]> git.sur5r.net Git - u-boot/commitdiff
zipitz2: enable USB host support
authorVasily Khoruzhick <anarsoul@gmail.com>
Mon, 21 Mar 2016 01:37:05 +0000 (18:37 -0700)
committerTom Rini <trini@konsulko.com>
Sun, 27 Mar 2016 13:12:58 +0000 (09:12 -0400)
Signed-off-by: Vasily Khoruzhick <anarsoul@gmail.com>
board/zipitz2/zipitz2.c
include/configs/zipitz2.h

index 8fa12618ad3ebfba902a2921a525ee515e7e4ed6..aefbeee89433cdb663a75653e176d861921aee03 100644 (file)
@@ -15,6 +15,7 @@
 #include <asm/arch/regs-mmc.h>
 #include <spi.h>
 #include <asm/io.h>
+#include <usb.h>
 
 DECLARE_GLOBAL_DATA_PTR;
 
@@ -52,6 +53,26 @@ int dram_init(void)
        return 0;
 }
 
+#ifdef CONFIG_CMD_USB
+int board_usb_init(int index, enum usb_init_type init)
+{
+       /* enable port 2 */
+       writel(readl(UP2OCR) | UP2OCR_HXOE | UP2OCR_HXS |
+               UP2OCR_DMPDE | UP2OCR_DPPDE, UP2OCR);
+
+       return 0;
+}
+
+int board_usb_cleanup(int index, enum usb_init_type init)
+{
+       return 0;
+}
+
+void usb_board_stop(void)
+{
+}
+#endif
+
 void dram_init_banksize(void)
 {
        gd->bd->bi_dram[0].start = PHYS_SDRAM_1;
index f69b52eabf6cbdffc40e79d096428c7f3b7e5083..52a36b7e547d0087af3046ac63fb1f84ffd4fb89 100644 (file)
@@ -64,6 +64,7 @@
 #define        CONFIG_CMD_ENV
 #define        CONFIG_CMD_MMC
 #define        CONFIG_CMD_SPI
+#define        CONFIG_CMD_USB
 
 /*
  * MMC Card Configuration