From mboxrd@z Thu Jan 1 00:00:00 1970 From: "Ananyev, Konstantin" Subject: Re: [PATCH v4 1/4] ethdev: add apis to support access device info Date: Thu, 11 Jun 2015 13:14:22 +0000 Message-ID: <2601191342CEEE43887BDE71AB97725836A08BEC@irsmsx105.ger.corp.intel.com> References: <1432946276-9424-1-git-send-email-liang-min.wang@intel.com> <1433948996-9716-1-git-send-email-liang-min.wang@intel.com> <1433948996-9716-2-git-send-email-liang-min.wang@intel.com> <2601191342CEEE43887BDE71AB97725836A08BA3@irsmsx105.ger.corp.intel.com> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable To: "Wang, Liang-min" , "dev@dpdk.org" Return-path: Received: from mga11.intel.com (mga11.intel.com [192.55.52.93]) by dpdk.org (Postfix) with ESMTP id 2EDC6688E for ; Thu, 11 Jun 2015 15:14:24 +0200 (CEST) In-Reply-To: Content-Language: en-US List-Id: patches and discussions about DPDK List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org Sender: "dev" > > > + > > > +int > > > +rte_eth_dev_set_ringparam(uint8_t port_id, struct rte_dev_ring_info > > > +*info) { > > > + struct rte_eth_dev *dev; > > > + > > > + if (!rte_eth_dev_is_valid_port(port_id)) { > > > + PMD_DEBUG_TRACE("Invalid port_id=3D%d\n", port_id); > > > + return -ENODEV; > > > + } > > > + > > > + if ((dev=3D &rte_eth_devices[port_id]) =3D=3D NULL) { > > > + PMD_DEBUG_TRACE("Invalid port device\n"); > > > + return -ENODEV; > > > + } > > > + > > > + FUNC_PTR_OR_ERR_RET(*dev->dev_ops->set_ringparam, - > > ENOTSUP); > > > + return (*dev->dev_ops->set_ringparam)(dev, info); } > > > > > > I am a bit confused, what particular value of rte_dev_ring_info will be > > allowed to change? > > You can't change number of RXD/TXD at runtime. > > You have to stop the device first, and then reconfigure particular queu= e(s). > > Again, you can't reset RXF/TXD without stopping RX/TX first. > > So what that function is supposed to do? > > As I can see currently, none of the PMD in your patch support it. > > >=20 > Exactly, setting RXD/TXD will require some change on kernel (RX/TX burst)= function. > As you already observe that there is no dev_op registered for set_ring. > The API is created as a placeholder for future implementation. > There are a couple of idea thrown around (such as mono- increase/decrease= to avoid buffer overrun). > Any suggestion is welcome. If you don't plan to implement it in current patch-set, then it is better t= o remove it for now. About suggestions - as I said, I don't think it is doable without stopping = (and reconfiguring) the queue. Again not sure, why do you want to do that run-tme. Konstantin