syzbot


possible deadlock in __netlink_diag_dump

Status: closed as invalid on 2021/12/15 18:06
Reported-by: syzbot+@syzkaller.appspotmail.com
First crash: 404d, last: 404d

Sample crash report:
========================================================
WARNING: possible irq lock inversion dependency detected
5.15.0-rc5-syzkaller #0 Not tainted
--------------------------------------------------------
syz-executor.1/17246 just changed the state of lock:
ffffffff8d17ad38 (nl_table_lock){.+.?}-{2:2}, at: __netlink_diag_dump+0x2ce/0x790 net/netlink/diag.c:155
but this lock was taken by another, SOFTIRQ-safe lock in the past:
 (&local->queue_stop_reason_lock){..-.}-{2:2}


and interrupts could create inverse lock ordering between them.


other info that might help us debug this:
 Possible interrupt unsafe locking scenario:

       CPU0                    CPU1
       ----                    ----
  lock(nl_table_lock);
                               local_irq_disable();
                               lock(&local->queue_stop_reason_lock);
                               lock(nl_table_lock);
  <Interrupt>
    lock(&local->queue_stop_reason_lock);

 *** DEADLOCK ***

3 locks held by syz-executor.1/17246:
 #0: ffffffff8d0f4308 (sock_diag_mutex){+.+.}-{3:3}, at: sock_diag_rcv+0x17/0x40 net/core/sock_diag.c:275
 #1: ffffffff8d0f4488 (sock_diag_table_mutex){+.+.}-{3:3}, at: __sock_diag_cmd net/core/sock_diag.c:229 [inline]
 #1: ffffffff8d0f4488 (sock_diag_table_mutex){+.+.}-{3:3}, at: sock_diag_rcv_msg+0x19b/0x440 net/core/sock_diag.c:265
 #2: ffff88802e070678 (nlk_cb_mutex-SOCK_DIAG){+.+.}-{3:3}, at: netlink_dump+0xb0/0xb60 net/netlink/af_netlink.c:2220

