commit | b6b4f987c5c4fe488f3f68460b9addc08482b164 | [log] [tgz] |
---|---|---|
author | Huazhong Tan <tanhuazhong@huawei.com> | Sat Feb 02 22:39:32 2019 +0800 |
committer | David S. Miller <davem@davemloft.net> | Sat Feb 02 08:24:08 2019 -0800 |
tree | e25bc772cd02a91c5f97695de5d4113f3ed2427f | |
parent | 3a586422a5533a6c78376a779860f48ed72b9d83 [diff] |
net: hns3: fix a wrong checking in the hclge_tx_buffer_calc() Only the TC is enabled, we need to check whether the buffer is enough, otherwise it may lead to a wrong -ENOMEM case. Fixes: 9ffe79a9c2ee ("net: hns3: Support for dynamically assigning tx buffer to TC") Signed-off-by: Huazhong Tan <tanhuazhong@huawei.com> Signed-off-by: Peng Li <lipeng321@huawei.com> Signed-off-by: David S. Miller <davem@davemloft.net>