Eric Biederman | 8ca8d76 | 2003-04-22 19:02:15 +0000 | [diff] [blame] | 1 | #include <console/loglevel.h> |
2 | |||||
Yinghai Lu | 5f9624d | 2006-10-04 22:56:21 +0000 | [diff] [blame] | 3 | #if CONFIG_USE_PRINTK_IN_CAR == 0 |
Eric Biederman | 8ca8d76 | 2003-04-22 19:02:15 +0000 | [diff] [blame] | 4 | static void __console_tx_byte(unsigned char byte) |
5 | { | ||||
6 | uart_tx_byte(byte); | ||||
7 | } | ||||
8 | |||||
Carl-Daniel Hailfinger | a81bb03 | 2007-03-02 14:21:09 +0000 | [diff] [blame] | 9 | #include "console_print.c" |
Eric Biederman | 8ca8d76 | 2003-04-22 19:02:15 +0000 | [diff] [blame] | 10 | |
Stefan Reinauer | 7ce8c54 | 2005-12-02 21:52:30 +0000 | [diff] [blame] | 11 | #else |
Yinghai Lu | 30b4abe | 2007-04-06 19:57:42 +0000 | [diff] [blame] | 12 | /* CONFIG_USE_PRINTK_IN_CAR == 1 */ |
arch import user (historical) | 6ca7636 | 2005-07-06 17:17:25 +0000 | [diff] [blame] | 13 | |
Carl-Daniel Hailfinger | a81bb03 | 2007-03-02 14:21:09 +0000 | [diff] [blame] | 14 | #include "console_printk.c" |
arch import user (historical) | 6ca7636 | 2005-07-06 17:17:25 +0000 | [diff] [blame] | 15 | |
Yinghai Lu | 30b4abe | 2007-04-06 19:57:42 +0000 | [diff] [blame] | 16 | // do_printk |
17 | #include "../../../console/vtxprintf.c" | ||||
18 | #include "printk_init.c" | ||||
19 | |||||
20 | #endif /* CONFIG_USE_PRINTK_IN_CAR */ | ||||
Eric Biederman | 69afe28 | 2004-11-11 06:53:24 +0000 | [diff] [blame] | 21 | |
Stefan Reinauer | f8ee180 | 2008-01-18 15:08:58 +0000 | [diff] [blame^] | 22 | #ifndef COREBOOT_EXTRA_VERSION |
23 | #define COREBOOT_EXTRA_VERSION "" | ||||
Eric Biederman | 8ca8d76 | 2003-04-22 19:02:15 +0000 | [diff] [blame] | 24 | #endif |
25 | |||||
Stefan Reinauer | 7ce8c54 | 2005-12-02 21:52:30 +0000 | [diff] [blame] | 26 | |
Eric Biederman | 8ca8d76 | 2003-04-22 19:02:15 +0000 | [diff] [blame] | 27 | static void console_init(void) |
28 | { | ||||
29 | static const char console_test[] = | ||||
Stefan Reinauer | f8ee180 | 2008-01-18 15:08:58 +0000 | [diff] [blame^] | 30 | "\r\n\r\ncoreboot-" |
31 | COREBOOT_VERSION | ||||
32 | COREBOOT_EXTRA_VERSION | ||||
Eric Biederman | 8ca8d76 | 2003-04-22 19:02:15 +0000 | [diff] [blame] | 33 | " " |
Stefan Reinauer | f8ee180 | 2008-01-18 15:08:58 +0000 | [diff] [blame^] | 34 | COREBOOT_BUILD |
Eric Biederman | 8ca8d76 | 2003-04-22 19:02:15 +0000 | [diff] [blame] | 35 | " starting...\r\n"; |
36 | print_info(console_test); | ||||
37 | } | ||||
Eric Biederman | 05f26fc | 2003-06-11 21:55:00 +0000 | [diff] [blame] | 38 | |
39 | |||||
40 | static void die(const char *str) | ||||
41 | { | ||||
42 | print_emerg(str); | ||||
43 | do { | ||||
44 | hlt(); | ||||
45 | } while(1); | ||||
46 | } |