fix: corner case for x87 context restore on execve
[lunaix-os.git] / lunaix-os / includes / arch / x86 / idt.h
index af0ae7d57bc457d5cc23fac361efe8389d20c7db..0d515c2c063ae93280065f60b491cd35c75d2d9d 100644 (file)
@@ -1,7 +1,10 @@
 #ifndef __LUNAIX_IDT_H
-#define __LUNAIX_IDT_H 1
-#define IDT_ATTR(dpl)                   ((0x70 << 5) | (dpl & 3) << 13 | 1 << 15)
+#define __LUNAIX_IDT_H
+#define IDT_TRAP 0x78
+#define IDT_INTERRUPT 0x70
+#define IDT_ATTR(dpl, type) (((type) << 5) | ((dpl & 3) << 13) | (1 << 15))
 
 void
 _init_idt();
-#endif
\ No newline at end of file
+
+#endif /* __LUNAIX_IDT_H */
\ No newline at end of file