syzbot


INFO: task hung in btrfs_commit_transaction

Status: auto-obsoleted due to no activity on 2024/08/07 22:30
Subsystems: btrfs
[Documentation on labels]
First crash: 425d, last: 263d

Sample crash report:
INFO: task syz-executor.2:15947 blocked for more than 143 seconds.
      Not tainted 6.8.0-rc7-syzkaller-00231-g09e5c48fea17 #0
"echo 0 > /proc/sys/kernel/hung_task_timeout_secs" disables this message.
task:syz-executor.2  state:D stack:25112 pid:15947 tgid:15947 ppid:12029  flags:0x00004006
Call Trace:
 <TASK>
 context_switch kernel/sched/core.c:5400 [inline]
 __schedule+0x177f/0x49a0 kernel/sched/core.c:6727
 __schedule_loop kernel/sched/core.c:6802 [inline]
 schedule+0x149/0x260 kernel/sched/core.c:6817
 btrfs_commit_transaction+0x9bc/0x3740 fs/btrfs/transaction.c:2328
 flush_space+0x9ae/0xcf0 fs/btrfs/space-info.c:818
 priority_reclaim_metadata_space+0xe7/0x5a0 fs/btrfs/space-info.c:1412
 __reserve_bytes+0xb74/0x18a0 fs/btrfs/space-info.c:1757
 btrfs_reserve_metadata_bytes+0x2e/0x110 fs/btrfs/space-info.c:1783
 btrfs_block_rsv_refill+0xd8/0x1b0 fs/btrfs/block-rsv.c:265
 evict_refill_and_join+0xcf/0x210 fs/btrfs/inode.c:5197
 btrfs_evict_inode+0xa19/0x1010 fs/btrfs/inode.c:5291
 evict+0x2a8/0x630 fs/inode.c:665
 __dentry_kill+0x20d/0x630 fs/dcache.c:603
 dput+0x19f/0x2b0 fs/dcache.c:845
 __fput+0x678/0x8a0 fs/file_table.c:384
 __do_sys_close fs/open.c:1554 [inline]
 __se_sys_close fs/open.c:1539 [inline]
 __x64_sys_close+0x7e/0x110 fs/open.c:1539
 do_syscall_64+0xf9/0x240
 entry_SYSCALL_64_after_hwframe+0x6f/0x77
RIP: 0033:0x7f999d47cc9a
RSP: 002b:00007ffef31ee800 EFLAGS: 00000293 ORIG_RAX: 0000000000000003
RAX: ffffffffffffffda RBX: 0000000000000006 RCX: 00007f999d47cc9a
RDX: 0000000000000000 RSI: 0000000000000000 RDI: 0000000000000005
RBP: 00007f999d5ad980 R08: 0000001b32a60000 R09: 00007ffef31f90b0
R10: 00007ffef31f9080 R11: 0000000000000293 R12: 000000000016f1d4
R13: ffffffffffffffff R14: 00007f999d000000 R15: 000000000016e828
 </TASK>
INFO: task syz-executor.2:15949 blocked for more than 144 seconds.
      Not tainted 6.8.0-rc7-syzkaller-00231-g09e5c48fea17 #0
