This patch splits console.c into 3 different files to get a better
[coreboot.git] / src / arch / i386 / lib / console.c
1 #include <console/loglevel.h>
2
3 #if CONFIG_USE_PRINTK_IN_CAR == 0
4 static void __console_tx_byte(unsigned char byte)
5 {
6         uart_tx_byte(byte);
7 }
8
9 #include "console_print.c"
10
11 #else  
12 /* CONFIG_USE_INIT == 1 */
13
14 #include "console_printk.c"
15
16 #endif /* CONFIG_USE_INIT */
17
18 #ifndef LINUXBIOS_EXTRA_VERSION
19 #define LINUXBIOS_EXTRA_VERSION ""
20 #endif
21
22
23 static void console_init(void)
24 {
25         static const char console_test[] = 
26                 "\r\n\r\nLinuxBIOS-"
27                 LINUXBIOS_VERSION
28                 LINUXBIOS_EXTRA_VERSION
29                 " "
30                 LINUXBIOS_BUILD
31                 " starting...\r\n";
32         print_info(console_test);
33 }
34
35
36 static void die(const char *str)
37 {
38         print_emerg(str);
39         do {
40                 hlt();
41         } while(1);
42 }