Functions | |
| void | NvOsMemcpy (void *dest, const void *src, size_t size) |
| This function copy to destination pointer from source pointer, and copying length is given as size parameter. More... | |
| void * | NvOsAllocAlign (size_t align, size_t size) |
| This function allocates aligned memory. More... | |
| void * | NvOsAlloc (size_t size) |
| This function returns the allocated memory dynamically, and allocated memory is not initialized. More... | |
| void | NvOsFree (void *ptr) |
| This function free the allocated memory. More... | |
| void | NvOsMemset (void *s, NvU8 c, size_t size) |
| This function initializes the memory with the c parameter, And the length of initializing memory, is give the size parameter as bytes. More... | |
| void * | NvOsRealloc (void *ptr, size_t size) |
| This function resizes the allocated memory as the size parameter. More... | |
| int32_t | NvOsTypeMemInit (const char *typ_mem_name, int32_t *handle) |
| Open type memory specified by typ_mem_name and return the handle to the typed memory. More... | |
| int32_t | NvOsTypeMemDeinit (int32_t handle) |
| Close typed memory handle. More... | |
| void * | NvOsAllocTypeMemCached (int32_t handle, size_t size, uint32_t flags, int64_t *paddr) |
| Allocate cached typed memory. More... | |
| void * | NvOsAllocTypeMemUncached (int32_t handle, size_t size, uint32_t flags, int64_t *paddr) |
| Allocate non-cached typed memory. More... | |
| int32_t | NvOsTypeMemFree (size_t size, void *ptr) |
| Frees the previously allocated memory. This function removes any mappings for pages in the address range starting at ptr (passed as input parameter) and continuing for size (passed as input parameter) bytes, rounded up to the next multiple of the page size. References to unmapped pages cause a SIGSEGV signalto be set on the process. If there are no mappings in the specified address range, then this call has no effect. More... | |
| void* NvOsAlloc | ( | size_t | size | ) |
This function returns the allocated memory dynamically, and allocated memory is not initialized.
| [in] | size | The size to allocate memory, as bytes |
Usage considerations
| void* NvOsAllocAlign | ( | size_t | align, |
| size_t | size | ||
| ) |
This function allocates aligned memory.
| [in] | align | Followed/passed to alignment parameter of posix_memalign() in QNX libc |
| [in] | size | Memory size to allocate as bytes, passed to size parameter of posix_memalign() in QNX libc |
Usage considerations
| void* NvOsAllocTypeMemCached | ( | int32_t | handle, |
| size_t | size, | ||
| uint32_t | flags, | ||
| int64_t * | paddr | ||
| ) |
Allocate cached typed memory.
| [in] | handle | handle to typed memory which is opened by NvOsTypeMemInit() call. |
| [in] | size | size of memory to be allocated. It should not be 0. |
| [in] | flags | flags to be used for mmap, limited to MAP_NOINHERIT. |
| [out] | paddr | returning physical address of the allocated memory |
Usage considerations
| void* NvOsAllocTypeMemUncached | ( | int32_t | handle, |
| size_t | size, | ||
| uint32_t | flags, | ||
| int64_t * | paddr | ||
| ) |
Allocate non-cached typed memory.
| [in] | handle | handle to typed memory which is opened by NvOsTypeMemInit() call. |
| [in] | size | size of memory to be allocated |
| [in] | flags | flags to be used for mmap, limited to MAP_NOINHERIT. |
| [out] | paddr | returning physical address of the allocated memory |
Usage considerations
This function free the allocated memory.
| [in] | ptr | The pointer of allocated memory |
Usage considerations
This function copy to destination pointer from source pointer, and copying length is given as size parameter.
| [out] | dest | Destination memory pointer |
| [in] | src | Source memory pointer |
| [in] | size | Copying length as bytes |
Usage considerations
This function initializes the memory with the c parameter, And the length of initializing memory, is give the size parameter as bytes.
| [out] | s | Memory pointer will be initialized with c parameter |
| [in] | c | s parameter is initialized with c parameter |
| [in] | size | Length of initializing memory, as bytes |
Usage considerations
This function resizes the allocated memory as the size parameter.
| [in] | ptr | Allocated memory pointer |
| [in] | size | New size of allocated memory as bytes |
Usage considerations
| int32_t NvOsTypeMemDeinit | ( | int32_t | handle | ) |
Close typed memory handle.
| [in] | handle | handle to typed memory which is opened by NvOsTypeMemInit() call. |
Usage considerations
| int32_t NvOsTypeMemFree | ( | size_t | size, |
| void * | ptr | ||
| ) |
Frees the previously allocated memory. This function removes any mappings for pages in the address range starting at ptr (passed as input parameter) and continuing for size (passed as input parameter) bytes, rounded up to the next multiple of the page size. References to unmapped pages cause a SIGSEGV signalto be set on the process. If there are no mappings in the specified address range, then this call has no effect.
| [in] | size | Size of the memory to free. |
| [in] | ptr | A pointer to the memory to be freed. |
Usage considerations
| int32_t NvOsTypeMemInit | ( | const char * | typ_mem_name, |
| int32_t * | handle | ||
| ) |
Open type memory specified by typ_mem_name and return the handle to the typed memory.
| [in] | typ_mem_name | typed memory name |
| [out] | handle | handle to typed memory |
Usage considerations