Skip to content

Commit 6e3163c

Browse files
vinaychelsiogregkh
authored andcommitted
chelsio/chtls: fix deadlock issue
[ Upstream commit 28e9dcd ] In chtls_pass_establish() we hold child socket lock using bh_lock_sock and we are again trying bh_lock_sock in add_to_reap_list, causing deadlock. Remove bh_lock_sock in add_to_reap_list() as lock is already held. Fixes: cc35c88 ("crypto : chtls - CPL handler definition") Signed-off-by: Vinay Kumar Yadav <vinay.yadav@chelsio.com> Link: https://lore.kernel.org/r/20201025193538.31112-1-vinay.yadav@chelsio.com Signed-off-by: Jakub Kicinski <kuba@kernel.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
1 parent c4fd583 commit 6e3163c

1 file changed

Lines changed: 0 additions & 2 deletions

File tree

drivers/crypto/chelsio/chtls/chtls_cm.c

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1514,7 +1514,6 @@ static void add_to_reap_list(struct sock *sk)
15141514
struct chtls_sock *csk = sk->sk_user_data;
15151515

15161516
local_bh_disable();
1517-
bh_lock_sock(sk);
15181517
release_tcp_port(sk); /* release the port immediately */
15191518

15201519
spin_lock(&reap_list_lock);
@@ -1523,7 +1522,6 @@ static void add_to_reap_list(struct sock *sk)
15231522
if (!csk->passive_reap_next)
15241523
schedule_work(&reap_task);
15251524
spin_unlock(&reap_list_lock);
1526-
bh_unlock_sock(sk);
15271525
local_bh_enable();
15281526
}
15291527

0 commit comments

Comments
 (0)