diff options
author | Huazhong Tan <tanhuazhong@huawei.com> | 2019-01-18 16:13:05 +0800 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2019-01-18 15:10:21 -0800 |
commit | be5929b89002bb6b06b299f04bc35d90ab9d08fe (patch) | |
tree | adab92cc5c8f1669c417f856033ccd8e58dbe49c /drivers/net | |
parent | a81aca01a1152b8fafcb67f6d3122cf815e87a70 (diff) |
net: hns3: remove unnecessary hns3_adjust_tqps_num
The parameter passed to hns3_set_channels() are already the number of
queues per channel of the enabled TC, so it is not need to divide
the number of enabled TCs.
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>
Diffstat (limited to 'drivers/net')
-rw-r--r-- | drivers/net/ethernet/hisilicon/hns3/hns3_enet.c | 6 |
1 files changed, 0 insertions, 6 deletions
diff --git a/drivers/net/ethernet/hisilicon/hns3/hns3_enet.c b/drivers/net/ethernet/hisilicon/hns3/hns3_enet.c index c6f2d72a5e6f..c88714c667ba 100644 --- a/drivers/net/ethernet/hisilicon/hns3/hns3_enet.c +++ b/drivers/net/ethernet/hisilicon/hns3/hns3_enet.c @@ -4183,11 +4183,6 @@ err_alloc_vector: return ret; } -static int hns3_adjust_tqps_num(u8 num_tc, u32 new_tqp_num) -{ - return (new_tqp_num / num_tc) * num_tc; -} - int hns3_set_channels(struct net_device *netdev, struct ethtool_channels *ch) { @@ -4211,7 +4206,6 @@ int hns3_set_channels(struct net_device *netdev, return -EINVAL; } - new_tqp_num = hns3_adjust_tqps_num(kinfo->num_tc, new_tqp_num); if (kinfo->num_tqps == new_tqp_num) return 0; |