syzbot


INFO: rcu detected stall in sys_getsockopt (2)

Status: upstream: reported on 2024/10/21 14:07
Reported-by: syzbot+ef72cd904969122c5343@syzkaller.appspotmail.com
First crash: 43d, last: 8d14h
Similar bugs (16)
Kernel Title Repro Cause bisect Fix bisect Count Last Reported Patched Status
upstream INFO: rcu detected stall in sys_getsockopt (2) kernel 1 1791d 1791d 0/28 closed as invalid on 2020/01/08 05:23
linux-4.19 INFO: rcu detected stall in sys_getsockopt 1 804d 804d 0/1 auto-obsoleted due to no activity on 2023/01/19 05:52
upstream INFO: rcu detected stall in sys_getsockopt (11) netfilter 4 338d 350d 0/28 auto-obsoleted due to no activity on 2024/03/30 17:47
linux-5.15 INFO: rcu detected stall in sys_getsockopt 1 357d 357d 0/3 auto-obsoleted due to no activity on 2024/03/21 16:23
upstream INFO: rcu detected stall in sys_getsockopt (3) kernel 1 1791d 1791d 0/28 closed as invalid on 2020/01/08 05:33
upstream INFO: rcu detected stall in sys_getsockopt (4) kernel 3 1791d 1791d 0/28 closed as invalid on 2020/01/09 08:13
upstream INFO: rcu detected stall in sys_getsockopt (6) kvm 3 1209d 1277d 0/28 auto-closed as invalid on 2021/11/10 12:58
upstream INFO: rcu detected stall in sys_getsockopt (7) netfilter 2 1066d 1115d 0/28 closed as invalid on 2022/02/08 10:10
upstream INFO: rcu detected stall in sys_getsockopt (5) sctp 2 1608d 1651d 0/28 auto-closed as invalid on 2020/10/06 19:28
linux-6.1 INFO: rcu detected stall in sys_getsockopt 4 274d 431d 0/3 auto-obsoleted due to no activity on 2024/06/12 17:46
upstream INFO: rcu detected stall in sys_getsockopt (10) mm 9 469d 550d 0/28 auto-obsoleted due to no activity on 2023/11/20 15:28
upstream INFO: rcu detected stall in sys_getsockopt (9) kernel 6 672d 828d 0/28 auto-obsoleted due to no activity on 2023/05/01 05:21
upstream INFO: rcu detected stall in sys_getsockopt (8) net 2 956d 972d 0/28 auto-closed as invalid on 2022/07/21 00:25
upstream INFO: rcu detected stall in sys_getsockopt kernel 2 1826d 1826d 0/28 closed as invalid on 2019/12/04 14:04
android-54 BUG: soft lockup in sys_getsockopt 1 230d 230d 0/2 auto-obsoleted due to no activity on 2024/07/15 21:19
android-5-15 BUG: soft lockup in sys_getsockopt 6 125d 224d 0/2 auto-obsoleted due to no activity on 2024/10/28 21:41

Sample crash report:
rcu: INFO: rcu_preempt detected stalls on CPUs/tasks:
rcu: 	0-...!: (0 ticks this GP) idle=ec5/1/0x4000000000000000 softirq=28837/28837 fqs=0 
	(detected by 1, t=10502 jiffies, g=36841, q=1941)
