[v5.15] INFO: rcu detected stall in syscall_exit_to_user_mode

0 views
Skip to first unread message

syzbot

unread,
Aug 26, 2023, 6:23:53 PM8/26/23
to syzkaller...@googlegroups.com
Hello,

syzbot found the following issue on:

HEAD commit: 5ddfe5cc8716 Linux 5.15.128
git tree: linux-5.15.y
console output: https://syzkaller.appspot.com/x/log.txt?x=12069a33a80000
kernel config: https://syzkaller.appspot.com/x/.config?x=1b6ad98d397fbe23
dashboard link: https://syzkaller.appspot.com/bug?extid=82e2b3f11a49481f3ea3
compiler: Debian clang version 15.0.6, GNU ld (GNU Binutils for Debian) 2.40

Unfortunately, I don't have any reproducer for this issue yet.

Downloadable assets:
disk image: https://storage.googleapis.com/syzbot-assets/9a542b09fbaf/disk-5ddfe5cc.raw.xz
vmlinux: https://storage.googleapis.com/syzbot-assets/4452fc1a4542/vmlinux-5ddfe5cc.xz
kernel image: https://storage.googleapis.com/syzbot-assets/90dc6d0c61df/bzImage-5ddfe5cc.xz

IMPORTANT: if you fix the issue, please add the following tag to the commit:
Reported-by: syzbot+82e2b3...@syzkaller.appspotmail.com

rcu: INFO: rcu_preempt detected stalls on CPUs/tasks:
(detected by 0, t=10502 jiffies, g=115501, q=1)
rcu: All QSes seen, last rcu_preempt kthread activity 10503 (4295064435-4295053932), jiffies_till_next_fqs=1, root ->qsmask 0x0
rcu: rcu_preempt kthread starved for 10504 jiffies! g115501 f0x2 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:26936 pid: 15 ppid: 2 flags:0x00004000
Call Trace:
<TASK>
context_switch kernel/sched/core.c:5026 [inline]
__schedule+0x12c4/0x4590 kernel/sched/core.c:6372
schedule+0x11b/0x1f0 kernel/sched/core.c:6455
schedule_timeout+0x1b9/0x300 kernel/time/timer.c:1884
rcu_gp_fqs_loop+0x2af/0xf70 kernel/rcu/tree.c:1959
rcu_gp_kthread+0xa4/0x360 kernel/rcu/tree.c:2132
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 0 to CPUs 1:
NMI backtrace for cpu 1
CPU: 1 PID: 22315 Comm: syz-executor.0 Not tainted 5.15.128-syzkaller #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 07/26/2023
RIP: 0010:arch_static_branch arch/x86/include/asm/jump_label.h:27 [inline]
RIP: 0010:static_key_false include/linux/jump_label.h:212 [inline]
RIP: 0010:native_write_msr arch/x86/include/asm/msr.h:156 [inline]
RIP: 0010:wrmsr arch/x86/include/asm/msr.h:263 [inline]
RIP: 0010:native_apic_msr_write+0x35/0x50 arch/x86/include/asm/apic.h:207
Code: 74 2a 83 ff 30 74 25 eb 10 81 ff d0 00 00 00 74 1b 81 ff e0 00 00 00 74 13 c1 ef 04 81 c7 00 08 00 00 89 f9 89 f0 31 d2 0f 30 <66> 90 c3 89 f6 31 d2 e9 cf b2 f1 02 66 2e 0f 1f 84 00 00 00 00 00
RSP: 0018:ffffc90000dd0e60 EFLAGS: 00000046
RAX: 000000000002ff58 RBX: ffffffff8c3509a8 RCX: 0000000000000838
RDX: 0000000000000000 RSI: 000000000002ff58 RDI: 0000000000000838
RBP: 000000000002ff58 R08: ffffffff81723d4d R09: fffffbfff1bc8156
R10: 0000000000000000 R11: dffffc0000000001 R12: ffff8880b9b27240
R13: dffffc0000000000 R14: 000000000002ff58 R15: dffffc0000000000
FS: 00007f659d7ee6c0(0000) GS:ffff8880b9b00000(0000) knlGS:0000000000000000
CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: 000000002006b000 CR3: 0000000094077000 CR4: 00000000003506e0
DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000
DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400
Call Trace:
<NMI>
</NMI>
<IRQ>
apic_write arch/x86/include/asm/apic.h:394 [inline]
lapic_next_event+0x5b/0x70 arch/x86/kernel/apic/apic.c:468
clockevents_program_event+0x1c5/0x310 kernel/time/clockevents.c:334
hrtimer_interrupt+0x546/0x980 kernel/time/hrtimer.c:1824
local_apic_timer_interrupt arch/x86/kernel/apic/apic.c:1085 [inline]
__sysvec_apic_timer_interrupt+0x139/0x470 arch/x86/kernel/apic/apic.c:1102
sysvec_apic_timer_interrupt+0x8c/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:__raw_spin_unlock_irq include/linux/spinlock_api_smp.h:169 [inline]
RIP: 0010:_raw_spin_unlock_irq+0x25/0x40 kernel/locking/spinlock.c:202
Code: 21 7e f6 ff 90 53 48 89 fb 48 83 c7 18 48 8b 74 24 08 e8 2e 98 3c f7 48 89 df e8 86 eb 3d f7 e8 11 80 60 f7 fb bf 01 00 00 00 <e8> 46 28 31 f7 65 8b 05 27 65 dc 75 85 c0 74 02 5b c3 e8 b4 7c da
RSP: 0018:ffffc9000942fbc0 EFLAGS: 00000282
RAX: f3aad30863bd7d00 RBX: ffff88807726ca00 RCX: ffffffff913d0003
RDX: dffffc0000000000 RSI: ffffffff8a8b0ce0 RDI: 0000000000000001
RBP: 0000000000000000 R08: ffffffff81868ad0 R09: ffffed100ee4d941
R10: 0000000000000000 R11: dffffc0000000001 R12: 0000000000000021
R13: dffffc0000000000 R14: ffff88807726ce98 R15: ffff88807726ca00
spin_unlock_irq include/linux/spinlock.h:413 [inline]
get_signal+0x13ee/0x14e0 kernel/signal.c:2892
arch_do_signal_or_restart+0xc3/0x1890 arch/x86/kernel/signal.c:867
handle_signal_work kernel/entry/common.c:148 [inline]
exit_to_user_mode_loop+0x97/0x130 kernel/entry/common.c:172
exit_to_user_mode_prepare+0xb1/0x140 kernel/entry/common.c:208
__syscall_exit_to_user_mode_work kernel/entry/common.c:290 [inline]
syscall_exit_to_user_mode+0x5d/0x250 kernel/entry/common.c:301
do_syscall_64+0x49/0xb0 arch/x86/entry/common.c:86
entry_SYSCALL_64_after_hwframe+0x61/0xcb
RIP: 0033:0x7f659f26cae7
Code: 14 25 28 00 00 00 75 05 48 83 c4 28 c3 e8 e1 20 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
RSP: 002b:00007f659d7ee0c8 EFLAGS: 00000246
RAX: 0000000000000013 RBX: 00007f659f38bf80 RCX: 00007f659f26cae9
RDX: 0000000000000001 RSI: 00000000200000c0 RDI: 0000000000000005
RBP: 00007f659f2b847a R08: 0000000000000000 R09: 0000000000000000
R10: 0000000000000000 R11: 0000000000000246 R12: 0000000000000000
R13: 000000000000000b R14: 00007f659f38bf80 R15: 00007ffd57fa06c8
</TASK>


