[ OK ] Reached target Graphical Interface. Starting Update UTMP about System Runlevel Changes... Starting Load/Save RF Kill Switch Status... [ OK ] Started Load/Save RF Kill Switch Status. [ OK ] Started Update UTMP about System Runlevel Changes. Debian GNU/Linux 9 syzkaller ttyS0 Warning: Permanently added '10.128.0.151' (ECDSA) to the list of known hosts. executing program syzkaller login: [ 35.787512] BTRFS: device fsid 24c7a497-3402-47dd-bef8-82358f5f30e0 devid 1 transid 8 /dev/loop0 [ 35.805143] BTRFS info (device loop0): using free space tree [ 35.815195] BTRFS info (device loop0): has skinny extents [ 35.871412] [ 35.873052] ====================================================== [ 35.879402] WARNING: possible circular locking dependency detected [ 35.886057] 4.19.211-syzkaller #0 Not tainted [ 35.890531] ------------------------------------------------------ [ 35.897098] syz-executor978/8104 is trying to acquire lock: [ 35.902788] 000000009e342d63 (&fs_info->qgroup_ioctl_lock){+.+.}, at: btrfs_remove_qgroup+0xae/0x770 [ 35.912057] [ 35.912057] but task is already holding lock: [ 35.918015] 000000007a81c44c (sb_internal#2){.+.+}, at: start_transaction+0xa37/0xf90 [ 35.925984] [ 35.925984] which lock already depends on the new lock. [ 35.925984] [ 35.934283] [ 35.934283] the existing dependency chain (in reverse order) is: [ 35.941885] [ 35.941885] -> #1 (sb_internal#2){.+.+}: [ 35.947418] start_transaction+0xa37/0xf90 [ 35.952416] btrfs_quota_enable+0x169/0x10b0 [ 35.957338] btrfs_ioctl+0x622c/0x76d0 [ 35.961722] do_vfs_ioctl+0xcdb/0x12e0 [ 35.966106] ksys_ioctl+0x9b/0xc0 [ 35.970165] __x64_sys_ioctl+0x6f/0xb0 [ 35.974587] do_syscall_64+0xf9/0x620 [ 35.978902] entry_SYSCALL_64_after_hwframe+0x49/0xbe [ 35.984591] [ 35.984591] -> #0 (&fs_info->qgroup_ioctl_lock){+.+.}: [ 35.991346] __mutex_lock+0xd7/0x1190 [ 35.995651] btrfs_remove_qgroup+0xae/0x770 [ 36.000560] btrfs_ioctl+0x661c/0x76d0 [ 36.004946] do_vfs_ioctl+0xcdb/0x12e0 [ 36.009330] ksys_ioctl+0x9b/0xc0 [ 36.013541] __x64_sys_ioctl+0x6f/0xb0 [ 36.017929] do_syscall_64+0xf9/0x620 [ 36.022232] entry_SYSCALL_64_after_hwframe+0x49/0xbe [ 36.027915] [ 36.027915] other info that might help us debug this: [ 36.027915] [ 36.036037] Possible unsafe locking scenario: [ 36.036037] [ 36.042133] CPU0 CPU1 [ 36.046774] ---- ---- [ 36.051416] lock(sb_internal#2); [ 36.054935] lock(&fs_info->qgroup_ioctl_lock); [ 36.062191] lock(sb_internal#2); [ 36.068227] lock(&fs_info->qgroup_ioctl_lock); [ 36.073741] [ 36.073741] *** DEADLOCK *** [ 36.073741] [ 36.079792] 2 locks held by syz-executor978/8104: [ 36.084608] #0: 00000000c0e4bdae (sb_writers#11){.+.+}, at: mnt_want_write_file+0x63/0x1d0 [ 36.093089] #1: 000000007a81c44c (sb_internal#2){.+.+}, at: start_transaction+0xa37/0xf90 [ 36.101482] [ 36.101482] stack backtrace: [ 36.105960] CPU: 1 PID: 8104 Comm: syz-executor978 Not tainted 4.19.211-syzkaller #0 [ 36.113818] Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 10/26/2022 [ 36.123148] Call Trace: [ 36.125723] dump_stack+0x1fc/0x2ef [ 36.129343] print_circular_bug.constprop.0.cold+0x2d7/0x41e [ 36.135126] __lock_acquire+0x30c9/0x3ff0 [ 36.139260] ? mark_held_locks+0xf0/0xf0 [ 36.143299] ? __bfs.part.0+0x1ce/0x450 [ 36.147261] lock_acquire+0x170/0x3c0 [ 36.151044] ? btrfs_remove_qgroup+0xae/0x770 [ 36.155528] ? btrfs_remove_qgroup+0xae/0x770 [ 36.160001] __mutex_lock+0xd7/0x1190 [ 36.163781] ? btrfs_remove_qgroup+0xae/0x770 [ 36.168259] ? btrfs_record_root_in_trans+0x137/0x190 [ 36.173434] ? btrfs_remove_qgroup+0xae/0x770 [ 36.177936] ? mutex_trylock+0x1a0/0x1a0 [ 36.181979] ? record_root_in_trans.isra.0+0x2db/0x400 [ 36.187238] ? __mutex_unlock_slowpath+0xea/0x610 [ 36.192062] ? wait_for_completion_io+0x10/0x10 [ 36.196712] btrfs_remove_qgroup+0xae/0x770 [ 36.201019] ? btrfs_record_root_in_trans+0x13c/0x190 [ 36.206187] ? btrfs_create_qgroup+0x270/0x270 [ 36.210756] ? start_transaction+0x239/0xf90 [ 36.215151] btrfs_ioctl+0x661c/0x76d0 [ 36.219024] ? page_remove_rmap.part.0+0x2f/0x2c0 [ 36.223847] ? do_raw_spin_unlock+0x171/0x230 [ 36.228321] ? btrfs_ioctl_get_supported_features+0x50/0x50 [ 36.234025] ? wp_page_copy+0x1203/0x2c40 [ 36.238163] ? follow_pte_pmd+0x60/0x60 [ 36.242125] ? do_wp_page+0x2dc/0x2210 [ 36.245993] ? finish_mkwrite_fault+0x640/0x640 [ 36.250644] ? __handle_mm_fault+0x15f6/0x41c0 [ 36.255208] ? mark_held_locks+0xf0/0xf0 [ 36.259249] ? __handle_mm_fault+0xf34/0x41c0 [ 36.263725] ? btrfs_ioctl_get_supported_features+0x50/0x50 [ 36.269415] do_vfs_ioctl+0xcdb/0x12e0 [ 36.273294] ? ioctl_preallocate+0x200/0x200 [ 36.277697] ? __do_page_fault+0x6d1/0xd60 [ 36.281939] ? lock_downgrade+0x720/0x720 [ 36.286072] ? up_read+0x17/0x110 [ 36.290324] ? __do_page_fault+0x180/0xd60 [ 36.294541] ksys_ioctl+0x9b/0xc0 [ 36.297988] __x64_sys_ioctl+0x6f/0xb0 [ 36.301859] ? lockdep_hardirqs_on+0x3a8/0x5c0 [ 36.306422] do_syscall_64+0xf9/0x620 [ 36.310215] entry_SYSCALL_64_after_hwframe+0x49/0xbe [ 36.315381] RIP: 0033:0x7fd4ad269259 [ 36.319077] Code: 28 00 00 00 75 05 48 83 c4 28 c3 e8 e1 14 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 c0 ff ff ff f7 d8 64 89 01 48 [ 36.337964] RSP: 002b:00007ffe1ff66398 EFLAGS: 00000246 ORIG_RAX: 0000000000000010 [ 36.345662] RAX: ffffffffffffffda RBX: 0030656c69662f2e RCX: 00007fd4ad269259 [ 36.352913] RDX: 00000000200011c0 RSI: 000000004010942a RDI: 0000000000000004 [ 36.360246] RBP: 0000000000000000 R08: 00007fd4ad2dcec0 R09: 00007fd4ad2dcec0 executing program [ 36.367496] R10: 00007fd4ad2dcec0 R11: 0000000000000246 R12: 00007ffe1ff663c0 [ 36.374742] R13: 0000000000000000 R14: 431bde82d7b634db R15: 0000000000000000 [ 36.392481] BTRFS error (device loop0): fail to start transaction for status update: -28 executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program