ch_ktls: fix device connection close
authorVinay Kumar Yadav <vinay.yadav@chelsio.com>
Thu, 15 Apr 2021 07:47:46 +0000 (13:17 +0530)
committerDavid S. Miller <davem@davemloft.net>
Thu, 15 Apr 2021 23:55:49 +0000 (16:55 -0700)
commitbc16efd2430652f894ae34b1de5eccc3bf0d2810
tree8934371d618bc64d5f065a2726e5471cd17c41fd
parent1a73e427b824133940c2dd95ebe26b6dce1cbf10
ch_ktls: fix device connection close

When sge queue is full and chcr_ktls_xmit_wr_complete()
returns failure, skb is not freed if it is not the last tls record in
this skb, causes refcount never gets freed and tls_dev_del()
never gets called on this connection.

Fixes: 5a4b9fe7fece ("cxgb4/chcr: complete record tx handling")
Signed-off-by: Vinay Kumar Yadav <vinay.yadav@chelsio.com>
Signed-off-by: Rohit Maheshwari <rohitm@chelsio.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ethernet/chelsio/inline_crypto/ch_ktls/chcr_ktls.c