syzbot


possible deadlock in evdev_pass_values

Status: auto-obsoleted due to no activity on 2023/10/09 19:52
Reported-by: syzbot+24c365f820cef9806586@syzkaller.appspotmail.com
First crash: 303d, last: 303d
Similar bugs (6)
Kernel Title Repro Cause bisect Fix bisect Count Last Reported Patched Status
upstream possible deadlock in evdev_pass_values fuse kernfs 351 384d 1207d 0/26 closed as dup on 2021/07/02 09:55
linux-6.1 possible deadlock in evdev_pass_values (3) 12 1d01h 32d 0/3 upstream: reported on 2024/03/28 21:07
linux-5.15 possible deadlock in evdev_pass_values 6 181d 284d 0/3 auto-obsoleted due to no activity on 2024/02/09 07:09
upstream possible deadlock in evdev_pass_values (2) input 558 6h30m 375d 0/26 upstream: reported on 2023/04/21 09:42
linux-5.15 possible deadlock in evdev_pass_values (2) 21 16h12m 76d 0/3 upstream: reported on 2024/02/13 17:30
linux-6.1 possible deadlock in evdev_pass_values (2) 1 164d 164d 0/3 auto-obsoleted due to no activity on 2024/02/25 22:49

Sample crash report:
=====================================================
WARNING: SOFTIRQ-safe -> SOFTIRQ-unsafe lock order detected
6.1.37-syzkaller #0 Not tainted
-----------------------------------------------------
syz-executor.2/20832 [HC0[0]:SC0[0]:HE0:SE1] is trying to acquire:
ffffffff8cc0a058 (tasklist_lock){.+.+}-{2:2}, at: send_sigio+0xd2/0x330 fs/fcntl.c:792

and this task is already holding:
ffff888074816db0 (&f->f_owner.lock){...-}-{2:2}, at: send_sigio+0x2f/0x330 fs/fcntl.c:778
which would create a new lock dependency:
 (&f->f_owner.lock){...-}-{2:2} -> (tasklist_lock){.+.+}-{2:2}

but this new dependency connects a SOFTIRQ-irq-safe lock:
 (&client->buffer_lock){..-.}-{2:2}

... which became SOFTIRQ-irq-safe at:
  lock_acquire+0x1f8/0x5a0 kernel/locking/lockdep.c:5669
  __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:350 [inline]
  evdev_pass_values+0xee/0xad0 drivers/input/evdev.c:261
  evdev_events+0x198/0x2c0 drivers/input/evdev.c:306
  input_to_handler drivers/input/input.c:127 [inline]
  input_pass_values+0x8dc/0x1290 drivers/input/input.c:159
  input_event_dispose+0x366/0x650 drivers/input/input.c:374
  input_handle_event+0x97d/0xb00 drivers/input/input.c:402
  input_event+0xa0/0xd0 drivers/input/input.c:431
  input_sync include/linux/input.h:450 [inline]
  hidinput_report_event+0x8f/0xf0 drivers/hid/hid-input.c:1681
  hid_report_raw_event+0x15d1/0x17e0 drivers/hid/hid-core.c:2019
  hid_input_report+0x420/0x4e0 drivers/hid/hid-core.c:2080
  hid_irq_in+0x45c/0x690 drivers/hid/usbhid/hid-core.c:284
  __usb_hcd_giveback_urb+0x371/0x530 drivers/usb/core/hcd.c:1671
  dummy_timer+0x8ad/0x3200 drivers/usb/gadget/udc/dummy_hcd.c:1988
  call_timer_fn+0x19e/0x6b0 kernel/time/timer.c:1474
  expire_timers kernel/time/timer.c:1519 [inline]
  __run_timers+0x67c/0x890 kernel/time/timer.c:1790
  run_timer_softirq+0x63/0xf0 kernel/time/timer.c:1803
  __do_softirq+0x2e9/0xa4c kernel/softirq.c:571
  invoke_softirq kernel/softirq.c:445 [inline]
  __irq_exit_rcu+0x155/0x240 kernel/softirq.c:650
  irq_exit_rcu+0x5/0x20 kernel/softirq.c:662
  sysvec_apic_timer_interrupt+0x91/0xb0 arch/x86/kernel/apic/apic.c:1106
  asm_sysvec_apic_timer_interrupt+0x16/0x20 arch/x86/include/asm/idtentry.h:649
  native_safe_halt arch/x86/include/asm/irqflags.h:51 [inline]
  arch_safe_halt arch/x86/include/asm/irqflags.h:89 [inline]
  acpi_safe_halt drivers/acpi/processor_idle.c:112 [inline]
  acpi_idle_do_entry+0x10f/0x340 drivers/acpi/processor_idle.c:572
  acpi_idle_enter+0x352/0x4f0 drivers/acpi/processor_idle.c:709
  cpuidle_enter_state+0x516/0xf80 drivers/cpuidle/cpuidle.c:239
  cpuidle_enter+0x59/0x90 drivers/cpuidle/cpuidle.c:356
  call_cpuidle kernel/sched/idle.c:155 [inline]
  cpuidle_idle_call kernel/sched/idle.c:236 [inline]
  do_idle+0x3ce/0x680 kernel/sched/idle.c:303
  cpu_startup_entry+0x14/0x20 kernel/sched/idle.c:400
  rest_init+0x28f/0x2b0 init/main.c:729
  start_kernel+0x0/0x544 init/main.c:890
  start_kernel+0x49b/0x544 init/main.c:1145
  secondary_startup_64_no_verify+0xcf/0xdb