Sending NMI from CPU 1 to CPUs 0:
NMI backtrace for cpu 0
CPU: 0 PID: 5805 Comm: syz-executor Not tainted 5.15.173-syzkaller #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 09/13/2024
RIP: 0010:kasan_check_range+0x5/0x290 mm/kasan/generic.c:188
Code: c7 e8 9f c5 6a 08 31 c0 c3 0f 0b b8 ea ff ff ff c3 0f 0b b8 ea ff ff ff c3 cc cc cc cc cc cc cc cc cc cc cc cc 55 41 57 41 56 <53> b0 01 48 85 f6 0f 84 9a 01 00 00 48 89 fd 48 01 f5 0f 82 59 02
RSP: 0018:ffffc90000007b20 EFLAGS: 00000046
RAX: 0000000000000000 RBX: 0000000000000000 RCX: ffffffff8162bd7c
RDX: 0000000000000000 RSI: 0000000000000008 RDI: ffffffff8de969e8
RBP: ffffc90000007ca0 R08: 0000000000000000 R09: 0000000000000000
R10: 0000000000000000 R11: dffffc0000000001 R12: 1ffff92000000f70
R13: dffffc0000000000 R14: 0000000000000000 R15: 18162a22d4000000
FS:  0000555594401500(0000) GS:ffff8880b9000000(0000) knlGS:0000000000000000
CS:  0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: 00007f1c7bc152d8 CR3: 0000000025ca0000 CR4: 00000000003526f0
DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000
DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400
Call Trace:
 <NMI>
 </NMI>
 <IRQ>
 instrument_atomic_read include/linux/instrumented.h:71 [inline]
 test_bit include/asm-generic/bitops/instrumented-non-atomic.h:134 [inline]
 cpumask_test_cpu include/linux/cpumask.h:344 [inline]
 cpu_online include/linux/cpumask.h:895 [inline]
 trace_lock_acquire include/trace/events/lock.h:13 [inline]
 lock_acquire+0xcc/0x4f0 kernel/locking/lockdep.c:5594
 rcu_lock_acquire+0x2a/0x30 include/linux/rcupdate.h:312
 rcu_read_lock include/linux/rcupdate.h:739 [inline]
 advance_sched+0x6ce/0x940 net/sched/sch_taprio.c:769
 __run_hrtimer kernel/time/hrtimer.c:1688 [inline]
 __hrtimer_run_queues+0x598/0xcf0 kernel/time/hrtimer.c:1752
 hrtimer_interrupt+0x392/0x980 kernel/time/hrtimer.c:1814
 local_apic_timer_interrupt arch/x86/kernel/apic/apic.c:1097 [inline]
 __sysvec_apic_timer_interrupt+0x13b/0x4b0 arch/x86/kernel/apic/apic.c:1114
 instr_sysvec_apic_timer_interrupt arch/x86/kernel/apic/apic.c:1108 [inline]
 sysvec_apic_timer_interrupt+0x9b/0xc0 arch/x86/kernel/apic/apic.c:1108
 </IRQ>
 <TASK>
 asm_sysvec_apic_timer_interrupt+0x16/0x20 arch/x86/include/asm/idtentry.h:676
