VirtualBox

Ignore:
Timestamp:
Jun 28, 2023 10:26:46 AM (19 months ago)
Author:
vboxsync
Message:

Runtime/r3/posix: Replace occurences of PAGE_SIZE/PAGE_OFFSET_MASK with RTSystemGetPageSize()/RTSystemGetPageOffsetMask() in code which is used by the linux.arm64 guest additions, bugref:10476

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/Runtime/r3/posix/rtmempage-exec-mmap-posix.cpp

    r98103 r100310  
    4747#include <iprt/param.h>
    4848#include <iprt/string.h>
     49#include <iprt/system.h>
    4950
    5051#include <stdlib.h>
     
    106107    Assert(cb > 0);
    107108    NOREF(pszTag);
    108     cb = RT_ALIGN_Z(cb, PAGE_SIZE);
     109    cb = RTSystemPageAlignSize(cb);
    109110
    110111    /*
     
    143144    AssertPtr(pv);
    144145    Assert(cb > 0);
    145     Assert(!((uintptr_t)pv & PAGE_OFFSET_MASK));
    146     cb = RT_ALIGN_Z(cb, PAGE_SIZE);
     146    Assert(!((uintptr_t)pv & RTSystemGetPageOffsetMask()));
     147    cb = RTSystemPageAlignSize(cb);
    147148
    148149    /*
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