Starting Load/Save RF Kill Switch Status... [ OK ] Started Load/Save RF Kill Switch Status. Debian GNU/Linux 9 syzkaller ttyS0 Warning: Permanently added '10.128.0.158' (ECDSA) to the list of known hosts. executing program syzkaller login: [ 57.153481][ T8426] [ 57.155920][ T8426] ====================================================== [ 57.163073][ T8426] WARNING: possible circular locking dependency detected [ 57.170183][ T8426] 5.13.0-rc4-syzkaller #0 Not tainted [ 57.175738][ T8426] ------------------------------------------------------ [ 57.182817][ T8426] syz-executor102/8426 is trying to acquire lock: [ 57.189207][ T8426] ffff8881452dba20 (&bdev->bd_mutex){+.+.}-{3:3}, at: del_gendisk+0x24b/0xa00 [ 57.198165][ T8426] [ 57.198165][ T8426] but task is already holding lock: [ 57.205593][ T8426] ffffffff8ca6da28 (loop_ctl_mutex){+.+.}-{3:3}, at: loop_control_ioctl+0x7b/0x4f0 [ 57.214879][ T8426] [ 57.214879][ T8426] which lock already depends on the new lock. [ 57.214879][ T8426] [ 57.225353][ T8426] [ 57.225353][ T8426] the existing dependency chain (in reverse order) is: [ 57.234350][ T8426] [ 57.234350][ T8426] -> #1 (loop_ctl_mutex){+.+.}-{3:3}: [ 57.241893][ T8426] __mutex_lock+0x139/0x10c0 [ 57.247006][ T8426] lo_open+0x1a/0x130 [ 57.251488][ T8426] __blkdev_get+0x182/0xa30 [ 57.256665][ T8426] blkdev_get_by_dev+0x200/0x660 [ 57.262187][ T8426] blkdev_open+0x154/0x2b0 [ 57.267101][ T8426] do_dentry_open+0x4b9/0x11b0 [ 57.272366][ T8426] path_openat+0x1c0e/0x27e0 [ 57.277456][ T8426] do_filp_open+0x190/0x3d0 [ 57.282457][ T8426] do_sys_openat2+0x16d/0x420 [ 57.288246][ T8426] __x64_sys_open+0x119/0x1c0 [ 57.293680][ T8426] do_syscall_64+0x3a/0xb0 [ 57.298593][ T8426] entry_SYSCALL_64_after_hwframe+0x44/0xae [ 57.305175][ T8426] [ 57.305175][ T8426] -> #0 (&bdev->bd_mutex){+.+.}-{3:3}: [ 57.314374][ T8426] __lock_acquire+0x2a17/0x5230 [ 57.319826][ T8426] lock_acquire+0x1ab/0x740 [ 57.325004][ T8426] __mutex_lock+0x139/0x10c0 [ 57.330093][ T8426] del_gendisk+0x24b/0xa00 [ 57.335011][ T8426] loop_control_ioctl+0x40d/0x4f0 [ 57.340640][ T8426] __x64_sys_ioctl+0x193/0x200 [ 57.346191][ T8426] do_syscall_64+0x3a/0xb0 [ 57.351235][ T8426] entry_SYSCALL_64_after_hwframe+0x44/0xae [ 57.357646][ T8426] [ 57.357646][ T8426] other info that might help us debug this: [ 57.357646][ T8426] [ 57.367854][ T8426] Possible unsafe locking scenario: [ 57.367854][ T8426] [ 57.375398][ T8426] CPU0 CPU1 [ 57.381005][ T8426] ---- ---- [ 57.386356][ T8426] lock(loop_ctl_mutex); [ 57.390746][ T8426] lock(&bdev->bd_mutex); [ 57.397653][ T8426] lock(loop_ctl_mutex); [ 57.404648][ T8426] lock(&bdev->bd_mutex); [ 57.409042][ T8426] [ 57.409042][ T8426] *** DEADLOCK *** [ 57.409042][ T8426] [ 57.417157][ T8426] 1 lock held by syz-executor102/8426: [ 57.422588][ T8426] #0: ffffffff8ca6da28 (loop_ctl_mutex){+.+.}-{3:3}, at: loop_control_ioctl+0x7b/0x4f0 [ 57.432400][ T8426] [ 57.432400][ T8426] stack backtrace: [ 57.438265][ T8426] CPU: 0 PID: 8426 Comm: syz-executor102 Not tainted 5.13.0-rc4-syzkaller #0 [ 57.447175][ T8426] Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011 [ 57.457220][ T8426] Call Trace: [ 57.460475][ T8426] dump_stack+0x141/0x1d7 [ 57.464797][ T8426] check_noncircular+0x25f/0x2e0 [ 57.469711][ T8426] ? print_circular_bug+0x1e0/0x1e0 [ 57.474883][ T8426] ? lockdep_lock+0xc6/0x200 [ 57.479463][ T8426] ? call_rcu_zapped+0xb0/0xb0 [ 57.484288][ T8426] ? mark_held_locks+0x9f/0xe0 [ 57.489047][ T8426] __lock_acquire+0x2a17/0x5230 [ 57.493879][ T8426] ? lockdep_hardirqs_on_prepare+0x400/0x400 [ 57.499851][ T8426] lock_acquire+0x1ab/0x740 [ 57.504342][ T8426] ? del_gendisk+0x24b/0xa00 [ 57.508921][ T8426] ? lock_release+0x720/0x720 [ 57.513576][ T8426] ? find_held_lock+0x2d/0x110 [ 57.518317][ T8426] __mutex_lock+0x139/0x10c0 [ 57.523019][ T8426] ? del_gendisk+0x24b/0xa00 [ 57.528177][ T8426] ? mutex_lock_io_nested+0xf20/0xf20 [ 57.533530][ T8426] ? del_gendisk+0x24b/0xa00 [ 57.538184][ T8426] ? __mutex_unlock_slowpath+0xe2/0x610 [ 57.543707][ T8426] ? mutex_lock_io_nested+0xf20/0xf20 [ 57.549056][ T8426] ? wait_for_completion_io+0x270/0x270 [ 57.554595][ T8426] ? __sanitizer_cov_trace_const_cmp4+0x1c/0x70 [ 57.560835][ T8426] ? kernfs_remove_by_name_ns+0x62/0xb0 [ 57.566361][ T8426] ? sysfs_remove_files+0x87/0xf0 [ 57.571362][ T8426] del_gendisk+0x24b/0xa00 [ 57.575845][ T8426] loop_control_ioctl+0x40d/0x4f0 [ 57.580847][ T8426] ? loop_lookup+0x1d0/0x1d0 [ 57.585429][ T8426] ? __sanitizer_cov_trace_const_cmp4+0x1c/0x70 [ 57.591841][ T8426] ? loop_lookup+0x1d0/0x1d0 [ 57.596409][ T8426] __x64_sys_ioctl+0x193/0x200 [ 57.601151][ T8426] do_syscall_64+0x3a/0xb0 [ 57.605556][ T8426] entry_SYSCALL_64_after_hwframe+0x44/0xae [ 57.611443][ T8426] RIP: 0033:0x43ee49 [ 57.615315][ T8426] Code: 28 c3 e8 2a 14 00 00 66 2e 0f 1f 84 00 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 73 01 c3 48 c7 c1 c0 ff ff ff f7 d8 64 89 01 48 [ 57.634903][ T8426] RSP: 002b:00007fff460cf978 EFLAGS: 00000246 ORIG_RAX: 0000000000000010 [ 57.643289][ T8426] RAX: ffffffffffffffda RBX: 0000000000400488 RCX: 000000000043ee49 [ 57.651238][ T8426] RDX: 0000000000000000 RSI: 0000000000004c81 RDI: 0000000000000003 [ 57.659706][ T8426] RBP: 0000000000402e30 R08: 0000000000000000 R09: 0000000000400488 [ 57.667657][ T8426] R10: 0000000000000000 R11: 0000000000000246 R12: 0000000000402ec0 [ 57.675778][ T8426] R13: 0000000000000000 R14: 00000000004ac018 R15: 0000000000400488