From patchwork Tue Apr 17 03:02:48 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "Xu, Rosen" X-Patchwork-Id: 38274 X-Patchwork-Delegate: helin.zhang@intel.com Return-Path: X-Original-To: patchwork@dpdk.org Delivered-To: patchwork@dpdk.org Received: from [92.243.14.124] (localhost [127.0.0.1]) by dpdk.org (Postfix) with ESMTP id 9DBB9AAEB; Tue, 17 Apr 2018 05:00:58 +0200 (CEST) Received: from mga17.intel.com (mga17.intel.com [192.55.52.151]) by dpdk.org (Postfix) with ESMTP id 2E07EAAD6 for ; Tue, 17 Apr 2018 05:00:56 +0200 (CEST) X-Amp-Result: SKIPPED(no attachment in message) X-Amp-File-Uploaded: False Received: from orsmga004.jf.intel.com ([10.7.209.38]) by fmsmga107.fm.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 16 Apr 2018 20:00:55 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.48,461,1517904000"; d="scan'208";a="192037528" Received: from dpdkx8602.sh.intel.com ([10.67.110.200]) by orsmga004.jf.intel.com with ESMTP; 16 Apr 2018 20:00:54 -0700 From: Rosen Xu To: dev@dpdk.org Cc: beilei.xing@intel.com, helin.zhang@intel.com, qi.z.zhang@intel.com, jingjing.wu@intel.com Date: Tue, 17 Apr 2018 11:02:48 +0800 Message-Id: <1523934168-128914-1-git-send-email-rosen.xu@intel.com> X-Mailer: git-send-email 1.8.3.1 In-Reply-To: <1521090873-50595-1-git-send-email-rosen.xu@intel.com> References: <1521090873-50595-1-git-send-email-rosen.xu@intel.com> Subject: [dpdk-dev] [PATCH v3] drivers/net/i40e: fix missing promiscuous disable at device disable 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" v3 updates: =========== - Move modification from device close to device disable - i40evf_reset_vf() will cause kernel driver enable all vlan promiscuous, so unicast/multicast promiscuous disable should set before reset. v2 updates: =========== - Add more comments In scenario of Kernel Driver runs on PF and PMD runs on VF, PMD exit doesn't disable promiscuous mode, this will cause vlan filter set by Kernel Driver will not take effect. This patch will fix it, add promiscuous disable at device disable. Signed-off-by: Rosen Xu --- drivers/net/i40e/i40e_ethdev_vf.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/drivers/net/i40e/i40e_ethdev_vf.c b/drivers/net/i40e/i40e_ethdev_vf.c index 031c706..40012b0 100644 --- a/drivers/net/i40e/i40e_ethdev_vf.c +++ b/drivers/net/i40e/i40e_ethdev_vf.c @@ -2288,6 +2288,8 @@ static int eth_i40evf_pci_remove(struct rte_pci_device *pci_dev) i40evf_dev_stop(dev); i40e_dev_free_queues(dev); + i40evf_dev_promiscuous_disable(dev); + i40evf_dev_allmulticast_disable(dev); i40evf_reset_vf(hw); i40e_shutdown_adminq(hw); /* disable uio intr before callback unregister */