syzbot


INFO: rcu detected stall in sys_perf_event_open (2)

Status: upstream: reported C repro on 2024/01/09 18:19
Bug presence: origin:lts-only
[Documentation on labels]
Reported-by: syzbot+47c987bb570dba7d2a87@syzkaller.appspotmail.com
First crash: 195d, last: 195d
Bug presence (2)
Date Name Commit Repro Result
2024/01/08 linux-5.15.y (ToT) 26c690eff0a5 C [report] INFO: rcu detected stall in sys_perf_event_open
2024/01/08 upstream (ToT) 0dd3ee311255 C Didn't crash
Similar bugs (8)
Kernel Title Repro Cause bisect Fix bisect Count Last Reported Patched Status
upstream INFO: rcu detected stall in sys_perf_event_open (3) perf 1 1656d 1656d 0/27 closed as invalid on 2020/01/08 05:23
upstream INFO: rcu detected stall in sys_perf_event_open (4) perf 1 1656d 1656d 0/27 closed as invalid on 2020/01/09 08:13
upstream INFO: rcu detected stall in sys_perf_event_open (2) perf 8 1691d 1692d 0/27 closed as invalid on 2019/12/04 14:14
linux-6.1 INFO: rcu detected stall in sys_perf_event_open 1 40d 40d 0/3 upstream: reported on 2024/06/11 01:45
linux-5.15 INFO: rcu detected stall in sys_perf_event_open 1 459d 459d 0/3 auto-obsoleted due to no activity on 2023/08/17 04:33
upstream INFO: rcu detected stall in sys_perf_event_open perf 1 2135d 2133d 0/27 auto-closed as invalid on 2019/03/14 17:19
android-5-15 BUG: soft lockup in sys_perf_event_open 1 76d 76d 0/2 premoderation: reported on 2024/05/06 07:00
upstream BUG: soft lockup in sys_perf_event_open kvm 1 51d 47d 0/27 moderation: reported on 2024/06/04 02:01
Fix bisection attempts (6)
Created Duration User Patch Repo Result
2024/07/05 00:12 17m fix candidate upstream error job log
2024/06/04 23:16 24m fix candidate upstream error job log
2024/04/26 11:53 17m fix candidate upstream error job log
2024/03/20 20:06 17m fix candidate upstream error job log
2024/02/11 13:55 17m fix candidate upstream error job log
2024/01/08 20:44 30m fix candidate upstream error job log

Sample crash report:
rcu: INFO: rcu_preempt detected stalls on CPUs/tasks:
rcu: 	0-...!: (1 ticks this GP) idle=231/1/0x4000000000000002 softirq=38742/38742 fqs=0 
	(detected by 1, t=10502 jiffies, g=48561, q=161)
Sending NMI from CPU 1 to CPUs 0:
NMI backtrace for cpu 0
CPU: 0 PID: 8470 Comm: syz-executor425 Not tainted 5.15.146-syzkaller #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 11/17/2023
RIP: 0010:perf_misc_flags+0x167/0x1b0 arch/x86/events/core.c:2975
Code: e8 0e 10 7f 00 bd 02 00 00 00 48 29 dd 49 81 c6 90 00 00 00 4c 89 f0 48 c1 e8 03 42 80 3c 38 00 74 08 4c 89 f7 e8 b9 be c8 00 <41> 8b 06 83 e0 08 48 c1 e0 0b 48 09 e8 5b 41 5e 41 5f 5d c3 e8 f0
RSP: 0018:ffffc900000073f8 EFLAGS: 00000046
RAX: 1ffff110173468bf RBX: 0000000000000001 RCX: ffff88807b92d940
RDX: 0000000000000101 RSI: 0000000000000000 RDI: 0000000000000000
RBP: 0000000000000001 R08: ffffffff81011e12 R09: fffffbfff1f79e19
R10: 0000000000000000 R11: dffffc0000000001 R12: ffffc900000075c0
R13: dffffc0000000000 R14: ffff8880b9a345f8 R15: dffffc0000000000
FS:  00005555574813c0(0000) GS:ffff8880b9a00000(0000) knlGS:0000000000000000
CS:  0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: 00005555574816c8 CR3: 000000001e17f000 CR4: 00000000003506f0
DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000
DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400
Call Trace:
 <NMI>
 </NMI>
 <IRQ>
 perf_prepare_sample+0x13a/0x1ce0 kernel/events/core.c:7537
 __perf_event_output kernel/events/core.c:7717 [inline]
 perf_event_output_forward+0x199/0x310 kernel/events/core.c:7737
 __perf_event_overflow+0x35d/0x530 kernel/events/core.c:9432
 perf_swevent_overflow kernel/events/core.c:9508 [inline]
 perf_swevent_event+0x4c5/0x550 kernel/events/core.c:9546
 perf_tp_event+0x363/0xc40 kernel/events/core.c:9964
 perf_trace_run_bpf_submit+0xf7/0x1d0 kernel/events/core.c:9938
 perf_trace_preemptirq_template+0x31d/0x430 include/trace/events/preemptirq.h:14
 trace_irq_enable_rcuidle+0x10e/0x190 include/trace/events/preemptirq.h:40
 trace_hardirqs_on+0x57/0x80 kernel/trace/trace_preemptirq.c:44
 asm_sysvec_irq_work+0x16/0x20 arch/x86/include/asm/idtentry.h:664
