================================================================== BUG: KASAN: stack-out-of-bounds in list_empty include/linux/list.h:373 [inline] BUG: KASAN: stack-out-of-bounds in bpf_net_ctx_get_all_used_flush_lists include/linux/filter.h:846 [inline] BUG: KASAN: stack-out-of-bounds in xdp_do_check_flushed+0x429/0x4e0 net/core/filter.c:4305 Read of size 8 at addr ffffc9000320fa68 by task syz.1.3625/15936 CPU: 1 UID: 0 PID: 15936 Comm: syz.1.3625 Not tainted 6.11.0-rc1-syzkaller-00063-g21b136cc63d2 #0 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:93 [inline] dump_stack_lvl+0x116/0x1f0 lib/dump_stack.c:119 print_address_description mm/kasan/report.c:377 [inline] print_report+0xc3/0x620 mm/kasan/report.c:488 kasan_report+0xd9/0x110 mm/kasan/report.c:601 list_empty include/linux/list.h:373 [inline] bpf_net_ctx_get_all_used_flush_lists include/linux/filter.h:846 [inline] xdp_do_check_flushed+0x429/0x4e0 net/core/filter.c:4305 __napi_poll.constprop.0+0xd1/0x550 net/core/dev.c:6774 napi_poll net/core/dev.c:6840 [inline] net_rx_action+0xa92/0x1010 net/core/dev.c:6962 handle_softirqs+0x216/0x8f0 kernel/softirq.c:554 __do_softirq kernel/softirq.c:588 [inline] invoke_softirq kernel/softirq.c:428 [inline] __irq_exit_rcu kernel/softirq.c:637 [inline] irq_exit_rcu+0xbb/0x120 kernel/softirq.c:649 common_interrupt+0xb0/0xd0 arch/x86/kernel/irq.c:278 asm_common_interrupt+0x26/0x40 arch/x86/include/asm/idtentry.h:693 RIP: 0010:finish_task_switch.isra.0+0x220/0xcc0 kernel/sched/core.c:5062 Code: a9 0a 00 00 44 8b 0d 07 d6 b7 0e 45 85 c9 0f 85 c0 01 00 00 48 89 df e8 ae f8 ff ff e8 19 ba 36 00 fb 65 48 8b 1d 30 cf a8 7e <48> 8d bb f8 15 00 00 48 b8 00 00 00 00 00 fc ff df 48 89 fa 48 c1 RSP: 0018:ffffc9000320f718 EFLAGS: 00000202 RAX: 0000000000002707 RBX: ffff8880231d2440 RCX: 1ffffffff2024d91 RDX: 0000000000000000 RSI: ffffffff8b4cc580 RDI: ffffffff8bb08480 RBP: ffffc9000320f760 R08: 0000000000000001 R09: 0000000000000001 R10: ffffffff9012b0df R11: 0000000000000000 R12: ffff88806b13fb58 R13: ffff8880231d4880 R14: 0000000000000000 R15: ffff88806b03edc0 context_switch kernel/sched/core.c:5191 [inline] __schedule+0xe3f/0x5490 kernel/sched/core.c:6529 __schedule_loop kernel/sched/core.c:6606 [inline] schedule+0xe7/0x350 kernel/sched/core.c:6621 schedule_timeout+0x258/0x2a0 kernel/time/timer.c:2557 do_wait_for_common kernel/sched/completion.c:95 [inline] __wait_for_common+0x3de/0x5f0 kernel/sched/completion.c:116 rdmsr_safe_on_cpu+0x1de/0x210 arch/x86/lib/msr-smp.c:181 msr_read+0x1a4/0x250 arch/x86/kernel/msr.c:66 vfs_read+0x1d4/0xbd0 fs/read_write.c:474 ksys_read+0x12f/0x260 fs/read_write.c:619 do_syscall_x64 arch/x86/entry/common.c:52 [inline] do_syscall_64+0xcd/0x250 arch/x86/entry/common.c:83 entry_SYSCALL_64_after_hwframe+0x77/0x7f RIP: 0033:0x7f75095773b9 Code: ff ff c3 66 2e 0f 1f 84 00 00 00 00 00 0f 1f 40 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 a8 ff ff ff f7 d8 64 89 01 48 RSP: 002b:00007f750a337048 EFLAGS: 00000246 ORIG_RAX: 0000000000000000 RAX: ffffffffffffffda RBX: 00007f7509705f80 RCX: 00007f75095773b9 RDX: 0000000000018ff8 RSI: 0000000020019680 RDI: 000000000000000e RBP: 00007f75095e48e6 R08: 0000000000000000 R09: 0000000000000000 R10: 0000000000000000 R11: 0000000000000246 R12: 0000000000000000 R13: 000000000000000b R14: 00007f7509705f80 R15: 00007ffdab7080c8 The buggy address belongs to stack of task syz.1.3625/15936 and is located at offset 0 in frame: __wait_for_common+0x0/0x5f0 This frame has 1 object: [32, 56) 'wait' The buggy address belongs to the virtual mapping at [ffffc90003208000, ffffc90003211000) created by: kernel_clone+0xfd/0x980 kernel/fork.c:2781 The buggy address belongs to the physical page: page: refcount:1 mapcount:0 mapping:0000000000000000 index:0xffff888027898780 pfn:0x27898 memcg:ffff888046a05302 flags: 0xfff00000000000(node=0|zone=1|lastcpupid=0x7ff) raw: 00fff00000000000 0000000000000000 dead000000000122 0000000000000000 raw: ffff888027898780 0000000000000000 00000001ffffffff ffff888046a05302 page dumped because: kasan: bad access detected page_owner tracks the page as allocated page last allocated via order 0, migratetype Unmovable, gfp_mask 0x102dc2(GFP_HIGHUSER|__GFP_NOWARN|__GFP_ZERO), pid 9565, tgid 9565 (syz-executor), ts 872166597461, free_ts 867660944860 set_page_owner include/linux/page_owner.h:32 [inline] post_alloc_hook+0x2d1/0x350 mm/page_alloc.c:1493 prep_new_page mm/page_alloc.c:1501 [inline] get_page_from_freelist+0x1351/0x2e50 mm/page_alloc.c:3442 __alloc_pages_noprof+0x22b/0x2460 mm/page_alloc.c:4700 alloc_pages_mpol_noprof+0x275/0x610 mm/mempolicy.c:2263 vm_area_alloc_pages mm/vmalloc.c:3584 [inline] __vmalloc_area_node mm/vmalloc.c:3660 [inline] __vmalloc_node_range_noprof+0xa6a/0x1520 mm/vmalloc.c:3841 alloc_thread_stack_node kernel/fork.c:313 [inline] dup_task_struct kernel/fork.c:1113 [inline] copy_process+0x2f3b/0x8de0 kernel/fork.c:2204 kernel_clone+0xfd/0x980 kernel/fork.c:2781 __do_sys_clone+0xba/0x100 kernel/fork.c:2924 do_syscall_x64 arch/x86/entry/common.c:52 [inline] do_syscall_64+0xcd/0x250 arch/x86/entry/common.c:83 entry_SYSCALL_64_after_hwframe+0x77/0x7f page last free pid 11552 tgid 11552 stack trace: reset_page_owner include/linux/page_owner.h:25 [inline] free_pages_prepare mm/page_alloc.c:1094 [inline] free_unref_page+0x64a/0xe40 mm/page_alloc.c:2612 qlink_free mm/kasan/quarantine.c:163 [inline] qlist_free_all+0x4e/0x140 mm/kasan/quarantine.c:179 kasan_quarantine_reduce+0x192/0x1e0 mm/kasan/quarantine.c:286 __kasan_slab_alloc+0x69/0x90 mm/kasan/common.c:322 kasan_slab_alloc include/linux/kasan.h:201 [inline] slab_post_alloc_hook mm/slub.c:3988 [inline] slab_alloc_node mm/slub.c:4037 [inline] kmem_cache_alloc_noprof+0x121/0x2f0 mm/slub.c:4044 vma_lock_alloc kernel/fork.c:445 [inline] vm_area_dup+0x53/0x2f0 kernel/fork.c:498 dup_mmap kernel/fork.c:695 [inline] dup_mm kernel/fork.c:1672 [inline] copy_mm kernel/fork.c:1721 [inline] copy_process+0x7bd5/0x8de0 kernel/fork.c:2374 kernel_clone+0xfd/0x980 kernel/fork.c:2781 __do_sys_clone+0xba/0x100 kernel/fork.c:2924 do_syscall_x64 arch/x86/entry/common.c:52 [inline] do_syscall_64+0xcd/0x250 arch/x86/entry/common.c:83 entry_SYSCALL_64_after_hwframe+0x77/0x7f Memory state around the buggy address: ffffc9000320f900: 00 00 00 00 00 00 00 f1 f1 f1 f1 00 00 00 00 00 ffffc9000320f980: 00 00 00 00 00 00 f3 f3 f3 f3 f3 00 00 00 00 00 >ffffc9000320fa00: 00 00 00 00 00 00 00 00 00 00 00 00 00 f1 f1 f1 ^ ffffc9000320fa80: f1 00 00 00 f3 f3 f3 f3 f3 00 00 00 00 00 00 00 ffffc9000320fb00: 00 00 00 00 f1 f1 f1 f1 00 00 00 00 f2 f2 f2 f2 ================================================================== vkms_vblank_simulate: vblank timer overrun ---------------- Code disassembly (best guess): 0: a9 0a 00 00 44 test $0x4400000a,%eax 5: 8b 0d 07 d6 b7 0e mov 0xeb7d607(%rip),%ecx # 0xeb7d612 b: 45 85 c9 test %r9d,%r9d e: 0f 85 c0 01 00 00 jne 0x1d4 14: 48 89 df mov %rbx,%rdi 17: e8 ae f8 ff ff call 0xfffff8ca 1c: e8 19 ba 36 00 call 0x36ba3a 21: fb sti 22: 65 48 8b 1d 30 cf a8 mov %gs:0x7ea8cf30(%rip),%rbx # 0x7ea8cf5a 29: 7e * 2a: 48 8d bb f8 15 00 00 lea 0x15f8(%rbx),%rdi <-- trapping instruction 31: 48 b8 00 00 00 00 00 movabs $0xdffffc0000000000,%rax 38: fc ff df 3b: 48 89 fa mov %rdi,%rdx 3e: 48 rex.W 3f: c1 .byte 0xc1