to a SOFTIRQ-irq-unsafe lock:
 (tasklist_lock){.+.+}-{2:2}

... which became SOFTIRQ-irq-unsafe at:
...
  lock_acquire+0x1f8/0x5a0 kernel/locking/lockdep.c:5669
  __raw_read_lock include/linux/rwlock_api_smp.h:150 [inline]
  _raw_read_lock+0x32/0x40 kernel/locking/spinlock.c:228
  do_wait+0x2c3/0xb70 kernel/exit.c:1602
  kernel_wait+0xe5/0x230 kernel/exit.c:1792
  call_usermodehelper_exec_sync kernel/umh.c:140 [inline]
  call_usermodehelper_exec_work+0xb5/0x220 kernel/umh.c:167
  process_one_work+0x8aa/0x11f0 kernel/workqueue.c:2289
  worker_thread+0xa5f/0x1210 kernel/workqueue.c:2436
  kthread+0x26e/0x300 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:
  &client->buffer_lock --> &f->f_owner.lock --> tasklist_lock

 Possible interrupt unsafe locking scenario:

       CPU0                    CPU1
       ----                    ----
  lock(tasklist_lock);
                               local_irq_disable();
                               lock(&client->buffer_lock);
                               lock(&f->f_owner.lock);
  <Interrupt>
    lock(&client->buffer_lock);

 *** DEADLOCK ***

5 locks held by syz-executor.2/20832:
 #0: ffff88814c112460 (sb_writers#4){.+.+}-{0:0}, at: __do_splice fs/splice.c:1139 [inline]
 #0: ffff88814c112460 (sb_writers#4){.+.+}-{0:0}, at: __do_sys_splice fs/splice.c:1346 [inline]
 #0: ffff88814c112460 (sb_writers#4){.+.+}-{0:0}, at: __se_sys_splice+0x340/0x420 fs/splice.c:1328
 #1: ffff888077dd7c68 (&pipe->mutex/1){+.+.}-{3:3}, at: iter_file_splice_write+0x2ab/0xfa0 fs/splice.c:632
 #2: ffffffff91b52208 (&fsnotify_mark_srcu){....}-{0:0}, at: rcu_lock_acquire+0x5/0x30 include/linux/rcupdate.h:305
 #3: ffff88801e479038 (&mark->lock){+.+.}-{2:2}, at: spin_lock include/linux/spinlock.h:350 [inline]
 #3: ffff88801e479038 (&mark->lock){+.+.}-{2:2}, at: dnotify_handle_event+0x5d/0x440 fs/notify/dnotify/dnotify.c:107
 #4: ffff888074816db0 (&f->f_owner.lock){...-}-{2:2}, at: send_sigio+0x2f/0x330 fs/fcntl.c:778

