From patchwork Tue Sep 1 11:52:42 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "humin (Q)" X-Patchwork-Id: 76249 X-Patchwork-Delegate: ferruh.yigit@amd.com Return-Path: X-Original-To: patchwork@inbox.dpdk.org Delivered-To: patchwork@inbox.dpdk.org Received: from dpdk.org (dpdk.org [92.243.14.124]) by inbox.dpdk.org (Postfix) with ESMTP id B7564A04AC; Tue, 1 Sep 2020 14:00:41 +0200 (CEST) Received: from [92.243.14.124] (localhost [127.0.0.1]) by dpdk.org (Postfix) with ESMTP id 572681C195; Tue, 1 Sep 2020 13:55:09 +0200 (CEST) Received: from huawei.com (szxga07-in.huawei.com [45.249.212.35]) by dpdk.org (Postfix) with ESMTP id 7C5681C131 for ; Tue, 1 Sep 2020 13:55:06 +0200 (CEST) Received: from DGGEMS406-HUB.china.huawei.com (unknown [172.30.72.58]) by Forcepoint Email with ESMTP id A053755F34B98644EB5A; Tue, 1 Sep 2020 19:55:04 +0800 (CST) Received: from localhost.localdomain (10.69.192.56) by DGGEMS406-HUB.china.huawei.com (10.3.19.206) with Microsoft SMTP Server id 14.3.487.0; Tue, 1 Sep 2020 19:54:58 +0800 From: "Min Hu (Connor)" To: CC: , , , Date: Tue, 1 Sep 2020 19:52:42 +0800 Message-ID: <1598961165-20832-2-git-send-email-humin29@huawei.com> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1598961165-20832-1-git-send-email-humin29@huawei.com> References: <1598923998-44155-1-git-send-email-humin29@huawei.com> <1598961165-20832-1-git-send-email-humin29@huawei.com> MIME-Version: 1.0 X-Originating-IP: [10.69.192.56] X-CFilter-Loop: Reflected Subject: [dpdk-dev] [PATCH 1/4] ethdev: change data type in TC rxq and TC txq X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org Sender: "dev" From: Huisong Li Currently, base and nb_queue in the tc_rxq and tc_txq information of queue and TC mapping on both TX and RX paths are uint8_t. However, these datas will be truncated when queue number under a TC is greater than 256. So it is necessay for base and nb_queue to change from uint8_t to uint16_t. Fixes: 01eb53eefeb40e8 ("ethdev: rename folder to library name") Cc: stable@dpdk.org Signed-off-by: Huisong Li Signed-off-by: Min Hu (Connor) Reviewed-by: Wei Hu (Xavier) Reviewed-by: Dongdong Liu --- lib/librte_ethdev/rte_ethdev.h | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/lib/librte_ethdev/rte_ethdev.h b/lib/librte_ethdev/rte_ethdev.h index 70295d7..b0114bb 100644 --- a/lib/librte_ethdev/rte_ethdev.h +++ b/lib/librte_ethdev/rte_ethdev.h @@ -1489,13 +1489,13 @@ struct rte_eth_xstat_name { struct rte_eth_dcb_tc_queue_mapping { /** rx queues assigned to tc per Pool */ struct { - uint8_t base; - uint8_t nb_queue; + uint16_t base; + uint16_t nb_queue; } tc_rxq[ETH_MAX_VMDQ_POOL][ETH_DCB_NUM_TCS]; /** rx queues assigned to tc per Pool */ struct { - uint8_t base; - uint8_t nb_queue; + uint16_t base; + uint16_t nb_queue; } tc_txq[ETH_MAX_VMDQ_POOL][ETH_DCB_NUM_TCS]; };