diff options
| author | Fabian Imhof <fabian.imhof@ost.ch> | 2025-03-13 14:05:49 +0000 |
|---|---|---|
| committer | Fabian Imhof <fabian.imhof@ost.ch> | 2025-03-13 14:05:49 +0000 |
| commit | bdbe6d4bc0f2966541bcd5a47c1a4ad9cbff16fa (patch) | |
| tree | ab65cfdff8a74560b061738b3b729011934eb4f1 /arch/x86_64/include | |
| parent | 2e4cbd473ff3bb7ac7371af39becf830b4fb753b (diff) | |
| parent | 34c36096e55ac678e29c58f7336b419647e805b6 (diff) | |
| download | teachos-bdbe6d4bc0f2966541bcd5a47c1a4ad9cbff16fa.tar.xz teachos-bdbe6d4bc0f2966541bcd5a47c1a4ad9cbff16fa.zip | |
Merge branch 'feat_inital_context_switching' of ssh://gitlab.ost.ch:45022/teachos/kernel into feat_inital_context_switching
Diffstat (limited to 'arch/x86_64/include')
| -rw-r--r-- | arch/x86_64/include/arch/context_switching/descriptor_table/segment_descriptor.hpp | 13 |
1 files changed, 8 insertions, 5 deletions
diff --git a/arch/x86_64/include/arch/context_switching/descriptor_table/segment_descriptor.hpp b/arch/x86_64/include/arch/context_switching/descriptor_table/segment_descriptor.hpp index b5697e3..06e2e8a 100644 --- a/arch/x86_64/include/arch/context_switching/descriptor_table/segment_descriptor.hpp +++ b/arch/x86_64/include/arch/context_switching/descriptor_table/segment_descriptor.hpp @@ -51,11 +51,14 @@ namespace teachos::arch::context_switching::descriptor_table auto get_segment_type() const -> segment_descriptor_type; private: - uint32_t _reserved = {}; - access_byte _access = {}; - gdt_flags _flag = {}; - uint64_t _base = {}; - std::bitset<20U> _limit = {}; + // The order in private variables starts for the first variable being the rightmost bit. + std::bitset<16U> _limit_1 = {}; ///< First part of the limit field (0 - 15) + std::bitset<24U> _base_1 = {}; ///< First part of the base field (16 - 39) + access_byte _access = {}; ///< Access byte field (40 - 47) + std::bitset<4U> _limit_2 = {}; ///< Second part of the limit field (48 - 51) + gdt_flags _flag = {}; ///< Flags field (52 - 55) + std::bitset<40U> _base_2 = {}; ///< Second part of the base field (56 - 95) + uint32_t _reserved = {}; ///< Reserved field used to ensure this struct is 128 bits big (96 - 127) }; } // namespace teachos::arch::context_switching::descriptor_table |
