================================================================== BUG: KASAN: slab-use-after-free in rose_timer_expiry+0x45a/0x4d0 net/rose/rose_timer.c:183 Read of size 2 at addr ffff888056f6482a by task syz-executor/5830 CPU: 1 UID: 0 PID: 5830 Comm: syz-executor Not tainted 6.16.0-rc5-syzkaller #0 PREEMPT(full) Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 05/07/2025 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+0xcd/0x680 mm/kasan/report.c:521 kasan_report+0xe0/0x110 mm/kasan/report.c:634 rose_timer_expiry+0x45a/0x4d0 net/rose/rose_timer.c:183 call_timer_fn+0x197/0x620 kernel/time/timer.c:1747 expire_timers kernel/time/timer.c:1798 [inline] __run_timers+0x6ef/0x960 kernel/time/timer.c:2372 __run_timer_base kernel/time/timer.c:2384 [inline] __run_timer_base kernel/time/timer.c:2376 [inline] run_timer_base+0x114/0x190 kernel/time/timer.c:2393 run_timer_softirq+0x1a/0x40 kernel/time/timer.c:2403 handle_softirqs+0x219/0x8e0 kernel/softirq.c:579 __do_softirq kernel/softirq.c:613 [inline] invoke_softirq kernel/softirq.c:453 [inline] __irq_exit_rcu+0x109/0x170 kernel/softirq.c:680 irq_exit_rcu+0x9/0x30 kernel/softirq.c:696 instr_sysvec_apic_timer_interrupt arch/x86/kernel/apic/apic.c:1050 [inline] sysvec_apic_timer_interrupt+0xa4/0xc0 arch/x86/kernel/apic/apic.c:1050 asm_sysvec_apic_timer_interrupt+0x1a/0x20 arch/x86/include/asm/idtentry.h:702 RIP: 0010:__sanitizer_cov_trace_pc+0x0/0x70 kernel/kcov.c:210 Code: 26 4e 56 00 48 89 df 5b e9 1d d6 5b 00 be 03 00 00 00 5b e9 12 65 20 03 66 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 0f 1e fa 48 8b 34 24 65 48 8b 15 58 99 14 12 65 8b 05 69 99 14 RSP: 0018:ffffc900030e7430 EFLAGS: 00000202 RAX: fffffbfff35c5e30 RBX: 00000000000697fd RCX: ffffffff822e7607 RDX: ffff888036dea440 RSI: ffffffff822e7615 RDI: 0000000000000007 RBP: 0000000000000001 R08: 0000000000000007 R09: 0000000000000000 R10: 00000000000017fd R11: 0000000000000001 R12: ffff88801f077f10 R13: 0000000000000001 R14: 0000000000000000 R15: 00000000000017fd page_table_check_set+0x2e3/0x750 mm/page_table_check.c:113 __page_table_check_ptes_set+0x318/0x420 mm/page_table_check.c:209 page_table_check_ptes_set include/linux/page_table_check.h:76 [inline] set_ptes include/linux/pgtable.h:292 [inline] __copy_present_ptes mm/memory.c:973 [inline] copy_present_ptes+0x1aa1/0x6790 mm/memory.c:1056 copy_pte_range mm/memory.c:1179 [inline] copy_pmd_range mm/memory.c:1267 [inline] copy_pud_range mm/memory.c:1304 [inline] copy_p4d_range mm/memory.c:1328 [inline] copy_page_range+0x125a/0x5740 mm/memory.c:1416 dup_mmap+0xe88/0x21d0 mm/mmap.c:1838 dup_mm kernel/fork.c:1477 [inline] copy_mm kernel/fork.c:1529 [inline] copy_process+0x4081/0x7650 kernel/fork.c:2169 kernel_clone+0xfc/0x960 kernel/fork.c:2599 __do_sys_clone+0xce/0x120 kernel/fork.c:2742 do_syscall_x64 arch/x86/entry/syscall_64.c:63 [inline] do_syscall_64+0xcd/0x4c0 arch/x86/entry/syscall_64.c:94 entry_SYSCALL_64_after_hwframe+0x77/0x7f RIP: 0033:0x7fa16c985193 Code: 1f 84 00 00 00 00 00 64 48 8b 04 25 10 00 00 00 45 31 c0 31 d2 31 f6 bf 11 00 20 01 4c 8d 90 d0 02 00 00 b8 38 00 00 00 0f 05 <48> 3d 00 f0 ff ff 77 35 89 c2 85 c0 75 2c 64 48 8b 04 25 10 00 00 RSP: 002b:00007ffd6eea66c8 EFLAGS: 00000246 ORIG_RAX: 0000000000000038 RAX: ffffffffffffffda RBX: 0000000000000000 RCX: 00007fa16c985193 RDX: 0000000000000000 RSI: 0000000000000000 RDI: 0000000001200011 RBP: 0000000000000001 R08: 0000000000000000 R09: 0000000000000001 R10: 000055557b58c7d0 R11: 0000000000000246 R12: 0000000000000000 R13: 00000000000927c0 R14: 000000000004487b R15: 00007ffd6eea6860 Allocated by task 6848: 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] kzalloc_noprof include/linux/slab.h:1039 [inline] kernfs_fop_open+0x244/0xda0 fs/kernfs/file.c:623 do_dentry_open+0x744/0x1c10 fs/open.c:964 vfs_open+0x82/0x3f0 fs/open.c:1094 do_open fs/namei.c:3896 [inline] path_openat+0x1de4/0x2cb0 fs/namei.c:4055 do_filp_open+0x20b/0x470 fs/namei.c:4082 do_sys_openat2+0x11b/0x1d0 fs/open.c:1437 do_sys_open fs/open.c:1452 [inline] __do_sys_openat fs/open.c:1468 [inline] __se_sys_openat fs/open.c:1463 [inline] __x64_sys_openat+0x174/0x210 fs/open.c:1463 do_syscall_x64 arch/x86/entry/syscall_64.c:63 [inline] do_syscall_64+0xcd/0x4c0 arch/x86/entry/syscall_64.c:94 entry_SYSCALL_64_after_hwframe+0x77/0x7f Freed by task 6848: 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:2381 [inline] slab_free mm/slub.c:4643 [inline] kfree+0x2b4/0x4d0 mm/slub.c:4842 kernfs_fop_release+0x12c/0x1e0 fs/kernfs/file.c:768 __fput+0x3ff/0xb70 fs/file_table.c:465 fput_close_sync+0x118/0x260 fs/file_table.c:570 __do_sys_close fs/open.c:1589 [inline] __se_sys_close fs/open.c:1574 [inline] __x64_sys_close+0x8b/0x120 fs/open.c:1574 do_syscall_x64 arch/x86/entry/syscall_64.c:63 [inline] do_syscall_64+0xcd/0x4c0 arch/x86/entry/syscall_64.c:94 entry_SYSCALL_64_after_hwframe+0x77/0x7f The buggy address belongs to the object at ffff888056f64800 which belongs to the cache kmalloc-512 of size 512 The buggy address is located 42 bytes inside of freed 512-byte region [ffff888056f64800, ffff888056f64a00) The buggy address belongs to the physical page: page: refcount:0 mapcount:0 mapping:0000000000000000 index:0xffff888056f67000 pfn:0x56f64 head: order:2 mapcount:0 entire_mapcount:0 nr_pages_mapped:0 pincount:0 flags: 0xfff00000000240(workingset|head|node=0|zone=1|lastcpupid=0x7ff) page_type: f5(slab) raw: 00fff00000000240 ffff88801b841c80 ffffea00007ed110 ffffea000156aa10 raw: ffff888056f67000 0000000000100009 00000000f5000000 0000000000000000 head: 00fff00000000240 ffff88801b841c80 ffffea00007ed110 ffffea000156aa10 head: ffff888056f67000 0000000000100009 00000000f5000000 0000000000000000 head: 00fff00000000002 ffffea00015bd901 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 5838, tgid 5838 (syz-executor), ts 66143749858, free_ts 15501310900 set_page_owner include/linux/page_owner.h:32 [inline] post_alloc_hook+0x1c0/0x230 mm/page_alloc.c:1704 prep_new_page mm/page_alloc.c:1712 [inline] get_page_from_freelist+0x1321/0x3890 mm/page_alloc.c:3669 __alloc_frozen_pages_noprof+0x261/0x23f0 mm/page_alloc.c:4959 alloc_pages_mpol+0x1fb/0x550 mm/mempolicy.c:2419 alloc_slab_page mm/slub.c:2451 [inline] allocate_slab mm/slub.c:2619 [inline] new_slab+0x23b/0x330 mm/slub.c:2673 ___slab_alloc+0xd9c/0x1940 mm/slub.c:3859 __slab_alloc.constprop.0+0x56/0xb0 mm/slub.c:3949 __slab_alloc_node mm/slub.c:4024 [inline] slab_alloc_node mm/slub.c:4185 [inline] __kmalloc_cache_noprof+0xfb/0x3e0 mm/slub.c:4354 kmalloc_noprof include/linux/slab.h:905 [inline] kzalloc_noprof include/linux/slab.h:1039 [inline] device_private_init drivers/base/core.c:3537 [inline] device_add+0xccc/0x1a70 drivers/base/core.c:3588 wiphy_register+0x1c9c/0x2850 net/wireless/core.c:1005 ieee80211_register_hw+0x24ac/0x4140 net/mac80211/main.c:1589 mac80211_hwsim_new_radio+0x3034/0x54d0 drivers/net/wireless/virtual/mac80211_hwsim.c:5565 hwsim_new_radio_nl+0xb51/0x12c0 drivers/net/wireless/virtual/mac80211_hwsim.c:6249 genl_family_rcv_msg_doit+0x206/0x2f0 net/netlink/genetlink.c:1115 genl_family_rcv_msg net/netlink/genetlink.c:1195 [inline] genl_rcv_msg+0x55c/0x800 net/netlink/genetlink.c:1210 netlink_rcv_skb+0x155/0x420 net/netlink/af_netlink.c:2534 page last free pid 1 tgid 1 stack trace: reset_page_owner include/linux/page_owner.h:25 [inline] free_pages_prepare mm/page_alloc.c:1248 [inline] __free_frozen_pages+0x7fe/0x1180 mm/page_alloc.c:2706 __free_pages mm/page_alloc.c:5071 [inline] free_contig_range+0x183/0x4b0 mm/page_alloc.c:6927 destroy_args+0x7f6/0xa60 mm/debug_vm_pgtable.c:1009 debug_vm_pgtable+0x13b8/0x2d00 mm/debug_vm_pgtable.c:1389 do_one_initcall+0x120/0x6e0 init/main.c:1274 do_initcall_level init/main.c:1336 [inline] do_initcalls init/main.c:1352 [inline] do_basic_setup init/main.c:1371 [inline] kernel_init_freeable+0x5c2/0x900 init/main.c:1584 kernel_init+0x1c/0x2b0 init/main.c:1474 ret_from_fork+0x5d4/0x6f0 arch/x86/kernel/process.c:148 ret_from_fork_asm+0x1a/0x30 arch/x86/entry/entry_64.S:245 Memory state around the buggy address: ffff888056f64700: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc ffff888056f64780: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc >ffff888056f64800: fa fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb ^ ffff888056f64880: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb ffff888056f64900: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb ================================================================== vkms_vblank_simulate: vblank timer overrun ---------------- Code disassembly (best guess): 0: 26 4e 56 es rex.WRX push %rsi 3: 00 48 89 add %cl,-0x77(%rax) 6: df 5b e9 fistps -0x17(%rbx) 9: 1d d6 5b 00 be sbb $0xbe005bd6,%eax e: 03 00 add (%rax),%eax 10: 00 00 add %al,(%rax) 12: 5b pop %rbx 13: e9 12 65 20 03 jmp 0x320652a 18: 66 90 xchg %ax,%ax 1a: 90 nop 1b: 90 nop 1c: 90 nop 1d: 90 nop 1e: 90 nop 1f: 90 nop 20: 90 nop 21: 90 nop 22: 90 nop 23: 90 nop 24: 90 nop 25: 90 nop 26: 90 nop 27: 90 nop 28: 90 nop 29: 90 nop * 2a: f3 0f 1e fa endbr64 <-- trapping instruction 2e: 48 8b 34 24 mov (%rsp),%rsi 32: 65 48 8b 15 58 99 14 mov %gs:0x12149958(%rip),%rdx # 0x12149992 39: 12 3a: 65 gs 3b: 8b .byte 0x8b 3c: 05 .byte 0x5 3d: 69 .byte 0x69 3e: 99 cltd 3f: 14 .byte 0x14