aboutsummaryrefslogtreecommitdiff
path: root/kernel/drivers/keyboard.c
diff options
context:
space:
mode:
authorMarvin Borner2020-11-05 17:30:39 +0100
committerMarvin Borner2020-11-05 17:32:53 +0100
commit63e86f792167e6cc2e9600d00b184a3c83fe7498 (patch)
tree31e2d583be3ebf34782f6ec37f6c524657c40686 /kernel/drivers/keyboard.c
parent916fca2161e76de67a5106b90baf00a57f2a0512 (diff)
Added warning flags and fixed them :)
Diffstat (limited to 'kernel/drivers/keyboard.c')
-rw-r--r--kernel/drivers/keyboard.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/kernel/drivers/keyboard.c b/kernel/drivers/keyboard.c
index 2bd67ba..67e0a72 100644
--- a/kernel/drivers/keyboard.c
+++ b/kernel/drivers/keyboard.c
@@ -15,7 +15,7 @@ int state = 0;
int merged = 0;
void keyboard_handler()
{
- u32 scancode = (u32)inb(0x60);
+ int scancode = inb(0x60);
// TODO: Support more than two-byte scancodes
if (scancode == 0xe0) {
@@ -40,20 +40,20 @@ void keyboard_handler()
merged = 0;
}
-void keyboard_acknowledge()
+void keyboard_acknowledge(void)
{
while (inb(0x60) != 0xfa)
;
}
-void keyboard_rate()
+void keyboard_rate(void)
{
outb(0x60, 0xF3);
keyboard_acknowledge();
outb(0x60, 0x0); // Rate{00000} Delay{00} 0
}
-void keyboard_install()
+void keyboard_install(void)
{
//keyboard_rate(); TODO: Fix keyboard rate?
irq_install_handler(1, keyboard_handler);
@@ -67,7 +67,7 @@ char keymap[128] = {
0, // Alt key
' ', // Space bar
15, // Caps lock
- 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, // F keys
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, // F keys
0, // Num lock
0, // Scroll lock
0, // Home key