From 798fa99abc9ce732938253d759d05b8fd039ff85 Mon Sep 17 00:00:00 2001 From: Samin Guo Date: Thu, 20 Apr 2023 09:18:07 +0800 Subject: [PATCH 1/3] riscv: dts: starfive: vf2: add Pad Drive Strength Cfg Increase the drive strength of rx_clk to increase the delay available window. Signed-off-by: Samin Guo --- arch/riscv/dts/starfive_visionfive2.dts | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/arch/riscv/dts/starfive_visionfive2.dts b/arch/riscv/dts/starfive_visionfive2.dts index fb00079b8c..a5fe92a2b5 100644 --- a/arch/riscv/dts/starfive_visionfive2.dts +++ b/arch/riscv/dts/starfive_visionfive2.dts @@ -314,6 +314,9 @@ #address-cells = <1>; #size-cells = <0>; phy0: ethernet-phy@0 { + rgmii_sw_dr_2 = <0x0>; + rgmii_sw_dr = <0x3>; + rgmii_sw_dr_rxc = <0x6>; rxc_dly_en = <1>; tx_delay_sel_fe = <5>; tx_delay_sel = <0xa>; @@ -328,6 +331,9 @@ #address-cells = <1>; #size-cells = <0>; phy1: ethernet-phy@1 { + rgmii_sw_dr_2 = <0x0>; + rgmii_sw_dr = <0x3>; + rgmii_sw_dr_rxc = <0x6>; tx_delay_sel_fe = <5>; tx_delay_sel = <0>; rxc_dly_en = <0>; From 63cac2a17fcb8748b9b0e31bc212bf15253cfd8f Mon Sep 17 00:00:00 2001 From: Samin Guo Date: Thu, 20 Apr 2023 09:18:50 +0800 Subject: [PATCH 2/3] riscv: dts: starfive: vf2: set gmac0 rx delay to 1500ps set gmac0 rx delay to 1500ps to to match better delays. Signed-off-by: Samin Guo --- arch/riscv/dts/starfive_visionfive2.dts | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/arch/riscv/dts/starfive_visionfive2.dts b/arch/riscv/dts/starfive_visionfive2.dts index a5fe92a2b5..5293cdbae6 100644 --- a/arch/riscv/dts/starfive_visionfive2.dts +++ b/arch/riscv/dts/starfive_visionfive2.dts @@ -317,7 +317,8 @@ rgmii_sw_dr_2 = <0x0>; rgmii_sw_dr = <0x3>; rgmii_sw_dr_rxc = <0x6>; - rxc_dly_en = <1>; + rxc_dly_en = <0>; + rx_delay_sel = <0xa>; tx_delay_sel_fe = <5>; tx_delay_sel = <0xa>; tx_inverted_10 = <0x1>; From c3df27a0d1d7cb7cfd4b19117fcb5dc224231a47 Mon Sep 17 00:00:00 2001 From: Samin Guo Date: Thu, 20 Apr 2023 11:25:57 +0800 Subject: [PATCH 3/3] riscv: dts: starfive: vf2: set gmac1 rx delay to 300ps set gmac1 rx delay to 300ps to to match better delays. Signed-off-by: Samin Guo --- arch/riscv/dts/starfive_visionfive2.dts | 1 + 1 file changed, 1 insertion(+) diff --git a/arch/riscv/dts/starfive_visionfive2.dts b/arch/riscv/dts/starfive_visionfive2.dts index 5293cdbae6..d0268fbfeb 100644 --- a/arch/riscv/dts/starfive_visionfive2.dts +++ b/arch/riscv/dts/starfive_visionfive2.dts @@ -338,6 +338,7 @@ tx_delay_sel_fe = <5>; tx_delay_sel = <0>; rxc_dly_en = <0>; + rx_delay_sel = <0x2>; tx_inverted_10 = <0x1>; tx_inverted_100 = <0x1>; tx_inverted_1000 = <0x0>;