===================================================== WARNING: HARDIRQ-safe -> HARDIRQ-unsafe lock order detected syzkaller #0 Not tainted ----------------------------------------------------- syz.0.2500/16940 [HC0[0]:SC0[0]:HE0:SE1] is trying to acquire: ffff88805902f2b8 (&new->fa_lock){....}-{2:2}, at: kill_fasync_rcu fs/fcntl.c:990 [inline] ffff88805902f2b8 (&new->fa_lock){....}-{2:2}, at: kill_fasync+0x192/0x4b0 fs/fcntl.c:1011 and this task is already holding: ffff888026248230 (&dev->event_lock#2){-.-.}-{2:2}, at: input_inject_event+0xab/0x320 drivers/input/input.c:460 which would create a new lock dependency: (&dev->event_lock#2){-.-.}-{2:2} -> (&new->fa_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+0x197/0x410 kernel/locking/lockdep.c:5754 __raw_spin_lock_irqsave include/linux/spinlock_api_smp.h:110 [inline] _raw_spin_lock_irqsave+0xa8/0xf0 kernel/locking/spinlock.c:162 input_event+0x7a/0xc0 drivers/input/input.c:434 input_report_key include/linux/input.h:425 [inline] psmouse_report_standard_buttons drivers/input/mouse/psmouse-base.c:128 [inline] psmouse_report_standard_packet+0x53/0x200 drivers/input/mouse/psmouse-base.c:146 psmouse_process_byte+0x478/0x670 drivers/input/mouse/psmouse-base.c:237 psmouse_handle_byte+0x43/0x490 drivers/input/mouse/psmouse-base.c:279 ps2_interrupt+0x164/0x980 drivers/input/serio/libps2.c:613 serio_interrupt+0x8b/0x130 drivers/input/serio/serio.c:998 i8042_interrupt+0x394/0x730 drivers/input/serio/i8042.c:610 __handle_irq_event_percpu+0x276/0x930 kernel/irq/handle.c:158 handle_irq_event_percpu kernel/irq/handle.c:193 [inline] handle_irq_event+0x8b/0x1e0 kernel/irq/handle.c:210 handle_edge_irq+0x247/0xb30 kernel/irq/chip.c:831 generic_handle_irq_desc include/linux/irqdesc.h:161 [inline] handle_irq arch/x86/kernel/irq.c:240 [inline] __common_interrupt+0x13b/0x230 arch/x86/kernel/irq.c:259 common_interrupt+0xb4/0xd0 arch/x86/kernel/irq.c:249 asm_common_interrupt+0x26/0x40 arch/x86/include/asm/idtentry.h:678 __raw_spin_unlock_irqrestore include/linux/spinlock_api_smp.h:152 [inline] _raw_spin_unlock_irqrestore+0xa9/0x110 kernel/locking/spinlock.c:194 spin_unlock_irqrestore include/linux/spinlock.h:406 [inline] i8042_command drivers/input/serio/i8042.c:360 [inline] i8042_aux_write+0x109/0x170 drivers/input/serio/i8042.c:395 serio_write include/linux/serio.h:126 [inline] ps2_do_sendbyte+0x1ff/0x6d0 drivers/input/serio/libps2.c:58 ps2_sendbyte+0x5f/0x120 drivers/input/serio/libps2.c:113 cypress_ps2_sendbyte drivers/input/mouse/cypress_ps2.c:42 [inline] cypress_ps2_read_cmd_status drivers/input/mouse/cypress_ps2.c:116 [inline] cypress_send_ext_cmd+0x23d/0x920 drivers/input/mouse/cypress_ps2.c:189 cypress_detect+0x8d/0x190 drivers/input/mouse/cypress_ps2.c:205 psmouse_do_detect drivers/input/mouse/psmouse-base.c:1006 [inline] psmouse_try_protocol drivers/input/mouse/psmouse-base.c:1020 [inline] psmouse_extensions+0x467/0xbe0 drivers/input/mouse/psmouse-base.c:1143 psmouse_switch_protocol+0xdc/0x610 drivers/input/mouse/psmouse-base.c:1537 psmouse_connect+0x89f/0x1470 drivers/input/mouse/psmouse-base.c:1626 serio_connect_driver drivers/input/serio/serio.c:44 [inline] serio_driver_probe+0x7a/0xa0 drivers/input/serio/serio.c:775 call_driver_probe drivers/base/dd.c:-1 [inline] really_probe+0x25b/0xb40 drivers/base/dd.c:658 __driver_probe_device+0x18c/0x330 drivers/base/dd.c:800 driver_probe_device+0x4f/0x420 drivers/base/dd.c:830 __driver_attach+0x44e/0x6f0 drivers/base/dd.c:1216 bus_for_each_dev+0x22d/0x2a0 drivers/base/bus.c:370 serio_attach_driver drivers/input/serio/serio.c:804 [inline] serio_handle_event+0x1a2/0x860 drivers/input/serio/serio.c:224 process_one_work kernel/workqueue.c:2634 [inline] process_scheduled_works+0xa45/0x15b0 kernel/workqueue.c:2711 worker_thread+0xa55/0xfc0 kernel/workqueue.c:2792 kthread+0x2fa/0x390 kernel/kthread.c:388 ret_from_fork+0x48/0x80 arch/x86/kernel/process.c:152 ret_from_fork_asm+0x11/0x20 arch/x86/entry/entry_64.S:293 to a HARDIRQ-irq-unsafe lock: (tasklist_lock){.+.+}-{2:2} ... which became HARDIRQ-irq-unsafe at: ... lock_acquire+0x197/0x410 kernel/locking/lockdep.c:5754 __raw_read_lock include/linux/rwlock_api_smp.h:150 [inline] _raw_read_lock+0x36/0x50 kernel/locking/spinlock.c:228 do_wait+0x294/0xaf0 kernel/exit.c:1607 kernel_wait+0xac/0x170 kernel/exit.c:1797 call_usermodehelper_exec_sync kernel/umh.c:137 [inline] call_usermodehelper_exec_work+0xb9/0x220 kernel/umh.c:164 process_one_work kernel/workqueue.c:2634 [inline] process_scheduled_works+0xa45/0x15b0 kernel/workqueue.c:2711 worker_thread+0xa55/0xfc0 kernel/workqueue.c:2792 kthread+0x2fa/0x390 kernel/kthread.c:388 ret_from_fork+0x48/0x80 arch/x86/kernel/process.c:152 ret_from_fork_asm+0x11/0x20 arch/x86/entry/entry_64.S:293 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 *** 6 locks held by syz.0.2500/16940: #0: ffff88802624a110 (&evdev->mutex){+.+.}-{3:3}, at: evdev_write+0x17b/0x470 drivers/input/evdev.c:513 #1: ffff888026248230 (&dev->event_lock#2){-.-.}-{2:2}, at: input_inject_event+0xab/0x320 drivers/input/input.c:460 #2: ffffffff8cd2fc20 (rcu_read_lock){....}-{1:2}, at: rcu_lock_acquire include/linux/rcupdate.h:334 [inline] #2: ffffffff8cd2fc20 (rcu_read_lock){....}-{1:2}, at: rcu_read_lock include/linux/rcupdate.h:786 [inline] #2: ffffffff8cd2fc20 (rcu_read_lock){....}-{1:2}, at: input_inject_event+0xbc/0x320 drivers/input/input.c:462 #3: ffffffff8cd2fc20 (rcu_read_lock){....}-{1:2}, at: rcu_lock_acquire include/linux/rcupdate.h:334 [inline] #3: ffffffff8cd2fc20 (rcu_read_lock){....}-{1:2}, at: rcu_read_lock include/linux/rcupdate.h:786 [inline] #3: ffffffff8cd2fc20 (rcu_read_lock){....}-{1:2}, at: input_pass_values+0xa3/0x1300 drivers/input/input.c:153 #4: ffffffff8cd2fc20 (rcu_read_lock){....}-{1:2}, at: rcu_lock_acquire include/linux/rcupdate.h:334 [inline] #4: ffffffff8cd2fc20 (rcu_read_lock){....}-{1:2}, at: rcu_read_lock include/linux/rcupdate.h:786 [inline] #4: ffffffff8cd2fc20 (rcu_read_lock){....}-{1:2}, at: mousedev_notify_readers+0x2c/0xc00 drivers/input/mousedev.c:269 #5: ffffffff8cd2fc20 (rcu_read_lock){....}-{1:2}, at: rcu_lock_acquire include/linux/rcupdate.h:334 [inline] #5: ffffffff8cd2fc20 (rcu_read_lock){....}-{1:2}, at: rcu_read_lock include/linux/rcupdate.h:786 [inline] #5: ffffffff8cd2fc20 (rcu_read_lock){....}-{1:2}, at: kill_fasync+0x53/0x4b0 fs/fcntl.c:1010 the dependencies between HARDIRQ-irq-safe lock and the holding lock: -> (&dev->event_lock#2){-.-.}-{2:2} { IN-HARDIRQ-W at: lock_acquire+0x197/0x410 kernel/locking/lockdep.c:5754 __raw_spin_lock_irqsave include/linux/spinlock_api_smp.h:110 [inline] _raw_spin_lock_irqsave+0xa8/0xf0 kernel/locking/spinlock.c:162 input_event+0x7a/0xc0 drivers/input/input.c:434 input_report_key include/linux/input.h:425 [inline] psmouse_report_standard_buttons drivers/input/mouse/psmouse-base.c:128 [inline] psmouse_report_standard_packet+0x53/0x200 drivers/input/mouse/psmouse-base.c:146 psmouse_process_byte+0x478/0x670 drivers/input/mouse/psmouse-base.c:237 psmouse_handle_byte+0x43/0x490 drivers/input/mouse/psmouse-base.c:279 ps2_interrupt+0x164/0x980 drivers/input/serio/libps2.c:613 serio_interrupt+0x8b/0x130 drivers/input/serio/serio.c:998 i8042_interrupt+0x394/0x730 drivers/input/serio/i8042.c:610 __handle_irq_event_percpu+0x276/0x930 kernel/irq/handle.c:158 handle_irq_event_percpu kernel/irq/handle.c:193 [inline] handle_irq_event+0x8b/0x1e0 kernel/irq/handle.c:210 handle_edge_irq+0x247/0xb30 kernel/irq/chip.c:831 generic_handle_irq_desc include/linux/irqdesc.h:161 [inline] handle_irq arch/x86/kernel/irq.c:240 [inline] __common_interrupt+0x13b/0x230 arch/x86/kernel/irq.c:259 common_interrupt+0xb4/0xd0 arch/x86/kernel/irq.c:249 asm_common_interrupt+0x26/0x40 arch/x86/include/asm/idtentry.h:678 __raw_spin_unlock_irqrestore include/linux/spinlock_api_smp.h:152 [inline] _raw_spin_unlock_irqrestore+0xa9/0x110 kernel/locking/spinlock.c:194 spin_unlock_irqrestore include/linux/spinlock.h:406 [inline] i8042_command drivers/input/serio/i8042.c:360 [inline] i8042_aux_write+0x109/0x170 drivers/input/serio/i8042.c:395 serio_write include/linux/serio.h:126 [inline] ps2_do_sendbyte+0x1ff/0x6d0 drivers/input/serio/libps2.c:58 ps2_sendbyte+0x5f/0x120 drivers/input/serio/libps2.c:113 cypress_ps2_sendbyte drivers/input/mouse/cypress_ps2.c:42 [inline] cypress_ps2_read_cmd_status drivers/input/mouse/cypress_ps2.c:116 [inline] cypress_send_ext_cmd+0x23d/0x920 drivers/input/mouse/cypress_ps2.c:189 cypress_detect+0x8d/0x190 drivers/input/mouse/cypress_ps2.c:205 psmouse_do_detect drivers/input/mouse/psmouse-base.c:1006 [inline] psmouse_try_protocol drivers/input/mouse/psmouse-base.c:1020 [inline] psmouse_extensions+0x467/0xbe0 drivers/input/mouse/psmouse-base.c:1143 psmouse_switch_protocol+0xdc/0x610 drivers/input/mouse/psmouse-base.c:1537 psmouse_connect+0x89f/0x1470 drivers/input/mouse/psmouse-base.c:1626 serio_connect_driver drivers/input/serio/serio.c:44 [inline] serio_driver_probe+0x7a/0xa0 drivers/input/serio/serio.c:775 call_driver_probe drivers/base/dd.c:-1 [inline] really_probe+0x25b/0xb40 drivers/base/dd.c:658 __driver_probe_device+0x18c/0x330 drivers/base/dd.c:800 driver_probe_device+0x4f/0x420 drivers/base/dd.c:830 __driver_attach+0x44e/0x6f0 drivers/base/dd.c:1216 bus_for_each_dev+0x22d/0x2a0 drivers/base/bus.c:370 serio_attach_driver drivers/input/serio/serio.c:804 [inline] serio_handle_event+0x1a2/0x860 drivers/input/serio/serio.c:224 process_one_work kernel/workqueue.c:2634 [inline] process_scheduled_works+0xa45/0x15b0 kernel/workqueue.c:2711 worker_thread+0xa55/0xfc0 kernel/workqueue.c:2792 kthread+0x2fa/0x390 kernel/kthread.c:388 ret_from_fork+0x48/0x80 arch/x86/kernel/process.c:152 ret_from_fork_asm+0x11/0x20 arch/x86/entry/entry_64.S:293 IN-SOFTIRQ-W at: lock_acquire+0x197/0x410 kernel/locking/lockdep.c:5754 __raw_spin_lock_irqsave include/linux/spinlock_api_smp.h:110 [inline] _raw_spin_lock_irqsave+0xa8/0xf0 kernel/locking/spinlock.c:162 input_event+0x7a/0xc0 drivers/input/input.c:434 input_report_key include/linux/input.h:425 [inline] atp_complete_geyser_3_4+0x11ea/0x1e70 drivers/input/mouse/appletouch.c:762 __usb_hcd_giveback_urb+0x35f/0x520 drivers/usb/core/hcd.c:1650 dummy_timer+0x8a3/0x31b0 drivers/usb/gadget/udc/dummy_hcd.c:1993 __run_hrtimer kernel/time/hrtimer.c:1755 [inline] __hrtimer_run_queues+0x51e/0xc40 kernel/time/hrtimer.c:1819 hrtimer_run_softirq+0x187/0x2b0 kernel/time/hrtimer.c:1836 handle_softirqs+0x280/0x820 kernel/softirq.c:578 __do_softirq kernel/softirq.c:612 [inline] invoke_softirq kernel/softirq.c:452 [inline] __irq_exit_rcu+0xc7/0x190 kernel/softirq.c:661 irq_exit_rcu+0x9/0x20 kernel/softirq.c:673 instr_sysvec_apic_timer_interrupt arch/x86/kernel/apic/apic.c:1088 [inline] sysvec_apic_timer_interrupt+0xa4/0xc0 arch/x86/kernel/apic/apic.c:1088 asm_sysvec_apic_timer_interrupt+0x1a/0x20 arch/x86/include/asm/idtentry.h:687 __raw_spin_unlock_irqrestore include/linux/spinlock_api_smp.h:152 [inline] _raw_spin_unlock_irqrestore+0xa9/0x110 kernel/locking/spinlock.c:194 spin_unlock_irqrestore include/linux/spinlock.h:406 [inline] dummy_urb_enqueue+0x58a/0x780 drivers/usb/gadget/udc/dummy_hcd.c:1314 usb_hcd_submit_urb+0x313/0x1a90 drivers/usb/core/hcd.c:1535 atp_open+0x63/0xc0 drivers/input/mouse/appletouch.c:800 input_open_device+0x170/0x2e0 drivers/input/input.c:654 mousedev_open_device+0xc7/0x150 drivers/input/mousedev.c:430 mousedev_open+0x2e9/0x4a0 drivers/input/mousedev.c:556 chrdev_open+0x59e/0x670 fs/char_dev.c:414 do_dentry_open+0x8c6/0x1500 fs/open.c:929 do_open fs/namei.c:3632 [inline] path_openat+0x274b/0x3190 fs/namei.c:3789 do_filp_open+0x1c5/0x3d0 fs/namei.c:3816 do_sys_openat2+0x12c/0x1c0 fs/open.c:1419 do_sys_open fs/open.c:1434 [inline] __do_sys_openat fs/open.c:1450 [inline] __se_sys_openat fs/open.c:1445 [inline] __x64_sys_openat+0x139/0x160 fs/open.c:1445 do_syscall_x64 arch/x86/entry/common.c:51 [inline] do_syscall_64+0x55/0xb0 arch/x86/entry/common.c:81 entry_SYSCALL_64_after_hwframe+0x68/0xd2 INITIAL USE at: lock_acquire+0x197/0x410 kernel/locking/lockdep.c:5754 __raw_spin_lock_irqsave include/linux/spinlock_api_smp.h:110 [inline] _raw_spin_lock_irqsave+0xa8/0xf0 kernel/locking/spinlock.c:162 input_inject_event+0xab/0x320 drivers/input/input.c:460 led_trigger_event+0x133/0x210 drivers/leds/led-triggers.c:393 kbd_led_trigger_activate+0xbd/0x100 drivers/tty/vt/keyboard.c:1036 led_trigger_set+0x524/0x940 drivers/leds/led-triggers.c:212 led_trigger_set_default+0x1a0/0x1e0 drivers/leds/led-triggers.c:276 led_classdev_register_ext+0x6e9/0x940 drivers/leds/led-class.c:562 led_classdev_register include/linux/leds.h:279 [inline] input_leds_connect+0x4eb/0x6b0 drivers/input/input-leds.c:139 input_attach_handler drivers/input/input.c:1064 [inline] input_register_device+0xcdc/0x1070 drivers/input/input.c:2470 atkbd_connect+0x6fb/0x9a0 drivers/input/keyboard/atkbd.c:1342 serio_connect_driver drivers/input/serio/serio.c:44 [inline] serio_driver_probe+0x7a/0xa0 drivers/input/serio/serio.c:775 call_driver_probe drivers/base/dd.c:-1 [inline] really_probe+0x25b/0xb40 drivers/base/dd.c:658 __driver_probe_device+0x18c/0x330 drivers/base/dd.c:800 driver_probe_device+0x4f/0x420 drivers/base/dd.c:830 __driver_attach+0x44e/0x6f0 drivers/base/dd.c:1216 bus_for_each_dev+0x22d/0x2a0 drivers/base/bus.c:370 serio_attach_driver drivers/input/serio/serio.c:804 [inline] serio_handle_event+0x1a2/0x860 drivers/input/serio/serio.c:224 process_one_work kernel/workqueue.c:2634 [inline] process_scheduled_works+0xa45/0x15b0 kernel/workqueue.c:2711 worker_thread+0xa55/0xfc0 kernel/workqueue.c:2792 kthread+0x2fa/0x390 kernel/kthread.c:388 ret_from_fork+0x48/0x80 arch/x86/kernel/process.c:152 ret_from_fork_asm+0x11/0x20 arch/x86/entry/entry_64.S:293 } ... key at: [] input_allocate_device.__key.5+0x0/0x20 the dependencies between the lock to be acquired and HARDIRQ-irq-unsafe lock: -> (tasklist_lock){.+.+}-{2:2} { HARDIRQ-ON-R at: lock_acquire+0x197/0x410 kernel/locking/lockdep.c:5754 __raw_read_lock include/linux/rwlock_api_smp.h:150 [inline] _raw_read_lock+0x36/0x50 kernel/locking/spinlock.c:228 do_wait+0x294/0xaf0 kernel/exit.c:1607 kernel_wait+0xac/0x170 kernel/exit.c:1797 call_usermodehelper_exec_sync kernel/umh.c:137 [inline] call_usermodehelper_exec_work+0xb9/0x220 kernel/umh.c:164 process_one_work kernel/workqueue.c:2634 [inline] process_scheduled_works+0xa45/0x15b0 kernel/workqueue.c:2711 worker_thread+0xa55/0xfc0 kernel/workqueue.c:2792 kthread+0x2fa/0x390 kernel/kthread.c:388 ret_from_fork+0x48/0x80 arch/x86/kernel/process.c:152 ret_from_fork_asm+0x11/0x20 arch/x86/entry/entry_64.S:293 SOFTIRQ-ON-R at: lock_acquire+0x197/0x410 kernel/locking/lockdep.c:5754 __raw_read_lock include/linux/rwlock_api_smp.h:150 [inline] _raw_read_lock+0x36/0x50 kernel/locking/spinlock.c:228 do_wait+0x294/0xaf0 kernel/exit.c:1607 kernel_wait+0xac/0x170 kernel/exit.c:1797 call_usermodehelper_exec_sync kernel/umh.c:137 [inline] call_usermodehelper_exec_work+0xb9/0x220 kernel/umh.c:164 process_one_work kernel/workqueue.c:2634 [inline] process_scheduled_works+0xa45/0x15b0 kernel/workqueue.c:2711 worker_thread+0xa55/0xfc0 kernel/workqueue.c:2792 kthread+0x2fa/0x390 kernel/kthread.c:388 ret_from_fork+0x48/0x80 arch/x86/kernel/process.c:152 ret_from_fork_asm+0x11/0x20 arch/x86/entry/entry_64.S:293 INITIAL USE at: lock_acquire+0x197/0x410 kernel/locking/lockdep.c:5754 __raw_write_lock_irq include/linux/rwlock_api_smp.h:195 [inline] _raw_write_lock_irq+0xa3/0xe0 kernel/locking/spinlock.c:326 copy_process+0x225d/0x3d70 kernel/fork.c:2631 kernel_clone+0x21b/0x840 kernel/fork.c:2914 user_mode_thread+0xde/0x130 kernel/fork.c:2992 rest_init+0x27/0x300 init/main.c:697 arch_call_rest_init+0xe/0x10 init/main.c:829 start_kernel+0x459/0x4e0 init/main.c:1074 x86_64_start_reservations+0x2a/0x30 arch/x86/kernel/head64.c:555 copy_bootdata+0x0/0xe0 arch/x86/kernel/head64.c:536 secondary_startup_64_no_verify+0x179/0x17b INITIAL READ USE at: lock_acquire+0x197/0x410 kernel/locking/lockdep.c:5754 __raw_read_lock include/linux/rwlock_api_smp.h:150 [inline] _raw_read_lock+0x36/0x50 kernel/locking/spinlock.c:228 do_wait+0x294/0xaf0 kernel/exit.c:1607 kernel_wait+0xac/0x170 kernel/exit.c:1797 call_usermodehelper_exec_sync kernel/umh.c:137 [inline] call_usermodehelper_exec_work+0xb9/0x220 kernel/umh.c:164 process_one_work kernel/workqueue.c:2634 [inline] process_scheduled_works+0xa45/0x15b0 kernel/workqueue.c:2711 worker_thread+0xa55/0xfc0 kernel/workqueue.c:2792 kthread+0x2fa/0x390 kernel/kthread.c:388 ret_from_fork+0x48/0x80 arch/x86/kernel/process.c:152 ret_from_fork_asm+0x11/0x20 arch/x86/entry/entry_64.S:293 } ... key at: [] tasklist_lock+0x18/0x40 ... acquired at: __raw_read_lock include/linux/rwlock_api_smp.h:150 [inline] _raw_read_lock+0x36/0x50 kernel/locking/spinlock.c:228 send_sigurg+0xf0/0x3c0 fs/fcntl.c:827 sk_send_sigurg+0x6f/0xc0 net/core/sock.c:3404 tcp_check_urg+0x200/0x750 net/ipv4/tcp_input.c:5772 tcp_urg+0x161/0x3f0 net/ipv4/tcp_input.c:5813 tcp_rcv_established+0xa2e/0x1cf0 net/ipv4/tcp_input.c:6168 tcp_v4_do_rcv+0x4ed/0xb80 net/ipv4/tcp_ipv4.c:1734 sk_backlog_rcv include/net/sock.h:1123 [inline] __release_sock+0x1bd/0x430 net/core/sock.c:3005 release_sock+0x5f/0x1c0 net/core/sock.c:3542 tcp_sendmsg+0x39/0x50 net/ipv4/tcp.c:1345 sock_sendmsg_nosec net/socket.c:730 [inline] __sock_sendmsg net/socket.c:745 [inline] ____sys_sendmsg+0x5bf/0x950 net/socket.c:2595 ___sys_sendmsg+0x220/0x290 net/socket.c:2649 __sys_sendmsg net/socket.c:2678 [inline] __do_sys_sendmsg net/socket.c:2687 [inline] __se_sys_sendmsg+0x1a5/0x270 net/socket.c:2685 do_syscall_x64 arch/x86/entry/common.c:51 [inline] do_syscall_64+0x55/0xb0 arch/x86/entry/common.c:81 entry_SYSCALL_64_after_hwframe+0x68/0xd2 -> (&f->f_owner.lock){...-}-{2:2} { IN-SOFTIRQ-R at: lock_acquire+0x197/0x410 kernel/locking/lockdep.c:5754 __raw_read_lock_irqsave include/linux/rwlock_api_smp.h:160 [inline] _raw_read_lock_irqsave+0xb0/0x100 kernel/locking/spinlock.c:236 send_sigurg+0x29/0x3c0 fs/fcntl.c:811 sk_send_sigurg+0x6f/0xc0 net/core/sock.c:3404 tcp_check_urg+0x200/0x750 net/ipv4/tcp_input.c:5772 tcp_urg+0x161/0x3f0 net/ipv4/tcp_input.c:5813 tcp_rcv_established+0xa2e/0x1cf0 net/ipv4/tcp_input.c:6168 tcp_v4_do_rcv+0x4ed/0xb80 net/ipv4/tcp_ipv4.c:1734 tcp_v4_rcv+0x2334/0x2a50 net/ipv4/tcp_ipv4.c:2166 ip_protocol_deliver_rcu+0x20e/0x3f0 net/ipv4/ip_input.c:205 ip_local_deliver_finish+0x2ca/0x510 net/ipv4/ip_input.c:233 NF_HOOK+0x303/0x390 include/linux/netfilter.h:304 NF_HOOK+0x303/0x390 include/linux/netfilter.h:304 __netif_receive_skb_one_core net/core/dev.c:5608 [inline] __netif_receive_skb+0xcc/0x290 net/core/dev.c:5722 process_backlog+0x380/0x6e0 net/core/dev.c:6050 __napi_poll+0xc0/0x460 net/core/dev.c:6612 napi_poll net/core/dev.c:6679 [inline] net_rx_action+0x5ea/0xbf0 net/core/dev.c:6815 handle_softirqs+0x280/0x820 kernel/softirq.c:578 __do_softirq kernel/softirq.c:612 [inline] invoke_softirq kernel/softirq.c:452 [inline] __irq_exit_rcu+0xc7/0x190 kernel/softirq.c:661 irq_exit_rcu+0x9/0x20 kernel/softirq.c:673 instr_sysvec_apic_timer_interrupt arch/x86/kernel/apic/apic.c:1088 [inline] sysvec_apic_timer_interrupt+0xa4/0xc0 arch/x86/kernel/apic/apic.c:1088 asm_sysvec_apic_timer_interrupt+0x1a/0x20 arch/x86/include/asm/idtentry.h:687 unwind_next_frame+0x164d/0x2970 arch/x86/kernel/unwind_orc.c:-1 arch_stack_walk+0x144/0x190 arch/x86/kernel/stacktrace.c:25 stack_trace_save+0x9c/0xe0 kernel/stacktrace.c:122 save_stack+0xf7/0x1f0 mm/page_owner.c:128 __set_page_owner+0x1d/0x60 mm/page_owner.c:192 set_page_owner include/linux/page_owner.h:31 [inline] post_alloc_hook+0x1cd/0x210 mm/page_alloc.c:1554 prep_new_page mm/page_alloc.c:1561 [inline] get_page_from_freelist+0x195c/0x19f0 mm/page_alloc.c:3191 __alloc_pages+0x1e3/0x460 mm/page_alloc.c:4457 __folio_alloc+0x10/0x20 mm/page_alloc.c:4489 vma_alloc_folio+0x47a/0x8f0 mm/mempolicy.c:2242 shmem_alloc_folio+0x179/0x230 mm/shmem.c:1680 shmem_alloc_and_acct_folio+0x189/0x630 mm/shmem.c:1705 shmem_get_folio_gfp+0xcde/0x2ac0 mm/shmem.c:2042 shmem_get_folio mm/shmem.c:2165 [inline] shmem_write_begin+0xf2/0x420 mm/shmem.c:2707 generic_perform_write+0x2fb/0x5b0 mm/filemap.c:4016 shmem_file_write_iter+0xfb/0x120 mm/shmem.c:2884 call_write_iter include/linux/fs.h:2018 [inline] new_sync_write fs/read_write.c:491 [inline] vfs_write+0x43b/0x940 fs/read_write.c:584 ksys_write+0x147/0x250 fs/read_write.c:637 do_syscall_x64 arch/x86/entry/common.c:51 [inline] do_syscall_64+0x55/0xb0 arch/x86/entry/common.c:81 entry_SYSCALL_64_after_hwframe+0x68/0xd2 INITIAL USE at: lock_acquire+0x197/0x410 kernel/locking/lockdep.c:5754 __raw_write_lock_irq include/linux/rwlock_api_smp.h:195 [inline] _raw_write_lock_irq+0xa3/0xe0 kernel/locking/spinlock.c:326 __f_setown+0x3b/0x330 fs/fcntl.c:92 f_setown+0x14b/0x200 fs/fcntl.c:133 do_fcntl+0x650/0x1380 fs/fcntl.c:371 __do_sys_fcntl fs/fcntl.c:448 [inline] __se_sys_fcntl+0xc9/0x1a0 fs/fcntl.c:433 do_syscall_x64 arch/x86/entry/common.c:51 [inline] do_syscall_64+0x55/0xb0 arch/x86/entry/common.c:81 entry_SYSCALL_64_after_hwframe+0x68/0xd2 INITIAL READ USE at: lock_acquire+0x197/0x410 kernel/locking/lockdep.c:5754 __raw_read_lock_irq include/linux/rwlock_api_smp.h:169 [inline] _raw_read_lock_irq+0xab/0xf0 kernel/locking/spinlock.c:244 f_getown_ex fs/fcntl.c:207 [inline] do_fcntl+0x3b0/0x1380 fs/fcntl.c:374 __do_sys_fcntl fs/fcntl.c:448 [inline] __se_sys_fcntl+0xc9/0x1a0 fs/fcntl.c:433 do_syscall_x64 arch/x86/entry/common.c:51 [inline] do_syscall_64+0x55/0xb0 arch/x86/entry/common.c:81 entry_SYSCALL_64_after_hwframe+0x68/0xd2 } ... key at: [] init_file.__key+0x0/0x20 ... acquired at: __raw_read_lock_irqsave include/linux/rwlock_api_smp.h:160 [inline] _raw_read_lock_irqsave+0xb0/0x100 kernel/locking/spinlock.c:236 send_sigio+0x33/0x360 fs/fcntl.c:772 kill_fasync_rcu fs/fcntl.c:997 [inline] kill_fasync+0x228/0x4b0 fs/fcntl.c:1011 pipe_read+0x1074/0x12a0 fs/pipe.c:394 do_iter_readv_writev fs/read_write.c:-1 [inline] do_iter_read+0x798/0xc80 fs/read_write.c:795 vfs_readv fs/read_write.c:915 [inline] do_readv+0x235/0x3e0 fs/read_write.c:952 do_syscall_x64 arch/x86/entry/common.c:51 [inline] do_syscall_64+0x55/0xb0 arch/x86/entry/common.c:81 entry_SYSCALL_64_after_hwframe+0x68/0xd2 -> (&new->fa_lock){....}-{2:2} { INITIAL USE at: lock_acquire+0x197/0x410 kernel/locking/lockdep.c:5754 __raw_write_lock_irq include/linux/rwlock_api_smp.h:195 [inline] _raw_write_lock_irq+0xa3/0xe0 kernel/locking/spinlock.c:326 fasync_remove_entry+0xf4/0x1c0 fs/fcntl.c:867 fsnotify_fasync+0x4f/0x70 fs/notify/group.c:170 __fput+0x7f3/0x970 fs/file_table.c:381 __do_sys_close fs/open.c:1571 [inline] __se_sys_close+0x15f/0x220 fs/open.c:1556 do_syscall_x64 arch/x86/entry/common.c:51 [inline] do_syscall_64+0x55/0xb0 arch/x86/entry/common.c:81 entry_SYSCALL_64_after_hwframe+0x68/0xd2 INITIAL READ USE at: lock_acquire+0x197/0x410 kernel/locking/lockdep.c:5754 __raw_read_lock_irqsave include/linux/rwlock_api_smp.h:160 [inline] _raw_read_lock_irqsave+0xb0/0x100 kernel/locking/spinlock.c:236 kill_fasync_rcu fs/fcntl.c:990 [inline] kill_fasync+0x192/0x4b0 fs/fcntl.c:1011 pipe_read+0x1074/0x12a0 fs/pipe.c:394 do_iter_readv_writev fs/read_write.c:-1 [inline] do_iter_read+0x798/0xc80 fs/read_write.c:795 vfs_readv fs/read_write.c:915 [inline] do_readv+0x235/0x3e0 fs/read_write.c:952 do_syscall_x64 arch/x86/entry/common.c:51 [inline] do_syscall_64+0x55/0xb0 arch/x86/entry/common.c:81 entry_SYSCALL_64_after_hwframe+0x68/0xd2 } ... key at: [] fasync_insert_entry.__key+0x0/0x20 ... acquired at: __raw_read_lock_irqsave include/linux/rwlock_api_smp.h:160 [inline] _raw_read_lock_irqsave+0xb0/0x100 kernel/locking/spinlock.c:236 kill_fasync_rcu fs/fcntl.c:990 [inline] kill_fasync+0x192/0x4b0 fs/fcntl.c:1011 mousedev_notify_readers+0x6eb/0xc00 drivers/input/mousedev.c:309 mousedev_event+0x5f0/0x1310 drivers/input/mousedev.c:394 input_to_handler drivers/input/input.c:132 [inline] input_pass_values+0x9c9/0x1300 drivers/input/input.c:161 input_event_dispose+0x346/0x6c0 drivers/input/input.c:378 input_inject_event+0x1f9/0x320 drivers/input/input.c:465 evdev_write+0x32a/0x470 drivers/input/evdev.c:530 vfs_write+0x288/0x940 fs/read_write.c:582 ksys_write+0x147/0x250 fs/read_write.c:637 do_syscall_x64 arch/x86/entry/common.c:51 [inline] do_syscall_64+0x55/0xb0 arch/x86/entry/common.c:81 entry_SYSCALL_64_after_hwframe+0x68/0xd2 stack backtrace: CPU: 0 PID: 16940 Comm: syz.0.2500 Not tainted syzkaller #0 Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 07/12/2025 Call Trace: dump_stack_lvl+0x16c/0x230 lib/dump_stack.c:106 print_bad_irq_dependency kernel/locking/lockdep.c:2626 [inline] check_irq_usage kernel/locking/lockdep.c:2865 [inline] check_prev_add kernel/locking/lockdep.c:3138 [inline] check_prevs_add kernel/locking/lockdep.c:3253 [inline] validate_chain kernel/locking/lockdep.c:3869 [inline] __lock_acquire+0x678f/0x7c80 kernel/locking/lockdep.c:5137 lock_acquire+0x197/0x410 kernel/locking/lockdep.c:5754 __raw_read_lock_irqsave include/linux/rwlock_api_smp.h:160 [inline] _raw_read_lock_irqsave+0xb0/0x100 kernel/locking/spinlock.c:236 kill_fasync_rcu fs/fcntl.c:990 [inline] kill_fasync+0x192/0x4b0 fs/fcntl.c:1011 mousedev_notify_readers+0x6eb/0xc00 drivers/input/mousedev.c:309 mousedev_event+0x5f0/0x1310 drivers/input/mousedev.c:394 input_to_handler drivers/input/input.c:132 [inline] input_pass_values+0x9c9/0x1300 drivers/input/input.c:161 input_event_dispose+0x346/0x6c0 drivers/input/input.c:378 input_inject_event+0x1f9/0x320 drivers/input/input.c:465 evdev_write+0x32a/0x470 drivers/input/evdev.c:530 vfs_write+0x288/0x940 fs/read_write.c:582 ksys_write+0x147/0x250 fs/read_write.c:637 do_syscall_x64 arch/x86/entry/common.c:51 [inline] do_syscall_64+0x55/0xb0 arch/x86/entry/common.c:81 entry_SYSCALL_64_after_hwframe+0x68/0xd2 RIP: 0033:0x7f833258ebe9 Code: ff ff c3 66 2e 0f 1f 84 00 00 00 00 00 0f 1f 40 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 a8 ff ff ff f7 d8 64 89 01 48 RSP: 002b:00007f83333ae038 EFLAGS: 00000246 ORIG_RAX: 0000000000000001 RAX: ffffffffffffffda RBX: 00007f83327c5fa0 RCX: 00007f833258ebe9 RDX: 0000000000000918 RSI: 0000200000000040 RDI: 0000000000000003 RBP: 00007f8332611e19 R08: 0000000000000000 R09: 0000000000000000 R10: 0000000000000000 R11: 0000000000000246 R12: 0000000000000000 R13: 00007f83327c6038 R14: 00007f83327c5fa0 R15: 00007ffd32b00f28