RIP: 0010:memset_erms+0xb/0x10 arch/x86/lib/memset_64.S:65
Code: 03 40 0f b6 f6 48 b8 01 01 01 01 01 01 01 01 48 0f af c6 f3 48 ab 89 d1 f3 aa 4c 89 c8 c3 90 49 89 f9 40 88 f0 48 89 d1 f3 aa <4c> 89 c8 c3 90 49 89 fa 40 0f b6 ce 48 b8 01 01 01 01 01 01 01 01
RSP: 0018:ffffc90003506860 EFLAGS: 00000202
RAX: 0000000000000000 RBX: ffffc90003506970 RCX: 0000000000000000
RDX: 0000000000000010 RSI: 0000000000000000 RDI: ffffc90003506980
RBP: ffffffff8ed19f02 R08: dffffc0000000000 R09: ffffc90003506970
R10: 0000000000000000 R11: dffffc0000000001 R12: 1ffffffff1da33e0
R13: 1ffffffff1da33e0 R14: ffffffff8ed19efe R15: ffffc90003506920
 unwind_next_frame+0xbc8/0x1fa0 arch/x86/kernel/unwind_orc.c:547
 arch_stack_walk+0x10d/0x140 arch/x86/kernel/stacktrace.c:25
 stack_trace_save+0x113/0x1c0 kernel/stacktrace.c:122
 kasan_save_stack mm/kasan/common.c:38 [inline]
 kasan_set_track mm/kasan/common.c:46 [inline]
 set_alloc_info mm/kasan/common.c:434 [inline]
 ____kasan_kmalloc+0xba/0xf0 mm/kasan/common.c:513
 kasan_kmalloc include/linux/kasan.h:264 [inline]
 kmem_cache_alloc_node_trace+0x171/0x2e0 mm/slub.c:3275
 kmalloc_node include/linux/slab.h:609 [inline]
 kzalloc_node include/linux/slab.h:732 [inline]
 __get_vm_area_node+0x11f/0x2f0 mm/vmalloc.c:2416
 __vmalloc_node_range+0xe3/0x8c0 mm/vmalloc.c:3019
 __vmalloc_node mm/vmalloc.c:3079 [inline]
 vzalloc+0x75/0x80 mm/vmalloc.c:3149
 alloc_counters+0xcf/0x7d0 net/ipv4/netfilter/arp_tables.c:659
 copy_entries_to_user net/ipv6/netfilter/ip6_tables.c:839 [inline]
 get_entries net/ipv6/netfilter/ip6_tables.c:1041 [inline]
 do_ip6t_get_ctl+0xea8/0x1890 net/ipv6/netfilter/ip6_tables.c:1679
 nf_getsockopt+0x28e/0x2b0 net/netfilter/nf_sockopt.c:116
 ipv6_getsockopt+0x468/0x2ff0 net/ipv6/ipv6_sockglue.c:1492
 tcp_getsockopt+0x25a/0x6fe0 net/ipv4/tcp.c:4313
 __sys_getsockopt+0x2a6/0x550 net/socket.c:2247
 __do_sys_getsockopt net/socket.c:2262 [inline]
 __se_sys_getsockopt net/socket.c:2259 [inline]
 __x64_sys_getsockopt+0xb1/0xc0 net/socket.c:2259
 do_syscall_x64 arch/x86/entry/common.c:50 [inline]
 do_syscall_64+0x3b/0xb0 arch/x86/entry/common.c:80
 entry_SYSCALL_64_after_hwframe+0x66/0xd0
RIP: 0033:0x7f1c7ba8f55a
Code: ff c3 66 0f 1f 44 00 00 48 c7 c2 a8 ff ff ff f7 d8 64 89 02 b8 ff ff ff ff eb b8 0f 1f 44 00 00 49 89 ca b8 37 00 00 00 0f 05 <48> 3d 00 f0 ff ff 77 06 c3 0f 1f 44 00 00 48 c7 c2 a8 ff ff ff f7
RSP: 002b:00007ffc25b90e48 EFLAGS: 00000212 ORIG_RAX: 0000000000000037
RAX: ffffffffffffffda RBX: 00007ffc25b90ed0 RCX: 00007f1c7ba8f55a
RDX: 0000000000000041 RSI: 0000000000000029 RDI: 0000000000000003
RBP: 0000000000000003 R08: 00007ffc25b90e6c R09: 0079746972756365
R10: 00007ffc25b90ed0 R11: 0000000000000212 R12: 00007f1c7bc17a00
R13: 00007ffc25b90e6c R14: 0000000000000000 R15: 00007f1c7bc18e40
 </TASK>
rcu: rcu_preempt kthread timer wakeup didn't happen for 10501 jiffies! g36841 f0x0 RCU_GP_WAIT_FQS(5) ->state=0x402
rcu: 	Possible timer handling issue on cpu=0 timer-softirq=14776
rcu: rcu_preempt kthread starved for 10502 jiffies! g36841 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:27256 pid:   15 ppid:     2 flags:0x00004000
Call Trace:
 <TASK>
 context_switch kernel/sched/core.c:5027 [inline]
 __schedule+0x12c4/0x45b0 kernel/sched/core.c:6373
 schedule+0x11b/0x1f0 kernel/sched/core.c:6456
 schedule_timeout+0x1b9/0x300 kernel/time/timer.c:1914
 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:334
 ret_from_fork+0x1f/0x30 arch/x86/entry/entry_64.S:287
 </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: 5805 Comm: syz-executor Not tainted 5.15.173-syzkaller #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 09/13/2024
