==================================================================
BUG: KASAN: slab-use-after-free in __raw_spin_lock_irqsave include/linux/spinlock_api_smp.h:110 [inline]
BUG: KASAN: slab-use-after-free in _raw_spin_lock_irqsave+0x3a/0x60 kernel/locking/spinlock.c:162
Read of size 1 at addr ffff88804f15fc18 by task syz-executor/5953
CPU: 3 UID: 0 PID: 5953 Comm: syz-executor Not tainted 6.15.0-rc1-syzkaller-00060-ga24588245776 #0 PREEMPT(full)
Hardware name: QEMU Standard PC (Q35 + ICH9, 2009), BIOS 1.16.3-debian-1.16.3-2~bpo12+1 04/01/2014
Call Trace:
__dump_stack lib/dump_stack.c:94 [inline]
dump_stack_lvl+0x116/0x1f0 lib/dump_stack.c:120
print_address_description mm/kasan/report.c:408 [inline]
print_report+0xc3/0x670 mm/kasan/report.c:521
kasan_report+0xe0/0x110 mm/kasan/report.c:634
__kasan_check_byte+0x36/0x50 mm/kasan/common.c:557
kasan_check_byte include/linux/kasan.h:399 [inline]
lock_acquire kernel/locking/lockdep.c:5840 [inline]
lock_acquire+0xfc/0x350 kernel/locking/lockdep.c:5823
__raw_spin_lock_irqsave include/linux/spinlock_api_smp.h:110 [inline]
_raw_spin_lock_irqsave+0x3a/0x60 kernel/locking/spinlock.c:162
p9_tag_remove net/9p/client.c:397 [inline]
p9_req_put net/9p/client.c:405 [inline]
p9_req_put+0xaf/0x250 net/9p/client.c:402
req_done+0x1dc/0x2e0 net/9p/trans_virtio.c:147
vring_interrupt drivers/virtio/virtio_ring.c:2715 [inline]
vring_interrupt+0x31b/0x400 drivers/virtio/virtio_ring.c:2690
__handle_irq_event_percpu+0x229/0x7d0 kernel/irq/handle.c:158
handle_irq_event_percpu kernel/irq/handle.c:193 [inline]
handle_irq_event+0xab/0x1e0 kernel/irq/handle.c:210
handle_edge_irq+0x263/0xd10 kernel/irq/chip.c:831
generic_handle_irq_desc include/linux/irqdesc.h:173 [inline]
handle_irq arch/x86/kernel/irq.c:254 [inline]
call_irq_handler arch/x86/kernel/irq.c:266 [inline]
__common_interrupt+0xdf/0x250 arch/x86/kernel/irq.c:292
common_interrupt+0xba/0xe0 arch/x86/kernel/irq.c:285
asm_common_interrupt+0x26/0x40 arch/x86/include/asm/idtentry.h:693
RIP: 0010:__sanitizer_cov_trace_pc+0x66/0x70 kernel/kcov.c:235
Code: 82 18 16 00 00 83 f8 02 75 20 48 8b 8a 20 16 00 00 8b 92 1c 16 00 00 48 8b 01 48 83 c0 01 48 39 d0 73 07 48 89 01 48 89 34 c1 cc cc cc cc 0f 1f 44 00 00 90 90 90 90 90 90 90 90 90 90 90 90
RSP: 0018:ffffc90002957dd8 EFLAGS: 00000293
RAX: 0000000000000000 RBX: 0000000000000000 RCX: ffffffff84815db9
RDX: ffff888025c00000 RSI: ffffffff84815e35 RDI: 0000000000000005
RBP: ffffc90002957e78 R08: 0000000000000005 R09: 0000000000000000
R10: 0000000000000000 R11: 0000000000000000 R12: ffff88805005e178
R13: ffff888025671100 R14: 0000000000000000 R15: ffff88805123ea00
security_path_unlink+0x115/0x2b0 security/security.c:1965
do_unlinkat+0x463/0x6a0 fs/namei.c:4605
__do_sys_unlink fs/namei.c:4654 [inline]
__se_sys_unlink fs/namei.c:4652 [inline]
__x64_sys_unlink+0xc5/0x110 fs/namei.c:4652
do_syscall_x64 arch/x86/entry/syscall_64.c:63 [inline]
do_syscall_64+0xcd/0x260 arch/x86/entry/syscall_64.c:94
entry_SYSCALL_64_after_hwframe+0x77/0x7f
RIP: 0033:0x7f5d0e58c717
Code: 73 01 c3 48 c7 c1 a8 ff ff ff f7 d8 64 89 01 48 83 c8 ff c3 66 2e 0f 1f 84 00 00 00 00 00 0f 1f 44 00 00 b8 57 00 00 00 0f 05 <48> 3d 01 f0 ff ff 73 01 c3 48 c7 c1 a8 ff ff ff f7 d8 64 89 01 48
RSP: 002b:00007ffec40d96d8 EFLAGS: 00000202 ORIG_RAX: 0000000000000057
RAX: ffffffffffffffda RBX: 0000000000000062 RCX: 00007f5d0e58c717
RDX: 0000000000000000 RSI: 0000000000000000 RDI: 00007ffec40d9790
RBP: 00007ffec40d9790 R08: 0000000000000000 R09: 0000000000000000
R10: 0000000000000000 R11: 0000000000000202 R12: 00007ffec40da820
R13: 00007f5d0e60e08c R14: 0000555561fe84a8 R15: 0000000000000005
Allocated by task 6334:
kasan_save_stack+0x33/0x60 mm/kasan/common.c:47
kasan_save_track+0x14/0x30 mm/kasan/common.c:68
poison_kmalloc_redzone mm/kasan/common.c:377 [inline]
__kasan_kmalloc+0xaa/0xb0 mm/kasan/common.c:394
kmalloc_noprof include/linux/slab.h:905 [inline]
p9_client_create+0xc7/0x11c0 net/9p/client.c:985
v9fs_session_init+0x1f7/0x1a80 fs/9p/v9fs.c:410
v9fs_mount+0xc5/0xa30 fs/9p/vfs_super.c:122
legacy_get_tree+0x109/0x220 fs/fs_context.c:662
vfs_get_tree+0x8b/0x340 fs/super.c:1759
do_new_mount fs/namespace.c:3879 [inline]
path_mount+0x14d4/0x1f30 fs/namespace.c:4206
do_mount fs/namespace.c:4219 [inline]
__do_sys_mount fs/namespace.c:4430 [inline]
__se_sys_mount fs/namespace.c:4407 [inline]
__x64_sys_mount+0x28d/0x310 fs/namespace.c:4407
do_syscall_x64 arch/x86/entry/syscall_64.c:63 [inline]
do_syscall_64+0xcd/0x260 arch/x86/entry/syscall_64.c:94
entry_SYSCALL_64_after_hwframe+0x77/0x7f
Freed by task 6334:
kasan_save_stack+0x33/0x60 mm/kasan/common.c:47
kasan_save_track+0x14/0x30 mm/kasan/common.c:68
kasan_save_free_info+0x3b/0x60 mm/kasan/generic.c:576
poison_slab_object mm/kasan/common.c:247 [inline]
__kasan_slab_free+0x51/0x70 mm/kasan/common.c:264
kasan_slab_free include/linux/kasan.h:233 [inline]
slab_free_hook mm/slub.c:2389 [inline]
slab_free mm/slub.c:4646 [inline]
kfree+0x2b6/0x4d0 mm/slub.c:4845
p9_client_create+0xa28/0x11c0 net/9p/client.c:1064
v9fs_session_init+0x1f7/0x1a80 fs/9p/v9fs.c:410
v9fs_mount+0xc5/0xa30 fs/9p/vfs_super.c:122
legacy_get_tree+0x109/0x220 fs/fs_context.c:662
vfs_get_tree+0x8b/0x340 fs/super.c:1759
do_new_mount fs/namespace.c:3879 [inline]
path_mount+0x14d4/0x1f30 fs/namespace.c:4206
do_mount fs/namespace.c:4219 [inline]
__do_sys_mount fs/namespace.c:4430 [inline]
__se_sys_mount fs/namespace.c:4407 [inline]
__x64_sys_mount+0x28d/0x310 fs/namespace.c:4407
do_syscall_x64 arch/x86/entry/syscall_64.c:63 [inline]
do_syscall_64+0xcd/0x260 arch/x86/entry/syscall_64.c:94
entry_SYSCALL_64_after_hwframe+0x77/0x7f
The buggy address belongs to the object at ffff88804f15fc00
which belongs to the cache kmalloc-512 of size 512
The buggy address is located 24 bytes inside of
freed 512-byte region [ffff88804f15fc00, ffff88804f15fe00)
The buggy address belongs to the physical page:
page: refcount:0 mapcount:0 mapping:0000000000000000 index:0x0 pfn:0x4f15c
head: order:2 mapcount:0 entire_mapcount:0 nr_pages_mapped:0 pincount:0
anon flags: 0xfff00000000040(head|node=0|zone=1|lastcpupid=0x7ff)
page_type: f5(slab)
raw: 00fff00000000040 ffff88801b442c80 0000000000000000 dead000000000001
raw: 0000000000000000 0000000080100010 00000000f5000000 0000000000000000
head: 00fff00000000040 ffff88801b442c80 0000000000000000 dead000000000001
head: 0000000000000000 0000000080100010 00000000f5000000 0000000000000000
head: 00fff00000000002 ffffea00013c5701 00000000ffffffff 00000000ffffffff
head: ffffffffffffffff 0000000000000000 00000000ffffffff 0000000000000004
page dumped because: kasan: bad access detected
page_owner tracks the page as allocated
page last allocated via order 2, migratetype Unmovable, gfp_mask 0xd20c0(__GFP_IO|__GFP_FS|__GFP_NOWARN|__GFP_NORETRY|__GFP_COMP|__GFP_NOMEMALLOC), pid 5948, tgid 5948 (syz-executor), ts 49224882638, free_ts 0
set_page_owner include/linux/page_owner.h:32 [inline]
post_alloc_hook+0x181/0x1b0 mm/page_alloc.c:1717
prep_new_page mm/page_alloc.c:1725 [inline]
get_page_from_freelist+0x1193/0x39b0 mm/page_alloc.c:3652
__alloc_frozen_pages_noprof+0x263/0x23a0 mm/page_alloc.c:4934
alloc_pages_mpol+0x1fb/0x550 mm/mempolicy.c:2301
alloc_slab_page mm/slub.c:2459 [inline]
allocate_slab mm/slub.c:2623 [inline]
new_slab+0x23c/0x330 mm/slub.c:2676
___slab_alloc+0xd9c/0x1940 mm/slub.c:3862
__slab_alloc.constprop.0+0x56/0xb0 mm/slub.c:3952
__slab_alloc_node mm/slub.c:4027 [inline]
slab_alloc_node mm/slub.c:4188 [inline]
__do_kmalloc_node mm/slub.c:4330 [inline]
__kmalloc_noprof+0x2f2/0x510 mm/slub.c:4343
kmalloc_noprof include/linux/slab.h:909 [inline]
kzalloc_noprof include/linux/slab.h:1039 [inline]
fib6_info_alloc+0x40/0x160 net/ipv6/ip6_fib.c:155
ip6_route_info_create+0x33f/0x18e0 net/ipv6/route.c:3801
ip6_route_add+0x26/0x1c0 net/ipv6/route.c:3895
addrconf_prefix_route+0x2fd/0x510 net/ipv6/addrconf.c:2487
add_v4_addrs+0x6cc/0x9f0 net/ipv6/addrconf.c:3266
addrconf_sit_config net/ipv6/addrconf.c:3516 [inline]
addrconf_init_auto_addrs+0x4df/0x820 net/ipv6/addrconf.c:3553
addrconf_notify+0xe93/0x19e0 net/ipv6/addrconf.c:3740
notifier_call_chain+0xb9/0x410 kernel/notifier.c:85
page_owner free stack trace missing
Memory state around the buggy address:
ffff88804f15fb00: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc
ffff88804f15fb80: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc
>ffff88804f15fc00: fa fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb
^
ffff88804f15fc80: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb
ffff88804f15fd00: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb
==================================================================
----------------
Code disassembly (best guess), 1 bytes skipped:
0: 18 16 sbb %dl,(%rsi)
2: 00 00 add %al,(%rax)
4: 83 f8 02 cmp $0x2,%eax
7: 75 20 jne 0x29
9: 48 8b 8a 20 16 00 00 mov 0x1620(%rdx),%rcx
10: 8b 92 1c 16 00 00 mov 0x161c(%rdx),%edx
16: 48 8b 01 mov (%rcx),%rax
19: 48 83 c0 01 add $0x1,%rax
1d: 48 39 d0 cmp %rdx,%rax
20: 73 07 jae 0x29
22: 48 89 01 mov %rax,(%rcx)
25: 48 89 34 c1 mov %rsi,(%rcx,%rax,8)
* 29: c3 ret <-- trapping instruction
2a: cc int3
2b: cc int3
2c: cc int3
2d: cc int3
2e: 0f 1f 44 00 00 nopl 0x0(%rax,%rax,1)
33: 90 nop
34: 90 nop
35: 90 nop
36: 90 nop
37: 90 nop
38: 90 nop
39: 90 nop
3a: 90 nop
3b: 90 nop
3c: 90 nop
3d: 90 nop
3e: 90 nop