Bluetooth: hci0: Injecting HCI hardware error event Bluetooth: hci0: hardware error 0x00 ------------[ cut here ]------------ refcount_t: underflow; use-after-free. WARNING: CPU: 3 PID: 63 at lib/refcount.c:28 refcount_warn_saturate+0x14a/0x210 lib/refcount.c:28 Modules linked in: CPU: 3 UID: 0 PID: 63 Comm: kworker/u33:0 Not tainted 6.16.0-rc7-syzkaller #0 PREEMPT(full) Hardware name: QEMU Standard PC (Q35 + ICH9, 2009), BIOS 1.16.3-debian-1.16.3-2~bpo12+1 04/01/2014 Workqueue: hci0 hci_error_reset RIP: 0010:refcount_warn_saturate+0x14a/0x210 lib/refcount.c:28 Code: ff 89 de e8 38 f2 e0 fc 84 db 0f 85 66 ff ff ff e8 4b f7 e0 fc c6 05 76 aa b6 0b 01 90 48 c7 c7 a0 1f 15 8c e8 d7 fe 9f fc 90 <0f> 0b 90 90 e9 43 ff ff ff e8 28 f7 e0 fc 0f b6 1d 51 aa b6 0b 31 RSP: 0018:ffffc90000b0f908 EFLAGS: 00010282 RAX: 0000000000000000 RBX: 0000000000000000 RCX: ffffffff817af1a8 RDX: ffff888022390000 RSI: ffffffff817af1b5 RDI: 0000000000000001 RBP: ffff88802b8eac78 R08: 0000000000000001 R09: 0000000000000000 R10: 0000000000000000 R11: 0000000000000001 R12: ffff888048789400 R13: ffff88802b8eac78 R14: ffffffff8609d0d0 R15: ffffffff908c3d20 FS: 0000000000000000(0000) GS:ffff8880d6a20000(0000) knlGS:0000000000000000 CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033 CR2: 0000200000000208 CR3: 000000005111d000 CR4: 0000000000352ef0 DR0: 0000000000004e53 DR1: 0000000000000000 DR2: 0000000000000000 DR3: 0000000000000000 DR6: 00000000ffff0ff0 DR7: 0000000000000400 Call Trace: __refcount_sub_and_test include/linux/refcount.h:400 [inline] __refcount_dec_and_test include/linux/refcount.h:432 [inline] refcount_dec_and_test include/linux/refcount.h:450 [inline] kref_put include/linux/kref.h:64 [inline] klist_dec_and_del lib/klist.c:206 [inline] klist_put+0x11b/0x1b0 lib/klist.c:217 klist_del lib/klist.c:230 [inline] klist_remove+0x13f/0x2e0 lib/klist.c:249 device_move+0x12d/0x10d0 drivers/base/core.c:4618 hci_conn_del_sysfs+0x81/0x180 net/bluetooth/hci_sysfs.c:75 hci_conn_cleanup net/bluetooth/hci_conn.c:175 [inline] hci_conn_del+0x566/0xdc0 net/bluetooth/hci_conn.c:1173 hci_conn_hash_flush+0x186/0x260 net/bluetooth/hci_conn.c:2561 hci_dev_close_sync+0x602/0x11d0 net/bluetooth/hci_sync.c:5294 hci_dev_do_close+0x2e/0x90 net/bluetooth/hci_core.c:501 hci_error_reset+0xbf/0x320 net/bluetooth/hci_core.c:1034 process_one_work+0x9cf/0x1b70 kernel/workqueue.c:3238 process_scheduled_works kernel/workqueue.c:3321 [inline] worker_thread+0x6c8/0xf10 kernel/workqueue.c:3402 kthread+0x3c5/0x780 kernel/kthread.c:464 ret_from_fork+0x5d4/0x6f0 arch/x86/kernel/process.c:148 ret_from_fork_asm+0x1a/0x30 arch/x86/entry/entry_64.S:245