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 8F5E2A0562; Thu, 2 Apr 2020 19:33:50 +0200 (CEST) Received: from [92.243.14.124] (localhost [127.0.0.1]) by dpdk.org (Postfix) with ESMTP id E8F931BE0C; Thu, 2 Apr 2020 19:33:48 +0200 (CEST) Received: from out2-smtp.messagingengine.com (out2-smtp.messagingengine.com [66.111.4.26]) by dpdk.org (Postfix) with ESMTP id A488F1BDAC for ; Thu, 2 Apr 2020 19:33:47 +0200 (CEST) Received: from compute7.internal (compute7.nyi.internal [10.202.2.47]) by mailout.nyi.internal (Postfix) with ESMTP id 4AA725C0145; Thu, 2 Apr 2020 13:33:46 -0400 (EDT) Received: from mailfrontend2 ([10.202.2.163]) by compute7.internal (MEProxy); Thu, 02 Apr 2020 13:33:46 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=monjalon.net; h= from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding:content-type; s=mesmtp; bh=q3IzIDpQhDNBkvLMyHigkqIo31SnYMXdRWq75zig8Kk=; b=mOEOm0iYXZAp iHJentF35/xIBdJQ/MvjP7m1gbXbcJ7jpMtO9ITBzhpKzEiVUAqfNcq/A6s/j1e7 fcMsuNWfowRCyKyCy+568IwAXENCylSVIf3ZIHXd45ST5USjWNXgR8+HLNvFNqZW JY/leaH8ehBasm8deShkeRJMua/1+7E= 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-proxy:x-me-proxy:x-me-sender:x-me-sender :x-sasl-enc; s=fm2; bh=q3IzIDpQhDNBkvLMyHigkqIo31SnYMXdRWq75zig8 Kk=; b=Ei6A0eYoHNKyWxZx5BMZTZjQsjT4cni7tmdiV0zwKykdeNT3H7k7zRcY1 NWPNfy0cenCKBjZlCJaUm8kcwpmgVTT/RbDDbm5QPFDJwvrr5v39kPJ9HVzjToGK vkB/kSnhlrpqx+x9pn3Q0Pva7IFSUk3suAj0QWRjn/xl4+0nPN5HhlfZm0z4dhi6 SPJSMZK30hB1v0i6CzeTuvJXHyq/Q179KZuoOCWVF232tOQdTxxMzNs28Hf5tJk+ +TOOSTs/wq+8lSNWOwFqiKqIYdOnTbERUe2SGkiH2vj4DlZyefB3j8+v/H24xLF4 9lZ4VgV8GSH0u2Vt4O0BJs/sRkYKA== X-ME-Sender: X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgeduhedrtdeggddutdekucetufdoteggodetrfdotf fvucfrrhhofhhilhgvmecuhfgrshhtofgrihhlpdfqfgfvpdfurfetoffkrfgpnffqhgen uceurghilhhouhhtmecufedttdenucesvcftvggtihhpihgvnhhtshculddquddttddmne cujfgurhephffvufffkfgjfhgggfgtsehtqhertddttdejnecuhfhrohhmpefvhhhomhgr shcuofhonhhjrghlohhnuceothhhohhmrghssehmohhnjhgrlhhonhdrnhgvtheqnecukf hppeejjedrudefgedrvddtfedrudekgeenucevlhhushhtvghrufhiiigvpedtnecurfgr rhgrmhepmhgrihhlfhhrohhmpehthhhomhgrshesmhhonhhjrghlohhnrdhnvght X-ME-Proxy: Received: from xps.localnet (184.203.134.77.rev.sfr.net [77.134.203.184]) by mail.messagingengine.com (Postfix) with ESMTPA id 0893D306CE51; Thu, 2 Apr 2020 13:33:43 -0400 (EDT) From: Thomas Monjalon To: Ivan Dyukov Cc: dev@dpdk.org, maxime.coquelin@redhat.com, tiwei.bie@intel.com, amorenoz@redhat.com, zhihong.wang@intel.com, xiaolong.ye@intel.com, Morten =?ISO-8859-1?Q?Br=F8rup?= , ferruh.yigit@intel.com, arybchenko@solarflare.com Date: Thu, 02 Apr 2020 19:33:42 +0200 Message-ID: <21725978.sM9OFumVh5@xps> In-Reply-To: <66962d3d-acee-1992-bf4c-e4954067b015@samsung.com> References: <20191212085012.9170-1-i.dyukov@samsung.com> <2966019.2vfOZ694Ok@xps> <66962d3d-acee-1992-bf4c-e4954067b015@samsung.com> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset="UTF-8" Subject: Re: [dpdk-dev] [PATCH v8 2/5] net/virtio: add link speed devarg 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" 02/04/2020 11:18, Ivan Dyukov: > Hello Thomas, >=20 > 01.04.2020 13:57, Thomas Monjalon =D0=BF=D0=B8=D1=88=D0=B5=D1=82: > > 30/03/2020 09:57, Ivan Dyukov: > >> Some applications like pktgen use link speed to calculate > >> transmission rate. It limits outcome traffic to hardcoded 10G. > >> > >> This patch adds speed devarg which allows to configure > >> link speed of virtio device. > > Is it really a good idea to fake such information? > > Shouldn't it be managed differently in the application instead? > > > > > > > This is main stream of net devices. Device provides speed to=20 > application. Application calculates the packet rate. In case of virtio,=20 > speed is not limited by device. It could be specified by user. This=20 > patch just gives this posibility to user. The other possibility is to return 0 meaning unknown speed. I don't see why this information should be saved in the driver space. The user can give this information to the application, it would look more correct to me. Note: the application is controlling the devargs passed to the driver, so it can intercept such information. I understand it is easier to have the speed info at the same place in all cases. But it avoids differentiating what is a reliable info, and what is user-provided info.