summaryrefslogtreecommitdiffstats
path: root/drivers/net/ethernet/hisilicon/hns3/hns3pf
diff options
context:
space:
mode:
authorYunsheng Lin2019-06-13 11:12:30 +0200
committerDavid S. Miller2019-06-15 04:26:16 +0200
commit8f9eed1a8791b83eb1c54c261d68424717e4111e (patch)
tree86b6eef3cccc8c0eef2ec449bb84d2ebea9cc3e1 /drivers/net/ethernet/hisilicon/hns3/hns3pf
parentnet: hns3: fix for dereferencing before null checking (diff)
downloadkernel-qcow2-linux-8f9eed1a8791b83eb1c54c261d68424717e4111e.tar.gz
kernel-qcow2-linux-8f9eed1a8791b83eb1c54c261d68424717e4111e.tar.xz
kernel-qcow2-linux-8f9eed1a8791b83eb1c54c261d68424717e4111e.zip
net: hns3: fix for skb leak when doing selftest
If hns3_nic_net_xmit does not return NETDEV_TX_BUSY when doing a loopback selftest, the skb is not freed in hns3_clean_tx_ring or hns3_nic_net_xmit, which causes skb not freed problem. This patch fixes it by freeing skb when hns3_nic_net_xmit does not return NETDEV_TX_OK. Fixes: c39c4d98dc65 ("net: hns3: Add mac loopback selftest support in hns3 driver") Signed-off-by: Yunsheng Lin <linyunsheng@huawei.com> Signed-off-by: Peng Li <lipeng321@huawei.com> Signed-off-by: Huazhong Tan <tanhuazhong@huawei.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/ethernet/hisilicon/hns3/hns3pf')
0 files changed, 0 insertions, 0 deletions