[U-Boot] [PATCH 7/7] arm: mvebu: helios4: Reset uSOM onboard phy during board init

Aditya Prayoga aditya at kobol.io
Wed Nov 28 09:00:39 UTC 2018


Similar to Clearfog rev 2.1, GPIO 19 also used to reset onboard ethernet
PHY.

Signed-off-by: Aditya Prayoga <aditya at kobol.io>
---
 board/kobol/helios4/helios4.c | 7 +++++++
 1 file changed, 7 insertions(+)

diff --git a/board/kobol/helios4/helios4.c b/board/kobol/helios4/helios4.c
index 37c46a5..7c1a7a8 100644
--- a/board/kobol/helios4/helios4.c
+++ b/board/kobol/helios4/helios4.c
@@ -114,6 +114,13 @@ int board_init(void)
 	/* Address of boot parameters */
 	gd->bd->bi_boot_params = mvebu_sdram_bar(0) + 0x100;
 
+	/* GPIO 19 controls the uSOM onboard phy reset */
+	clrbits_le32(MVEBU_GPIO0_BASE + 0x0, BIT(19));
+	clrbits_le32(MVEBU_GPIO0_BASE + 0x4, BIT(19));
+	mdelay(1);
+	setbits_le32(MVEBU_GPIO0_BASE + 0x0, BIT(19));
+	mdelay(10);
+
 	return 0;
 }
 
-- 
2.7.4



More information about the U-Boot mailing list