]> git.ipfire.org Git - thirdparty/kernel/stable.git/commit
chelsio/chtls: fix always leaking ctrl_skb
authorVinay Kumar Yadav <vinay.yadav@chelsio.com>
Mon, 2 Nov 2020 17:39:10 +0000 (23:09 +0530)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Tue, 10 Nov 2020 11:38:56 +0000 (12:38 +0100)
commitb18ec4a9634d510bf70df3393ec27e1b52ca5329
tree53339ca4aa240fb92da6e6f51b39fd01fbb35b35
parentd38c4b58aaa78f475d88ece4199472c9008ebc1c
chelsio/chtls: fix always leaking ctrl_skb

[ Upstream commit dbfe394dad33f99cf8458be50483ec40a5d29c34 ]

Correct skb refcount in alloc_ctrl_skb(), causing skb memleak
when chtls_send_abort() called with NULL skb.
it was always leaking the skb, correct it by incrementing skb
refs by one.

Fixes: cc35c88ae4db ("crypto : chtls - CPL handler definition")
Signed-off-by: Vinay Kumar Yadav <vinay.yadav@chelsio.com>
Link: https://lore.kernel.org/r/20201102173909.24826-1-vinay.yadav@chelsio.com
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/crypto/chelsio/chtls/chtls_cm.c