==================================================================
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 ffffc9000754fa58 by task syz.2.684/7499
CPU: 0 UID: 0 PID: 7499 Comm: syz.2.684 Not tainted 6.11.0-rc1-syzkaller #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
instr_sysvec_apic_timer_interrupt arch/x86/kernel/apic/apic.c:1043 [inline]
sysvec_apic_timer_interrupt+0x95/0xb0 arch/x86/kernel/apic/apic.c:1043
asm_sysvec_apic_timer_interrupt+0x1a/0x20 arch/x86/include/asm/idtentry.h:702
RIP: 0010:finish_task_switch.isra.0+0x220/0xcc0 kernel/sched/core.c:5062
Code: a9 0a 00 00 44 8b 0d 87 4f b5 0e 45 85 c9 0f 85 c0 01 00 00 48 89 df e8 ae f8 ff ff e8 49 8c 36 00 fb 65 48 8b 1d 30 fb a7 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:ffffc9000754f8e0 EFLAGS: 00000206
RAX: 00000000000001eb RBX: ffff88801d344880 RCX: 1ffffffff2021749
RDX: 0000000000000000 RSI: ffffffff8b4ccfc0 RDI: ffffffff8bb04ba0
RBP: ffffc9000754f928 R08: 0000000000000001 R09: 0000000000000001
R10: ffffffff9010fe9f R11: 0000000000000000 R12: ffff88802c03fb98
R13: ffff888023c60000 R14: 0000000000000000 R15: ffff88802c03ee00
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
futex_wait_queue+0xfc/0x1f0 kernel/futex/waitwake.c:370
__futex_wait+0x291/0x3c0 kernel/futex/waitwake.c:669
futex_wait+0xe9/0x380 kernel/futex/waitwake.c:697
do_futex+0x22b/0x350 kernel/futex/syscalls.c:102
__do_sys_futex_time32 kernel/futex/syscalls.c:509 [inline]
__se_sys_futex_time32 kernel/futex/syscalls.c:492 [inline]
__ia32_sys_futex_time32+0x1da/0x460 kernel/futex/syscalls.c:492
do_syscall_32_irqs_on arch/x86/entry/common.c:165 [inline]
__do_fast_syscall_32+0x73/0x120 arch/x86/entry/common.c:386
do_fast_syscall_32+0x32/0x80 arch/x86/entry/common.c:411
entry_SYSENTER_compat_after_hwframe+0x84/0x8e
RIP: 0023:0xf73de579
Code: b8 01 10 06 03 74 b4 01 10 07 03 74 b0 01 10 08 03 74 d8 01 00 00 00 00 00 00 00 00 00 00 00 00 00 51 52 55 89 e5 0f 34 cd 80 <5d> 5a 59 c3 90 90 90 90 8d b4 26 00 00 00 00 8d b4 26 00 00 00 00
RSP: 002b:00000000f56f661c EFLAGS: 00000292 ORIG_RAX: 00000000000000f0
RAX: ffffffffffffffda RBX: 00000000f7404f88 RCX: 0000000000000080
RDX: 0000000000000000 RSI: 0000000000000000 RDI: 00000000f7404f8c
RBP: 0000000000000081 R08: 0000000000000000 R09: 0000000000000000
R10: 0000000000000000 R11: 0000000000000246 R12: 0000000000000000
R13: 0000000000000000 R14: 0000000000000000 R15: 0000000000000000
The buggy address belongs to stack of task syz.2.684/7499
and is located at offset 120 in frame:
__schedule+0x0/0x5490
This frame has 3 objects:
[48, 52) 'cid'
[64, 80) 'rf'
[96, 120) 'ac'
The buggy address belongs to the virtual mapping at
[ffffc90007548000, ffffc90007551000) 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:0xffff88805f644f80 pfn:0x5f644
memcg:ffff88801e7c1382
flags: 0x4fff00000000000(node=1|zone=1|lastcpupid=0x7ff)
raw: 04fff00000000000 0000000000000000 dead000000000122 0000000000000000
raw: ffff88805f644f80 0000000000000000 00000001ffffffff ffff88801e7c1382
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 7486, tgid 7486 (syz.2.680), ts 193900280106, free_ts 193059794256
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+0x29f5/0x6f50 kernel/fork.c:2204
kernel_clone+0xfd/0x980 kernel/fork.c:2781
__do_sys_clone3+0x1f5/0x270 kernel/fork.c:3085
do_syscall_32_irqs_on arch/x86/entry/common.c:165 [inline]
do_int80_emulation+0x104/0x200 arch/x86/entry/common.c:253
asm_int80_emulation+0x1a/0x20 arch/x86/include/asm/idtentry.h:626
page last free pid 4822 tgid 4822 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]
__do_kmalloc_node mm/slub.c:4157 [inline]
__kmalloc_node_track_caller_noprof+0x1c1/0x440 mm/slub.c:4177
kmalloc_reserve+0xef/0x2c0 net/core/skbuff.c:605
__alloc_skb+0x164/0x380 net/core/skbuff.c:674
alloc_skb include/linux/skbuff.h:1320 [inline]
alloc_skb_with_frags+0xe4/0x710 net/core/skbuff.c:6526
sock_alloc_send_pskb+0x7f1/0x980 net/core/sock.c:2815
unix_dgram_sendmsg+0x46c/0x19b0 net/unix/af_unix.c:2030
sock_sendmsg_nosec net/socket.c:730 [inline]
__sock_sendmsg net/socket.c:745 [inline]
__sys_sendto+0x47f/0x4e0 net/socket.c:2204
__do_sys_sendto net/socket.c:2216 [inline]
__se_sys_sendto net/socket.c:2212 [inline]
__x64_sys_sendto+0xe0/0x1c0 net/socket.c:2212
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:
ffffc9000754f900: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
ffffc9000754f980: 00 00 00 00 00 00 00 00 00 00 00 00 f1 f1 f1 f1
>ffffc9000754fa00: f1 f1 04 f2 00 00 f2 f2 00 00 00 f3 f3 f3 f3 f3
^
ffffc9000754fa80: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
ffffc9000754fb00: 00 00 00 00 00 00 00 00 00 00 f1 f1 f1 f1 00 f2
==================================================================
----------------
Code disassembly (best guess):
0: a9 0a 00 00 44 test $0x4400000a,%eax
5: 8b 0d 87 4f b5 0e mov 0xeb54f87(%rip),%ecx # 0xeb54f92
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 49 8c 36 00 call 0x368c6a
21: fb sti
22: 65 48 8b 1d 30 fb a7 mov %gs:0x7ea7fb30(%rip),%rbx # 0x7ea7fb5a
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