the dependencies between SOFTIRQ-irq-safe lock and the holding lock:
  -> (&client->buffer_lock){..-.}-{2:2} {
     IN-SOFTIRQ-W at:
                        lock_acquire+0x1f8/0x5a0 kernel/locking/lockdep.c:5669
                        __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:350 [inline]
                        evdev_pass_values+0xee/0xad0 drivers/input/evdev.c:261
                        evdev_events+0x198/0x2c0 drivers/input/evdev.c:306
                        input_to_handler drivers/input/input.c:127 [inline]
                        input_pass_values+0x8dc/0x1290 drivers/input/input.c:159
                        input_event_dispose+0x366/0x650 drivers/input/input.c:374
                        input_handle_event+0x97d/0xb00 drivers/input/input.c:402
                        input_event+0xa0/0xd0 drivers/input/input.c:431
                        input_sync include/linux/input.h:450 [inline]
                        hidinput_report_event+0x8f/0xf0 drivers/hid/hid-input.c:1681
                        hid_report_raw_event+0x15d1/0x17e0 drivers/hid/hid-core.c:2019
                        hid_input_report+0x420/0x4e0 drivers/hid/hid-core.c:2080
                        hid_irq_in+0x45c/0x690 drivers/hid/usbhid/hid-core.c:284
                        __usb_hcd_giveback_urb+0x371/0x530 drivers/usb/core/hcd.c:1671
                        dummy_timer+0x8ad/0x3200 drivers/usb/gadget/udc/dummy_hcd.c:1988
                        call_timer_fn+0x19e/0x6b0 kernel/time/timer.c:1474
                        expire_timers kernel/time/timer.c:1519 [inline]
                        __run_timers+0x67c/0x890 kernel/time/timer.c:1790
                        run_timer_softirq+0x63/0xf0 kernel/time/timer.c:1803
                        __do_softirq+0x2e9/0xa4c kernel/softirq.c:571
                        invoke_softirq kernel/softirq.c:445 [inline]
                        __irq_exit_rcu+0x155/0x240 kernel/softirq.c:650
                        irq_exit_rcu+0x5/0x20 kernel/softirq.c:662
                        sysvec_apic_timer_interrupt+0x91/0xb0 arch/x86/kernel/apic/apic.c:1106
                        asm_sysvec_apic_timer_interrupt+0x16/0x20 arch/x86/include/asm/idtentry.h:649
                        native_safe_halt arch/x86/include/asm/irqflags.h:51 [inline]
                        arch_safe_halt arch/x86/include/asm/irqflags.h:89 [inline]
                        acpi_safe_halt drivers/acpi/processor_idle.c:112 [inline]
                        acpi_idle_do_entry+0x10f/0x340 drivers/acpi/processor_idle.c:572
                        acpi_idle_enter+0x352/0x4f0 drivers/acpi/processor_idle.c:709
                        cpuidle_enter_state+0x516/0xf80 drivers/cpuidle/cpuidle.c:239
                        cpuidle_enter+0x59/0x90 drivers/cpuidle/cpuidle.c:356
                        call_cpuidle kernel/sched/idle.c:155 [inline]
                        cpuidle_idle_call kernel/sched/idle.c:236 [inline]
                        do_idle+0x3ce/0x680 kernel/sched/idle.c:303
                        cpu_startup_entry+0x14/0x20 kernel/sched/idle.c:400
                        rest_init+0x28f/0x2b0 init/main.c:729
                        start_kernel+0x0/0x544 init/main.c:890
                        start_kernel+0x49b/0x544 init/main.c:1145
                        secondary_startup_64_no_verify+0xcf/0xdb
     INITIAL USE at:
                       lock_acquire+0x1f8/0x5a0 kernel/locking/lockdep.c:5669
                       __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:350 [inline]
                       evdev_pass_values+0xee/0xad0 drivers/input/evdev.c:261
                       evdev_events+0x198/0x2c0 drivers/input/evdev.c:306
                       input_to_handler drivers/input/input.c:127 [inline]
                       input_pass_values+0x8dc/0x1290 drivers/input/input.c:159
                       input_event_dispose+0x366/0x650 drivers/input/input.c:374
                       input_handle_event+0x97d/0xb00 drivers/input/input.c:402
                       input_event+0xa0/0xd0 drivers/input/input.c:431
                       input_sync include/linux/input.h:450 [inline]
                       hidinput_report_event+0x8f/0xf0 drivers/hid/hid-input.c:1681
                       hid_report_raw_event+0x15d1/0x17e0 drivers/hid/hid-core.c:2019
                       hid_input_report+0x420/0x4e0 drivers/hid/hid-core.c:2080
                       hid_irq_in+0x45c/0x690 drivers/hid/usbhid/hid-core.c:284
                       __usb_hcd_giveback_urb+0x371/0x530 drivers/usb/core/hcd.c:1671
                       dummy_timer+0x8ad/0x3200 drivers/usb/gadget/udc/dummy_hcd.c:1988
                       call_timer_fn+0x19e/0x6b0 kernel/time/timer.c:1474
                       expire_timers kernel/time/timer.c:1519 [inline]
                       __run_timers+0x67c/0x890 kernel/time/timer.c:1790
                       run_timer_softirq+0x63/0xf0 kernel/time/timer.c:1803
                       __do_softirq+0x2e9/0xa4c kernel/softirq.c:571
                       invoke_softirq kernel/softirq.c:445 [inline]
                       __irq_exit_rcu+0x155/0x240 kernel/softirq.c:650
                       irq_exit_rcu+0x5/0x20 kernel/softirq.c:662
                       sysvec_apic_timer_interrupt+0x91/0xb0 arch/x86/kernel/apic/apic.c:1106
                       asm_sysvec_apic_timer_interrupt+0x16/0x20 arch/x86/include/asm/idtentry.h:649
                       native_safe_halt arch/x86/include/asm/irqflags.h:51 [inline]
                       arch_safe_halt arch/x86/include/asm/irqflags.h:89 [inline]
                       acpi_safe_halt drivers/acpi/processor_idle.c:112 [inline]
                       acpi_idle_do_entry+0x10f/0x340 drivers/acpi/processor_idle.c:572
                       acpi_idle_enter+0x352/0x4f0 drivers/acpi/processor_idle.c:709
                       cpuidle_enter_state+0x516/0xf80 drivers/cpuidle/cpuidle.c:239
                       cpuidle_enter+0x59/0x90 drivers/cpuidle/cpuidle.c:356
                       call_cpuidle kernel/sched/idle.c:155 [inline]
                       cpuidle_idle_call kernel/sched/idle.c:236 [inline]
                       do_idle+0x3ce/0x680 kernel/sched/idle.c:303
                       cpu_startup_entry+0x14/0x20 kernel/sched/idle.c:400
                       rest_init+0x28f/0x2b0 init/main.c:729
                       start_kernel+0x0/0x544 init/main.c:890
                       start_kernel+0x49b/0x544 init/main.c:1145
                       secondary_startup_64_no_verify+0xcf/0xdb
   }
   ... key      at: [<ffffffff91e4eb80>] evdev_open.__key.25+0x0/0x20
 -> (&new->fa_lock){....}-{2:2} {
    INITIAL USE at:
                     lock_acquire+0x1f8/0x5a0 kernel/locking/lockdep.c:5669
                     __raw_write_lock_irq include/linux/rwlock_api_smp.h:195 [inline]
                     _raw_write_lock_irq+0xcf/0x110 kernel/locking/spinlock.c:326
                     fasync_remove_entry+0xfb/0x1d0 fs/fcntl.c:873
                     sock_fasync+0x86/0xf0 net/socket.c:1395
                     __fput+0x70d/0x890 fs/file_table.c:317
                     task_work_run+0x246/0x300 kernel/task_work.c:179
                     exit_task_work include/linux/task_work.h:38 [inline]
                     do_exit+0x6fb/0x2300 kernel/exit.c:869
                     do_group_exit+0x202/0x2b0 kernel/exit.c:1019
                     get_signal+0x16f7/0x17d0 kernel/signal.c:2858
                     arch_do_signal_or_restart+0xb0/0x1a10 arch/x86/kernel/signal.c:869
                     exit_to_user_mode_loop+0x6a/0x100 kernel/entry/common.c:168
                     exit_to_user_mode_prepare+0xb1/0x140 kernel/entry/common.c:204
                     __syscall_exit_to_user_mode_work kernel/entry/common.c:286 [inline]
                     syscall_exit_to_user_mode+0x60/0x270 kernel/entry/common.c:297
                     do_syscall_64+0x49/0xb0 arch/x86/entry/common.c:86
                     entry_SYSCALL_64_after_hwframe+0x63/0xcd
    INITIAL READ USE at:
                          lock_acquire+0x1f8/0x5a0 kernel/locking/lockdep.c:5669
                          __raw_read_lock_irqsave include/linux/rwlock_api_smp.h:160 [inline]
                          _raw_read_lock_irqsave+0xd9/0x120 kernel/locking/spinlock.c:236
                          kill_fasync_rcu fs/fcntl.c:996 [inline]
                          kill_fasync+0x16a/0x490 fs/fcntl.c:1017
                          sock_wake_async+0x145/0x170
                          sk_wake_async+0x15d/0x250 include/net/sock.h:2554
                          unix_release_sock+0x6f7/0xcf0 net/unix/af_unix.c:635
                          unix_release+0x88/0xc0 net/unix/af_unix.c:1041
                          __sock_release net/socket.c:652 [inline]
                          sock_close+0xcd/0x230 net/socket.c:1370
                          __fput+0x3b7/0x890 fs/file_table.c:320
                          task_work_run+0x246/0x300 kernel/task_work.c:179
                          get_signal+0x15fc/0x17d0 kernel/signal.c:2635
                          arch_do_signal_or_restart+0xb0/0x1a10 arch/x86/kernel/signal.c:869
                          exit_to_user_mode_loop+0x6a/0x100 kernel/entry/common.c:168
                          exit_to_user_mode_prepare+0xb1/0x140 kernel/entry/common.c:204
                          __syscall_exit_to_user_mode_work kernel/entry/common.c:286 [inline]
                          syscall_exit_to_user_mode+0x60/0x270 kernel/entry/common.c:297
                          do_syscall_64+0x49/0xb0 arch/x86/entry/common.c:86
                          entry_SYSCALL_64_after_hwframe+0x63/0xcd
  }
  ... key      at: [<ffffffff91b4f020>] fasync_insert_entry.__key+0x0/0x20
  ... acquired at:
   lock_acquire+0x1f8/0x5a0 kernel/locking/lockdep.c:5669
   __raw_read_lock_irqsave include/linux/rwlock_api_smp.h:160 [inline]
   _raw_read_lock_irqsave+0xd9/0x120 kernel/locking/spinlock.c:236
   kill_fasync_rcu fs/fcntl.c:996 [inline]
   kill_fasync+0x16a/0x490 fs/fcntl.c:1017
   __pass_event drivers/input/evdev.c:240 [inline]
   evdev_pass_values+0x586/0xad0 drivers/input/evdev.c:278
   evdev_events+0x198/0x2c0 drivers/input/evdev.c:306
   input_to_handler drivers/input/input.c:127 [inline]
   input_pass_values+0x8dc/0x1290 drivers/input/input.c:159
   input_event_dispose+0x366/0x650 drivers/input/input.c:374
   input_handle_event+0x97d/0xb00 drivers/input/input.c:402
   input_inject_event+0x1fd/0x300 drivers/input/input.c:461
   evdev_write+0x668/0x7c0 drivers/input/evdev.c:530
   vfs_write+0x2d9/0xba0 fs/read_write.c:582
   ksys_write+0x19c/0x2c0 fs/read_write.c:637
   do_syscall_x64 arch/x86/entry/common.c:50 [inline]
   do_syscall_64+0x3d/0xb0 arch/x86/entry/common.c:80
   entry_SYSCALL_64_after_hwframe+0x63/0xcd

