- Timestamp:
- Jun 27, 2017, 5:20:55 PM (7 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/hal/x86_64/core/hal_gpt.c
r51 r79 81 81 XASSERT(va == tmpva || PTE_BASE[pl1_i(va)] == 0); 82 82 PTE_BASE[pl1_i(va)] = (pa & PG_FRAME) | PG_V | PG_KW | PG_NX; 83 invlpg(va); 83 84 } 84 85 … … 88 89 for (i = 0; i < n; i++) { 89 90 hal_gpt_enter(va + i * PAGE_SIZE, pa + i * PAGE_SIZE); 90 invlpg(va + i * PAGE_SIZE);91 91 } 92 92 } … … 97 97 XASSERT(PTE_BASE[pl1_i(va)] != 0); 98 98 PTE_BASE[pl1_i(va)] = 0; 99 invlpg(va); 99 100 } 100 101 … … 104 105 for (i = 0; i < n; i++) { 105 106 hal_gpt_leave(va + i * PAGE_SIZE); 106 invlpg(va + i * PAGE_SIZE);107 107 } 108 108 } … … 146 146 pa = L1page + i * PAGE_SIZE; 147 147 hal_gpt_enter(tmpva, pa); 148 invlpg(tmpva);149 148 150 149 memset((void *)tmpva, 0, PAGE_SIZE); … … 155 154 pa = L2page + i * PAGE_SIZE; 156 155 hal_gpt_enter(tmpva, pa); 157 invlpg(tmpva);158 156 159 157 memset((void *)tmpva, 0, PAGE_SIZE); … … 164 162 pa = L3page + i * PAGE_SIZE; 165 163 hal_gpt_enter(tmpva, pa); 166 invlpg(tmpva);167 164 168 165 memset((void *)tmpva, 0, PAGE_SIZE); … … 176 173 pa &= PG_FRAME; /* rounddown to a page boundary */ 177 174 hal_gpt_enter(tmpva, pa); 178 invlpg(tmpva);179 175 180 176 pde = (pt_entry_t *)tmpva; … … 190 186 pa &= PG_FRAME; /* rounddown to a page boundary */ 191 187 hal_gpt_enter(tmpva, pa); 192 invlpg(tmpva);193 188 194 189 pde = (pt_entry_t *)tmpva;
Note: See TracChangeset
for help on using the changeset viewer.