* Stefan Reinauer stepan@openbios.org [040517 17:51]:
There needs to be some way to call into interrupts set up by the executed option rom, or otherwise functions like handleint21() will have to be added and changed for every minor release of a vga bios update.
There's a potential hint in src/arch/i386/lib/idt.c:biosint():
// cases in a good compiler are just as good as your own tables. switch (intnumber) { case 0 ... 15: [..] #ifdef CONFIG_PCIBIOS case PCIBIOS: [..] #endif case MEMSIZE: [..] #ifdef CONFIG_INT21HANDLER case 0x15: [..] #endif default: [..] }
It looks like this case construct was done for readability, but in fact some kind of interrupt lookup table is needed to handle things correctly.
Stefan