syzbot


INFO: rcu detected stall in ext4_file_write_iter

Status: upstream: reported C repro on 2019/04/20 13:09
Reported-by: syzbot+b0c07a7f1f6925ea6219@syzkaller.appspotmail.com
First crash: 1325d, last: 441d

Fix bisection: failed (bisect log)
similar bugs (7):
Kernel Title Repro Cause bisect Fix bisect Count Last Reported Patched Status
upstream INFO: rcu detected stall in ext4_file_write_iter (3) 5 483d 573d 0/24 auto-closed as invalid on 2021/11/07 19:52
upstream INFO: rcu detected stall in ext4_file_write_iter (5) 3 223d 224d 0/24 auto-closed as invalid on 2022/06/25 07:58
upstream INFO: rcu detected stall in ext4_file_write_iter (4) C unreliable 58 319d 348d 0/24 closed as invalid on 2022/02/08 10:32
android-49 INFO: rcu detected stall in ext4_file_write_iter syz 2 1281d 1322d 0/3 public: reported syz repro on 2019/04/23 08:58
upstream INFO: rcu detected stall in ext4_file_write_iter (2) 1 784d 784d 0/24 auto-closed as invalid on 2021/01/10 12:58
linux-4.14 INFO: rcu detected stall in ext4_file_write_iter C 7 39d 1333d 0/1 upstream: reported C repro on 2019/04/12 16:30
upstream INFO: rcu detected stall in ext4_file_write_iter C inconclusive done 93 846d 1378d 17/24 fixed on 2020/09/25 01:17

Sample crash report:
audit: type=1400 audit(1561207928.558:36): avc:  denied  { map } for  pid=7583 comm="syz-executor978" path="/root/syz-executor978141630" dev="sda1" ino=1426 scontext=unconfined_u:system_r:insmod_t:s0-s0:c0.c1023 tcontext=unconfined_u:object_r:user_home_t:s0 tclass=file permissive=1
rcu: INFO: rcu_preempt detected stalls on CPUs/tasks:
rcu: 	(detected by 1, t=10502 jiffies, g=5293, q=20)
rcu: All QSes seen, last rcu_preempt kthread activity 10503 (4295055363-4295044860), jiffies_till_next_fqs=1, root ->qsmask 0x0
syz-executor978 R  running task    26464  7592   7585 0x00000000
Call Trace:
 <IRQ>
 sched_show_task kernel/sched/core.c:5297 [inline]
 sched_show_task.cold+0x292/0x30b kernel/sched/core.c:5272
 print_other_cpu_stall kernel/rcu/tree.c:1430 [inline]
 check_cpu_stall kernel/rcu/tree.c:1557 [inline]
 __rcu_pending kernel/rcu/tree.c:3293 [inline]
 rcu_pending kernel/rcu/tree.c:3336 [inline]
 rcu_check_callbacks.cold+0xaa1/0xd93 kernel/rcu/tree.c:2682
 update_process_times+0x32/0x80 kernel/time/timer.c:1636
 tick_sched_handle+0xa2/0x190 kernel/time/tick-sched.c:164
 tick_sched_timer+0x47/0x130 kernel/time/tick-sched.c:1274
 __run_hrtimer kernel/time/hrtimer.c:1398 [inline]
 __hrtimer_run_queues+0x33b/0xdd0 kernel/time/hrtimer.c:1460
 hrtimer_interrupt+0x314/0x770 kernel/time/hrtimer.c:1518
 local_apic_timer_interrupt arch/x86/kernel/apic/apic.c:1029 [inline]
 smp_apic_timer_interrupt+0x111/0x550 arch/x86/kernel/apic/apic.c:1054
 apic_timer_interrupt+0xf/0x20 arch/x86/entry/entry_64.S:869
 </IRQ>
