program: syz_init_net_socket$bt_l2cap(0x1f, 0x2, 0x0) (async) 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) bpf$MAP_CREATE_RINGBUF(0x0, &(0x7f0000000380)={0x1b, 0x0, 0x0, 0x40000, 0x0, 0x0, 0x3, '\x00', 0x0, 0x0}, 0x50) (async) r1 = bpf$MAP_CREATE_RINGBUF(0x0, &(0x7f0000000380)={0x1b, 0x0, 0x0, 0x40000, 0x0, 0x0, 0x3, '\x00', 0x0, 0x0}, 0x50) bpf$BPF_PROG_RAW_TRACEPOINT_LOAD(0x5, &(0x7f0000000200)={0x18, 0x13, &(0x7f0000000580)=ANY=[@ANYBLOB="180000008f000000000000000b00000018110000", @ANYRES32=r1, @ANYBLOB="0000000000000000b702000014000000b7030000000700008500000086000000bf0920000000000055090100000000009500000000000000e5000700000000004500f4fffcffffff18000000060000040000000009000000bf91200000000000b702000003000000850000002a000000b70000000000000095"], &(0x7f0000000100)='syzkaller\x00', 0xf, 0x0, 0x0, 0x41100, 0xa}, 0x94) r2 = syz_init_net_socket$bt_hidp(0x1f, 0x3, 0x6) ioctl$sock_bt_hidp_HIDPCONNADD(r2, 0x400448c8, &(0x7f0000000280)={r0, r0, 0xc, 0x1, &(0x7f0000000340)='\x00', 0x9, 0x1, 0x457, 0x9, 0x9, 0x1, 0x1, 'syz1\x00'}) r3 = syz_init_net_socket$bt_hci(0x1f, 0x3, 0x1) socket$nl_generic(0x10, 0x3, 0x10) (async) socket$nl_generic(0x10, 0x3, 0x10) ioctl$HCIINQUIRY(r3, 0x400448ca, 0x0) [ 85.211255][ T5302] Bluetooth: hci0: command tx timeout [ 85.387803][ T4680] hid-multitouch 0005:0457:0009.0002: unknown main item tag 0x0 [ 85.413473][ T4680] hid-multitouch 0005:0457:0009.0002: hidraw1: BLUETOOTH HID v0.09 Device [syz1] on aa:aa:aa:aa:aa:aa [ 85.469168][ T5324] [ 85.470287][ T5324] ====================================================== [ 85.473397][ T5324] WARNING: possible circular locking dependency detected [ 85.476548][ T5324] syzkaller #0 Not tainted [ 85.478469][ T5324] ------------------------------------------------------ [ 85.481552][ T5324] syz.0.0/5324 is trying to acquire lock: [ 85.483970][ T5324] ffff888040c81040 ((work_completion)(&(&conn->info_timer)->work)){+.+.}-{0:0}, at: __flush_work+0x100/0xc50 [ 85.488928][ T5324] [ 85.488928][ T5324] but task is already holding lock: [ 85.492196][ T5324] ffff888040c812f8 (&conn->lock#2){+.+.}-{4:4}, at: l2cap_conn_del+0x7b/0x5c0 [ 85.495825][ T5324] [ 85.495825][ T5324] which lock already depends on the new lock. [ 85.495825][ T5324] [ 85.500298][ T5324] [ 85.500298][ T5324] the existing dependency chain (in reverse order) is: [ 85.504272][ T5324] [ 85.504272][ T5324] -> #1 (&conn->lock#2){+.+.}-{4:4}: [ 85.507490][ T5324] __mutex_lock+0x19f/0x1300 [ 85.509699][ T5324] l2cap_info_timeout+0x60/0xa0 [ 85.512053][ T5324] process_scheduled_works+0xb02/0x1830 [ 85.514554][ T5324] worker_thread+0xa50/0xfc0 [ 85.516659][ T5324] kthread+0x388/0x470 [ 85.518559][ T5324] ret_from_fork+0x51e/0xb90 [ 85.520909][ T5324] ret_from_fork_asm+0x1a/0x30 [ 85.523325][ T5324] [ 85.523325][ T5324] -> #0 ((work_completion)(&(&conn->info_timer)->work)){+.+.}-{0:0}: [ 85.527883][ T5324] __lock_acquire+0x15a5/0x2cf0 [ 85.530329][ T5324] lock_acquire+0xf0/0x2e0 [ 85.532905][ T5324] __flush_work+0x700/0xc50 [ 85.535528][ T5324] __cancel_work_sync+0xbe/0x110 [ 85.537835][ T5324] l2cap_conn_del+0x40f/0x5c0 [ 85.539980][ T5324] hci_conn_hash_flush+0x10d/0x260 [ 85.542309][ T5324] hci_dev_close_sync+0x821/0x10e0 [ 85.544714][ T5324] hci_dev_close+0x108/0x260 [ 85.546679][ T5324] sock_do_ioctl+0x101/0x320 [ 85.548936][ T5324] sock_ioctl+0x5c6/0x7f0 [ 85.551087][ T5324] __se_sys_ioctl+0xfc/0x170 [ 85.553269][ T5324] do_syscall_64+0x14d/0xf80 [ 85.555336][ T5324] entry_SYSCALL_64_after_hwframe+0x77/0x7f [ 85.558146][ T5324] [ 85.558146][ T5324] other info that might help us debug this: [ 85.558146][ T5324] [ 85.562638][ T5324] Possible unsafe locking scenario: [ 85.562638][ T5324] [ 85.565804][ T5324] CPU0 CPU1 [ 85.568039][ T5324] ---- ---- [ 85.570344][ T5324] lock(&conn->lock#2); [ 85.572214][ T5324] lock((work_completion)(&(&conn->info_timer)->work)); [ 85.576078][ T5324] lock(&conn->lock#2); [ 85.578847][ T5324] lock((work_completion)(&(&conn->info_timer)->work)); [ 85.581749][ T5324] [ 85.581749][ T5324] *** DEADLOCK *** [ 85.581749][ T5324] [ 85.585357][ T5324] 5 locks held by syz.0.0/5324: [ 85.587419][ T5324] #0: ffff888011dd4ec0 (&hdev->req_lock){+.+.}-{4:4}, at: hci_dev_close+0x100/0x260 [ 85.591346][ T5324] #1: ffff888011dd40c0 (&hdev->lock){+.+.}-{4:4}, at: hci_dev_close_sync+0x640/0x10e0 [ 85.595491][ T5324] #2: ffffffff8fd5aea8 (hci_cb_list_lock){+.+.}-{4:4}, at: hci_conn_hash_flush+0xa1/0x260 [ 85.599680][ T5324] #3: ffff888040c812f8 (&conn->lock#2){+.+.}-{4:4}, at: l2cap_conn_del+0x7b/0x5c0 [ 85.603670][ T5324] #4: ffffffff8e7602e0 (rcu_read_lock){....}-{1:3}, at: __flush_work+0x100/0xc50 [ 85.607567][ T5324] [ 85.607567][ T5324] stack backtrace: [ 85.610082][ T5324] CPU: 0 UID: 0 PID: 5324 Comm: syz.0.0 Not tainted syzkaller #0 PREEMPT(full) [ 85.610095][ T5324] Hardware name: QEMU Standard PC (Q35 + ICH9, 2009), BIOS 1.16.3-debian-1.16.3-2 04/01/2014 [ 85.610102][ T5324] Call Trace: [ 85.610109][ T5324] [ 85.610115][ T5324] dump_stack_lvl+0xe8/0x150 [ 85.610133][ T5324] print_circular_bug+0x2e1/0x300 [ 85.610148][ T5324] check_noncircular+0x12e/0x150 [ 85.610164][ T5324] __lock_acquire+0x15a5/0x2cf0 [ 85.610175][ T5324] ? do_raw_spin_lock+0x12b/0x2f0 [ 85.610187][ T5324] ? do_raw_spin_unlock+0x4d/0x210 [ 85.610196][ T5324] lock_acquire+0xf0/0x2e0 [ 85.610207][ T5324] ? __flush_work+0x100/0xc50 [ 85.610221][ T5324] ? __flush_work+0x100/0xc50 [ 85.610234][ T5324] __flush_work+0x700/0xc50 [ 85.610247][ T5324] ? __flush_work+0x100/0xc50 [ 85.610259][ T5324] ? __flush_work+0x100/0xc50 [ 85.610271][ T5324] ? __pfx___flush_work+0x10/0x10 [ 85.610283][ T5324] ? __pfx_wq_barrier_func+0x10/0x10 [ 85.610297][ T5324] ? __cancel_work_sync+0x5c/0x110 [ 85.610311][ T5324] __cancel_work_sync+0xbe/0x110 [ 85.610325][ T5324] l2cap_conn_del+0x40f/0x5c0 [ 85.610338][ T5324] ? __pfx_l2cap_disconn_cfm+0x10/0x10 [ 85.610349][ T5324] hci_conn_hash_flush+0x10d/0x260 [ 85.610363][ T5324] hci_dev_close_sync+0x821/0x10e0 [ 85.610375][ T5324] ? __pfx_hci_dev_close_sync+0x10/0x10 [ 85.610384][ T5324] ? lockdep_hardirqs_on+0x7a/0x110 [ 85.610397][ T5324] ? enable_work+0x1fd/0x230 [ 85.610412][ T5324] hci_dev_close+0x108/0x260 [ 85.610423][ T5324] sock_do_ioctl+0x101/0x320 [ 85.610438][ T5324] ? __pfx_sock_do_ioctl+0x10/0x10 [ 85.610450][ T5324] ? do_futex+0x395/0x420 [ 85.610464][ T5324] sock_ioctl+0x5c6/0x7f0 [ 85.610476][ T5324] ? __pfx_sock_ioctl+0x10/0x10 [ 85.610489][ T5324] ? __fget_files+0x2a/0x420 [ 85.610501][ T5324] ? __fget_files+0x3a0/0x420 [ 85.610511][ T5324] ? __fget_files+0x2a/0x420 [ 85.610522][ T5324] ? bpf_lsm_file_ioctl+0x9/0x20 [ 85.610532][ T5324] ? __pfx_sock_ioctl+0x10/0x10 [ 85.610544][ T5324] __se_sys_ioctl+0xfc/0x170 [ 85.610559][ T5324] do_syscall_64+0x14d/0xf80 [ 85.610573][ T5324] ? trace_irq_disable+0x3b/0x150 [ 85.610586][ T5324] ? entry_SYSCALL_64_after_hwframe+0x77/0x7f [ 85.610595][ T5324] ? clear_bhb_loop+0x40/0x90 [ 85.610605][ T5324] entry_SYSCALL_64_after_hwframe+0x77/0x7f [ 85.610615][ T5324] RIP: 0033:0x7f2ef179c629 [ 85.610625][ T5324] 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.610634][ T5324] RSP: 002b:00007f2ef26f8028 EFLAGS: 00000246 ORIG_RAX: 0000000000000010 [ 85.610645][ T5324] RAX: ffffffffffffffda RBX: 00007f2ef1a16090 RCX: 00007f2ef179c629 [ 85.610651][ T5324] RDX: 0000000000000000 RSI: 00000000400448ca RDI: 000000000000000a [ 85.610658][ T5324] RBP: 00007f2ef1832b39 R08: 0000000000000000 R09: 0000000000000000 [ 85.610664][ T5324] R10: 0000000000000000 R11: 0000000000000246 R12: 0000000000000000 [ 85.610669][ T5324] R13: 00007f2ef1a16128 R14: 00007f2ef1a16090 R15: 00007ffe29f86388 [ 85.610678][ T5324] [ 85.807266][ T5331] fido_id[5331]: Failed to open report descriptor at '/sys/devices/virtual/bluetooth/hci0/hci0:200/report_descriptor': No such file or directory [ 87.220423][ T4667] Bluetooth: hci0: command tx timeout [ 89.302336][ T4667] Bluetooth: hci0: command tx timeout [ 91.380327][ T4667] Bluetooth: hci0: command tx timeout [ 91.868298][ T9] cfg80211: failed to load regulatory.db