syzbot


INFO: rcu detected stall in chrdev_open

Status: upstream: reported C repro on 2021/12/21 07:54
Reported-by: syzbot+929fa38ef7e406a27eb8@syzkaller.appspotmail.com
First crash: 280d, last: 174d

Fix bisection: failed (bisect log)
similar bugs (5):
Kernel Title Repro Cause bisect Fix bisect Count Last Reported Patched Status
linux-4.19 INFO: rcu detected stall in chrdev_open (2) 1 864d 864d 0/1 auto-closed as invalid on 2020/09/12 23:19
linux-4.19 INFO: rcu detected stall in chrdev_open (3) C error 16 173d 553d 0/1 upstream: reported C repro on 2021/03/22 19:09
linux-4.19 INFO: rcu detected stall in chrdev_open 1 998d 998d 0/1 auto-closed as invalid on 2020/05/02 02:53
upstream INFO: rcu detected stall in chrdev_open (2) C done inconclusive 55 252d 1019d 0/24 closed as invalid on 2022/02/08 10:45
upstream INFO: rcu detected stall in chrdev_open 4 1028d 1029d 0/24 closed as invalid on 2019/12/04 14:04

Sample crash report:
INFO: rcu_preempt detected stalls on CPUs/tasks:
	(detected by 0, t=10502 jiffies, g=1144, c=1143, q=65)
All QSes seen, last rcu_preempt kthread activity 10502 (4294994573-4294984071), jiffies_till_next_fqs=1, root ->qsmask 0x0
syz-executor271 R  running task    27976  8228   7974 0x00000000
Call Trace:
 <IRQ>
 sched_show_task.cold+0x333/0x39a kernel/sched/core.c:5168
 print_other_cpu_stall kernel/rcu/tree.c:1501 [inline]
 check_cpu_stall kernel/rcu/tree.c:1616 [inline]
 __rcu_pending kernel/rcu/tree.c:3390 [inline]
 rcu_pending kernel/rcu/tree.c:3452 [inline]
 rcu_check_callbacks.cold+0xd29/0xd8d kernel/rcu/tree.c:2792
 update_process_times+0x29/0x60 kernel/time/timer.c:1591
 tick_sched_handle+0x7d/0x150 kernel/time/tick-sched.c:165
 tick_sched_timer+0x92/0x200 kernel/time/tick-sched.c:1223
 __run_hrtimer kernel/time/hrtimer.c:1223 [inline]
 __hrtimer_run_queues+0x30b/0xc80 kernel/time/hrtimer.c:1287
 hrtimer_interrupt+0x1e6/0x5e0 kernel/time/hrtimer.c:1321
 local_apic_timer_interrupt arch/x86/kernel/apic/apic.c:1079 [inline]
 smp_apic_timer_interrupt+0x117/0x5e0 arch/x86/kernel/apic/apic.c:1104
 apic_timer_interrupt+0x93/0xa0 arch/x86/entry/entry_64.S:793
 </IRQ>
RIP: 0010:__mutex_unlock_slowpath+0x261/0x770 kernel/locking/mutex.c:1013
RSP: 0018:ffff8880aaa57928 EFLAGS: 00000246 ORIG_RAX: ffffffffffffff10
RAX: ffff88809df1c240 RBX: 0000000000000000 RCX: fffffbfff17d93a8
RDX: 0000000000000000 RSI: 0000000000000001 RDI: 0000000000000286
RBP: ffffffff89472920 R08: ffff88809df1c240 R09: dffffc0000000000
R10: 0000000000000000 R11: ffff88809df1c240 R12: ffffffff8bec9d40
R13: 1ffff1101554af29 R14: ffff8880aaa57968 R15: 0000000000000003
 tty_open_by_driver drivers/tty/tty_io.c:1958 [inline]
 tty_open+0x3d5/0x8b0 drivers/tty/tty_io.c:2021
 chrdev_open+0x23c/0x6d0 fs/char_dev.c:423
 do_dentry_open+0x44b/0xec0 fs/open.c:777
 vfs_open+0x105/0x220 fs/open.c:888
 do_last fs/namei.c:3428 [inline]
 path_openat+0x628/0x2970 fs/namei.c:3569
 do_filp_open+0x179/0x3c0 fs/namei.c:3603
 do_sys_open+0x296/0x410 fs/open.c:1081
 do_syscall_64+0x1d5/0x640 arch/x86/entry/common.c:292
 entry_SYSCALL_64_after_hwframe+0x46/0xbb
RIP: 0033:0x7f0578eadaf9
RSP: 002b:00007f0578e5f318 EFLAGS: 00000246 ORIG_RAX: 0000000000000101
RAX: ffffffffffffffda RBX: 00007f0578f353e8 RCX: 00007f0578eadaf9
RDX: 0000000000000802 RSI: 0000000020000840 RDI: ffffffffffffff9c
RBP: 00007f0578f353e0 R08: 0000000000000000 R09: 0000000000000000
R10: 0000000000000000 R11: 0000000000000246 R12: 7974742f7665642f
R13: 00007fffc41d99af R14: 00007f0578e5f400 R15: 0000000000022000
rcu_preempt kthread starved for 10502 jiffies! g1144 c1143 f0x2 RCU_GP_WAIT_FQS(3) ->state=0x0 ->cpu=0
rcu_preempt     R  running task    30008     8      2 0x80000000
Call Trace:
 context_switch kernel/sched/core.c:2811 [inline]
 __schedule+0x88b/0x1de0 kernel/sched/core.c:3387
 schedule+0x8d/0x1b0 kernel/sched/core.c:3431
 schedule_timeout+0x4af/0xe90 kernel/time/timer.c:1747
 rcu_gp_kthread+0xc0a/0x1e60 kernel/rcu/tree.c:2255
 kthread+0x30d/0x420 kernel/kthread.c:232
 ret_from_fork+0x24/0x30 arch/x86/entry/entry_64.S:404
