Process event on ps2 keyboard irq even if event already read.
Some old DOS programs will hook the keyboard irq, read the keyboard
data on irq, and then call the BIOS handler expecting it to continue
process the event. So, the BIOS can't assume it is the first to read
the data from the ps2 port.
Also, reduce window where a ps2 command could conflict with incoming
data. Disable all data during interrupt flushing, and only re-enable
the desired port just prior to sending the command.
Also, discard data from any interrupts if init hasn't completed.
1 file changed