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 ACA9BA0568 for ; Wed, 11 Mar 2020 08:32:15 +0100 (CET) Received: from [92.243.14.124] (localhost [127.0.0.1]) by dpdk.org (Postfix) with ESMTP id 8C0DA1BFFC; Wed, 11 Mar 2020 08:32:15 +0100 (CET) Received: from mga02.intel.com (mga02.intel.com [134.134.136.20]) by dpdk.org (Postfix) with ESMTP id BFA4A2BE6; Wed, 11 Mar 2020 08:32:11 +0100 (CET) X-Amp-Result: UNKNOWN X-Amp-Original-Verdict: FILE UNKNOWN X-Amp-File-Uploaded: False Received: from orsmga004.jf.intel.com ([10.7.209.38]) by orsmga101.jf.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 11 Mar 2020 00:32:10 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.70,540,1574150400"; d="scan'208";a="389180619" Received: from yexl-server.sh.intel.com (HELO localhost) ([10.67.117.17]) by orsmga004.jf.intel.com with ESMTP; 11 Mar 2020 00:32:08 -0700 Date: Wed, 11 Mar 2020 15:29:36 +0800 From: Ye Xiaolong To: Guinan Sun Cc: dev@dpdk.org, Wenzhuo Lu , Qiming Yang , stable@dpdk.org Message-ID: <20200311072936.GA21997@intel.com> References: <20200310025836.70492-1-guinanx.sun@intel.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20200310025836.70492-1-guinanx.sun@intel.com> User-Agent: Mutt/1.9.4 (2018-02-28) Subject: Re: [dpdk-stable] [dpdk-dev] [PATCH] net/ixgbe: fix setting VF MAC address X-BeenThere: stable@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: patches for DPDK stable branches List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: stable-bounces@dpdk.org Sender: "stable" Hi, Guinan On 03/10, Guinan Sun wrote: >This problem occurs because clear_rar is executed at the wrong time, > so PF cannot receive data normally. Could you elaborate what problem you've encountered, and how this patch solves it? Thanks, Xiaolong >This patch is used to modify the calling logic of clear_rar. > >Fixes: 3c4270187518 ("net/ixgbe: support VF MAC address add/remove") >Cc: stable@dpdk.org > >Signed-off-by: Guinan Sun >--- > drivers/net/ixgbe/ixgbe_pf.c | 6 ++++-- > 1 file changed, 4 insertions(+), 2 deletions(-) > >diff --git a/drivers/net/ixgbe/ixgbe_pf.c b/drivers/net/ixgbe/ixgbe_pf.c >index afae21f81..67b5bef44 100644 >--- a/drivers/net/ixgbe/ixgbe_pf.c >+++ b/drivers/net/ixgbe/ixgbe_pf.c >@@ -783,8 +783,10 @@ ixgbe_set_vf_macvlan_msg(struct rte_eth_dev *dev, uint32_t vf, uint32_t *msgbuf) > hw->mac.ops.set_rar(hw, vf_info[vf].mac_count, > new_mac, vf, IXGBE_RAH_AV); > } else { >- hw->mac.ops.clear_rar(hw, vf_info[vf].mac_count); >- vf_info[vf].mac_count = 0; >+ if (vf_info[vf].mac_count) { >+ hw->mac.ops.clear_rar(hw, vf_info[vf].mac_count); >+ vf_info[vf].mac_count = 0; >+ } > } > return 0; > } >-- >2.17.1 >