~sircmpwn/bunnix

1211264eda47fbed9942aa614898a324d84c9827 — Drew DeVault 2 months ago b70189c
sys: ps2kbd: handle extended scancodes

Bit of a hack.
1 files changed, 5 insertions(+), 1 deletions(-)

M sys/arch/dev/+x86_64/ps2kbd.ha
M sys/arch/dev/+x86_64/ps2kbd.ha => sys/arch/dev/+x86_64/ps2kbd.ha +5 -1
@@ 17,7 17,11 @@ export fn ps2_init() void = {
fn ps2_irq(irq: u8, user: nullable *opaque) void = {
	defer arch::irq_ack(irq);

	let scancode = x86_64::inb(PS2_DATA);
	let scancode = x86_64::inb(PS2_DATA): u32;
	if (scancode == 0xE0) {
		scancode <<= 8;
		scancode |= x86_64::inb(PS2_DATA);
	};

	const mask = 1u8 << 7;
	const state = if (scancode & mask == 0) {