[ BIG CHANGE ] Properly Implemented IDT

- New include files: idt.h, pic.h, syscall.h and exceptions.h
- Proper exception handling (still could be improved
- PIC properly initiated and irqs all masked
- BREAKS Keyboard - The keyboard IRQ is not handled anymore
- convertColor() is kinda broken :/ (More in README.md)
This commit is contained in:
2024-05-05 21:03:21 +02:00
parent 29418eb46b
commit 1d71a4e384
15 changed files with 448 additions and 617 deletions
+3 -12
View File
@@ -24,18 +24,9 @@ void outw(uint16_t port, uint16_t data) {
asm volatile("outw %0, %1" :: "a"(data), "Nd"(port));
}
// Assembly stuff
void cli() {
asm volatile("cli");
}
void sti() {
asm volatile("sti");
}
void hlt() {
asm volatile("hlt");
void ioWait() {
// Waits ~1 I/O Cycle (Linux uses this so it should be good)
asm volatile("outb %%al, $0x80" : : "a"(0));
}
#endif