Changeset 30368 in vbox for trunk/src/VBox/VMM/VMMAll
- Timestamp:
- Jun 22, 2010 12:20:38 PM (15 years ago)
- svn:sync-xref-src-repo-rev:
- 62960
- Location:
- trunk/src/VBox/VMM/VMMAll
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/VMM/VMMAll/PGMAllGst.h
r28800 r30368 90 90 Pde.n.u1Write &= pPml4e->n.u1Write & Pdpe.lm.u1Write; 91 91 Pde.n.u1User &= pPml4e->n.u1User & Pdpe.lm.u1User; 92 Pde.n.u1NoExecute &= pPml4e->n.u1NoExecute &Pdpe.lm.u1NoExecute;92 Pde.n.u1NoExecute |= pPml4e->n.u1NoExecute | Pdpe.lm.u1NoExecute; 93 93 # endif 94 94 … … 128 128 # if PGM_WITH_NX(PGM_GST_TYPE, PGM_GST_TYPE) 129 129 /* The NX bit is determined by a bitwise OR between the PT and PD */ 130 if (( Pte.u & Pde.u & X86_PTE_PAE_NX) && CPUMIsGuestNXEnabled(pVCpu)) /** @todo the code is ANDing not ORing NX like the comment says... */130 if (((Pte.u | Pde.u) & X86_PTE_PAE_NX) && CPUMIsGuestNXEnabled(pVCpu)) 131 131 *pfFlags |= X86_PTE_PAE_NX; 132 132 # endif -
trunk/src/VBox/VMM/VMMAll/PGMAllShw.h
r30364 r30368 177 177 Pde.n.u1Write &= Pml4e.n.u1Write & Pdpe.lm.u1Write; 178 178 Pde.n.u1User &= Pml4e.n.u1User & Pdpe.lm.u1User; 179 Pde.n.u1NoExecute &= Pml4e.n.u1NoExecute &Pdpe.lm.u1NoExecute;179 Pde.n.u1NoExecute |= Pml4e.n.u1NoExecute | Pdpe.lm.u1NoExecute; 180 180 181 181 # elif PGM_SHW_TYPE == PGM_TYPE_PAE … … 202 202 return VERR_PAGE_TABLE_NOT_PRESENT; 203 203 204 /** todo deal with large pages. */ 205 AssertFatal(!Pde.b.u1Size); 204 /** Deal with large pages. */ 205 if (Pde.b.u1Size) 206 { 207 /* 208 * Store the results. 209 * RW and US flags depend on the entire page translation hierarchy - except for 210 * legacy PAE which has a simplified PDPE. 211 */ 212 if (pfFlags) 213 { 214 *pfFlags = (Pde.u & ~SHW_PDE_PG_MASK); 215 # if PGM_WITH_NX(PGM_SHW_TYPE, PGM_SHW_TYPE) 216 if ((Pde.u & X86_PTE_PAE_NX) && CPUMIsGuestNXEnabled(pVCpu)) 217 *pfFlags |= X86_PTE_PAE_NX; 218 # endif 219 } 220 221 if (pHCPhys) 222 *pHCPhys = (Pde.u & SHW_PDE_PG_MASK) + (GCPtr & (RT_BIT(SHW_PD_SHIFT) - 1) & X86_PAGE_4K_BASE_MASK); 223 } 206 224 207 225 /* … … 248 266 # if PGM_WITH_NX(PGM_SHW_TYPE, PGM_SHW_TYPE) 249 267 /* The NX bit is determined by a bitwise OR between the PT and PD */ 250 if (( Pte.u & Pde.u & X86_PTE_PAE_NX) && CPUMIsGuestNXEnabled(pVCpu)) /** @todo the code is ANDing not ORing NX like the comment says... */268 if (((Pte.u | Pde.u) & X86_PTE_PAE_NX) && CPUMIsGuestNXEnabled(pVCpu)) 251 269 *pfFlags |= X86_PTE_PAE_NX; 252 270 # endif
Note:
See TracChangeset
for help on using the changeset viewer.