diff options
author | Marvin Borner | 2020-02-15 16:57:57 +0100 |
---|---|---|
committer | Marvin Borner | 2020-02-15 16:57:57 +0100 |
commit | f5b995586e28f7db426f4707a4348dc067df41c0 (patch) | |
tree | 37bfd54a3ecbe6dca0b2c4530dd28d3177c98362 /src/kernel/gdt/gdt.c | |
parent | 7ec74159de339baf3687bc59f1c18309b23ef36b (diff) |
Quite many improvements
ok.
Diffstat (limited to 'src/kernel/gdt/gdt.c')
-rw-r--r-- | src/kernel/gdt/gdt.c | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/src/kernel/gdt/gdt.c b/src/kernel/gdt/gdt.c index efff8a3..5b43025 100644 --- a/src/kernel/gdt/gdt.c +++ b/src/kernel/gdt/gdt.c @@ -97,6 +97,7 @@ void gdt_install() // Remove old GDT and install the new changes! gdt_flush(); + tss_flush(); vga_log("Installed Global Descriptor Table"); } @@ -114,13 +115,10 @@ void tss_write(int32_t num, uint16_t ss0, uint32_t esp0) tss_entry.esp0 = esp0; tss_entry.cs = 0x0b; tss_entry.ss = tss_entry.ds = tss_entry.es = tss_entry.fs = tss_entry.gs = 0x13; - - tss_entry.iomap_base = sizeof(struct tss_entry_struct); } -void tss_flush(void) +void tss_flush() { - tss_entry.esp0 = 4096 + (uint32_t) kmalloc(4096); asm volatile ("ltr %%ax": : "a" (0x2B)); } |