From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from dpdk.org (dpdk.org [92.243.14.124]) by inbox.dpdk.org (Postfix) with ESMTP id 87A8DA0350; Wed, 24 Jun 2020 05:48:25 +0200 (CEST) Received: from [92.243.14.124] (localhost [127.0.0.1]) by dpdk.org (Postfix) with ESMTP id 28A041D6F1; Wed, 24 Jun 2020 05:48:24 +0200 (CEST) Received: from huawei.com (szxga04-in.huawei.com [45.249.212.190]) by dpdk.org (Postfix) with ESMTP id 1EBBF1D632 for ; Wed, 24 Jun 2020 05:48:21 +0200 (CEST) Received: from DGGEMS405-HUB.china.huawei.com (unknown [172.30.72.58]) by Forcepoint Email with ESMTP id 16A73E5CDA0A78FCEDC4; Wed, 24 Jun 2020 11:48:19 +0800 (CST) Received: from [127.0.0.1] (10.65.81.238) by DGGEMS405-HUB.china.huawei.com (10.3.19.205) with Microsoft SMTP Server id 14.3.487.0; Wed, 24 Jun 2020 11:48:10 +0800 To: Andrew Rybchenko , References: <1592894934-57856-1-git-send-email-tangchengchang@huawei.com> <566d8162-7550-6812-bf62-e0fb55e8e500@solarflare.com> CC: , , From: Chengchang Tang Message-ID: Date: Wed, 24 Jun 2020 11:48:10 +0800 User-Agent: Mozilla/5.0 (Windows NT 6.1; WOW64; rv:45.0) Gecko/20100101 Thunderbird/45.7.1 MIME-Version: 1.0 In-Reply-To: <566d8162-7550-6812-bf62-e0fb55e8e500@solarflare.com> Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: 7bit X-Originating-IP: [10.65.81.238] X-CFilter-Loop: Reflected Subject: Re: [dpdk-dev] [RFC] ethdev: add a field for rte_eth_rxq_info 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" On 2020/6/23 17:30, Andrew Rybchenko wrote: > On 6/23/20 9:48 AM, Chengchang Tang wrote: >> In common practice, PMD configure the rx_buf_size according to the data >> room size of the object in mempool. But in fact the final value is related >> to the specifications of hw, and its values will affect the number of >> fragments in recieving pkts. >> >> At present, we seem to have no way to espose relevant information to upper >> layer users. >> >> Add a field named rx_bufsize in rte_eth_rxq_info to indicate the buffer >> size used in recieving pkts for hw. >> > > I'm OK with the change in general. > I'm unsure which name to use: 'rx_buf_size' or 'rx_bursize', > since I found both 'min_rx_buf_size' and 'min_rx_bufsize' in > ethdev. > > I think it is important to update PMDs which provides the > information to fill the field in. My plan is to divide the subsequent series into two patches, one to modify rte_eth_rxq_info, and one to add our hns3 PMD implementation of rxq_info_get. Should i update all the PMDs that provide this information and test programs such as testpmd at the same time? > >> Signed-off-by: Chengchang Tang > > Acked-by: Andrew Rybchenko > >> --- >> lib/librte_ethdev/rte_ethdev.h | 1 + >> 1 file changed, 1 insertion(+) >> >> diff --git a/lib/librte_ethdev/rte_ethdev.h b/lib/librte_ethdev/rte_ethdev.h >> index 0f6d053..82b7e98 100644 >> --- a/lib/librte_ethdev/rte_ethdev.h >> +++ b/lib/librte_ethdev/rte_ethdev.h >> @@ -1306,6 +1306,7 @@ struct rte_eth_rxq_info { >> struct rte_eth_rxconf conf; /**< queue config parameters. */ >> uint8_t scattered_rx; /**< scattered packets RX supported. */ >> uint16_t nb_desc; /**< configured number of RXDs. */ >> + uint16_t rx_bufsize; /**< size of RX buffer. */ >> } __rte_cache_min_aligned; >> >> /** >> -- >> 2.7.4 >> > > > . >