From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from dispatch1-us1.ppe-hosted.com (dispatch1-us1.ppe-hosted.com [148.163.129.52]) by dpdk.org (Postfix) with ESMTP id D2D201B3B9 for ; Thu, 28 Jun 2018 16:34:30 +0200 (CEST) X-Virus-Scanned: Proofpoint Essentials engine Received: from webmail.solarflare.com (uk.solarflare.com [193.34.186.16]) (using TLSv1 with cipher ECDHE-RSA-AES256-SHA (256/256 bits)) (No client certificate requested) by mx1-us1.ppe-hosted.com (Proofpoint Essentials ESMTP Server) with ESMTPS id 31F9510006B; Thu, 28 Jun 2018 14:34:29 +0000 (UTC) Received: from [192.168.38.17] (91.220.146.112) by ukex01.SolarFlarecom.com (10.17.10.4) with Microsoft SMTP Server (TLS) id 15.0.1044.25; Thu, 28 Jun 2018 15:34:22 +0100 To: Qi Zhang , , CC: , , , , , References: <20180607123849.14439-1-qi.z.zhang@intel.com> <20180628125708.39610-1-qi.z.zhang@intel.com> <20180628125708.39610-2-qi.z.zhang@intel.com> From: Andrew Rybchenko Message-ID: <51b78bc9-cfa6-aa2f-e820-1cadcc276fb4@solarflare.com> Date: Thu, 28 Jun 2018 17:34:18 +0300 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.8.0 MIME-Version: 1.0 In-Reply-To: <20180628125708.39610-2-qi.z.zhang@intel.com> Content-Language: en-GB X-Originating-IP: [91.220.146.112] X-ClientProxiedBy: ocex03.SolarFlarecom.com (10.20.40.36) To ukex01.SolarFlarecom.com (10.17.10.4) X-TM-AS-Product-Ver: SMEX-11.0.0.1191-8.100.1062-23934.003 X-TM-AS-Result: No--13.327100-0.000000-31 X-TM-AS-User-Approved-Sender: Yes X-TM-AS-User-Blocked-Sender: No X-MDID: 1530196470-g-kk_b21oQnB Content-Type: text/plain; charset="utf-8"; format=flowed Content-Transfer-Encoding: 7bit X-Content-Filtered-By: Mailman/MimeDel 2.1.15 Subject: Re: [dpdk-dev] [PATCH v7 01/19] ethdev: add function to release port in local process 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: Thu, 28 Jun 2018 14:34:31 -0000 On 06/28/2018 03:56 PM, Qi Zhang wrote: > Add driver API rte_eth_release_port_private to support the > requirement that an ethdev only be released on secondary process, > so only local state be set to unused , share data will not be Extra space before comma above. > reset so primary process can still use it. > > Signed-off-by: Qi Zhang > Acked-by: Remy Horton > --- > lib/librte_ethdev/rte_ethdev.c | 13 ++++++++++++- > lib/librte_ethdev/rte_ethdev_driver.h | 13 +++++++++++++ > lib/librte_ethdev/rte_ethdev_pci.h | 3 +++ > 3 files changed, 28 insertions(+), 1 deletion(-) > > diff --git a/lib/librte_ethdev/rte_ethdev.c b/lib/librte_ethdev/rte_ethdev.c > index a9977df97..2353fc921 100644 > --- a/lib/librte_ethdev/rte_ethdev.c > +++ b/lib/librte_ethdev/rte_ethdev.c <...> > @@ -371,7 +383,6 @@ rte_eth_dev_release_port(struct rte_eth_dev *eth_dev) > rte_spinlock_lock(&rte_eth_dev_shared_data->ownership_lock); > > eth_dev->state = RTE_ETH_DEV_UNUSED; > - > memset(eth_dev->data, 0, sizeof(struct rte_eth_dev_data)); > > rte_spinlock_unlock(&rte_eth_dev_shared_data->ownership_lock); Just a nit: above looks like unrelated change. Reviewed-by: Andrew Rybchenko