From: syzbot <syzbot+c6bddbec1a368100eb25@syzkaller.appspotmail.com>
To: achender@kernel.org, axboe@kernel.dk, davem@davemloft.net,
edumazet@google.com, edumazet@kernel.org, horms@kernel.org,
josef@toxicpanda.com, kartikey406@gmail.com, kuba@kernel.org,
kuniyu@google.com, linux-block@vger.kernel.org,
linux-kernel@vger.kernel.org, linux-rdma@vger.kernel.org,
nbd@other.debian.org, ncardwell@google.com,
netdev@vger.kernel.org, pabeni@redhat.com,
rds-devel@oss.oracle.com, syzkaller-bugs@googlegroups.com,
willemb@google.com
Subject: [syzbot] [nbd?] [rds?] possible deadlock in rds_tcp_recv_path (3)
Date: Sun, 29 Nov 2026 01:13:42 -0800 [thread overview]
Message-ID: <6b0becc6.c4dd33ab.25911d.0027.GAE@google.com> (raw)
Hello,
syzbot found the following issue on:
HEAD commit: 28a371228d4e selftests: bridge_mdb: Test failed source lis..
git tree: net
console output: https://syzkaller.appspot.com/x/log.txt?x=149248e9580000
kernel config: https://syzkaller.appspot.com/x/.config?x=b17c6161667d112d
dashboard link: https://syzkaller.appspot.com/bug?extid=c6bddbec1a368100eb25
compiler: Debian clang version 22.1.8 (1~deb13u5), Debian LLD 22.1.8
Unfortunately, I don't have any reproducer for this issue yet.
Downloadable assets:
disk image: https://storage.googleapis.com/syzbot-assets/066001d29ea3/disk-28a37122.raw.xz
vmlinux: https://storage.googleapis.com/syzbot-assets/e158c7ce539f/vmlinux-28a37122.xz
kernel image: https://storage.googleapis.com/syzbot-assets/8154a3d65bd1/bzImage-28a37122.xz
The issue was bisected by AI to:
commit 9280e6edf65662b6aafc8b704ad065b54c08b519
Author: Deepanshu Kartikey <kartikey406@gmail.com>
Date: Sun Jun 21 23:52:55 2026 +0000
nbd: don't warn when reclassifying a busy socket lock
reasoning: https://syzkaller.appspot.com/ai_job?id=5151cf29-ebf6-4c4e-93bb-337afc0bd9de
AI-generated root cause summary:
Lockdep reports a circular locking dependency (`fs_reclaim -> sk_lock-AF_INET6
-> k-sk_lock-AF_INET6 -> fs_reclaim`) due to lockdep class aliasing across
unrelated AF_INET6 sockets. In `drivers/block/nbd.c`, `nbd_reclassify_socket()`
silently skips moving an NBD socket out of the generic `sk_lock-AF_INET6` class
if `sock_allow_reclassification(sk)` returns false (e.g., when the socket lock
or slock is concurrently held), causing NBD's block-reclaim lock ordering
(`fs_reclaim -> ... -> nsock->tx_lock -> sk_lock`) to be recorded on
`sk_lock-AF_INET6`. Combined with MPTCP nesting `sk_lock-AF_INET6 ->
k-sk_lock-AF_INET6` in `mptcp_setsockopt_first_sf_only()` and RDS-TCP performing
`GFP_KERNEL` allocations (`fs_reclaim`) while holding `lock_sock(sock->sk)`
(`k-sk_lock-AF_INET6`) in `rds_tcp_recv_path()`, lockdep detects a cycle.
full analysis: https://syzkaller.appspot.com/x/ai_root_cause?x=c6bddbec1a368100eb25
IMPORTANT: if you fix the issue, please add the following tag to the commit:
Reported-by: syzbot+c6bddbec1a368100eb25@syzkaller.appspotmail.com
The bisection result may be wrong.
If you agree with it, please also add:
Fixes: 9280e6edf656 ("nbd: don't warn when reclassifying a busy socket lock")
======================================================
WARNING: possible circular locking dependency detected
syzkaller #0 Not tainted
------------------------------------------------------
kworker/u8:11/3383 is trying to acquire lock:
ffffffff902954c0 (fs_reclaim){+.+.}-{0:0}, at: might_alloc include/linux/sched/mm.h:316 [inline]
ffffffff902954c0 (fs_reclaim){+.+.}-{0:0}, at: slab_pre_alloc_hook mm/slub.c:4673 [inline]
ffffffff902954c0 (fs_reclaim){+.+.}-{0:0}, at: slab_alloc_node mm/slub.c:5011 [inline]
ffffffff902954c0 (fs_reclaim){+.+.}-{0:0}, at: kmem_cache_alloc_noprof+0x5f/0x600 mm/slub.c:5047
but task is already holding lock:
ffff88807d634720 (k-sk_lock-AF_INET6){+.+.}-{0:0}, at: lock_sock include/net/sock.h:1717 [inline]
ffff88807d634720 (k-sk_lock-AF_INET6){+.+.}-{0:0}, at: rds_tcp_recv_path+0xfe/0x340 net/rds/tcp_recv.c:304
which lock already depends on the new lock.
the existing dependency chain (in reverse order) is:
-> #7 (k-sk_lock-AF_INET6){+.+.}-{0:0}:
lock_sock_nested+0x41/0x100 net/core/sock.c:3909
do_tcp_setsockopt+0x8ec/0x1f70 net/ipv4/tcp.c:3977
mptcp_setsockopt_first_sf_only net/mptcp/sockopt.c:804 [inline]
mptcp_setsockopt_sol_tcp net/mptcp/sockopt.c:852 [inline]
mptcp_setsockopt+0x1165/0x3550 net/mptcp/sockopt.c:940
do_sock_setsockopt+0x17c/0x1b0 net/socket.c:2399
__sys_setsockopt net/socket.c:2424 [inline]
__do_sys_setsockopt net/socket.c:2430 [inline]
__se_sys_setsockopt net/socket.c:2427 [inline]
__x64_sys_setsockopt+0x13d/0x1b0 net/socket.c:2427
do_syscall_x64 arch/x86/entry/syscall_64.c:61 [inline]
do_syscall_64+0x171/0x540 arch/x86/entry/syscall_64.c:89
entry_SYSCALL_64_after_hwframe+0x77/0x7f
-> #6 (sk_lock-AF_INET6){+.+.}-{0:0}:
lock_sock_nested+0x41/0x100 net/core/sock.c:3909
lock_sock include/net/sock.h:1717 [inline]
inet_shutdown+0x6a/0x390 net/ipv4/af_inet.c:913
nbd_mark_nsock_dead+0x2cb/0x550 drivers/block/nbd.c:319
sock_shutdown+0x15e/0x260 drivers/block/nbd.c:420
nbd_clear_sock+0x24/0x170 drivers/block/nbd.c:1464
nbd_config_put+0x477/0x7e0 drivers/block/nbd.c:1493
nbd_genl_connect+0x19b8/0x1cd0 drivers/block/nbd.c:2320
genl_family_rcv_msg_doit+0x233/0x340 net/netlink/genetlink.c:1114
genl_family_rcv_msg net/netlink/genetlink.c:1194 [inline]
genl_rcv_msg+0x614/0x7a0 net/netlink/genetlink.c:1209
netlink_rcv_skb+0x226/0x4a0 net/netlink/af_netlink.c:2585
genl_rcv+0x28/0x40 net/netlink/genetlink.c:1218
netlink_unicast_kernel net/netlink/af_netlink.c:1336 [inline]
netlink_unicast+0x8ef/0xa80 net/netlink/af_netlink.c:1362
netlink_sendmsg+0x7f0/0xb20 net/netlink/af_netlink.c:1921
sock_sendmsg_nosec+0x14e/0x190 net/socket.c:800
__sock_sendmsg net/socket.c:818 [inline]
____sys_sendmsg+0x49f/0x790 net/socket.c:2713
___sys_sendmsg+0x2f8/0x3d0 net/socket.c:2770
__sys_sendmsg net/socket.c:2802 [inline]
__do_sys_sendmsg net/socket.c:2807 [inline]
__se_sys_sendmsg net/socket.c:2805 [inline]
__x64_sys_sendmsg+0x1b1/0x290 net/socket.c:2805
do_syscall_x64 arch/x86/entry/syscall_64.c:61 [inline]
do_syscall_64+0x171/0x540 arch/x86/entry/syscall_64.c:89
entry_SYSCALL_64_after_hwframe+0x77/0x7f
-> #5 (&nsock->tx_lock){+.+.}-{4:4}:
__mutex_lock_common kernel/locking/mutex.c:646 [inline]
__mutex_lock+0x197/0x15a0 kernel/locking/mutex.c:821
nbd_handle_cmd drivers/block/nbd.c:1143 [inline]
nbd_queue_rq+0x373/0xff0 drivers/block/nbd.c:1207
blk_mq_dispatch_rq_list+0x499/0x1990 block/blk-mq.c:2141
__blk_mq_do_dispatch_sched block/blk-mq-sched.c:168 [inline]
blk_mq_do_dispatch_sched block/blk-mq-sched.c:182 [inline]
__blk_mq_sched_dispatch_requests+0xd36/0x1580 block/blk-mq-sched.c:307
blk_mq_sched_dispatch_requests+0xd7/0x190 block/blk-mq-sched.c:329
blk_mq_run_work_fn+0x167/0x2f0 block/blk-mq.c:2556
process_one_work kernel/workqueue.c:3497 [inline]
process_scheduled_works+0xc5d/0x1650 kernel/workqueue.c:3580
worker_thread+0xa47/0xfb0 kernel/workqueue.c:3661
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
-> #4 (&cmd->lock){+.+.}-{4:4}:
__mutex_lock_common kernel/locking/mutex.c:646 [inline]
__mutex_lock+0x197/0x15a0 kernel/locking/mutex.c:821
nbd_queue_rq+0xc1/0xff0 drivers/block/nbd.c:1199
blk_mq_dispatch_rq_list+0x499/0x1990 block/blk-mq.c:2141
__blk_mq_do_dispatch_sched block/blk-mq-sched.c:168 [inline]
blk_mq_do_dispatch_sched block/blk-mq-sched.c:182 [inline]
__blk_mq_sched_dispatch_requests+0xd36/0x1580 block/blk-mq-sched.c:307
blk_mq_sched_dispatch_requests+0xd7/0x190 block/blk-mq-sched.c:329
blk_mq_run_work_fn+0x167/0x2f0 block/blk-mq.c:2556
process_one_work kernel/workqueue.c:3497 [inline]
process_scheduled_works+0xc5d/0x1650 kernel/workqueue.c:3580
worker_thread+0xa47/0xfb0 kernel/workqueue.c:3661
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
-> #3 (set->srcu){.+.+}-{0:0}:
srcu_lock_sync include/linux/srcu.h:261 [inline]
__synchronize_srcu+0xca/0x2f0 kernel/rcu/srcutree.c:1662
elevator_switch+0x1e8/0x7b0 block/elevator.c:576
elevator_change+0x2fa/0x480 block/elevator.c:681
elevator_set_default+0x375/0x440 block/elevator.c:754
blk_register_queue+0x404/0x4f0 block/blk-sysfs.c:992
__add_disk+0x6b8/0xdb0 block/genhd.c:531
add_disk_fwnode+0x100/0x3a0 block/genhd.c:600
add_disk include/linux/blkdev.h:799 [inline]
nbd_dev_add+0x733/0xb60 drivers/block/nbd.c:2027
nbd_init+0x168/0x1f0 drivers/block/nbd.c:2744
do_one_initcall+0x250/0x870 init/main.c:1432
do_initcall_level+0x10a/0x1a0 init/main.c:1494
do_initcalls+0x59/0xa0 init/main.c:1510
kernel_init_freeable+0x29d/0x3e0 init/main.c:1745
kernel_init+0x22/0x1d0 init/main.c:1635
ret_from_fork+0x514/0xb70 arch/x86/kernel/process.c:158
ret_from_fork_asm+0x1a/0x30 arch/x86/entry/entry_64.S:245
-> #2 (&q->elevator_lock){+.+.}-{4:4}:
__mutex_lock_common kernel/locking/mutex.c:646 [inline]
__mutex_lock+0x197/0x15a0 kernel/locking/mutex.c:821
elevator_change+0x1af/0x480 block/elevator.c:679
elevator_set_none+0xb5/0x140 block/elevator.c:769
blk_mq_elv_switch_none block/blk-mq.c:5171 [inline]
__blk_mq_update_nr_hw_queues block/blk-mq.c:5216 [inline]
blk_mq_update_nr_hw_queues+0x60b/0x1b70 block/blk-mq.c:5284
nbd_start_device+0x189/0xb30 drivers/block/nbd.c:1531
nbd_genl_connect+0x167d/0x1cd0 drivers/block/nbd.c:2311
genl_family_rcv_msg_doit+0x233/0x340 net/netlink/genetlink.c:1114
genl_family_rcv_msg net/netlink/genetlink.c:1194 [inline]
genl_rcv_msg+0x614/0x7a0 net/netlink/genetlink.c:1209
netlink_rcv_skb+0x226/0x4a0 net/netlink/af_netlink.c:2585
genl_rcv+0x28/0x40 net/netlink/genetlink.c:1218
netlink_unicast_kernel net/netlink/af_netlink.c:1336 [inline]
netlink_unicast+0x8ef/0xa80 net/netlink/af_netlink.c:1362
netlink_sendmsg+0x7f0/0xb20 net/netlink/af_netlink.c:1921
sock_sendmsg_nosec+0x14e/0x190 net/socket.c:800
__sock_sendmsg net/socket.c:818 [inline]
____sys_sendmsg+0x49f/0x790 net/socket.c:2713
___sys_sendmsg+0x2f8/0x3d0 net/socket.c:2770
__sys_sendmsg net/socket.c:2802 [inline]
__do_sys_sendmsg net/socket.c:2807 [inline]
__se_sys_sendmsg net/socket.c:2805 [inline]
__x64_sys_sendmsg+0x1b1/0x290 net/socket.c:2805
do_syscall_x64 arch/x86/entry/syscall_64.c:61 [inline]
do_syscall_64+0x171/0x540 arch/x86/entry/syscall_64.c:89
entry_SYSCALL_64_after_hwframe+0x77/0x7f
-> #1 (&q->q_usage_counter(io)#51){++++}-{0:0}:
blk_alloc_queue+0x544/0x690 block/blk-core.c:503
blk_mq_alloc_queue block/blk-mq.c:4471 [inline]
__blk_mq_alloc_disk+0x194/0x390 block/blk-mq.c:4518
nbd_dev_add+0x494/0xb60 drivers/block/nbd.c:1997
nbd_init+0x168/0x1f0 drivers/block/nbd.c:2744
do_one_initcall+0x250/0x870 init/main.c:1432
do_initcall_level+0x10a/0x1a0 init/main.c:1494
do_initcalls+0x59/0xa0 init/main.c:1510
kernel_init_freeable+0x29d/0x3e0 init/main.c:1745
kernel_init+0x22/0x1d0 init/main.c:1635
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 (fs_reclaim){+.+.}-{0:0}:
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
__fs_reclaim_acquire mm/page_alloc.c:4388 [inline]
fs_reclaim_acquire+0x71/0x100 mm/page_alloc.c:4402
might_alloc include/linux/sched/mm.h:316 [inline]
slab_pre_alloc_hook mm/slub.c:4673 [inline]
slab_alloc_node mm/slub.c:5011 [inline]
kmem_cache_alloc_noprof+0x5f/0x600 mm/slub.c:5047
rds_tcp_data_recv+0x174/0xa00 net/rds/tcp_recv.c:174
__tcp_read_sock+0x18d/0x970 net/ipv4/tcp.c:1706
rds_tcp_read_sock net/rds/tcp_recv.c:277 [inline]
rds_tcp_recv_path+0x200/0x340 net/rds/tcp_recv.c:305
rds_tcp_conn_path_shutdown+0x29b/0xac0 net/rds/tcp_connect.c:269
rds_conn_shutdown+0x46d/0xb20 net/rds/connection.c:440
process_one_work kernel/workqueue.c:3497 [inline]
process_scheduled_works+0xc5d/0x1650 kernel/workqueue.c:3580
worker_thread+0xa47/0xfb0 kernel/workqueue.c:3661
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
other info that might help us debug this:
Chain exists of:
fs_reclaim --> sk_lock-AF_INET6 --> k-sk_lock-AF_INET6
Possible unsafe locking scenario:
CPU0 CPU1
---- ----
lock(k-sk_lock-AF_INET6);
lock(sk_lock-AF_INET6);
lock(k-sk_lock-AF_INET6);
lock(fs_reclaim);
*** DEADLOCK ***
locks held by kworker/u8:11/3383: 3, on CPU#0:
#0: ffff888079cbd948 ((wq_completion)krds_cp_wq#11/2){+.+.}-{0:0}, at: rcu_lock_acquire include/linux/rcupdate.h:309 [inline]
#0: ffff888079cbd948 ((wq_completion)krds_cp_wq#11/2){+.+.}-{0:0}, at: rcu_read_lock include/linux/rcupdate.h:849 [inline]
#0: ffff888079cbd948 ((wq_completion)krds_cp_wq#11/2){+.+.}-{0:0}, at: process_one_work kernel/workqueue.c:3462 [inline]
#0: ffff888079cbd948 ((wq_completion)krds_cp_wq#11/2){+.+.}-{0:0}, at: process_scheduled_works+0x99a/0x1650 kernel/workqueue.c:3580
#1: ffffc9000ecf7c40 ((work_completion)(&cp->cp_down_w)){+.+.}-{0:0}, at: rcu_lock_acquire include/linux/rcupdate.h:309 [inline]
#1: ffffc9000ecf7c40 ((work_completion)(&cp->cp_down_w)){+.+.}-{0:0}, at: rcu_read_lock include/linux/rcupdate.h:849 [inline]
#1: ffffc9000ecf7c40 ((work_completion)(&cp->cp_down_w)){+.+.}-{0:0}, at: process_one_work kernel/workqueue.c:3462 [inline]
#1: ffffc9000ecf7c40 ((work_completion)(&cp->cp_down_w)){+.+.}-{0:0}, at: process_scheduled_works+0x99a/0x1650 kernel/workqueue.c:3580
#2: ffff88807d634720 (k-sk_lock-AF_INET6){+.+.}-{0:0}, at: lock_sock include/net/sock.h:1717 [inline]
#2: ffff88807d634720 (k-sk_lock-AF_INET6){+.+.}-{0:0}, at: rds_tcp_recv_path+0xfe/0x340 net/rds/tcp_recv.c:304
stack backtrace:
CPU: 0 UID: 0 PID: 3383 Comm: kworker/u8:11 Not tainted syzkaller #0 PREEMPT(full)
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 11/06/2026
Workqueue: krds_cp_wq#11/2 rds_shutdown_worker
Call Trace:
<TASK>
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
__fs_reclaim_acquire mm/page_alloc.c:4388 [inline]
fs_reclaim_acquire+0x71/0x100 mm/page_alloc.c:4402
might_alloc include/linux/sched/mm.h:316 [inline]
slab_pre_alloc_hook mm/slub.c:4673 [inline]
slab_alloc_node mm/slub.c:5011 [inline]
kmem_cache_alloc_noprof+0x5f/0x600 mm/slub.c:5047
rds_tcp_data_recv+0x174/0xa00 net/rds/tcp_recv.c:174
__tcp_read_sock+0x18d/0x970 net/ipv4/tcp.c:1706
rds_tcp_read_sock net/rds/tcp_recv.c:277 [inline]
rds_tcp_recv_path+0x200/0x340 net/rds/tcp_recv.c:305
rds_tcp_conn_path_shutdown+0x29b/0xac0 net/rds/tcp_connect.c:269
rds_conn_shutdown+0x46d/0xb20 net/rds/connection.c:440
process_one_work kernel/workqueue.c:3497 [inline]
process_scheduled_works+0xc5d/0x1650 kernel/workqueue.c:3580
worker_thread+0xa47/0xfb0 kernel/workqueue.c:3661
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
</TASK>
---
This report is generated by a bot. It may contain errors.
See https://goo.gl/tpsmEJ for more information about syzbot.
syzbot engineers can be reached at syzkaller@googlegroups.com.
syzbot will keep track of this issue. See:
https://goo.gl/tpsmEJ#status for how to communicate with syzbot.
For information about bisection process see: https://goo.gl/tpsmEJ#ai-bisection
If the report is already addressed, let syzbot know by replying with:
#syz fix: exact-commit-title
If you want to overwrite report's subsystems, reply with:
#syz set subsystems: new-subsystem
(See the list of subsystem names on the web dashboard)
If the report is a duplicate of another one, reply with:
#syz dup: exact-subject-of-another-report
If you want to undo deduplication, reply with:
#syz undup
reply other threads:[~2026-11-29 9:13 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=6b0becc6.c4dd33ab.25911d.0027.GAE@google.com \
--to=syzbot+c6bddbec1a368100eb25@syzkaller.appspotmail.com \
--cc=achender@kernel.org \
--cc=axboe@kernel.dk \
--cc=davem@davemloft.net \
--cc=edumazet@google.com \
--cc=edumazet@kernel.org \
--cc=horms@kernel.org \
--cc=josef@toxicpanda.com \
--cc=kartikey406@gmail.com \
--cc=kuba@kernel.org \
--cc=kuniyu@google.com \
--cc=linux-block@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-rdma@vger.kernel.org \
--cc=nbd@other.debian.org \
--cc=ncardwell@google.com \
--cc=netdev@vger.kernel.org \
--cc=pabeni@redhat.com \
--cc=rds-devel@oss.oracle.com \
--cc=syzkaller-bugs@googlegroups.com \
--cc=willemb@google.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox