udc-core: couldn't find an available UDC or it's busy misc raw-gadget: fail, usb_gadget_probe_driver returned -16 ===================================================== WARNING: HARDIRQ-safe -> HARDIRQ-unsafe lock order detected 5.10.0-syzkaller #0 Not tainted ----------------------------------------------------- syz-executor.2/8452 [HC0[0]:SC0[0]:HE0:SE1] is trying to acquire: ffff88810f4480c0 (&new->fa_lock){.+.+}-{2:2}, at: kill_fasync_rcu fs/fcntl.c:1004 [inline] ffff88810f4480c0 (&new->fa_lock){.+.+}-{2:2}, at: kill_fasync fs/fcntl.c:1025 [inline] ffff88810f4480c0 (&new->fa_lock){.+.+}-{2:2}, at: kill_fasync+0x1a3/0x4d0 fs/fcntl.c:1018 and this task is already holding: ffff8881123b2028 (&client->buffer_lock){....}-{2:2}, at: spin_lock include/linux/spinlock.h:354 [inline] ffff8881123b2028 (&client->buffer_lock){....}-{2:2}, at: evdev_pass_values.part.0+0xf6/0x970 drivers/input/evdev.c:261 which would create a new lock dependency: (&client->buffer_lock){....}-{2:2} -> ( &new->fa_lock){.+.+}-{2:2} but this new dependency connects a HARDIRQ-irq-safe lock: (&dev->event_lock){-.-.}-{2:2} ... which became HARDIRQ-irq-safe at: lock_acquire kernel/locking/lockdep.c:5437 [inline] lock_acquire+0x288/0x710 kernel/locking/lockdep.c:5402 __raw_spin_lock_irqsave include/linux/spinlock_api_smp.h:110 [inline] _raw_spin_lock_irqsave+0x36/0x50 kernel/locking/spinlock.c:159 input_event drivers/input/input.c:445 [inline] input_event+0x7b/0xb0 drivers/input/input.c:438 input_report_key include/linux/input.h:425 [inline] psmouse_report_standard_buttons+0x2c/0x80 drivers/input/mouse/psmouse-base.c:123 psmouse_report_standard_packet drivers/input/mouse/psmouse-base.c:141 [inline] psmouse_process_byte+0x1df/0x8a0 drivers/input/mouse/psmouse-base.c:232 psmouse_handle_byte+0x41/0x1b0 drivers/input/mouse/psmouse-base.c:274 psmouse_interrupt+0x301/0xf40 drivers/input/mouse/psmouse-base.c:426 serio_interrupt+0x88/0x150 drivers/input/serio/serio.c:1002 i8042_interrupt+0x3ba/0x710 drivers/input/serio/i8042.c:602 __handle_irq_event_percpu+0x303/0x8d0 kernel/irq/handle.c:156 handle_irq_event_percpu+0x76/0x170 kernel/irq/handle.c:196 handle_irq_event+0xa1/0x130 kernel/irq/handle.c:213 handle_edge_irq+0x247/0xcf0 kernel/irq/chip.c:819 asm_call_irq_on_stack+0xf/0x20 __run_irq_on_irqstack arch/x86/include/asm/irq_stack.h:48 [inline] run_irq_on_irqstack_cond arch/x86/include/asm/irq_stack.h:101 [inline] handle_irq arch/x86/kernel/irq.c:230 [inline] __common_interrupt arch/x86/kernel/irq.c:249 [inline] common_interrupt+0xf2/0x1b0 arch/x86/kernel/irq.c:239 asm_common_interrupt+0x1e/0x40 arch/x86/include/asm/idtentry.h:619 native_restore_fl arch/x86/include/asm/irqflags.h:41 [inline] arch_local_irq_restore arch/x86/include/asm/irqflags.h:84 [inline] __raw_spin_unlock_irqrestore include/linux/spinlock_api_smp.h:160 [inline] _raw_spin_unlock_irqrestore+0x25/0x40 kernel/locking/spinlock.c:191 __debug_check_no_obj_freed lib/debugobjects.c:997 [inline] debug_check_no_obj_freed+0x20c/0x430 lib/debugobjects.c:1018 slab_free_hook mm/slub.c:1536 [inline] slab_free_freelist_hook+0x107/0x150 mm/slub.c:1577 slab_free mm/slub.c:3140 [inline] kmem_cache_free+0x82/0x340 mm/slub.c:3156 mmdrop include/linux/sched/mm.h:49 [inline] __mmput kernel/fork.c:1093 [inline] mmput+0x324/0x3d0 kernel/fork.c:1104 free_bprm+0x65/0x2e0 fs/exec.c:1477 kernel_execve+0x380/0x460 fs/exec.c:1971 call_usermodehelper_exec_async+0x2de/0x580 kernel/umh.c:110 ret_from_fork+0x1f/0x30 arch/x86/entry/entry_64.S:296 to a HARDIRQ-irq-unsafe lock: (&new->fa_lock){.+.+}-{2:2} ... which became HARDIRQ-irq-unsafe at: ... lock_acquire kernel/locking/lockdep.c:5437 [inline] lock_acquire+0x288/0x710 kernel/locking/lockdep.c:5402 __raw_read_lock include/linux/rwlock_api_smp.h:149 [inline] _raw_read_lock+0x58/0x70 kernel/locking/spinlock.c:223 kill_fasync_rcu fs/fcntl.c:1004 [inline] kill_fasync fs/fcntl.c:1025 [inline] kill_fasync+0x1a3/0x4d0 fs/fcntl.c:1018 evdev_hangup drivers/input/evdev.c:429 [inline] evdev_cleanup+0xb6/0x1a0 drivers/input/evdev.c:1324 evdev_disconnect+0x45/0xb0 drivers/input/evdev.c:1407 __input_unregister_device+0x206/0x470 drivers/input/input.c:2189 input_unregister_device+0xd9/0x120 drivers/input/input.c:2379 rc_free_rx_device drivers/media/rc/rc-main.c:1883 [inline] rc_unregister_device+0x17a/0x430 drivers/media/rc/rc-main.c:2032 mceusb_dev_disconnect+0x103/0x290 drivers/media/rc/mceusb.c:1854 usb_unbind_interface+0x1d8/0x8d0 drivers/usb/core/driver.c:458 __device_release_driver+0x40d/0x740 drivers/base/dd.c:1161 device_release_driver_internal drivers/base/dd.c:1192 [inline] device_release_driver+0x26/0x40 drivers/base/dd.c:1215 bus_remove_device+0x2eb/0x5a0 drivers/base/bus.c:533 device_del+0x502/0xd40 drivers/base/core.c:3270 usb_disable_device+0x35b/0x7b0 drivers/usb/core/message.c:1413 usb_disconnect.cold+0x27d/0x780 drivers/usb/core/hub.c:2218 hub_port_connect drivers/usb/core/hub.c:5074 [inline] hub_port_connect_change drivers/usb/core/hub.c:5363 [inline] port_event drivers/usb/core/hub.c:5509 [inline] hub_event+0x1c8a/0x42d0 drivers/usb/core/hub.c:5591 process_one_work+0x98d/0x15c0 kernel/workqueue.c:2275 process_scheduled_works kernel/workqueue.c:2337 [inline] worker_thread+0x82b/0x1120 kernel/workqueue.c:2423 kthread+0x38c/0x460 kernel/kthread.c:292 ret_from_fork+0x1f/0x30 arch/x86/entry/entry_64.S:296 other info that might help us debug this: Chain exists of: &dev->event_lock --> &client->buffer_lock --> &new->fa_lock Possible interrupt unsafe locking scenario: CPU0 CPU1 ---- ---- lock(&new->fa_lock); local_irq_disable(); lock(&dev->event_lock); lock(&client->buffer_lock); lock(&dev->event_lock); *** DEADLOCK *** 7 locks held by syz-executor.2/8452: #0: ffff88810a7f3110 (&evdev->mutex){+.+.}-{3:3}, at: evdev_write+0x154/0x470 drivers/input/evdev.c:513 #1: ffff888109df4230 (&dev->event_lock){-.-.}-{2:2}, at: input_inject_event+0xa6/0x390 drivers/input/input.c:471 #2: ffffffff8767b560 (rcu_read_lock){....}-{1:2}, at: is_event_supported drivers/input/input.c:53 [inline] #2: ffffffff8767b560 (rcu_read_lock){....}-{1:2}, at: is_event_supported drivers/input/input.c:50 [inline] #2: ffffffff8767b560 (rcu_read_lock){....}-{1:2}, at: input_inject_event+0x92/0x390 drivers/input/input.c:470 #3: ffffffff8767b560 (rcu_read_lock){....}-{1:2}, at: input_pass_values.part.0+0x0/0x760 drivers/input/input.c:2461 #4: ffffffff8767b560 (rcu_read_lock){....}-{1:2}, at: evdev_events+0x59/0x490 drivers/input/evdev.c:296 #5: ffff8881123b2028 (&client->buffer_lock){....}-{2:2}, at: spin_lock include/linux/spinlock.h:354 [inline] #5: ffff8881123b2028 (&client->buffer_lock){....}-{2:2}, at: evdev_pass_values.part.0+0xf6/0x970 drivers/input/evdev.c:261 #6: ffffffff8767b560 (rcu_read_lock){....}-{1:2}, at: kill_fasync+0x3d/0x4d0 fs/fcntl.c:1023 the dependencies between HARDIRQ-irq-safe lock and the holding lock: -> (&dev->event_lock){-.-.}-{2:2} { IN-HARDIRQ-W at: lock_acquire kernel/locking/lockdep.c:5437 [inline] lock_acquire+0x288/0x710 kernel/locking/lockdep.c:5402 __raw_spin_lock_irqsave include/linux/spinlock_api_smp.h:110 [inline] _raw_spin_lock_irqsave+0x36/0x50 kernel/locking/spinlock.c:159 input_event drivers/input/input.c:445 [inline] input_event+0x7b/0xb0 drivers/input/input.c:438 input_report_key include/linux/input.h:425 [inline] psmouse_report_standard_buttons+0x2c/0x80 drivers/input/mouse/psmouse-base.c:123 psmouse_report_standard_packet drivers/input/mouse/psmouse-base.c:141 [inline] psmouse_process_byte+0x1df/0x8a0 drivers/input/mouse/psmouse-base.c:232 psmouse_handle_byte+0x41/0x1b0 drivers/input/mouse/psmouse-base.c:274 psmouse_interrupt+0x301/0xf40 drivers/input/mouse/psmouse-base.c:426 serio_interrupt+0x88/0x150 drivers/input/serio/serio.c:1002 i8042_interrupt+0x3ba/0x710 drivers/input/serio/i8042.c:602 __handle_irq_event_percpu+0x303/0x8d0 kernel/irq/handle.c:156 handle_irq_event_percpu+0x76/0x170 kernel/irq/handle.c:196 handle_irq_event+0xa1/0x130 kernel/irq/handle.c:213 handle_edge_irq+0x247/0xcf0 kernel/irq/chip.c:819 asm_call_irq_on_stack+0xf/0x20 __run_irq_on_irqstack arch/x86/include/asm/irq_stack.h:48 [inline] run_irq_on_irqstack_cond arch/x86/include/asm/irq_stack.h:101 [inline] handle_irq arch/x86/kernel/irq.c:230 [inline] __common_interrupt arch/x86/kernel/irq.c:249 [inline] common_interrupt+0xf2/0x1b0 arch/x86/kernel/irq.c:239 asm_common_interrupt+0x1e/0x40 arch/x86/include/asm/idtentry.h:619 native_restore_fl arch/x86/include/asm/irqflags.h:41 [inline] arch_local_irq_restore arch/x86/include/asm/irqflags.h:84 [inline] __raw_spin_unlock_irqrestore include/linux/spinlock_api_smp.h:160 [inline] _raw_spin_unlock_irqrestore+0x25/0x40 kernel/locking/spinlock.c:191 __debug_check_no_obj_freed lib/debugobjects.c:997 [inline] debug_check_no_obj_freed+0x20c/0x430 lib/debugobjects.c:1018 slab_free_hook mm/slub.c:1536 [inline] slab_free_freelist_hook+0x107/0x150 mm/slub.c:1577 slab_free mm/slub.c:3140 [inline] kmem_cache_free+0x82/0x340 mm/slub.c:3156 mmdrop include/linux/sched/mm.h:49 [inline] __mmput kernel/fork.c:1093 [inline] mmput+0x324/0x3d0 kernel/fork.c:1104 free_bprm+0x65/0x2e0 fs/exec.c:1477 kernel_execve+0x380/0x460 fs/exec.c:1971 call_usermodehelper_exec_async+0x2de/0x580 kernel/umh.c:110 ret_from_fork+0x1f/0x30 arch/x86/entry/entry_64.S:296 IN-SOFTIRQ-W at: lock_acquire kernel/locking/lockdep.c:5437 [inline] lock_acquire+0x288/0x710 kernel/locking/lockdep.c:5402 __raw_spin_lock_irqsave include/linux/spinlock_api_smp.h:110 [inline] _raw_spin_lock_irqsave+0x36/0x50 kernel/locking/spinlock.c:159 input_event drivers/input/input.c:445 [inline] input_event+0x7b/0xb0 drivers/input/input.c:438 hidinput_hid_event+0x14d7/0x18b0 drivers/hid/hid-input.c:1401 hid_process_event+0x491/0x570 drivers/hid/hid-core.c:1519 hid_input_field drivers/hid/hid-core.c:1563 [inline] hid_report_raw_event+0xcf6/0x11b0 drivers/hid/hid-core.c:1783 hid_input_report+0x360/0x4c0 drivers/hid/hid-core.c:1850 hid_irq_in+0x50e/0x690 drivers/hid/usbhid/hid-core.c:284 __usb_hcd_giveback_urb+0x2b0/0x5c0 drivers/usb/core/hcd.c:1657 usb_hcd_giveback_urb+0x38c/0x430 drivers/usb/core/hcd.c:1728 dummy_timer+0x11f4/0x32a0 drivers/usb/gadget/udc/dummy_hcd.c:1971 call_timer_fn+0x1a5/0x690 kernel/time/timer.c:1417 expire_timers kernel/time/timer.c:1462 [inline] __run_timers.part.0+0x692/0xa50 kernel/time/timer.c:1731 __run_timers kernel/time/timer.c:1712 [inline] run_timer_softirq+0x80/0x120 kernel/time/timer.c:1744 __do_softirq+0x1b7/0x9c5 kernel/softirq.c:343 asm_call_irq_on_stack+0xf/0x20 __run_on_irqstack arch/x86/include/asm/irq_stack.h:26 [inline] run_on_irqstack_cond arch/x86/include/asm/irq_stack.h:77 [inline] do_softirq_own_stack+0x80/0xa0 arch/x86/kernel/irq_64.c:77 invoke_softirq kernel/softirq.c:226 [inline] __irq_exit_rcu+0x119/0x1b0 kernel/softirq.c:420 irq_exit_rcu+0x5/0x10 kernel/softirq.c:432 sysvec_apic_timer_interrupt+0x43/0xa0 arch/x86/kernel/apic/apic.c:1096 asm_sysvec_apic_timer_interrupt+0x12/0x20 arch/x86/include/asm/idtentry.h:628 check_kcov_mode kernel/kcov.c:163 [inline] __sanitizer_cov_trace_pc+0x9/0x60 kernel/kcov.c:197 prepend_path+0x539/0xe20 fs/d_path.c:130 d_absolute_path+0xfa/0x180 fs/d_path.c:205 tomoyo_get_absolute_path security/tomoyo/realpath.c:101 [inline] tomoyo_realpath_from_path+0x282/0x620 security/tomoyo/realpath.c:276 tomoyo_get_realpath security/tomoyo/file.c:151 [inline] tomoyo_path_perm+0x21b/0x3f0 security/tomoyo/file.c:822 security_inode_getattr+0xcf/0x140 security/security.c:1280 vfs_getattr fs/stat.c:121 [inline] vfs_statx+0x164/0x390 fs/stat.c:189 vfs_fstatat fs/stat.c:207 [inline] vfs_lstat include/linux/fs.h:3123 [inline] __do_sys_newlstat+0x91/0x110 fs/stat.c:362 do_syscall_64+0x2d/0x40 arch/x86/entry/common.c:46 entry_SYSCALL_64_after_hwframe+0x44/0xa9 INITIAL USE at: lock_acquire kernel/locking/lockdep.c:5437 [inline] lock_acquire+0x288/0x710 kernel/locking/lockdep.c:5402 __raw_spin_lock_irqsave include/linux/spinlock_api_smp.h:110 [inline] _raw_spin_lock_irqsave+0x36/0x50 kernel/locking/spinlock.c:159 input_inject_event+0xa6/0x390 drivers/input/input.c:471 __led_set_brightness drivers/leds/led-core.c:48 [inline] led_set_brightness_nopm drivers/leds/led-core.c:275 [inline] led_set_brightness_nosleep+0xe6/0x1a0 drivers/leds/led-core.c:292 led_set_brightness+0x134/0x170 drivers/leds/led-core.c:267 led_trigger_event drivers/leds/led-triggers.c:387 [inline] led_trigger_event+0x70/0xd0 drivers/leds/led-triggers.c:377 kbd_led_trigger_activate+0xfa/0x130 drivers/tty/vt/keyboard.c:1017 led_trigger_set+0x61e/0xbd0 drivers/leds/led-triggers.c:195 led_trigger_set_default drivers/leds/led-triggers.c:259 [inline] led_trigger_set_default+0x1a6/0x230 drivers/leds/led-triggers.c:246 led_classdev_register_ext+0x5d6/0x7f0 drivers/leds/led-class.c:417 led_classdev_register include/linux/leds.h:190 [inline] input_leds_connect+0x3fb/0x740 drivers/input/input-leds.c:139 input_attach_handler+0x180/0x1f0 drivers/input/input.c:1035 input_register_device.cold+0x10a/0x35f drivers/input/input.c:2335 atkbd_connect+0x83b/0xb50 drivers/input/keyboard/atkbd.c:1293 serio_connect_driver drivers/input/serio/serio.c:47 [inline] serio_driver_probe+0x72/0xa0 drivers/input/serio/serio.c:778 really_probe+0x2b1/0xe40 drivers/base/dd.c:561 driver_probe_device+0x285/0x3f0 drivers/base/dd.c:745 device_driver_attach+0x27d/0x2f0 drivers/base/dd.c:1020 __driver_attach+0x15b/0x2f0 drivers/base/dd.c:1097 bus_for_each_dev+0x147/0x1d0 drivers/base/bus.c:305 serio_attach_driver drivers/input/serio/serio.c:808 [inline] serio_handle_event+0x5f6/0xa30 drivers/input/serio/serio.c:227 process_one_work+0x98d/0x15c0 kernel/workqueue.c:2275 worker_thread+0x64c/0x1120 kernel/workqueue.c:2421 kthread+0x38c/0x460 kernel/kthread.c:292 ret_from_fork+0x1f/0x30 arch/x86/entry/entry_64.S:296 } ... key at: [] __key.8+0x0/0x40 ... acquired at: __raw_spin_lock include/linux/spinlock_api_smp.h:142 [inline] _raw_spin_lock+0x27/0x40 kernel/locking/spinlock.c:151 spin_lock include/linux/spinlock.h:354 [inline] evdev_handle_get_val+0x70/0x5e0 drivers/input/evdev.c:900 evdev_do_ioctl+0xf3d/0x1820 drivers/input/evdev.c:1159 evdev_ioctl_handler drivers/input/evdev.c:1272 [inline] evdev_ioctl+0x180/0x1f0 drivers/input/evdev.c:1281 vfs_ioctl fs/ioctl.c:48 [inline] __do_sys_ioctl fs/ioctl.c:753 [inline] __se_sys_ioctl fs/ioctl.c:739 [inline] __x64_sys_ioctl+0x193/0x200 fs/ioctl.c:739 do_syscall_64+0x2d/0x40 arch/x86/entry/common.c:46 entry_SYSCALL_64_after_hwframe+0x44/0xa9 -> (&client->buffer_lock){....}-{2:2} { INITIAL USE at: lock_acquire kernel/locking/lockdep.c:5437 [inline] lock_acquire+0x288/0x710 kernel/locking/lockdep.c:5402 __raw_spin_lock include/linux/spinlock_api_smp.h:142 [inline] _raw_spin_lock+0x27/0x40 kernel/locking/spinlock.c:151 spin_lock include/linux/spinlock.h:354 [inline] evdev_handle_get_val+0x70/0x5e0 drivers/input/evdev.c:900 evdev_do_ioctl+0xf3d/0x1820 drivers/input/evdev.c:1159 evdev_ioctl_handler drivers/input/evdev.c:1272 [inline] evdev_ioctl+0x180/0x1f0 drivers/input/evdev.c:1281 vfs_ioctl fs/ioctl.c:48 [inline] __do_sys_ioctl fs/ioctl.c:753 [inline] __se_sys_ioctl fs/ioctl.c:739 [inline] __x64_sys_ioctl+0x193/0x200 fs/ioctl.c:739 do_syscall_64+0x2d/0x40 arch/x86/entry/common.c:46 entry_SYSCALL_64_after_hwframe+0x44/0xa9 } ... key at: [] __key.4+0x0/0x40 ... acquired at: lock_acquire kernel/locking/lockdep.c:5437 [inline] lock_acquire+0x288/0x710 kernel/locking/lockdep.c:5402 __raw_read_lock include/linux/rwlock_api_smp.h:149 [inline] _raw_read_lock+0x58/0x70 kernel/locking/spinlock.c:223 kill_fasync_rcu fs/fcntl.c:1004 [inline] kill_fasync fs/fcntl.c:1025 [inline] kill_fasync+0x1a3/0x4d0 fs/fcntl.c:1018 __pass_event drivers/input/evdev.c:240 [inline] evdev_pass_values.part.0+0x64e/0x970 drivers/input/evdev.c:278 evdev_pass_values drivers/input/evdev.c:253 [inline] evdev_events+0x331/0x490 drivers/input/evdev.c:306 input_to_handler+0x2a0/0x4c0 drivers/input/input.c:115 input_pass_values.part.0+0x2ed/0x760 drivers/input/input.c:145 input_pass_values drivers/input/input.c:134 [inline] input_handle_event+0x39b/0x1470 drivers/input/input.c:404 input_inject_event+0x373/0x390 drivers/input/input.c:476 evdev_write+0x329/0x470 drivers/input/evdev.c:530 vfs_write+0x28e/0xa30 fs/read_write.c:603 ksys_write+0x1ee/0x250 fs/read_write.c:658 do_syscall_64+0x2d/0x40 arch/x86/entry/common.c:46 entry_SYSCALL_64_after_hwframe+0x44/0xa9 the dependencies between the lock to be acquired and HARDIRQ-irq-unsafe lock: -> (&new->fa_lock){.+.+}-{2:2} { HARDIRQ-ON-R at: lock_acquire kernel/locking/lockdep.c:5437 [inline] lock_acquire+0x288/0x710 kernel/locking/lockdep.c:5402 __raw_read_lock include/linux/rwlock_api_smp.h:149 [inline] _raw_read_lock+0x58/0x70 kernel/locking/spinlock.c:223 kill_fasync_rcu fs/fcntl.c:1004 [inline] kill_fasync fs/fcntl.c:1025 [inline] kill_fasync+0x1a3/0x4d0 fs/fcntl.c:1018 evdev_hangup drivers/input/evdev.c:429 [inline] evdev_cleanup+0xb6/0x1a0 drivers/input/evdev.c:1324 evdev_disconnect+0x45/0xb0 drivers/input/evdev.c:1407 __input_unregister_device+0x206/0x470 drivers/input/input.c:2189 input_unregister_device+0xd9/0x120 drivers/input/input.c:2379 rc_free_rx_device drivers/media/rc/rc-main.c:1883 [inline] rc_unregister_device+0x17a/0x430 drivers/media/rc/rc-main.c:2032 mceusb_dev_disconnect+0x103/0x290 drivers/media/rc/mceusb.c:1854 usb_unbind_interface+0x1d8/0x8d0 drivers/usb/core/driver.c:458 __device_release_driver+0x40d/0x740 drivers/base/dd.c:1161 device_release_driver_internal drivers/base/dd.c:1192 [inline] device_release_driver+0x26/0x40 drivers/base/dd.c:1215 bus_remove_device+0x2eb/0x5a0 drivers/base/bus.c:533 device_del+0x502/0xd40 drivers/base/core.c:3270 usb_disable_device+0x35b/0x7b0 drivers/usb/core/message.c:1413 usb_disconnect.cold+0x27d/0x780 drivers/usb/core/hub.c:2218 hub_port_connect drivers/usb/core/hub.c:5074 [inline] hub_port_connect_change drivers/usb/core/hub.c:5363 [inline] port_event drivers/usb/core/hub.c:5509 [inline] hub_event+0x1c8a/0x42d0 drivers/usb/core/hub.c:5591 process_one_work+0x98d/0x15c0 kernel/workqueue.c:2275 process_scheduled_works kernel/workqueue.c:2337 [inline] worker_thread+0x82b/0x1120 kernel/workqueue.c:2423 kthread+0x38c/0x460 kernel/kthread.c:292 ret_from_fork+0x1f/0x30 arch/x86/entry/entry_64.S:296 SOFTIRQ-ON-R at: lock_acquire kernel/locking/lockdep.c:5437 [inline] lock_acquire+0x288/0x710 kernel/locking/lockdep.c:5402 __raw_read_lock include/linux/rwlock_api_smp.h:149 [inline] _raw_read_lock+0x58/0x70 kernel/locking/spinlock.c:223 kill_fasync_rcu fs/fcntl.c:1004 [inline] kill_fasync fs/fcntl.c:1025 [inline] kill_fasync+0x1a3/0x4d0 fs/fcntl.c:1018 evdev_hangup drivers/input/evdev.c:429 [inline] evdev_cleanup+0xb6/0x1a0 drivers/input/evdev.c:1324 evdev_disconnect+0x45/0xb0 drivers/input/evdev.c:1407 __input_unregister_device+0x206/0x470 drivers/input/input.c:2189 input_unregister_device+0xd9/0x120 drivers/input/input.c:2379 rc_free_rx_device drivers/media/rc/rc-main.c:1883 [inline] rc_unregister_device+0x17a/0x430 drivers/media/rc/rc-main.c:2032 mceusb_dev_disconnect+0x103/0x290 drivers/media/rc/mceusb.c:1854 usb_unbind_interface+0x1d8/0x8d0 drivers/usb/core/driver.c:458 __device_release_driver+0x40d/0x740 drivers/base/dd.c:1161 device_release_driver_internal drivers/base/dd.c:1192 [inline] device_release_driver+0x26/0x40 drivers/base/dd.c:1215 bus_remove_device+0x2eb/0x5a0 drivers/base/bus.c:533 device_del+0x502/0xd40 drivers/base/core.c:3270 usb_disable_device+0x35b/0x7b0 drivers/usb/core/message.c:1413 usb_disconnect.cold+0x27d/0x780 drivers/usb/core/hub.c:2218 hub_port_connect drivers/usb/core/hub.c:5074 [inline] hub_port_connect_change drivers/usb/core/hub.c:5363 [inline] port_event drivers/usb/core/hub.c:5509 [inline] hub_event+0x1c8a/0x42d0 drivers/usb/core/hub.c:5591 process_one_work+0x98d/0x15c0 kernel/workqueue.c:2275 process_scheduled_works kernel/workqueue.c:2337 [inline] worker_thread+0x82b/0x1120 kernel/workqueue.c:2423 kthread+0x38c/0x460 kernel/kthread.c:292 ret_from_fork+0x1f/0x30 arch/x86/entry/entry_64.S:296 INITIAL USE at: lock_acquire kernel/locking/lockdep.c:5437 [inline] lock_acquire+0x288/0x710 kernel/locking/lockdep.c:5402 __raw_write_lock_irq include/linux/rwlock_api_smp.h:196 [inline] _raw_write_lock_irq+0x2f/0x40 kernel/locking/spinlock.c:311 fasync_remove_entry+0xb6/0x1f0 fs/fcntl.c:882 fasync_helper+0x9e/0xb0 fs/fcntl.c:985 __fput+0x712/0x920 fs/file_table.c:277 task_work_run+0xdd/0x1a0 kernel/task_work.c:140 tracehook_notify_resume include/linux/tracehook.h:189 [inline] exit_to_user_mode_loop kernel/entry/common.c:174 [inline] exit_to_user_mode_prepare+0x186/0x190 kernel/entry/common.c:201 __syscall_exit_to_user_mode_work kernel/entry/common.c:291 [inline] syscall_exit_to_user_mode+0x19/0x50 kernel/entry/common.c:302 entry_SYSCALL_64_after_hwframe+0x44/0xa9 INITIAL READ USE at: lock_acquire kernel/locking/lockdep.c:5437 [inline] lock_acquire+0x288/0x710 kernel/locking/lockdep.c:5402 __raw_read_lock include/linux/rwlock_api_smp.h:149 [inline] _raw_read_lock+0x58/0x70 kernel/locking/spinlock.c:223 kill_fasync_rcu fs/fcntl.c:1004 [inline] kill_fasync fs/fcntl.c:1025 [inline] kill_fasync+0x1a3/0x4d0 fs/fcntl.c:1018 evdev_hangup drivers/input/evdev.c:429 [inline] evdev_cleanup+0xb6/0x1a0 drivers/input/evdev.c:1324 evdev_disconnect+0x45/0xb0 drivers/input/evdev.c:1407 __input_unregister_device+0x206/0x470 drivers/input/input.c:2189 input_unregister_device+0xd9/0x120 drivers/input/input.c:2379 rc_free_rx_device drivers/media/rc/rc-main.c:1883 [inline] rc_unregister_device+0x17a/0x430 drivers/media/rc/rc-main.c:2032 mceusb_dev_disconnect+0x103/0x290 drivers/media/rc/mceusb.c:1854 usb_unbind_interface+0x1d8/0x8d0 drivers/usb/core/driver.c:458 __device_release_driver+0x40d/0x740 drivers/base/dd.c:1161 device_release_driver_internal drivers/base/dd.c:1192 [inline] device_release_driver+0x26/0x40 drivers/base/dd.c:1215 bus_remove_device+0x2eb/0x5a0 drivers/base/bus.c:533 device_del+0x502/0xd40 drivers/base/core.c:3270 usb_disable_device+0x35b/0x7b0 drivers/usb/core/message.c:1413 usb_disconnect.cold+0x27d/0x780 drivers/usb/core/hub.c:2218 hub_port_connect drivers/usb/core/hub.c:5074 [inline] hub_port_connect_change drivers/usb/core/hub.c:5363 [inline] port_event drivers/usb/core/hub.c:5509 [inline] hub_event+0x1c8a/0x42d0 drivers/usb/core/hub.c:5591 process_one_work+0x98d/0x15c0 kernel/workqueue.c:2275 process_scheduled_works kernel/workqueue.c:2337 [inline] worker_thread+0x82b/0x1120 kernel/workqueue.c:2423 kthread+0x38c/0x460 kernel/kthread.c:292 ret_from_fork+0x1f/0x30 arch/x86/entry/entry_64.S:296 } ... key at: [] __key.0+0x0/0x40 ... acquired at: lock_acquire kernel/locking/lockdep.c:5437 [inline] lock_acquire+0x288/0x710 kernel/locking/lockdep.c:5402 __raw_read_lock include/linux/rwlock_api_smp.h:149 [inline] _raw_read_lock+0x58/0x70 kernel/locking/spinlock.c:223 kill_fasync_rcu fs/fcntl.c:1004 [inline] kill_fasync fs/fcntl.c:1025 [inline] kill_fasync+0x1a3/0x4d0 fs/fcntl.c:1018 __pass_event drivers/input/evdev.c:240 [inline] evdev_pass_values.part.0+0x64e/0x970 drivers/input/evdev.c:278 evdev_pass_values drivers/input/evdev.c:253 [inline] evdev_events+0x331/0x490 drivers/input/evdev.c:306 input_to_handler+0x2a0/0x4c0 drivers/input/input.c:115 input_pass_values.part.0+0x2ed/0x760 drivers/input/input.c:145 input_pass_values drivers/input/input.c:134 [inline] input_handle_event+0x39b/0x1470 drivers/input/input.c:404 input_inject_event+0x373/0x390 drivers/input/input.c:476 evdev_write+0x329/0x470 drivers/input/evdev.c:530 vfs_write+0x28e/0xa30 fs/read_write.c:603 ksys_write+0x1ee/0x250 fs/read_write.c:658 do_syscall_64+0x2d/0x40 arch/x86/entry/common.c:46 entry_SYSCALL_64_after_hwframe+0x44/0xa9 stack backtrace: CPU: 0 PID: 8452 Comm: syz-executor.2 Not tainted 5.10.0-syzkaller #0 Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011 Call Trace: __dump_stack lib/dump_stack.c:79 [inline] dump_stack+0x107/0x163 lib/dump_stack.c:120 print_bad_irq_dependency kernel/locking/lockdep.c:2452 [inline] check_irq_usage.cold+0x50d/0x744 kernel/locking/lockdep.c:2681 check_prev_add kernel/locking/lockdep.c:2872 [inline] check_prevs_add kernel/locking/lockdep.c:2993 [inline] validate_chain kernel/locking/lockdep.c:3608 [inline] __lock_acquire+0x2b45/0x54a0 kernel/locking/lockdep.c:4832 lock_acquire kernel/locking/lockdep.c:5437 [inline] lock_acquire+0x288/0x710 kernel/locking/lockdep.c:5402 __raw_read_lock include/linux/rwlock_api_smp.h:149 [inline] _raw_read_lock+0x58/0x70 kernel/locking/spinlock.c:223 kill_fasync_rcu fs/fcntl.c:1004 [inline] kill_fasync fs/fcntl.c:1025 [inline] kill_fasync+0x1a3/0x4d0 fs/fcntl.c:1018 __pass_event drivers/input/evdev.c:240 [inline] evdev_pass_values.part.0+0x64e/0x970 drivers/input/evdev.c:278 evdev_pass_values drivers/input/evdev.c:253 [inline] evdev_events+0x331/0x490 drivers/input/evdev.c:306 input_to_handler+0x2a0/0x4c0 drivers/input/input.c:115 input_pass_values.part.0+0x2ed/0x760 drivers/input/input.c:145 input_pass_values drivers/input/input.c:134 [inline] input_handle_event+0x39b/0x1470 drivers/input/input.c:404 input_inject_event+0x373/0x390 drivers/input/input.c:476 evdev_write+0x329/0x470 drivers/input/evdev.c:530 vfs_write+0x28e/0xa30 fs/read_write.c:603 ksys_write+0x1ee/0x250 fs/read_write.c:658 do_syscall_64+0x2d/0x40 arch/x86/entry/common.c:46 entry_SYSCALL_64_after_hwframe+0x44/0xa9 RIP: 0033:0x45e149 Code: 0d b4 fb ff c3 66 2e 0f 1f 84 00 00 00 00 00 66 90 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 0f 83 db b3 fb ff c3 66 2e 0f 1f 84 00 00 00 00 RSP: 002b:00007f723a6b8c68 EFLAGS: 00000246 ORIG_RAX: 0000000000000001 RAX: ffffffffffffffda RBX: 0000000000000003 RCX: 000000000045e149 RDX: 0000000000035000 RSI: 0000000020000040 RDI: 0000000000000006 RBP: 000000000119c068 R08: 0000000000000000 R09: 0000000000000000 R10: 0000000000000000 R11: 0000000000000246 R12: 000000000119c034 R13: 00007fff6b74f4df R14: 00007f723a6b99c0 R15: 000000000119c034