possible deadlock in input_register_device (4)

Status: upstream: reported on 2026/05/14 15:22
Reported-by: syzbot+84d01e7883b798244618@syzkaller.appspotmail.com
First crash: 104d, last: 15d
Similar bugs (6)
Kernel Title Rank 🛈 Repro Cause bisect Fix bisect Count Last Reported Patched Status
linux-6.1 possible deadlock in input_register_device 4 5 532d 538d 0/3 auto-obsoleted due to no activity on 2025/06/20 09:48
linux-6.1 possible deadlock in input_register_device (3) 4 1 104d 104d 0/3 auto-obsoleted due to no activity on 2026/08/22 15:13
linux-6.1 possible deadlock in input_register_device (2) 4 1 249d 249d 0/3 auto-obsoleted due to no activity on 2026/03/30 14:59
linux-5.15 possible deadlock in input_register_device 4 3 528d 538d 0/3 auto-obsoleted due to no activity on 2025/06/24 16:34
linux-5.15 possible deadlock in input_register_device (2) 4 2 345d 393d 0/3 auto-obsoleted due to no activity on 2025/12/24 16:08
linux-5.15 possible deadlock in input_register_device (3) 4 2 230d 233d 0/3 auto-obsoleted due to no activity on 2026/04/19 03:54

Sample crash report:
hid-steam 0003:28DE:1102.000E: steam_send_report: error -19 (87 03 18 01 00)
input: Steam Controller as /devices/platform/dummy_hcd.4/usb5/5-1/5-1:0.0/0003:28DE:1102.000E/input/input19
======================================================
WARNING: possible circular locking dependency detected
syzkaller #0 Not tainted
------------------------------------------------------
kworker/0:0/7 is trying to acquire lock:
ffffffff8cf56da8 (input_mutex){+.+.}-{3:3}, at: input_register_device+0xaf4/0x10c0 drivers/input/input.c:2422

but task is already holding lock:
ffff88804f3a1ee8 (&hdev->ll_open_lock){+.+.}-{3:3}, at: hid_hw_close+0x2c/0xd0 drivers/hid/hid-core.c:2183

which lock already depends on the new lock.


the existing dependency chain (in reverse order) is:

-> #2 (&hdev->ll_open_lock){+.+.}-{3:3}:
       __mutex_lock_common+0x1e5/0x2400 kernel/locking/mutex.c:596
       __mutex_lock kernel/locking/mutex.c:729 [inline]
       mutex_lock_killable_nested+0x17/0x20 kernel/locking/mutex.c:758
       hid_hw_open+0x23/0x160 drivers/hid/hid-core.c:2157
       input_open_device+0x16d/0x2e0 drivers/input/input.c:640
       joydev_open_device drivers/input/joydev.c:207 [inline]
       joydev_open+0x42a/0x8a0 drivers/input/joydev.c:272
       chrdev_open+0x585/0x5f0 fs/char_dev.c:414
       do_dentry_open+0x7f7/0xf90 fs/open.c:826
       do_open fs/namei.c:3616 [inline]
       path_openat+0x2718/0x2fb0 fs/namei.c:3750
       do_filp_open+0x1df/0x400 fs/namei.c:3777
       do_sys_openat2+0x14b/0x500 fs/open.c:1255
       do_sys_open fs/open.c:1271 [inline]
       __do_sys_openat fs/open.c:1287 [inline]
       __se_sys_openat fs/open.c:1282 [inline]
       __x64_sys_openat+0x135/0x160 fs/open.c:1282
       do_syscall_x64 arch/x86/entry/common.c:50 [inline]
       do_syscall_64+0x4c/0xa0 arch/x86/entry/common.c:80
       entry_SYSCALL_64_after_hwframe+0x66/0xd0