INFO: rcu_sched detected stalls on CPUs/tasks:
	(detected by 0, t=10539 jiffies, g=297, c=296, q=5)
All QSes seen, last rcu_sched kthread activity 10539 (4294994611-4294984072), jiffies_till_next_fqs=1, root ->qsmask 0x0
syz-executor271 R  running task    27976  8228   7974 0x00000000
Call Trace:
 <IRQ>
 sched_show_task.cold+0x333/0x39a kernel/sched/core.c:5168
 print_other_cpu_stall kernel/rcu/tree.c:1501 [inline]
 check_cpu_stall kernel/rcu/tree.c:1616 [inline]
 __rcu_pending kernel/rcu/tree.c:3390 [inline]
 rcu_pending kernel/rcu/tree.c:3452 [inline]
 rcu_check_callbacks.cold+0xd29/0xd8d kernel/rcu/tree.c:2792
 update_process_times+0x29/0x60 kernel/time/timer.c:1591
 tick_sched_handle+0x7d/0x150 kernel/time/tick-sched.c:165
 tick_sched_timer+0x92/0x200 kernel/time/tick-sched.c:1223
 __run_hrtimer kernel/time/hrtimer.c:1223 [inline]
 __hrtimer_run_queues+0x30b/0xc80 kernel/time/hrtimer.c:1287
 hrtimer_interrupt+0x1e6/0x5e0 kernel/time/hrtimer.c:1321
 local_apic_timer_interrupt arch/x86/kernel/apic/apic.c:1079 [inline]
 smp_apic_timer_interrupt+0x117/0x5e0 arch/x86/kernel/apic/apic.c:1104
 apic_timer_interrupt+0x93/0xa0 arch/x86/entry/entry_64.S:793
 </IRQ>
RIP: 0010:__mutex_unlock_slowpath+0x261/0x770 kernel/locking/mutex.c:1013
RSP: 0018:ffff8880aaa57928 EFLAGS: 00000246 ORIG_RAX: ffffffffffffff10
RAX: ffff88809df1c240 RBX: 0000000000000000 RCX: fffffbfff17d93a8
RDX: 0000000000000000 RSI: 0000000000000001 RDI: 0000000000000286
RBP: ffffffff89472920 R08: ffff88809df1c240 R09: dffffc0000000000
R10: 0000000000000000 R11: ffff88809df1c240 R12: ffffffff8bec9d40
R13: 1ffff1101554af29 R14: ffff8880aaa57968 R15: 0000000000000003
 tty_open_by_driver drivers/tty/tty_io.c:1958 [inline]
 tty_open+0x3d5/0x8b0 drivers/tty/tty_io.c:2021
 chrdev_open+0x23c/0x6d0 fs/char_dev.c:423
 do_dentry_open+0x44b/0xec0 fs/open.c:777
 vfs_open+0x105/0x220 fs/open.c:888
 do_last fs/namei.c:3428 [inline]
 path_openat+0x628/0x2970 fs/namei.c:3569
 do_filp_open+0x179/0x3c0 fs/namei.c:3603
 do_sys_open+0x296/0x410 fs/open.c:1081
 do_syscall_64+0x1d5/0x640 arch/x86/entry/common.c:292
 entry_SYSCALL_64_after_hwframe+0x46/0xbb
RIP: 0033:0x7f0578eadaf9
RSP: 002b:00007f0578e5f318 EFLAGS: 00000246 ORIG_RAX: 0000000000000101
RAX: ffffffffffffffda RBX: 00007f0578f353e8 RCX: 00007f0578eadaf9
RDX: 0000000000000802 RSI: 0000000020000840 RDI: ffffffffffffff9c
RBP: 00007f0578f353e0 R08: 0000000000000000 R09: 0000000000000000
R10: 0000000000000000 R11: 0000000000000246 R12: 7974742f7665642f
R13: 00007fffc41d99af R14: 00007f0578e5f400 R15: 0000000000022000
rcu_sched kthread starved for 10539 jiffies! g297 c296 f0x2 RCU_GP_WAIT_FQS(3) ->state=0x0 ->cpu=1
rcu_sched       R  running task    30008     9      2 0x80000000
Call Trace:
 context_switch kernel/sched/core.c:2811 [inline]
 __schedule+0x88b/0x1de0 kernel/sched/core.c:3387
 schedule+0x8d/0x1b0 kernel/sched/core.c:3431
 schedule_timeout+0x4af/0xe90 kernel/time/timer.c:1747
 rcu_gp_kthread+0xc0a/0x1e60 kernel/rcu/tree.c:2255
 kthread+0x30d/0x420 kernel/kthread.c:232
 ret_from_fork+0x24/0x30 arch/x86/entry/entry_64.S:404

Crashes (4):
Manager Time Kernel Commit Syzkaller Config Log Report Syz repro C repro VM info Title
ci2-linux-4-14 2022/01/20 14:13 linux-4.14.y 4ba8e26127c3 5da9499f .config log report syz C INFO: rcu detected stall in chrdev_open
ci2-linux-4-14 2022/04/05 19:33 linux-4.14.y 74766a973637 0127c10f .config log report info INFO: rcu detected stall in chrdev_open
ci2-linux-4-14 2022/03/28 13:12 linux-4.14.y af1af6ebca0e 89bc8608 .config log report info INFO: rcu detected stall in chrdev_open
ci2-linux-4-14 2021/12/21 07:53 linux-4.14.y 9dfbac0e6b86 a938f0b8 .config log report info INFO: rcu detected stall in chrdev_open
* Struck through repros no longer work on HEAD.