summaryrefslogtreecommitdiff
path: root/board/trizepsiv/conxs.c
diff options
context:
space:
mode:
Diffstat (limited to 'board/trizepsiv/conxs.c')
-rw-r--r--board/trizepsiv/conxs.c27
1 files changed, 15 insertions, 12 deletions
diff --git a/board/trizepsiv/conxs.c b/board/trizepsiv/conxs.c
index 5c0eb41..8c11456 100644
--- a/board/trizepsiv/conxs.c
+++ b/board/trizepsiv/conxs.c
@@ -44,13 +44,18 @@ extern struct serial_device serial_ffuart_device;
extern struct serial_device serial_btuart_device;
extern struct serial_device serial_stuart_device;
+#if CONFIG_POLARIS
+#define BOOT_CONSOLE "serial_stuart"
+#else
+#define BOOT_CONSOLE "serial_ffuart"
+#endif
/* ------------------------------------------------------------------------- */
/*
* Miscelaneous platform dependent initialisations
*/
-void usb_board_init(void)
+int usb_board_init(void)
{
UHCHR = (UHCHR | UHCHR_PCPL | UHCHR_PSPL) &
~(UHCHR_SSEP0 | UHCHR_SSEP1 | UHCHR_SSEP2 | UHCHR_SSE);
@@ -71,6 +76,8 @@ void usb_board_init(void)
/* Set port power control mask bits, only 3 ports. */
UHCRHDB |= (0x7<<17);
+
+ return 0;
}
void usb_board_init_fail(void)
@@ -89,7 +96,6 @@ void usb_board_stop(void)
CKEN &= ~CKEN10_USBHOST;
- puts("Called USB STOP\n");
return;
}
@@ -112,17 +118,14 @@ int board_late_init(void)
#if defined(CONFIG_SERIAL_MULTI)
char *console=getenv("boot_console");
- if ((strcmp(console,"serial_btuart") == 0) ||
- (strcmp(console,"serial_stuart") == 0) ||
- (strcmp(console,"serial_ffuart") == 0)) {
- setenv("stdout",console);
- setenv("stdin", console);
- setenv("stderr",console);
- } else {
- setenv("stdout", "serial");
- setenv("stdin", "serial");
- setenv("stderr", "serial");
+ if ((console == NULL) || (strcmp(console,"serial_btuart") &&
+ strcmp(console,"serial_stuart") &&
+ strcmp(console,"serial_ffuart"))) {
+ console = BOOT_CONSOLE;
}
+ setenv("stdout",console);
+ setenv("stdin", console);
+ setenv("stderr",console);
#endif
return 0;
}