"echo 0 > /proc/sys/kernel/hung_task_timeout_secs" disables this message.
task:syz-executor.2  state:D stack:22392 pid:15949 tgid:15947 ppid:12029  flags:0x00004006
Call Trace:
 <TASK>
 context_switch kernel/sched/core.c:5400 [inline]
 __schedule+0x177f/0x49a0 kernel/sched/core.c:6727
 __schedule_loop kernel/sched/core.c:6802 [inline]
 schedule+0x149/0x260 kernel/sched/core.c:6817
 __wait_on_freeing_inode fs/inode.c:2243 [inline]
 find_inode+0x304/0x440 fs/inode.c:906
 ilookup5_nowait fs/inode.c:1420 [inline]
 ilookup5+0xa1/0x1f0 fs/inode.c:1449
 iget5_locked+0x37/0x280 fs/inode.c:1230
 btrfs_iget_locked fs/btrfs/inode.c:5563 [inline]
 btrfs_iget_path+0x147/0x1540 fs/btrfs/inode.c:5580
 add_conflicting_inode fs/btrfs/tree-log.c:5585 [inline]
 copy_inode_items_to_log fs/btrfs/tree-log.c:5856 [inline]
 btrfs_log_inode+0x1ae5/0x43f0 fs/btrfs/tree-log.c:6520
 btrfs_log_inode_parent+0xab4/0x1100 fs/btrfs/tree-log.c:7007
 btrfs_log_new_name+0x55d/0x970 fs/btrfs/tree-log.c:7512
 btrfs_rename fs/btrfs/inode.c:9218 [inline]
 btrfs_rename2+0x2463/0x2d90 fs/btrfs/inode.c:9262
 vfs_rename+0xbdb/0xf00 fs/namei.c:4883
 do_renameat2+0xd94/0x13f0 fs/namei.c:5040
 __do_sys_rename fs/namei.c:5087 [inline]
 __se_sys_rename fs/namei.c:5085 [inline]
 __x64_sys_rename+0x86/0xa0 fs/namei.c:5085
 do_syscall_64+0xf9/0x240
 entry_SYSCALL_64_after_hwframe+0x6f/0x77
RIP: 0033:0x7f999d47dda9
RSP: 002b:00007f999e24e0c8 EFLAGS: 00000246 ORIG_RAX: 0000000000000052
RAX: ffffffffffffffda RBX: 00007f999d5abf80 RCX: 00007f999d47dda9
RDX: 0000000000000000 RSI: 0000000020000140 RDI: 0000000020000100
RBP: 00007f999d4ca47a R08: 0000000000000000 R09: 0000000000000000
R10: 0000000000000000 R11: 0000000000000246 R12: 0000000000000000
R13: 000000000000000b R14: 00007f999d5abf80 R15: 00007ffef31ee738
 </TASK>

Showing all locks held in the system:
1 lock held by khungtaskd/29:
 #0: 
ffffffff8e130be0 (rcu_read_lock){....}-{1:2}, at: rcu_lock_acquire include/linux/rcupdate.h:298 [inline]
ffffffff8e130be0 (rcu_read_lock){....}-{1:2}, at: rcu_read_lock include/linux/rcupdate.h:750 [inline]
ffffffff8e130be0 (rcu_read_lock){....}-{1:2}, at: debug_show_all_locks+0x55/0x2a0 kernel/locking/lockdep.c:6614
3 locks held by kworker/u4:6/1091:
 #0: ffff8880b953c918 (&rq->__lock){-.-.}-{2:2}, at: raw_spin_rq_lock_nested+0x2a/0x140 kernel/sched/core.c:559
 #1: ffff8880b9428988 (&per_cpu_ptr(group->pcpu, cpu)->seq){-.-.}-{0:0}, at: psi_task_switch+0x441/0x770 kernel/sched/psi.c:988
 #2: ffff88801fcc68d8 (&lo->lo_work_lock){..-.}-{2:2}, at: spin_lock_irq include/linux/spinlock.h:376 [inline]
 #2: ffff88801fcc68d8 (&lo->lo_work_lock){..-.}-{2:2}, at: loop_process_work+0x1994/0x1e60 drivers/block/loop.c:1947
2 locks held by getty/4805:
 #0: ffff88802a6730a0 (&tty->ldisc_sem){++++}-{0:0}, at: tty_ldisc_ref_wait+0x25/0x70 drivers/tty/tty_ldisc.c:243
 #1: ffffc900031332f0 (&ldata->atomic_read_lock){+.+.}-{3:3}, at: n_tty_read+0x6b4/0x1e10 drivers/tty/n_tty.c:2201
2 locks held by kworker/1:3/5140:
 #0: ffff888014c7a538 ((wq_completion)rcu_gp){+.+.}-{0:0}, at: process_one_work kernel/workqueue.c:2608 [inline]
 #0: ffff888014c7a538 ((wq_completion)rcu_gp){+.+.}-{0:0}, at: process_scheduled_works+0x825/0x1420 kernel/workqueue.c:2706
 #1: ffffc90004937d20 ((work_completion)(&rew->rew_work)){+.+.}-{0:0}, at: process_one_work kernel/workqueue.c:2608 [inline]
 #1: ffffc90004937d20 ((work_completion)(&rew->rew_work)){+.+.}-{0:0}, at: process_scheduled_works+0x825/0x1420 kernel/workqueue.c:2706
