VirtualBox

Changeset 14591 in vbox for trunk/src


Ignore:
Timestamp:
Nov 25, 2008 7:53:49 PM (16 years ago)
Author:
vboxsync
Message:

MMPagePool: SUPPageAlloc/SUPPageLock -> SUPR3PageAllocEx.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/VMM/MMPagePool.cpp

    r14589 r14591  
    122122        while (pSubPool)
    123123        {
    124             int rc = SUPPageUnlock(pSubPool->pvPages);
    125             AssertMsgRC(rc, ("SUPPageUnlock(%p) failed with rc=%d\n", pSubPool->pvPages, rc));
    126             rc = SUPPageFree(pSubPool->pvPages, pSubPool->cPages);
    127             AssertMsgRC(rc, ("SUPPageFree(%p) failed with rc=%d\n", pSubPool->pvPages, rc));
     124            int rc = SUPR3PageFreeEx(pSubPool->pvPages, pSubPool->cPages);
     125            AssertMsgRC(rc, ("SUPPageFree(%p) failed with rc=%Rrc\n", pSubPool->pvPages, rc));
    128126            pSubPool->pvPages = NULL;
    129127
     
    250248    if (!pPool->fLow)
    251249    {
    252         /*
    253          * Allocate and lock the pages.
    254          */
    255         rc = SUPPageAlloc(cPages, &pSub->pvPages);
     250        rc = SUPR3PageAllocEx(cPages,
     251                              0 /* fFlags */,
     252                              &pSub->pvPages,
     253                              NULL,
     254                              paPhysPages);
    256255        if (RT_SUCCESS(rc))
    257         {
    258             rc = SUPPageLock(pSub->pvPages, cPages, paPhysPages);
    259             if (RT_FAILURE(rc))
    260             {
    261                 SUPPageFree(pSub->pvPages, cPages);
    262                 rc = VMSetError(pPool->pVM, rc, RT_SRC_POS,
    263                                 N_("Failed to lock host %zd bytes of memory (out of memory)"), (size_t)cPages << PAGE_SHIFT);
    264             }
    265         }
     256            rc = VMSetError(pPool->pVM, rc, RT_SRC_POS,
     257                            N_("Failed to lock host %zd bytes of memory (out of memory)"), (size_t)cPages << PAGE_SHIFT);
    266258    }
    267259    else
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