-> #1 (&dev->mutex#2){+.+.}-{3:3}:
       __mutex_lock_common+0x1e5/0x2400 kernel/locking/mutex.c:596
       __mutex_lock kernel/locking/mutex.c:729 [inline]
       mutex_lock_interruptible_nested+0x17/0x20 kernel/locking/mutex.c:765
       input_register_handle+0x69/0x3c0 drivers/input/input.c:2588
       kbd_connect+0xbf/0x130 drivers/tty/vt/keyboard.c:1577
       input_attach_handler drivers/input/input.c:1046 [inline]
       input_register_device+0xd26/0x10c0 drivers/input/input.c:2429
       acpi_button_add+0x683/0xa40 drivers/acpi/button.c:579
       acpi_device_probe+0xa0/0x300 drivers/acpi/bus.c:1013
       call_driver_probe drivers/base/dd.c:-1 [inline]
       really_probe+0x276/0xc70 drivers/base/dd.c:595
       __driver_probe_device+0x1f5/0x390 drivers/base/dd.c:775
       driver_probe_device+0x4f/0x420 drivers/base/dd.c:805
       __driver_attach+0x45d/0x660 drivers/base/dd.c:1184
       bus_for_each_dev+0x182/0x1f0 drivers/base/bus.c:303
       bus_add_driver+0x324/0x5d0 drivers/base/bus.c:620
       driver_register+0x32d/0x430 drivers/base/driver.c:240
       do_one_initcall+0x272/0x730 init/main.c:1315
       do_initcall_level+0x13d/0x1f0 init/main.c:1388
       do_initcalls+0x4b/0x90 init/main.c:1404
       kernel_init_freeable+0x3d5/0x560 init/main.c:1628
       kernel_init+0x19/0x1b0 init/main.c:1519
       ret_from_fork+0x1f/0x30 arch/x86/entry/entry_64.S:287

-> #0 (input_mutex){+.+.}-{3:3}:
       check_prev_add kernel/locking/lockdep.c:3053 [inline]
       check_prevs_add kernel/locking/lockdep.c:3172 [inline]
       validate_chain kernel/locking/lockdep.c:3788 [inline]
       __lock_acquire+0x2c66/0x7b50 kernel/locking/lockdep.c:5012
       lock_acquire+0x19e/0x400 kernel/locking/lockdep.c:5623
       __mutex_lock_common+0x1e5/0x2400 kernel/locking/mutex.c:596
       __mutex_lock kernel/locking/mutex.c:729 [inline]
       mutex_lock_interruptible_nested+0x17/0x20 kernel/locking/mutex.c:765
       input_register_device+0xaf4/0x10c0 drivers/input/input.c:2422
       steam_input_register+0x9b1/0xc80 drivers/hid/hid-steam.c:469
       hid_hw_close+0xa5/0xd0 drivers/hid/hid-core.c:2185
       drop_ref+0x97/0x360 drivers/hid/hidraw.c:324
       hidraw_disconnect+0x4d/0x60 drivers/hid/hidraw.c:602
       hid_disconnect drivers/hid/hid-core.c:2097 [inline]
       hid_hw_stop+0xf6/0x1e0 drivers/hid/hid-core.c:2140
       hid_device_remove+0x227/0x340 drivers/hid/hid-core.c:-1
       __device_release_driver drivers/base/dd.c:1247 [inline]
       device_release_driver_internal+0x44c/0x710 drivers/base/dd.c:1282
       bus_remove_device+0x2dd/0x400 drivers/base/bus.c:531
       device_del+0x63f/0xa80 drivers/base/core.c:3615
       hid_remove_device drivers/hid/hid-core.c:2549 [inline]
       hid_destroy_device+0x66/0x100 drivers/hid/hid-core.c:2568
       steam_remove+0xab/0x180 drivers/hid/hid-steam.c:823
       hid_device_remove+0x227/0x340 drivers/hid/hid-core.c:-1
       __device_release_driver drivers/base/dd.c:1247 [inline]
       device_release_driver_internal+0x44c/0x710 drivers/base/dd.c:1282
       bus_remove_device+0x2dd/0x400 drivers/base/bus.c:531
       device_del+0x63f/0xa80 drivers/base/core.c:3615
       hid_remove_device drivers/hid/hid-core.c:2549 [inline]
       hid_destroy_device+0x66/0x100 drivers/hid/hid-core.c:2568
       usbhid_disconnect+0x9b/0xc0 drivers/hid/usbhid/hid-core.c:1469
       usb_unbind_interface+0x203/0x870 drivers/usb/core/driver.c:458
       __device_release_driver drivers/base/dd.c:1249 [inline]
       device_release_driver_internal+0x487/0x710 drivers/base/dd.c:1282
       bus_remove_device+0x2dd/0x400 drivers/base/bus.c:531
       device_del+0x63f/0xa80 drivers/base/core.c:3615
       usb_disable_device+0x3e7/0x8a0 drivers/usb/core/message.c:1472
       usb_disconnect+0x33c/0x8a0 drivers/usb/core/hub.c:2287
       hub_port_connect drivers/usb/core/hub.c:5341 [inline]
       hub_port_connect_change drivers/usb/core/hub.c:5637 [inline]
       port_event drivers/usb/core/hub.c:5799 [inline]
       hub_event+0x1d64/0x5260 drivers/usb/core/hub.c:5881
       process_one_work+0x867/0xff0 kernel/workqueue.c:2310
       process_scheduled_works kernel/workqueue.c:2373 [inline]
       worker_thread+0xd93/0x12a0 kernel/workqueue.c:2459
       kthread+0x42e/0x520 kernel/kthread.c:334
       ret_from_fork+0x1f/0x30 arch/x86/entry/entry_64.S:287

