KOS custom allocator extensions
More...
|
| file | malloc.h |
| | KOS-specific Allocator functionality.
|
| |
KOS custom allocator extensions
◆ DEFAULT_MMAP_MAX
| #define DEFAULT_MMAP_MAX 65536 |
◆ DEFAULT_MMAP_THRESHOLD
| #define DEFAULT_MMAP_THRESHOLD (256*1024) |
◆ DEFAULT_MXFAST
| #define DEFAULT_MXFAST 64 |
◆ DEFAULT_TOP_PAD
| #define DEFAULT_TOP_PAD 0 |
◆ DEFAULT_TRIM_THRESHOLD
| #define DEFAULT_TRIM_THRESHOLD (256*1024) |
◆ malloc_irq_safe()
| int malloc_irq_safe |
( |
void | | ) |
|
Determine if it is safe to call malloc() in an IRQ context.
This function checks the value of the internal spinlock that is used for malloc() to ensure that a call to it will not freeze the running process. This is only really useful in an IRQ context to ensure that a call to malloc() (or some other memory allocation function) won't cause a deadlock.
- Return values
-
| 1 | If it is safe to call malloc() in the current IRQ. |
| 0 | Otherwise. |
◆ mem_check_all()
| int mem_check_all |
( |
void | | ) |
|
Only available with KM_DBG.
◆ mem_check_block()
| int mem_check_block |
( |
void * | p | ) |
|
Only available with KM_DBG.