-> (&f->f_owner.lock){...-}-{2:2} {
   IN-SOFTIRQ-R at:
                    lock_acquire+0x1f8/0x5a0 kernel/locking/lockdep.c:5669
                    __raw_read_lock_irqsave include/linux/rwlock_api_smp.h:160 [inline]
                    _raw_read_lock_irqsave+0xd9/0x120 kernel/locking/spinlock.c:236
                    send_sigurg+0x25/0x380 fs/fcntl.c:817
                    sk_send_sigurg+0x6a/0xb0 net/core/sock.c:3330
                    tcp_check_urg+0x202/0x740 net/ipv4/tcp_input.c:5614
                    tcp_urg+0x154/0x440 net/ipv4/tcp_input.c:5655
                    tcp_rcv_established+0xe58/0x1f00 net/ipv4/tcp_input.c:6002
                    tcp_v4_do_rcv+0x487/0xb00 net/ipv4/tcp_ipv4.c:1671
                    tcp_v4_rcv+0x29e0/0x3250 net/ipv4/tcp_ipv4.c:2092
                    ip_protocol_deliver_rcu+0x381/0x740 net/ipv4/ip_input.c:205
                    ip_local_deliver_finish+0x28c/0x4c0 net/ipv4/ip_input.c:233
                    NF_HOOK+0x364/0x410 include/linux/netfilter.h:302
                    NF_HOOK+0x364/0x410 include/linux/netfilter.h:302
                    __netif_receive_skb_one_core net/core/dev.c:5496 [inline]
                    __netif_receive_skb+0x1c6/0x530 net/core/dev.c:5610
                    process_backlog+0x347/0x700 net/core/dev.c:5938
                    __napi_poll+0xc7/0x470 net/core/dev.c:6505
                    napi_poll net/core/dev.c:6572 [inline]
                    net_rx_action+0x70f/0xeb0 net/core/dev.c:6683
                    __do_softirq+0x2e9/0xa4c kernel/softirq.c:571
                    invoke_softirq kernel/softirq.c:445 [inline]
                    __irq_exit_rcu+0x155/0x240 kernel/softirq.c:650
                    irq_exit_rcu+0x5/0x20 kernel/softirq.c:662
                    sysvec_apic_timer_interrupt+0x91/0xb0 arch/x86/kernel/apic/apic.c:1106
                    asm_sysvec_apic_timer_interrupt+0x16/0x20 arch/x86/include/asm/idtentry.h:649
                    rep_nop arch/x86/include/asm/vdso/processor.h:13 [inline]
                    cpu_relax arch/x86/include/asm/vdso/processor.h:18 [inline]
                    mutex_spin_on_owner+0x264/0x330 kernel/locking/mutex.c:383
                    mutex_optimistic_spin+0x38/0x2c0 kernel/locking/mutex.c:476
                    __mutex_lock_common+0x206/0x2520 kernel/locking/mutex.c:607
                    __mutex_lock kernel/locking/mutex.c:747 [inline]
                    mutex_lock_nested+0x17/0x20 kernel/locking/mutex.c:799
                    ip_tunnel_init_net+0x20f/0x700 net/ipv4/ip_tunnel.c:1072
                    ops_init+0x356/0x600 net/core/net_namespace.c:135
                    setup_net+0x4b5/0xb90 net/core/net_namespace.c:332
                    copy_net_ns+0x395/0x5d0 net/core/net_namespace.c:478
                    create_new_namespaces+0x425/0x7a0 kernel/nsproxy.c:110
                    copy_namespaces+0x365/0x3b0 kernel/nsproxy.c:178
                    copy_process+0x1a85/0x4020 kernel/fork.c:2262
                    kernel_clone+0x222/0x920 kernel/fork.c:2679
                    __do_sys_clone3 kernel/fork.c:2978 [inline]
                    __se_sys_clone3+0x373/0x410 kernel/fork.c:2962
                    do_syscall_x64 arch/x86/entry/common.c:50 [inline]
                    do_syscall_64+0x3d/0xb0 arch/x86/entry/common.c:80
                    entry_SYSCALL_64_after_hwframe+0x63/0xcd
   INITIAL USE at:
                   lock_acquire+0x1f8/0x5a0 kernel/locking/lockdep.c:5669
                   __raw_write_lock_irq include/linux/rwlock_api_smp.h:195 [inline]
                   _raw_write_lock_irq+0xcf/0x110 kernel/locking/spinlock.c:326
                   f_modown+0x38/0x340 fs/fcntl.c:91
                   __f_setown fs/fcntl.c:110 [inline]
                   f_setown+0x127/0x1d0 fs/fcntl.c:138
                   do_fcntl+0x128/0x1480 fs/fcntl.c:377
                   __do_sys_fcntl fs/fcntl.c:454 [inline]
                   __se_sys_fcntl+0xd5/0x1b0 fs/fcntl.c:439
                   do_syscall_x64 arch/x86/entry/common.c:50 [inline]
                   do_syscall_64+0x3d/0xb0 arch/x86/entry/common.c:80
                   entry_SYSCALL_64_after_hwframe+0x63/0xcd
   INITIAL READ USE at:
                        lock_acquire+0x1f8/0x5a0 kernel/locking/lockdep.c:5669
                        __raw_read_lock_irq include/linux/rwlock_api_smp.h:169 [inline]
                        _raw_read_lock_irq+0xd6/0x120 kernel/locking/spinlock.c:244
                        f_getown+0x22/0x240 fs/fcntl.c:154
                        do_fcntl+0x55b/0x1480 fs/fcntl.c:373
                        __do_sys_fcntl fs/fcntl.c:454 [inline]
                        __se_sys_fcntl+0xd5/0x1b0 fs/fcntl.c:439
                        do_syscall_x64 arch/x86/entry/common.c:50 [inline]
                        do_syscall_64+0x3d/0xb0 arch/x86/entry/common.c:80
                        entry_SYSCALL_64_after_hwframe+0x63/0xcd
 }
 ... key      at: [<ffffffff91b4e3a0>] __alloc_file.__key+0x0/0x10
 ... acquired at:
   lock_acquire+0x1f8/0x5a0 kernel/locking/lockdep.c:5669
   __raw_read_lock_irqsave include/linux/rwlock_api_smp.h:160 [inline]
   _raw_read_lock_irqsave+0xd9/0x120 kernel/locking/spinlock.c:236
   send_sigio+0x2f/0x330 fs/fcntl.c:778
   kill_fasync_rcu fs/fcntl.c:1003 [inline]
   kill_fasync+0x20c/0x490 fs/fcntl.c:1017
   sock_wake_async+0x145/0x170
   sk_wake_async+0x15d/0x250 include/net/sock.h:2554
   unix_release_sock+0x6f7/0xcf0 net/unix/af_unix.c:635
   unix_release+0x88/0xc0 net/unix/af_unix.c:1041
   __sock_release net/socket.c:652 [inline]
   sock_close+0xcd/0x230 net/socket.c:1370
   __fput+0x3b7/0x890 fs/file_table.c:320
   task_work_run+0x246/0x300 kernel/task_work.c:179
   get_signal+0x15fc/0x17d0 kernel/signal.c:2635
   arch_do_signal_or_restart+0xb0/0x1a10 arch/x86/kernel/signal.c:869
   exit_to_user_mode_loop+0x6a/0x100 kernel/entry/common.c:168
   exit_to_user_mode_prepare+0xb1/0x140 kernel/entry/common.c:204
   __syscall_exit_to_user_mode_work kernel/entry/common.c:286 [inline]
   syscall_exit_to_user_mode+0x60/0x270 kernel/entry/common.c:297
   do_syscall_64+0x49/0xb0 arch/x86/entry/common.c:86
   entry_SYSCALL_64_after_hwframe+0x63/0xcd


