From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from out3-smtp.messagingengine.com (out3-smtp.messagingengine.com [66.111.4.27]) by dpdk.org (Postfix) with ESMTP id 16CE81B355 for ; Fri, 26 Jan 2018 08:50:14 +0100 (CET) Received: from compute4.internal (compute4.nyi.internal [10.202.2.44]) by mailout.nyi.internal (Postfix) with ESMTP id B8F3820DE2; Fri, 26 Jan 2018 02:50:13 -0500 (EST) Received: from frontend1 ([10.202.2.160]) by compute4.internal (MEProxy); Fri, 26 Jan 2018 02:50:13 -0500 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; s=mesmtp; bh=ZN4+vqJfgCEZ2W3Sglm6zqjggA F1aIpsiIwEYiVfq3I=; b=fIzFrZAiJTI4bYeE0Pi5WS3Z1Venj8As4iyIEwiS85 +QLfj2FW/bvQ5PicromD8tpYvazWkzENlXfXw4z0YsIsQFJd+Y7H2GrPAzYtR8kP mhDzcJ9XUAmvUx7qL38rBs+iviy4mbXjKbuNPOQ8HdUpnjiS7itGlFBCK3oAXJHa w= 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; s=fm1; bh=ZN4+vq JfgCEZ2W3Sglm6zqjggAF1aIpsiIwEYiVfq3I=; b=ey7fd7vC1B86v7ev2Ca26P R8JWktgnaIRt7n4cpgy+OPjTlQ2dIAkiBmLmX1IOch5C+xrHsHj79QqmFC+B/kYe HIpzWOEmKoCmSmhymEA87I0Z0O8LlKh9oqxhdaMaylSVuDAhoWN6A+lf4rjZFc8z FVUHapzpWXCLX60tZqv9YfOGMSnlCrUwCPR9GZ8wl2CFKEvwdFj82fvKMDq8fNhO sa1+pWmVTkvGNNg6/MrRy1DqTcJ/vxNBN3KR+XM/COM0I9MrYvFLc8yPmFf0rMUj /XHG5fihLYpFsVgRFgTfcRlYmQ1H8ZmmO/Baa83nqC7FRnRtDlGWalmjoZPntRUQ == X-ME-Sender: Received: from xps.localnet (184.203.134.77.rev.sfr.net [77.134.203.184]) by mail.messagingengine.com (Postfix) with ESMTPA id 7801B7E82A; Fri, 26 Jan 2018 02:50:13 -0500 (EST) From: Thomas Monjalon To: "Lu, Wenzhuo" Cc: Stephen Hemminger , Moti Haimovsky , dev@dpdk.org, "shahafs@mellanox.com" , "Yigit, Ferruh" Date: Fri, 26 Jan 2018 08:49:31 +0100 Message-ID: <22325029.7cdozGXWV9@xps> In-Reply-To: <6A0DE07E22DDAD4C9103DF62FEBC09093B721CB9@shsmsx102.ccr.corp.intel.com> References: <1516695081-178919-1-git-send-email-motih@mellanox.com> <20180125080141.0dd6ac91@xeon-e3> <6A0DE07E22DDAD4C9103DF62FEBC09093B721CB9@shsmsx102.ccr.corp.intel.com> MIME-Version: 1.0 Content-Transfer-Encoding: 7Bit Content-Type: text/plain; charset="us-ascii" Subject: Re: [dpdk-dev] [PATCH] app/testpmd: do not enable Rx offloads by default 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: Fri, 26 Jan 2018 07:50:14 -0000 26/01/2018 08:31, Lu, Wenzhuo: > From: Stephen Hemminger [mailto:stephen@networkplumber.org] > > On Thu, 25 Jan 2018 10:04:11 +0100 > > Thomas Monjalon wrote: > > > 25/01/2018 02:11, Lu, Wenzhuo: > > > > > --- a/app/test-pmd/testpmd.c > > > > > +++ b/app/test-pmd/testpmd.c > > > > > @@ -305,9 +305,7 @@ struct fwd_engine * fwd_engines[] = { > > > > > */ > > > > > struct rte_eth_rxmode rx_mode = { > > > > > .max_rx_pkt_len = ETHER_MAX_LEN, /**< Default maximum frame > > > > > length. */ > > > > > - .offloads = (DEV_RX_OFFLOAD_VLAN_FILTER | > > > > > - DEV_RX_OFFLOAD_VLAN_STRIP | > > > > > - DEV_RX_OFFLOAD_CRC_STRIP), > > > > > + .offloads = 0, > > > > > > > > Change the default behavior may trigger other problems. I think TX > > offload could be a good reference. Get the capability and check what's > > supported first, then ignore the not supported functions with printing a > > warning but not block anything... > > > > > > I agree that we should check the capabilities before requesting an offload. > > > But I disagree on another point: we should not enable an offload if > > > the user did not request it explicitly. It makes things unclear. > > > This is a testing tool, it should be close to the ethdev API behavior. > > > > > > Why these offload flags are silently enabled? > > > > Also all virtual devices ignore CRC strip. > Look like it's the case the device ignores the flag if it doesn't have the capability. It is a wrong behaviour! If a configuration cannot be applied, it must be an error.