From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mails.dpdk.org (mails.dpdk.org [217.70.189.124]) by inbox.dpdk.org (Postfix) with ESMTP id 38132A04FF; Thu, 24 Mar 2022 09:40:14 +0100 (CET) Received: from [217.70.189.124] (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 05511410FC; Thu, 24 Mar 2022 09:40:14 +0100 (CET) Received: from mga17.intel.com (mga17.intel.com [192.55.52.151]) by mails.dpdk.org (Postfix) with ESMTP id ACF9B40141 for ; Thu, 24 Mar 2022 09:40:12 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1648111212; x=1679647212; h=from:to:cc:subject:date:message-id:references: in-reply-to:content-transfer-encoding:mime-version; bh=mFHpSxuRabNWiyIq98p887gmd7W7xWC0ysfoYvATZog=; b=PHJ108816M0QAuDZM+qBspLrctG9w/sGB2ZpBG5S9X0a3LDOMUkga4HB LsNoWSQtaUlYU9sapMsQ223LIVaBRGtBxGN2mAc+dM3rrHQxG6DG9/T1v KiKvGnl2Nu5qsYnKML4yATzbfjOXhICsNTp1j7B46tzzVLFsXskioyusJ BjDMCuxtfYqEoupLX1ip6dtqhFv3CHcp3bksnnFOwkeIoD+3zRpnrAtfW W16TFDNRJy/CL0UTYVrjeChuul8flf1tR5i5kv6nz1iXWXHgPyTDv8C85 r2d+6xbBerno9+9d4FM3Ioj1fGVgouXf1VR9K6gCwmgn2BaPCiW5/JfdQ Q==; X-IronPort-AV: E=McAfee;i="6200,9189,10295"; a="238921258" X-IronPort-AV: E=Sophos;i="5.90,206,1643702400"; d="scan'208";a="238921258" Received: from fmsmga002.fm.intel.com ([10.253.24.26]) by fmsmga107.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 24 Mar 2022 01:40:11 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.90,206,1643702400"; d="scan'208";a="647788303" Received: from fmsmsx604.amr.corp.intel.com ([10.18.126.84]) by fmsmga002.fm.intel.com with ESMTP; 24 Mar 2022 01:40:11 -0700 Received: from shsmsx602.ccr.corp.intel.com (10.109.6.142) by fmsmsx604.amr.corp.intel.com (10.18.126.84) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2308.27; Thu, 24 Mar 2022 01:40:11 -0700 Received: from shsmsx601.ccr.corp.intel.com (10.109.6.141) by SHSMSX602.ccr.corp.intel.com (10.109.6.142) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2308.21; Thu, 24 Mar 2022 16:40:09 +0800 Received: from shsmsx601.ccr.corp.intel.com ([10.109.6.141]) by SHSMSX601.ccr.corp.intel.com ([10.109.6.141]) with mapi id 15.01.2308.021; Thu, 24 Mar 2022 16:40:09 +0800 From: "Zhang, Qi Z" To: "Wang, Haiyue" , "Daly, Jeff" , "dev@dpdk.org" CC: Stephen Douthit , "Daly, Jeff" Subject: RE: [PATCH v3] net/ixgbe: Retry SFP ID read field to handle misbehaving SFPs Thread-Topic: [PATCH v3] net/ixgbe: Retry SFP ID read field to handle misbehaving SFPs Thread-Index: AQHYPvEu6aEbW3xkVECnYtplPYqgiazNMSUAgAEGHMA= Date: Thu, 24 Mar 2022 08:40:09 +0000 Message-ID: References: <20220307223337.27876-1-jeffd@silicom-usa.com> <20220323200346.22318-1-jeffd@silicom-usa.com> In-Reply-To: Accept-Language: en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: dlp-reaction: no-action dlp-version: 11.6.401.20 dlp-product: dlpe-windows x-originating-ip: [10.239.127.36] Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org > -----Original Message----- > From: Wang, Haiyue > Sent: Thursday, March 24, 2022 9:01 AM > To: Daly, Jeff ; dev@dpdk.org > Cc: Stephen Douthit ; Daly, Jeff > > Subject: RE: [PATCH v3] net/ixgbe: Retry SFP ID read field to handle > misbehaving SFPs Slightly reword the title as below to fix check-git-log warning net/ixgbe: retry to handle misbehaving SFPs read >=20 > > -----Original Message----- > > From: jeffd@silicom-usa.com > > Sent: Thursday, March 24, 2022 04:04 > > To: dev@dpdk.org > > Cc: Stephen Douthit ; Daly, Jeff > > ; Wang, Haiyue > > Subject: [PATCH v3] net/ixgbe: Retry SFP ID read field to handle > > misbehaving SFPs > > > > From: Stephen Douthit > > > > Some XGS-PON SFPs have been observed ACKing I2C reads and returning > > uninitialized garbage while their uC boots. This can lead to the SFP > > ID code marking an otherwise working SFP module as unsupported if a > > bogus ID value is read while its internal PHY/microcontroller is still > > booting. > > > > Retry the ID read several times looking not just for NAK, but also for > > a valid ID field. > > > > Since the device isn't NAKing the trasanction the existing longer > > retry code in ixgbe_read_i2c_byte_generic_int() doesn't apply here. > > > > Signed-off-by: Stephen Douthit > > Signed-off-by: Jeff Daly > > --- > > > > Notes: > > v2: > > * Removed superfluous DEBUGOUT > > * Renamed id_reads to retries > > * Don't assume status =3D=3D 0 means IXGBE_SUCCESS > > > > v3: > > * Removed extra braces around single statement if > > > > drivers/net/ixgbe/base/ixgbe_phy.c | 27 ++++++++++++++++++++++++-- > - > > 1 file changed, 24 insertions(+), 3 deletions(-) > > >=20 > Thanks! >=20 > Reviewed-by: Haiyue Wang Applied to dpdk-next-net-intel. Thanks Qi >=20 > > -- > > 2.25.1