==================================================================
BUG: KASAN: use-after-free in rose_timer_expiry+0x470/0x490 net/rose/rose_timer.c:183
Read of size 2 at addr ffff88807a71942a by task syz.3.2478/16324
CPU: 1 PID: 16324 Comm: syz.3.2478 Not tainted syzkaller #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 02/12/2026
Call Trace:
dump_stack_lvl+0x188/0x250 lib/dump_stack.c:106
print_address_description+0x60/0x2d0 mm/kasan/report.c:248
__kasan_report mm/kasan/report.c:434 [inline]
kasan_report+0xdf/0x130 mm/kasan/report.c:451
rose_timer_expiry+0x470/0x490 net/rose/rose_timer.c:183
call_timer_fn+0x17b/0x540 kernel/time/timer.c:1648
expire_timers kernel/time/timer.c:1699 [inline]
__run_timers+0x53e/0x800 kernel/time/timer.c:1970
run_timer_softirq+0x63/0xf0 kernel/time/timer.c:1983
handle_softirqs+0x339/0x830 kernel/softirq.c:576
__do_softirq kernel/softirq.c:610 [inline]
invoke_softirq kernel/softirq.c:450 [inline]
__irq_exit_rcu+0x13b/0x230 kernel/softirq.c:659
irq_exit_rcu+0x5/0x20 kernel/softirq.c:671
instr_sysvec_apic_timer_interrupt arch/x86/kernel/apic/apic.c:1108 [inline]
sysvec_apic_timer_interrupt+0xa0/0xc0 arch/x86/kernel/apic/apic.c:1108
asm_sysvec_apic_timer_interrupt+0x16/0x20 arch/x86/include/asm/idtentry.h:676
RIP: 0010:kasan_check_range+0x1b2/0x290 mm/kasan/generic.c:-1
Code: 01 f3 49 89 df 49 8d 5f 07 4d 85 ff 49 0f 49 df 48 83 e3 f8 49 29 df 74 0e 41 80 3b 00 75 69 49 ff c3 49 ff cf 75 f2 5b 41 5c <41> 5e 41 5f 5d c3 45 84 ff 0f 85 91 00 00 00 41 f7 c7 00 ff 00 00
RSP: 0018:ffffc9000455f600 EFLAGS: 00000256
RAX: 0000000000000001 RBX: 0000000000000000 RCX: ffffffff815d0086
RDX: 0000000000000000 RSI: 0000000000000008 RDI: ffffffff8d89e368
RBP: ffffc9000455f740 R08: ffffffff8d89e36f R09: 1ffffffff1b13c6d
R10: dffffc0000000000 R11: fffffbfff1b13c6e R12: ffffffff8c31eaa0
R13: 1ffff920008abed0 R14: 1ffffffff1b13c6d R15: 0000000000000001
instrument_atomic_read include/linux/instrumented.h:71 [inline]
test_bit include/asm-generic/bitops/instrumented-non-atomic.h:134 [inline]
cpumask_test_cpu include/linux/cpumask.h:344 [inline]
cpu_online include/linux/cpumask.h:895 [inline]
trace_lock_acquire include/trace/events/lock.h:13 [inline]
lock_acquire+0xb6/0x400 kernel/locking/lockdep.c:5594
rcu_lock_acquire+0x2a/0x30 include/linux/rcupdate.h:313
rcu_read_lock include/linux/rcupdate.h:740 [inline]
filemap_map_pages+0x193/0x13b0 mm/filemap.c:3313
do_fault_around mm/memory.c:4243 [inline]
do_read_fault mm/memory.c:4258 [inline]
do_fault mm/memory.c:4392 [inline]
handle_pte_fault mm/memory.c:4650 [inline]
__handle_mm_fault mm/memory.c:4785 [inline]
handle_mm_fault+0x25bc/0x4410 mm/memory.c:4883
faultin_page mm/gup.c:976 [inline]
__get_user_pages+0x94b/0x11e0 mm/gup.c:1197
populate_vma_page_range+0x213/0x290 mm/gup.c:1529
__mm_populate+0x275/0x3b0 mm/gup.c:1638
mm_populate include/linux/mm.h:2646 [inline]
vm_mmap_pgoff+0x212/0x2d0 mm/util.c:556
ksys_mmap_pgoff+0x140/0x790 mm/mmap.c:1635
do_syscall_x64 arch/x86/entry/common.c:50 [inline]
do_syscall_64+0x4c/0xa0 arch/x86/entry/common.c:80
entry_SYSCALL_64_after_hwframe+0x66/0xd0
RIP: 0033:0x7f89387a2799
Code: ff c3 66 2e 0f 1f 84 00 00 00 00 00 0f 1f 44 00 00 48 89 f8 48 89 f7 48 89 d6 48 89 ca 4d 89 c2 4d 89 c8 4c 8b 4c 24 08 0f 05 <48> 3d 01 f0 ff ff 73 01 c3 48 c7 c1 e8 ff ff ff f7 d8 64 89 01 48
RSP: 002b:00007f89369fc028 EFLAGS: 00000246 ORIG_RAX: 0000000000000009
RAX: ffffffffffffffda RBX: 00007f8938a1bfa0 RCX: 00007f89387a2799
RDX: b635773f06ebbeee RSI: 0000000000b36000 RDI: 0000200000000000
RBP: 00007f8938838c99 R08: ffffffffffffffff R09: 0000000000000000
R10: 0000000000008031 R11: 0000000000000246 R12: 0000000000000000
R13: 00007f8938a1c038 R14: 00007f8938a1bfa0 R15: 00007ffc38725d78
Allocated by task 16320:
kasan_save_stack mm/kasan/common.c:38 [inline]
kasan_set_track mm/kasan/common.c:46 [inline]
set_alloc_info mm/kasan/common.c:434 [inline]
____kasan_kmalloc mm/kasan/common.c:513 [inline]
__kasan_kmalloc+0xb5/0xf0 mm/kasan/common.c:522
kmalloc_reserve net/core/skbuff.c:356 [inline]
__alloc_skb+0x22c/0x750 net/core/skbuff.c:427
alloc_skb include/linux/skbuff.h:1162 [inline]
alloc_skb_with_frags+0xa7/0x730 net/core/skbuff.c:6170
sock_alloc_send_pskb+0x87f/0x9a0 net/core/sock.c:2536
__ip6_append_data+0x2593/0x38c0 net/ipv6/ip6_output.c:1663
ip6_make_skb+0x402/0x530 net/ipv6/ip6_output.c:2032
udpv6_sendmsg+0x1dd7/0x2650 net/ipv6/udp.c:1580
sock_sendmsg_nosec net/socket.c:706 [inline]
__sock_sendmsg net/socket.c:718 [inline]
____sys_sendmsg+0x5b7/0x8f0 net/socket.c:2445
___sys_sendmsg+0x236/0x2e0 net/socket.c:2499
__sys_sendmmsg+0x2ba/0x500 net/socket.c:2585
__do_sys_sendmmsg net/socket.c:2614 [inline]
__se_sys_sendmmsg net/socket.c:2611 [inline]
__x64_sys_sendmmsg+0x9c/0xb0 net/socket.c:2611
do_syscall_x64 arch/x86/entry/common.c:50 [inline]
do_syscall_64+0x4c/0xa0 arch/x86/entry/common.c:80
entry_SYSCALL_64_after_hwframe+0x66/0xd0
Freed by task 16320:
kasan_save_stack mm/kasan/common.c:38 [inline]
kasan_set_track+0x4b/0x70 mm/kasan/common.c:46
kasan_set_free_info+0x1f/0x40 mm/kasan/generic.c:360
____kasan_slab_free+0xd5/0x110 mm/kasan/common.c:366
kasan_slab_free include/linux/kasan.h:230 [inline]
slab_free_hook mm/slub.c:1710 [inline]
slab_free_freelist_hook+0xea/0x170 mm/slub.c:1736
slab_free mm/slub.c:3504 [inline]
kfree+0xef/0x2a0 mm/slub.c:4564
skb_free_head net/core/skbuff.c:655 [inline]
skb_release_data+0x6b8/0x800 net/core/skbuff.c:677
skb_release_all net/core/skbuff.c:742 [inline]
__kfree_skb net/core/skbuff.c:756 [inline]
kfree_skb_reason+0xaf/0x110 net/core/skbuff.c:776
ip6_pkt_discard_out+0xee/0x110 net/ipv6/route.c:4549
ip6_send_skb+0x1b9/0x360 net/ipv6/ip6_output.c:1952
udp_v6_send_skb+0xa28/0x1680 net/ipv6/udp.c:1285
udpv6_sendmsg+0x1e11/0x2650 net/ipv6/udp.c:1586
sock_sendmsg_nosec net/socket.c:706 [inline]
__sock_sendmsg net/socket.c:718 [inline]
____sys_sendmsg+0x5b7/0x8f0 net/socket.c:2445
___sys_sendmsg+0x236/0x2e0 net/socket.c:2499
__sys_sendmmsg+0x2ba/0x500 net/socket.c:2585
__do_sys_sendmmsg net/socket.c:2614 [inline]
__se_sys_sendmmsg net/socket.c:2611 [inline]
__x64_sys_sendmmsg+0x9c/0xb0 net/socket.c:2611
do_syscall_x64 arch/x86/entry/common.c:50 [inline]
do_syscall_64+0x4c/0xa0 arch/x86/entry/common.c:80
entry_SYSCALL_64_after_hwframe+0x66/0xd0
Last potentially related work creation:
kasan_save_stack+0x35/0x60 mm/kasan/common.c:38
kasan_record_aux_stack+0xb8/0x100 mm/kasan/generic.c:348
kvfree_call_rcu+0x105/0x7d0 kernel/rcu/tree.c:3600
hash_ipportnet6_flush+0x544/0x720 net/netfilter/ipset/ip_set_hash_gen.h:403
ip_set_flush_set net/netfilter/ipset/ip_set_core.c:1304 [inline]
ip_set_flush+0x3c2/0x650 net/netfilter/ipset/ip_set_core.c:1322
nfnetlink_rcv_msg+0xbb0/0x11f0 net/netfilter/nfnetlink.c:297
netlink_rcv_skb+0x1f5/0x440 net/netlink/af_netlink.c:2507
nfnetlink_rcv+0x2b4/0x2460 net/netfilter/nfnetlink.c:654
netlink_unicast_kernel net/netlink/af_netlink.c:1318 [inline]
netlink_unicast+0x774/0x920 net/netlink/af_netlink.c:1344
netlink_sendmsg+0x8ba/0xbe0 net/netlink/af_netlink.c:1918
sock_sendmsg_nosec net/socket.c:706 [inline]
__sock_sendmsg net/socket.c:718 [inline]
____sys_sendmsg+0x5b7/0x8f0 net/socket.c:2445
___sys_sendmsg+0x236/0x2e0 net/socket.c:2499
__sys_sendmsg net/socket.c:2528 [inline]
__do_sys_sendmsg net/socket.c:2537 [inline]
__se_sys_sendmsg+0x1af/0x290 net/socket.c:2535
do_syscall_x64 arch/x86/entry/common.c:50 [inline]
do_syscall_64+0x4c/0xa0 arch/x86/entry/common.c:80
entry_SYSCALL_64_after_hwframe+0x66/0xd0
The buggy address belongs to the object at ffff88807a719400
which belongs to the cache kmalloc-512 of size 512
The buggy address is located 42 bytes inside of
512-byte region [ffff88807a719400, ffff88807a719600)
The buggy address belongs to the page:
page:ffffea0001e9c600 refcount:1 mapcount:0 mapping:0000000000000000 index:0x0 pfn:0x7a718
head:ffffea0001e9c600 order:2 compound_mapcount:0 compound_pincount:0
flags: 0xfff00000010200(slab|head|node=0|zone=1|lastcpupid=0x7ff)
raw: 00fff00000010200 ffffea0001894a00 0000000600000006 ffff888016c41c80
raw: 0000000000000000 0000000000100010 00000001ffffffff 0000000000000000
page dumped because: kasan: bad access detected
page_owner tracks the page as allocated
page last allocated via order 2, migratetype Unmovable, gfp_mask 0x1d2a20(GFP_ATOMIC|__GFP_NOWARN|__GFP_NORETRY|__GFP_COMP|__GFP_NOMEMALLOC|__GFP_HARDWALL), pid 4236, ts 92309705386, free_ts 92262564353
prep_new_page mm/page_alloc.c:2426 [inline]
get_page_from_freelist+0x1bbd/0x1ca0 mm/page_alloc.c:4192
__alloc_pages+0x1ee/0x480 mm/page_alloc.c:5501
alloc_slab_page mm/slub.c:1780 [inline]
allocate_slab mm/slub.c:1917 [inline]
new_slab+0xc0/0x4b0 mm/slub.c:1980
___slab_alloc+0x80a/0xdd0 mm/slub.c:3013
__slab_alloc mm/slub.c:3100 [inline]
slab_alloc_node mm/slub.c:3191 [inline]
__kmalloc_node_track_caller+0x1fc/0x3a0 mm/slub.c:4963
kmalloc_reserve net/core/skbuff.c:356 [inline]
__alloc_skb+0x22c/0x750 net/core/skbuff.c:427
alloc_skb include/linux/skbuff.h:1162 [inline]
ndisc_alloc_skb+0xa6/0x420 net/ipv6/ndisc.c:422
ndisc_send_rs+0x291/0x730 net/ipv6/ndisc.c:691
addrconf_dad_completed+0x75d/0xc80 net/ipv6/addrconf.c:4275
addrconf_dad_work+0xc8c/0x1540 net/ipv6/addrconf.c:-1
process_one_work+0x85f/0x1010 kernel/workqueue.c:2310
worker_thread+0xaa6/0x1290 kernel/workqueue.c:2457
kthread+0x436/0x520 kernel/kthread.c:334
ret_from_fork+0x1f/0x30 arch/x86/entry/entry_64.S:287
page last free stack trace:
reset_page_owner include/linux/page_owner.h:24 [inline]
free_pages_prepare mm/page_alloc.c:1340 [inline]
free_pcp_prepare mm/page_alloc.c:1391 [inline]
free_unref_page_prepare+0x637/0x6c0 mm/page_alloc.c:3317
free_unref_page+0x8f/0x2a0 mm/page_alloc.c:3396
free_slab mm/slub.c:2020 [inline]
discard_slab mm/slub.c:2026 [inline]
__unfreeze_partials+0x1a5/0x200 mm/slub.c:2512
put_cpu_partial+0x12d/0x190 mm/slub.c:2592
qlist_free_all+0x35/0x90 mm/kasan/quarantine.c:176
kasan_quarantine_reduce+0x150/0x160 mm/kasan/quarantine.c:283
__kasan_slab_alloc+0x2f/0xd0 mm/kasan/common.c:444
kasan_slab_alloc include/linux/kasan.h:254 [inline]
slab_post_alloc_hook+0x4c/0x380 mm/slab.h:519
slab_alloc_node mm/slub.c:3225 [inline]
slab_alloc mm/slub.c:3233 [inline]
kmem_cache_alloc+0x100/0x290 mm/slub.c:3238
ptlock_alloc+0x1c/0x60 mm/memory.c:5556
ptlock_init include/linux/mm.h:2241 [inline]
pgtable_pte_page_ctor include/linux/mm.h:2268 [inline]
__pte_alloc_one include/asm-generic/pgalloc.h:66 [inline]
pte_alloc_one+0xc0/0x310 arch/x86/mm/pgtable.c:33
__pte_alloc+0x21/0x150 mm/memory.c:439
do_anonymous_page mm/memory.c:3806 [inline]
handle_pte_fault mm/memory.c:4648 [inline]
__handle_mm_fault mm/memory.c:4785 [inline]
handle_mm_fault+0x39b6/0x4410 mm/memory.c:4883
do_user_addr_fault+0x489/0xc80 arch/x86/mm/fault.c:1355
handle_page_fault arch/x86/mm/fault.c:1443 [inline]
exc_page_fault+0x60/0x100 arch/x86/mm/fault.c:1496
asm_exc_page_fault+0x22/0x30 arch/x86/include/asm/idtentry.h:606
Memory state around the buggy address:
ffff88807a719300: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc
ffff88807a719380: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc
>ffff88807a719400: fa fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb
^
ffff88807a719480: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb
ffff88807a719500: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb
==================================================================
----------------
Code disassembly (best guess):
0: 01 f3 add %esi,%ebx
2: 49 89 df mov %rbx,%r15
5: 49 8d 5f 07 lea 0x7(%r15),%rbx
9: 4d 85 ff test %r15,%r15
c: 49 0f 49 df cmovns %r15,%rbx
10: 48 83 e3 f8 and $0xfffffffffffffff8,%rbx
14: 49 29 df sub %rbx,%r15
17: 74 0e je 0x27
19: 41 80 3b 00 cmpb $0x0,(%r11)
1d: 75 69 jne 0x88
1f: 49 ff c3 inc %r11
22: 49 ff cf dec %r15
25: 75 f2 jne 0x19
27: 5b pop %rbx
28: 41 5c pop %r12
* 2a: 41 5e pop %r14 <-- trapping instruction
2c: 41 5f pop %r15
2e: 5d pop %rbp
2f: c3 ret
30: 45 84 ff test %r15b,%r15b
33: 0f 85 91 00 00 00 jne 0xca
39: 41 f7 c7 00 ff 00 00 test $0xff00,%r15d