Page 1 of 1

IVT and Protected mode

Posted: Thu Mar 06, 2008 1:48 pm
by AlfaOmega08
In the piece of memory between 0x0 and 0x3FF, there is the IVT right?
The IVT is a 4-byte entry table. Each entry points to the code of an interrupt...

If I parse that zone of memory, I can find the code of the ints, can't I?
Then I can create some IDT descriptors (0x30 = int 0, 0x31 = int 1, ...) with as base, the value I found in the table (adapted for protected mode)

Can I do all this wonderful things? Or when switching to pmode, the IVT goes lost?

Posted: Thu Mar 06, 2008 3:02 pm
by JamesM
Each entry points to the code of an interrupt...
The interrupt handling code is 16 bits - real mode code. It can't be run in a 32bit protected mode environment.

Posted: Thu Mar 06, 2008 10:57 pm
by tjhastings
The IVT is not lost when you switch to protected mode. It may be possible to do as you suggest using the right call gates; as I recall they could be set to transfer execution between 32 and 16-bit code.

Check out chapter 16 of the Intel Software Developer's Manual Volume 3A

- TJ

Posted: Sun Mar 09, 2008 3:58 pm
by Combuster
The code referenced from the IDT will still assume real mode, not protected mode. If you want to make bios calls, you either have to leave protected mode, or use v8086