RIP: 0010:validate_chain+0x9b/0x5930 kernel/locking/lockdep.c:3744
Code: f1 f1 f1 f1 00 f2 f2 f2 4a 89 04 21 48 b8 f2 f2 f2 00 f2 f2 f2 00 4a 89 44 21 09 48 b8 f2 f2 f2 f2 f2 00 00 00 4a 89 44 21 17 <48> b8 f2 f2 f2 f2 f2 00 f3 f3 4a 89 44 21 23 48 89 8c 24 98 00 00
RSP: 0018:ffffc900000077a0 EFLAGS: 00000806
RAX: 000000f2f2f2f2f2 RBX: ffffffff900ecfc0 RCX: 1ffff92000000f14
RDX: 0000000000000001 RSI: ffff88802907c698 RDI: ffff88802907bb80
RBP: ffffc90000007a50 R08: dffffc0000000000 R09: fffffbfff20ec821
R10: 0000000000000000 R11: dffffc0000000001 R12: dffffc0000000000
R13: ffff88802907c668 R14: 9be2421a50ef4013 R15: ffff88802907c6b8
FS:  0000555594401500(0000) GS:ffff8880b9000000(0000) knlGS:0000000000000000
CS:  0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: 00007f1c7bc152d8 CR3: 0000000025ca0000 CR4: 00000000003526f0
DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000
DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400
Call Trace:
 <NMI>
 </NMI>
 <IRQ>
 __lock_acquire+0x1295/0x1ff0 kernel/locking/lockdep.c:5012
 lock_acquire+0x1db/0x4f0 kernel/locking/lockdep.c:5623
 rcu_lock_acquire+0x2a/0x30 include/linux/rcupdate.h:312
 rcu_read_lock include/linux/rcupdate.h:739 [inline]
 advance_sched+0x6ce/0x940 net/sched/sch_taprio.c:769
 __run_hrtimer kernel/time/hrtimer.c:1688 [inline]
 __hrtimer_run_queues+0x598/0xcf0 kernel/time/hrtimer.c:1752
 hrtimer_interrupt+0x392/0x980 kernel/time/hrtimer.c:1814
 local_apic_timer_interrupt arch/x86/kernel/apic/apic.c:1097 [inline]
 __sysvec_apic_timer_interrupt+0x13b/0x4b0 arch/x86/kernel/apic/apic.c:1114
 instr_sysvec_apic_timer_interrupt arch/x86/kernel/apic/apic.c:1108 [inline]
 sysvec_apic_timer_interrupt+0x9b/0xc0 arch/x86/kernel/apic/apic.c:1108
 </IRQ>
 <TASK>
 asm_sysvec_apic_timer_interrupt+0x16/0x20 arch/x86/include/asm/idtentry.h:676
