diff options
author | Navid Emamdoost <navid.emamdoost@gmail.com> | 2020-07-22 21:58:39 -0500 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2020-07-22 20:04:17 -0700 |
commit | e6827d1abdc9b061a57d7b7d3019c4e99fabea2f (patch) | |
tree | 4ad9d9fb45e7b73c3b6c1108223848b6951552b7 /drivers/net | |
parent | 901f3cc1639e5103a8997f6ab243785d292e2074 (diff) | |
download | linux-e6827d1abdc9b061a57d7b7d3019c4e99fabea2f.tar.gz linux-e6827d1abdc9b061a57d7b7d3019c4e99fabea2f.tar.bz2 linux-e6827d1abdc9b061a57d7b7d3019c4e99fabea2f.zip |
cxgb4: add missing release on skb in uld_send()
In the implementation of uld_send(), the skb is consumed on all
execution paths except one. Release skb when returning NET_XMIT_DROP.
Signed-off-by: Navid Emamdoost <navid.emamdoost@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net')
-rw-r--r-- | drivers/net/ethernet/chelsio/cxgb4/sge.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/drivers/net/ethernet/chelsio/cxgb4/sge.c b/drivers/net/ethernet/chelsio/cxgb4/sge.c index 32a45dc51ed7..92eee66cbc84 100644 --- a/drivers/net/ethernet/chelsio/cxgb4/sge.c +++ b/drivers/net/ethernet/chelsio/cxgb4/sge.c @@ -2938,6 +2938,7 @@ static inline int uld_send(struct adapter *adap, struct sk_buff *skb, txq_info = adap->sge.uld_txq_info[tx_uld_type]; if (unlikely(!txq_info)) { WARN_ON(true); + kfree_skb(skb); return NET_XMIT_DROP; } |