VirtualBox

Changeset 41069 in vbox for trunk/src/VBox/Runtime


Ignore:
Timestamp:
Apr 26, 2012 12:01:00 PM (13 years ago)
Author:
vboxsync
svn:sync-xref-src-repo-rev:
77637
Message:

GMMR0,memobj-r0drv-darwin.cpp: Moved the allocate fudge factor from GMMR0 to the darwin code. Mystery still unsolved, thought to be related to various panics as well.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/Runtime/r0drv/darwin/memobj-r0drv-darwin.cpp

    r41060 r41069  
    426426     * The kIOMemoryKernelUserShared flag just forces the result to be page aligned.
    427427     */
     428#if 1 /** @todo Figure out why this is broken. Is it only on snow leopard? Seen allocating memory for the VM structure, last page corrupted or inaccessible. */
     429    size_t const cbFudged = cb + PAGE_SIZE;
     430#else
     431    size_t const cbFudged = cb;
     432#endif
    428433    int rc;
    429434    IOBufferMemoryDescriptor *pMemDesc =
     
    432437                                                         | kIODirectionInOut
    433438                                                         | (fContiguous ? kIOMemoryPhysicallyContiguous : 0),
    434                                                          cb,
     439                                                         cbFudged,
    435440                                                         PhysMask);
    436441    if (pMemDesc)
     
    439444        if (IORet == kIOReturnSuccess)
    440445        {
    441             void *pv = pMemDesc->getBytesNoCopy(0, cb);
     446            void *pv = pMemDesc->getBytesNoCopy(0, cbFudged);
    442447            if (pv)
    443448            {
Note: See TracChangeset for help on using the changeset viewer.

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