aboutsummaryrefslogtreecommitdiffstats
path: root/roms/u-boot/board/sr1500/socfpga.c
diff options
context:
space:
mode:
Diffstat (limited to 'roms/u-boot/board/sr1500/socfpga.c')
-rw-r--r--roms/u-boot/board/sr1500/socfpga.c28
1 files changed, 28 insertions, 0 deletions
diff --git a/roms/u-boot/board/sr1500/socfpga.c b/roms/u-boot/board/sr1500/socfpga.c
new file mode 100644
index 000000000..d9125a76b
--- /dev/null
+++ b/roms/u-boot/board/sr1500/socfpga.c
@@ -0,0 +1,28 @@
+// SPDX-License-Identifier: GPL-2.0+
+/*
+ * Copyright (C) 2015 Stefan Roese <sr@denx.de>
+ */
+
+#include <common.h>
+#include <init.h>
+#include <asm/arch/reset_manager.h>
+#include <asm/gpio.h>
+#include <asm/io.h>
+#include <linux/delay.h>
+
+int board_early_init_f(void)
+{
+ int ret;
+
+ /* Reset the Marvell PHY 88E1510 */
+ ret = gpio_request(63, "PHY reset");
+ if (ret)
+ return ret;
+
+ gpio_direction_output(63, 0);
+ mdelay(1);
+ gpio_set_value(63, 1);
+ mdelay(10);
+
+ return 0;
+}