Message ID | 1458524230-10827-6-git-send-email-anarsoul@gmail.com |
---|---|
State | Accepted |
Commit | afed7ebe8500e6f05ac93ceb5e3f75fd193fd786 |
Delegated to: | Tom Rini |
Headers | show |
On 03/21/2016 02:37 AM, Vasily Khoruzhick wrote: Commit message is missing, NAK > Signed-off-by: Vasily Khoruzhick <anarsoul@gmail.com> > --- > board/zipitz2/zipitz2.c | 21 +++++++++++++++++++++ > include/configs/zipitz2.h | 1 + > 2 files changed, 22 insertions(+) > > diff --git a/board/zipitz2/zipitz2.c b/board/zipitz2/zipitz2.c > index 8fa1261..aefbeee 100644 > --- a/board/zipitz2/zipitz2.c > +++ b/board/zipitz2/zipitz2.c > @@ -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) > +{ Please stop the USB here, otherwise it can corrupt the memory when Linux boots. > +} > +#endif > + > void dram_init_banksize(void) > { > gd->bd->bi_dram[0].start = PHYS_SDRAM_1; > diff --git a/include/configs/zipitz2.h b/include/configs/zipitz2.h > index f69b52e..52a36b7 100644 > --- a/include/configs/zipitz2.h > +++ b/include/configs/zipitz2.h > @@ -64,6 +64,7 @@ > #define CONFIG_CMD_ENV > #define CONFIG_CMD_MMC > #define CONFIG_CMD_SPI > +#define CONFIG_CMD_USB > > /* > * MMC Card Configuration >
On Sun, Mar 20, 2016 at 06:37:05PM -0700, Vasily Khoruzhick wrote:
> Signed-off-by: Vasily Khoruzhick <anarsoul@gmail.com>
Applied to u-boot/master, thanks!
diff --git a/board/zipitz2/zipitz2.c b/board/zipitz2/zipitz2.c index 8fa1261..aefbeee 100644 --- a/board/zipitz2/zipitz2.c +++ b/board/zipitz2/zipitz2.c @@ -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; diff --git a/include/configs/zipitz2.h b/include/configs/zipitz2.h index f69b52e..52a36b7 100644 --- a/include/configs/zipitz2.h +++ b/include/configs/zipitz2.h @@ -64,6 +64,7 @@ #define CONFIG_CMD_ENV #define CONFIG_CMD_MMC #define CONFIG_CMD_SPI +#define CONFIG_CMD_USB /* * MMC Card Configuration
Signed-off-by: Vasily Khoruzhick <anarsoul@gmail.com> --- board/zipitz2/zipitz2.c | 21 +++++++++++++++++++++ include/configs/zipitz2.h | 1 + 2 files changed, 22 insertions(+)