RIP: 0010:arch_local_save_flags arch/x86/include/asm/paravirt.h:783 [inline]
RIP: 0010:arch_local_irq_save arch/x86/include/asm/paravirt.h:805 [inline]
RIP: 0010:lock_is_held_type+0x87/0x210 kernel/locking/lockdep.c:3934
Code: 72 88 48 ba 00 00 00 00 00 fc ff df 48 c1 e8 03 80 3c 10 00 0f 85 69 01 00 00 48 83 3d d1 8e 20 07 00 0f 84 20 01 00 00 9c 58 <0f> 1f 44 00 00 48 c7 c2 50 36 72 88 48 89 c3 48 b8 00 00 00 00 00
RSP: 0018:ffff8880908b7428 EFLAGS: 00000286 ORIG_RAX: ffffffffffffff13
RAX: 0000000000000286 RBX: ffff8880a112e700 RCX: 0000000000000000
RDX: dffffc0000000000 RSI: 00000000ffffffff RDI: ffff8880a112ef7c
RBP: ffff8880908b7448 R08: ffff8880a112e700 R09: ffffed1015d24733
R10: ffffed1015d24732 R11: ffff8880ae923993 R12: ffffffff8879d760
R13: ffff88808efad4f0 R14: 000000000496d9e4 R15: ffff88808efad6f0
 lock_is_held include/linux/lockdep.h:344 [inline]
 rcu_read_lock_sched_held+0x110/0x130 kernel/rcu/update.c:118
 trace_ext4_da_write_end include/trace/events/ext4.h:382 [inline]
 ext4_da_write_end+0x865/0xa50 fs/ext4/inode.c:3146
 generic_perform_write+0x2ed/0x520 mm/filemap.c:3150
 __generic_file_write_iter+0x25e/0x630 mm/filemap.c:3264
 ext4_file_write_iter+0x32b/0x1060 fs/ext4/file.c:266
 call_write_iter include/linux/fs.h:1820 [inline]
 do_iter_readv_writev+0x558/0x830 fs/read_write.c:681
 do_iter_write fs/read_write.c:960 [inline]
 do_iter_write+0x184/0x5f0 fs/read_write.c:941
 vfs_iter_write+0x77/0xb0 fs/read_write.c:973
 iter_file_splice_write+0x661/0xbd0 fs/splice.c:750
 do_splice_from fs/splice.c:852 [inline]
 direct_splice_actor+0x123/0x190 fs/splice.c:1019
 splice_direct_to_actor+0x2e7/0x890 fs/splice.c:974
 do_splice_direct+0x1da/0x2a0 fs/splice.c:1062
 do_sendfile+0x597/0xce0 fs/read_write.c:1447
 __do_sys_sendfile64 fs/read_write.c:1502 [inline]
 __se_sys_sendfile64 fs/read_write.c:1494 [inline]
 __x64_sys_sendfile64+0x15a/0x220 fs/read_write.c:1494
 do_syscall_64+0xfd/0x620 arch/x86/entry/common.c:293
 entry_SYSCALL_64_after_hwframe+0x49/0xbe
RIP: 0033:0x4417c9
Code: e8 7c e7 ff ff 48 83 c4 18 c3 0f 1f 80 00 00 00 00 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 0f 83 bb 07 fc ff c3 66 2e 0f 1f 84 00 00 00 00
RSP: 002b:00007ffedf309698 EFLAGS: 00000246 ORIG_RAX: 0000000000000028
RAX: ffffffffffffffda RBX: 00007ffedf309840 RCX: 00000000004417c9
RDX: 0000000020000000 RSI: 0000000000000003 RDI: 0000000000000003
RBP: 0000000000000000 R08: 0000000000000000 R09: 0000000000000000
R10: 00008080fffffffe R11: 0000000000000246 R12: 0000000000000000
R13: 00000000004024a0 R14: 0000000000000000 R15: 0000000000000000
rcu: rcu_preempt kthread starved for 10549 jiffies! g5293 f0x2 RCU_GP_WAIT_FQS(5) ->state=0x0 ->cpu=0
rcu: RCU grace-period kthread stack dump:
rcu_preempt     R  running task    29624    10      2 0x80000000
Call Trace:
 context_switch kernel/sched/core.c:2826 [inline]
 __schedule+0x80d/0x1c70 kernel/sched/core.c:3474
 schedule+0x92/0x1c0 kernel/sched/core.c:3518
 schedule_timeout+0x4db/0xfc0 kernel/time/timer.c:1804
 rcu_gp_kthread+0xd5c/0x2190 kernel/rcu/tree.c:2202
 kthread+0x354/0x420 kernel/kthread.c:246
 ret_from_fork+0x24/0x30 arch/x86/entry/entry_64.S:415

Crashes (7):
Manager Time Kernel Commit Syzkaller Config Log Report Syz repro C repro VM info Title
ci2-linux-4-19 2019/06/22 12:57 linux-4.19.y 63bbbcd8ed53 34bf9440 .config log report syz C
ci2-linux-4-19 2020/06/13 06:00 linux-4.19.y 3fc898571b97 f4724dd3 .config log report
ci2-linux-4-19 2020/06/13 05:56 linux-4.19.y 3fc898571b97 f4724dd3 .config log report
ci2-linux-4-19 2020/04/18 08:09 linux-4.19.y 8488c3f3bc86 435c6d53 .config log report
ci2-linux-4-19 2020/03/04 06:43 linux-4.19.y a083db76118d 1f73b64b .config log report
ci2-linux-4-19 2019/06/13 12:01 linux-4.19.y 768292d05361 3f4e812b .config log report
ci2-linux-4-19 2019/04/20 12:08 linux-4.19.y c98875d930e9 b0e8efcb .config log report
* Struck through repros no longer work on HEAD.