diff options
author | Hung-Te Lin <hungte@chromium.org> | 2013-02-06 22:01:18 +0800 |
---|---|---|
committer | Stefan Reinauer <stefan.reinauer@coreboot.org> | 2013-02-08 03:24:09 +0100 |
commit | b868d40830787ba5a92721d131c38165285b7795 (patch) | |
tree | 382cf2dbf7896d9e370a1361797a72bd35540882 /src/mainboard | |
parent | 580fa2bf316d4796e5ed76cbbd3e454479fb0688 (diff) | |
download | coreboot-b868d40830787ba5a92721d131c38165285b7795.tar.xz |
armv7: Use same console initialization procedure for all ARM stages
Use same console initialization procedure for all ARM stages (bootblock,
romstage, and ramstage):
#include <console/console.h>
...
console_init()
...
printk(level, format, ...)
Verified to boot on armv7/snow with console messages in all stages.
Change-Id: Idd689219035e67450ea133838a2ca02f8d74557e
Signed-off-by: Hung-Te Lin <hungte@chromium.org>
Signed-off-by: David Hendricks <dhendrix@chromium.org>
Reviewed-on: http://review.coreboot.org/2301
Tested-by: build bot (Jenkins)
Reviewed-by: Stefan Reinauer <stefan.reinauer@coreboot.org>
Diffstat (limited to 'src/mainboard')
-rw-r--r-- | src/mainboard/google/snow/bootblock.c | 16 | ||||
-rw-r--r-- | src/mainboard/google/snow/ramstage.c | 4 |
2 files changed, 8 insertions, 12 deletions
diff --git a/src/mainboard/google/snow/bootblock.c b/src/mainboard/google/snow/bootblock.c index b57b6c3533..00e97c1674 100644 --- a/src/mainboard/google/snow/bootblock.c +++ b/src/mainboard/google/snow/bootblock.c @@ -17,18 +17,18 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA */ -#if CONFIG_EARLY_CONSOLE #include <types.h> #include <arch/io.h> -#include <cbfs.h> -#include <uart.h> -#include <console/console.h> +#include <device/i2c.h> #include <cpu/samsung/exynos5250/clk.h> #include <cpu/samsung/exynos5250/dmc.h> #include <cpu/samsung/exynos5250/periph.h> #include <cpu/samsung/exynos5250/clock_init.h> +#include <src/cpu/samsung/exynos5250/power.h> +#include <drivers/maxim/max77686/max77686.h> +#include <console/console.h> -#endif +#define I2C0_BASE 0x12c60000 void bootblock_mainboard_init(void); void bootblock_mainboard_init(void) @@ -39,10 +39,8 @@ void bootblock_mainboard_init(void) mem = get_mem_timings(); arm_ratios = get_arm_clk_ratios(); system_clock_init(mem, arm_ratios); - -#if CONFIG_EARLY_CONSOLE exynos_pinmux_config(PERIPH_ID_UART3, PINMUX_FLAG_NONE); - uart_init(); + + console_init(); printk(BIOS_INFO, "\n\n\n%s: UART initialized\n", __func__); -#endif } diff --git a/src/mainboard/google/snow/ramstage.c b/src/mainboard/google/snow/ramstage.c index 50050d37a5..f9d9c9600c 100644 --- a/src/mainboard/google/snow/ramstage.c +++ b/src/mainboard/google/snow/ramstage.c @@ -24,9 +24,7 @@ void main(void) // volatile unsigned long *pshold = (unsigned long *)0x1004330c; // *pshold &= ~0x100; /* shut down */ - /* FIXME: console_init() seems to cause things to die... Maybe - we need to reset our stack pointer? */ -// console_init(); + console_init(); printk(BIOS_INFO, "hello from ramstage\n"); while (1); } |