---
This report is generated by a bot. It may contain errors.
See https://goo.gl/tpsmEJ for more information about syzbot.
syzbot engineers can be reached at syzk...@googlegroups.com.

syzbot will keep track of this issue. See:
https://goo.gl/tpsmEJ#status for how to communicate with syzbot.

If the bug is already fixed, let syzbot know by replying with:
#syz fix: exact-commit-title

If you want to overwrite bug's subsystems, reply with:
#syz set subsystems: new-subsystem
(See the list of subsystem names on the web dashboard)

If the bug is a duplicate of another bug, reply with:
#syz dup: exact-subject-of-another-report

If you want to undo deduplication, reply with:
#syz undup

syzbot

unread,
Sep 7, 2023, 9:32:04 PM9/7/23
to syzkaller...@googlegroups.com
syzbot has found a reproducer for the following issue on:

HEAD commit: aff03380bda4 Linux 5.15.131
git tree: linux-5.15.y
console output: https://syzkaller.appspot.com/x/log.txt?x=150a87cc680000
kernel config: https://syzkaller.appspot.com/x/.config?x=6587a45fd4ed4bea
dashboard link: https://syzkaller.appspot.com/bug?extid=82e2b3f11a49481f3ea3
compiler: Debian clang version 15.0.6, GNU ld (GNU Binutils for Debian) 2.40
syz repro: https://syzkaller.appspot.com/x/repro.syz?x=17d5ba2fa80000
C reproducer: https://syzkaller.appspot.com/x/repro.c?x=1766f4b4680000

Downloadable assets:
disk image: https://storage.googleapis.com/syzbot-assets/27b8e091695d/disk-aff03380.raw.xz
vmlinux: https://storage.googleapis.com/syzbot-assets/966318f77343/vmlinux-aff03380.xz
kernel image: https://storage.googleapis.com/syzbot-assets/5eb45b408cbc/bzImage-aff03380.xz

IMPORTANT: if you fix the issue, please add the following tag to the commit:
Reported-by: syzbot+82e2b3...@syzkaller.appspotmail.com

