diff options
| author | Alexey Gavrilov <rebovas@yahoo.com> | 2024-03-06 15:32:17 +0700 |
|---|---|---|
| committer | Alexey Gavrilov <rebovas@yahoo.com> | 2024-03-06 15:32:17 +0700 |
| commit | 244a9154e42a49470bd28e3a95ebe9f4a5fe5ff7 (patch) | |
| tree | 4999e8c789a036511a1b6bbaec594b712bb1f64a /arch/x86/gdt | |
| parent | 1af53b431da6d3b5dcf7132f98f9eb2af88b57fa (diff) | |
Initialization mechanism
Diffstat (limited to 'arch/x86/gdt')
| -rwxr-xr-x | arch/x86/gdt/Gdt.cpp | 2 | ||||
| -rw-r--r-- | arch/x86/gdt/GlobalObj.cpp | 6 | ||||
| -rw-r--r-- | arch/x86/gdt/GlobalObj.h | 11 | ||||
| -rw-r--r-- | arch/x86/gdt/GoToGdtMemSeg.s | 13 |
4 files changed, 2 insertions, 30 deletions
diff --git a/arch/x86/gdt/Gdt.cpp b/arch/x86/gdt/Gdt.cpp index 80fcd13..21941b4 100755 --- a/arch/x86/gdt/Gdt.cpp +++ b/arch/x86/gdt/Gdt.cpp @@ -1,6 +1,8 @@ #include "Gdt.h" +uint64 MngGdt::gdt[MngGdt::size]; + DescSeg32::DescSeg32(uint32 base, uint32 limit, uint8 access, uint8 flags) { this->baseLow = base & 0x0000FFFF; diff --git a/arch/x86/gdt/GlobalObj.cpp b/arch/x86/gdt/GlobalObj.cpp deleted file mode 100644 index fbceeef..0000000 --- a/arch/x86/gdt/GlobalObj.cpp +++ /dev/null @@ -1,6 +0,0 @@ -#include "GlobalObj.h" - - -uint64 MngGdt::gdt[MngGdt::size]; - -MngGdt mngGdt; diff --git a/arch/x86/gdt/GlobalObj.h b/arch/x86/gdt/GlobalObj.h deleted file mode 100644 index 3c62847..0000000 --- a/arch/x86/gdt/GlobalObj.h +++ /dev/null @@ -1,11 +0,0 @@ -#ifndef GDTGLOBALOBJ_H -#define GDTGLOBALOBJ_H - -#include <types.h> -#include "Gdt.h" - -extern MngGdt mngGdt; - -void mngGdtInit(); - -#endif diff --git a/arch/x86/gdt/GoToGdtMemSeg.s b/arch/x86/gdt/GoToGdtMemSeg.s deleted file mode 100644 index 2b5dd62..0000000 --- a/arch/x86/gdt/GoToGdtMemSeg.s +++ /dev/null @@ -1,13 +0,0 @@ -global GOTOGDTMEMSEG -GOTOGDTMEMSEG: - lgdt [esp + 4] - jmp 0x08:.reloadCS -.reloadCS: - mov ax, 0x10 - mov ds, ax - mov es, ax - mov fs, ax - mov gs, ax - mov ss, ax - ret -.end: |
