VirtualBox

Changeset 46567 in vbox for trunk/include/iprt


Ignore:
Timestamp:
Jun 14, 2013 4:12:24 PM (12 years ago)
Author:
vboxsync
svn:sync-xref-src-repo-rev:
86432
Message:

RTMemAllocEx for ring-3.

Location:
trunk/include/iprt
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/include/iprt/mangling.h

    r46298 r46567  
    812812# define RTMd5ToString                                  RT_MANGLER(RTMd5ToString)
    813813# define RTMd5Update                                    RT_MANGLER(RTMd5Update)
    814 # define RTMemAllocExTag                                RT_MANGLER(RTMemAllocExTag) /* r0drv */
     814# define RTMemAllocExTag                                RT_MANGLER(RTMemAllocExTag)
    815815# define RTMemAllocTag                                  RT_MANGLER(RTMemAllocTag)
    816816# define RTMemAllocVarTag                               RT_MANGLER(RTMemAllocVarTag)
     
    852852# define RTMemExecFree                                  RT_MANGLER(RTMemExecFree)
    853853# define RTMemFree                                      RT_MANGLER(RTMemFree)
    854 # define RTMemFreeEx                                    RT_MANGLER(RTMemFreeEx)     /* r0drv */
     854# define RTMemFreeEx                                    RT_MANGLER(RTMemFreeEx)
    855855# define RTMemPageAllocTag                              RT_MANGLER(RTMemPageAllocTag)
    856856# define RTMemPageAllocZTag                             RT_MANGLER(RTMemPageAllocZTag)
  • trunk/include/iprt/mem.h

    r45174 r46567  
    314314 * Will return VERR_NOT_SUPPORTED if not supported. */
    315315#define RTMEMALLOCEX_FLAGS_ANY_CTX          (RTMEMALLOCEX_FLAGS_ANY_CTX_ALLOC | RTMEMALLOCEX_FLAGS_ANY_CTX_FREE)
     316/** Reachable by 16-bit address.
     317 * Will return VERR_NOT_SUPPORTED if not supported.  */
     318#define RTMEMALLOCEX_FLAGS_16BIT_REACH      RT_BIT(4)
     319/** Reachable by 32-bit address.
     320 * Will return VERR_NOT_SUPPORTED if not supported.  */
     321#define RTMEMALLOCEX_FLAGS_32BIT_REACH      RT_BIT(5)
    316322/** Mask of valid flags. */
    317 #define RTMEMALLOCEX_FLAGS_VALID_MASK       UINT32_C(0x0000000f)
     323#define RTMEMALLOCEX_FLAGS_VALID_MASK       UINT32_C(0x0000003f)
     324/** Mask of valid flags for ring-0. */
     325#define RTMEMALLOCEX_FLAGS_VALID_MASK_R0    UINT32_C(0x0000000f)
    318326/** @}  */
    319327
     
    337345/**
    338346 * Extended heap allocation API, custom tag.
     347 *
     348 * Depending on the implementation, using this function may add extra overhead,
     349 * so use the simpler APIs where ever possible.
    339350 *
    340351 * @returns IPRT status code.
     
    358369 * @param   pv                  What to free, NULL is fine.
    359370 * @param   cb                  The amount of allocated memory.
     371 * @param   fFlags              The flags specified when allocating the memory.
     372 *                              Whether the exact flags are requires depends on
     373 *                              the implementation, but in general, ring-0
     374 *                              doesn't require anything while ring-3 requires
     375 *                              RTMEMALLOCEX_FLAGS_EXEC if used.
    360376 */
    361377RTDECL(void) RTMemFreeEx(void *pv, size_t cb) RT_NO_THROW;
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