====================================================== WARNING: possible circular locking dependency detected 6.10.0-rc2-syzkaller-00003-g8867bbd4a056 #0 Tainted: G W ------------------------------------------------------ syz-executor.0/7544 is trying to acquire lock: ffff0000d4941ef8 ((work_completion)(&new_smc->smc_listen_work)){+.+.}-{0:0}, at: touch_work_lockdep_map+0x74/0x11c kernel/workqueue.c:3894 but task is already holding lock: ffff0000c4b38d58 (sk_lock-AF_SMC/1){+.+.}-{0:0}, at: smc_release+0x1e8/0x528 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+0x5c/0x11c net/core/sock.c:3534 smc_listen_out+0x10c/0x3bc net/smc/af_smc.c:1922 smc_listen_work+0x1e4/0x1074 process_one_work+0x7b0/0x15e8 kernel/workqueue.c:3231 process_scheduled_works kernel/workqueue.c:3312 [inline] worker_thread+0x938/0xef4 kernel/workqueue.c:3393 kthread+0x288/0x310 kernel/kthread.c:389 ret_from_fork+0x10/0x20 arch/arm64/kernel/entry.S:860 -> #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+0x3384/0x763c kernel/locking/lockdep.c:5137 lock_acquire+0x248/0x73c kernel/locking/lockdep.c:5754 touch_work_lockdep_map+0x9c/0x11c kernel/workqueue.c:3894 start_flush_work kernel/workqueue.c:4148 [inline] __flush_work+0x578/0x954 kernel/workqueue.c:4181 __cancel_work_sync kernel/workqueue.c:4331 [inline] cancel_work_sync+0xc4/0x120 kernel/workqueue.c:4368 smc_clcsock_release+0x64/0xec net/smc/smc_close.c:29 __smc_release+0x55c/0x700 net/smc/af_smc.c:300 smc_close_non_accepted+0xd8/0x260 net/smc/af_smc.c:1854 smc_close_cleanup_listen net/smc/smc_close.c:45 [inline] smc_close_active+0x9bc/0xd20 net/smc/smc_close.c:225 __smc_release+0xa0/0x700 net/smc/af_smc.c:276 smc_release+0x260/0x528 net/smc/af_smc.c:343 __sock_release net/socket.c:659 [inline] sock_close+0xa4/0x1e8 net/socket.c:1421 __fput+0x334/0x760 fs/file_table.c:422 __fput_sync+0x60/0x9c fs/file_table.c:507 __do_sys_close fs/open.c:1555 [inline] __se_sys_close fs/open.c:1540 [inline] __arm64_sys_close+0x150/0x1e0 fs/open.c:1540 __invoke_syscall arch/arm64/kernel/syscall.c:34 [inline] invoke_syscall+0x98/0x2b8 arch/arm64/kernel/syscall.c:48 el0_svc_common+0x130/0x23c arch/arm64/kernel/syscall.c:133 do_el0_svc+0x48/0x58 arch/arm64/kernel/syscall.c:152 el0_svc+0x54/0x168 arch/arm64/kernel/entry-common.c:712 el0t_64_sync_handler+0x84/0xfc arch/arm64/kernel/entry-common.c:730 el0t_64_sync+0x190/0x194 arch/arm64/kernel/entry.S:598 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-executor.0/7544: #0: ffff0000ddc8a010 (&sb->s_type->i_mutex_key#10){+.+.}-{3:3}, at: inode_lock include/linux/fs.h:791 [inline] #0: ffff0000ddc8a010 (&sb->s_type->i_mutex_key#10){+.+.}-{3:3}, at: __sock_release net/socket.c:658 [inline] #0: ffff0000ddc8a010 (&sb->s_type->i_mutex_key#10){+.+.}-{3:3}, at: sock_close+0x80/0x1e8 net/socket.c:1421 #1: ffff0000c4b38d58 (sk_lock-AF_SMC/1){+.+.}-{0:0}, at: smc_release+0x1e8/0x528 #2: ffff80008f1c76a0 (rcu_read_lock){....}-{1:2}, at: rcu_lock_acquire+0x10/0x4c include/linux/rcupdate.h:328 stack backtrace: CPU: 0 PID: 7544 Comm: syz-executor.0 Tainted: G W 6.10.0-rc2-syzkaller-00003-g8867bbd4a056 #0 Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 04/02/2024 Call trace: dump_backtrace+0x1b8/0x1e4 arch/arm64/kernel/stacktrace.c:317 show_stack+0x2c/0x3c arch/arm64/kernel/stacktrace.c:324 __dump_stack lib/dump_stack.c:88 [inline] dump_stack_lvl+0xe4/0x150 lib/dump_stack.c:114 dump_stack+0x1c/0x28 lib/dump_stack.c:123 print_circular_bug+0x150/0x1b8 kernel/locking/lockdep.c:2060 check_noncircular+0x310/0x404 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+0x3384/0x763c kernel/locking/lockdep.c:5137 lock_acquire+0x248/0x73c kernel/locking/lockdep.c:5754 touch_work_lockdep_map+0x9c/0x11c kernel/workqueue.c:3894 start_flush_work kernel/workqueue.c:4148 [inline] __flush_work+0x578/0x954 kernel/workqueue.c:4181 __cancel_work_sync kernel/workqueue.c:4331 [inline] cancel_work_sync+0xc4/0x120 kernel/workqueue.c:4368 smc_clcsock_release+0x64/0xec net/smc/smc_close.c:29 __smc_release+0x55c/0x700 net/smc/af_smc.c:300 smc_close_non_accepted+0xd8/0x260 net/smc/af_smc.c:1854 smc_close_cleanup_listen net/smc/smc_close.c:45 [inline] smc_close_active+0x9bc/0xd20 net/smc/smc_close.c:225 __smc_release+0xa0/0x700 net/smc/af_smc.c:276 smc_release+0x260/0x528 net/smc/af_smc.c:343 __sock_release net/socket.c:659 [inline] sock_close+0xa4/0x1e8 net/socket.c:1421 __fput+0x334/0x760 fs/file_table.c:422 __fput_sync+0x60/0x9c fs/file_table.c:507 __do_sys_close fs/open.c:1555 [inline] __se_sys_close fs/open.c:1540 [inline] __arm64_sys_close+0x150/0x1e0 fs/open.c:1540 __invoke_syscall arch/arm64/kernel/syscall.c:34 [inline] invoke_syscall+0x98/0x2b8 arch/arm64/kernel/syscall.c:48 el0_svc_common+0x130/0x23c arch/arm64/kernel/syscall.c:133 do_el0_svc+0x48/0x58 arch/arm64/kernel/syscall.c:152 el0_svc+0x54/0x168 arch/arm64/kernel/entry-common.c:712 el0t_64_sync_handler+0x84/0xfc arch/arm64/kernel/entry-common.c:730 el0t_64_sync+0x190/0x194 arch/arm64/kernel/entry.S:598