net: hns3: fix wrong combined count returned by ethtool -l
authorHuazhong Tan <tanhuazhong@huawei.com>
Fri, 18 Jan 2019 08:13:12 +0000 (16:13 +0800)
committerDavid S. Miller <davem@davemloft.net>
Fri, 18 Jan 2019 23:10:22 +0000 (15:10 -0800)
commitc3b9c50d1567aa12be4448fe85b09626eba2499c
tree18f6c57e028836df2958a26c47f056c28b3a0ffe
parent205a24ca2df10621a19081ad349920870759c0a6
net: hns3: fix wrong combined count returned by ethtool -l

The current code returns the number of all queues that can be used and
the number of queues that have been allocated, which is incorrect.
What should be returned is the number of queues allocated for each enabled
TC and the number of queues that can be allocated.

This patch fixes it.

Fixes: 482d2e9c1cc7 ("net: hns3: add support to query tqps number")
Signed-off-by: Huazhong Tan <tanhuazhong@huawei.com>
Signed-off-by: Yunsheng Lin <linyunsheng@huawei.com>
Signed-off-by: Peng Li <lipeng321@huawei.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ethernet/hisilicon/hns3/hns3pf/hclge_main.c