diff options
Diffstat (limited to 'kc/core')
| -rw-r--r-- | kc/core/Makefile | 3 | ||||
| -rw-r--r-- | kc/core/kcc_memory.c | 16 | ||||
| -rw-r--r-- | kc/core/memory.c | 2 |
3 files changed, 19 insertions, 2 deletions
diff --git a/kc/core/Makefile b/kc/core/Makefile index 7458ba5..b0f4035 100644 --- a/kc/core/Makefile +++ b/kc/core/Makefile @@ -12,7 +12,8 @@ CFLAGS += -Wno-unused-const-variable -Wno-unused-function -fvisibility=hidden -g SOBJS := GOBJS := entry_x86_64.o reloc_x86_64.o kprint.o serial.o port.o \ kc_main.o main.o memory.o memset.o memcpy.o memmove.o memcmp.o cpu.o \ - vm_tree.o exceptions.o panic.o msr.o task.o cpu_task.o + vm_tree.o exceptions.o panic.o msr.o task.o cpu_task.o \ + kcc_memory.o IOBJS := # __attribute__((interrupt)) requires -mgeneral-regs-only diff --git a/kc/core/kcc_memory.c b/kc/core/kcc_memory.c new file mode 100644 index 0000000..68aa1d4 --- /dev/null +++ b/kc/core/kcc_memory.c @@ -0,0 +1,16 @@ +#include "memory.h" + +#include <kc/core/memory.h> + +KC_EXPORT +kc_phys_addr kcc_page_alloc(void) +{ + return page_alloc(); +} + +KC_EXPORT +void kcc_page_free(kc_phys_addr page) +{ + page_free(page); +} + diff --git a/kc/core/memory.c b/kc/core/memory.c index 2d5dd75..634c3b3 100644 --- a/kc/core/memory.c +++ b/kc/core/memory.c @@ -6,7 +6,7 @@ #include <stdint.h> -#include <kernel/component.h> +#include <kc/kc.h> /* kernel virtual space guarantees * |
