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 306F8A04B7; Tue, 13 Oct 2020 14:51:23 +0200 (CEST) Received: from [92.243.14.124] (localhost [127.0.0.1]) by dpdk.org (Postfix) with ESMTP id EBB7C1DB37; Tue, 13 Oct 2020 14:51:18 +0200 (CEST) Received: from new2-smtp.messagingengine.com (new2-smtp.messagingengine.com [66.111.4.224]) by dpdk.org (Postfix) with ESMTP id 4AD441DB35 for ; Tue, 13 Oct 2020 14:51:16 +0200 (CEST) Received: from compute2.internal (compute2.nyi.internal [10.202.2.42]) by mailnew.nyi.internal (Postfix) with ESMTP id EB88B580150; Tue, 13 Oct 2020 08:51:15 -0400 (EDT) Received: from mailfrontend1 ([10.202.2.162]) by compute2.internal (MEProxy); Tue, 13 Oct 2020 08:51:15 -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=fm2; bh= 03xFAIsXowpULCW8SBIp4OJa6/J191xmYMd3ks2st4U=; b=LM+01MhF7kIpNANE mDe5gTLw99gjQuo/EZBunmqnfqxsdxkuaCvZD04mJssh4bI4j6ZGCI482S1SDuiz JnaR6zz+smG8K36Yuf1pl8nxdcTLc8WcCpLHHDVhJGmqUrViq+CMpFWN3ltdpq/g DoRf/xA4Lcdx0/kkW7sibKYBoFXykyg+COTIlOse5Fg78yf8AVOvb2XLmIFOJKWs P/a9tW8dNXDbEdwA0h5JrOvQt7V2dj3di0AeLfb+zbmniCW17zTEnlOjMT8FX8lj Erlx5sXJHO8lHZ+4CK+eXTg2CLw9RD0Os1VdlOmBXbjQy+ReQx9UbVjrzMUe1Bx/ +hcu9Q== 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=fm1; bh=03xFAIsXowpULCW8SBIp4OJa6/J191xmYMd3ks2st 4U=; b=AZ81qhcrm6E06LBmWKgHgHC79oiGEwio58uyXWTOAgOLhwBhK6Il3M5tX 75DCg9L8MXQtZtVp68wR1fSQSsTW2GUxS64jTE/IvYnjrZfZNIeyc0oC9A5M/h6E ZJpYyGn9nSrlhgRmVggIuIyq7FSL0Cu+78SmXVP/knoP4ToKIALKLSRVdCcdqytW xH+q8BZXR/MBT3enMGuwTcdox5fbyFA05tUZ/Ln5CJhXd093BIJnpgMvt2G0jnVj 2vZaSZ2hYlji1YeyNHZgObTRxqvG0gmUh/IXl49o1qTrPECWT+DtqkmWayU1tFFx YvvwwaeUrxzP35+vtPJElOQvcRtDQ== X-ME-Sender: X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgedujedrheelgdehjecutefuodetggdotefrodftvf curfhrohhfihhlvgemucfhrghsthforghilhdpqfgfvfdpuffrtefokffrpgfnqfghnecu uegrihhlohhuthemuceftddtnecusecvtfgvtghiphhivghnthhsucdlqddutddtmdenuc fjughrpefhvffufffkjghfggfgtgesthfuredttddtvdenucfhrhhomhepvfhhohhmrghs ucfoohhnjhgrlhhonhcuoehthhhomhgrshesmhhonhhjrghlohhnrdhnvghtqeenucggtf frrghtthgvrhhnpedugefgvdefudfftdefgeelgffhueekgfffhfeujedtteeutdejueei iedvffegheenucfkphepjeejrddufeegrddvtdefrddukeegnecuvehluhhsthgvrhfuih iivgeptdenucfrrghrrghmpehmrghilhhfrhhomhepthhhohhmrghssehmohhnjhgrlhho nhdrnhgvth 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 01910328005E; Tue, 13 Oct 2020 08:51:11 -0400 (EDT) From: Thomas Monjalon To: Ferruh Yigit Cc: dev@dpdk.org, Andrew Rybchenko , Steven Webster , Matt Peters , Somalapuram Amaranath , Rasesh Mody , Shahed Shaikh , Rahul Lakkireddy , Hemant Agrawal , Sachin Saxena , John Daley , Hyong Youb Kim , Qiming Yang , Qi Zhang , Alfredo Cardigliano , Rosen Xu , Matan Azrad , Shahaf Shuler , Viacheslav Ovsiienko , Liron Himi , Heinrich Kuhn , Harman Kalra , Jerin Jacob , Nithin Dabilpuram , Kiran Kumar K , Andrew Rybchenko Date: Tue, 13 Oct 2020 14:51:10 +0200 Message-ID: <4842858.jpJ4lIlKDh@thomas> In-Reply-To: <500095bc-470e-1bce-05d2-6fa67437dddd@intel.com> References: <20200913220711.3768597-1-thomas@monjalon.net> <20201013100634.2482593-2-thomas@monjalon.net> <500095bc-470e-1bce-05d2-6fa67437dddd@intel.com> MIME-Version: 1.0 Content-Transfer-Encoding: 7Bit Content-Type: text/plain; charset="us-ascii" Subject: Re: [dpdk-dev] [PATCH v5 1/3] ethdev: remove forcing stopped state upon close 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" 13/10/2020 14:45, Ferruh Yigit: > On 10/13/2020 11:06 AM, Thomas Monjalon wrote: > > When closing a port, it is supposed to be already stopped, > > and marked as such with "dev_started" state zeroed by the stop API. > > > > Resetting "dev_started" before calling the driver close operation > > was hiding the case of not properly stopped port being closed. > > The flag "dev_started" is not changed anymore in "rte_eth_dev_close()". > > > > In case the "dev_stop" function is called from "dev_close", > > bypassing "rte_eth_dev_stop()" API, > > the "dev_started" state must be explicitly reset in the PMD > > in order to keep the same behaviour. > > > > Signed-off-by: Thomas Monjalon > > Acked-by: Stephen Hemminger > > Reviewed-by: Andrew Rybchenko [...] > Following non-virtual PMDs doesn't call 'dev_stop()' from 'dev_close()', > maintainers of the PMDs cc'ed. > > avp > axgbe > bnx2x > cxgbe > dpaa2 > enic > ice_dcf > ionic > ipn3ke > mlx4 > mlx5 > mvpp2 > nfp > octeontx > octeontx2 > sfc > > Can you please double check for your driver: > > 1) Device stopped properly before it has been closed? > > 2) The device stopped state ('dev->data->dev_started') is correct if device > closed without explicitly stopped first. The application is supposed to call stop before close, so I don't know what has to be checked. The automatic stop in close is an extra feature per PMD choice.