From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from dpdk.org (dpdk.org [92.243.14.124]) by inbox.dpdk.org (Postfix) with ESMTP id 194ACA32A2 for ; Fri, 25 Oct 2019 07:45:04 +0200 (CEST) Received: from [92.243.14.124] (localhost [127.0.0.1]) by dpdk.org (Postfix) with ESMTP id 043C41E85E; Fri, 25 Oct 2019 07:45:02 +0200 (CEST) Received: from mga05.intel.com (mga05.intel.com [192.55.52.43]) by dpdk.org (Postfix) with ESMTP id 20A5A1E551 for ; Fri, 25 Oct 2019 07:44:59 +0200 (CEST) X-Amp-Result: SKIPPED(no attachment in message) X-Amp-File-Uploaded: False Received: from fmsmga002.fm.intel.com ([10.253.24.26]) by fmsmga105.fm.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 24 Oct 2019 22:44:59 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.68,227,1569308400"; d="scan'208";a="228782247" Received: from intel.sh.intel.com ([10.239.255.149]) by fmsmga002.fm.intel.com with ESMTP; 24 Oct 2019 22:44:57 -0700 From: Di ChenxuX To: dev@dpdk.org Cc: Wenzhuo Lu , Yang Qiming , Di ChenxuX Date: Fri, 25 Oct 2019 04:52:58 +0000 Message-Id: <20191025045258.66935-1-chenxux.di@intel.com> X-Mailer: git-send-email 2.17.1 Subject: [dpdk-dev] [PATCH] net/ixgbe: fix port close in FreeBSD OS 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: , Errors-To: dev-bounces@dpdk.org Sender: "dev" FreeBSD OS don't support igb_uio interrupt, so it will fail that unregister intr callback when port close. Fix by passing -ENOENT when check the return value of unregister intr callback function. Fixes: f2f4990eff94 ("net/ixgbe: release port upon close") Signed-off-by: Di ChenxuX --- drivers/net/ixgbe/ixgbe_ethdev.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/net/ixgbe/ixgbe_ethdev.c b/drivers/net/ixgbe/ixgbe_ethdev.c index dbce7a80e..0a654accb 100644 --- a/drivers/net/ixgbe/ixgbe_ethdev.c +++ b/drivers/net/ixgbe/ixgbe_ethdev.c @@ -2978,7 +2978,7 @@ ixgbe_dev_close(struct rte_eth_dev *dev) do { ret = rte_intr_callback_unregister(intr_handle, ixgbe_dev_interrupt_handler, dev); - if (ret >= 0) { + if (ret >= 0 || ret == -ENOENT) { break; } else if (ret != -EAGAIN) { PMD_INIT_LOG(ERR, -- 2.17.1