Hi,

there are several legacy tables that PCBIOS writes, eg. about the io-ports
of the various serial ports.

We probably need a place for them to be generated, as some clients might
rely on the presence of these tables.

Grub2 definitely needs the serial port's ioport written at 0x400 (which the
attached patch does) to support serial console, but I'm not sure if that's
a good place to collect such configuration or where to put it instead.
So please consider this patch an attempt to start a discussion... :-)

Regards,
Patrick Georgi
Writes the serial port at the location where PCBIOS places it.
Some operating systems (windows?) and loaders (grub2) rely on it.

I'm not quite sure if that's actually a sensible place for this
or if the code should end up elsewhere.

It can't be in the serial driver, as it is ran in CAR mode, so
0x400 isn't accessible yet.

Other than that,

Signed-off-by: Patrick Georgi <[EMAIL PROTECTED]>

Index: arch/x86/archtables.c
===================================================================
--- arch/x86/archtables.c	(Revision 477)
+++ arch/x86/archtables.c	(Arbeitskopie)
@@ -25,6 +25,7 @@
 #include <console.h>
 #include <string.h>
 #include <tables.h>
+#include <uart8250.h>
 //#include <cpu/cpu.h>
 //#include <pirq_routing.h>
 //#include <smp/mpspec.h>
@@ -141,5 +142,7 @@
 			      low_table_start, low_table_end,
 			      rom_table_start, rom_table_end);
 
+	*(u32*)(0x400)=TTYSx_BASE;
+
 	return get_lb_mem();
 }

-- 
linuxbios mailing list
[email protected]
http://www.linuxbios.org/mailman/listinfo/linuxbios

Reply via email to