RIP: 0010:rcu_read_unlock_special+0x84/0x520 kernel/rcu/tree_plugin.h:671
Code: f1 f1 f1 00 f2 f2 f2 49 89 04 17 66 41 c7 44 17 09 f3 f3 41 c6 44 17 0b f3 65 44 8b 25 bd d0 96 7e 41 f7 c4 00 00 f0 00 74 45 <48> c7 44 24 20 0e 36 e0 45 4a c7 04 3a 00 00 00 00 66 42 c7 44 3a
RSP: 0018:ffffc90000007be0 EFLAGS: 00000206
RAX: a20979f8cdcef500 RBX: 1ffff92000000f84 RCX: ffffffff8162ee48
RDX: dffffc0000000000 RSI: ffffffff8a8b0f80 RDI: ffffffff8ad87e00
RBP: ffffc90000007cb8 R08: dffffc0000000000 R09: fffffbfff1f79e20
R10: 0000000000000000 R11: dffffc0000000001 R12: ffffffff8c923200
R13: ffff88807b92dd98 R14: ffffc90000007c20 R15: 1ffff92000000f80
 __rcu_read_unlock+0x92/0x100 kernel/rcu/tree_plugin.h:422
 rcu_read_unlock include/linux/rcupdate.h:728 [inline]
 rebalance_domains+0x93d/0xab0 kernel/sched/fair.c:10645
 __do_softirq+0x3b3/0x93a kernel/softirq.c:558
 invoke_softirq kernel/softirq.c:432 [inline]
 __irq_exit_rcu+0x155/0x240 kernel/softirq.c:637
 irq_exit_rcu+0x5/0x20 kernel/softirq.c:649
 sysvec_apic_timer_interrupt+0x91/0xb0 arch/x86/kernel/apic/apic.c:1096
 </IRQ>
 <TASK>
 asm_sysvec_apic_timer_interrupt+0x16/0x20 arch/x86/include/asm/idtentry.h:638
RIP: 0010:perf_trace_init+0xa7/0x2d0 kernel/trace/trace_event_perf.c:223
Code: eb 0f 84 78 01 00 00 49 c7 c6 20 cb 96 8c 48 8d 6b 40 48 89 e8 48 c1 e8 03 42 0f b6 04 28 84 c0 0f 85 17 01 00 00 48 63 6d 00 <4c> 89 ff 48 89 ee e8 1e ec f7 ff 49 39 ef 0f 85 a6 00 00 00 48 8d
RSP: 0018:ffffc9000469fb88 EFLAGS: 00000246
RAX: 0000000000000000 RBX: ffffffff8d8c8800 RCX: ffff88807b92d940
RDX: 0000000000000000 RSI: 0000000000000a0f RDI: 0000000000000116
RBP: 0000000000000a0e R08: ffffffff81884002 R09: fffff520008d3f31
R10: 0000000000000000 R11: dffffc0000000001 R12: ffffffff8c9a6a40
R13: dffffc0000000000 R14: ffffffff8c96cb20 R15: 0000000000000116
 perf_tp_event_init+0x89/0x110 kernel/events/core.c:10019
 perf_try_init_event+0x135/0x3e0 kernel/events/core.c:11481
 perf_init_event kernel/events/core.c:11545 [inline]
 perf_event_alloc+0x1150/0x2150 kernel/events/core.c:11836
 __do_sys_perf_event_open kernel/events/core.c:12374 [inline]
 __se_sys_perf_event_open+0x7e2/0x4510 kernel/events/core.c:12266
 do_syscall_x64 arch/x86/entry/common.c:50 [inline]
 do_syscall_64+0x3d/0xb0 arch/x86/entry/common.c:80
 entry_SYSCALL_64_after_hwframe+0x61/0xcb
