From 1fa41f4518f9f30465a0ed32640e7dbce00b3f4f Mon Sep 17 00:00:00 2001 From: Chenxu Di Date: Wed, 11 Dec 2019 09:06:03 +0000 Subject: [PATCH] net/i40e: fix port close in FreeBSD FreeBSD OS doesn't support igb_uio interrupt, so it will fail when unregister the interrupt callback in port close. We can fix the issue by passing -ENOENT when check the return value of unregister interrupt callback function. Fixes: ac89d46096d5 ("net/i40e: release port upon close") Cc: stable@dpdk.org Signed-off-by: Chenxu Di Acked-by: Xiaolong Ye --- drivers/net/i40e/i40e_ethdev.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/net/i40e/i40e_ethdev.c b/drivers/net/i40e/i40e_ethdev.c index 5999c964bd..8b25003910 100644 --- a/drivers/net/i40e/i40e_ethdev.c +++ b/drivers/net/i40e/i40e_ethdev.c @@ -2594,7 +2594,7 @@ i40e_dev_close(struct rte_eth_dev *dev) do { ret = rte_intr_callback_unregister(intr_handle, i40e_dev_interrupt_handler, dev); - if (ret >= 0) { + if (ret >= 0 || ret == -ENOENT) { break; } else if (ret != -EAGAIN) { PMD_INIT_LOG(ERR, -- 2.20.1