[U-Boot] [PATCH] arm: socfpga: Enable ethernet PHY configuration to RGMII again

Stefan Roese sr at denx.de
Thu Feb 11 16:45:13 CET 2016


With commit c32a6fd0 [net: Don't call board/cpu_eth_init() with driver
model], cpu_eth_init() is not called on SoCFPGA any more. Since this
function configures the internal PHY interface to RGMII (via the physel_X
bits), its still needed. So lets rename this function and call it in
arch_early_init_r().

Tested on socfpga_sr1500.

Signed-off-by: Stefan Roese <sr at denx.de>
Cc: Simon Glass <sjg at chromium.org>
Cc: Dinh Nguyen <dinguyen at opensource.altera.com>
Cc: Marek Vasut <marex at denx.de>
---
 arch/arm/mach-socfpga/misc.c | 6 +++++-
 1 file changed, 5 insertions(+), 1 deletion(-)

diff --git a/arch/arm/mach-socfpga/misc.c b/arch/arm/mach-socfpga/misc.c
index 9b43b92..2b1cd4a 100644
--- a/arch/arm/mach-socfpga/misc.c
+++ b/arch/arm/mach-socfpga/misc.c
@@ -104,7 +104,7 @@ static void dwmac_deassert_reset(const unsigned int of_reset_id)
 	socfpga_per_reset(reset, 0);
 }
 
-int cpu_eth_init(bd_t *bis)
+static int dwmac_eth_init(void)
 {
 	const void *fdt = gd->fdt_blob;
 	struct fdtdec_phandle_args args;
@@ -363,6 +363,10 @@ int arch_early_init_r(void)
 	socfpga_per_reset(SOCFPGA_RESET(NAND), 0);
 #endif
 
+#ifdef CONFIG_ETH_DESIGNWARE
+	dwmac_eth_init();
+#endif
+
 	return 0;
 }
 
-- 
2.7.1



More information about the U-Boot mailing list