syzbot


INFO: rcu detected stall in packet_setsockopt

Status: upstream: reported on 2025/07/01 04:48
Reported-by: syzbot+144e0c1fe3033d898285@syzkaller.appspotmail.com
First crash: 19d, last: 19d

Sample crash report:
rcu: INFO: rcu_preempt detected stalls on CPUs/tasks:
rcu: 	Tasks blocked on level-0 rcu_node (CPUs 0-1): P6934/1:b..l P4762/1:b..l
	(detected by 0, t=10502 jiffies, g=28329, q=1067 ncpus=2)
task:kworker/u4:10   state:R  running task     stack:25352 pid:4762  ppid:2      flags:0x00004000
Workqueue: bat_events batadv_iv_send_outstanding_bat_ogm_packet
Call Trace:
 <TASK>
 context_switch kernel/sched/core.c:5244 [inline]
 __schedule+0x10e9/0x40d0 kernel/sched/core.c:6561
 preempt_schedule_common+0x82/0xd0 kernel/sched/core.c:6730
 preempt_schedule+0xa7/0xb0 kernel/sched/core.c:6754
 preempt_schedule_thunk+0x16/0x18 arch/x86/entry/thunk_64.S:34
 __local_bh_enable_ip+0x13b/0x1b0 kernel/softirq.c:428
 batadv_iv_ogm_schedule_buff net/batman-adv/bat_iv_ogm.c:849 [inline]
 batadv_iv_ogm_schedule+0xaaf/0xe90 net/batman-adv/bat_iv_ogm.c:868
 batadv_iv_send_outstanding_bat_ogm_packet+0x72d/0x840 net/batman-adv/bat_iv_ogm.c:1712
 process_one_work+0x898/0x1160 kernel/workqueue.c:2292
 worker_thread+0xaa2/0x1250 kernel/workqueue.c:2439
 kthread+0x29d/0x330 kernel/kthread.c:376
 ret_from_fork+0x1f/0x30 arch/x86/entry/entry_64.S:295
 </TASK>
task:syz.0.754       state:R  running task     stack:26176 pid:6934  ppid:4260   flags:0x00004004
Call Trace:
 <TASK>
 context_switch kernel/sched/core.c:5244 [inline]
 __schedule+0x10e9/0x40d0 kernel/sched/core.c:6561
 preempt_schedule_irq+0xb1/0x150 kernel/sched/core.c:6873
 irqentry_exit+0x63/0x70 kernel/entry/common.c:439
 asm_sysvec_apic_timer_interrupt+0x16/0x20 arch/x86/include/asm/idtentry.h:691
RIP: 0010:__nr_to_section include/linux/mmzone.h:1695 [inline]
RIP: 0010:__pfn_to_section include/linux/mmzone.h:1803 [inline]
RIP: 0010:lookup_page_ext mm/page_ext.c:274 [inline]
RIP: 0010:page_ext_get+0x133/0x2a0 mm/page_ext.c:158
Code: a1 96 e8 f0 e4 f5 ff 48 8b 05 19 35 c5 14 48 85 c0 74 42 4c 89 f1 48 c1 e9 16 4c 8d 3c c8 4c 89 f8 48 c1 e8 03 42 80 3c 20 00 <74> 08 4c 89 ff e8 c3 e4 f5 ff 4d 8b 3f 4d 85 ff 74 20 4d 89 f5 49
RSP: 0018:ffffc90002ff77b8 EFLAGS: 00000246
RAX: 1ffff11047ffde00 RBX: ffffffff81dc6d4e RCX: 0000000000000000
RDX: 0000000000000002 RSI: 0000000000050a5e RDI: 00000003ffffffff
RBP: 0000000000000001 R08: dffffc0000000000 R09: fffffbfff2117249
R10: fffffbfff2117249 R11: 1ffffffff2117248 R12: dffffc0000000000
R13: 0000000000000000 R14: 0000000000050a5e R15: ffff88823ffef000
 __page_table_check_zero+0x134/0x4b0 mm/page_table_check.c:146
 page_table_check_free include/linux/page_table_check.h:46 [inline]
 free_pages_prepare mm/page_alloc.c:1460 [inline]
 free_pcp_prepare mm/page_alloc.c:1509 [inline]
 free_unref_page_prepare+0x8c4/0x9a0 mm/page_alloc.c:3384
 free_unref_page+0x2e/0x3f0 mm/page_alloc.c:3479
 __vunmap+0x856/0xa00 mm/vmalloc.c:2718
 free_pg_vec+0x9e/0x120 net/packet/af_packet.c:4373
 alloc_pg_vec net/packet/af_packet.c:4428 [inline]
 packet_set_ring+0x1a00/0x2400 net/packet/af_packet.c:4504
 packet_setsockopt+0xcd9/0x1140 net/packet/af_packet.c:3884
 __sys_setsockopt+0x3d6/0x660 net/socket.c:2288
 __do_sys_setsockopt net/socket.c:2299 [inline]
 __se_sys_setsockopt net/socket.c:2296 [inline]
 __x64_sys_setsockopt+0xb1/0xc0 net/socket.c:2296
 do_syscall_x64 arch/x86/entry/common.c:51 [inline]
 do_syscall_64+0x4c/0xa0 arch/x86/entry/common.c:81
 entry_SYSCALL_64_after_hwframe+0x68/0xd2