the dependencies between the lock to be acquired
 and SOFTIRQ-irq-unsafe lock:
-> (tasklist_lock){.+.+}-{2:2} {
   HARDIRQ-ON-R at:
                    lock_acquire+0x1f8/0x5a0 kernel/locking/lockdep.c:5669
                    __raw_read_lock include/linux/rwlock_api_smp.h:150 [inline]
                    _raw_read_lock+0x32/0x40 kernel/locking/spinlock.c:228
                    do_wait+0x2c3/0xb70 kernel/exit.c:1602
                    kernel_wait+0xe5/0x230 kernel/exit.c:1792
                    call_usermodehelper_exec_sync kernel/umh.c:140 [inline]
                    call_usermodehelper_exec_work+0xb5/0x220 kernel/umh.c:167
                    process_one_work+0x8aa/0x11f0 kernel/workqueue.c:2289
                    worker_thread+0xa5f/0x1210 kernel/workqueue.c:2436
                    kthread+0x26e/0x300 kernel/kthread.c:376
                    ret_from_fork+0x1f/0x30 arch/x86/entry/entry_64.S:306
   SOFTIRQ-ON-R at:
                    lock_acquire+0x1f8/0x5a0 kernel/locking/lockdep.c:5669
                    __raw_read_lock include/linux/rwlock_api_smp.h:150 [inline]
                    _raw_read_lock+0x32/0x40 kernel/locking/spinlock.c:228
                    do_wait+0x2c3/0xb70 kernel/exit.c:1602
                    kernel_wait+0xe5/0x230 kernel/exit.c:1792
                    call_usermodehelper_exec_sync kernel/umh.c:140 [inline]
                    call_usermodehelper_exec_work+0xb5/0x220 kernel/umh.c:167
                    process_one_work+0x8aa/0x11f0 kernel/workqueue.c:2289
                    worker_thread+0xa5f/0x1210 kernel/workqueue.c:2436
                    kthread+0x26e/0x300 kernel/kthread.c:376
                    ret_from_fork+0x1f/0x30 arch/x86/entry/entry_64.S:306
   INITIAL USE at:
                   lock_acquire+0x1f8/0x5a0 kernel/locking/lockdep.c:5669
                   __raw_write_lock_irq include/linux/rwlock_api_smp.h:195 [inline]
                   _raw_write_lock_irq+0xcf/0x110 kernel/locking/spinlock.c:326
                   copy_process+0x2483/0x4020 kernel/fork.c:2393
                   kernel_clone+0x222/0x920 kernel/fork.c:2679
                   user_mode_thread+0x12e/0x190 kernel/fork.c:2755
                   rest_init+0x21/0x2b0 init/main.c:694
                   start_kernel+0x0/0x544 init/main.c:890
                   start_kernel+0x49b/0x544 init/main.c:1145
                   secondary_startup_64_no_verify+0xcf/0xdb
   INITIAL READ USE at:
                        lock_acquire+0x1f8/0x5a0 kernel/locking/lockdep.c:5669
                        __raw_read_lock include/linux/rwlock_api_smp.h:150 [inline]
                        _raw_read_lock+0x32/0x40 kernel/locking/spinlock.c:228
                        do_wait+0x2c3/0xb70 kernel/exit.c:1602
                        kernel_wait+0xe5/0x230 kernel/exit.c:1792
                        call_usermodehelper_exec_sync kernel/umh.c:140 [inline]
                        call_usermodehelper_exec_work+0xb5/0x220 kernel/umh.c:167
                        process_one_work+0x8aa/0x11f0 kernel/workqueue.c:2289
                        worker_thread+0xa5f/0x1210 kernel/workqueue.c:2436
                        kthread+0x26e/0x300 kernel/kthread.c:376
                        ret_from_fork+0x1f/0x30 arch/x86/entry/entry_64.S:306
 }
 ... key      at: [<ffffffff8cc0a058>] tasklist_lock+0x18/0x40
 ... acquired at:
   lock_acquire+0x1f8/0x5a0 kernel/locking/lockdep.c:5669
   __raw_read_lock include/linux/rwlock_api_smp.h:150 [inline]
   _raw_read_lock+0x32/0x40 kernel/locking/spinlock.c:228
   send_sigio+0xd2/0x330 fs/fcntl.c:792
   dnotify_handle_event+0x138/0x440 fs/notify/dnotify/dnotify.c:115
   fsnotify_handle_inode_event fs/notify/fsnotify.c:264 [inline]
   fsnotify_handle_event fs/notify/fsnotify.c:293 [inline]
   send_to_group fs/notify/fsnotify.c:364 [inline]
   fsnotify+0x1a24/0x2450 fs/notify/fsnotify.c:570
   __fsnotify_parent+0x5dd/0x730 fs/notify/fsnotify.c:230
   fsnotify_parent include/linux/fsnotify.h:77 [inline]
   fsnotify_file include/linux/fsnotify.h:99 [inline]
   fsnotify_modify include/linux/fsnotify.h:317 [inline]
   do_iter_write+0x9ca/0xc50 fs/read_write.c:865
   iter_file_splice_write+0x806/0xfa0 fs/splice.c:686
   do_splice_from fs/splice.c:764 [inline]
   do_splice+0xfdb/0x1790 fs/splice.c:1074
   __do_splice fs/splice.c:1139 [inline]
   __do_sys_splice fs/splice.c:1346 [inline]
   __se_sys_splice+0x340/0x420 fs/splice.c:1328
   do_syscall_x64 arch/x86/entry/common.c:50 [inline]
   do_syscall_64+0x3d/0xb0 arch/x86/entry/common.c:80
   entry_SYSCALL_64_after_hwframe+0x63/0xcd


