Jens Nerche <[EMAIL PROTECTED]> wrote:
> A second look on GDT handling raises another question:
> in emulat_lgdt are guest_gdt_info.[limit|base] changed,
> but (in nexus) is mon_gdt_info loaded. Seems that lgdt
> in guest doesn't change any relevant table. (??)
> (But why I can crash vm with lgdt?)
Maybe you need to take a third look ;-) emulate_lgdt()
copies the guest GDT into the monitor GDT, while switching
off all dangerous settings (gates, ring-0, etc.).
It *also* remembers the address of the guest GDT itself
so that subsequent routines can look at it to check what
the guest really wanted to do. The guest GDT is never
itself used as real processor GDT, however.
Bye,
Ulrich