====================================================== WARNING: possible circular locking dependency detected syzkaller #0 Not tainted ------------------------------------------------------ syz.0.1542/9363 is trying to acquire lock: ffff8880213d1458 ((work_completion)(&new_smc->smc_listen_work)){+.+.}-{0:0}, at: rcu_lock_acquire include/linux/rcupdate.h:334 [inline] ffff8880213d1458 ((work_completion)(&new_smc->smc_listen_work)){+.+.}-{0:0}, at: rcu_read_lock include/linux/rcupdate.h:786 [inline] ffff8880213d1458 ((work_completion)(&new_smc->smc_listen_work)){+.+.}-{0:0}, at: start_flush_work kernel/workqueue.c:3371 [inline] ffff8880213d1458 ((work_completion)(&new_smc->smc_listen_work)){+.+.}-{0:0}, at: __flush_work+0xe6/0x9f0 kernel/workqueue.c:3429 but task is already holding lock: ffff8880213d0130 (sk_lock-AF_SMC/1){+.+.}-{0:0}, at: smc_release+0x255/0x530 net/smc/af_smc.c:-1 which lock already depends on the new lock. the existing dependency chain (in reverse order) is: -> #1 (sk_lock-AF_SMC/1){+.+.}-{0:0}: lock_sock_nested+0x48/0x100 net/core/sock.c:3532 smc_listen_out+0x109/0x3d0 net/smc/af_smc.c:1912 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 -> #0 ((work_completion)(&new_smc->smc_listen_work)){+.+.}-{0:0}: check_prev_add kernel/locking/lockdep.c:3134 [inline] check_prevs_add kernel/locking/lockdep.c:3253 [inline] validate_chain kernel/locking/lockdep.c:3869 [inline] __lock_acquire+0x2ddb/0x7c80 kernel/locking/lockdep.c:5137 lock_acquire+0x197/0x410 kernel/locking/lockdep.c:5754 touch_work_lockdep_map kernel/workqueue.c:3145 [inline] start_flush_work kernel/workqueue.c:3397 [inline] __flush_work+0x5ed/0x9f0 kernel/workqueue.c:3429 __cancel_work_timer+0x3b0/0x520 kernel/workqueue.c:3517 smc_clcsock_release+0x60/0xf0 net/smc/smc_close.c:29 __smc_release+0x661/0x7d0 net/smc/af_smc.c:301 smc_close_non_accepted+0xd5/0x1f0 net/smc/af_smc.c:1843 smc_close_cleanup_listen net/smc/smc_close.c:45 [inline] smc_close_active+0xb61/0xf00 net/smc/smc_close.c:225 __smc_release+0x8d/0x7d0 net/smc/af_smc.c:277 smc_release+0x2ce/0x530 net/smc/af_smc.c:344 __sock_release net/socket.c:659 [inline] sock_close+0xbd/0x230 net/socket.c:1421 __fput+0x234/0x970 fs/file_table.c:384 task_work_run+0x1ce/0x250 kernel/task_work.c:239 resume_user_mode_work include/linux/resume_user_mode.h:49 [inline] exit_to_user_mode_loop+0xe6/0x110 kernel/entry/common.c:177 exit_to_user_mode_prepare+0xf6/0x180 kernel/entry/common.c:210 __syscall_exit_to_user_mode_work kernel/entry/common.c:291 [inline] syscall_exit_to_user_mode+0x1a/0x50 kernel/entry/common.c:302 do_syscall_64+0x61/0xb0 arch/x86/entry/common.c:87 entry_SYSCALL_64_after_hwframe+0x68/0xd2 other info that might help us debug this: Possible unsafe locking scenario: CPU0 CPU1 ---- ---- lock(sk_lock-AF_SMC/1); lock((work_completion)(&new_smc->smc_listen_work)); lock(sk_lock-AF_SMC/1); lock((work_completion)(&new_smc->smc_listen_work)); *** DEADLOCK *** 3 locks held by syz.0.1542/9363: #0: ffff88805b95be20 (&sb->s_type->i_mutex_key#11){+.+.}-{3:3}, at: inode_lock include/linux/fs.h:804 [inline] #0: ffff88805b95be20 (&sb->s_type->i_mutex_key#11){+.+.}-{3:3}, at: __sock_release net/socket.c:658 [inline] #0: ffff88805b95be20 (&sb->s_type->i_mutex_key#11){+.+.}-{3:3}, at: sock_close+0x9b/0x230 net/socket.c:1421 #1: ffff8880213d0130 (sk_lock-AF_SMC/1){+.+.}-{0:0}, at: smc_release+0x255/0x530 net/smc/af_smc.c:-1 #2: ffffffff8cd2fee0 (rcu_read_lock){....}-{1:2}, at: rcu_lock_acquire include/linux/rcupdate.h:334 [inline] #2: ffffffff8cd2fee0 (rcu_read_lock){....}-{1:2}, at: rcu_read_lock include/linux/rcupdate.h:786 [inline] #2: ffffffff8cd2fee0 (rcu_read_lock){....}-{1:2}, at: start_flush_work kernel/workqueue.c:3371 [inline] #2: ffffffff8cd2fee0 (rcu_read_lock){....}-{1:2}, at: __flush_work+0xe6/0x9f0 kernel/workqueue.c:3429 stack backtrace: CPU: 1 PID: 9363 Comm: syz.0.1542 Not tainted syzkaller #0 Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 10/02/2025 Call Trace: dump_stack_lvl+0x16c/0x230 lib/dump_stack.c:106 check_noncircular+0x2bd/0x3c0 kernel/locking/lockdep.c:2187 check_prev_add kernel/locking/lockdep.c:3134 [inline] check_prevs_add kernel/locking/lockdep.c:3253 [inline] validate_chain kernel/locking/lockdep.c:3869 [inline] __lock_acquire+0x2ddb/0x7c80 kernel/locking/lockdep.c:5137 lock_acquire+0x197/0x410 kernel/locking/lockdep.c:5754 touch_work_lockdep_map kernel/workqueue.c:3145 [inline] start_flush_work kernel/workqueue.c:3397 [inline] __flush_work+0x5ed/0x9f0 kernel/workqueue.c:3429 __cancel_work_timer+0x3b0/0x520 kernel/workqueue.c:3517 smc_clcsock_release+0x60/0xf0 net/smc/smc_close.c:29 __smc_release+0x661/0x7d0 net/smc/af_smc.c:301 smc_close_non_accepted+0xd5/0x1f0 net/smc/af_smc.c:1843 smc_close_cleanup_listen net/smc/smc_close.c:45 [inline] smc_close_active+0xb61/0xf00 net/smc/smc_close.c:225 __smc_release+0x8d/0x7d0 net/smc/af_smc.c:277 smc_release+0x2ce/0x530 net/smc/af_smc.c:344 __sock_release net/socket.c:659 [inline] sock_close+0xbd/0x230 net/socket.c:1421 __fput+0x234/0x970 fs/file_table.c:384 task_work_run+0x1ce/0x250 kernel/task_work.c:239 resume_user_mode_work include/linux/resume_user_mode.h:49 [inline] exit_to_user_mode_loop+0xe6/0x110 kernel/entry/common.c:177 exit_to_user_mode_prepare+0xf6/0x180 kernel/entry/common.c:210 __syscall_exit_to_user_mode_work kernel/entry/common.c:291 [inline] syscall_exit_to_user_mode+0x1a/0x50 kernel/entry/common.c:302 do_syscall_64+0x61/0xb0 arch/x86/entry/common.c:87 entry_SYSCALL_64_after_hwframe+0x68/0xd2 RIP: 0033:0x7f00a4b8f749 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:00007f00a5943038 EFLAGS: 00000246 ORIG_RAX: 00000000000001b4 RAX: 0000000000000000 RBX: 00007f00a4de5fa0 RCX: 00007f00a4b8f749 RDX: 0000000000000000 RSI: ffffffffffffffff RDI: 0000000000000000 RBP: 00007f00a4c13f91 R08: 0000000000000000 R09: 0000000000000000 R10: 0000000000000000 R11: 0000000000000246 R12: 0000000000000000 R13: 00007f00a4de6038 R14: 00007f00a4de5fa0 R15: 00007ffe0417a9d8