diff options
| author | Yunsheng Lin <linyunsheng@huawei.com> | 2019-06-13 17:12:30 +0800 |
|---|---|---|
| committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2019-07-26 09:14:07 +0200 |
| commit | 1a3706d8f800f2c2bbd7d8282dc019d780f1ea8b (patch) | |
| tree | c1eca67b995dd27462f41723016f2b43a30aade1 /include/linux/rtnetlink.h | |
| parent | 6a47a42f51cfa5821a82137185db0f1f6442c001 (diff) | |
net: hns3: fix for skb leak when doing selftest
[ Upstream commit 8f9eed1a8791b83eb1c54c261d68424717e4111e ]
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>
Signed-off-by: Sasha Levin <sashal@kernel.org>
Diffstat (limited to 'include/linux/rtnetlink.h')
0 files changed, 0 insertions, 0 deletions
