On 07/04/2021 16:21, Stefan Agner wrote: > On 2021-04-07 15:31, Neil Armstrong wrote: >> Hi, >> >> On 06/04/2021 19:47, Stefan Agner wrote: >>> The sync of the device tree and dt-bindings from Linux v5.6-rc2 >>> 11a48a5a18c6 ("Linux 5.6-rc2") causes Ethernet to break on some >>> ODROID-C2. >>> >>> Meanwhile a fix to increase the reset timing has been added to Linux. >>> Instead of reverting the offending commit, use the new reset timing >>> from upstream Linux commit c183c406c432 ("arm64: dts: meson: fix PHY >>> deassert timing requirements"). >>> >>> Fixes: dd5f2351e99a ("arm64: dts: meson: sync dt and bindings from >>> v5.6-rc2") >>> Signed-off-by: Stefan Agner <ste...@agner.ch> >>> --- >>> arch/arm/dts/meson-g12b-odroid-n2.dtsi | 2 +- >>> arch/arm/dts/meson-gxbb-nanopi-k2.dts | 2 +- >>> arch/arm/dts/meson-gxbb-odroidc2.dts | 2 +- >>> arch/arm/dts/meson-gxm-khadas-vim2.dts | 2 +- >>> 4 files changed, 4 insertions(+), 4 deletions(-) >>> >>> diff --git a/arch/arm/dts/meson-g12b-odroid-n2.dtsi >>> b/arch/arm/dts/meson-g12b-odroid-n2.dtsi >>> index 6982632ae6..39a09661c5 100644 >>> --- a/arch/arm/dts/meson-g12b-odroid-n2.dtsi >>> +++ b/arch/arm/dts/meson-g12b-odroid-n2.dtsi >>> @@ -413,7 +413,7 @@ >>> max-speed = <1000>; >>> >>> reset-assert-us = <10000>; >>> - reset-deassert-us = <30000>; >>> + reset-deassert-us = <80000>; >> >> In fact, these are not used by current U-boot, support for >> reset/deassert in PHY node >> is not yet supported in U-Boot. This first step was to switch to >> DM_MDIO and use the >> proper Designware glue, the second step is to find how to make use of >> these properties. > > Hm, that is strange, I have users reporting that this patch fixes the > issue on their devices. I guess it might be that the problem does not > always appear and it was just (bad) luck. > >> >> Concerning the patch, I'll prefer you sync the DT with v5.11 instead. > > We have multiple reports of non-working ODROID-C2 which worked in > previous U-Boot releases: > https://github.com/home-assistant/operating-system/issues/1202 > > Similar reports exist in Armbian Forums as well. > > Until we have proper PHY reset/deassert support, I'd suggest to revert > dd5f2351e99a ("arm64: dts: meson: sync dt and bindings from v5.6-rc2") > partially then...
Reverting this is clearly not a solution, the intermediate solution is to put back the previous reset properties like it was done for multiple boards like in arch/arm/dts/meson-sm1-odroid-c4-u-boot.dtsi : ========================================================================== diff --git a/arch/arm/dts/meson-gxbb-odroidc2-u-boot.dtsi b/arch/arm/dts/meson-gxbb-odroidc2-u-boot.dtsi index 90087b00db..f1e6914351 100644 --- a/arch/arm/dts/meson-gxbb-odroidc2-u-boot.dtsi +++ b/arch/arm/dts/meson-gxbb-odroidc2-u-boot.dtsi @@ -29,6 +29,12 @@ }; }; +ðmac { + snps,reset-gpio = <&gpio GPIOZ_14 0>; + snps,reset-delays-us = <0 10000 1000000>; + snps,reset-active-low; +}; + &usb0 { status = "disabled"; }; ========================================================================== Neil > > -- > Stefan > > >> >> Neil >> >>> reset-gpios = <&gpio GPIOZ_15 (GPIO_ACTIVE_LOW | >>> GPIO_OPEN_DRAIN)>; >>> >>> interrupt-parent = <&gpio_intc>; >>> diff --git a/arch/arm/dts/meson-gxbb-nanopi-k2.dts >>> b/arch/arm/dts/meson-gxbb-nanopi-k2.dts >>> index 7be3e35409..de27beafe9 100644 >>> --- a/arch/arm/dts/meson-gxbb-nanopi-k2.dts >>> +++ b/arch/arm/dts/meson-gxbb-nanopi-k2.dts >>> @@ -165,7 +165,7 @@ >>> reg = <0>; >>> >>> reset-assert-us = <10000>; >>> - reset-deassert-us = <30000>; >>> + reset-deassert-us = <80000>; >>> reset-gpios = <&gpio GPIOZ_14 GPIO_ACTIVE_LOW>; >>> >>> interrupt-parent = <&gpio_intc>; >>> diff --git a/arch/arm/dts/meson-gxbb-odroidc2.dts >>> b/arch/arm/dts/meson-gxbb-odroidc2.dts >>> index 70fcfb7b06..50de1d01e5 100644 >>> --- a/arch/arm/dts/meson-gxbb-odroidc2.dts >>> +++ b/arch/arm/dts/meson-gxbb-odroidc2.dts >>> @@ -200,7 +200,7 @@ >>> reg = <0>; >>> >>> reset-assert-us = <10000>; >>> - reset-deassert-us = <30000>; >>> + reset-deassert-us = <80000>; >>> reset-gpios = <&gpio GPIOZ_14 GPIO_ACTIVE_LOW>; >>> >>> interrupt-parent = <&gpio_intc>; >>> diff --git a/arch/arm/dts/meson-gxm-khadas-vim2.dts >>> b/arch/arm/dts/meson-gxm-khadas-vim2.dts >>> index bff8ec2c1c..e38d9e50ca 100644 >>> --- a/arch/arm/dts/meson-gxm-khadas-vim2.dts >>> +++ b/arch/arm/dts/meson-gxm-khadas-vim2.dts >>> @@ -194,7 +194,7 @@ >>> reg = <0>; >>> >>> reset-assert-us = <10000>; >>> - reset-deassert-us = <30000>; >>> + reset-deassert-us = <80000>; >>> reset-gpios = <&gpio GPIOZ_14 GPIO_ACTIVE_LOW>; >>> >>> interrupt-parent = <&gpio_intc>; >>>