1 lock held by syz-executor.3/8253:
 #0: ffffffff8e136578 (rcu_state.exp_mutex){+.+.}-{3:3}, at: exp_funnel_lock kernel/rcu/tree_exp.h:324 [inline]
 #0: ffffffff8e136578 (rcu_state.exp_mutex){+.+.}-{3:3}, at: synchronize_rcu_expedited+0x46c/0x890 kernel/rcu/tree_exp.h:995
1 lock held by syz-executor.2/15947:
 #0: ffff88807c82e378 (btrfs_trans_num_writers){++++}-{0:0}, at: join_transaction+0x405/0xcf0 fs/btrfs/transaction.c:292
7 locks held by syz-executor.2/15949:
 #0: ffff888078830420 (sb_writers#13){.+.+}-{0:0}, at: mnt_want_write+0x3f/0x90 fs/namespace.c:409
 #1: ffff888035196720 (&type->i_mutex_dir_key#8/1){+.+.}-{3:3}, at: inode_lock_nested include/linux/fs.h:839 [inline]
 #1: ffff888035196720 (&type->i_mutex_dir_key#8/1){+.+.}-{3:3}, at: lock_rename fs/namei.c:3069 [inline]
 #1: ffff888035196720 (&type->i_mutex_dir_key#8/1){+.+.}-{3:3}, at: do_renameat2+0x62c/0x13f0 fs/namei.c:4975
 #2: ffff88803898de38 (&sb->s_type->i_mutex_key#20/4){+.+.}-{3:3}, at: vfs_rename+0x6a2/0xf00 fs/namei.c:4854
 #3: ffff888078830610 (sb_internal#2){.+.+}-{0:0}, at: btrfs_rename fs/btrfs/inode.c:9136 [inline]
 #3: ffff888078830610 (sb_internal#2){.+.+}-{0:0}, at: btrfs_rename2+0x17fc/0x2d90 fs/btrfs/inode.c:9262
 #4: ffff88807c82e378 (btrfs_trans_num_writers){++++}-{0:0}, at: join_transaction+0x405/0xcf0 fs/btrfs/transaction.c:292
 #5: ffff88807c82e3a0 (btrfs_trans_num_extwriters){++++}-{0:0}, at: join_transaction+0x405/0xcf0 fs/btrfs/transaction.c:292
 #6: ffff88803898da98 (&ei->log_mutex){+.+.}-{3:3}, at: btrfs_log_inode+0x4c4/0x43f0 fs/btrfs/tree-log.c:6409
1 lock held by btrfs-transacti/16014:
 #0: ffff88807c82c7c0 (&fs_info->transaction_kthread_mutex){+.+.}-{3:3}, at: transaction_kthread+0x100/0x500 fs/btrfs/disk-io.c:1576
1 lock held by udevd/16423:

=============================================

NMI backtrace for cpu 1
CPU: 1 PID: 29 Comm: khungtaskd Not tainted 6.8.0-rc7-syzkaller-00231-g09e5c48fea17 #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 02/29/2024
Call Trace:
 <TASK>
 __dump_stack lib/dump_stack.c:88 [inline]
 dump_stack_lvl+0x1e7/0x2e0 lib/dump_stack.c:106
 nmi_cpu_backtrace+0x49c/0x4d0 lib/nmi_backtrace.c:113
 nmi_trigger_cpumask_backtrace+0x198/0x320 lib/nmi_backtrace.c:62
 trigger_all_cpu_backtrace include/linux/nmi.h:160 [inline]
 check_hung_uninterruptible_tasks kernel/hung_task.c:222 [inline]
 watchdog+0xfaf/0xff0 kernel/hung_task.c:379
 kthread+0x2ef/0x390 kernel/kthread.c:388
 ret_from_fork+0x4b/0x80 arch/x86/kernel/process.c:147
 ret_from_fork_asm+0x1b/0x30 arch/x86/entry/entry_64.S:243
 </TASK>
