summaryrefslogtreecommitdiff
path: root/src/arch
diff options
context:
space:
mode:
authorPatrick Georgi <patrick@georgi-clan.de>2008-01-27 14:12:54 +0000
committerPatrick Georgi <patrick.georgi@coresystems.de>2008-01-27 14:12:54 +0000
commit3bbf2ff789791ca6fe3eb9fc7d3c92ce1fc86367 (patch)
treec3a7e6810a784c80d4330d57afa75bb3500a724c /src/arch
parent2d94dead69b150492646453184ae64d15744fc11 (diff)
Add a new record type "console" for lbtable, and insert one record
for each output device we support, so the payload can figure out where to find consoles that the user cares about. Signed-off-by: Patrick Georgi <patrick@georgi-clan.de> Acked-by: Stefan Reinauer <stepan@coresystems.de> git-svn-id: svn://svn.coreboot.org/coreboot/trunk@3081 2b7e53f0-3cfb-0310-b3e9-8179ed1497e1
Diffstat (limited to 'src/arch')
-rw-r--r--src/arch/i386/boot/coreboot_table.c35
1 files changed, 35 insertions, 0 deletions
diff --git a/src/arch/i386/boot/coreboot_table.c b/src/arch/i386/boot/coreboot_table.c
index 963ff385f5..0ba09e7215 100644
--- a/src/arch/i386/boot/coreboot_table.c
+++ b/src/arch/i386/boot/coreboot_table.c
@@ -90,6 +90,39 @@ struct lb_serial *lb_serial(struct lb_header *header)
#endif
}
+void add_console(struct lb_header *header, u16 consoletype)
+{
+ struct lb_record *rec;
+ struct lb_console *console;
+ rec = lb_new_record(header);
+ console = (struct lb_console *)lb_new_record(header);
+ console->tag = LB_TAG_CONSOLE;
+ console->size = sizeof(*console);
+ console->type = consoletype;
+}
+
+void lb_console(struct lb_header *header)
+{
+#ifdef CONFIG_CONSOLE_SERIAL8250
+ add_console(header, LB_TAG_CONSOLE_SERIAL8250);
+#endif
+#ifdef CONFIG_CONSOLE_VGA
+ add_console(header, LB_TAG_CONSOLE_VGA);
+#endif
+#ifdef CONFIG_CONSOLE_BTEXT
+ add_console(header, LB_TAG_CONSOLE_BTEXT);
+#endif
+#ifdef CONFIG_CONSOLE_LOGBUF
+ add_console(header, LB_TAG_CONSOLE_LOGBUF);
+#endif
+#ifdef CONFIG_CONSOLE_SROM
+ add_console(header, LB_TAG_CONSOLE_SROM);
+#endif
+#ifdef CONFIG_USBDEBUG_DIRECT
+ add_console(header, LB_TAG_CONSOLE_EHCI);
+#endif
+}
+
struct lb_mainboard *lb_mainboard(struct lb_header *header)
{
struct lb_record *rec;
@@ -426,6 +459,8 @@ unsigned long write_coreboot_table(
lb_mainboard(head);
/* Record the serial port, if present */
lb_serial(head);
+ /* Record our console setup */
+ lb_console(head);
/* Record our various random string information */
lb_strings(head);