Changeset 1433ecda in mainline for kernel/arch/amd64/include/arch/pm.h
- Timestamp:
- 2018-04-04T15:42:37Z (8 years ago)
- Branches:
- lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
- Children:
- 2c4e1cc
- Parents:
- 47b2d7e3
- File:
-
- 1 edited
-
kernel/arch/amd64/include/arch/pm.h (modified) (3 diffs)
Legend:
- Unmodified
- Added
- Removed
-
kernel/arch/amd64/include/arch/pm.h
r47b2d7e3 r1433ecda 37 37 38 38 #ifndef __ASSEMBLER__ 39 #include <typedefs.h>40 #include <arch/context.h>39 #include <typedefs.h> 40 #include <arch/context.h> 41 41 #endif 42 42 … … 91 91 92 92 typedef struct { 93 unsigned limit_0_15 : 16;94 unsigned base_0_15 : 16;95 unsigned base_16_23 : 8;96 unsigned access : 8;97 unsigned limit_16_19 : 4;98 unsigned available : 1;99 unsigned longmode : 1;100 unsigned special : 1;93 unsigned limit_0_15 : 16; 94 unsigned base_0_15 : 16; 95 unsigned base_16_23 : 8; 96 unsigned access : 8; 97 unsigned limit_16_19 : 4; 98 unsigned available : 1; 99 unsigned longmode : 1; 100 unsigned special : 1; 101 101 unsigned granularity : 1; 102 unsigned base_24_31 : 8;103 } __attribute__ ((packed)) descriptor_t;102 unsigned base_24_31 : 8; 103 } __attribute__((packed)) descriptor_t; 104 104 105 105 typedef struct { 106 unsigned limit_0_15 : 16;107 unsigned base_0_15 : 16;108 unsigned base_16_23 : 8;109 unsigned type : 4;106 unsigned limit_0_15 : 16; 107 unsigned base_0_15 : 16; 108 unsigned base_16_23 : 8; 109 unsigned type : 4; 110 110 unsigned : 1; 111 111 unsigned dpl : 2; 112 112 unsigned present : 1; 113 unsigned limit_16_19 : 4;114 unsigned available : 1;113 unsigned limit_16_19 : 4; 114 unsigned available : 1; 115 115 unsigned : 2; 116 116 unsigned granularity : 1; 117 unsigned base_24_31 : 8;117 unsigned base_24_31 : 8; 118 118 unsigned base_32_63 : 32; 119 119 unsigned : 32; 120 } __attribute__ ((packed)) tss_descriptor_t;120 } __attribute__((packed)) tss_descriptor_t; 121 121 122 122 typedef struct { 123 unsigned offset_0_15 : 16;124 unsigned selector : 16;125 unsigned ist :3;126 unsigned unused : 5;127 unsigned type : 5;128 unsigned dpl : 2;123 unsigned offset_0_15 : 16; 124 unsigned selector : 16; 125 unsigned ist : 3; 126 unsigned unused : 5; 127 unsigned type : 5; 128 unsigned dpl : 2; 129 129 unsigned present : 1; 130 unsigned offset_16_31 : 16;131 unsigned offset_32_63 : 32;130 unsigned offset_16_31 : 16; 131 unsigned offset_32_63 : 32; 132 132 unsigned : 32; 133 } __attribute__ ((packed)) idescriptor_t;133 } __attribute__((packed)) idescriptor_t; 134 134 135 135 typedef struct { 136 136 uint16_t limit; 137 137 uint64_t base; 138 } __attribute__ ((packed)) ptr_16_64_t;138 } __attribute__((packed)) ptr_16_64_t; 139 139 140 140 typedef struct { 141 141 uint16_t limit; 142 142 uint32_t base; 143 } __attribute__ ((packed)) ptr_16_32_t;143 } __attribute__((packed)) ptr_16_32_t; 144 144 145 145 typedef struct { … … 160 160 uint16_t iomap_base; 161 161 uint8_t iomap[TSS_IOMAP_SIZE]; 162 } __attribute__ ((packed)) tss_t;162 } __attribute__((packed)) tss_t; 163 163 164 164 extern tss_t *tss_p;
Note:
See TracChangeset
for help on using the changeset viewer.
