Changeset 43163 in vbox for trunk/src/VBox/VMM/VMMR3
- Timestamp:
- Sep 4, 2012 2:12:53 PM (12 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/VMM/VMMR3/PGMPool.cpp
r41965 r43163 285 285 /* The NIL entry. */ 286 286 Assert(NIL_PGMPOOL_IDX == 0); 287 pPool->aPages[NIL_PGMPOOL_IDX].enmKind = PGMPOOLKIND_INVALID; 287 pPool->aPages[NIL_PGMPOOL_IDX].enmKind = PGMPOOLKIND_INVALID; 288 pPool->aPages[NIL_PGMPOOL_IDX].idx = NIL_PGMPOOL_IDX; 288 289 289 290 /* The Shadow 32-bit PD. (32 bits guest paging) */ 290 pPool->aPages[PGMPOOL_IDX_PD].Core.Key = NIL_RTHCPHYS; 291 pPool->aPages[PGMPOOL_IDX_PD].GCPhys = NIL_RTGCPHYS; 292 pPool->aPages[PGMPOOL_IDX_PD].pvPageR3 = 0; 293 pPool->aPages[PGMPOOL_IDX_PD].enmKind = PGMPOOLKIND_32BIT_PD; 294 pPool->aPages[PGMPOOL_IDX_PD].idx = PGMPOOL_IDX_PD; 291 pPool->aPages[PGMPOOL_IDX_PD].enmKind = PGMPOOLKIND_32BIT_PD; 292 pPool->aPages[PGMPOOL_IDX_PD].idx = PGMPOOL_IDX_PD; 295 293 296 294 /* The Shadow PDPT. */ 297 pPool->aPages[PGMPOOL_IDX_PDPT].Core.Key = NIL_RTHCPHYS; 298 pPool->aPages[PGMPOOL_IDX_PDPT].GCPhys = NIL_RTGCPHYS; 299 pPool->aPages[PGMPOOL_IDX_PDPT].pvPageR3 = 0; 300 pPool->aPages[PGMPOOL_IDX_PDPT].enmKind = PGMPOOLKIND_PAE_PDPT; 301 pPool->aPages[PGMPOOL_IDX_PDPT].idx = PGMPOOL_IDX_PDPT; 295 pPool->aPages[PGMPOOL_IDX_PDPT].enmKind = PGMPOOLKIND_PAE_PDPT; 296 pPool->aPages[PGMPOOL_IDX_PDPT].idx = PGMPOOL_IDX_PDPT; 302 297 303 298 /* The Shadow AMD64 CR3. */ 304 pPool->aPages[PGMPOOL_IDX_AMD64_CR3].Core.Key = NIL_RTHCPHYS; 305 pPool->aPages[PGMPOOL_IDX_AMD64_CR3].GCPhys = NIL_RTGCPHYS; 306 pPool->aPages[PGMPOOL_IDX_AMD64_CR3].pvPageR3 = 0; 307 pPool->aPages[PGMPOOL_IDX_AMD64_CR3].enmKind = PGMPOOLKIND_64BIT_PML4; 308 pPool->aPages[PGMPOOL_IDX_AMD64_CR3].idx = PGMPOOL_IDX_AMD64_CR3; 299 pPool->aPages[PGMPOOL_IDX_AMD64_CR3].enmKind = PGMPOOLKIND_64BIT_PML4; 300 pPool->aPages[PGMPOOL_IDX_AMD64_CR3].idx = PGMPOOL_IDX_AMD64_CR3; 309 301 310 302 /* The Nested Paging CR3. */ 311 pPool->aPages[PGMPOOL_IDX_NESTED_ROOT].Core.Key = NIL_RTHCPHYS; 312 pPool->aPages[PGMPOOL_IDX_NESTED_ROOT].GCPhys = NIL_RTGCPHYS; 313 pPool->aPages[PGMPOOL_IDX_NESTED_ROOT].pvPageR3 = 0; 314 pPool->aPages[PGMPOOL_IDX_NESTED_ROOT].enmKind = PGMPOOLKIND_ROOT_NESTED; 315 pPool->aPages[PGMPOOL_IDX_NESTED_ROOT].idx = PGMPOOL_IDX_NESTED_ROOT; 303 pPool->aPages[PGMPOOL_IDX_NESTED_ROOT].enmKind = PGMPOOLKIND_ROOT_NESTED; 304 pPool->aPages[PGMPOOL_IDX_NESTED_ROOT].idx = PGMPOOL_IDX_NESTED_ROOT; 316 305 317 306 /* 318 307 * Set common stuff. 319 308 */ 320 for (unsigned iPage = 1; iPage < PGMPOOL_IDX_FIRST; iPage++) 321 { 309 for (unsigned iPage = 0; iPage < PGMPOOL_IDX_FIRST; iPage++) 310 { 311 pPool->aPages[iPage].Core.Key = NIL_RTHCPHYS; 312 pPool->aPages[iPage].GCPhys = NIL_RTGCPHYS; 322 313 pPool->aPages[iPage].iNext = NIL_PGMPOOL_IDX; 314 /* pPool->aPages[iPage].cLocked = INT32_MAX; - test this out... */ 315 pPool->aPages[iPage].pvPageR3 = 0; 323 316 pPool->aPages[iPage].iUserHead = NIL_PGMPOOL_USER_INDEX; 324 317 pPool->aPages[iPage].iModifiedNext = NIL_PGMPOOL_IDX; … … 328 321 pPool->aPages[iPage].iAgeNext = NIL_PGMPOOL_IDX; 329 322 pPool->aPages[iPage].iAgePrev = NIL_PGMPOOL_IDX; 323 330 324 Assert(pPool->aPages[iPage].idx == iPage); 331 325 Assert(pPool->aPages[iPage].GCPhys == NIL_RTGCPHYS);
Note:
See TracChangeset
for help on using the changeset viewer.