VirtualBox

Changeset 23610 in vbox for trunk/include/iprt


Ignore:
Timestamp:
Oct 7, 2009 9:22:10 PM (15 years ago)
Author:
vboxsync
svn:sync-xref-src-repo-rev:
53284
Message:

IPRT,VMM,SUPDrv,VBGLR0: Added a parameter to RTR0MemObjLockUser/Kernel that indicates read/write intent so we can correctly lock readonly memory on Windows and OS/2. (Guest property strings, see #4238.)

File:
1 edited

Legend:

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

    r20525 r23610  
    146146 * @returns IPRT status code.
    147147 * @param   pMemObj         Where to store the ring-0 memory object handle.
    148  * @param   R3Ptr           User virtual address. This is rounded down to a page boundrary.
    149  * @param   cb              Number of bytes to lock. This is rounded up to nearest page boundrary.
    150  * @param   R0Process       The process to lock pages in. NIL_R0PROCESS is an alias for the current one.
    151  *
    152  * @remarks RTR0MemGetAddressR3() and RTR0MemGetAddress() will return the rounded
     148 * @param   R3Ptr           User virtual address. This is rounded down to a page
     149 *                          boundrary.
     150 * @param   cb              Number of bytes to lock. This is rounded up to
     151 *                          nearest page boundrary.
     152 * @param   fAccess         The desired access, a combination of RTMEM_PROT_READ
     153 *                          and RTMEM_PROT_WRITE.
     154 * @param   R0Process       The process to lock pages in. NIL_R0PROCESS is an
     155 *                          alias for the current one.
     156 *
     157 * @remarks RTR0MemGetAddressR3() and RTR0MemGetAddress() will return therounded
    153158 *          down address.
     159 *
    154160 * @remarks Linux: This API requires that the memory begin locked is in a memory
    155161 *          mapping that is not required in any forked off child process. This
     
    157163 *          lifting it.
    158164 */
    159 RTR0DECL(int) RTR0MemObjLockUser(PRTR0MEMOBJ pMemObj, RTR3PTR R3Ptr, size_t cb, RTR0PROCESS R0Process);
     165RTR0DECL(int) RTR0MemObjLockUser(PRTR0MEMOBJ pMemObj, RTR3PTR R3Ptr, size_t cb, uint32_t fAccess, RTR0PROCESS R0Process);
    160166
    161167/**
     
    166172 * @param   pv              Kernel virtual address. This is rounded down to a page boundrary.
    167173 * @param   cb              Number of bytes to lock. This is rounded up to nearest page boundrary.
     174 * @param   fAccess         The desired access, a combination of RTMEM_PROT_READ
     175 *                          and RTMEM_PROT_WRITE.
    168176 *
    169177 * @remark  RTR0MemGetAddress() will return the rounded down address.
    170178 */
    171 RTR0DECL(int) RTR0MemObjLockKernel(PRTR0MEMOBJ pMemObj, void *pv, size_t cb);
     179RTR0DECL(int) RTR0MemObjLockKernel(PRTR0MEMOBJ pMemObj, void *pv, size_t cb, uint32_t fAccess);
    172180
    173181/**
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