syzbot


INFO: rcu detected stall in sys_mlock

Status: upstream: reported on 2024/05/15 11:10
Reported-by: syzbot+79baacb751cac7803ff5@syzkaller.appspotmail.com
First crash: 40d, last: 40d

Sample crash report:
rcu: INFO: rcu_preempt detected stalls on CPUs/tasks:
rcu: 	Tasks blocked on level-0 rcu_node (CPUs 0-1): P3727/1:b..l
	(detected by 1, t=10503 jiffies, g=6577, q=65 ncpus=2)
task:syz-executor.0  state:R  running task     stack:25064 pid:3727  ppid:3561   flags:0x00004002
Call Trace:
 <TASK>
 context_switch kernel/sched/core.c:5245 [inline]
 __schedule+0x142d/0x4550 kernel/sched/core.c:6558
 preempt_schedule_irq+0xf7/0x1c0 kernel/sched/core.c:6870
 irqentry_exit+0x53/0x80 kernel/entry/common.c:439
 asm_sysvec_apic_timer_interrupt+0x16/0x20 arch/x86/include/asm/idtentry.h:653
RIP: 0010:lock_acquire+0x26f/0x5a0 kernel/locking/lockdep.c:5666
Code: 2b 00 74 08 4c 89 f7 e8 3f a1 77 00 f6 44 24 61 02 0f 85 84 01 00 00 41 f7 c7 00 02 00 00 74 01 fb 48 c7 44 24 40 0e 36 e0 45 <4b> c7 44 25 00 00 00 00 00 43 c7 44 25 09 00 00 00 00 43 c7 44 25
RSP: 0018:ffffc90005067680 EFLAGS: 00000206
RAX: 0000000000000001 RBX: 1ffff92000a0cedc RCX: 1ffff92000a0ce7c
RDX: dffffc0000000000 RSI: ffffffff8aec1340 RDI: ffffffff8b3d43e0
RBP: ffffc900050677e0 R08: dffffc0000000000 R09: fffffbfff2093645
R10: 0000000000000000 R11: dffffc0000000001 R12: 1ffff92000a0ced8
R13: dffffc0000000000 R14: ffffc900050676e0 R15: 0000000000000246
 rcu_lock_acquire include/linux/rcupdate.h:350 [inline]
 rcu_read_lock include/linux/rcupdate.h:791 [inline]
 blk_cgroup_congested+0x36/0x220 block/blk-cgroup.c:1997
 __cgroup_throttle_swaprate+0x6d/0x1b0 mm/swapfile.c:3671
 cgroup_throttle_swaprate include/linux/swap.h:662 [inline]
 do_anonymous_page mm/memory.c:4178 [inline]
 handle_pte_fault mm/memory.c:5011 [inline]
 __handle_mm_fault mm/memory.c:5155 [inline]
 handle_mm_fault+0x3b53/0x5340 mm/memory.c:5276
 faultin_page mm/gup.c:1009 [inline]
 __get_user_pages+0x4f3/0x1190 mm/gup.c:1233
 populate_vma_page_range+0x217/0x2b0 mm/gup.c:1590
 __mm_populate+0x275/0x440 mm/gup.c:1704
 do_mlock+0x567/0x660 mm/mlock.c:608
 __do_sys_mlock mm/mlock.c:616 [inline]
 __se_sys_mlock mm/mlock.c:614 [inline]
 __x64_sys_mlock+0x5c/0x70 mm/mlock.c:614
 do_syscall_x64 arch/x86/entry/common.c:51 [inline]
 do_syscall_64+0x3b/0xb0 arch/x86/entry/common.c:81
 entry_SYSCALL_64_after_hwframe+0x68/0xd2
RIP: 0033:0x7f8020e7dd69
RSP: 002b:00007f8021b4a0c8 EFLAGS: 00000246 ORIG_RAX: 0000000000000095
RAX: ffffffffffffffda RBX: 00007f8020fabf80 RCX: 00007f8020e7dd69
RDX: 0000000000000000 RSI: 0000000000800000 RDI: 0000000020000000
RBP: 00007f8020eca49e R08: 0000000000000000 R09: 0000000000000000
R10: 0000000000000000 R11: 0000000000000246 R12: 0000000000000000
R13: 000000000000000b R14: 00007f8020fabf80 R15: 00007ffc2e74f118
 </TASK>