RIP: 0033:0x7f042929cd29
Code: 28 00 00 00 75 05 48 83 c4 28 c3 e8 c1 1f 00 00 90 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 b0 ff ff ff f7 d8 64 89 01 48
RSP: 002b:00007ffd78eb08d8 EFLAGS: 00000246 ORIG_RAX: 000000000000012a
RAX: ffffffffffffffda RBX: 000000000000000f RCX: 00007f042929cd29
RDX: 0000000000000000 RSI: ffffffffffffffff RDI: 00000000200003c0
RBP: 0000000000000000 R08: 0000000000000000 R09: 00007ffd78eb0400
R10: 00000000ffffffff R11: 0000000000000246 R12: 0000000000000000
R13: 0000000000000000 R14: 0000000000000000 R15: 0000000000000000
 </TASK>
rcu: rcu_preempt kthread timer wakeup didn't happen for 10501 jiffies! g48561 f0x0 RCU_GP_WAIT_FQS(5) ->state=0x402
rcu: 	Possible timer handling issue on cpu=0 timer-softirq=14206
rcu: rcu_preempt kthread starved for 10502 jiffies! g48561 f0x0 RCU_GP_WAIT_FQS(5) ->state=0x402 ->cpu=0
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:I stack:26200 pid:   15 ppid:     2 flags:0x00004000
Call Trace:
 <TASK>
 context_switch kernel/sched/core.c:5030 [inline]
 __schedule+0x12c4/0x45b0 kernel/sched/core.c:6376
 schedule+0x11b/0x1f0 kernel/sched/core.c:6459
 schedule_timeout+0x1b9/0x300 kernel/time/timer.c:1884
 rcu_gp_fqs_loop+0x2bf/0x1080 kernel/rcu/tree.c:1972
 rcu_gp_kthread+0xa4/0x360 kernel/rcu/tree.c:2145
 kthread+0x3f6/0x4f0 kernel/kthread.c:319
 ret_from_fork+0x1f/0x30 arch/x86/entry/entry_64.S:298
 </TASK>
rcu: Stack dump where RCU GP kthread last ran:
Sending NMI from CPU 1 to CPUs 0:
NMI backtrace for cpu 0
CPU: 0 PID: 8470 Comm: syz-executor425 Not tainted 5.15.146-syzkaller #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 11/17/2023
RIP: 0010:native_save_fl arch/x86/include/asm/irqflags.h:35 [inline]
RIP: 0010:arch_local_save_flags arch/x86/include/asm/irqflags.h:70 [inline]
RIP: 0010:lockdep_hardirqs_on_prepare+0x110/0x7a0 kernel/locking/lockdep.c:4259
Code: 80 3c 13 00 74 12 4c 89 f7 e8 ac 93 67 00 48 ba 00 00 00 00 00 fc ff df 48 c7 44 24 40 00 00 00 00 9c 8f 44 24 40 80 3c 13 00 <74> 12 4c 89 f7 e8 06 93 67 00 48 ba 00 00 00 00 00 fc ff df f6 44
RSP: 0018:ffffc90000007a60 EFLAGS: 00000046
RAX: 0000000000000004 RBX: 1ffff92000000f54 RCX: ffffffff913c6f03
RDX: dffffc0000000000 RSI: 0000000000000000 RDI: 0000000000000000
RBP: ffffc90000007b18 R08: ffffffff8186a728 R09: ffffed10173474da
R10: 0000000000000000 R11: dffffc0000000001 R12: 0000000000000000
R13: 0000000000000000 R14: ffffc90000007aa0 R15: 1ffff92000000f50
FS:  00005555574813c0(0000) GS:ffff8880b9a00000(0000) knlGS:0000000000000000
CS:  0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: 00005555574816c8 CR3: 000000001e17f000 CR4: 00000000003506f0
DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000
DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400
Call Trace:
 <NMI>
 </NMI>
 <IRQ>
 trace_hardirqs_on+0x67/0x80 kernel/trace/trace_preemptirq.c:49
 asm_sysvec_irq_work+0x16/0x20 arch/x86/include/asm/idtentry.h:664
