Message ID | 20230427195538.2718661-1-hugo@hugovil.com |
---|---|
State | New |
Headers |
Return-Path: <linux-kernel-owner@vger.kernel.org> Delivered-To: ouuuleilei@gmail.com Received: by 2002:a59:b0ea:0:b0:3b6:4342:cba0 with SMTP id b10csp517355vqo; Thu, 27 Apr 2023 13:36:45 -0700 (PDT) X-Google-Smtp-Source: ACHHUZ49PFAKuA1zhTYVXOxpjFlw+nl6HtG7PWoGeONjVhuDUJQcjPHCLpPXaKHoFgySbwm/twk+ X-Received: by 2002:a05:6a20:a6a4:b0:da:368e:7c73 with SMTP id ba36-20020a056a20a6a400b000da368e7c73mr3177779pzb.37.1682627804723; Thu, 27 Apr 2023 13:36:44 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1682627804; cv=none; d=google.com; s=arc-20160816; b=ppUTfLdW7HRrbzOaVAzvJEJA6Nubb5iFskEjR5Cdu/IarDi+ThX5ADz8AXtG+5cupW l6L82gXrVyBVUjB1CCAbXM+YwgKndIiXyjgvwQMGlnR9sduZmf5IckYZ7VjHNbqZlQmW hwW7/32reEgrm1AQWY56nTZcrLA3m088lidUedLCesiIhPv1fksqGSymoVdgsUzzqbND aGcbBMSyZKawZ/Lz1bMEpJpP7EEEsKgZ+9PJe5WjY80Fu4l40Sr5EY33r82Ohgh9L5zf Ymqx3pNIGQ2mLYySTzKoV77RGySiRW86gakbPFk+blhjZSq6uQNw3fYFKrW+ubtQXx80 NYjg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:subject:content-transfer-encoding:mime-version :message-id:date:cc:to:from:dkim-signature; bh=dXVd02aZfCBZB8aqLEE5MFIo/7qfAJEue/einpiysyY=; b=kEJlXVrO0s2tCVjtOI3YQ1CvPi7zKoOTV6G5WrftCYQovBhePtrLqZX5l8l8V7hzC9 EOHIow/kp402E6S7Sp9Eywn62Mq/SJsHDLoSDFagP2qIf99NWD0O7sZdxrZY9P6x/8Vw uatY5crFkt3WSN1MtPUP97k7Ed7ExbkmXoBHsviVC/OJWaXAuwXbD1kj3fIHKtAovBBh 9l1plpxIvtlOKilptcPfHVb1tZuOySbKyg9IQ5/3zvF9N2pXzVcF36NsFvMVF/Pc4d7g iXHwdEiJuCV47QRNheyUCBfnBjNwjHfAkPiUZ9MJNchN6Zg7hJMZ2ZlzbFovizMMvpo0 vKbg== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@hugovil.com header.s=x header.b=n21snRrj; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id f16-20020a63f110000000b0051b1fe0b7besi19833295pgi.580.2023.04.27.13.36.30; Thu, 27 Apr 2023 13:36:44 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=fail header.i=@hugovil.com header.s=x header.b=n21snRrj; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1344189AbjD0UVK (ORCPT <rfc822;zxc52fgh@gmail.com> + 99 others); Thu, 27 Apr 2023 16:21:10 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:53326 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1344184AbjD0UVF (ORCPT <rfc822;linux-kernel@vger.kernel.org>); Thu, 27 Apr 2023 16:21:05 -0400 Received: from mail.hugovil.com (mail.hugovil.com [162.243.120.170]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 4D7FF3C07; Thu, 27 Apr 2023 13:21:04 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=hugovil.com ; s=x; h=Subject:Content-Transfer-Encoding:MIME-Version:Message-Id:Date:Cc:To :From:Sender:Reply-To:Content-Type:Content-ID:Content-Description:Resent-Date :Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:In-Reply-To: References:List-Id:List-Help:List-Unsubscribe:List-Subscribe:List-Post: List-Owner:List-Archive; bh=dXVd02aZfCBZB8aqLEE5MFIo/7qfAJEue/einpiysyY=; b=n 21snRrjJ5QWb8iCWg3KZrjIzkHvibayRWSiLDCdGvPoxBifQyxQebNFZqjFMYpabDHNJessUMuP67 Bjwuv+sS6bI4y3DdLbgMhswiLk+ZnqIK2wW9RYby2t9eNTGXzv06QtKL9MhIqMsIU8S/Czr5wB5uS 51F5wnX16rVfqeUc=; Received: from modemcable168.174-80-70.mc.videotron.ca ([70.80.174.168]:50478 helo=pettiford.lan) by mail.hugovil.com with esmtpa (Exim 4.92) (envelope-from <hugo@hugovil.com>) id 1ps7j4-0002gK-Fv; Thu, 27 Apr 2023 15:56:22 -0400 From: Hugo Villeneuve <hugo@hugovil.com> To: Rob Herring <robh+dt@kernel.org>, Krzysztof Kozlowski <krzysztof.kozlowski+dt@linaro.org>, Shawn Guo <shawnguo@kernel.org>, Sascha Hauer <s.hauer@pengutronix.de>, Pengutronix Kernel Team <kernel@pengutronix.de>, Fabio Estevam <festevam@gmail.com>, NXP Linux Team <linux-imx@nxp.com> Cc: Hugo Villeneuve <hvilleneuve@dimonoff.com>, devicetree@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org Date: Thu, 27 Apr 2023 15:55:38 -0400 Message-Id: <20230427195538.2718661-1-hugo@hugovil.com> X-Mailer: git-send-email 2.30.2 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-SA-Exim-Connect-IP: 70.80.174.168 X-SA-Exim-Mail-From: hugo@hugovil.com X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net X-Spam-Level: X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,SPF_HELO_PASS,SPF_PASS, T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.6 Subject: [PATCH] imx8mn-var-som: dts: fix PHY detection bug by adding deassert delay X-SA-Exim-Version: 4.2.1 (built Wed, 08 May 2019 21:11:16 +0000) X-SA-Exim-Scanned: Yes (on mail.hugovil.com) Precedence: bulk List-ID: <linux-kernel.vger.kernel.org> X-Mailing-List: linux-kernel@vger.kernel.org X-getmail-retrieved-from-mailbox: =?utf-8?q?INBOX?= X-GMAIL-THRID: =?utf-8?q?1764361702774900387?= X-GMAIL-MSGID: =?utf-8?q?1764363132954193267?= |
Series |
imx8mn-var-som: dts: fix PHY detection bug by adding deassert delay
|
|
Commit Message
Hugo Villeneuve
April 27, 2023, 7:55 p.m. UTC
From: Hugo Villeneuve <hvilleneuve@dimonoff.com> While testing the ethernet interface on a symphony carrier board using an imx8mn SOM with an onboard PHY (EC hardware configuration), the ethernet PHY is not detected. The device tree in Variscite custom linux git repository uses the following property: phy-reset-post-delay = <20>; Add a new property 'reset-deassert-us' of 20ms to have the same delay inside the ethphy phandle. Adding this property fixes the problem with the PHY detection. Signed-off-by: Hugo Villeneuve <hvilleneuve@dimonoff.com> --- arch/arm64/boot/dts/freescale/imx8mn-var-som.dtsi | 1 + 1 file changed, 1 insertion(+)
Comments
On Thu, 27 Apr 2023 17:07:59 -0300 Fabio Estevam <festevam@gmail.com> wrote: > On Thu, Apr 27, 2023 at 5:06 PM Hugo Villeneuve <hugo@hugovil.com> wrote: > > > Hi Fabio, > > it uses a ADIN1300 PHY. > > > > The datasheet indicate that the "Management interface active (t4)" state is reached at most 5ms after the reset signal is deasserted. > > Please add this information to the commit log and please add a Fixes: tag. > > Thanks Hi, I am trying to properly add a "Fixes: " tag, but the description for this tag indicates that it is to report that "the patch fixes an issue in a previous commit". In this case, I cannot identify a commit that introduced that bug, apart from the initial commit of the DTS file which didn't have the reset property present? Thank you, Hugo.
On Thu, Apr 27, 2023 at 5:22 PM Hugo Villeneuve <hugo@hugovil.com> wrote: > Hi, > I am trying to properly add a "Fixes: " tag, but the description for this tag indicates that it is to report that "the patch fixes an issue in a previous commit". > > In this case, I cannot identify a commit that introduced that bug, apart from the initial commit of the DTS file which didn't have the reset property present? You can add: Fixes: ade0176dd8a0 ("arm64: dts: imx8mn-var-som: Add Variscite VAR-SOM-MX8MN System on Module")
On Thu, Apr 27, 2023 at 04:22:51PM -0400, Hugo Villeneuve wrote: > On Thu, 27 Apr 2023 17:07:59 -0300 > Fabio Estevam <festevam@gmail.com> wrote: > > > On Thu, Apr 27, 2023 at 5:06 PM Hugo Villeneuve <hugo@hugovil.com> wrote: > > > > > Hi Fabio, > > > it uses a ADIN1300 PHY. > > > > > > The datasheet indicate that the "Management interface active (t4)" state is reached at most 5ms after the reset signal is deasserted. > > > > Please add this information to the commit log and please add a Fixes: tag. > > > > Thanks > > Hi, > I am trying to properly add a "Fixes: " tag, but the description for this tag indicates that it is to report that "the patch fixes an issue in a previous commit". > > In this case, I cannot identify a commit that introduced that bug, apart from the initial commit of the DTS file which didn't have the reset property present? Is the PHY on the SOM or the carrier? If the PHY is on the carrier, then the delay is a carrier property, and should be in the carrier .dts file. So use the commit for when the carrier DTS file was added. If the PHY is on the SOM, then use the commit for when the SOM DTSI was added. Andrew
On Thu, 27 Apr 2023 22:56:40 +0200 Andrew Lunn <andrew@lunn.ch> wrote: > On Thu, Apr 27, 2023 at 04:22:51PM -0400, Hugo Villeneuve wrote: > > On Thu, 27 Apr 2023 17:07:59 -0300 > > Fabio Estevam <festevam@gmail.com> wrote: > > > > > On Thu, Apr 27, 2023 at 5:06 PM Hugo Villeneuve <hugo@hugovil.com> wrote: > > > > > > > Hi Fabio, > > > > it uses a ADIN1300 PHY. > > > > > > > > The datasheet indicate that the "Management interface active (t4)" state is reached at most 5ms after the reset signal is deasserted. > > > > > > Please add this information to the commit log and please add a Fixes: tag. > > > > > > Thanks > > > > Hi, > > I am trying to properly add a "Fixes: " tag, but the description for this tag indicates that it is to report that "the patch fixes an issue in a previous commit". > > > > In this case, I cannot identify a commit that introduced that bug, apart from the initial commit of the DTS file which didn't have the reset property present? > > Is the PHY on the SOM or the carrier? It is on the SOM. > > If the PHY is on the carrier, then the delay is a carrier property, > and should be in the carrier .dts file. So use the commit for when the > carrier DTS file was added. > > If the PHY is on the SOM, then use the commit for when the SOM DTSI > was added. Ok, will use that. Hugo.
On Thu, 27 Apr 2023 22:16:45 +0200 Ahmad Fatoum <a.fatoum@pengutronix.de> wrote: > On 27.04.23 22:12, Hugo Villeneuve wrote: > > On Thu, 27 Apr 2023 17:07:59 -0300 > > Fabio Estevam <festevam@gmail.com> wrote: > > > >> On Thu, Apr 27, 2023 at 5:06 PM Hugo Villeneuve <hugo@hugovil.com> wrote: > >> > >>> Hi Fabio, > >>> it uses a ADIN1300 PHY. > >>> > >>> The datasheet indicate that the "Management interface active (t4)" state is reached at most 5ms after the reset signal is deasserted. > >> > >> Please add this information to the commit log and please add a Fixes: tag. > > > > Good idea, will do. > > Please also add the PHY name into the DT, e.g.: > > ethphy: ethernet-phy@4 { /* ADIN1300 */ > > I find this very useful when bringing up a new board and looking > for similar DTs. > > Thanks, > Ahmad Hi Ahmad, altough I agree it is a good idea, I prefer to not add this information for now, because there is probably some (old) versions of this SOM which use other PHY devices (maybe AR8033), but I am not 100% sure as this is not clear from the SOM manufacturer infos/website. Hugo.
Hello Hugo, On 28.04.23 00:18, Hugo Villeneuve wrote: > On Thu, 27 Apr 2023 22:16:45 +0200 > Ahmad Fatoum <a.fatoum@pengutronix.de> wrote: >> Please also add the PHY name into the DT, e.g.: >> >> ethphy: ethernet-phy@4 { /* ADIN1300 */ >> >> I find this very useful when bringing up a new board and looking >> for similar DTs. > > Hi Ahmad, > altough I agree it is a good idea, I prefer to not add this information for now, because there is probably some (old) versions of this SOM which use other PHY devices (maybe AR8033), but I am not 100% sure as this is not clear from the SOM manufacturer infos/website. /* ADIN1300 on new revisions */ would work too. Cheers, Ahmad > > Hugo. >
diff --git a/arch/arm64/boot/dts/freescale/imx8mn-var-som.dtsi b/arch/arm64/boot/dts/freescale/imx8mn-var-som.dtsi index 67072e6c77d5..9052b0d4b5b4 100644 --- a/arch/arm64/boot/dts/freescale/imx8mn-var-som.dtsi +++ b/arch/arm64/boot/dts/freescale/imx8mn-var-som.dtsi @@ -103,6 +103,7 @@ ethphy: ethernet-phy@4 { reg = <4>; reset-gpios = <&gpio1 9 GPIO_ACTIVE_LOW>; reset-assert-us = <10000>; + reset-deassert-us = <20000>; }; }; };