RIP: 0010:memset_erms+0xb/0x10 arch/x86/lib/memset_64.S:65
Code: 03 40 0f b6 f6 48 b8 01 01 01 01 01 01 01 01 48 0f af c6 f3 48 ab 89 d1 f3 aa 4c 89 c8 c3 90 49 89 f9 40 88 f0 48 89 d1 f3 aa <4c> 89 c8 c3 90 49 89 fa 40 0f b6 ce 48 b8 01 01 01 01 01 01 01 01
RSP: 0018:ffffc90003506860 EFLAGS: 00000202
RAX: 0000000000000000 RBX: ffffc90003506970 RCX: 0000000000000000
RDX: 0000000000000010 RSI: 0000000000000000 RDI: ffffc90003506980
RBP: ffffffff8ed19f02 R08: dffffc0000000000 R09: ffffc90003506970
R10: 0000000000000000 R11: dffffc0000000001 R12: 1ffffffff1da33e0
R13: 1ffffffff1da33e0 R14: ffffffff8ed19efe R15: ffffc90003506920
 unwind_next_frame+0xbc8/0x1fa0 arch/x86/kernel/unwind_orc.c:547
 arch_stack_walk+0x10d/0x140 arch/x86/kernel/stacktrace.c:25
 stack_trace_save+0x113/0x1c0 kernel/stacktrace.c:122
 kasan_save_stack mm/kasan/common.c:38 [inline]
 kasan_set_track mm/kasan/common.c:46 [inline]
 set_alloc_info mm/kasan/common.c:434 [inline]
 ____kasan_kmalloc+0xba/0xf0 mm/kasan/common.c:513
 kasan_kmalloc include/linux/kasan.h:264 [inline]
 kmem_cache_alloc_node_trace+0x171/0x2e0 mm/slub.c:3275
 kmalloc_node include/linux/slab.h:609 [inline]
 kzalloc_node include/linux/slab.h:732 [inline]
 __get_vm_area_node+0x11f/0x2f0 mm/vmalloc.c:2416
 __vmalloc_node_range+0xe3/0x8c0 mm/vmalloc.c:3019
 __vmalloc_node mm/vmalloc.c:3079 [inline]
 vzalloc+0x75/0x80 mm/vmalloc.c:3149
 alloc_counters+0xcf/0x7d0 net/ipv4/netfilter/arp_tables.c:659
 copy_entries_to_user net/ipv6/netfilter/ip6_tables.c:839 [inline]
 get_entries net/ipv6/netfilter/ip6_tables.c:1041 [inline]
 do_ip6t_get_ctl+0xea8/0x1890 net/ipv6/netfilter/ip6_tables.c:1679
 nf_getsockopt+0x28e/0x2b0 net/netfilter/nf_sockopt.c:116
 ipv6_getsockopt+0x468/0x2ff0 net/ipv6/ipv6_sockglue.c:1492
 tcp_getsockopt+0x25a/0x6fe0 net/ipv4/tcp.c:4313
 __sys_getsockopt+0x2a6/0x550 net/socket.c:2247
 __do_sys_getsockopt net/socket.c:2262 [inline]
 __se_sys_getsockopt net/socket.c:2259 [inline]
 __x64_sys_getsockopt+0xb1/0xc0 net/socket.c:2259
 do_syscall_x64 arch/x86/entry/common.c:50 [inline]
 do_syscall_64+0x3b/0xb0 arch/x86/entry/common.c:80
 entry_SYSCALL_64_after_hwframe+0x66/0xd0
RIP: 0033:0x7f1c7ba8f55a
Code: ff c3 66 0f 1f 44 00 00 48 c7 c2 a8 ff ff ff f7 d8 64 89 02 b8 ff ff ff ff eb b8 0f 1f 44 00 00 49 89 ca b8 37 00 00 00 0f 05 <48> 3d 00 f0 ff ff 77 06 c3 0f 1f 44 00 00 48 c7 c2 a8 ff ff ff f7
RSP: 002b:00007ffc25b90e48 EFLAGS: 00000212 ORIG_RAX: 0000000000000037
RAX: ffffffffffffffda RBX: 00007ffc25b90ed0 RCX: 00007f1c7ba8f55a
RDX: 0000000000000041 RSI: 0000000000000029 RDI: 0000000000000003
RBP: 0000000000000003 R08: 00007ffc25b90e6c R09: 0079746972756365
R10: 00007ffc25b90ed0 R11: 0000000000000212 R12: 00007f1c7bc17a00
R13: 00007ffc25b90e6c R14: 0000000000000000 R15: 00007f1c7bc18e40
 </TASK>

Crashes (2):
Time Kernel Commit Syzkaller Config Log Report Syz repro C repro VM info Assets (help?) Manager Title
2024/11/25 03:24 linux-5.15.y 0a51d2d4527b 68da6d95 .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-5-15-kasan INFO: rcu detected stall in sys_getsockopt
2024/10/21 14:06 linux-5.15.y 584a40a22cb9 f1e4447c .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-5-15-kasan INFO: rcu detected stall in sys_getsockopt
* Struck through repros no longer work on HEAD.