stack backtrace:
CPU: 0 PID: 20832 Comm: syz-executor.2 Not tainted 6.1.37-syzkaller #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 05/27/2023
Call Trace:
 <TASK>
 __dump_stack lib/dump_stack.c:88 [inline]
 dump_stack_lvl+0x1e3/0x2cb lib/dump_stack.c:106
 print_bad_irq_dependency kernel/locking/lockdep.c:2612 [inline]
 check_irq_usage kernel/locking/lockdep.c:2851 [inline]
 check_prev_add kernel/locking/lockdep.c:3102 [inline]
 check_prevs_add kernel/locking/lockdep.c:3217 [inline]
 validate_chain+0x4d2e/0x58e0 kernel/locking/lockdep.c:3832
 __lock_acquire+0x125b/0x1f80 kernel/locking/lockdep.c:5056
 lock_acquire+0x1f8/0x5a0 kernel/locking/lockdep.c:5669
 __raw_read_lock include/linux/rwlock_api_smp.h:150 [inline]
 _raw_read_lock+0x32/0x40 kernel/locking/spinlock.c:228
 send_sigio+0xd2/0x330 fs/fcntl.c:792
 dnotify_handle_event+0x138/0x440 fs/notify/dnotify/dnotify.c:115
 fsnotify_handle_inode_event fs/notify/fsnotify.c:264 [inline]
 fsnotify_handle_event fs/notify/fsnotify.c:293 [inline]
 send_to_group fs/notify/fsnotify.c:364 [inline]
 fsnotify+0x1a24/0x2450 fs/notify/fsnotify.c:570
 __fsnotify_parent+0x5dd/0x730 fs/notify/fsnotify.c:230
 fsnotify_parent include/linux/fsnotify.h:77 [inline]
 fsnotify_file include/linux/fsnotify.h:99 [inline]
 fsnotify_modify include/linux/fsnotify.h:317 [inline]
 do_iter_write+0x9ca/0xc50 fs/read_write.c:865
 iter_file_splice_write+0x806/0xfa0 fs/splice.c:686
 do_splice_from fs/splice.c:764 [inline]
 do_splice+0xfdb/0x1790 fs/splice.c:1074
 __do_splice fs/splice.c:1139 [inline]
 __do_sys_splice fs/splice.c:1346 [inline]
 __se_sys_splice+0x340/0x420 fs/splice.c:1328
 do_syscall_x64 arch/x86/entry/common.c:50 [inline]
 do_syscall_64+0x3d/0xb0 arch/x86/entry/common.c:80
 entry_SYSCALL_64_after_hwframe+0x63/0xcd
RIP: 0033:0x7f6317e8c389
Code: 28 00 00 00 75 05 48 83 c4 28 c3 e8 f1 19 00 00 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 73 01 c3 48 c7 c1 b8 ff ff ff f7 d8 64 89 01 48
RSP: 002b:00007f6318c07168 EFLAGS: 00000246 ORIG_RAX: 0000000000000113
RAX: ffffffffffffffda RBX: 00007f6317fabf80 RCX: 00007f6317e8c389
RDX: 0000000000000003 RSI: 0000000000000000 RDI: 0000000000000004
RBP: 00007f6317ed7493 R08: 000000007ffffffb R09: 0000000000000000
R10: 0000000000000000 R11: 0000000000000246 R12: 0000000000000000
R13: 00007ffdc2df274f R14: 00007f6318c07300 R15: 0000000000022000
 </TASK>

Crashes (1):
Time Kernel Commit Syzkaller Config Log Report Syz repro C repro VM info Assets (help?) Manager Title
2023/07/01 19:52 linux-6.1.y 0f4ac6b4c5f0 bfc47836 .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-6-1-kasan possible deadlock in evdev_pass_values
* Struck through repros no longer work on HEAD.