summaryrefslogtreecommitdiff
path: root/board
diff options
context:
space:
mode:
authorTom Rini <trini@ti.com>2014-11-11 16:59:25 -0500
committerTom Rini <trini@ti.com>2014-11-11 16:59:25 -0500
commit6841deb6209ee420b7bcb6e320a8a06fd57658df (patch)
treefd00ae8121b49d33b1f02437cfee50ad1df0adaa /board
parent63f7af9a4cfb4a3b9136674c6612c6d13957c2cd (diff)
parent6a559bbe2f60ab64e28662f7ab52551a2eaa7163 (diff)
Merge branch 'master' of git://git.denx.de/u-boot-usb
Diffstat (limited to 'board')
-rw-r--r--board/altera/socfpga/socfpga_cyclone5.c21
1 files changed, 21 insertions, 0 deletions
diff --git a/board/altera/socfpga/socfpga_cyclone5.c b/board/altera/socfpga/socfpga_cyclone5.c
index 0f81d899a6..ce625e54d0 100644
--- a/board/altera/socfpga/socfpga_cyclone5.c
+++ b/board/altera/socfpga/socfpga_cyclone5.c
@@ -8,6 +8,10 @@
#include <asm/arch/reset_manager.h>
#include <asm/io.h>
+#include <usb.h>
+#include <usb/s3c_udc.h>
+#include <usb_mass_storage.h>
+
#include <netdev.h>
DECLARE_GLOBAL_DATA_PTR;
@@ -39,3 +43,20 @@ int board_init(void)
return 0;
}
+
+#ifdef CONFIG_USB_GADGET
+struct s3c_plat_otg_data socfpga_otg_data = {
+ .regs_otg = CONFIG_USB_DWC2_REG_ADDR,
+ .usb_gusbcfg = 0x1417,
+};
+
+int board_usb_init(int index, enum usb_init_type init)
+{
+ return s3c_udc_probe(&socfpga_otg_data);
+}
+
+int g_dnl_board_usb_cable_connected(void)
+{
+ return 1;
+}
+#endif