From: Andrew Rybchenko [mailto:[email protected]] Sent: Thursday, June 28, 2018 10:34 PM To: Zhang, Qi Z <[email protected]>; [email protected]; Burakov, Anatoly <[email protected]> Cc: Ananyev, Konstantin <[email protected]>; [email protected]; Richardson, Bruce <[email protected]>; Yigit, Ferruh <[email protected]>; Shelton, Benjamin H <[email protected]>; Vangati, Narender <[email protected]> Subject: Re: [dpdk-dev] [PATCH v7 01/19] ethdev: add function to release port in local process
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 <[email protected]><mailto:[email protected]> Acked-by: Remy Horton <[email protected]><mailto:[email protected]> --- 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 <[email protected]><mailto:[email protected]> will fix both issue in v8. Thanks, Qi

