From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from phobos.denx.de (phobos.denx.de [85.214.62.61]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id DE377EB64DC for ; Tue, 11 Jul 2023 19:40:33 +0000 (UTC) Received: from h2850616.stratoserver.net (localhost [IPv6:::1]) by phobos.denx.de (Postfix) with ESMTP id A2B568621A; Tue, 11 Jul 2023 21:40:31 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=posteo.net Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=u-boot-bounces@lists.denx.de Authentication-Results: phobos.denx.de; dkim=pass (2048-bit key; secure) header.d=posteo.net header.i=@posteo.net header.b="WgNgeW8G"; dkim-atps=neutral Received: by phobos.denx.de (Postfix, from userid 109) id 8EDE7861E1; Tue, 11 Jul 2023 21:40:29 +0200 (CEST) Received: from mout02.posteo.de (mout02.posteo.de [185.67.36.66]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) (No client certificate requested) by phobos.denx.de (Postfix) with ESMTPS id 20303861E1 for ; Tue, 11 Jul 2023 21:40:22 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=posteo.net Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=retpolanne@posteo.net Received: from submission (posteo.de [185.67.36.169]) by mout02.posteo.de (Postfix) with ESMTPS id B87BC240108 for ; Tue, 11 Jul 2023 21:40:21 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=posteo.net; s=2017; t=1689104421; bh=g9k1FRid3+liwP5dvPwlB6jEAO2KiyUjZz0Y5JaBXKk=; h=MIME-Version:Content-Transfer-Encoding:Date:From:To:Cc:Subject: Message-ID:From; b=WgNgeW8GE9caqIlxZWKScMY+xdettUubAAINe9SzXKXChgT73vbW8ZC2VLX6H+5gb BUvD4tB/9IT6df4EdUcffJu1QgbgEW9mfrhhuubS1GMHkvT1WidPzsKv1AT8zsL8wg J8CCQcUrGnsftYjoLpHgKoJLFT3sqStG2r3iqQY3gvcdJ3t2OQR6Hpb+LTHJv4lYjS DesUFaIYqN4vwRY4Dq7+S65I4uR3VYahIMDxOMGtwvNtsqjLyt1rtX3e0TNsPJiYNq P07IVP/62ttgurlzCqdpoU78A1wxXWgI/sFNKauS9Nw6CXX35BElONa8irSRphda0F Yb9e6ORH5KLpw== Received: from customer (localhost [127.0.0.1]) by submission (posteo.de) with ESMTPSA id 4R0rnK15fJz6tw4; Tue, 11 Jul 2023 21:40:21 +0200 (CEST) MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII; format=flowed Content-Transfer-Encoding: 7bit Date: Tue, 11 Jul 2023 19:40:21 +0000 From: Anne Macedo To: Jagan Teki Cc: u-boot@lists.denx.de, linux-sunxi@lists.linux.dev Subject: Re: [PATCH] sunxi: H6: Enable Ethernet on Orange Pi One Plus In-Reply-To: <20230711003957.658805-2-retpolanne@posteo.net> References: <20230711003957.658805-2-retpolanne@posteo.net> Message-ID: <30debca8b31ed4d2cbd64850d48b81ac@posteo.net> X-BeenThere: u-boot@lists.denx.de X-Mailman-Version: 2.1.39 Precedence: list List-Id: U-Boot discussion List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: u-boot-bounces@lists.denx.de Sender: "U-Boot" X-Virus-Scanned: clamav-milter 0.103.8 at phobos.denx.de X-Virus-Status: Clean On 11.07.2023 02:39, Anne Macedo wrote: > Enable Ethernet on Orange Pi One Plus by using the correct phy for > Realtek RTL8211E instead of the Generic One. Also use CONFIG_MACPWR to > turn on ethernet on startup. > > After this patch is applied, a few issues can be seen: > > - there's still a PHY reset timed out error that doesn't seem to cause > any impacts to the overall connection > > - sometimes the emac driver times out after reset (yellow LED turns on > and never blinks) > > For future patches: for now, CONFIG_MACPWR is the only way to enable > Ethernet on boot. There's already code on the dts for using the > 3v3-gmac > regulator. However, it is not probed on boot, so it only starts after a > "regulator status" command is issued. > > More details about the troubleshooting on [1]. > > [1] > https://lore.kernel.org/u-boot/4wsvwgy56e2xfgtvioru2tf2ofkqprlts36qggivxogww6pn5j@4jk63zxhzhag/ > > Signed-off-by: Anne Macedo > --- > arch/arm/dts/sun50i-h6-orangepi-one-plus.dts | 2 +- > configs/orangepi_one_plus_defconfig | 4 ++++ > 2 files changed, 5 insertions(+), 1 deletion(-) > > diff --git a/arch/arm/dts/sun50i-h6-orangepi-one-plus.dts > b/arch/arm/dts/sun50i-h6-orangepi-one-plus.dts > index 29a081e72a..6427c58f8a 100644 > --- a/arch/arm/dts/sun50i-h6-orangepi-one-plus.dts > +++ b/arch/arm/dts/sun50i-h6-orangepi-one-plus.dts > @@ -37,7 +37,7 @@ > > &mdio { > ext_rgmii_phy: ethernet-phy@1 { > - compatible = "ethernet-phy-ieee802.3-c22"; > + compatible = "ethernet-phy-id001c.c915", > "ethernet-phy-ieee802.3-c22" ; > reg = <1>; > }; > }; > diff --git a/configs/orangepi_one_plus_defconfig > b/configs/orangepi_one_plus_defconfig > index aa5f540eb1..a1835492db 100644 > --- a/configs/orangepi_one_plus_defconfig > +++ b/configs/orangepi_one_plus_defconfig > @@ -8,3 +8,7 @@ CONFIG_SUNXI_DRAM_H6_LPDDR3=y > # CONFIG_SYS_MALLOC_CLEAR_ON_INIT is not set > CONFIG_USB_EHCI_HCD=y > CONFIG_USB_OHCI_HCD=y > +CONFIG_SUN8I_EMAC=y > +CONFIG_PHY_REALTEK=y > +CONFIG_PHY_ETHERNET_ID=y > +CONFIG_MACPWR="PD6" Adding linux-sunxi to the thread (I unfortunately forgot this list)