virtmem: Deprecate virtmemReserve/virtmemFree

This commit is contained in:
fincs 2020-10-30 16:10:52 +01:00
parent 8310f438ca
commit 22a3efcbe1
No known key found for this signature in database
GPG Key ID: 62C7609ADA219C60

View File

@ -14,15 +14,17 @@ typedef struct VirtmemReservation VirtmemReservation;
* @brief Reserves a slice of general purpose address space sequentially. * @brief Reserves a slice of general purpose address space sequentially.
* @param size Desired size of the slice (rounded up to page alignment). * @param size Desired size of the slice (rounded up to page alignment).
* @return Pointer to the slice of address space. * @return Pointer to the slice of address space.
* @deprecated This function is prone to race conditions, please use \ref virtmemFindAslr or \ref virtmemFindCodeMemory (and, if necessary, \ref virtmemAddReservation) instead.
*/ */
void* virtmemReserve(size_t size); void* DEPRECATED virtmemReserve(size_t size);
/** /**
* @brief Relinquishes a slice of address space reserved with virtmemReserve (currently no-op). * @brief Relinquishes a slice of address space reserved with virtmemReserve (currently no-op).
* @param addr Pointer to the slice. * @param addr Pointer to the slice.
* @param size Size of the slice. * @param size Size of the slice.
* @deprecated This function is a companion of \ref virtmemReserve which is deprecated.
*/ */
void virtmemFree(void* addr, size_t size); void DEPRECATED virtmemFree(void* addr, size_t size);
/// Locks the virtual memory manager mutex. /// Locks the virtual memory manager mutex.
void virtmemLock(void); void virtmemLock(void);