Received: by 2002:a25:23cc:0:0:0:0:0 with SMTP id j195csp1461860ybj; Tue, 5 May 2020 21:56:26 -0700 (PDT) X-Google-Smtp-Source: APiQypJ6a4ork8g6YogZktT/M1rttCnMFpWyKbUm5xGYorvKKZv/2hNVRm/8cCiVNPus/s50Z2dD X-Received: by 2002:a17:906:2511:: with SMTP id i17mr5850989ejb.165.1588740986082; Tue, 05 May 2020 21:56:26 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1588740986; cv=none; d=google.com; s=arc-20160816; b=Cx/SmYNmIhSU3KL4h5xKvecc3Fe+y1YMF28yA9c/tq5kfyq2cy9rbOjE0oU45Og98H xlw8OmIAAFhYmJKAshGZoo4cSwr5pScQo5IAkA56PBS1spvDzLqyQErIvNWu3R5qgyEO qtn9quYmCcx247L/rxhl6f8Sn9GUILvVnmEawfW5mVn6x5cT47ypjw1m/UTpbdnXR4Nn zjMwAniRbnpLi7+qhEA1g/w7qEnjQJ3iLcnQTjWxRKqhoKW6djFCTYTlJoFlN+T1Z1Bw U34jhQvIuhItgCuXQ51t9PsrTxAuS/uFaMJnhM0hTCdMQhClv/Gvb65vf23L/97v7D41 bnLA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:user-agent:in-reply-to :content-disposition:mime-version:references:message-id:subject:cc :to:from:date; bh=iMIgwsWba+BcmhISEnXWTJXPgf8x21V7AkolHY9wQVk=; b=nUJrMM0Z2K+7ssvgMF0XGSYUJ0z0cYjC2S+PPYV2kfIkN/YWVH0+Pp2oDJHNjiNewh dQ+HsBllKJd03HPAUn6A/8gLVBrHjcjA78QuveylDuhngPwAX/iYSPwJJpb58znSOr74 fMkOoK9ySBJN/e7DojXmbYVgyC4SnR7XEqVgKbzGTbOvmjv8y9MGVC5GQCbVYftQYRkh LieidahwR+QYqZfRkmavSVxDFFN34uwluBfKZ6ciyjsqfyJlTJodzkEpd3U+tbKqW9HK Ow4M5qw6jzrem1kQ+jNk1aHfe5e02bssyMjcN/anmHOs5julnYZtkAVeRWCPtEetpMGW Czeg== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id y11si382480edr.151.2020.05.05.21.56.03; Tue, 05 May 2020 21:56:26 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726930AbgEFEvg (ORCPT + 99 others); Wed, 6 May 2020 00:51:36 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:44592 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726350AbgEFEvf (ORCPT ); Wed, 6 May 2020 00:51:35 -0400 Received: from metis.ext.pengutronix.de (metis.ext.pengutronix.de [IPv6:2001:67c:670:201:290:27ff:fe1d:cc33]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 4A8BEC061A10 for ; Tue, 5 May 2020 21:51:35 -0700 (PDT) Received: from pty.hi.pengutronix.de ([2001:67c:670:100:1d::c5]) by metis.ext.pengutronix.de with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1jWC1j-0000J1-MN; Wed, 06 May 2020 06:51:23 +0200 Received: from ore by pty.hi.pengutronix.de with local (Exim 4.89) (envelope-from ) id 1jWC1e-0006qW-QW; Wed, 06 May 2020 06:51:18 +0200 Date: Wed, 6 May 2020 06:51:18 +0200 From: Oleksij Rempel To: Grygorii Strashko Cc: Andrew Lunn , Florian Fainelli , Heiner Kallweit , David Jander , "David S. Miller" , kernel@pengutronix.de, linux-kernel@vger.kernel.org, netdev@vger.kernel.org, Philippe Schenker , Russell King Subject: Re: [PATCH net-next v3] net: phy: micrel: add phy-mode support for the KSZ9031 PHY Message-ID: <20200506045118.hl3sfmww2ncfh5ze@pengutronix.de> References: <20200422072137.8517-1-o.rempel@pengutronix.de> <71dea993-b420-e994-ffa8-87350e157cda@ti.com> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha256; protocol="application/pgp-signature"; boundary="l5xaumdvxm7xwgpw" Content-Disposition: inline In-Reply-To: <71dea993-b420-e994-ffa8-87350e157cda@ti.com> X-Sent-From: Pengutronix Hildesheim X-URL: http://www.pengutronix.de/ X-IRC: #ptxdist @freenode X-Accept-Language: de,en X-Accept-Content-Type: text/plain X-Uptime: 06:46:43 up 172 days, 20:05, 176 users, load average: 0.04, 0.07, 0.07 User-Agent: NeoMutt/20170113 (1.7.2) X-SA-Exim-Connect-IP: 2001:67c:670:100:1d::c5 X-SA-Exim-Mail-From: ore@pengutronix.de X-SA-Exim-Scanned: No (on metis.ext.pengutronix.de); SAEximRunCond expanded to false X-PTX-Original-Recipient: linux-kernel@vger.kernel.org Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org --l5xaumdvxm7xwgpw Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable Hi Grygorii, On Tue, May 05, 2020 at 09:26:46PM +0300, Grygorii Strashko wrote: >=20 >=20 > On 22/04/2020 10:21, Oleksij Rempel wrote: > > Add support for following phy-modes: rgmii, rgmii-id, rgmii-txid, rgmii= -rxid. > >=20 > > This PHY has an internal RX delay of 1.2ns and no delay for TX. > >=20 > > The pad skew registers allow to set the total TX delay to max 1.38ns and > > the total RX delay to max of 2.58ns (configurable 1.38ns + build in > > 1.2ns) and a minimal delay of 0ns. > >=20 > > According to the RGMII v1.3 specification the delay provided by PCB tra= ces > > should be between 1.5ns and 2.0ns. The RGMII v2.0 allows to provide this > > delay by MAC or PHY. So, we configure this PHY to the best values we can > > get by this HW: TX delay to 1.38ns (max supported value) and RX delay to > > 1.80ns (best calculated delay) > >=20 > > The phy-modes can still be fine tuned/overwritten by *-skew-ps > > device tree properties described in: > > Documentation/devicetree/bindings/net/micrel-ksz90x1.txt > >=20 > > Signed-off-by: Oleksij Rempel > > --- > > changes v3: > > - change delay on RX line to 1.80ns > > - add warning if *-skew-ps properties are used together with not rgmii > > mode. > >=20 > > changes v2: > > - change RX_ID value from 0x1a to 0xa. The overflow bit was detected by > > FIELD_PREP() build check. > > Reported-by: kbuild test robot > >=20 > > drivers/net/phy/micrel.c | 128 +++++++++++++++++++++++++++++++++++++-- > > 1 file changed, 123 insertions(+), 5 deletions(-) > >=20 >=20 > This patch broke networking on at least 5 TI boards: > am572x-idk > am571x-idk > am43xx-hsevm > am43xx-gpevm > am437x-idk >=20 > am57xx I can fix. >=20 > am437x need to investigate. Please try: phy-mode =3D "rgmii-txid" I assume your boards are using "rgmii" which should be used only if you boards have extra long clk traces. Regards, Oleksij --=20 Pengutronix e.K. | | Steuerwalder Str. 21 | http://www.pengutronix.de/ | 31137 Hildesheim, Germany | Phone: +49-5121-206917-0 | Amtsgericht Hildesheim, HRA 2686 | Fax: +49-5121-206917-5555 | --l5xaumdvxm7xwgpw Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iQIzBAABCAAdFiEERBNZvwSgvmcMY/T74omh9DUaUbMFAl6yQkIACgkQ4omh9DUa UbMp2A/+J8sk5MKQrPLpxu0jbGmvE3SO4JOpyFLJVxg83qR0ndhzuRXM2o0AKz7a v5BmOL+e926ev0iisyOdzsNSdWh5xlV3FiIT1sUOSyfigVsgKUVe5Jb7n8q+QiKi 5NEyB6LckWrWnfkEp5OFyAh0wY3+GX/RUQEeQQ4sLBUNyyhHCSKR5WAxLkZ24M8P K+b/g/DbRJGWCiasnFnOJZTdHjW7MWtxBUBoxEYPt9LtyGWJ5E8S8R93jmztaLJr wFSrX0Wi0UrAYX+OCLGerw6N2biFrU7jQeXs5Gup+fwq9+MfAm7s2R16ecqNVzdy r1N6exEX+POV0BAgovn8sG8pUSij36d41Iiuqt85o9ZXXEnNB5l2XCPlhbKIltT/ dJQR9F5TwhIM6zc6jnU0DvAtdl3WvkvU0gZab2hmC00Wigpsdw6sNmsUyfEOVC2R 207W76WNCEJnQJw81z8QJiQcvgFhr/HaSdvLvzAmXbOj23PxV+wgp8vVawmgGcLR kIsJDwu4TBUS3SZfoKXcYberpHvaSZaikijpJxCJs2NMND/3Cgn/WzNCkBrbaFQL znUhKYUoPX6isaX+e4i4DxEe+35tTggQhQZ+E0Pk+lppkDIecyHrGOCM3NTUBDA3 NM3UoHo/K1XyIpTbPWuQp6o1U5KMQPA4SQbdOSdkw7S+0++zglY= =tVb8 -----END PGP SIGNATURE----- --l5xaumdvxm7xwgpw--