From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from netronome.com (host-79-78-33-110.static.as9105.net [79.78.33.110]) by dpdk.org (Postfix) with ESMTP id 379FC1B22C for ; Tue, 31 Oct 2017 12:05:09 +0100 (CET) Received: from netronome.com (localhost [127.0.0.1]) by netronome.com (8.14.4/8.14.4/Debian-4.1ubuntu1) with ESMTP id v9VB4qs8036461; Tue, 31 Oct 2017 11:04:52 GMT Received: (from alucero@localhost) by netronome.com (8.14.4/8.14.4/Submit) id v9VB4qk3036460; Tue, 31 Oct 2017 11:04:52 GMT From: Alejandro Lucero To: dev@dpdk.org Cc: gaetan.rivet@6wind.com Date: Tue, 31 Oct 2017 11:04:52 +0000 Message-Id: <1509447892-36422-1-git-send-email-alejandro.lucero@netronome.com> X-Mailer: git-send-email 1.9.1 Subject: [dpdk-dev] [PATCH] net/nfp: avoid unplug if multiport 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: Tue, 31 Oct 2017 11:05:09 -0000 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") Cc: gaetan.rivet@6wind.com 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 8c1c1f0..05f26bc 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); } -- 1.9.1