From 0b274fbecec5302aa8c68ed3770cbed7f1e59cf2 Mon Sep 17 00:00:00 2001 From: Alejandro Lucero Date: Tue, 31 Oct 2017 11:04:52 +0000 Subject: [PATCH] net/nfp: avoid unplug if multiport PF multiport support has some limitations like not allowing plugging or unplugging of single ports as they all belong to same PCI device. A previous patch for removing detachable flag introduced a wrong check. Fixes: 00a3d8104ac5 ("ethdev: remove detachable device flag") Signed-off-by: Alejandro Lucero --- drivers/net/nfp/nfp_net.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/net/nfp/nfp_net.c b/drivers/net/nfp/nfp_net.c index e9001f440b..83dec0612f 100644 --- a/drivers/net/nfp/nfp_net.c +++ b/drivers/net/nfp/nfp_net.c @@ -3029,7 +3029,7 @@ static int eth_nfp_pci_remove(struct rte_pci_device *pci_dev) hw = NFP_NET_DEV_PRIVATE_TO_HW(eth_dev->data->dev_private); } /* hotplug is not possible with multiport PF */ - if (!hw->pf_multiport_enabled) + if (hw->pf_multiport_enabled) return -ENOTSUP; return rte_eth_dev_pci_generic_remove(pci_dev, NULL); } -- 2.20.1