diff options
author | Stefan Reinauer <reinauer@google.com> | 2011-04-26 23:47:04 +0000 |
---|---|---|
committer | Stefan Reinauer <stepan@openbios.org> | 2011-04-26 23:47:04 +0000 |
commit | 4885daadb33bea37ef3970696d3cf0d05e9852a3 (patch) | |
tree | 9b068b5645f5aa60fd310919c0a08ce3dea34b3f /src/cpu/x86/smm | |
parent | 3187d0267d4b456eb43bca21a817c78687d6f73b (diff) | |
download | coreboot-4885daadb33bea37ef3970696d3cf0d05e9852a3.tar.xz |
Add support for memory mapped UARTs to coreboot and add the OXPCIe952 as an
example.
This newer version reflects the recent changes to further simplify the console
code and partly gets rid of some hacks in the previous version.
Signed-off-by: Stefan Reinauer <reinauer@google.com>
Acked-by: Peter Stuge <peter@stuge.se>
git-svn-id: svn://svn.coreboot.org/coreboot/trunk@6544 2b7e53f0-3cfb-0310-b3e9-8179ed1497e1
Diffstat (limited to 'src/cpu/x86/smm')
-rw-r--r-- | src/cpu/x86/smm/smiutil.c | 13 |
1 files changed, 12 insertions, 1 deletions
diff --git a/src/cpu/x86/smm/smiutil.c b/src/cpu/x86/smm/smiutil.c index cf951f4518..d9057d813a 100644 --- a/src/cpu/x86/smm/smiutil.c +++ b/src/cpu/x86/smm/smiutil.c @@ -26,7 +26,7 @@ #include <console/console.h> #include <console/vtxprintf.h> -#if CONFIG_CONSOLE_SERIAL8250 +#if CONFIG_CONSOLE_SERIAL8250 || CONFIG_CONSOLE_SERIAL8250MEM #include <uart8250.h> #endif #if CONFIG_USBDEBUG @@ -36,6 +36,10 @@ #include <console/ne2k.h> #endif +#if CONFIG_CONSOLE_SERIAL8250MEM +static u32 serial8250mem_base_address = 0; +#endif + void console_tx_flush(void) { // the tx_byte functions take care of the flush. @@ -47,6 +51,10 @@ void console_tx_byte(unsigned char byte) if (byte == '\n') console_tx_byte('\r'); +#if CONFIG_CONSOLE_SERIAL8250MEM + if (serial8250mem_base_address) + uart8250_mem_tx_byte(serial8250mem_base_address, byte); +#endif #if CONFIG_CONSOLE_SERIAL8250 uart8250_tx_byte(CONFIG_TTYS0_BASE, byte); #endif @@ -65,6 +73,9 @@ void console_init(void) #if CONFIG_CONSOLE_SERIAL8250 uart_init(); #endif +#if CONFIG_CONSOLE_SERIAL8250MEM + serial8250mem_base_address = uart_mem_init(); +#endif #else console_loglevel = 1; #endif |