Memory Blocks Allocator.
More...
Go to the source code of this file.
|
#define | MAX_MULTI_ALLOCATORS 8 |
|
#define | SYS_MEM_BLOCKS_DEFINE(name, blk_sz, num_blks, buf_align) |
| Create a memory block object with a new backing buffer.
|
|
#define | SYS_MEM_BLOCKS_DEFINE_STATIC(name, blk_sz, num_blks, buf_align) |
| Create a static memory block object with a new backing buffer.
|
|
#define | SYS_MEM_BLOCKS_DEFINE_WITH_EXT_BUF(name, blk_sz, num_blks, buf) |
| Create a memory block object with a providing backing buffer.
|
|
#define | SYS_MEM_BLOCKS_DEFINE_STATIC_WITH_EXT_BUF(name, blk_sz, num_blks, buf) |
| Create a static memory block object with a providing backing buffer.
|
|
|
int | sys_mem_blocks_alloc (sys_mem_blocks_t *mem_block, size_t count, void **out_blocks) |
| Allocate multiple memory blocks.
|
|
int | sys_mem_blocks_alloc_contiguous (sys_mem_blocks_t *mem_block, size_t count, void **out_block) |
| Allocate a contiguous set of memory blocks.
|
|
int | sys_mem_blocks_get (sys_mem_blocks_t *mem_block, void *in_block, size_t count) |
| Force allocation of a specified blocks in a memory block object.
|
|
int | sys_mem_blocks_is_region_free (sys_mem_blocks_t *mem_block, void *in_block, size_t count) |
| check if the region is free
|
|
int | sys_mem_blocks_free (sys_mem_blocks_t *mem_block, size_t count, void **in_blocks) |
| Free multiple memory blocks.
|
|
int | sys_mem_blocks_free_contiguous (sys_mem_blocks_t *mem_block, void *block, size_t count) |
| Free contiguous multiple memory blocks.
|
|
void | sys_multi_mem_blocks_init (sys_multi_mem_blocks_t *group, sys_multi_mem_blocks_choice_fn_t choice_fn) |
| Initialize multi memory blocks allocator group.
|
|
void | sys_multi_mem_blocks_add_allocator (sys_multi_mem_blocks_t *group, sys_mem_blocks_t *alloc) |
| Add an allocator to an allocator group.
|
|
int | sys_multi_mem_blocks_alloc (sys_multi_mem_blocks_t *group, void *cfg, size_t count, void **out_blocks, size_t *blk_size) |
| Allocate memory from multi memory blocks allocator group.
|
|
int | sys_multi_mem_blocks_free (sys_multi_mem_blocks_t *group, size_t count, void **in_blocks) |
| Free memory allocated from multi memory blocks allocator group.
|
|
◆ MAX_MULTI_ALLOCATORS
#define MAX_MULTI_ALLOCATORS 8 |