syzbot


KASAN: stack-out-of-bounds Read in dev_deactivate_many

Status: auto-obsoleted due to no activity on 2025/01/13 04:11
Subsystems: net
[Documentation on labels]
First crash: 105d, last: 105d

Sample crash report:
bridge0: port 2(bridge_slave_1) entered disabled state
bridge_slave_0: left allmulticast mode
bridge_slave_0: left promiscuous mode
bridge0: port 1(bridge_slave_0) entered disabled state
==================================================================
BUG: KASAN: stack-out-of-bounds in dev_ingress_queue include/linux/rtnetlink.h:100 [inline]
BUG: KASAN: stack-out-of-bounds in dev_deactivate_many+0x1b1/0xb10 net/sched/sch_generic.c:1359
Read of size 8 at addr ffffc900015c7a30 by task kworker/u8:8/3002

CPU: 0 UID: 0 PID: 3002 Comm: kworker/u8:8 Not tainted 6.12.0-rc1-syzkaller-00381-g2a130b7e1fcd #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 09/13/2024
Workqueue: netns cleanup_net
Call Trace:
 <TASK>
 __dump_stack lib/dump_stack.c:94 [inline]
 dump_stack_lvl+0x241/0x360 lib/dump_stack.c:120
 print_address_description mm/kasan/report.c:377 [inline]
 print_report+0x169/0x550 mm/kasan/report.c:488
 kasan_report+0x143/0x180 mm/kasan/report.c:601
 dev_ingress_queue include/linux/rtnetlink.h:100 [inline]
 dev_deactivate_many+0x1b1/0xb10 net/sched/sch_generic.c:1359
 __dev_close_many+0x1a4/0x300 net/core/dev.c:1547
 dev_close_many+0x24e/0x4c0 net/core/dev.c:1585
 unregister_netdevice_many_notify+0x530/0x1da0 net/core/dev.c:11377
 cleanup_net+0x75d/0xcc0 net/core/net_namespace.c:621
 process_one_work kernel/workqueue.c:3229 [inline]
 process_scheduled_works+0xa63/0x1850 kernel/workqueue.c:3310
 worker_thread+0x870/0xd30 kernel/workqueue.c:3391
 kthread+0x2f0/0x390 kernel/kthread.c:389
 ret_from_fork+0x4b/0x80 arch/x86/kernel/process.c:147
 ret_from_fork_asm+0x1a/0x30 arch/x86/entry/entry_64.S:244
 </TASK>

The buggy address belongs to the virtual mapping at
 [ffffc900015c0000, ffffc900015c9000) created by:
 copy_process+0x5d1/0x3d50 kernel/fork.c:2203

The buggy address belongs to the physical page:
page: refcount:1 mapcount:0 mapping:0000000000000000 index:0x0 pfn:0x1cf22
flags: 0xfff00000000000(node=0|zone=1|lastcpupid=0x7ff)
raw: 00fff00000000000 0000000000000000 dead000000000122 0000000000000000
raw: 0000000000000000 0000000000000000 00000001ffffffff 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 0x2dc2(GFP_KERNEL|__GFP_HIGHMEM|__GFP_NOWARN|__GFP_ZERO), pid 2, tgid 2 (kthreadd), ts 3737243524, free_ts 0
 set_page_owner include/linux/page_owner.h:32 [inline]
 post_alloc_hook+0x1f3/0x230 mm/page_alloc.c:1537
 prep_new_page mm/page_alloc.c:1545 [inline]
 get_page_from_freelist+0x3045/0x3190 mm/page_alloc.c:3457
 __alloc_pages_noprof+0x256/0x6c0 mm/page_alloc.c:4733
 alloc_pages_mpol_noprof+0x3e8/0x680 mm/mempolicy.c:2265
 vm_area_alloc_pages mm/vmalloc.c:3568 [inline]
 __vmalloc_area_node mm/vmalloc.c:3646 [inline]
 __vmalloc_node_range_noprof+0xa2b/0x13f0 mm/vmalloc.c:3828
 alloc_thread_stack_node kernel/fork.c:314 [inline]
 dup_task_struct+0x444/0x8c0 kernel/fork.c:1115
 copy_process+0x5d1/0x3d50 kernel/fork.c:2203
 kernel_clone+0x226/0x8f0 kernel/fork.c:2784
 kernel_thread+0x1bc/0x240 kernel/fork.c:2846
 create_kthread kernel/kthread.c:412 [inline]
 kthreadd+0x60d/0x810 kernel/kthread.c:765
 ret_from_fork+0x4b/0x80 arch/x86/kernel/process.c:147
 ret_from_fork_asm+0x1a/0x30 arch/x86/entry/entry_64.S:244
page_owner free stack trace missing

Memory state around the buggy address:
 ffffc900015c7900: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
 ffffc900015c7980: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
>ffffc900015c7a00: f1 f1 f1 f1 01 f2 01 f2 01 f2 01 f2 01 f2 00 00
                                     ^
 ffffc900015c7a80: 00 00 00 00 00 00 00 00 00 00 00 f2 f2 f2 f2 f2
 ffffc900015c7b00: 00 f2 f2 f2 00 f2 f2 f2 00 f3 f3 f3 00 00 00 00
==================================================================

Crashes (1):
Time Kernel Commit Syzkaller Config Log Report Syz repro C repro VM info Assets (help?) Manager Title
2024/10/07 02:26 upstream 2a130b7e1fcd d7906eff .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-kasan-gce KASAN: stack-out-of-bounds Read in dev_deactivate_many
* Struck through repros no longer work on HEAD.