rcu: INFO: rcu_preempt detected stalls on CPUs/tasks:
(detected by 0, t=10502 jiffies, g=3697, q=9)
rcu: All QSes seen, last rcu_preempt kthread activity 10498 (4294965880-4294955382), jiffies_till_next_fqs=1, root ->qsmask 0x0
rcu: rcu_preempt kthread starved for 10498 jiffies! g3697 f0x2 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:25984 pid: 15 ppid: 2 flags:0x00004000
Call Trace:
<TASK>
context_switch kernel/sched/core.c:5026 [inline]
__schedule+0x12c4/0x4590 kernel/sched/core.c:6372
schedule+0x11b/0x1f0 kernel/sched/core.c:6455
schedule_timeout+0x1b9/0x300 kernel/time/timer.c:1884
rcu_gp_fqs_loop+0x2af/0xf70 kernel/rcu/tree.c:1959
rcu_gp_kthread+0xa4/0x360 kernel/rcu/tree.c:2132
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 0 to CPUs 1:
NMI backtrace for cpu 1
CPU: 1 PID: 3553 Comm: syz-executor143 Not tainted 5.15.131-syzkaller #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 07/26/2023
RIP: 0010:irqtime_account_irq+0x12b/0x1e0
Code: 89 df e8 e8 0e 70 00 48 8b 03 4a 8d 9c f8 b0 76 02 00 48 89 d8 48 c1 e8 03 80 3c 28 00 74 08 48 89 df e8 c8 0e 70 00 4c 01 33 <4c> 89 e0 48 c1 e8 03 80 3c 28 00 74 08 4c 89 e7 e8 b0 0e 70 00 4d
RSP: 0018:ffffc90000dd0f00 EFLAGS: 00000016
RAX: 1ffff11017364eda RBX: ffff8880b9b276d0 RCX: 1ffffffff1ebb608
RDX: 1ffffffff1ebb608 RSI: ffffffff8ad878e0 RDI: ffffffff8ad878a0
RBP: dffffc0000000000 R08: ffffffff8f5db040 R09: ffffffff8f5db048
R10: ffffffff8f5db058 R11: ffffffff8f5db050 R12: ffff8880b9b27740
R13: ffff8880b9b27750 R14: 0000000000002ccd R15: 0000000000000004
FS: 00005555558ca3c0(0000) GS:ffff8880b9b00000(0000) knlGS:0000000000000000
CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: 000000002006b000 CR3: 000000001a53e000 CR4: 00000000003506e0
DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000
DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400
Call Trace:
<NMI>
</NMI>
<IRQ>
account_hardirq_exit include/linux/vtime.h:159 [inline]
__irq_exit_rcu+0xb8/0x240 kernel/softirq.c:634
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:__raw_spin_unlock_irq include/linux/spinlock_api_smp.h:169 [inline]
RIP: 0010:_raw_spin_unlock_irq+0x25/0x40 kernel/locking/spinlock.c:202
Code: 21 7e f6 ff 90 53 48 89 fb 48 83 c7 18 48 8b 74 24 08 e8 be 77 3c f7 48 89 df e8 16 cb 3d f7 e8 11 6a 60 f7 fb bf 01 00 00 00 <e8> 46 08 31 f7 65 8b 05 27 45 dc 75 85 c0 74 02 5b c3 e8 b4 5c da
RSP: 0018:ffffc90002d9fbc0 EFLAGS: 00000282
RAX: f3abadd24cf80500 RBX: ffff88807883ca00 RCX: ffffffff913d0003
RDX: dffffc0000000000 RSI: ffffffff8a8b0ce0 RDI: 0000000000000001
RBP: 0000000000000000 R08: ffffffff818694d0 R09: ffffed100f107941
R10: 0000000000000000 R11: dffffc0000000001 R12: 0000000000000021
R13: dffffc0000000000 R14: ffff88807883ce98 R15: ffff88807883ca00
spin_unlock_irq include/linux/spinlock.h:413 [inline]
get_signal+0x13ee/0x14e0 kernel/signal.c:2892
arch_do_signal_or_restart+0xc3/0x1890 arch/x86/kernel/signal.c:867
handle_signal_work kernel/entry/common.c:148 [inline]
exit_to_user_mode_loop+0x97/0x130 kernel/entry/common.c:172
exit_to_user_mode_prepare+0xb1/0x140 kernel/entry/common.c:208
__syscall_exit_to_user_mode_work kernel/entry/common.c:290 [inline]
syscall_exit_to_user_mode+0x5d/0x250 kernel/entry/common.c:301
do_syscall_64+0x49/0xb0 arch/x86/entry/common.c:86
entry_SYSCALL_64_after_hwframe+0x61/0xcb
RIP: 0033:0x7fe39c939e79
Code: 28 00 00 00 75 05 48 83 c4 28 c3 e8 e1 18 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:00007ffc452af488 EFLAGS: 00000246
RAX: 0000000000000000 RBX: 0000000000000003 RCX: 00007fe39c939e79
RDX: 000000002006b000 RSI: 0000000000000000 RDI: 0000000000000000
RBP: 00000000000f4240 R08: 0000000000000000 R09: 0000000000000000
R10: 0000000000000000 R11: 0000000000000246 R12: 00005555558ca370
R13: 0000000000000005 R14: 00007ffc452af500 R15: 00007ffc452af4f0
</TASK>
INFO: NMI handler (nmi_cpu_backtrace_handler) took too long to run: 1.264 msecs


---
If you want syzbot to run the reproducer, reply with:
#syz test: git://repo/address.git branch-or-commit-hash
If you attach or paste a git patch, syzbot will apply it before testing.
Reply all
Reply to author
Forward
0 new messages