From 68915f46e66ed65ce2d32009fdfa2f5dca116842 Mon Sep 17 00:00:00 2001 From: Marvin Borner Date: Tue, 10 Dec 2019 21:47:41 +0100 Subject: Some syscalls and userspace stuff sorry for the worse-getting commit messages... --- src/kernel/syscall/actions/sys_paging_alloc.c | 10 ++++++++++ 1 file changed, 10 insertions(+) create mode 100644 src/kernel/syscall/actions/sys_paging_alloc.c (limited to 'src/kernel/syscall/actions/sys_paging_alloc.c') 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 +#include +#include + +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 -- cgit v1.2.3