diff options
author | Marvin Borner | 2019-12-10 21:47:41 +0100 |
---|---|---|
committer | Marvin Borner | 2019-12-10 21:47:41 +0100 |
commit | 68915f46e66ed65ce2d32009fdfa2f5dca116842 (patch) | |
tree | 7d6df3e4dc6219422cc4b1faf909ff32a74b6edf /src/kernel/syscall/actions/sys_paging_alloc.c | |
parent | 33bdf18dad2539aca21727e95e04bfedecd37a76 (diff) |
Some syscalls and userspace stuff
sorry for the worse-getting commit messages...
Diffstat (limited to 'src/kernel/syscall/actions/sys_paging_alloc.c')
-rw-r--r-- | src/kernel/syscall/actions/sys_paging_alloc.c | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/src/kernel/syscall/actions/sys_paging_alloc.c b/src/kernel/syscall/actions/sys_paging_alloc.c new file mode 100644 index 0000000..fb4e415 --- /dev/null +++ b/src/kernel/syscall/actions/sys_paging_alloc.c @@ -0,0 +1,10 @@ +#include <stdint.h> +#include <kernel/paging/paging.h> +#include <kernel/io/io.h> + +uint32_t sys_paging_alloc(uint32_t count) +{ + uint32_t ptr = paging_alloc_pages((uint32_t) count); + paging_set_user(ptr, count); + return ptr; +}
\ No newline at end of file |