lapbether: lapb_data_request error - 4
lapbether: lapb_data_request error - 4
lapbether: lapb_data_request error - 4
lapbether: lapb_data_request error - 4
======================================================
WARNING: possible circular locking dependency detected
syzkaller #0 Not tainted
------------------------------------------------------
klogd/4975 is trying to acquire lock:
ffff888021781958 (_xmit_X25#2){+.-.}-{3:3}, at: spin_lock include/linux/spinlock.h:347 [inline]
ffff888021781958 (_xmit_X25#2){+.-.}-{3:3}, at: __netif_tx_lock include/linux/netdevice.h:4864 [inline]
ffff888021781958 (_xmit_X25#2){+.-.}-{3:3}, at: __dev_queue_xmit+0xe9d/0x3920 net/core/dev.c:5060
but task is already holding lock:
ffff8880580e6dc0 (&lapb->lock){+.-.}-{3:3}, at: spin_lock_bh include/linux/spinlock.h:353 [inline]
ffff8880580e6dc0 (&lapb->lock){+.-.}-{3:3}, at: lapb_t1timer_expiry+0x33/0xaa0 net/lapb/lapb_timer.c:99
which lock already depends on the new lock.
the existing dependency chain (in reverse order) is:
-> #2 (&lapb->lock){+.-.}-{3:3}:
__raw_spin_lock_bh include/linux/spinlock_api_smp.h:182 [inline]
_raw_spin_lock_bh+0x36/0x50 kernel/locking/spinlock.c:205
spin_lock_bh include/linux/spinlock.h:353 [inline]
lapb_data_received+0xfc/0x1c0 net/lapb/lapb_iface.c:398
lapbeth_rcv+0x34d/0x640 drivers/net/wan/lapbether.c:142
__netif_receive_skb_one_core net/core/dev.c:6405 [inline]
__netif_receive_skb net/core/dev.c:6518 [inline]
process_backlog+0xc26/0x18b0 net/core/dev.c:6869
__napi_poll+0xaa/0x330 net/core/dev.c:7938
napi_poll net/core/dev.c:8001 [inline]
net_rx_action+0x61d/0xf50 net/core/dev.c:8158
handle_softirqs+0x226/0x860 kernel/softirq.c:645
do_softirq+0x77/0xd0 kernel/softirq.c:546
__local_bh_enable_ip+0x100/0x140 kernel/softirq.c:473
spin_unlock_bh include/linux/spinlock.h:407 [inline]
lapb_device_event+0x4f3/0x680 net/lapb/lapb_iface.c:527
notifier_call_chain+0x1a5/0x3d0 kernel/notifier.c:85
call_netdevice_notifiers_extack net/core/dev.c:2351 [inline]
call_netdevice_notifiers net/core/dev.c:2365 [inline]
__dev_notify_flags+0x31e/0x510 net/core/dev.c:10004
netif_change_flags+0xde/0x1b0 net/core/dev.c:10033
dev_change_flags+0x128/0x260 net/core/dev_api.c:68
devinet_ioctl+0x966/0x1c50 net/ipv4/devinet.c:1189
inet_ioctl+0x42a/0x560 net/ipv4/af_inet.c:1006
sock_do_ioctl+0x101/0x320 net/socket.c:1328
sock_ioctl+0x57a/0x7e0 net/socket.c:1449
vfs_ioctl fs/ioctl.c:51 [inline]
__do_sys_ioctl fs/ioctl.c:597 [inline]
__se_sys_ioctl+0xfc/0x170 fs/ioctl.c:583
do_syscall_x64 arch/x86/entry/syscall_64.c:61 [inline]
do_syscall_64+0x166/0x520 arch/x86/entry/syscall_64.c:84
entry_SYSCALL_64_after_hwframe+0x77/0x7f
-> #1 (&lapbeth->up_lock){+.-.}-{3:3}:
__raw_spin_lock_bh include/linux/spinlock_api_smp.h:182 [inline]
_raw_spin_lock_bh+0x36/0x50 kernel/locking/spinlock.c:205
spin_lock_bh include/linux/spinlock.h:353 [inline]
lapbeth_xmit+0x32/0x260 drivers/net/wan/lapbether.c:191
__netdev_start_xmit include/linux/netdevice.h:5455 [inline]
netdev_start_xmit include/linux/netdevice.h:5464 [inline]
xmit_one net/core/dev.c:4057 [inline]
dev_hard_start_xmit+0x2cd/0x830 net/core/dev.c:4073
__dev_queue_xmit+0x14d1/0x3920 net/core/dev.c:5066
dev_queue_xmit include/linux/netdevice.h:3483 [inline]
tx+0x6b/0x190 drivers/block/aoe/aoenet.c:62
kthread+0x1ed/0x420 drivers/block/aoe/aoecmd.c:1241
kthread+0x38b/0x480 kernel/kthread.c:436
ret_from_fork+0x514/0xb70 arch/x86/kernel/process.c:158
ret_from_fork_asm+0x1a/0x30 arch/x86/entry/entry_64.S:245
-> #0 (_xmit_X25#2){+.-.}-{3:3}:
check_prev_add kernel/locking/lockdep.c:3209 [inline]
check_prevs_add kernel/locking/lockdep.c:3328 [inline]
validate_chain kernel/locking/lockdep.c:3952 [inline]
__lock_acquire+0x164c/0x2de0 kernel/locking/lockdep.c:5288
lock_acquire+0x115/0x350 kernel/locking/lockdep.c:5942
__raw_spin_lock include/linux/spinlock_api_smp.h:190 [inline]
_raw_spin_lock+0x2e/0x40 kernel/locking/spinlock.c:173
spin_lock include/linux/spinlock.h:347 [inline]
__netif_tx_lock include/linux/netdevice.h:4864 [inline]
__dev_queue_xmit+0xe9d/0x3920 net/core/dev.c:5060
neigh_output include/net/neighbour.h:554 [inline]
ip_finish_output2+0xc4b/0x10b0 net/ipv4/ip_output.c:236
iptunnel_xmit+0x626/0xd10 net/ipv4/ip_tunnel_core.c:97
ip_tunnel_xmit+0x1960/0x2040 net/ipv4/ip_tunnel.c:852
__gre_xmit net/ipv4/ip_gre.c:488 [inline]
gre_tap_xmit+0x543/0x760 net/ipv4/ip_gre.c:783
__netdev_start_xmit include/linux/netdevice.h:5455 [inline]
netdev_start_xmit include/linux/netdevice.h:5464 [inline]
xmit_one net/core/dev.c:4057 [inline]
dev_hard_start_xmit+0x2cd/0x830 net/core/dev.c:4073
sch_direct_xmit+0x257/0x4c0 net/sched/sch_generic.c:372
__dev_xmit_skb net/core/dev.c:4385 [inline]
__dev_queue_xmit+0x179a/0x3920 net/core/dev.c:5024
lapb_data_transmit+0x90/0xb0 net/lapb/lapb_iface.c:447
lapb_transmit_buffer+0x163/0x200 net/lapb/lapb_out.c:149
lapb_t1timer_expiry+0x68d/0xaa0 net/lapb/lapb_timer.c:-1
call_timer_fn+0x18d/0x5f0 kernel/time/timer.c:1748
expire_timers kernel/time/timer.c:1799 [inline]
__run_timers kernel/time/timer.c:2374 [inline]
__run_timer_base+0x652/0x8b0 kernel/time/timer.c:2386
run_timer_base kernel/time/timer.c:2395 [inline]
run_timer_softirq+0xb7/0x170 kernel/time/timer.c:2405
handle_softirqs+0x226/0x860 kernel/softirq.c:645
do_softirq+0x77/0xd0 kernel/softirq.c:546
__local_bh_enable_ip+0x100/0x140 kernel/softirq.c:473
local_bh_enable include/linux/bottom_half.h:33 [inline]
__alloc_skb+0x1b1/0x7a0 net/core/skbuff.c:700
alloc_skb include/linux/skbuff.h:1390 [inline]
alloc_skb_with_frags+0xc6/0x760 net/core/skbuff.c:6893
sock_alloc_send_pskb+0xb66/0xc90 net/core/sock.c:3065
unix_dgram_sendmsg+0x4da/0x17b0 net/unix/af_unix.c:2144
sock_sendmsg_nosec+0x14e/0x190 net/socket.c:800
__sock_sendmsg net/socket.c:818 [inline]
__sys_sendto+0x408/0x5a0 net/socket.c:2283
__do_sys_sendto net/socket.c:2290 [inline]
__se_sys_sendto net/socket.c:2286 [inline]
__x64_sys_sendto+0xde/0x100 net/socket.c:2286
do_syscall_x64 arch/x86/entry/syscall_64.c:61 [inline]
do_syscall_64+0x166/0x520 arch/x86/entry/syscall_64.c:84
entry_SYSCALL_64_after_hwframe+0x77/0x7f
other info that might help us debug this:
Chain exists of:
_xmit_X25#2 --> &lapbeth->up_lock --> &lapb->lock
Possible unsafe locking scenario:
CPU0 CPU1
---- ----
lock(&lapb->lock);
lock(&lapbeth->up_lock);
lock(&lapb->lock);
lock(_xmit_X25#2);
*** DEADLOCK ***
locks held by klogd/4975: 6, last CPU#1:
#0: ffffc90000a18d00 ((&lapb->t1timer)){+.-.}-{0:0}, at: call_timer_fn+0xd5/0x5f0 kernel/time/timer.c:1745
#1: ffff8880580e6dc0 (&lapb->lock){+.-.}-{3:3}, at: spin_lock_bh include/linux/spinlock.h:353 [inline]
#1: ffff8880580e6dc0 (&lapb->lock){+.-.}-{3:3}, at: lapb_t1timer_expiry+0x33/0xaa0 net/lapb/lapb_timer.c:99
#2: ffffffff8fd5c940 (rcu_read_lock_bh){....}-{1:3}, at: local_bh_disable include/linux/bottom_half.h:20 [inline]
#2: ffffffff8fd5c940 (rcu_read_lock_bh){....}-{1:3}, at: rcu_read_lock_bh include/linux/rcupdate.h:902 [inline]
#2: ffffffff8fd5c940 (rcu_read_lock_bh){....}-{1:3}, at: __dev_queue_xmit+0x29b/0x3920 net/core/dev.c:4980
#3: ffff888049adb228 (dev->qdisc_tx_busylock ?: &qdisc_tx_busylock#3){+...}-{3:3}, at: spin_trylock include/linux/spinlock.h:359 [inline]
#3: ffff888049adb228 (dev->qdisc_tx_busylock ?: &qdisc_tx_busylock#3){+...}-{3:3}, at: qdisc_run_begin include/net/sch_generic.h:206 [inline]
#3: ffff888049adb228 (dev->qdisc_tx_busylock ?: &qdisc_tx_busylock#3){+...}-{3:3}, at: __dev_xmit_skb net/core/dev.c:4372 [inline]
#3: ffff888049adb228 (dev->qdisc_tx_busylock ?: &qdisc_tx_busylock#3){+...}-{3:3}, at: __dev_queue_xmit+0x114e/0x3920 net/core/dev.c:5024
#4: ffffffff8fd5c8e0 (rcu_read_lock){....}-{1:3}, at: rcu_lock_acquire include/linux/rcupdate.h:309 [inline]
#4: ffffffff8fd5c8e0 (rcu_read_lock){....}-{1:3}, at: rcu_read_lock include/linux/rcupdate.h:849 [inline]
#4: ffffffff8fd5c8e0 (rcu_read_lock){....}-{1:3}, at: ip_finish_output2+0x3de/0x10b0 net/ipv4/ip_output.c:229
#5: ffffffff8fd5c940 (rcu_read_lock_bh){....}-{1:3}, at: local_bh_disable include/linux/bottom_half.h:20 [inline]
#5: ffffffff8fd5c940 (rcu_read_lock_bh){....}-{1:3}, at: rcu_read_lock_bh include/linux/rcupdate.h:902 [inline]
#5: ffffffff8fd5c940 (rcu_read_lock_bh){....}-{1:3}, at: __dev_queue_xmit+0x29b/0x3920 net/core/dev.c:4980
stack backtrace:
CPU: 1 UID: 0 PID: 4975 Comm: klogd Not tainted syzkaller #0 PREEMPT(full)
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 10/07/2026
Call Trace:
dump_stack_lvl+0xe8/0x150 lib/dump_stack.c:120
print_circular_bug+0x2e2/0x300 kernel/locking/lockdep.c:2087
check_noncircular+0x12f/0x150 kernel/locking/lockdep.c:2219
check_prev_add kernel/locking/lockdep.c:3209 [inline]
check_prevs_add kernel/locking/lockdep.c:3328 [inline]
validate_chain kernel/locking/lockdep.c:3952 [inline]
__lock_acquire+0x164c/0x2de0 kernel/locking/lockdep.c:5288
lock_acquire+0x115/0x350 kernel/locking/lockdep.c:5942
__raw_spin_lock include/linux/spinlock_api_smp.h:190 [inline]
_raw_spin_lock+0x2e/0x40 kernel/locking/spinlock.c:173
spin_lock include/linux/spinlock.h:347 [inline]
__netif_tx_lock include/linux/netdevice.h:4864 [inline]
__dev_queue_xmit+0xe9d/0x3920 net/core/dev.c:5060
neigh_output include/net/neighbour.h:554 [inline]
ip_finish_output2+0xc4b/0x10b0 net/ipv4/ip_output.c:236
iptunnel_xmit+0x626/0xd10 net/ipv4/ip_tunnel_core.c:97
ip_tunnel_xmit+0x1960/0x2040 net/ipv4/ip_tunnel.c:852
__gre_xmit net/ipv4/ip_gre.c:488 [inline]
gre_tap_xmit+0x543/0x760 net/ipv4/ip_gre.c:783
__netdev_start_xmit include/linux/netdevice.h:5455 [inline]
netdev_start_xmit include/linux/netdevice.h:5464 [inline]
xmit_one net/core/dev.c:4057 [inline]
dev_hard_start_xmit+0x2cd/0x830 net/core/dev.c:4073
sch_direct_xmit+0x257/0x4c0 net/sched/sch_generic.c:372
__dev_xmit_skb net/core/dev.c:4385 [inline]
__dev_queue_xmit+0x179a/0x3920 net/core/dev.c:5024
lapb_data_transmit+0x90/0xb0 net/lapb/lapb_iface.c:447
lapb_transmit_buffer+0x163/0x200 net/lapb/lapb_out.c:149
lapb_t1timer_expiry+0x68d/0xaa0 net/lapb/lapb_timer.c:-1
call_timer_fn+0x18d/0x5f0 kernel/time/timer.c:1748
expire_timers kernel/time/timer.c:1799 [inline]
__run_timers kernel/time/timer.c:2374 [inline]
__run_timer_base+0x652/0x8b0 kernel/time/timer.c:2386
run_timer_base kernel/time/timer.c:2395 [inline]
run_timer_softirq+0xb7/0x170 kernel/time/timer.c:2405
handle_softirqs+0x226/0x860 kernel/softirq.c:645
do_softirq+0x77/0xd0 kernel/softirq.c:546
__local_bh_enable_ip+0x100/0x140 kernel/softirq.c:473
local_bh_enable include/linux/bottom_half.h:33 [inline]
__alloc_skb+0x1b1/0x7a0 net/core/skbuff.c:700
alloc_skb include/linux/skbuff.h:1390 [inline]
alloc_skb_with_frags+0xc6/0x760 net/core/skbuff.c:6893
sock_alloc_send_pskb+0xb66/0xc90 net/core/sock.c:3065
unix_dgram_sendmsg+0x4da/0x17b0 net/unix/af_unix.c:2144
sock_sendmsg_nosec+0x14e/0x190 net/socket.c:800
__sock_sendmsg net/socket.c:818 [inline]
__sys_sendto+0x408/0x5a0 net/socket.c:2283
__do_sys_sendto net/socket.c:2290 [inline]
__se_sys_sendto net/socket.c:2286 [inline]
__x64_sys_sendto+0xde/0x100 net/socket.c:2286
do_syscall_x64 arch/x86/entry/syscall_64.c:61 [inline]
do_syscall_64+0x166/0x520 arch/x86/entry/syscall_64.c:84
entry_SYSCALL_64_after_hwframe+0x77/0x7f
RIP: 0033:0x7f574719f407
Code: 48 89 fa 4c 89 df e8 38 aa 00 00 8b 93 08 03 00 00 59 5e 48 83 f8 fc 74 1a 5b c3 0f 1f 84 00 00 00 00 00 48 8b 44 24 10 0f 05 <5b> c3 0f 1f 80 00 00 00 00 83 e2 39 83 fa 08 75 de e8 23 ff ff ff
RSP: 002b:00007ffc8bae3e30 EFLAGS: 00000202 ORIG_RAX: 000000000000002c
RAX: ffffffffffffffda RBX: 00007f574704fc80 RCX: 00007f574719f407
RDX: 0000000000000058 RSI: 00007ffc8bae3f70 RDI: 0000000000000003
RBP: 00007ffc8bae43a0 R08: 0000000000000000 R09: 0000000000000000
R10: 0000000000004000 R11: 0000000000000202 R12: 00007ffc8bae43b8
R13: 00007ffc8bae3f70 R14: 000000000000003d R15: 00007ffc8bae3f70
lapbether: lapb_data_request error - 4
lapbether: lapb_data_request error - 4
lapbether: lapb_data_request error - 4
lapbether: lapb_data_request error - 4
lapbether: lapb_data_request error - 4
lapbether: lapb_data_request error - 4
lapbether: lapb_data_request error - 4
lapbether: lapb_data_request error - 4
lapbether: lapb_data_request error - 4
lapbether: lapb_data_request error - 4
lapbether: lapb_data_request error - 4
lapbether: lapb_data_request error - 4
lapbether: lapb_data_request error - 4
lapbether: lapb_data_request error - 4
lapbether: lapb_data_request error - 4
lapbether: lapb_data_request error - 4
lapbether: lapb_data_request error - 4
lapbether: lapb_data_request error - 4
lapbether: lapb_data_request error - 4
lapbether: lapb_data_request error - 4
lapbether: lapb_data_request error - 4
lapbether: lapb_data_request error - 4
lapbether: lapb_data_request error - 4
lapbether: lapb_data_request error - 4
lapbether: lapb_data_request error - 4
lapbether: lapb_data_request error - 4
lapbether: lapb_data_request error - 4
lapbether: lapb_data_request error - 4
lapbether: lapb_data_request error - 4
lapbether: lapb_data_request error - 4
lapbether: lapb_data_request error - 4
lapbether: lapb_data_request error - 4
lapbether: lapb_data_request error - 4
lapbether: lapb_data_request error - 4
lapbether: lapb_data_request error - 4
lapbether: lapb_data_request error - 4
lapbether: lapb_data_request error - 4
lapbether: lapb_data_request error - 4
lapbether: lapb_data_request error - 4
lapbether: lapb_data_request error - 4
lapbether: lapb_data_request error - 4
lapbether: lapb_data_request error - 4
lapbether: lapb_data_request error - 4
lapbether: lapb_data_request error - 4
lapbether: lapb_data_request error - 4
lapbether: lapb_data_request error - 4
lapbether: lapb_data_request error - 4
lapbether: lapb_data_request error - 4
lapbether: lapb_data_request error - 4
lapbether: lapb_data_request error - 4
lapbether: lapb_data_request error - 4
lapbether: lapb_data_request error - 4
lapbether: lapb_data_request error - 4
lapbether: lapb_data_request error - 4
lapbether: lapb_data_request error - 4
lapbether: lapb_data_request error - 4
lapbether: lapb_data_request error - 4
lapbether: lapb_data_request error - 4
lapbether: lapb_data_request error - 4
lapbether: lapb_data_request error - 4
lapbether: lapb_data_request error - 4
lapbether: lapb_data_request error - 4
lapbether: lapb_data_request error - 4
lapbether: lapb_data_request error - 4
lapbether: lapb_data_request error - 4
lapbether: lapb_data_request error - 4
lapbether: lapb_data_request error - 4
lapbether: lapb_data_request error - 4
lapbether: lapb_data_request error - 4
lapbether: lapb_data_request error - 4
lapbether: lapb_data_request error - 4
lapbether: lapb_data_request error - 4
lapbether: lapb_data_request error - 4
lapbether: lapb_data_request error - 4
lapbether: lapb_data_request error - 4
lapbether: lapb_data_request error - 4
lapbether: lapb_data_request error - 4
lapbether: lapb_data_request error - 4
lapbether: lapb_data_request error - 4
lapbether: lapb_data_request error - 4
lapbether: lapb_data_request error - 4