summaryrefslogtreecommitdiff
path: root/arch/i386/include/kernel/pic.h
diff options
context:
space:
mode:
authorDanny Holman <dholman@gymli.org>2025-01-12 01:17:36 -0600
committerDanny Holman <dholman@gymli.org>2025-01-12 01:19:11 -0600
commit95cd78840f0891e60f5ebecc8a8eb4fbaf3c2ebf (patch)
treec8c35347b50477929727fa5be9f5d0f55cbe18fd /arch/i386/include/kernel/pic.h
parent5e166f3042a8e7b3031aae4da7006f80caa53ecc (diff)
PROJECT RESTRUCTURING
Move the entire kernel into its own directory. Create new directories for system commands, libraries and other required essentials for a complete Unix-like operating system. Signed-off-by: Danny Holman <dholman@gymli.org>
Diffstat (limited to 'arch/i386/include/kernel/pic.h')
-rw-r--r--arch/i386/include/kernel/pic.h44
1 files changed, 0 insertions, 44 deletions
diff --git a/arch/i386/include/kernel/pic.h b/arch/i386/include/kernel/pic.h
deleted file mode 100644
index 187d553..0000000
--- a/arch/i386/include/kernel/pic.h
+++ /dev/null
@@ -1,44 +0,0 @@
-#ifndef I386_PIC_H
-#define I386_PIC_H
-
-#include <kernel/asm.h>
-#include <stdint.h>
-
-#define PIC1 0x20
-#define PIC2 0x28
-#define PIC1_COMMAND PIC1
-#define PIC1_DATA (PIC1+1)
-#define PIC2_COMMAND PIC2
-#define PIC2_DATA (PIC2+1)
-
-#define ICW1_ICW4 0x01
-#define ICW1_SINGLE 0x02
-#define ICW1_INTERVAL4 0x04
-#define ICW1_LEVEL 0x08
-#define ICW1_INIT 0x10
-
-#define ICW4_8086 0x01
-#define ICW4_AUTO 0x02
-#define ICW4_BUF_SLAVE 0x08
-#define ICW4_BUF_MASTER 0x0C
-#define ICW4_SFNM 0x10
-
-#define PIC_READ_IRR 0x0A
-#define PIC_READ_ISR 0x0B
-
-static inline void io_wait(void) {
- outb(0x80, 0);
-}
-
-void pic_eoi(uint8_t irq);
-void pic_remap(void);
-uint16_t pic_get_irr(void);
-uint16_t pic_get_isr(void);
-
-void register_irq_handler(uint8_t irq, void (*handler)(struct isr_frame *frame));
-void irq_dispatch(struct isr_frame *frame);
-
-void irq_set_mask(uint8_t irq);
-void irq_clear_mask(uint8_t irq);
-
-#endif