X-Git-Url: https://scm.lunaixsky.com/lunaix-os.git/blobdiff_plain/b0c2a4be2d1f4f93ab01d0858979a12ef0735ec1..12293ed1d71cd306ed9a5d021a79ba945fe4e680:/lunaix-os/includes/lunaix/mm/dmm.h diff --git a/lunaix-os/includes/lunaix/mm/dmm.h b/lunaix-os/includes/lunaix/mm/dmm.h index 22b0539..0a79cdc 100644 --- a/lunaix-os/includes/lunaix/mm/dmm.h +++ b/lunaix-os/includes/lunaix/mm/dmm.h @@ -2,6 +2,8 @@ #define __LUNAIX_DMM_H // Dynamic Memory (i.e., heap) Manager +#include +#include #include #define M_ALLOCATED 0x1 @@ -29,21 +31,14 @@ #define HEAP_INIT_SIZE 4096 -typedef struct -{ - void* start; - void* brk; - void* max_addr; -} heap_context_t; - - int dmm_init(heap_context_t* heap); int -lxsbrk(heap_context_t* heap, void* addr); +lxbrk(heap_context_t* heap, void* addr, int user); + void* -lxbrk(heap_context_t* heap, size_t size); +lxsbrk(heap_context_t* heap, size_t size, int user); void* lx_malloc_internal(heap_context_t* heap, size_t size);