From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mga02.intel.com (mga02.intel.com [134.134.136.20]) by dpdk.org (Postfix) with ESMTP id 64DE2C40C for ; Fri, 24 Jul 2015 11:15:26 +0200 (CEST) Received: from fmsmga001.fm.intel.com ([10.253.24.23]) by orsmga101.jf.intel.com with ESMTP; 24 Jul 2015 02:15:25 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.15,537,1432623600"; d="scan'208";a="753718744" Received: from irsmsx154.ger.corp.intel.com ([163.33.192.96]) by fmsmga001.fm.intel.com with ESMTP; 24 Jul 2015 02:15:24 -0700 Received: from irsmsx105.ger.corp.intel.com ([169.254.7.223]) by IRSMSX154.ger.corp.intel.com ([169.254.12.253]) with mapi id 14.03.0224.002; Fri, 24 Jul 2015 10:15:23 +0100 From: "Ananyev, Konstantin" To: Thomas Monjalon Thread-Topic: [dpdk-dev] [PATCHv4 1/5] ethdev: add new API to retrieve RX/TX queue information Thread-Index: AQHQxK9QOtJCAJwhl0KZym7kHYZQWJ3pLn8AgAEn77A= Date: Fri, 24 Jul 2015 09:15:22 +0000 Message-ID: <2601191342CEEE43887BDE71AB97725836A671DF@irsmsx105.ger.corp.intel.com> References: <1437589735-30041-1-git-send-email-konstantin.ananyev@intel.com> <1437589735-30041-2-git-send-email-konstantin.ananyev@intel.com> <1781257.Eo9CaUGVAh@xps13> In-Reply-To: <1781257.Eo9CaUGVAh@xps13> Accept-Language: en-IE, en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-originating-ip: [163.33.239.182] Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 Cc: "dev@dpdk.org" Subject: Re: [dpdk-dev] [PATCHv4 1/5] ethdev: add new API to retrieve RX/TX queue information X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: patches and discussions about DPDK List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 24 Jul 2015 09:15:26 -0000 > -----Original Message----- > From: Thomas Monjalon [mailto:thomas.monjalon@6wind.com] > Sent: Thursday, July 23, 2015 5:26 PM > To: Ananyev, Konstantin > Cc: dev@dpdk.org > Subject: Re: [dpdk-dev] [PATCHv4 1/5] ethdev: add new API to retrieve RX/= TX queue information >=20 > 2015-07-22 19:28, Konstantin Ananyev: > > + if (!rte_eth_dev_is_valid_port(port_id)) { > > + PMD_DEBUG_TRACE("Invalid port_id=3D%d\n", port_id); > > + return -EINVAL; > > + } >=20 > Please use VALID_PORTID_OR_ERR_RET. >=20 > > + * Ethernet device RX queue information strcuture. >=20 > Typo here (and same for TX). >=20 > > +struct rte_eth_rxq_info { > > + struct rte_mempool *mp; /**< mempool used by that queue. */ > > + struct rte_eth_rxconf conf; /**< queue config parameters. */ > > + uint8_t scattered_rx; /**< scattered packets RX supported. */ > > + uint16_t nb_desc; /**< configured number of RXDs. */ >=20 > Shouldn't we move nb_desc in rte_eth_rxconf? > So rte_eth_rx_queue_setup() would have less parameters. I thought about that too, but it seems more drawbacks then pluses with that= idea: 1. Right now it is possible to call rte_eth_rx_queue_setup(..., rx_conf=3DN= ULL, ...); In that case rte_eth_rx_queue_setup()will use default for that device rx_co= nf. If we'll move mempool into rxconf, will break that ability. 2. A bit unclear what mempool should be returned as default_rxconf by rte_= eth_dev_info_get(). Should it be just NULL. 3. ABI breakage and we (and all customers) will need to modify each and ev= ery RX setup/configure code. For me it just seems like too much hassle, without any clear advanatage. >=20 > > -#ifdef __cplusplus > > -} > > -#endif > > - > > /** > > * Set the list of multicast addresses to filter on an Ethernet device= . > > * > > @@ -3882,4 +3952,9 @@ extern int rte_eth_timesync_read_rx_timestamp(uin= t8_t port_id, > > */ > > extern int rte_eth_timesync_read_tx_timestamp(uint8_t port_id, > > struct timespec *timestamp); > > + > > +#ifdef __cplusplus > > +} > > +#endif > > + > > #endif /* _RTE_ETHDEV_H_ */ >=20 > Please send this change in a separate patch alone. Ok, will do. Konstantin