Re: x86 - Realmode BIOS and Code calling module

From: Alan Cox
Date: Thu Aug 12 2004 - 16:46:48 EST


On Iau, 2004-08-12 at 14:38, Jakub Vana wrote:
> > Why is this better than LRMI in user mode.
>
> I was now looking on LRMI. It must be a nice code, but It is still only
> V86 emulation. I have listen that some BIOSes use something called
> Unreal mode, that is realmode with segment registers used like in
> protected mode. There is only one way, how to set this segregs -
> switch to prot. mode, but if the BIOS try to switch when is running
> in V86 CPU generates #GP (Global Protection fault). Not if it is
> running in real Real Mode.

I've yet to meet a video bios that does this. I don't think the X folks
have either, but you could run it past Egbert to make sure. The
"unreal" mode is normally only in existance during early boot.
>
> > To do BIOS calls safely
> > you need to be very careful about things like PCI locking, I/O
> > emulation and the ROM scribbling
>
> I'm not sure abou this, but I think there is not problem in calling
> BIOS, here is problem in BIOS handling with this features and so
> It's the problem of programmer that calls the BIOS to safely work
> and synchronize his hardware in kernel with BIOS. Other hardware
> (that is not pawn by BIOS) can't make problems.

One example is PCI configuration accesses which must be co-ordinated
with the kernel, and through the kernel PCI interfaces.

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/