rcu: rcu_preempt kthread starved for 10539 jiffies! g6577 f0x0 RCU_GP_WAIT_FQS(5) ->state=0x0 ->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:R  running task     stack:27032 pid:16    ppid:2      flags:0x00004000
Call Trace:
 <TASK>
 context_switch kernel/sched/core.c:5245 [inline]
 __schedule+0x142d/0x4550 kernel/sched/core.c:6558
 schedule+0xbf/0x180 kernel/sched/core.c:6634
 schedule_timeout+0x1b9/0x300 kernel/time/timer.c:1965
 rcu_gp_fqs_loop+0x2d2/0x1150 kernel/rcu/tree.c:1706
 rcu_gp_kthread+0xa3/0x3b0 kernel/rcu/tree.c:1905
 kthread+0x28d/0x320 kernel/kthread.c:376
 ret_from_fork+0x1f/0x30 arch/x86/entry/entry_64.S:308
 </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: 3743 Comm: syz-executor.1 Not tainted 6.1.90-syzkaller #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 04/02/2024
RIP: 0010:get_signal+0x68b/0x17d0 kernel/signal.c:2760
Code: 0f 87 38 08 00 00 e8 84 ce 33 00 48 c1 e3 05 4d 8d bc 1f 98 00 00 00 44 89 f7 48 8b 74 24 10 4c 89 fa e8 98 1c 00 00 4d 89 fc <49> c1 ec 03 48 b8 00 00 00 00 00 fc ff df 41 80 3c 04 00 74 08 4c
RSP: 0018:ffffc90005127b40 EFLAGS: 00000046
RAX: ffffffff8156dc35 RBX: 0000000000000400 RCX: 0000000000040000
RDX: ffffc900053e9000 RSI: 000000000003ffff RDI: 0000000000040000
RBP: ffffc90005127c70 R08: ffffffff8156dc22 R09: fffffbfff1ce7046
R10: 0000000000000000 R11: dffffc0000000001 R12: ffff88807b1c2998
R13: 0000000000000020 R14: 0000000000000021 R15: ffff88807b1c2998
FS:  00007fece65f66c0(0000) GS:ffff8880b9800000(0000) knlGS:0000000000000000
CS:  0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: 000000002006b000 CR3: 000000007dc69000 CR4: 00000000003506f0
DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000
DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400
Call Trace:
 <NMI>
 </NMI>
 <TASK>
 arch_do_signal_or_restart+0xb0/0x1a10 arch/x86/kernel/signal.c:871
 exit_to_user_mode_loop+0x6a/0x100 kernel/entry/common.c:174
 exit_to_user_mode_prepare+0xb1/0x140 kernel/entry/common.c:210
 __syscall_exit_to_user_mode_work kernel/entry/common.c:292 [inline]
 syscall_exit_to_user_mode+0x60/0x270 kernel/entry/common.c:303
 do_syscall_64+0x47/0xb0 arch/x86/entry/common.c:87
 entry_SYSCALL_64_after_hwframe+0x68/0xd2
RIP: 0033:0x7fece7a7dd67
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:00007fece65f60c8 EFLAGS: 00000246
RAX: 0000000000000113 RBX: 00007fece7babf80 RCX: 00007fece7a7dd69
RDX: 0000000000000003 RSI: 0000000000000000 RDI: 0000000000000004
RBP: 00007fece7aca49e R08: 0000000000000004 R09: 0000000000000000
R10: 0000000000000000 R11: 0000000000000246 R12: 0000000000000000
R13: 000000000000000b R14: 00007fece7babf80 R15: 00007ffc86a230b8
 </TASK>
sched: RT throttling activated

Crashes (1):
Time Kernel Commit Syzkaller Config Log Report Syz repro C repro VM info Assets (help?) Manager Title
2024/05/15 11:09 linux-6.1.y 909ba1f1b414 94b087b1 .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-6-1-kasan INFO: rcu detected stall in sys_mlock
* Struck through repros no longer work on HEAD.