Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S938519AbdLSDdE (ORCPT ); Mon, 18 Dec 2017 22:33:04 -0500 Received: from szxga04-in.huawei.com ([45.249.212.190]:2696 "EHLO huawei.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S965587AbdLSDcz (ORCPT ); Mon, 18 Dec 2017 22:32:55 -0500 From: Lipeng To: CC: , , , , Subject: [PATCH V2 net-next 03/17] net: hns3: change the returned tqp number by ethtool -x Date: Tue, 19 Dec 2017 12:02:25 +0800 Message-ID: <1513656159-127589-4-git-send-email-lipeng321@huawei.com> X-Mailer: git-send-email 1.9.1 In-Reply-To: <1513656159-127589-1-git-send-email-lipeng321@huawei.com> References: <1513656159-127589-1-git-send-email-lipeng321@huawei.com> MIME-Version: 1.0 Content-Type: text/plain X-Originating-IP: [10.71.200.31] X-CFilter-Loop: Reflected Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 980 Lines: 26 This patch modifies the return data of get_rxnfc, it will return the current handle's rss_size but not the total tqp number. because the tc_size has been change to the log2 of roundup power of two of rss_size. Signed-off-by: qumingguang Signed-off-by: Lipeng --- drivers/net/ethernet/hisilicon/hns3/hns3_ethtool.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/net/ethernet/hisilicon/hns3/hns3_ethtool.c b/drivers/net/ethernet/hisilicon/hns3/hns3_ethtool.c index 1b2d79b..2fd2656 100644 --- a/drivers/net/ethernet/hisilicon/hns3/hns3_ethtool.c +++ b/drivers/net/ethernet/hisilicon/hns3/hns3_ethtool.c @@ -730,7 +730,7 @@ static int hns3_get_rxnfc(struct net_device *netdev, switch (cmd->cmd) { case ETHTOOL_GRXRINGS: - cmd->data = h->kinfo.num_tc * h->kinfo.rss_size; + cmd->data = h->kinfo.rss_size; break; case ETHTOOL_GRXFH: return h->ae_algo->ops->get_rss_tuple(h, cmd); -- 1.9.1