VirtualBox

Changeset 82897 in vbox for trunk


Ignore:
Timestamp:
Jan 28, 2020 10:47:20 PM (5 years ago)
Author:
vboxsync
Message:

PGMPool: PGMR0PoolGrow should return failure when allocating the first batch of pages fails. It and the caller PGMR3PoolGrow should report the incident to the release log. [adjustments] bugref:9627

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

Legend:

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

    r82896 r82897  
    49954995        int rc = VMMRZCallRing3NoCpu(pVM, VMMCALLRING3_PGM_POOL_GROW, 0);
    49964996#endif
    4997         if (rc == VINF_SUCCESS)
    4998         { /* likely */ }
    4999         else
    5000         {
    5001             if (RT_FAILURE(rc))
    5002                 return rc;
    5003         }
    5004 
     4997        if (RT_FAILURE(rc))
     4998            return rc;
    50054999        STAM_PROFILE_ADV_RESUME(&pPool->StatAlloc, a);
    50065000        if (pPool->iFreeHead != NIL_PGMPOOL_IDX)
  • trunk/src/VBox/VMM/VMMR0/PGMR0Pool.cpp

    r82896 r82897  
    141141            RTR0MemObjFree(hMemObj, true /*fFreeMappings*/);
    142142        }
    143         if (cCurPages > 0)
    144             rc = -rc;
     143        if (cCurPages > 64)
     144            LogRelMax(5, ("PGMR0PoolGrow: rc=%Rrc cNewPages=%#x cCurPages=%#x cMaxPages=%#x fCanUseHighMemory=%d\n",
     145                          rc, cNewPages, cCurPages, cMaxPages, fCanUseHighMemory));
    145146        else
    146147            LogRel(("PGMR0PoolGrow: rc=%Rrc cNewPages=%#x cCurPages=%#x cMaxPages=%#x fCanUseHighMemory=%d\n",
  • trunk/src/VBox/VMM/VMMR3/PGMPool.cpp

    r82896 r82897  
    490490    LogRel(("PGMR3PoolGrow: rc=%Rrc cCurPages=%#x cMaxPages=%#x\n",
    491491            rc, pVM->pgm.s.pPoolR3->cCurPages, pVM->pgm.s.pPoolR3->cMaxPages));
     492    if (pVM->pgm.s.pPoolR3->cCurPages > 128 && RT_FAILURE_NP(rc))
     493        return -rc;
    492494    return rc;
    493495}
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