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 3FF3DA04C0; Mon, 28 Sep 2020 01:50:14 +0200 (CEST) Received: from [92.243.14.124] (localhost [127.0.0.1]) by dpdk.org (Postfix) with ESMTP id 0A6221D6A0; Mon, 28 Sep 2020 01:44:41 +0200 (CEST) Received: from out5-smtp.messagingengine.com (out5-smtp.messagingengine.com [66.111.4.29]) by dpdk.org (Postfix) with ESMTP id D17DB1D5FD for ; Mon, 28 Sep 2020 01:44:10 +0200 (CEST) Received: from compute7.internal (compute7.nyi.internal [10.202.2.47]) by mailout.nyi.internal (Postfix) with ESMTP id 7A9AC5C00F7; Sun, 27 Sep 2020 19:44:10 -0400 (EDT) Received: from mailfrontend1 ([10.202.2.162]) by compute7.internal (MEProxy); Sun, 27 Sep 2020 19:44:10 -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; s=fm2; bh=bTnjksrkZ4ca5 ljinf3/HAihp7/52r8LfEcASsDOi8Q=; b=cDw9UuX4xHI0epmrbtlRv9kleVUCW 971hZItDWDzejuvbG77IGVVEwMg3Eor6T42K9qqOKm+6SzonlS90lJHVEqwyl3xg A4ACRULJ3mdYR3FnbqM1Z3ceB3hCaa/29mzBUPfUwtQ3chaJ+feITNu5EVPzcESA TaiWIfHQwsK6KucQ+ywhMDFsN5y6HKcN7u0Vt+zWJK6M2O0Km4d49ywYiwvvKTuo w+5CY6p1gax5+hMc4FbZInyXgaFmP9T17PaWlnx0GAtLJOBUExHWADUP6bN2PY9X /5vpkzHJC9ID0y8RWUyh64SXpnBI7Ly9JxbUZiU8hifVGQfU2XzmX9rsw== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=cc:content-transfer-encoding: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= fm3; bh=bTnjksrkZ4ca5ljinf3/HAihp7/52r8LfEcASsDOi8Q=; b=CneGuSi7 Zmcm6KNPOjESZrqC/De16YmVHhKQ8ZFQRHsixtwOBfdI04QGSxY7GQtEDYq5Q4y3 xDOvqzr07Q2tuj+SKbpCQqX0bJ0hr9hWzKk+e3LRtwdKDrMH5leGdvotL0SInnjv 3sE2m5WRswJz10lHeNwMqknrwx92BEKFVAkemjAEGMnfeo6heqdDX1buF7Eea8NP pPqhgNLkiGX5izjKTQYBE84d/xaNfIywNtGXCA9nCNxa+h3Td5Kko5pOVqJTboPQ b6ltgtQwJXxBn+jvaFe2yatUnbZFGBAgpTqLllJJ4xhdhzom8OhRXl1FivnmU2H1 FTIDqsGKwNfwbw== X-ME-Sender: X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgedujedrvdehgddvhecutefuodetggdotefrodftvf curfhrohhfihhlvgemucfhrghsthforghilhdpqfgfvfdpuffrtefokffrpgfnqfghnecu uegrihhlohhuthemuceftddtnecunecujfgurhephffvufffkffojghfggfgsedtkeertd ertddtnecuhfhrohhmpefvhhhomhgrshcuofhonhhjrghlohhnuceothhhohhmrghssehm ohhnjhgrlhhonhdrnhgvtheqnecuggftrfgrthhtvghrnhepvdehgfeivdejgedtveehfe fhteelfefgieevgfffveefjeegtdfguedthedtgeevnecukfhppeejjedrudefgedrvddt fedrudekgeenucevlhhushhtvghrufhiiigvpedvudenucfrrghrrghmpehmrghilhhfrh homhepthhhohhmrghssehmohhnjhgrlhhonhdrnhgvth X-ME-Proxy: Received: from xps.monjalon.net (184.203.134.77.rev.sfr.net [77.134.203.184]) by mail.messagingengine.com (Postfix) with ESMTPA id D595A3280059; Sun, 27 Sep 2020 19:44:09 -0400 (EDT) From: Thomas Monjalon To: dev@dpdk.org Cc: ferruh.yigit@intel.com, arybchenko@solarflare.com Date: Mon, 28 Sep 2020 01:42:47 +0200 Message-Id: <20200927234249.3198780-24-thomas@monjalon.net> X-Mailer: git-send-email 2.28.0 In-Reply-To: <20200927234249.3198780-1-thomas@monjalon.net> References: <20200913220711.3768597-1-thomas@monjalon.net> <20200927234249.3198780-1-thomas@monjalon.net> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Subject: [dpdk-dev] [PATCH v2 23/25] 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" When closing a port, it is supposed to be already stopped, and marked as such with "dev_started" state zeroed. 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()". Signed-off-by: Thomas Monjalon --- lib/librte_ethdev/rte_ethdev.c | 1 - 1 file changed, 1 deletion(-) diff --git a/lib/librte_ethdev/rte_ethdev.c b/lib/librte_ethdev/rte_ethdev.c index d7668114ca..0b8e8e3e8d 100644 --- a/lib/librte_ethdev/rte_ethdev.c +++ b/lib/librte_ethdev/rte_ethdev.c @@ -1716,7 +1716,6 @@ rte_eth_dev_close(uint16_t port_id) dev = &rte_eth_devices[port_id]; RTE_FUNC_PTR_OR_RET(*dev->dev_ops->dev_close); - dev->data->dev_started = 0; (*dev->dev_ops->dev_close)(dev); rte_ethdev_trace_close(port_id); -- 2.28.0