================================================================== BUG: KASAN: double-free in rcu_free_sheaf+0x31/0x200 mm/slub.c:5850 Free of addr ffff888029c98180 by task syz.0.443/8022 CPU: 0 UID: 0 PID: 8022 Comm: syz.0.443 Not tainted syzkaller #0 PREEMPT(full) Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 04/18/2026 Call Trace: dump_stack_lvl+0xe8/0x150 lib/dump_stack.c:120 print_address_description+0x55/0x1e0 mm/kasan/report.c:378 print_report+0x58/0x70 mm/kasan/report.c:482 kasan_report_invalid_free+0xea/0x110 mm/kasan/report.c:557 check_slab_allocation mm/kasan/common.c:-1 [inline] __kasan_slab_pre_free+0x104/0x120 mm/kasan/common.c:261 kasan_slab_pre_free include/linux/kasan.h:199 [inline] slab_free_hook mm/slub.c:2634 [inline] __rcu_free_sheaf_prepare+0x10a/0x2a0 mm/slub.c:2940 rcu_free_sheaf+0x31/0x200 mm/slub.c:5850 rcu_do_batch kernel/rcu/tree.c:2617 [inline] rcu_core+0x7cd/0x1070 kernel/rcu/tree.c:2869 handle_softirqs+0x22a/0x840 kernel/softirq.c:622 __do_softirq kernel/softirq.c:656 [inline] invoke_softirq kernel/softirq.c:496 [inline] __irq_exit_rcu+0xca/0x220 kernel/softirq.c:735 irq_exit_rcu+0x9/0x30 kernel/softirq.c:752 instr_sysvec_apic_timer_interrupt arch/x86/kernel/apic/apic.c:1061 [inline] sysvec_apic_timer_interrupt+0xa6/0xc0 arch/x86/kernel/apic/apic.c:1061 asm_sysvec_apic_timer_interrupt+0x1a/0x20 arch/x86/include/asm/idtentry.h:697 RIP: 0010:__kasan_check_read+0x0/0x20 mm/kasan/shadow.c:30 Code: 22 8e 48 89 de e8 90 9b f6 fe 31 ed eb cf cc cc cc cc cc cc cc cc cc cc cc cc 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 0f 1e fa 89 f6 48 8b 0c 24 31 d2 e9 8f e5 ff ff 66 66 66 66 66 RSP: 0018:ffffc90005567398 EFLAGS: 00000246 RAX: ffffffff821676f4 RBX: ffff888042de2258 RCX: ffff888033cc3e00 RDX: 0000000000000000 RSI: 0000000000000008 RDI: ffffea00017c9480 RBP: ffffc90005567690 R08: ffffea00017c9473 R09: 1ffffd40002f928e R10: dffffc0000000000 R11: fffff940002f928f R12: dffffc0000000000 R13: 800000005f252007 R14: 0000000000000000 R15: ffffea00017c9480 instrument_atomic_read include/linux/instrumented.h:82 [inline] _test_bit include/asm-generic/bitops/instrumented-non-atomic.h:141 [inline] folio_test_head include/linux/page-flags.h:843 [inline] folio_test_large include/linux/page-flags.h:864 [inline] zap_present_ptes mm/memory.c:1723 [inline] do_zap_pte_range mm/memory.c:1832 [inline] zap_pte_range mm/memory.c:1934 [inline] zap_pmd_range mm/memory.c:2020 [inline] zap_pud_range mm/memory.c:2048 [inline] zap_p4d_range mm/memory.c:2069 [inline] __zap_vma_range+0x161b/0x4b70 mm/memory.c:2109 unmap_vmas+0x3ac/0x570 mm/memory.c:2178 exit_mmap+0x280/0x9e0 mm/mmap.c:1300 __mmput+0x118/0x430 kernel/fork.c:1178 exit_mm+0x1f6/0x2d0 kernel/exit.c:582 do_exit+0x6a2/0x22c0 kernel/exit.c:964 do_group_exit+0x21b/0x2d0 kernel/exit.c:1119 get_signal+0x1284/0x1330 kernel/signal.c:3037 arch_do_signal_or_restart+0xbc/0x840 arch/x86/kernel/signal.c:337 __exit_to_user_mode_loop kernel/entry/common.c:64 [inline] exit_to_user_mode_loop+0xa9/0x680 kernel/entry/common.c:98 __exit_to_user_mode_prepare include/linux/irq-entry-common.h:207 [inline] syscall_exit_to_user_mode_prepare include/linux/irq-entry-common.h:230 [inline] syscall_exit_to_user_mode include/linux/entry-common.h:318 [inline] do_syscall_64+0x353/0x580 arch/x86/entry/syscall_64.c:100 entry_SYSCALL_64_after_hwframe+0x77/0x7f RIP: 0033:0x7fbce2d9ce59 Code: Unable to access opcode bytes at 0x7fbce2d9ce2f. RSP: 002b:00007fbce3d020e8 EFLAGS: 00000246 ORIG_RAX: 00000000000000ca RAX: fffffffffffffe00 RBX: 00007fbce3016098 RCX: 00007fbce2d9ce59 RDX: 0000000000000000 RSI: 0000000000000080 RDI: 00007fbce3016098 RBP: 00007fbce3016090 R08: 0000000000000000 R09: 0000000000000000 R10: 0000000000000000 R11: 0000000000000246 R12: 0000000000000000 R13: 00007fbce3016128 R14: 00007ffed8795e50 R15: 00007ffed8795f38 Allocated by task 7771: kasan_save_stack mm/kasan/common.c:57 [inline] kasan_save_track+0x3e/0x80 mm/kasan/common.c:78 poison_kmalloc_redzone mm/kasan/common.c:398 [inline] __kasan_kmalloc+0x93/0xb0 mm/kasan/common.c:415 kasan_kmalloc include/linux/kasan.h:263 [inline] __do_kmalloc_node mm/slub.c:5296 [inline] __kmalloc_noprof+0x35c/0x760 mm/slub.c:5308 kmalloc_noprof include/linux/slab.h:954 [inline] kzalloc_noprof include/linux/slab.h:1188 [inline] tomoyo_encode2 security/tomoyo/realpath.c:45 [inline] tomoyo_encode+0x28b/0x550 security/tomoyo/realpath.c:80 tomoyo_realpath_from_path+0x58d/0x5d0 security/tomoyo/realpath.c:283 tomoyo_get_realpath security/tomoyo/file.c:151 [inline] tomoyo_check_open_permission+0x229/0x470 security/tomoyo/file.c:776 security_file_open+0xa9/0x240 security/security.c:2739 do_dentry_open+0x4a8/0x13a0 fs/open.c:924 vfs_open+0x3b/0x340 fs/open.c:1079 do_open fs/namei.c:4699 [inline] path_openat+0x2e08/0x3860 fs/namei.c:4858 do_file_open+0x23e/0x4a0 fs/namei.c:4887 do_sys_openat2+0x113/0x200 fs/open.c:1364 do_sys_open fs/open.c:1370 [inline] __do_sys_openat fs/open.c:1386 [inline] __se_sys_openat fs/open.c:1381 [inline] __x64_sys_openat+0x138/0x170 fs/open.c:1381 do_syscall_x64 arch/x86/entry/syscall_64.c:63 [inline] do_syscall_64+0x174/0x580 arch/x86/entry/syscall_64.c:94 entry_SYSCALL_64_after_hwframe+0x77/0x7f Freed by task 7771: kasan_save_stack mm/kasan/common.c:57 [inline] kasan_save_track+0x3e/0x80 mm/kasan/common.c:78 kasan_save_free_info+0x46/0x50 mm/kasan/generic.c:584 poison_slab_object mm/kasan/common.c:253 [inline] __kasan_slab_free+0x5c/0x80 mm/kasan/common.c:285 kasan_slab_free include/linux/kasan.h:235 [inline] slab_free_hook mm/slub.c:2689 [inline] slab_free mm/slub.c:6251 [inline] kfree+0x1c5/0x640 mm/slub.c:6566 tomoyo_check_open_permission+0x32c/0x470 security/tomoyo/file.c:791 security_file_open+0xa9/0x240 security/security.c:2739 do_dentry_open+0x4a8/0x13a0 fs/open.c:924 vfs_open+0x3b/0x340 fs/open.c:1079 do_open fs/namei.c:4699 [inline] path_openat+0x2e08/0x3860 fs/namei.c:4858 do_file_open+0x23e/0x4a0 fs/namei.c:4887 do_sys_openat2+0x113/0x200 fs/open.c:1364 do_sys_open fs/open.c:1370 [inline] __do_sys_openat fs/open.c:1386 [inline] __se_sys_openat fs/open.c:1381 [inline] __x64_sys_openat+0x138/0x170 fs/open.c:1381 do_syscall_x64 arch/x86/entry/syscall_64.c:63 [inline] do_syscall_64+0x174/0x580 arch/x86/entry/syscall_64.c:94 entry_SYSCALL_64_after_hwframe+0x77/0x7f The buggy address belongs to the object at ffff888029c98180 which belongs to the cache kmalloc-64 of size 64 The buggy address is located 0 bytes inside of 64-byte region [ffff888029c98180, ffff888029c981c0) The buggy address belongs to the physical page: page: refcount:0 mapcount:0 mapping:0000000000000000 index:0x0 pfn:0x29c98 flags: 0xfff00000000000(node=0|zone=1|lastcpupid=0x7ff) page_type: f5(slab) raw: 00fff00000000000 ffff88813fe198c0 dead000000000100 dead000000000122 raw: 0000000000000000 0000000800200020 00000000f5000000 0000000000000000 page dumped because: kasan: bad access detected page_owner tracks the page as allocated page last allocated via order 0, migratetype Unmovable, gfp_mask 0xd2cc0(GFP_KERNEL|__GFP_NOWARN|__GFP_NORETRY|__GFP_COMP|__GFP_NOMEMALLOC), pid 1177, tgid 1177 (kworker/u8:8), ts 12265340009, free_ts 11115557125 set_page_owner include/linux/page_owner.h:32 [inline] post_alloc_hook+0x22d/0x280 mm/page_alloc.c:1853 prep_new_page mm/page_alloc.c:1861 [inline] get_page_from_freelist+0x2593/0x2610 mm/page_alloc.c:3941 __alloc_frozen_pages_noprof+0x18d/0x380 mm/page_alloc.c:5221 alloc_slab_page mm/slub.c:3278 [inline] allocate_slab+0x77/0x660 mm/slub.c:3467 new_slab mm/slub.c:3525 [inline] refill_objects+0x339/0x3d0 mm/slub.c:7272 refill_sheaf mm/slub.c:2816 [inline] __pcs_replace_empty_main+0x321/0x720 mm/slub.c:4652 alloc_from_pcs mm/slub.c:4750 [inline] slab_alloc_node mm/slub.c:4884 [inline] __do_kmalloc_node mm/slub.c:5295 [inline] __kmalloc_noprof+0x474/0x760 mm/slub.c:5308 kmalloc_noprof include/linux/slab.h:954 [inline] kzalloc_noprof include/linux/slab.h:1188 [inline] lsm_blob_alloc security/security.c:218 [inline] lsm_task_alloc security/security.c:270 [inline] security_task_alloc+0x4d/0x330 security/security.c:2785 copy_process+0x1d12/0x4440 kernel/fork.c:2246 kernel_clone+0x2d7/0x940 kernel/fork.c:2722 user_mode_thread+0x110/0x180 kernel/fork.c:2798 call_usermodehelper_exec_work+0x5c/0x230 kernel/umh.c:171 process_one_work kernel/workqueue.c:3314 [inline] process_scheduled_works+0xb5d/0x1860 kernel/workqueue.c:3397 worker_thread+0xa53/0xfc0 kernel/workqueue.c:3478 kthread+0x389/0x470 kernel/kthread.c:436 ret_from_fork+0x514/0xb70 arch/x86/kernel/process.c:158 page last free pid 808 tgid 808 stack trace: reset_page_owner include/linux/page_owner.h:25 [inline] __free_pages_prepare mm/page_alloc.c:1397 [inline] __free_frozen_pages+0xc1c/0xd30 mm/page_alloc.c:2938 vfree+0x1d1/0x2f0 mm/vmalloc.c:3472 delayed_vfree_work+0x55/0x80 mm/vmalloc.c:3392 process_one_work kernel/workqueue.c:3314 [inline] process_scheduled_works+0xb5d/0x1860 kernel/workqueue.c:3397 worker_thread+0xa53/0xfc0 kernel/workqueue.c:3478 kthread+0x389/0x470 kernel/kthread.c:436 ret_from_fork+0x514/0xb70 arch/x86/kernel/process.c:158 ret_from_fork_asm+0x1a/0x30 arch/x86/entry/entry_64.S:245 Memory state around the buggy address: ffff888029c98080: fa fb fb fb fb fb fb fb fc fc fc fc fc fc fc fc ffff888029c98100: fa fb fb fb fb fb fb fb fc fc fc fc fc fc fc fc >ffff888029c98180: fa fb fb fb fb fb fb fb fc fc fc fc fc fc fc fc ^ ffff888029c98200: fa fb fb fb fb fb fb fb fc fc fc fc fc fc fc fc ffff888029c98280: fa fb fb fb fb fb fb fb fc fc fc fc fc fc fc fc ================================================================== ---------------- Code disassembly (best guess): 0: 22 8e 48 89 de e8 and -0x172176b8(%rsi),%cl 6: 90 nop 7: 9b fwait 8: f6 fe idiv %dh a: 31 ed xor %ebp,%ebp c: eb cf jmp 0xffffffdd e: cc int3 f: cc int3 10: cc int3 11: cc int3 12: cc int3 13: cc int3 14: cc int3 15: cc int3 16: cc int3 17: cc int3 18: cc int3 19: cc int3 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: 89 f6 mov %esi,%esi 30: 48 8b 0c 24 mov (%rsp),%rcx 34: 31 d2 xor %edx,%edx 36: e9 8f e5 ff ff jmp 0xffffe5ca 3b: 66 data16 3c: 66 data16 3d: 66 data16 3e: 66 data16 3f: 66 data16