other info that might help us debug this:

Chain exists of:
  input_mutex --> &dev->mutex#2 --> &hdev->ll_open_lock

 Possible unsafe locking scenario:

       CPU0                    CPU1
       ----                    ----
  lock(&hdev->ll_open_lock);
                               lock(&dev->mutex#2);
                               lock(&hdev->ll_open_lock);
  lock(input_mutex);

 *** DEADLOCK ***

9 locks held by kworker/0:0/7:
 #0: ffff8881423e5538 ((wq_completion)usb_hub_wq){+.+.}-{0:0}, at: process_one_work+0x75c/0xff0 kernel/workqueue.c:-1
 #1: ffffc90000cc7d00 ((work_completion)(&hub->events)){+.+.}-{0:0}, at: process_one_work+0x79e/0xff0 kernel/workqueue.c:2285
 #2: ffff8881481bf220 (&dev->mutex){....}-{3:3}, at: device_lock include/linux/device.h:809 [inline]
 #2: ffff8881481bf220 (&dev->mutex){....}-{3:3}, at: hub_event+0x178/0x5260 drivers/usb/core/hub.c:5827
 #3: ffff888023060220 (&dev->mutex){....}-{3:3}, at: device_lock include/linux/device.h:809 [inline]
 #3: ffff888023060220 (&dev->mutex){....}-{3:3}, at: usb_disconnect+0xf8/0x8a0 drivers/usb/core/hub.c:2278
 #4: ffff8880775241a8 (&dev->mutex){....}-{3:3}, at: device_lock include/linux/device.h:809 [inline]
 #4: ffff8880775241a8 (&dev->mutex){....}-{3:3}, at: __device_driver_lock drivers/base/dd.c:1064 [inline]
 #4: ffff8880775241a8 (&dev->mutex){....}-{3:3}, at: device_release_driver_internal+0xa1/0x710 drivers/base/dd.c:1279
 #5: ffff88804e299ab0 (&dev->mutex){....}-{3:3}, at: device_lock include/linux/device.h:809 [inline]
 #5: ffff88804e299ab0 (&dev->mutex){....}-{3:3}, at: __device_driver_lock drivers/base/dd.c:1064 [inline]
 #5: ffff88804e299ab0 (&dev->mutex){....}-{3:3}, at: device_release_driver_internal+0xa1/0x710 drivers/base/dd.c:1279
 #6: ffff88804f3a1ab0 (&dev->mutex){....}-{3:3}, at: device_lock include/linux/device.h:809 [inline]
 #6: ffff88804f3a1ab0 (&dev->mutex){....}-{3:3}, at: __device_driver_lock drivers/base/dd.c:1064 [inline]
 #6: ffff88804f3a1ab0 (&dev->mutex){....}-{3:3}, at: device_release_driver_internal+0xa1/0x710 drivers/base/dd.c:1279
 #7: ffffffff8d2c7248 (minors_lock){+.+.}-{3:3}, at: hidraw_disconnect+0x40/0x60 drivers/hid/hidraw.c:600
 #8: ffff88804f3a1ee8 (&hdev->ll_open_lock){+.+.}-{3:3}, at: hid_hw_close+0x2c/0xd0 drivers/hid/hid-core.c:2183

stack backtrace:
CPU: 0 PID: 7 Comm: kworker/0:0 Not tainted syzkaller #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 07/24/2026
Workqueue: usb_hub_wq hub_event
Call Trace:
 <TASK>
 dump_stack_lvl+0x188/0x250 lib/dump_stack.c:106
 check_noncircular+0x296/0x330 kernel/locking/lockdep.c:2133
 check_prev_add kernel/locking/lockdep.c:3053 [inline]
 check_prevs_add kernel/locking/lockdep.c:3172 [inline]
 validate_chain kernel/locking/lockdep.c:3788 [inline]
 __lock_acquire+0x2c66/0x7b50 kernel/locking/lockdep.c:5012
 lock_acquire+0x19e/0x400 kernel/locking/lockdep.c:5623
 __mutex_lock_common+0x1e5/0x2400 kernel/locking/mutex.c:596
 __mutex_lock kernel/locking/mutex.c:729 [inline]
 mutex_lock_interruptible_nested+0x17/0x20 kernel/locking/mutex.c:765
 input_register_device+0xaf4/0x10c0 drivers/input/input.c:2422
 steam_input_register+0x9b1/0xc80 drivers/hid/hid-steam.c:469
 hid_hw_close+0xa5/0xd0 drivers/hid/hid-core.c:2185
 drop_ref+0x97/0x360 drivers/hid/hidraw.c:324
 hidraw_disconnect+0x4d/0x60 drivers/hid/hidraw.c:602
 hid_disconnect drivers/hid/hid-core.c:2097 [inline]
 hid_hw_stop+0xf6/0x1e0 drivers/hid/hid-core.c:2140
 hid_device_remove+0x227/0x340 drivers/hid/hid-core.c:-1
 __device_release_driver drivers/base/dd.c:1247 [inline]
 device_release_driver_internal+0x44c/0x710 drivers/base/dd.c:1282
 bus_remove_device+0x2dd/0x400 drivers/base/bus.c:531
 device_del+0x63f/0xa80 drivers/base/core.c:3615
 hid_remove_device drivers/hid/hid-core.c:2549 [inline]
 hid_destroy_device+0x66/0x100 drivers/hid/hid-core.c:2568
 steam_remove+0xab/0x180 drivers/hid/hid-steam.c:823
 hid_device_remove+0x227/0x340 drivers/hid/hid-core.c:-1
 __device_release_driver drivers/base/dd.c:1247 [inline]
 device_release_driver_internal+0x44c/0x710 drivers/base/dd.c:1282
 bus_remove_device+0x2dd/0x400 drivers/base/bus.c:531
 device_del+0x63f/0xa80 drivers/base/core.c:3615
 hid_remove_device drivers/hid/hid-core.c:2549 [inline]
 hid_destroy_device+0x66/0x100 drivers/hid/hid-core.c:2568
 usbhid_disconnect+0x9b/0xc0 drivers/hid/usbhid/hid-core.c:1469
 usb_unbind_interface+0x203/0x870 drivers/usb/core/driver.c:458
 __device_release_driver drivers/base/dd.c:1249 [inline]
 device_release_driver_internal+0x487/0x710 drivers/base/dd.c:1282
 bus_remove_device+0x2dd/0x400 drivers/base/bus.c:531
 device_del+0x63f/0xa80 drivers/base/core.c:3615
 usb_disable_device+0x3e7/0x8a0 drivers/usb/core/message.c:1472
 usb_disconnect+0x33c/0x8a0 drivers/usb/core/hub.c:2287
 hub_port_connect drivers/usb/core/hub.c:5341 [inline]
 hub_port_connect_change drivers/usb/core/hub.c:5637 [inline]
 port_event drivers/usb/core/hub.c:5799 [inline]
 hub_event+0x1d64/0x5260 drivers/usb/core/hub.c:5881
 process_one_work+0x867/0xff0 kernel/workqueue.c:2310
 process_scheduled_works kernel/workqueue.c:2373 [inline]
 worker_thread+0xd93/0x12a0 kernel/workqueue.c:2459
 kthread+0x42e/0x520 kernel/kthread.c:334
 ret_from_fork+0x1f/0x30 arch/x86/entry/entry_64.S:287
 </TASK>
hid-steam 0003:28DE:1102.000E: Steam Controller 'XXXXXXXXXX' disconnected
Bluetooth: hci0: command 0x0406 tx timeout
Bluetooth: hci1: command 0x0406 tx timeout
Bluetooth: hci4: command 0x0406 tx timeout
Bluetooth: hci2: command 0x0406 tx timeout
Bluetooth: hci3: command 0x0406 tx timeout

Crashes (3):
Time Kernel Commit Syzkaller Config Log Report Syz repro C repro VM info Assets (help?) Manager Title
2026/08/11 22:51 linux-5.15.y aabd761612db 71790083 .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-5-15-kasan possible deadlock in input_register_device
2026/05/15 12:25 linux-5.15.y de8dfb3f0278 9cd3beaa .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-5-15-kasan possible deadlock in input_register_device
2026/05/14 15:21 linux-5.15.y de8dfb3f0278 6ccb967e .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-5-15-kasan possible deadlock in input_register_device
* Struck through repros no longer work on HEAD.