aboutsummaryrefslogtreecommitdiffstats
path: root/lib/librte_ether/rte_ethdev_pci.h
diff options
context:
space:
mode:
authorChristian Ehrhardt <christian.ehrhardt@canonical.com>2017-09-21 11:34:38 +0200
committerChristian Ehrhardt <christian.ehrhardt@canonical.com>2017-09-21 11:37:31 +0200
commit90fb1fd9c01fbb2f44af75c63adb65d721da88ff (patch)
tree45252ac845d75865125a918863ee6897aa7a805e /lib/librte_ether/rte_ethdev_pci.h
parentbf7567fd2a5b0b28ab724046143c24561d38d015 (diff)
Imported Upstream version 17.05.2upstream-17.05-stable
Change-Id: I562c7c338dad65639f764aea8b598ff6711acd54 Signed-off-by: Christian Ehrhardt <christian.ehrhardt@canonical.com>
Diffstat (limited to 'lib/librte_ether/rte_ethdev_pci.h')
-rw-r--r--lib/librte_ether/rte_ethdev_pci.h6
1 files changed, 6 insertions, 0 deletions
diff --git a/lib/librte_ether/rte_ethdev_pci.h b/lib/librte_ether/rte_ethdev_pci.h
index d3bc03cf..60730073 100644
--- a/lib/librte_ether/rte_ethdev_pci.h
+++ b/lib/librte_ether/rte_ethdev_pci.h
@@ -134,6 +134,12 @@ rte_eth_dev_pci_release(struct rte_eth_dev *eth_dev)
eth_dev->data->dev_private = NULL;
+ /*
+ * Secondary process will check the name to attach.
+ * Clear this field to avoid attaching a released ports.
+ */
+ eth_dev->data->name[0] = '\0';
+
eth_dev->device = NULL;
eth_dev->intr_handle = NULL;
}