VirtualBox

Ignore:
Timestamp:
May 20, 2010 9:22:44 PM (15 years ago)
Author:
vboxsync
Message:

memobj-r0drv-freebsd.c: Correct range checks

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/Runtime/r0drv/freebsd/memobj-r0drv-freebsd.c

    r29711 r29714  
    5555#endif
    5656
     57/**
     58 * Check whether we can use kmem_alloc_attr for low allocs.
     59 */
     60#if    (__FreeBSD_version >= 900000 && __FreeBSD_version >= 900011) \
     61    || (__FreeBSD_version >= 800000 && __FreeBSD_version >= 800505) \
     62    || (__FreeBSD_version >= 700000 && __FreeBSD_version >= 703101)
     63# define USE_KMEM_ALLOC_ATTR
     64#endif
     65
    5766/*******************************************************************************
    5867*   Structures and Typedefs                                                    *
     
    215224        }
    216225
    217 #if (__FreeBSD_version >= 900011) || (__FreeBSD_version >= 800505) || (__FreeBSD_version >= 703101)
     226#ifdef USE_KMEM_ALLOC_ATTR
    218227        case RTR0MEMOBJTYPE_LOW:
    219228        {
     
    322331int rtR0MemObjNativeAllocLow(PPRTR0MEMOBJINTERNAL ppMem, size_t cb, bool fExecutable)
    323332{
    324 #if (__FreeBSD_version >= 900011) || (__FreeBSD_version >= 800505) || (__FreeBSD_version >= 703101)
     333#ifdef USE_KMEM_ALLOC_ATTR
    325334    /*
    326335     * Use kmem_alloc_attr, fExectuable is not needed because the
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