the shortest dependencies between 2nd lock and 1st lock:
 -> (&local->queue_stop_reason_lock){..-.}-{2:2} {
    IN-SOFTIRQ-W at:
                      lock_acquire kernel/locking/lockdep.c:5625 [inline]
                      lock_acquire+0x1ab/0x510 kernel/locking/lockdep.c:5590
                      __raw_spin_lock_irqsave include/linux/spinlock_api_smp.h:110 [inline]
                      _raw_spin_lock_irqsave+0x39/0x50 kernel/locking/spinlock.c:162
                      ieee80211_tx_frags+0x160/0x970 net/mac80211/tx.c:1668
                      __ieee80211_tx+0x1ad/0x640 net/mac80211/tx.c:1769
                      ieee80211_tx+0x32f/0x430 net/mac80211/tx.c:1953
                      ieee80211_xmit+0x339/0x420 net/mac80211/tx.c:2046
                      __ieee80211_subif_start_xmit+0x7ba/0xcc0 net/mac80211/tx.c:4255
                      ieee80211_subif_start_xmit+0xee/0xf00 net/mac80211/tx.c:4391
                      __netdev_start_xmit include/linux/netdevice.h:4987 [inline]
                      netdev_start_xmit include/linux/netdevice.h:5001 [inline]
                      xmit_one net/core/dev.c:3584 [inline]
                      dev_hard_start_xmit+0x1eb/0x920 net/core/dev.c:3600
                      sch_direct_xmit+0x19f/0xbc0 net/sched/sch_generic.c:342
                      __dev_xmit_skb net/core/dev.c:3811 [inline]
                      __dev_queue_xmit+0x1489/0x36e0 net/core/dev.c:4178
                      neigh_hh_output include/net/neighbour.h:511 [inline]
                      neigh_output include/net/neighbour.h:520 [inline]
                      ip6_finish_output2+0x922/0x1500 net/ipv6/ip6_output.c:126
                      __ip6_finish_output net/ipv6/ip6_output.c:191 [inline]
                      __ip6_finish_output+0x4c1/0x1050 net/ipv6/ip6_output.c:170
                      ip6_finish_output+0x32/0x200 net/ipv6/ip6_output.c:201
                      NF_HOOK_COND include/linux/netfilter.h:296 [inline]
                      ip6_output+0x1e4/0x530 net/ipv6/ip6_output.c:224
                      dst_output include/net/dst.h:450 [inline]
                      NF_HOOK include/linux/netfilter.h:307 [inline]
                      ndisc_send_skb+0xa99/0x17f0 net/ipv6/ndisc.c:508
                      ndisc_send_rs+0x12e/0x6f0 net/ipv6/ndisc.c:702
                      addrconf_rs_timer+0x3f2/0x820 net/ipv6/addrconf.c:3893
                      call_timer_fn+0x1a5/0x6b0 kernel/time/timer.c:1421
                      expire_timers kernel/time/timer.c:1466 [inline]
                      __run_timers.part.0+0x675/0xa20 kernel/time/timer.c:1734
                      __run_timers kernel/time/timer.c:1715 [inline]
                      run_timer_softirq+0xb3/0x1d0 kernel/time/timer.c:1747
                      __do_softirq+0x29b/0x9c2 kernel/softirq.c:558
                      invoke_softirq kernel/softirq.c:432 [inline]
                      __irq_exit_rcu+0x123/0x180 kernel/softirq.c:636
                      irq_exit_rcu+0x5/0x20 kernel/softirq.c:648
                      sysvec_apic_timer_interrupt+0x93/0xc0 arch/x86/kernel/apic/apic.c:1097
                      asm_sysvec_apic_timer_interrupt+0x12/0x20 arch/x86/include/asm/idtentry.h:638
                      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:109 [inline]
                      acpi_idle_do_entry+0x1c6/0x250 drivers/acpi/processor_idle.c:553
                      acpi_idle_enter+0x361/0x500 drivers/acpi/processor_idle.c:688
                      cpuidle_enter_state+0x1b1/0xc80 drivers/cpuidle/cpuidle.c:237
                      cpuidle_enter+0x4a/0xa0 drivers/cpuidle/cpuidle.c:351
                      call_cpuidle kernel/sched/idle.c:158 [inline]
                      cpuidle_idle_call kernel/sched/idle.c:239 [inline]
                      do_idle+0x3e8/0x590 kernel/sched/idle.c:306
                      cpu_startup_entry+0x14/0x20 kernel/sched/idle.c:403
                      start_kernel+0x47a/0x49b init/main.c:1141
                      secondary_startup_64_no_verify+0xb0/0xbb
    INITIAL USE at:
                     lock_acquire kernel/locking/lockdep.c:5625 [inline]
                     lock_acquire+0x1ab/0x510 kernel/locking/lockdep.c:5590
                     __raw_spin_lock_irqsave include/linux/spinlock_api_smp.h:110 [inline]
                     _raw_spin_lock_irqsave+0x39/0x50 kernel/locking/spinlock.c:162
                     ieee80211_do_open+0x15b3/0x2420 net/mac80211/iface.c:1271
                     ieee80211_open net/mac80211/iface.c:362 [inline]
                     ieee80211_open+0x1a0/0x240 net/mac80211/iface.c:348
                     __dev_open+0x2bc/0x4d0 net/core/dev.c:1490
                     __dev_change_flags+0x583/0x750 net/core/dev.c:8774
                     dev_change_flags+0x93/0x170 net/core/dev.c:8845
                     devinet_ioctl+0x15d1/0x1ca0 net/ipv4/devinet.c:1142
                     inet_ioctl+0x1e6/0x320 net/ipv4/af_inet.c:967
                     sock_do_ioctl+0xcc/0x230 net/socket.c:1118
                     sock_ioctl+0x2f1/0x640 net/socket.c:1235
                     vfs_ioctl fs/ioctl.c:51 [inline]
                     __do_sys_ioctl fs/ioctl.c:874 [inline]
                     __se_sys_ioctl fs/ioctl.c:860 [inline]
                     __x64_sys_ioctl+0x193/0x200 fs/ioctl.c:860
                     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+0x44/0xae
  }
  ... key      at: [<ffffffff90613f40>] __key.18+0x0/0x40
  ... acquired at:
   __raw_read_lock_irqsave include/linux/rwlock_api_smp.h:159 [inline]
   _raw_read_lock_irqsave+0x70/0x90 kernel/locking/spinlock.c:236
   netlink_lock_table net/netlink/af_netlink.c:468 [inline]
   netlink_broadcast+0x6c/0xd50 net/netlink/af_netlink.c:1513
   nlmsg_multicast include/net/netlink.h:1033 [inline]
   genlmsg_multicast_netns include/net/genetlink.h:311 [inline]
   nl80211_frame_tx_status+0x8d2/0xb40 net/wireless/nl80211.c:17089
   cfg80211_mgmt_tx_status+0x3b/0x50 net/wireless/nl80211.c:17109
   ieee80211_report_ack_skb net/mac80211/status.c:650 [inline]
   ieee80211_report_used_skb+0x1073/0x1620 net/mac80211/status.c:732
   ieee80211_free_txskb+0x1e/0x30 net/mac80211/status.c:1274
   ieee80211_do_stop+0xd2c/0x2060 net/mac80211/iface.c:564
   ieee80211_runtime_change_iftype net/mac80211/iface.c:1699 [inline]
   ieee80211_if_change_type+0x383/0x840 net/mac80211/iface.c:1737
   ieee80211_change_iface+0x57/0x3d0 net/mac80211/cfg.c:159
   rdev_change_virtual_intf net/wireless/rdev-ops.h:69 [inline]
   cfg80211_change_iface+0x335/0xf60 net/wireless/util.c:1073
   nl80211_set_interface+0x65c/0x8d0 net/wireless/nl80211.c:3930
   genl_family_rcv_msg_doit+0x228/0x320 net/netlink/genetlink.c:731
   genl_family_rcv_msg net/netlink/genetlink.c:775 [inline]
   genl_rcv_msg+0x328/0x580 net/netlink/genetlink.c:792
   netlink_rcv_skb+0x153/0x420 net/netlink/af_netlink.c:2491
   genl_rcv+0x24/0x40 net/netlink/genetlink.c:803
   netlink_unicast_kernel net/netlink/af_netlink.c:1319 [inline]
   netlink_unicast+0x533/0x7d0 net/netlink/af_netlink.c:1345
   netlink_sendmsg+0x86d/0xda0 net/netlink/af_netlink.c:1916
   sock_sendmsg_nosec net/socket.c:704 [inline]
   sock_sendmsg+0xcf/0x120 net/socket.c:724
   ____sys_sendmsg+0x6e8/0x810 net/socket.c:2409
   ___sys_sendmsg+0xf3/0x170 net/socket.c:2463
   __sys_sendmsg+0xe5/0x1b0 net/socket.c:2492
   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+0x44/0xae

