VirtualBox

Changeset 20068 in vbox


Ignore:
Timestamp:
May 27, 2009 11:32:49 AM (16 years ago)
Author:
vboxsync
Message:

Trying to get rid of annoying assertions

Location:
trunk/src/VBox/VMM/VMMAll
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/VMM/VMMAll/PGMAll.cpp

    r20008 r20068  
    790790VMMDECL(int) PGMShwGetPage(PVMCPU pVCpu, RTGCPTR GCPtr, uint64_t *pfFlags, PRTHCPHYS pHCPhys)
    791791{
    792     return PGM_SHW_PFN(GetPage, pVCpu)(pVCpu, GCPtr, pfFlags, pHCPhys);
     792    pgmLock(pVCpu->CTX_SUFF(pVM));
     793    int rc = PGM_SHW_PFN(GetPage, pVCpu)(pVCpu, GCPtr, pfFlags, pHCPhys);
     794    pgmUnlock(pVCpu->CTX_SUFF(pVM));
     795    return rc;
    793796}
    794797
  • trunk/src/VBox/VMM/VMMAll/PGMAllBth.h

    r20065 r20068  
    800800                    pgmLock(pVM);
    801801                    rc = PGM_BTH_NAME(SyncPage)(pVCpu, PdeSrc, pvFault, 1, uErr);
     802#   ifndef VBOX_STRICT
     803                    /* Keep it locked in VBOX_STRICT mode so the next checks won't trigger without reason with guest SMP. */
    802804                    pgmUnlock(pVM);
     805#   endif
    803806                    if (RT_SUCCESS(rc))
    804807                    {
     
    815818                        uint64_t fPageShw;
    816819                        rc = PGMShwGetPage(pVCpu, pvFault, &fPageShw, NULL);
    817                         AssertMsg((pVM->cCPUs > 1 && rc == VERR_PAGE_NOT_PRESENT) || (RT_SUCCESS(rc) && (fPageShw & X86_PTE_RW)), ("rc=%Rrc fPageShw=%RX64\n", rc, fPageShw));
     820                        AssertMsg((RT_SUCCESS(rc) && (fPageShw & X86_PTE_RW)), ("rc=%Rrc fPageShw=%RX64\n", rc, fPageShw));
     821                        pgmUnlock(pVM);
    818822#   endif /* VBOX_STRICT */
    819823                        STAM_PROFILE_STOP(&pVCpu->pgm.s.StatRZTrap0eTimeOutOfSync, c);
     
    821825                        return VINF_SUCCESS;
    822826                    }
     827#   ifdef VBOX_STRICT
     828                    pgmUnlock(pVM);
     829#   endif
    823830
    824831                    /* Check to see if we need to emulate the instruction as X86_CR0_WP has been cleared. */
  • trunk/src/VBox/VMM/VMMAll/PGMAllShw.h

    r19903 r20068  
    146146    PVM pVM = pVCpu->CTX_SUFF(pVM);
    147147
     148    Assert(PGMIsLockOwner(pVM));
     149
    148150    /*
    149151     * Get the PDE.
Note: See TracChangeset for help on using the changeset viewer.

© 2024 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette