From 4d4e784770b576199b18f22100689125a18bfd9a Mon Sep 17 00:00:00 2001 From: Marvin Borner Date: Thu, 15 Apr 2021 22:47:54 +0200 Subject: Basic block/unblock --- kernel/drivers/ps2/keyboard.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) (limited to 'kernel/drivers') diff --git a/kernel/drivers/ps2/keyboard.c b/kernel/drivers/ps2/keyboard.c index 3c2cdbb..616c539 100644 --- a/kernel/drivers/ps2/keyboard.c +++ b/kernel/drivers/ps2/keyboard.c @@ -43,6 +43,8 @@ static void keyboard_handler(struct regs *r) state = 0; merged = 0; + + io_unblock(IO_KEYBOARD); } static res keyboard_read(void *buf, u32 offset, u32 count) @@ -63,7 +65,8 @@ static res keyboard_ready(void) CLEAR void ps2_keyboard_reset(void) { - stack_clear(queue); + if (queue) + stack_clear(queue); } CLEAR void ps2_keyboard_install(u8 device) -- cgit v1.2.3