Timer re-worked!
[lunaix-os.git] / lunaix-os / includes / hal / pic.h
index 20ee67bb69abf9838ad77e0fd42bb14a74778183..54f03b0d9afac600c7178e58503665fb6e75dae1 100644 (file)
@@ -2,4 +2,13 @@
 #define __LUNAIX_PIC_H
 // TODO: PIC
 
+static inline void
+pic_disable()
+{
+    // ref: https://wiki.osdev.org/8259_PIC
+    asm volatile ("movb $0xff, %al\n"
+        "outb %al, $0xa1\n"
+        "outb %al, $0x21\n");
+}
+
 #endif /* __LUNAIX_PIC_H */