From 1847436ad5b191a5ff00a468768bcbd6c6f1d710 Mon Sep 17 00:00:00 2001 From: Max Date: Mon, 14 Sep 2020 22:13:52 -0400 Subject: OSFreeToHeap matching besides SDA offset, OSAllocFromHeap almost matching besides register swap --- include/SDK/OS/OSAlloc.h | 7 +++++++ 1 file changed, 7 insertions(+) (limited to 'include/SDK') diff --git a/include/SDK/OS/OSAlloc.h b/include/SDK/OS/OSAlloc.h index 150a5f8..10edb01 100644 --- a/include/SDK/OS/OSAlloc.h +++ b/include/SDK/OS/OSAlloc.h @@ -6,6 +6,11 @@ extern "C" { #endif typedef struct Cell Cell; +typedef int OSHeapHandle; + +#if 0 +extern volatile OSHeapHandle __OSCurrHeap; // used in OSInitAlloc +#endif struct Cell { Cell* prev; @@ -14,6 +19,8 @@ struct Cell { }; Cell *DLInsert(Cell *original, Cell *inserted); +void *OSAllocFromHeap(OSHeapHandle heap, u32 size); +void OSFreeToHeap(OSHeapHandle heap, void *ptr); #ifdef __cplusplus } -- cgit v1.2.3