aboutsummaryrefslogtreecommitdiffstats
path: root/src/plugins/dpdk/device
diff options
context:
space:
mode:
authorStephen Hemminger <stephen@networkplumber.org>2018-11-01 14:17:14 -0700
committerMarco Varlese <marco.varlese@suse.de>2018-11-02 08:07:45 +0000
commit93468adfc4c5a449532fbfecd575f17d9cae7099 (patch)
treee0cda596e769f9f41c564f183e280f7e011cd81e /src/plugins/dpdk/device
parentc44a558164a466a74a4c10d4e7d7dd1b9a4b01dd (diff)
dpdk: restore special handling for failsafe driver
The failsafe driver is unique because it shares device with underlying pci device. This confuses name generation. Without this fix, the name is wrong and multiple devices get created with same name. Fixes: 3901a038edf4 ("dpdk: only look at PCI information on PCI devices") Change-Id: I13796d03baf6c76dafe3667c83bea4a1ae30c48f Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
Diffstat (limited to 'src/plugins/dpdk/device')
-rw-r--r--src/plugins/dpdk/device/format.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/plugins/dpdk/device/format.c b/src/plugins/dpdk/device/format.c
index e173ebd5f84..d7685ebe627 100644
--- a/src/plugins/dpdk/device/format.c
+++ b/src/plugins/dpdk/device/format.c
@@ -239,7 +239,7 @@ format_dpdk_device_name (u8 * s, va_list * args)
rte_eth_dev_info_get (i, &dev_info);
pci_dev = dpdk_get_pci_device (&dev_info);
- if (pci_dev)
+ if (pci_dev && dm->devices[i].port_type != VNET_DPDK_PORT_TYPE_FAILSAFE)
ret = format (s, devname_format, device_name, pci_dev->addr.bus,
pci_dev->addr.devid, pci_dev->addr.function);
else