===================================================== WARNING: HARDIRQ-safe -> HARDIRQ-unsafe lock order detected 5.19.0-rc6-syzkaller-00104-g72a8e05d4f66 #0 Not tainted ----------------------------------------------------- syz-executor974/3616 [HC0[0]:SC0[0]:HE0:SE1] is trying to acquire: ffff888079392630 (&f->f_owner.lock){....}-{2:2} , at: send_sigio+0x24/0x380 fs/fcntl.c:777 and this task is already holding: ffff88807608b9f0 (&new->fa_lock){....}-{2:2}, at: kill_fasync_rcu fs/fcntl.c:995 [inline] ffff88807608b9f0 (&new->fa_lock){....}-{2:2}, at: kill_fasync fs/fcntl.c:1016 [inline] ffff88807608b9f0 (&new->fa_lock){....}-{2:2}, at: kill_fasync+0x136/0x470 fs/fcntl.c:1009 which would create a new lock dependency: (&new->fa_lock){....}-{2:2} -> (&f->f_owner.lock){....}-{2:2} but this new dependency connects a HARDIRQ-irq-safe lock: (&dev->event_lock#2){-...}-{2:2} ... which became HARDIRQ-irq-safe at: lock_acquire kernel/locking/lockdep.c:5665 [inline] lock_acquire+0x1ab/0x570 kernel/locking/lockdep.c:5630 __raw_spin_lock_irqsave include/linux/spinlock_api_smp.h:110 [inline] _raw_spin_lock_irqsave+0x39/0x50 kernel/locking/spinlock.c:162 input_event drivers/input/input.c:456 [inline] input_event+0x7b/0xb0 drivers/input/input.c:449 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+0x1e1/0x890 drivers/input/mouse/psmouse-base.c:232 psmouse_handle_byte+0x41/0x1b0 drivers/input/mouse/psmouse-base.c:274 psmouse_interrupt+0x304/0xf00 drivers/input/mouse/psmouse-base.c:426 serio_interrupt+0x88/0x150 drivers/input/serio/serio.c:1001 i8042_interrupt+0x27a/0x520 drivers/input/serio/i8042.c:606 __handle_irq_event_percpu+0x22b/0x880 kernel/irq/handle.c:158 handle_irq_event_percpu kernel/irq/handle.c:193 [inline] handle_irq_event+0xa7/0x1e0 kernel/irq/handle.c:210 handle_edge_irq+0x25f/0xd00 kernel/irq/chip.c:817 generic_handle_irq_desc include/linux/irqdesc.h:158 [inline] handle_irq arch/x86/kernel/irq.c:231 [inline] __common_interrupt+0x9d/0x210 arch/x86/kernel/irq.c:250 common_interrupt+0xa4/0xc0 arch/x86/kernel/irq.c:240 asm_common_interrupt+0x22/0x40 arch/x86/include/asm/idtentry.h:640 lock_acquire+0x1ef/0x570 kernel/locking/lockdep.c:5633 fs_reclaim_acquire mm/page_alloc.c:4606 [inline] fs_reclaim_acquire+0xd2/0x160 mm/page_alloc.c:4597 might_alloc include/linux/sched/mm.h:271 [inline] slab_pre_alloc_hook mm/slab.h:723 [inline] slab_alloc mm/slab.c:3285 [inline] __kmem_cache_alloc_lru mm/slab.c:3479 [inline] kmem_cache_alloc+0x3d/0x560 mm/slab.c:3499 kmem_cache_zalloc include/linux/slab.h:723 [inline] __kernfs_new_node+0xd4/0x8b0 fs/kernfs/dir.c:593 kernfs_new_node+0x93/0x120 fs/kernfs/dir.c:655 kernfs_create_link+0xcb/0x230 fs/kernfs/symlink.c:39 sysfs_do_create_link_sd+0x90/0x140 fs/sysfs/symlink.c:44 sysfs_do_create_link fs/sysfs/symlink.c:80 [inline] sysfs_create_link+0x5f/0xc0 fs/sysfs/symlink.c:92 module_add_driver+0x7a/0x370 drivers/base/module.c:62 bus_add_driver+0x2ff/0x640 drivers/base/bus.c:622 driver_register+0x220/0x3a0 drivers/base/driver.c:240 usb_register_driver+0x249/0x460 drivers/usb/core/driver.c:1062 do_one_initcall+0x103/0x650 init/main.c:1295 do_initcall_level init/main.c:1368 [inline] do_initcalls init/main.c:1384 [inline] do_basic_setup init/main.c:1403 [inline] kernel_init_freeable+0x6b1/0x73a init/main.c:1610 kernel_init+0x1a/0x1d0 init/main.c:1499 ret_from_fork+0x1f/0x30 arch/x86/entry/entry_64.S:306 to a HARDIRQ-irq-unsafe lock: (tasklist_lock){.+.+}-{2:2} ... which became HARDIRQ-irq-unsafe at: ... lock_acquire kernel/locking/lockdep.c:5665 [inline] lock_acquire+0x1ab/0x570 kernel/locking/lockdep.c:5630 __raw_read_lock include/linux/rwlock_api_smp.h:150 [inline] _raw_read_lock+0x5b/0x70 kernel/locking/spinlock.c:228 do_wait+0x284/0xce0 kernel/exit.c:1508 kernel_wait+0x9c/0x150 kernel/exit.c:1698 call_usermodehelper_exec_sync kernel/umh.c:139 [inline] call_usermodehelper_exec_work+0xf5/0x180 kernel/umh.c:166 process_one_work+0x996/0x1610 kernel/workqueue.c:2289 worker_thread+0x665/0x1080 kernel/workqueue.c:2436 kthread+0x2e9/0x3a0 kernel/kthread.c:376 ret_from_fork+0x1f/0x30 arch/x86/entry/entry_64.S:306 other info that might help us debug this: Chain exists of: &dev->event_lock#2 --> &new->fa_lock --> tasklist_lock Possible interrupt unsafe locking scenario: CPU0 CPU1 ---- ---- lock(tasklist_lock); local_irq_disable(); lock(&dev->event_lock#2); lock(&new->fa_lock); lock(&dev->event_lock#2); *** DEADLOCK *** 8 locks held by syz-executor974/3616: #0: ffff888147c34110 (&evdev->mutex){+.+.}-{3:3}, at: evdev_write+0x1d3/0x760 drivers/input/evdev.c:513 #1: ffff88814681b230 (&dev->event_lock#2){-...}-{2:2}, at: input_inject_event+0xa6/0x320 drivers/input/input.c:482 #2: ffffffff8bd845a0 (rcu_read_lock){....}-{1:2}, at: is_event_supported drivers/input/input.c:64 [inline] #2: ffffffff8bd845a0 (rcu_read_lock){....}-{1:2}, at: is_event_supported drivers/input/input.c:61 [inline] #2: ffffffff8bd845a0 (rcu_read_lock){....}-{1:2}, at: input_inject_event+0x92/0x320 drivers/input/input.c:481 #3: ffffffff8bd845a0 (rcu_read_lock){....}-{1:2}, at: input_pass_values.part.0+0x0/0x710 drivers/input/input.c:884 #4: ffffffff8bd845a0 (rcu_read_lock){....}-{1:2}, at: evdev_events+0x59/0x3e0 drivers/input/evdev.c:296 #5: ffff888017521028 (&client->buffer_lock){....}-{2:2}, at: spin_lock include/linux/spinlock.h:349 [inline] #5: ffff888017521028 (&client->buffer_lock){....}-{2:2}, at: evdev_pass_values.part.0+0xf6/0x970 drivers/input/evdev.c:261 #6: ffffffff8bd845a0 (rcu_read_lock){....}-{1:2}, at: kill_fasync+0x41/0x470 fs/fcntl.c:1014 #7: ffff88807608b9f0 (&new->fa_lock){....}-{2:2}, at: kill_fasync_rcu fs/fcntl.c:995 [inline] #7: ffff88807608b9f0 (&new->fa_lock){....}-{2:2}, at: kill_fasync fs/fcntl.c:1016 [inline] #7: ffff88807608b9f0 (&new->fa_lock){....}-{2:2}, at: kill_fasync+0x136/0x470 fs/fcntl.c:1009 the dependencies between HARDIRQ-irq-safe lock and the holding lock: -> (&dev->event_lock#2){-...}-{2:2} { IN-HARDIRQ-W at: lock_acquire kernel/locking/lockdep.c:5665 [inline] lock_acquire+0x1ab/0x570 kernel/locking/lockdep.c:5630 __raw_spin_lock_irqsave include/linux/spinlock_api_smp.h:110 [inline] _raw_spin_lock_irqsave+0x39/0x50 kernel/locking/spinlock.c:162 input_event drivers/input/input.c:456 [inline] input_event+0x7b/0xb0 drivers/input/input.c:449 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+0x1e1/0x890 drivers/input/mouse/psmouse-base.c:232 psmouse_handle_byte+0x41/0x1b0 drivers/input/mouse/psmouse-base.c:274 psmouse_interrupt+0x304/0xf00 drivers/input/mouse/psmouse-base.c:426 serio_interrupt+0x88/0x150 drivers/input/serio/serio.c:1001 i8042_interrupt+0x27a/0x520 drivers/input/serio/i8042.c:606 __handle_irq_event_percpu+0x22b/0x880 kernel/irq/handle.c:158 handle_irq_event_percpu kernel/irq/handle.c:193 [inline] handle_irq_event+0xa7/0x1e0 kernel/irq/handle.c:210 handle_edge_irq+0x25f/0xd00 kernel/irq/chip.c:817 generic_handle_irq_desc include/linux/irqdesc.h:158 [inline] handle_irq arch/x86/kernel/irq.c:231 [inline] __common_interrupt+0x9d/0x210 arch/x86/kernel/irq.c:250 common_interrupt+0xa4/0xc0 arch/x86/kernel/irq.c:240 asm_common_interrupt+0x22/0x40 arch/x86/include/asm/idtentry.h:640 lock_acquire+0x1ef/0x570 kernel/locking/lockdep.c:5633 fs_reclaim_acquire mm/page_alloc.c:4606 [inline] fs_reclaim_acquire+0xd2/0x160 mm/page_alloc.c:4597 might_alloc include/linux/sched/mm.h:271 [inline] slab_pre_alloc_hook mm/slab.h:723 [inline] slab_alloc mm/slab.c:3285 [inline] __kmem_cache_alloc_lru mm/slab.c:3479 [inline] kmem_cache_alloc+0x3d/0x560 mm/slab.c:3499 kmem_cache_zalloc include/linux/slab.h:723 [inline] __kernfs_new_node+0xd4/0x8b0 fs/kernfs/dir.c:593 kernfs_new_node+0x93/0x120 fs/kernfs/dir.c:655 kernfs_create_link+0xcb/0x230 fs/kernfs/symlink.c:39 sysfs_do_create_link_sd+0x90/0x140 fs/sysfs/symlink.c:44 sysfs_do_create_link fs/sysfs/symlink.c:80 [inline] sysfs_create_link+0x5f/0xc0 fs/sysfs/symlink.c:92 module_add_driver+0x7a/0x370 drivers/base/module.c:62 bus_add_driver+0x2ff/0x640 drivers/base/bus.c:622 driver_register+0x220/0x3a0 drivers/base/driver.c:240 usb_register_driver+0x249/0x460 drivers/usb/core/driver.c:1062 do_one_initcall+0x103/0x650 init/main.c:1295 do_initcall_level init/main.c:1368 [inline] do_initcalls init/main.c:1384 [inline] do_basic_setup init/main.c:1403 [inline] kernel_init_freeable+0x6b1/0x73a init/main.c:1610 kernel_init+0x1a/0x1d0 init/main.c:1499 ret_from_fork+0x1f/0x30 arch/x86/entry/entry_64.S:306 INITIAL USE at: lock_acquire kernel/locking/lockdep.c:5665 [inline] lock_acquire+0x1ab/0x570 kernel/locking/lockdep.c:5630 __raw_spin_lock_irqsave include/linux/spinlock_api_smp.h:110 [inline] _raw_spin_lock_irqsave+0x39/0x50 kernel/locking/spinlock.c:162 input_inject_event+0xa6/0x320 drivers/input/input.c:482 __led_set_brightness drivers/leds/led-core.c:47 [inline] led_set_brightness_nopm drivers/leds/led-core.c:271 [inline] led_set_brightness_nosleep+0xe6/0x1a0 drivers/leds/led-core.c:287 led_set_brightness+0x134/0x170 drivers/leds/led-core.c:264 led_trigger_event drivers/leds/led-triggers.c:390 [inline] led_trigger_event+0xb0/0x200 drivers/leds/led-triggers.c:380 kbd_led_trigger_activate+0xc9/0x100 drivers/tty/vt/keyboard.c:1036 led_trigger_set+0x5d7/0xaf0 drivers/leds/led-triggers.c:197 led_trigger_set_default drivers/leds/led-triggers.c:262 [inline] led_trigger_set_default+0x1a6/0x230 drivers/leds/led-triggers.c:249 led_classdev_register_ext+0x56f/0x770 drivers/leds/led-class.c:415 led_classdev_register include/linux/leds.h:196 [inline] input_leds_connect+0x4bd/0x860 drivers/input/input-leds.c:139 input_attach_handler+0x180/0x1f0 drivers/input/input.c:1082 input_register_device.cold+0xf0/0x303 drivers/input/input.c:2385 atkbd_connect+0x749/0xa10 drivers/input/keyboard/atkbd.c:1282 serio_connect_driver drivers/input/serio/serio.c:47 [inline] serio_driver_probe+0x72/0xa0 drivers/input/serio/serio.c:778 call_driver_probe drivers/base/dd.c:555 [inline] really_probe+0x23e/0xb90 drivers/base/dd.c:634 __driver_probe_device+0x338/0x4d0 drivers/base/dd.c:764 driver_probe_device+0x4c/0x1a0 drivers/base/dd.c:794 __driver_attach+0x22d/0x550 drivers/base/dd.c:1163 bus_for_each_dev+0x147/0x1d0 drivers/base/bus.c:301 serio_attach_driver drivers/input/serio/serio.c:807 [inline] serio_handle_event+0x5f6/0xa30 drivers/input/serio/serio.c:227 process_one_work+0x996/0x1610 kernel/workqueue.c:2289 worker_thread+0x665/0x1080 kernel/workqueue.c:2436 kthread+0x2e9/0x3a0 kernel/kthread.c:376 ret_from_fork+0x1f/0x30 arch/x86/entry/entry_64.S:306 } ... key at: [] __key.7+0x0/0x40 -> (&client->buffer_lock){....}-{2:2} { INITIAL USE at: lock_acquire kernel/locking/lockdep.c:5665 [inline] lock_acquire+0x1ab/0x570 kernel/locking/lockdep.c:5630 __raw_spin_lock include/linux/spinlock_api_smp.h:133 [inline] _raw_spin_lock+0x2a/0x40 kernel/locking/spinlock.c:154 spin_lock include/linux/spinlock.h:349 [inline] evdev_pass_values.part.0+0xf6/0x970 drivers/input/evdev.c:261 evdev_pass_values drivers/input/evdev.c:253 [inline] evdev_events+0x359/0x3e0 drivers/input/evdev.c:306 input_to_handler+0x2a0/0x4c0 drivers/input/input.c:126 input_pass_values.part.0+0x230/0x710 drivers/input/input.c:156 input_pass_values drivers/input/input.c:145 [inline] input_handle_event+0x373/0x1440 drivers/input/input.c:415 input_inject_event+0x1bd/0x320 drivers/input/input.c:487 evdev_write+0x430/0x760 drivers/input/evdev.c:530 vfs_write+0x269/0xac0 fs/read_write.c:589 ksys_write+0x1e8/0x250 fs/read_write.c:644 do_syscall_x64 arch/x86/entry/common.c:50 [inline] do_syscall_64+0x35/0xb0 arch/x86/entry/common.c:80 entry_SYSCALL_64_after_hwframe+0x63/0xcd } ... key at: [] __key.3+0x0/0x40 ... acquired at: __raw_spin_lock include/linux/spinlock_api_smp.h:133 [inline] _raw_spin_lock+0x2a/0x40 kernel/locking/spinlock.c:154 spin_lock include/linux/spinlock.h:349 [inline] evdev_pass_values.part.0+0xf6/0x970 drivers/input/evdev.c:261 evdev_pass_values drivers/input/evdev.c:253 [inline] evdev_events+0x359/0x3e0 drivers/input/evdev.c:306 input_to_handler+0x2a0/0x4c0 drivers/input/input.c:126 input_pass_values.part.0+0x230/0x710 drivers/input/input.c:156 input_pass_values drivers/input/input.c:145 [inline] input_handle_event+0x373/0x1440 drivers/input/input.c:415 input_inject_event+0x1bd/0x320 drivers/input/input.c:487 evdev_write+0x430/0x760 drivers/input/evdev.c:530 vfs_write+0x269/0xac0 fs/read_write.c:589 ksys_write+0x1e8/0x250 fs/read_write.c:644 do_syscall_x64 arch/x86/entry/common.c:50 [inline] do_syscall_64+0x35/0xb0 arch/x86/entry/common.c:80 entry_SYSCALL_64_after_hwframe+0x63/0xcd -> (&new->fa_lock){....}-{2:2} { INITIAL READ USE at: lock_acquire kernel/locking/lockdep.c:5665 [inline] lock_acquire+0x1ab/0x570 kernel/locking/lockdep.c:5630 __raw_read_lock_irqsave include/linux/rwlock_api_smp.h:160 [inline] _raw_read_lock_irqsave+0x70/0x90 kernel/locking/spinlock.c:236 kill_fasync_rcu fs/fcntl.c:995 [inline] kill_fasync fs/fcntl.c:1016 [inline] kill_fasync+0x136/0x470 fs/fcntl.c:1009 __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+0x359/0x3e0 drivers/input/evdev.c:306 input_to_handler+0x2a0/0x4c0 drivers/input/input.c:126 input_pass_values.part.0+0x230/0x710 drivers/input/input.c:156 input_pass_values drivers/input/input.c:145 [inline] input_handle_event+0x373/0x1440 drivers/input/input.c:415 input_inject_event+0x1bd/0x320 drivers/input/input.c:487 evdev_write+0x430/0x760 drivers/input/evdev.c:530 vfs_write+0x269/0xac0 fs/read_write.c:589 ksys_write+0x1e8/0x250 fs/read_write.c:644 do_syscall_x64 arch/x86/entry/common.c:50 [inline] do_syscall_64+0x35/0xb0 arch/x86/entry/common.c:80 entry_SYSCALL_64_after_hwframe+0x63/0xcd } ... key at: [] __key.0+0x0/0x40 ... acquired at: __raw_read_lock_irqsave include/linux/rwlock_api_smp.h:160 [inline] _raw_read_lock_irqsave+0x70/0x90 kernel/locking/spinlock.c:236 kill_fasync_rcu fs/fcntl.c:995 [inline] kill_fasync fs/fcntl.c:1016 [inline] kill_fasync+0x136/0x470 fs/fcntl.c:1009 __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+0x359/0x3e0 drivers/input/evdev.c:306 input_to_handler+0x2a0/0x4c0 drivers/input/input.c:126 input_pass_values.part.0+0x230/0x710 drivers/input/input.c:156 input_pass_values drivers/input/input.c:145 [inline] input_handle_event+0x373/0x1440 drivers/input/input.c:415 input_inject_event+0x1bd/0x320 drivers/input/input.c:487 evdev_write+0x430/0x760 drivers/input/evdev.c:530 vfs_write+0x269/0xac0 fs/read_write.c:589 ksys_write+0x1e8/0x250 fs/read_write.c:644 do_syscall_x64 arch/x86/entry/common.c:50 [inline] do_syscall_64+0x35/0xb0 arch/x86/entry/common.c:80 entry_SYSCALL_64_after_hwframe+0x63/0xcd the dependencies between the lock to be acquired and HARDIRQ-irq-unsafe lock: -> (tasklist_lock){.+.+}-{2:2} { HARDIRQ-ON-R at: lock_acquire kernel/locking/lockdep.c:5665 [inline] lock_acquire+0x1ab/0x570 kernel/locking/lockdep.c:5630 __raw_read_lock include/linux/rwlock_api_smp.h:150 [inline] _raw_read_lock+0x5b/0x70 kernel/locking/spinlock.c:228 do_wait+0x284/0xce0 kernel/exit.c:1508 kernel_wait+0x9c/0x150 kernel/exit.c:1698 call_usermodehelper_exec_sync kernel/umh.c:139 [inline] call_usermodehelper_exec_work+0xf5/0x180 kernel/umh.c:166 process_one_work+0x996/0x1610 kernel/workqueue.c:2289 worker_thread+0x665/0x1080 kernel/workqueue.c:2436 kthread+0x2e9/0x3a0 kernel/kthread.c:376 ret_from_fork+0x1f/0x30 arch/x86/entry/entry_64.S:306 SOFTIRQ-ON-R at: lock_acquire kernel/locking/lockdep.c:5665 [inline] lock_acquire+0x1ab/0x570 kernel/locking/lockdep.c:5630 __raw_read_lock include/linux/rwlock_api_smp.h:150 [inline] _raw_read_lock+0x5b/0x70 kernel/locking/spinlock.c:228 do_wait+0x284/0xce0 kernel/exit.c:1508 kernel_wait+0x9c/0x150 kernel/exit.c:1698 call_usermodehelper_exec_sync kernel/umh.c:139 [inline] call_usermodehelper_exec_work+0xf5/0x180 kernel/umh.c:166 process_one_work+0x996/0x1610 kernel/workqueue.c:2289 worker_thread+0x665/0x1080 kernel/workqueue.c:2436 kthread+0x2e9/0x3a0 kernel/kthread.c:376 ret_from_fork+0x1f/0x30 arch/x86/entry/entry_64.S:306 INITIAL USE at: lock_acquire kernel/locking/lockdep.c:5665 [inline] lock_acquire+0x1ab/0x570 kernel/locking/lockdep.c:5630 __raw_write_lock_irq include/linux/rwlock_api_smp.h:195 [inline] _raw_write_lock_irq+0x32/0x50 kernel/locking/spinlock.c:326 copy_process+0x445e/0x7020 kernel/fork.c:2374 kernel_clone+0xe7/0xab0 kernel/fork.c:2655 user_mode_thread+0xad/0xe0 kernel/fork.c:2724 rest_init+0x23/0x270 init/main.c:691 arch_call_rest_init+0xf/0x14 init/main.c:882 start_kernel+0x46e/0x48f init/main.c:1137 secondary_startup_64_no_verify+0xce/0xdb INITIAL READ USE at: lock_acquire kernel/locking/lockdep.c:5665 [inline] lock_acquire+0x1ab/0x570 kernel/locking/lockdep.c:5630 __raw_read_lock include/linux/rwlock_api_smp.h:150 [inline] _raw_read_lock+0x5b/0x70 kernel/locking/spinlock.c:228 do_wait+0x284/0xce0 kernel/exit.c:1508 kernel_wait+0x9c/0x150 kernel/exit.c:1698 call_usermodehelper_exec_sync kernel/umh.c:139 [inline] call_usermodehelper_exec_work+0xf5/0x180 kernel/umh.c:166 process_one_work+0x996/0x1610 kernel/workqueue.c:2289 worker_thread+0x665/0x1080 kernel/workqueue.c:2436 kthread+0x2e9/0x3a0 kernel/kthread.c:376 ret_from_fork+0x1f/0x30 arch/x86/entry/entry_64.S:306 } ... key at: [] tasklist_lock+0x18/0x40 ... acquired at: __raw_read_lock include/linux/rwlock_api_smp.h:150 [inline] _raw_read_lock+0x5b/0x70 kernel/locking/spinlock.c:228 send_sigio+0xab/0x380 fs/fcntl.c:791 dnotify_handle_event+0x148/0x280 fs/notify/dnotify/dnotify.c:115 fsnotify_handle_inode_event.isra.0+0x22e/0x370 fs/notify/fsnotify.c:264 fsnotify_handle_event fs/notify/fsnotify.c:316 [inline] send_to_group fs/notify/fsnotify.c:362 [inline] fsnotify+0xec5/0x13a0 fs/notify/fsnotify.c:567 fsnotify_name include/linux/fsnotify.h:36 [inline] fsnotify_name include/linux/fsnotify.h:29 [inline] fsnotify_dirent include/linux/fsnotify.h:42 [inline] fsnotify_create include/linux/fsnotify.h:207 [inline] vfs_symlink fs/namei.c:4343 [inline] vfs_symlink+0x242/0x2c0 fs/namei.c:4326 do_symlinkat+0x261/0x2e0 fs/namei.c:4370 __do_sys_symlinkat fs/namei.c:4387 [inline] __se_sys_symlinkat fs/namei.c:4384 [inline] __x64_sys_symlinkat+0x93/0xc0 fs/namei.c:4384 do_syscall_x64 arch/x86/entry/common.c:50 [inline] do_syscall_64+0x35/0xb0 arch/x86/entry/common.c:80 entry_SYSCALL_64_after_hwframe+0x63/0xcd -> (&f->f_owner.lock){....}-{2:2} { INITIAL USE at: lock_acquire kernel/locking/lockdep.c:5665 [inline] lock_acquire+0x1ab/0x570 kernel/locking/lockdep.c:5630 __raw_write_lock_irq include/linux/rwlock_api_smp.h:195 [inline] _raw_write_lock_irq+0x32/0x50 kernel/locking/spinlock.c:326 f_modown+0x2a/0x390 fs/fcntl.c:90 fcntl_dirnotify+0x9f3/0xf30 fs/notify/dnotify/dnotify.c:369 do_fcntl+0x24c/0x1040 fs/fcntl.c:405 __do_sys_fcntl fs/fcntl.c:453 [inline] __se_sys_fcntl fs/fcntl.c:438 [inline] __x64_sys_fcntl+0x15f/0x1d0 fs/fcntl.c:438 do_syscall_x64 arch/x86/entry/common.c:50 [inline] do_syscall_64+0x35/0xb0 arch/x86/entry/common.c:80 entry_SYSCALL_64_after_hwframe+0x63/0xcd INITIAL READ USE at: lock_acquire kernel/locking/lockdep.c:5665 [inline] lock_acquire+0x1ab/0x570 kernel/locking/lockdep.c:5630 __raw_read_lock_irqsave include/linux/rwlock_api_smp.h:160 [inline] _raw_read_lock_irqsave+0x70/0x90 kernel/locking/spinlock.c:236 send_sigio+0x24/0x380 fs/fcntl.c:777 dnotify_handle_event+0x148/0x280 fs/notify/dnotify/dnotify.c:115 fsnotify_handle_inode_event.isra.0+0x22e/0x370 fs/notify/fsnotify.c:264 fsnotify_handle_event fs/notify/fsnotify.c:316 [inline] send_to_group fs/notify/fsnotify.c:362 [inline] fsnotify+0xec5/0x13a0 fs/notify/fsnotify.c:567 fsnotify_name include/linux/fsnotify.h:36 [inline] fsnotify_name include/linux/fsnotify.h:29 [inline] fsnotify_dirent include/linux/fsnotify.h:42 [inline] fsnotify_create include/linux/fsnotify.h:207 [inline] vfs_symlink fs/namei.c:4343 [inline] vfs_symlink+0x242/0x2c0 fs/namei.c:4326 do_symlinkat+0x261/0x2e0 fs/namei.c:4370 __do_sys_symlinkat fs/namei.c:4387 [inline] __se_sys_symlinkat fs/namei.c:4384 [inline] __x64_sys_symlinkat+0x93/0xc0 fs/namei.c:4384 do_syscall_x64 arch/x86/entry/common.c:50 [inline] do_syscall_64+0x35/0xb0 arch/x86/entry/common.c:80 entry_SYSCALL_64_after_hwframe+0x63/0xcd } ... key at: [] __key.5+0x0/0x40 ... acquired at: lock_acquire kernel/locking/lockdep.c:5665 [inline] lock_acquire+0x1ab/0x570 kernel/locking/lockdep.c:5630 __raw_read_lock_irqsave include/linux/rwlock_api_smp.h:160 [inline] _raw_read_lock_irqsave+0x70/0x90 kernel/locking/spinlock.c:236 send_sigio+0x24/0x380 fs/fcntl.c:777 kill_fasync_rcu fs/fcntl.c:1002 [inline] kill_fasync fs/fcntl.c:1016 [inline] kill_fasync+0x1f8/0x470 fs/fcntl.c:1009 __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+0x359/0x3e0 drivers/input/evdev.c:306 input_to_handler+0x2a0/0x4c0 drivers/input/input.c:126 input_pass_values.part.0+0x230/0x710 drivers/input/input.c:156 input_pass_values drivers/input/input.c:145 [inline] input_handle_event+0x373/0x1440 drivers/input/input.c:415 input_inject_event+0x1bd/0x320 drivers/input/input.c:487 evdev_write+0x430/0x760 drivers/input/evdev.c:530 vfs_write+0x269/0xac0 fs/read_write.c:589 ksys_write+0x1e8/0x250 fs/read_write.c:644 do_syscall_x64 arch/x86/entry/common.c:50 [inline] do_syscall_64+0x35/0xb0 arch/x86/entry/common.c:80 entry_SYSCALL_64_after_hwframe+0x63/0xcd stack backtrace: CPU: 0 PID: 3616 Comm: syz-executor974 Not tainted 5.19.0-rc6-syzkaller-00104-g72a8e05d4f66 #0 Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 06/29/2022 Call Trace: __dump_stack lib/dump_stack.c:88 [inline] dump_stack_lvl+0xcd/0x134 lib/dump_stack.c:106 print_bad_irq_dependency kernel/locking/lockdep.c:2609 [inline] check_irq_usage.cold+0x4c1/0x6b0 kernel/locking/lockdep.c:2848 check_prev_add kernel/locking/lockdep.c:3099 [inline] check_prevs_add kernel/locking/lockdep.c:3214 [inline] validate_chain kernel/locking/lockdep.c:3829 [inline] __lock_acquire+0x2ad6/0x5660 kernel/locking/lockdep.c:5053 lock_acquire kernel/locking/lockdep.c:5665 [inline] lock_acquire+0x1ab/0x570 kernel/locking/lockdep.c:5630 __raw_read_lock_irqsave include/linux/rwlock_api_smp.h:160 [inline] _raw_read_lock_irqsave+0x70/0x90 kernel/locking/spinlock.c:236 send_sigio+0x24/0x380 fs/fcntl.c:777 kill_fasync_rcu fs/fcntl.c:1002 [inline] kill_fasync fs/fcntl.c:1016 [inline] kill_fasync+0x1f8/0x470 fs/fcntl.c:1009 __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+0x359/0x3e0 drivers/input/evdev.c:306 input_to_handler+0x2a0/0x4c0 drivers/input/input.c:126 input_pass_values.part.0+0x230/0x710 drivers/input/input.c:156 input_pass_values drivers/input/input.c:145 [inline] input_handle_event+0x373/0x1440 drivers/input/input.c:415 input_inject_event+0x1bd/0x320 drivers/input/input.c:487 evdev_write+0x430/0x760 drivers/input/evdev.c:530 vfs_write+0x269/0xac0 fs/read_write.c:589 ksys_write+0x1e8/0x250 fs/read_write.c:644 do_syscall_x64 arch/x86/entry/common.c:50 [inline] do_syscall_64+0x35/0xb0 arch/x86/entry/common.c:80 entry_SYSCALL_64_after_hwframe+0x63/0xcd RIP: 0033:0x7fcf30b707f9 Code: 28 c3 e8 2a 14 00 00 66 2e 0f 1f 84 00 00 00 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 c0 ff ff ff f7 d8 64 89 01 48 RSP: 002b:00007fff75a22c48 EFLAGS: 00000246 ORIG_RAX: 0000000000000001 RAX: ffffffffffffffda RBX: 0000000000000000 RCX: 00007fcf30b707f9 RDX: 0000000000000373 RSI: 0000000020000040 RDI: 0000000000000005 RBP: 00007fcf30b30300 R08: 0000000000000000 R09: 0000000000000000 R10: 0000000000000000 R11: 0000000000000246 R12: 00007fcf30b30390 R13: 0000000000000000 R14: 0000000000000000