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 92315A04F0; Wed, 18 Dec 2019 03:40:40 +0100 (CET) Received: from [92.243.14.124] (localhost [127.0.0.1]) by dpdk.org (Postfix) with ESMTP id DCC831BECF; Wed, 18 Dec 2019 03:40:39 +0100 (CET) Received: from mga09.intel.com (mga09.intel.com [134.134.136.24]) by dpdk.org (Postfix) with ESMTP id 8ECBA1BE9E; Wed, 18 Dec 2019 03:40:37 +0100 (CET) X-Amp-Result: UNKNOWN X-Amp-Original-Verdict: FILE UNKNOWN X-Amp-File-Uploaded: False Received: from orsmga007.jf.intel.com ([10.7.209.58]) by orsmga102.jf.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 17 Dec 2019 18:40:36 -0800 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.69,327,1571727600"; d="scan'208";a="205692549" Received: from yexl-server.sh.intel.com (HELO localhost) ([10.67.117.17]) by orsmga007.jf.intel.com with ESMTP; 17 Dec 2019 18:40:35 -0800 Date: Wed, 18 Dec 2019 10:35:48 +0800 From: Ye Xiaolong To: Lunyuan Cui Cc: dev@dpdk.org, Wenzhuo Lu , Qiming Yang , stable@dpdk.org Message-ID: <20191218023548.GQ59123@intel.com> References: <20191217061203.47833-1-lunyuanx.cui@intel.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20191217061203.47833-1-lunyuanx.cui@intel.com> User-Agent: Mutt/1.9.4 (2018-02-28) Subject: Re: [dpdk-dev] [PATCH] net/ixgbe: fix ixgbevf link status 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" On 12/17, Lunyuan Cui wrote: >The link status for ixgbevf is not correct when PF link up. >IXGBE_ESDP register is only used when media type is fiber. > >Fixes: 1ca05831b9be ("net/ixgbe: fix link status") >Cc: stable@dpdk.org > >Signed-off-by: Lunyuan Cui >--- > drivers/net/ixgbe/ixgbe_ethdev.c | 8 +++++--- > 1 file changed, 5 insertions(+), 3 deletions(-) > >diff --git a/drivers/net/ixgbe/ixgbe_ethdev.c b/drivers/net/ixgbe/ixgbe_ethdev.c >index 2c6fd0f13..a3f550c53 100644 >--- a/drivers/net/ixgbe/ixgbe_ethdev.c >+++ b/drivers/net/ixgbe/ixgbe_ethdev.c >@@ -4155,9 +4155,11 @@ ixgbe_dev_link_update_share(struct rte_eth_dev *dev, > return rte_eth_linkstatus_set(dev, &link); > } > >- esdp_reg = IXGBE_READ_REG(hw, IXGBE_ESDP); >- if ((esdp_reg & IXGBE_ESDP_SDP3)) >- link_up = 0; >+ if (ixgbe_get_media_type(hw) == ixgbe_media_type_fiber) { >+ esdp_reg = IXGBE_READ_REG(hw, IXGBE_ESDP); >+ if ((esdp_reg & IXGBE_ESDP_SDP3)) >+ link_up = 0; >+ } > > if (link_up == 0) { > if (ixgbe_get_media_type(hw) == ixgbe_media_type_fiber) { >-- >2.17.1 > Acked-by: Xiaolong Ye Applied to dpdk-next-net-intel, Thanks.