RIP: 0010:rcu_read_unlock_special+0x84/0x520 kernel/rcu/tree_plugin.h:671
Code: f1 f1 f1 00 f2 f2 f2 49 89 04 17 66 41 c7 44 17 09 f3 f3 41 c6 44 17 0b f3 65 44 8b 25 bd d0 96 7e 41 f7 c4 00 00 f0 00 74 45 <48> c7 44 24 20 0e 36 e0 45 4a c7 04 3a 00 00 00 00 66 42 c7 44 3a
RSP: 0018:ffffc90000007be0 EFLAGS: 00000206
RAX: a20979f8cdcef500 RBX: 1ffff92000000f84 RCX: ffffffff8162ee48
RDX: dffffc0000000000 RSI: ffffffff8a8b0f80 RDI: ffffffff8ad87e00
RBP: ffffc90000007cb8 R08: dffffc0000000000 R09: fffffbfff1f79e20
R10: 0000000000000000 R11: dffffc0000000001 R12: ffffffff8c923200
R13: ffff88807b92dd98 R14: ffffc90000007c20 R15: 1ffff92000000f80
 __rcu_read_unlock+0x92/0x100 kernel/rcu/tree_plugin.h:422
 rcu_read_unlock include/linux/rcupdate.h:728 [inline]
 rebalance_domains+0x93d/0xab0 kernel/sched/fair.c:10645
 __do_softirq+0x3b3/0x93a kernel/softirq.c:558
 invoke_softirq kernel/softirq.c:432 [inline]
 __irq_exit_rcu+0x155/0x240 kernel/softirq.c:637
 irq_exit_rcu+0x5/0x20 kernel/softirq.c:649
 sysvec_apic_timer_interrupt+0x91/0xb0 arch/x86/kernel/apic/apic.c:1096
 </IRQ>
 <TASK>
 asm_sysvec_apic_timer_interrupt+0x16/0x20 arch/x86/include/asm/idtentry.h:638
RIP: 0010:perf_trace_init+0xa7/0x2d0 kernel/trace/trace_event_perf.c:223
Code: eb 0f 84 78 01 00 00 49 c7 c6 20 cb 96 8c 48 8d 6b 40 48 89 e8 48 c1 e8 03 42 0f b6 04 28 84 c0 0f 85 17 01 00 00 48 63 6d 00 <4c> 89 ff 48 89 ee e8 1e ec f7 ff 49 39 ef 0f 85 a6 00 00 00 48 8d
RSP: 0018:ffffc9000469fb88 EFLAGS: 00000246
RAX: 0000000000000000 RBX: ffffffff8d8c8800 RCX: ffff88807b92d940
RDX: 0000000000000000 RSI: 0000000000000a0f RDI: 0000000000000116
RBP: 0000000000000a0e R08: ffffffff81884002 R09: fffff520008d3f31
R10: 0000000000000000 R11: dffffc0000000001 R12: ffffffff8c9a6a40
R13: dffffc0000000000 R14: ffffffff8c96cb20 R15: 0000000000000116
 perf_tp_event_init+0x89/0x110 kernel/events/core.c:10019
 perf_try_init_event+0x135/0x3e0 kernel/events/core.c:11481
 perf_init_event kernel/events/core.c:11545 [inline]
 perf_event_alloc+0x1150/0x2150 kernel/events/core.c:11836
 __do_sys_perf_event_open kernel/events/core.c:12374 [inline]
 __se_sys_perf_event_open+0x7e2/0x4510 kernel/events/core.c:12266
 do_syscall_x64 arch/x86/entry/common.c:50 [inline]
 do_syscall_64+0x3d/0xb0 arch/x86/entry/common.c:80
 entry_SYSCALL_64_after_hwframe+0x61/0xcb
RIP: 0033:0x7f042929cd29
Code: 28 00 00 00 75 05 48 83 c4 28 c3 e8 c1 1f 00 00 90 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 b0 ff ff ff f7 d8 64 89 01 48
RSP: 002b:00007ffd78eb08d8 EFLAGS: 00000246 ORIG_RAX: 000000000000012a
RAX: ffffffffffffffda RBX: 000000000000000f RCX: 00007f042929cd29
RDX: 0000000000000000 RSI: ffffffffffffffff RDI: 00000000200003c0
RBP: 0000000000000000 R08: 0000000000000000 R09: 00007ffd78eb0400
R10: 00000000ffffffff R11: 0000000000000246 R12: 0000000000000000
R13: 0000000000000000 R14: 0000000000000000 R15: 0000000000000000
 </TASK>

Crashes (1):
Time Kernel Commit Syzkaller Config Log Report Syz repro C repro VM info Assets (help?) Manager Title
2024/01/08 10:50 linux-5.15.y 26c690eff0a5 d0304e9c .config console log report syz C [disk image] [vmlinux] [kernel image] ci2-linux-5-15-kasan-perf INFO: rcu detected stall in sys_perf_event_open
* Struck through repros no longer work on HEAD.