Problem with key presses when interrupts are disabled
Posted: Mon May 10, 2010 7:11 pm
Hi,
I've got a basic protected mode kernel running using information found on the wiki and I can get key scancodes most of the time by reading from port 0x60 when IRQ 1 fires.
However, if a key is pressed before interrupts are enabled (e.g. after the kernel has been loaded by GRUB and is setting up GDT, IDT, ...) or between cli and sti (e.g. while handling other IRQs or software interrupts), IRQ 1 never fires, even for subsequent key presses.
I've googled, but didn't find much. Could someone point me in the right direction? Pressing a key at the wrong time basically disables the keyboard...
DL
I've got a basic protected mode kernel running using information found on the wiki and I can get key scancodes most of the time by reading from port 0x60 when IRQ 1 fires.
However, if a key is pressed before interrupts are enabled (e.g. after the kernel has been loaded by GRUB and is setting up GDT, IDT, ...) or between cli and sti (e.g. while handling other IRQs or software interrupts), IRQ 1 never fires, even for subsequent key presses.
I've googled, but didn't find much. Could someone point me in the right direction? Pressing a key at the wrong time basically disables the keyboard...
DL