Kernel: kmalloc has now somewhat dynamic storage
Allocations bigger than PAGE_SIZE and those not forced to be identity mapped are now done on a GeneralAllocator. This allows us to use kmalloc for big allocations; bigger than the fixed 1 MiB storage. This is still a hack and the whole kmalloc will have to be rewritten at some point, but for now this does the job :D
This commit is contained in:
@@ -1,10 +1,15 @@
|
||||
#pragma once
|
||||
|
||||
#include <BAN/Optional.h>
|
||||
#include <kernel/Memory/Types.h>
|
||||
|
||||
#include <stddef.h>
|
||||
|
||||
void kmalloc_initialize();
|
||||
void kmalloc_dump_info();
|
||||
|
||||
void* kmalloc(size_t);
|
||||
void* kmalloc(size_t, size_t);
|
||||
void* kmalloc(size_t size);
|
||||
void* kmalloc(size_t size, size_t align, bool force_identity_map = false);
|
||||
void kfree(void*);
|
||||
|
||||
BAN::Optional<Kernel::paddr_t> kmalloc_paddr_of(Kernel::vaddr_t);
|
||||
|
||||
Reference in New Issue
Block a user