- Timestamp:
- Dec 21, 2012 10:39:53 AM (12 years ago)
- svn:sync-xref-src-repo-rev:
- 82931
- Location:
- trunk
- Files:
-
- 6 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/include/VBox/vmm/hm.h
r43387 r44195 58 58 VMMDECL(int) HMInvalidatePage(PVMCPU pVCpu, RTGCPTR GCVirt); 59 59 VMMDECL(bool) HMHasPendingIrq(PVM pVM); 60 VMMDECL(PX86PDPE) HMGetPaePdpes(PVMCPU pVCpu); 60 61 61 62 #ifndef IN_RC -
trunk/include/VBox/vmm/vm.h
r43387 r44195 348 348 * thread or requests which must be executed in another context. */ 349 349 #define VMCPU_FF_REQUEST RT_BIT_32(9) 350 /** This action forces the VM to service any pending updates to CR3 (used only 351 * by HM). */ 352 #define VMCPU_FF_HM_UPDATE_CR3 RT_BIT_32(12) 353 /** This action forces the VM to service any pending updates to PAE PDPEs (used 354 * only by HM). */ 355 #define VMCPU_FF_HM_UPDATE_PAE_PDPES RT_BIT_32(13) 350 356 /** This action forces the VM to resync the page tables before going 351 357 * back to execute guest code. (GLOBAL FLUSH) */ … … 409 415 #define VM_FF_HIGH_PRIORITY_POST_MASK (VM_FF_PGM_NO_MEMORY) 410 416 /** High priority post-execution actions. */ 411 #define VMCPU_FF_HIGH_PRIORITY_POST_MASK (VMCPU_FF_PDM_CRITSECT|VMCPU_FF_CSAM_PENDING_ACTION) 417 #define VMCPU_FF_HIGH_PRIORITY_POST_MASK ( VMCPU_FF_PDM_CRITSECT | VMCPU_FF_CSAM_PENDING_ACTION \ 418 | VMCPU_FF_HM_UPDATE_CR3 | VMCPU_FF_HM_UPDATE_PAE_PDPES) 412 419 413 420 /** Normal priority VM post-execution actions. */ -
trunk/src/VBox/VMM/VMMAll/HMAll.cpp
r43510 r44195 342 342 } 343 343 344 345 /** 346 * Return the PAE PDPE entries. 347 * 348 * @returns Pointer to the PAE PDPE array. 349 * @param pVCpu Pointer to the VMCPU. 350 */ 351 VMMDECL(PX86PDPE) HMGetPaePdpes(PVMCPU pVCpu) 352 { 353 return &pVCpu->hm.s.aPdpes[0]; 354 } 355 -
trunk/src/VBox/VMM/VMMAll/PGMAll.cpp
r43953 r44195 1637 1637 * 1638 1638 * @returns VBox status code. 1639 * @param pVCpu The virtualCPU.1640 * @param paPdpes Where to return the four PDPEs. 1639 * @param pVCpu Pointer to the VMCPU. 1640 * @param paPdpes Where to return the four PDPEs. The array 1641 1641 * pointed to must have 4 entries. 1642 1642 */ … … 1659 1659 * 1660 1660 * @returns VBox status code. 1661 * @param pVCpu The virtualCPU.1662 * @param paPdpes The four PDPE values. The array pointed to1663 * musthave exactly 4 entries.1661 * @param pVCpu Pointer to the VMCPU. 1662 * @param paPdpes The four PDPE values. The array pointed to must 1663 * have exactly 4 entries. 1664 1664 * 1665 1665 * @remarks No-long-jump zone!!! … … 1684 1684 } 1685 1685 } 1686 1687 VMCPU_FF_CLEAR(pVCpu, VMCPU_FF_HM_UPDATE_PAE_PDPES); 1686 1688 return VINF_SUCCESS; 1687 1689 } … … 1969 1971 AssertRCSuccess(rc); /* Assumes VINF_PGM_SYNC_CR3 doesn't apply to nested paging. */ /** @todo this isn't true for the mac, but we need hw to test/fix this. */ 1970 1972 } 1973 1974 VMCPU_FF_CLEAR(pVCpu, VMCPU_FF_HM_UPDATE_CR3); 1971 1975 return rc; 1972 1976 } -
trunk/src/VBox/VMM/VMMR3/EM.cpp
r43872 r44195 1380 1380 PDMCritSectFF(pVCpu); 1381 1381 1382 /* Update CR3 (Nested Paging case for HM). */ 1383 if (VMCPU_FF_ISPENDING(pVCpu, VMCPU_FF_HM_UPDATE_CR3)) 1384 { 1385 int rc2 = PGMUpdateCR3(pVCpu, CPUMGetGuestCR3(pVCpu)); 1386 if (RT_FAILURE(rc2)) 1387 return rc2; 1388 Assert(!VMCPU_FF_ISPENDING(pVCpu, VMCPU_FF_HM_UPDATE_CR3)); 1389 } 1390 1391 /* Update PAE PDPEs. This must be done *after* PGMUpdateCR3() and used only by the Nested Paging case for HM. */ 1392 if (VMCPU_FF_ISPENDING(pVCpu, VMCPU_FF_HM_UPDATE_PAE_PDPES)) 1393 { 1394 Assert(CPUMIsGuestInPAEMode(pVCpu)); 1395 PX86PDPE pPdpes = HMGetPaePdpes(pVCpu); 1396 AssertPtr(pPdpes); 1397 1398 int rc2 = PGMGstUpdatePaePdpes(pVCpu, pPdpes); 1399 if (RT_FAILURE(rc2)) 1400 return rc2; 1401 Assert(!VMCPU_FF_ISPENDING(pVCpu, VMCPU_FF_HM_UPDATE_PAE_PDPES)); 1402 } 1403 1382 1404 if (VMCPU_FF_ISPENDING(pVCpu, VMCPU_FF_CSAM_PENDING_ACTION)) 1383 1405 CSAMR3DoPendingAction(pVM, pVCpu); -
trunk/src/VBox/VMM/include/HMInternal.h
r44146 r44195 692 692 } s; 693 693 } PendingIO; 694 695 /** The PAE PDPEs used with Nested Paging (only valid when 696 * VMCPU_FF_HM_UPDATE_PAE_PDPES is set). */ 697 X86PDPE aPdpes[4]; 694 698 695 699 /** Current shadow paging mode. */
Note:
See TracChangeset
for help on using the changeset viewer.