Sending NMI from CPU 1 to CPUs 0:
NMI backtrace for cpu 0
CPU: 0 PID: 1091 Comm: kworker/u4:6 Not tainted 6.8.0-rc7-syzkaller-00231-g09e5c48fea17 #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 02/29/2024
Workqueue: bat_events batadv_nc_worker
RIP: 0010:kasan_check_range+0x5/0x290 mm/kasan/generic.c:188
Code: 8d e8 5f 07 e6 ff 90 0f 0b 66 2e 0f 1f 84 00 00 00 00 00 66 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 66 0f 1f 00 55 <41> 57 41 56 41 54 53 b0 01 48 85 f6 0f 84 a0 01 00 00 4c 8d 04 37
RSP: 0018:ffffc9000448f920 EFLAGS: 00000046
RAX: 000000000000001b RBX: 00000000000006ca RCX: ffffffff8171256d
RDX: 0000000000000000 RSI: 0000000000000008 RDI: ffffffff92c584f8
RBP: 00000000ffffffff R08: ffffffff92c58427 R09: 1ffffffff258b084
R10: dffffc0000000000 R11: fffffbfff258b085 R12: 0000000000000000
R13: ffff88802214c660 R14: 0000000000000000 R15: ffff88802214c660
FS:  0000000000000000(0000) GS:ffff8880b9400000(0000) knlGS:0000000000000000
CS:  0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: 00007f7131465308 CR3: 000000000df32000 CR4: 00000000003506f0
DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000
DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400
Call Trace:
 <NMI>
 </NMI>
 <TASK>
 instrument_atomic_read include/linux/instrumented.h:68 [inline]
 _test_bit include/asm-generic/bitops/instrumented-non-atomic.h:141 [inline]
 hlock_class kernel/locking/lockdep.c:228 [inline]
 check_wait_context kernel/locking/lockdep.c:4798 [inline]
 __lock_acquire+0x86d/0x1fd0 kernel/locking/lockdep.c:5087
 lock_acquire+0x1e3/0x530 kernel/locking/lockdep.c:5754
 rcu_lock_acquire include/linux/rcupdate.h:298 [inline]
 rcu_read_lock include/linux/rcupdate.h:750 [inline]
 batadv_nc_purge_orig_hash net/batman-adv/network-coding.c:408 [inline]
 batadv_nc_worker+0xec/0x610 net/batman-adv/network-coding.c:719
 process_one_work kernel/workqueue.c:2633 [inline]
 process_scheduled_works+0x913/0x1420 kernel/workqueue.c:2706
 worker_thread+0xa5f/0x1000 kernel/workqueue.c:2787
 kthread+0x2ef/0x390 kernel/kthread.c:388
 ret_from_fork+0x4b/0x80 arch/x86/kernel/process.c:147
 ret_from_fork_asm+0x1b/0x30 arch/x86/entry/entry_64.S:243
 </TASK>

Crashes (6):
Time Kernel Commit Syzkaller Config Log Report Syz repro C repro VM info Assets (help?) Manager Title
2024/03/10 04:32 upstream 09e5c48fea17 6ee49f2e .config console log report info [disk image] [vmlinux] [kernel image] ci2-upstream-fs INFO: task hung in btrfs_commit_transaction
2024/01/02 19:04 upstream 610a9b8f49fb fb427a07 .config console log report info [disk image] [vmlinux] [kernel image] ci2-upstream-fs INFO: task hung in btrfs_commit_transaction
2023/12/27 04:43 upstream fbafc3e621c3 fb427a07 .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-kasan-gce-selinux-root INFO: task hung in btrfs_commit_transaction
2023/12/25 12:35 upstream 861deac3b092 fb427a07 .config console log report info [disk image] [vmlinux] [kernel image] ci2-upstream-fs INFO: task hung in btrfs_commit_transaction
2023/11/29 22:03 upstream 3b47bc037bd4 6e78f9ce .config console log report info [disk image] [vmlinux] [kernel image] ci2-upstream-fs INFO: task hung in btrfs_commit_transaction
2024/05/09 22:20 linux-next 704ba27ac555 de979bc2 .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-linux-next-kasan-gce-root INFO: task hung in btrfs_commit_transaction
* Struck through repros no longer work on HEAD.