aboutsummaryrefslogtreecommitdiff
path: root/i686/gdt.c
diff options
context:
space:
mode:
Diffstat (limited to 'i686/gdt.c')
-rw-r--r--i686/gdt.c20
1 files changed, 0 insertions, 20 deletions
diff --git a/i686/gdt.c b/i686/gdt.c
deleted file mode 100644
index 3148096..0000000
--- a/i686/gdt.c
+++ /dev/null
@@ -1,20 +0,0 @@
-#include "gdt.h"
-
-void
-SegmentDescriptor(struct SegmentDescriptor_t *self, unsigned base, unsigned limit, uint8_t access)
-{
- self->base_15_0 = base & 0xffff;
- self->base_23_16 = (uint8_t)(base >> 16);
- self->base_31_24 = (uint8_t)(base >> 24);
-
- self->limit_15_0 = (limit <= 0xffff) ? (limit & 0xffff) : ((limit >> 12) & 0xffff);
- self->limit_19_16 = 0xfu & (uint8_t)((limit <= 0xffff) ? 0 : (limit >> 28));
-
- self->access = access;
-
- self->a = 0;
- self->rsv = 0;
- self->db = (limit > 0xffff) ? 1 : 0;
- self->granularity = (limit > 0) ? 1 : 0;
-}
-