diff options
Diffstat (limited to 'include/libk/kmalloc.h')
-rw-r--r-- | include/libk/kmalloc.h | 19 |
1 files changed, 19 insertions, 0 deletions
diff --git a/include/libk/kmalloc.h b/include/libk/kmalloc.h new file mode 100644 index 0000000..6573d28 --- /dev/null +++ b/include/libk/kmalloc.h @@ -0,0 +1,19 @@ +#ifndef LIBK_KMALLOC_H +#define LIBK_KMALLOC_H + +#include <stdint.h> +#include <stddef.h> + +struct mem_block { + void *start; + size_t size; + int alloc; + struct mem_block *next; + struct mem_block *prev; +}; + +void kmalloc_init(void); +void* kmalloc(size_t sz); +void kfree(void *ptr); + +#endif |