
We enable this feature on all UARTs for Seaboard. This ensures that a message is printed if CONFIG_OF_CONTROL is in use and a value device tree is not available.
Signed-off-by: Simon Glass sjg@chromium.org --- board/nvidia/seaboard/seaboard.c | 18 ++++++++++++++++++ 1 files changed, 18 insertions(+), 0 deletions(-)
diff --git a/board/nvidia/seaboard/seaboard.c b/board/nvidia/seaboard/seaboard.c index 94efb1e..3f69dfc 100644 --- a/board/nvidia/seaboard/seaboard.c +++ b/board/nvidia/seaboard/seaboard.c @@ -24,6 +24,7 @@ #include <common.h> #include <asm/io.h> #include <asm/arch/tegra2.h> +#include <asm/arch/board.h> #include <asm/arch/clock.h> #include <asm/arch/funcmux.h> #include <asm/arch/pinmux.h> @@ -96,3 +97,20 @@ void pin_mux_usb(void) /* For USB's GPIO PD0. For now, since we have no pinmux in fdt */ pinmux_tristate_disable(PINGRP_SLXK); } + +/* + * This is called when we have no console. About the only reason that this + * happen is if we don't have a valid fdt. So we don't know what kind of + * Tegra board we are. We blindly try to print a message every which way we + * know. + */ +void board_pre_console_panic(const char *str) +{ + /* Seaboard has a UART switch on PI3 */ +#ifdef CONFIG_SPI_UART_SWITCH + gpio_direction_output(GPIO_PI3, 0); +#endif + + tegra_pre_console_panic(TEGRA_UART_ALL, CONFIG_DEFAULT_NS16550_CLK, + CONFIG_DEFAULT_NS16550_MULT, str); +}