Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 0959a0a1 authored by Vinay Kumar Yadav's avatar Vinay Kumar Yadav Committed by Greg Kroah-Hartman
Browse files

chelsio/chtls: fix panic during unload reload chtls



[ Upstream commit e3d5e971d2f83d8ddd4b91a50cea4517fb488383 ]

there is kernel panic in inet_twsk_free() while chtls
module unload when socket is in TIME_WAIT state because
sk_prot_creator was not preserved on connection socket.

Fixes: cc35c88a ("crypto : chtls - CPL handler definition")
Signed-off-by: default avatarUdai Sharma <udai.sharma@chelsio.com>
Signed-off-by: default avatarVinay Kumar Yadav <vinay.yadav@chelsio.com>
Link: https://lore.kernel.org/r/20201125214913.16938-1-vinay.yadav@chelsio.com


Signed-off-by: default avatarJakub Kicinski <kuba@kernel.org>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent 67633216
Loading
Loading
Loading
Loading
+1 −0
Original line number Diff line number Diff line
@@ -1079,6 +1079,7 @@ static struct sock *chtls_recv_sock(struct sock *lsk,

	oreq->ts_recent = PASS_OPEN_TID_G(ntohl(req->tos_stid));
	sk_setup_caps(newsk, dst);
	newsk->sk_prot_creator = lsk->sk_prot_creator;
	csk->sk = newsk;
	csk->passive_reap_next = oreq;
	csk->tx_chan = cxgb4_port_chan(ndev);