-> (nl_table_lock){.+.?}-{2:2} {
   HARDIRQ-ON-R at:
                    lock_acquire kernel/locking/lockdep.c:5625 [inline]
                    lock_acquire+0x1ab/0x510 kernel/locking/lockdep.c:5590
                    __raw_read_lock include/linux/rwlock_api_smp.h:149 [inline]
                    _raw_read_lock+0x36/0x70 kernel/locking/spinlock.c:228
                    netlink_set_err+0x2a/0x3a0 net/netlink/af_netlink.c:1592
                    br_mdb_notify+0x2dc/0xde0 net/bridge/br_mdb.c:815
                    br_multicast_host_join+0x2b8/0x370 net/bridge/br_multicast.c:1323
                    __br_multicast_add_group+0x4f5/0x5e0 net/bridge/br_multicast.c:1366
                    br_multicast_add_group net/bridge/br_multicast.c:1410 [inline]
                    br_ip6_multicast_add_group.part.0+0x190/0x270 net/bridge/br_multicast.c:1462
                    br_ip6_multicast_add_group net/bridge/br_multicast.c:2797 [inline]
                    br_ip6_multicast_mld2_report net/bridge/br_multicast.c:2796 [inline]
                    br_multicast_ipv6_rcv net/bridge/br_multicast.c:3734 [inline]
                    br_multicast_rcv+0xc5f/0x6230 net/bridge/br_multicast.c:3792
                    br_dev_xmit+0x6f6/0x16c0 net/bridge/br_device.c:89
                    __netdev_start_xmit include/linux/netdevice.h:4987 [inline]
                    netdev_start_xmit include/linux/netdevice.h:5001 [inline]
                    xmit_one net/core/dev.c:3584 [inline]
                    dev_hard_start_xmit+0x1eb/0x920 net/core/dev.c:3600
                    __dev_queue_xmit+0x2a26/0x36e0 net/core/dev.c:4210
                    neigh_resolve_output net/core/neighbour.c:1523 [inline]
                    neigh_resolve_output+0x50e/0x820 net/core/neighbour.c:1503
                    neigh_output include/net/neighbour.h:522 [inline]
                    ip6_finish_output2+0x717/0x1500 net/ipv6/ip6_output.c:126
                    __ip6_finish_output net/ipv6/ip6_output.c:191 [inline]
                    __ip6_finish_output+0x4c1/0x1050 net/ipv6/ip6_output.c:170
                    ip6_finish_output+0x32/0x200 net/ipv6/ip6_output.c:201
                    NF_HOOK_COND include/linux/netfilter.h:296 [inline]
                    ip6_output+0x1e4/0x530 net/ipv6/ip6_output.c:224
                    dst_output include/net/dst.h:450 [inline]
                    NF_HOOK include/linux/netfilter.h:307 [inline]
                    NF_HOOK include/linux/netfilter.h:301 [inline]
                    mld_sendpack+0x9a1/0xe40 net/ipv6/mcast.c:1826
                    mld_send_cr net/ipv6/mcast.c:2127 [inline]
                    mld_ifc_work+0x71c/0xdc0 net/ipv6/mcast.c:2659
                    process_one_work+0x9bf/0x16b0 kernel/workqueue.c:2297
                    worker_thread+0x658/0x11f0 kernel/workqueue.c:2444
                    kthread+0x3e5/0x4d0 kernel/kthread.c:319
                    ret_from_fork+0x1f/0x30 arch/x86/entry/entry_64.S:295
   IN-SOFTIRQ-R at:
                    lock_acquire kernel/locking/lockdep.c:5625 [inline]
                    lock_acquire+0x1ab/0x510 kernel/locking/lockdep.c:5590
                    __raw_read_lock_irqsave include/linux/rwlock_api_smp.h:159 [inline]
                    _raw_read_lock_irqsave+0x45/0x90 kernel/locking/spinlock.c:236
                    netlink_lock_table net/netlink/af_netlink.c:468 [inline]
                    netlink_broadcast+0x6c/0xd50 net/netlink/af_netlink.c:1513
                    nlmsg_multicast include/net/netlink.h:1033 [inline]
                    nlmsg_notify+0x8f/0x280 net/netlink/af_netlink.c:2534
                    __neigh_notify+0xdc/0x160 net/core/neighbour.c:3464
                    neigh_update_notify net/core/neighbour.c:2606 [inline]
                    __neigh_update+0x1080/0x2ba0 net/core/neighbour.c:1440
                    arp_process+0xa21/0x24e0 net/ipv4/arp.c:911
                    NF_HOOK include/linux/netfilter.h:307 [inline]
                    NF_HOOK include/linux/netfilter.h:301 [inline]
                    arp_rcv net/ipv4/arp.c:967 [inline]
                    arp_rcv+0x3d7/0x540 net/ipv4/arp.c:942
                    __netif_receive_skb_list_ptype net/core/dev.c:5492 [inline]
                    __netif_receive_skb_list_ptype net/core/dev.c:5476 [inline]
                    __netif_receive_skb_list_core+0x6c7/0x8e0 net/core/dev.c:5535
                    __netif_receive_skb_list net/core/dev.c:5587 [inline]
                    netif_receive_skb_list_internal+0x75e/0xd80 net/core/dev.c:5678
                    gro_normal_list net/core/dev.c:5832 [inline]
                    gro_normal_list net/core/dev.c:5828 [inline]
                    napi_complete_done+0x1f1/0x880 net/core/dev.c:6569
                    virtqueue_napi_complete drivers/net/virtio_net.c:339 [inline]
                    virtnet_poll+0xc88/0x1190 drivers/net/virtio_net.c:1556
                    __napi_poll+0xaf/0x440 net/core/dev.c:6999
                    napi_poll net/core/dev.c:7066 [inline]
                    net_rx_action+0x801/0xb40 net/core/dev.c:7153
                    __do_softirq+0x29b/0x9c2 kernel/softirq.c:558
                    invoke_softirq kernel/softirq.c:432 [inline]
                    __irq_exit_rcu+0x123/0x180 kernel/softirq.c:636
                    irq_exit_rcu+0x5/0x20 kernel/softirq.c:648
                    common_interrupt+0xa4/0xd0 arch/x86/kernel/irq.c:240
                    asm_common_interrupt+0x1e/0x40 arch/x86/include/asm/idtentry.h:629
                    get_current arch/x86/include/asm/current.h:15 [inline]
                    write_comp_data kernel/kcov.c:217 [inline]
                    __sanitizer_cov_trace_const_cmp1+0x15/0x80 kernel/kcov.c:270
                    tomoyo_domain_quota_is_ok+0x32a/0x550 security/tomoyo/util.c:1092
                    tomoyo_supervisor+0x2f2/0xf00 security/tomoyo/common.c:2089
                    tomoyo_audit_path_log security/tomoyo/file.c:168 [inline]
                    tomoyo_path_permission security/tomoyo/file.c:587 [inline]
                    tomoyo_path_permission+0x270/0x3a0 security/tomoyo/file.c:573
                    tomoyo_path_perm+0x2f0/0x400 security/tomoyo/file.c:838
                    security_inode_getattr+0xcf/0x140 security/security.c:1333
                    vfs_getattr fs/stat.c:157 [inline]
                    vfs_statx+0x164/0x390 fs/stat.c:225
                    vfs_fstatat fs/stat.c:243 [inline]
                    vfs_lstat include/linux/fs.h:3356 [inline]
                    __do_sys_newlstat+0x91/0x110 fs/stat.c:398
                    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+0x44/0xae
   SOFTIRQ-ON-R at:
                    lock_acquire kernel/locking/lockdep.c:5625 [inline]
                    lock_acquire+0x1ab/0x510 kernel/locking/lockdep.c:5590
                    __raw_read_lock include/linux/rwlock_api_smp.h:149 [inline]
                    _raw_read_lock+0x5b/0x70 kernel/locking/spinlock.c:228
                    __netlink_diag_dump+0x2ce/0x790 net/netlink/diag.c:155
                    netlink_diag_dump+0x198/0x230 net/netlink/diag.c:196
                    netlink_dump+0x4b0/0xb60 net/netlink/af_netlink.c:2265
                    __netlink_dump_start+0x642/0x900 net/netlink/af_netlink.c:2370
                    netlink_dump_start include/linux/netlink.h:254 [inline]
                    netlink_diag_handler_dump+0x1aa/0x240 net/netlink/diag.c:237
                    __sock_diag_cmd net/core/sock_diag.c:234 [inline]
                    sock_diag_rcv_msg+0x31a/0x440 net/core/sock_diag.c:265
                    netlink_rcv_skb+0x153/0x420 net/netlink/af_netlink.c:2491
                    sock_diag_rcv+0x26/0x40 net/core/sock_diag.c:276
                    netlink_unicast_kernel net/netlink/af_netlink.c:1319 [inline]
                    netlink_unicast+0x533/0x7d0 net/netlink/af_netlink.c:1345
                    netlink_sendmsg+0x86d/0xda0 net/netlink/af_netlink.c:1916
                    sock_sendmsg_nosec net/socket.c:704 [inline]
                    sock_sendmsg+0xcf/0x120 net/socket.c:724
                    sock_write_iter+0x289/0x3c0 net/socket.c:1057
                    call_write_iter include/linux/fs.h:2163 [inline]
                    do_iter_readv_writev+0x472/0x750 fs/read_write.c:729
                    do_iter_write+0x188/0x710 fs/read_write.c:855
                    vfs_writev+0x1aa/0x630 fs/read_write.c:928
                    do_writev+0x27f/0x300 fs/read_write.c:971
                    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+0x44/0xae
   INITIAL USE at:
                   lock_acquire kernel/locking/lockdep.c:5625 [inline]
                   lock_acquire+0x1ab/0x510 kernel/locking/lockdep.c:5590
                   __raw_write_lock_irq include/linux/rwlock_api_smp.h:196 [inline]
                   _raw_write_lock_irq+0x32/0x50 kernel/locking/spinlock.c:316
                   netlink_table_grab+0x2a/0x70 net/netlink/af_netlink.c:434
                   netlink_add_usersock_entry net/netlink/af_netlink.c:2796 [inline]
                   netlink_proto_init+0x195/0x2ea net/netlink/af_netlink.c:2887
                   do_one_initcall+0x103/0x650 init/main.c:1303
                   do_initcall_level init/main.c:1376 [inline]
                   do_initcalls init/main.c:1392 [inline]
                   do_basic_setup init/main.c:1411 [inline]
                   kernel_init_freeable+0x6b1/0x73a init/main.c:1614
                   kernel_init+0x1a/0x1d0 init/main.c:1505
                   ret_from_fork+0x1f/0x30 arch/x86/entry/entry_64.S:295
   INITIAL READ USE at:
                        lock_acquire kernel/locking/lockdep.c:5625 [inline]
                        lock_acquire+0x1ab/0x510 kernel/locking/lockdep.c:5590
                        __raw_read_lock_irqsave include/linux/rwlock_api_smp.h:159 [inline]
                        _raw_read_lock_irqsave+0x70/0x90 kernel/locking/spinlock.c:236
                        netlink_lock_table net/netlink/af_netlink.c:468 [inline]
                        netlink_broadcast+0x6c/0xd50 net/netlink/af_netlink.c:1513
                        nlmsg_multicast include/net/netlink.h:1033 [inline]
                        genlmsg_multicast_netns include/net/genetlink.h:311 [inline]
                        genl_ctrl_event.isra.0+0x3ea/0xa60 net/netlink/genetlink.c:1093
                        genl_register_family net/netlink/genetlink.c:430 [inline]
                        genl_register_family+0xad7/0x12e0 net/netlink/genetlink.c:384
                        thermal_init+0x12/0x253 drivers/thermal/thermal_core.c:1454
                        do_one_initcall+0x103/0x650 init/main.c:1303
                        do_initcall_level init/main.c:1376 [inline]
                        do_initcalls init/main.c:1392 [inline]
                        do_basic_setup init/main.c:1411 [inline]
                        kernel_init_freeable+0x6b1/0x73a init/main.c:1614
                        kernel_init+0x1a/0x1d0 init/main.c:1505
                        ret_from_fork+0x1f/0x30 arch/x86/entry/entry_64.S:295
 }
 ... key      at: [<ffffffff8d17ad38>] nl_table_lock+0x18/0x60
 ... acquired at:
   mark_usage kernel/locking/lockdep.c:4506 [inline]
   __lock_acquire+0x88f/0x54a0 kernel/locking/lockdep.c:4969
   lock_acquire kernel/locking/lockdep.c:5625 [inline]
   lock_acquire+0x1ab/0x510 kernel/locking/lockdep.c:5590
   __raw_read_lock include/linux/rwlock_api_smp.h:149 [inline]
   _raw_read_lock+0x5b/0x70 kernel/locking/spinlock.c:228
   __netlink_diag_dump+0x2ce/0x790 net/netlink/diag.c:155
   netlink_diag_dump+0x198/0x230 net/netlink/diag.c:196
   netlink_dump+0x4b0/0xb60 net/netlink/af_netlink.c:2265
   __netlink_dump_start+0x642/0x900 net/netlink/af_netlink.c:2370
   netlink_dump_start include/linux/netlink.h:254 [inline]
   netlink_diag_handler_dump+0x1aa/0x240 net/netlink/diag.c:237
   __sock_diag_cmd net/core/sock_diag.c:234 [inline]
   sock_diag_rcv_msg+0x31a/0x440 net/core/sock_diag.c:265
   netlink_rcv_skb+0x153/0x420 net/netlink/af_netlink.c:2491
   sock_diag_rcv+0x26/0x40 net/core/sock_diag.c:276
   netlink_unicast_kernel net/netlink/af_netlink.c:1319 [inline]
   netlink_unicast+0x533/0x7d0 net/netlink/af_netlink.c:1345
   netlink_sendmsg+0x86d/0xda0 net/netlink/af_netlink.c:1916
   sock_sendmsg_nosec net/socket.c:704 [inline]
   sock_sendmsg+0xcf/0x120 net/socket.c:724
   sock_write_iter+0x289/0x3c0 net/socket.c:1057
   call_write_iter include/linux/fs.h:2163 [inline]
   do_iter_readv_writev+0x472/0x750 fs/read_write.c:729
   do_iter_write+0x188/0x710 fs/read_write.c:855
   vfs_writev+0x1aa/0x630 fs/read_write.c:928
   do_writev+0x27f/0x300 fs/read_write.c:971
   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+0x44/0xae


