From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from out2-smtp.messagingengine.com (out2-smtp.messagingengine.com [66.111.4.26]) by dpdk.org (Postfix) with ESMTP id A07AA2C8 for ; Sat, 8 Jul 2017 18:45:38 +0200 (CEST) Received: from compute1.internal (compute1.nyi.internal [10.202.2.41]) by mailout.nyi.internal (Postfix) with ESMTP id 38CBD20940; Sat, 8 Jul 2017 12:45:38 -0400 (EDT) Received: from frontend1 ([10.202.2.160]) by compute1.internal (MEProxy); Sat, 08 Jul 2017 12:45:38 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=monjalon.net; h= cc:content-transfer-encoding:content-type:date:from:in-reply-to :message-id:mime-version:references:subject:to:x-me-sender :x-me-sender:x-sasl-enc:x-sasl-enc; s=mesmtp; bh=ZW8oC5/Docw3CL1 M/NPFcDyL6u7W/QHQw0C4libjOYU=; b=Gq2GfQFIHa3IMB1whPtMs7Se/n8ILkf EjiFQ02S1CMt0HkAiL8D8c29Kcq1vtxSUhesg7Uja3gZQOZK8udUg/YIBu5seScQ poDpZfsndekT+pp43eUYrlXS06fAkqGupHkZwETMv70qdFYBd5bPF0FPiWbg7rys 8YPf+YcQtySg= DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=cc:content-transfer-encoding:content-type :date:from:in-reply-to:message-id:mime-version:references :subject:to:x-me-sender:x-me-sender:x-sasl-enc:x-sasl-enc; s= fm1; bh=ZW8oC5/Docw3CL1M/NPFcDyL6u7W/QHQw0C4libjOYU=; b=nhMqF1Y7 B6ipjUwpmknKQ9upu2gQ3f1G/VvMoXy+pyP1o44e0+0G8tgUU96sG/bTtESeLsjf Wb5mUvl0jN7mvyFPOq/xMDF+7trkRtPGBdjrri1XJ+dfG95GzlU3PrbtX/Yp0y69 Ce67I1gnUhPYJWkj810I3WS4O/Qc/f2JxV7LShaNlm3NEMXBgbtDYL9HboqRgLkl 6tDiSspBdJRkdswJ4VvjSt85olbT+hPKNhwqvMWIkBgUM9tdWbPfdS6qUA3e94ly tM+HrOOL/ymGSNdiyvfToU7aDZd1sez/PdACVPufoB/XsVllKNJHCHzBnuilujsO 441BLLdWGWwK0A== X-ME-Sender: X-Sasl-enc: GiVT/pj/Fnuif6yy+eCJKs1gghHwL0bUZkwrN2hep1D6 1499532337 Received: from xps.localnet (184.203.134.77.rev.sfr.net [77.134.203.184]) by mail.messagingengine.com (Postfix) with ESMTPA id DA5A17E46B; Sat, 8 Jul 2017 12:45:37 -0400 (EDT) From: Thomas Monjalon To: Andrew Rybchenko , Roman Zhukov Cc: dev@dpdk.org, Stephen Hemminger , Sergio Gonzalez Monroy , Remy Horton , Jianfeng Tan , Declan Doherty , Ferruh Yigit , Yuanhan Liu , Maxime Coquelin , Konstantin Ananyev , Bruce Richardson , Reshma Pattan , Cristian Dumitrescu , Byron Marohn , Pablo de Lara Guarch , Pawel Wodkowski , Tomasz Kantecki , John McNamara , Daniel Mrzyglod Date: Sat, 08 Jul 2017 18:45:36 +0200 Message-ID: <2087233.oFzTOzXl1I@xps> In-Reply-To: <9753207.xkvjPXifed@xps> References: <1488459935-13273-2-git-send-email-arybchenko@solarflare.com> <9753207.xkvjPXifed@xps> MIME-Version: 1.0 Content-Transfer-Encoding: 7Bit Content-Type: text/plain; charset="us-ascii" Subject: Re: [dpdk-dev] [PATCH 1/2] ethdev: add function to adjust number of descriptors 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: , X-List-Received-Date: Sat, 08 Jul 2017 16:45:39 -0000 06/07/2017 01:00, Thomas Monjalon: > 14/06/2017 12:37, Andrew Rybchenko: > > On 05/25/2017 08:40 PM, Stephen Hemminger wrote: > > > On Thu, 25 May 2017 16:57:53 +0100 > > > Andrew Rybchenko wrote: > > > > > >> From: Roman Zhukov > > >> > > >> Check that numbers of Rx and Tx descriptors satisfy descriptors limits > > >> from the Ethernet device information, otherwise adjust them to boundaries. > > >> > > >> Signed-off-by: Roman Zhukov > > >> Signed-off-by: Andrew Rybchenko > > > Seems like new added complexity. > > > > It looks like there is no more comments. > > > > > Why not just allow devices to take the request as a hint and truncate or pad > > > as needed. > > > > Yes, it is possible solution. In this case rte_eth_rx_queue_info_get() > > may be used > > to get real values. If so, first of all it should be clearly documented > > in the > > rte_eth_rx_queue_setup()/rte_eth_tx_queue_setup() and > > rte_eth_rx_queue_info_get()/rte_eth_tx_queue_info_get(). > > However, the problem of such approach is non-obvious modification of > > values specified by the ethdev API caller. Some applications use ring sizes > > to estimate mbuf pool size and other resources and if real values differ > > from specified (and it is not taken into account since everything happens > > silently without any errors) it could be tricky to find out root cause of > > possible problems. That's why we have chosen approach with extra > > helper function which does the adjustment. > > Any more comment on this? > If not, it will be applied soon. > > > > IMHO to be successful DPDK must have as simple as possible API for application. > > > Good enough and as little more as possible. But other people seem to think > > > that having the richest and most complex possible API is a good thing. > > I agree it is better to have a simple API. > However the community process is in favor of code writers. > We cannot reject a solution if there is no other solution proposed in > a reasonnable timeframe. Applied, because we have no better alternative for now, and it is discussed since March.