IDEA: Linux kernel and pcbios compatibility...

Takeshi Sone ts1 at tsn.or.jp
Fri Dec 19 04:18:00 CET 2003


On Fri, Dec 19, 2003 at 12:49:42AM -0700, Eric W. Biederman wrote:
> Adam Sulmicki <adam at cfar.umd.edu> writes:
> 
> > you mean just like dosemu runs under linux ???
> 
> Right but for BSD and early versions of windows the dependencies
> were worse.  I don't know which services matter though.

Last time I saw the source code of FreeBSD, its _bootloader_ has its 
own vm86 monitor (in assembly), works in protected mode,
and calls all the BIOS calls (video, keyboard, disk,...) in 
vm86 mode. Also the kernel calls E820, APM, VESA, etc in vm86.
Also I saw a recent version of Windows calls BIOS services in vm86.

Maybe we can modify FreeBSD, and have work-around for Windows,
but at least I don't think it's the way to go.

My conclusion then was that PCBIOS had to work in real mode.

Maybe we can code it with GCC and .code16gcc hack.
If 64KB is not enough, maybe 0xE000 segment can be used
so that we have 64KB code and 64KB data segments.
And all the "POST" code can be outside the real mode space.
So it's not impossible or hard at all.
-- 
Takeshi



More information about the coreboot mailing list