Received: by 2002:a05:6a10:1a4d:0:0:0:0 with SMTP id nk13csp2093342pxb; Wed, 9 Feb 2022 10:40:27 -0800 (PST) X-Google-Smtp-Source: ABdhPJxwet3DU/X8BaYV7z3o0CEp6Amb2j/gWV9ipQ3bCmUkosJG/p46lshZl/Di42/h/JKSJe/Q X-Received: by 2002:a17:906:7487:: with SMTP id e7mr3193312ejl.58.1644432027395; Wed, 09 Feb 2022 10:40:27 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1644432027; cv=none; d=google.com; s=arc-20160816; b=RIc7uG8Lq7lf9q/yuH4xqyJl0sDZoUMY3qZ0/1RPRkFMEEGw6mVkK4dv4pHxETtJRm 7XdxXSzsLh7uaaG8BGcdp38+4roLoVe2R4mZgnatKXsgrkMQURLUWJAOnQ3l8emBO9OT JX4njgJI3OmciT6HYV81FRkQPooDm+ir8DL2DR22CBtQVmtXLfGFDa5EF/aCbaJ/pd17 YHE+T1PNGwaQUmuVAumqZhEtsyleuaMG+SR1LU5p0LPr+iWDFIey3sgVF8OSFBTHqM6b O1rt6tjSLX+2Q6XCyT9Iwo755xuK001A8+PA6BWAvtniBpBjrlhvEZzM4PfYV0xLbrGP k2WQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:cc:to:subject:message-id:date:from:in-reply-to :references:mime-version:dkim-signature; bh=f18zhjNA/1oePndK5dfsZn2r6JnfT2DoIKaTV1UU+J0=; b=MFP+qAVvQhw1GnD4CPR7pWy5pzRUQt7kY45Znh/JUes/Gfj9DkiWeMB1/OACwqp5qP VMRiieWh9DNUP/0kpRtrsy3ZXa9jMeb6jM/ginqpC7FAAStQOdZS+HWobIwu7ecUF3YO 4tKaRCL4ucc35x6pQWX1LtLx1AutU7xjp5/nO8f1ZJZ1Zr/Ec0UDjNFPRkkE1dHeD6sO JYyHRgSVBAM6rek+axKZtiAxOYkuTfVK8oYRzAGZTYQA1uK0Ndl29K2KSWg9vadD7XV8 Bo+vJaZuqTpGnZIpIVNRTt6JuPSCL0xHB9x2dWf2jzPDmDT745w/HWkkAEm95Bq1wlSM loFg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gateworks-com.20210112.gappssmtp.com header.s=20210112 header.b=2sVnnSBw; 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 jg3si5692905ejc.83.2022.02.09.10.39.59; Wed, 09 Feb 2022 10:40:27 -0800 (PST) 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; dkim=pass header.i=@gateworks-com.20210112.gappssmtp.com header.s=20210112 header.b=2sVnnSBw; 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 S237033AbiBIQbe (ORCPT + 99 others); Wed, 9 Feb 2022 11:31:34 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:35318 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S237020AbiBIQbc (ORCPT ); Wed, 9 Feb 2022 11:31:32 -0500 Received: from mail-pl1-x62d.google.com (mail-pl1-x62d.google.com [IPv6:2607:f8b0:4864:20::62d]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id C5F79C0612BE for ; Wed, 9 Feb 2022 08:31:35 -0800 (PST) Received: by mail-pl1-x62d.google.com with SMTP id u12so2645680plq.10 for ; Wed, 09 Feb 2022 08:31:35 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gateworks-com.20210112.gappssmtp.com; s=20210112; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=f18zhjNA/1oePndK5dfsZn2r6JnfT2DoIKaTV1UU+J0=; b=2sVnnSBwxhgFlh+U1Zk8St2FmWoyRonVGWeOy1DyA+M6q+sqWhARdchnOEZsUycKeP DxgI6Qfy795n43SEMakuXQYcficNKrhTiHeciPFcQNdKYQDWU/nWWsDbQ3I6ftPlwGZ1 HtZNSwk6kKpsllijI+8Yj9WxngExCltZghVwIsHlvKo8Oo6m8f8dypsDcIK2ovGB9rwf EkSvwhjoQ6bU01UYIUSGQdKc/S8PxfT/rp+nVVAVCxssTahcbN6AXnb/kobXDibDmIaU jV1kHAmmjV9iwGyAh+qdGPyfI0lGjMx3Tu6J51htzyd6WFLOq8ZUBF2IJqxRHG1apwSk Wh8g== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=f18zhjNA/1oePndK5dfsZn2r6JnfT2DoIKaTV1UU+J0=; b=baonj0ZvFb5WtBYPMgx+wzxQKtVTYFGKkFblBys9gOhyy1FUV4MnKPRAall37q5o8W f3M1yDEY+bcdWz/SSVbaKGSp6WPMI1p70ZJbsV6WNhC+fR77+Jy0+j+2+9BKEunDbVmr vMhwi9x2BQQkEcHAFNbSlAYfZjSRjOp/+/Z6woo+/HqkFN8LOzeObUA0tImSHFKvKwD5 yexvJd7BLCYQ6DA6onS6C+v4X/RgsS1+8cop9u9oXu3KMLtmjqqLL99zxkXj33GX7v2N YV9PR5dNQuUjox2rkzxFCWSWcudzzve6s3aEb4lSw4NQ+g8NbKAuoGiFG6JNVT9GpZty ILuQ== X-Gm-Message-State: AOAM531vENaZJ1iGkOIL67z/WrJ3Bw0R/SFBbVAK1cbvPsW8wFNYu7iW bY3QPrRbBPFxhLDzNH5hjnC2ozWhYgoCKJoHKTtS6A== X-Received: by 2002:a17:903:1210:: with SMTP id l16mr2952959plh.63.1644424295180; Wed, 09 Feb 2022 08:31:35 -0800 (PST) MIME-Version: 1.0 References: <20210421055047.22858-1-ms@dev.tdt.de> In-Reply-To: From: Tim Harvey Date: Wed, 9 Feb 2022 08:31:23 -0800 Message-ID: Subject: Re: [PATCH net v3] net: phy: intel-xway: enable integrated led functions To: Andrew Lunn Cc: Martin Schiller , Hauke Mehrtens , martin.blumenstingl@googlemail.com, Florian Fainelli , hkallweit1@gmail.com, Russell King - ARM Linux , David Miller , kuba@kernel.org, netdev , open list Content-Type: text/plain; charset="UTF-8" X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,RCVD_IN_DNSWL_NONE,SPF_HELO_NONE,SPF_PASS, T_SCC_BODY_TEXT_LINE autolearn=unavailable autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Fri, Feb 4, 2022 at 2:54 PM Andrew Lunn wrote: > > > The PHY_INTERRFACE_MODE_NA is a neat trick that I will remember but it > > would only help with the rgmii delay issue and not the LED issue (this > > patch). The GPY111 has some really nasty errata that is going to cause > > me to have a very hackish work-around anyway and I will be disabling > > the PHY driver to stay out of the way of that workaround > > Well, ideally we want the workaround for the erratas in the kernel > drivers. In the long run, you will get less surprises if you add what > you need to Linux, not hide stuff away in the bootloader. Andrew, I agree it is best to get workarounds for errata in the kernel where possible but this one is going to be a mess. There are 3 errata for this part and 2 of them require a toggle of the reset pin as a work around. Even if the mii bus can export a function for the phy to call to toggle reset in my case one of my boards has 2 of these PHY's (1 on a RGMII MAC and 1 on a SGMII MAC) on different MDIO busses that share a reset pin so if I trigger a reset I have to re-configure the other phy as well. The errata can be summarized as: - 1 out of 100 boots or cable plug events RGMII GbE link will end up going down and up 3 to 4 times then resort to a 100m link; workaround has been found to require a pin level reset - 1 out of 100 boots or cable plug events (varies per board) SGMII will fail link between the MAC and PHY; workaround has been found to require a pin level reset - occasionally the phy will come up with a high bit error rate between the MAC and PHY; workaround has been found to require a soft reset or ANEG restart > > > As far as changing a driver to force a LED configuration with no dt > > binding input (like this patch does) it feels wrong for exactly the > > same reason - LED configuration for this PHY can be done via > > pin-strapping and this driver now undoes that with this patch. > > Is it possible to read the pin strapping pins? If we know it has been > pin strapped, then a patch to detect this and not change the LED > configuration seems very likely to be accepted. > No, you can read the current LED configuration but you don't know if it was set via strapping or boot firmware. Best regards, Tim