flipperzero-firmware/firmware/targets/local/fatfs/heap.h
DrZlo13 59740349fa
furi memory managment (#177)
* memory managment calls now forwarded to freertos heap

* memory managment tests

* local target test compability

* rename heap.c file to heap_4.c for local target and explicity init heap in single thread context

* rebase BlockLink_t struct

* check mutex in local heap

Co-authored-by: aanper <mail@s3f.ru>
2020-10-15 20:36:15 +03:00

37 lines
755 B
C

#include <stdbool.h>
#include <stdlib.h>
#include <stdint.h>
#include <cmsis_os.h>
#define configTOTAL_HEAP_SIZE ((size_t)(8192 * 16))
#define configAPPLICATION_ALLOCATED_HEAP 0
#define portBYTE_ALIGNMENT 8
#if portBYTE_ALIGNMENT == 8
#define portBYTE_ALIGNMENT_MASK (0x0007)
#endif
/* No test marker by default. */
#ifndef mtCOVERAGE_TEST_MARKER
#define mtCOVERAGE_TEST_MARKER()
#endif
/* No tracing by default. */
#ifndef traceMALLOC
#define traceMALLOC(pvReturn, xWantedSize)
#endif
/* No tracing by default. */
#ifndef traceFREE
#define traceFREE(pvReturn, xBlockSize)
#endif
/* No assert by default. */
#ifndef configASSERT
#define configASSERT(var)
#endif
bool prvHeapInit(void);
void acquire_memalloc_mutex();
void release_memalloc_mutex();