stack backtrace:
CPU: 1 PID: 17246 Comm: syz-executor.1 Not tainted 5.15.0-rc5-syzkaller #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011
Call Trace:
 __dump_stack lib/dump_stack.c:88 [inline]
 dump_stack_lvl+0xcd/0x134 lib/dump_stack.c:106
 print_irq_inversion_bug kernel/locking/lockdep.c:203 [inline]
 check_usage_backwards kernel/locking/lockdep.c:4066 [inline]
 mark_lock_irq kernel/locking/lockdep.c:4156 [inline]
 mark_lock.cold+0x1d/0x8e kernel/locking/lockdep.c:4593
 mark_usage kernel/locking/lockdep.c:4506 [inline]
 __lock_acquire+0x88f/0x54a0 kernel/locking/lockdep.c:4969
 lock_acquire kernel/locking/lockdep.c:5625 [inline]
 lock_acquire+0x1ab/0x510 kernel/locking/lockdep.c:5590
 __raw_read_lock include/linux/rwlock_api_smp.h:149 [inline]
 _raw_read_lock+0x5b/0x70 kernel/locking/spinlock.c:228
 __netlink_diag_dump+0x2ce/0x790 net/netlink/diag.c:155
 netlink_diag_dump+0x198/0x230 net/netlink/diag.c:196
 netlink_dump+0x4b0/0xb60 net/netlink/af_netlink.c:2265
 __netlink_dump_start+0x642/0x900 net/netlink/af_netlink.c:2370
 netlink_dump_start include/linux/netlink.h:254 [inline]
 netlink_diag_handler_dump+0x1aa/0x240 net/netlink/diag.c:237
 __sock_diag_cmd net/core/sock_diag.c:234 [inline]
 sock_diag_rcv_msg+0x31a/0x440 net/core/sock_diag.c:265
 netlink_rcv_skb+0x153/0x420 net/netlink/af_netlink.c:2491
 sock_diag_rcv+0x26/0x40 net/core/sock_diag.c:276
 netlink_unicast_kernel net/netlink/af_netlink.c:1319 [inline]
 netlink_unicast+0x533/0x7d0 net/netlink/af_netlink.c:1345
 netlink_sendmsg+0x86d/0xda0 net/netlink/af_netlink.c:1916
 sock_sendmsg_nosec net/socket.c:704 [inline]
 sock_sendmsg+0xcf/0x120 net/socket.c:724
 sock_write_iter+0x289/0x3c0 net/socket.c:1057
 call_write_iter include/linux/fs.h:2163 [inline]
 do_iter_readv_writev+0x472/0x750 fs/read_write.c:729
 do_iter_write+0x188/0x710 fs/read_write.c:855
 vfs_writev+0x1aa/0x630 fs/read_write.c:928
 do_writev+0x27f/0x300 fs/read_write.c:971
 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+0x44/0xae
RIP: 0033:0x7fc0a8e86a39
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 bc ff ff ff f7 d8 64 89 01 48
RSP: 002b:00007fc0a63fc188 EFLAGS: 00000246 ORIG_RAX: 0000000000000014
RAX: ffffffffffffffda RBX: 00007fc0a8f89f60 RCX: 00007fc0a8e86a39
RDX: 0000000000000001 RSI: 0000000020000100 RDI: 0000000000000003
RBP: 00007fc0a8ee0c5f R08: 0000000000000000 R09: 0000000000000000
R10: 0000000000000000 R11: 0000000000000246 R12: 0000000000000000
R13: 00007ffca5400d7f R14: 00007fc0a63fc300 R15: 0000000000022000

Crashes (1):
Manager Time Kernel Commit Syzkaller Config Log Report Syz repro C repro VM info Title
ci-upstream-net-kasan-gce 2021/10/18 07:01 net-next 4e6e167bc049 0c5d9412 .config log report info possible deadlock in __netlink_diag_dump
* Struck through repros no longer work on HEAD.