program: r0 = syz_init_net_socket$bt_l2cap(0x1f, 0x2, 0x0) connect$bt_l2cap(r0, &(0x7f0000000080)={0x1f, 0x0, @fixed={'\xaa\xaa\xaa\xaa\xaa', 0x10}, 0x7ff}, 0xe) r1 = syz_init_net_socket$bt_hidp(0x1f, 0x3, 0x6) ioctl$sock_bt_hidp_HIDPCONNADD(r1, 0x400448c8, &(0x7f0000000280)={r0, r0, 0xc, 0x1, &(0x7f0000000340)='\x00', 0x9, 0x1, 0x457, 0x9, 0x9, 0x1, 0x1, 'syz1\x00'}) r2 = syz_init_net_socket$bt_hci(0x1f, 0x3, 0x1) ioctl$sock_bt_hci(r2, 0x400448ca, 0x0) bpf$PROG_LOAD(0x5, &(0x7f0000000440)={0xa, 0x6, &(0x7f0000000000)=@framed={{0x5, 0x0, 0x0, 0x0, 0x0, 0x6b, 0x11, 0xb9}, [@func={0x85, 0x0, 0x1, 0x0, 0x2}, @call={0x85, 0x0, 0x0, 0x76}, @exit], {0x95, 0x0, 0x5a5}}, &(0x7f0000000080)='GPL\x00', 0x5, 0x29e, &(0x7f000000cf3d)=""/195, 0x0, 0x0, '\x00', 0x0, @fallback, 0xffffffffffffffff, 0x6}, 0x70) [ 85.063780][ T5318] hid-multitouch 0005:0457:0009.0002: unknown main item tag 0x0 [ 85.107526][ T5318] hid-multitouch 0005:0457:0009.0002: hidraw1: BLUETOOTH HID v0.09 Device [syz1] on aa:aa:aa:aa:aa:aa [ 85.147239][ T5321] [ 85.148350][ T5321] ====================================================== [ 85.151299][ T5321] WARNING: possible circular locking dependency detected [ 85.154907][ T5321] syzkaller #0 Not tainted [ 85.156939][ T5321] ------------------------------------------------------ [ 85.159610][ T5321] syz.0.0/5321 is trying to acquire lock: [ 85.162099][ T5321] ffff888038bbb040 ((work_completion)(&(&conn->info_timer)->work)){+.+.}-{0:0}, at: __flush_work+0x100/0xc50 [ 85.167727][ T5321] [ 85.167727][ T5321] but task is already holding lock: [ 85.171001][ T5321] ffff888038bbb338 (&conn->lock#2){+.+.}-{4:4}, at: l2cap_conn_del+0x7b/0x5b0 [ 85.174929][ T5321] [ 85.174929][ T5321] which lock already depends on the new lock. [ 85.174929][ T5321] [ 85.179138][ T5321] [ 85.179138][ T5321] the existing dependency chain (in reverse order) is: [ 85.183229][ T5321] [ 85.183229][ T5321] -> #1 (&conn->lock#2){+.+.}-{4:4}: [ 85.186720][ T5321] __mutex_lock+0x19f/0x1300 [ 85.188828][ T5321] l2cap_info_timeout+0x60/0xa0 [ 85.191166][ T5321] process_scheduled_works+0xaec/0x17a0 [ 85.193788][ T5321] worker_thread+0xda6/0x1360 [ 85.196036][ T5321] kthread+0x388/0x470 [ 85.197935][ T5321] ret_from_fork+0x51e/0xb90 [ 85.200045][ T5321] ret_from_fork_asm+0x1a/0x30 [ 85.202521][ T5321] [ 85.202521][ T5321] -> #0 ((work_completion)(&(&conn->info_timer)->work)){+.+.}-{0:0}: [ 85.207069][ T5321] __lock_acquire+0x15a5/0x2cf0 [ 85.209370][ T5321] lock_acquire+0x106/0x330 [ 85.211625][ T5321] __flush_work+0x700/0xc50 [ 85.213762][ T5321] __cancel_work_sync+0xbe/0x110 [ 85.216239][ T5321] l2cap_conn_del+0x402/0x5b0 [ 85.218607][ T5321] hci_conn_hash_flush+0x10d/0x260 [ 85.221191][ T5321] hci_dev_close_sync+0x821/0x10e0 [ 85.223741][ T5321] hci_dev_close+0x108/0x260 [ 85.226038][ T5321] sock_do_ioctl+0x101/0x320 [ 85.228175][ T5321] sock_ioctl+0x5c6/0x7f0 [ 85.230335][ T5321] __se_sys_ioctl+0xfc/0x170 [ 85.232415][ T5321] do_syscall_64+0x14d/0xf80 [ 85.234551][ T5321] entry_SYSCALL_64_after_hwframe+0x77/0x7f [ 85.237246][ T5321] [ 85.237246][ T5321] other info that might help us debug this: [ 85.237246][ T5321] [ 85.241468][ T5321] Possible unsafe locking scenario: [ 85.241468][ T5321] [ 85.244711][ T5321] CPU0 CPU1 [ 85.247432][ T5321] ---- ---- [ 85.250068][ T5321] lock(&conn->lock#2); [ 85.252108][ T5321] lock((work_completion)(&(&conn->info_timer)->work)); [ 85.256704][ T5321] lock(&conn->lock#2); [ 85.259591][ T5321] lock((work_completion)(&(&conn->info_timer)->work)); [ 85.262410][ T5321] [ 85.262410][ T5321] *** DEADLOCK *** [ 85.262410][ T5321] [ 85.265730][ T5321] 5 locks held by syz.0.0/5321: [ 85.267937][ T5321] #0: ffff888040a80ec0 (&hdev->req_lock){+.+.}-{4:4}, at: hci_dev_close+0x100/0x260 [ 85.272272][ T5321] #1: ffff888040a800c0 (&hdev->lock){+.+.}-{4:4}, at: hci_dev_close_sync+0x640/0x10e0 [ 85.276389][ T5321] #2: ffffffff8fd4caa8 (hci_cb_list_lock){+.+.}-{4:4}, at: hci_conn_hash_flush+0xa1/0x260 [ 85.280839][ T5321] #3: ffff888038bbb338 (&conn->lock#2){+.+.}-{4:4}, at: l2cap_conn_del+0x7b/0x5b0 [ 85.284827][ T5321] #4: ffffffff8e75df20 (rcu_read_lock){....}-{1:3}, at: __flush_work+0x100/0xc50 [ 85.288750][ T5321] [ 85.288750][ T5321] stack backtrace: [ 85.291525][ T5321] CPU: 0 UID: 0 PID: 5321 Comm: syz.0.0 Not tainted syzkaller #0 PREEMPT(full) [ 85.291540][ T5321] Hardware name: QEMU Standard PC (Q35 + ICH9, 2009), BIOS 1.16.3-debian-1.16.3-2 04/01/2014 [ 85.291547][ T5321] Call Trace: [ 85.291557][ T5321] [ 85.291589][ T5321] dump_stack_lvl+0xe8/0x150 [ 85.291624][ T5321] print_circular_bug+0x2e1/0x300 [ 85.291642][ T5321] check_noncircular+0x12e/0x150 [ 85.291659][ T5321] __lock_acquire+0x15a5/0x2cf0 [ 85.291675][ T5321] ? do_raw_spin_lock+0x12b/0x2f0 [ 85.291723][ T5321] ? __flush_work+0x100/0xc50 [ 85.291736][ T5321] lock_acquire+0x106/0x330 [ 85.291749][ T5321] ? __flush_work+0x100/0xc50 [ 85.291764][ T5321] ? __flush_work+0x100/0xc50 [ 85.291777][ T5321] __flush_work+0x700/0xc50 [ 85.291791][ T5321] ? __flush_work+0x100/0xc50 [ 85.291804][ T5321] ? __flush_work+0x100/0xc50 [ 85.291817][ T5321] ? __pfx___flush_work+0x10/0x10 [ 85.291831][ T5321] ? __pfx_wq_barrier_func+0x10/0x10 [ 85.291847][ T5321] ? __cancel_work_sync+0x5c/0x110 [ 85.291861][ T5321] __cancel_work_sync+0xbe/0x110 [ 85.291875][ T5321] l2cap_conn_del+0x402/0x5b0 [ 85.291893][ T5321] ? __pfx_l2cap_disconn_cfm+0x10/0x10 [ 85.291909][ T5321] hci_conn_hash_flush+0x10d/0x260 [ 85.291926][ T5321] hci_dev_close_sync+0x821/0x10e0 [ 85.291960][ T5321] ? __pfx_hci_dev_close_sync+0x10/0x10 [ 85.291974][ T5321] ? lockdep_hardirqs_on+0x7a/0x110 [ 85.291989][ T5321] ? enable_work+0x1fd/0x230 [ 85.292004][ T5321] hci_dev_close+0x108/0x260 [ 85.292020][ T5321] sock_do_ioctl+0x101/0x320 [ 85.292034][ T5321] ? __pfx_sock_do_ioctl+0x10/0x10 [ 85.292045][ T5321] ? do_futex+0x395/0x420 [ 85.292060][ T5321] sock_ioctl+0x5c6/0x7f0 [ 85.292074][ T5321] ? __pfx_sock_ioctl+0x10/0x10 [ 85.292086][ T5321] ? __fget_files+0x2a/0x420 [ 85.292102][ T5321] ? __fget_files+0x3a0/0x420 [ 85.292118][ T5321] ? __fget_files+0x2a/0x420 [ 85.292132][ T5321] ? bpf_lsm_file_ioctl+0x9/0x20 [ 85.292146][ T5321] ? __pfx_sock_ioctl+0x10/0x10 [ 85.292158][ T5321] __se_sys_ioctl+0xfc/0x170 [ 85.292170][ T5321] do_syscall_64+0x14d/0xf80 [ 85.292185][ T5321] ? entry_SYSCALL_64_after_hwframe+0x77/0x7f [ 85.292195][ T5321] ? trace_irq_disable+0x37/0x100 [ 85.292207][ T5321] ? clear_bhb_loop+0x40/0x90 [ 85.292218][ T5321] entry_SYSCALL_64_after_hwframe+0x77/0x7f [ 85.292229][ T5321] RIP: 0033:0x7f031459bf79 [ 85.292241][ T5321] Code: ff c3 66 2e 0f 1f 84 00 00 00 00 00 0f 1f 44 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 e8 ff ff ff f7 d8 64 89 01 48 [ 85.292251][ T5321] RSP: 002b:00007f0315530028 EFLAGS: 00000246 ORIG_RAX: 0000000000000010 [ 85.292282][ T5321] RAX: ffffffffffffffda RBX: 00007f0314815fa0 RCX: 00007f031459bf79 [ 85.292290][ T5321] RDX: 0000000000000000 RSI: 00000000400448ca RDI: 0000000000000006 [ 85.292298][ T5321] RBP: 00007f03146327e0 R08: 0000000000000000 R09: 0000000000000000 [ 85.292305][ T5321] R10: 0000000000000000 R11: 0000000000000246 R12: 0000000000000000 [ 85.292312][ T5321] R13: 00007f0314816038 R14: 00007f0314815fa0 R15: 00007ffd0df1b1c8 [ 85.292323][ T5321] [ 85.437593][ T4664] Bluetooth: hci0: command tx timeout [ 85.470256][ T5328] fido_id[5328]: Failed to open report descriptor at '/sys/devices/virtual/bluetooth/hci0/hci0:200/report_descriptor': No such file or directory [ 87.464772][ T4664] Bluetooth: hci0: command tx timeout [ 89.544665][ T4664] Bluetooth: hci0: command tx timeout [ 91.708421][ T1354] cfg80211: failed to load regulatory.db