RIP: 0033:0x7f111058e929
RSP: 002b:00007f11114bb038 EFLAGS: 00000246 ORIG_RAX: 0000000000000036
RAX: ffffffffffffffda RBX: 00007f11107b5fa0 RCX: 00007f111058e929
RDX: 0000000000000005 RSI: 0000000000000107 RDI: 0000000000000003
RBP: 00007f1110610b39 R08: 000000000000001c R09: 0000000000000000
R10: 00002000000000c0 R11: 0000000000000246 R12: 0000000000000000
R13: 0000000000000000 R14: 00007f11107b5fa0 R15: 00007ffe749267e8
 </TASK>
rcu: rcu_preempt kthread starved for 9813 jiffies! g28329 f0x0 RCU_GP_WAIT_FQS(5) ->state=0x0 ->cpu=1
rcu: 	Unless rcu_preempt kthread gets sufficient CPU time, OOM is now expected behavior.
rcu: RCU grace-period kthread stack dump:
task:rcu_preempt     state:R  running task     stack:26912 pid:16    ppid:2      flags:0x00004000
Call Trace:
 <TASK>
 context_switch kernel/sched/core.c:5244 [inline]
 __schedule+0x10e9/0x40d0 kernel/sched/core.c:6561
 schedule+0xb9/0x180 kernel/sched/core.c:6637
 schedule_timeout+0x15c/0x280 kernel/time/timer.c:1965
 rcu_gp_fqs_loop+0x2f2/0x1310 kernel/rcu/tree.c:1706
 rcu_gp_kthread+0x95/0x380 kernel/rcu/tree.c:1905
 kthread+0x29d/0x330 kernel/kthread.c:376
 ret_from_fork+0x1f/0x30 arch/x86/entry/entry_64.S:295
 </TASK>
rcu: Stack dump where RCU GP kthread last ran:
Sending NMI from CPU 0 to CPUs 1:
NMI backtrace for cpu 1 skipped: idling at native_safe_halt arch/x86/include/asm/irqflags.h:51 [inline]
NMI backtrace for cpu 1 skipped: idling at arch_safe_halt arch/x86/include/asm/irqflags.h:89 [inline]
NMI backtrace for cpu 1 skipped: idling at default_idle+0xb/0x10 arch/x86/kernel/process.c:741

Crashes (1):
Time Kernel Commit Syzkaller Config Log Report Syz repro C repro VM info Assets (help?) Manager Title
2025/07/01 04:47 linux-6.1.y 7e69c33e4858 6e83b42d .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-6-1-kasan INFO: rcu detected stall in packet_setsockopt
* Struck through repros no longer work on HEAD.