diff options
author | Jon Santmyer <jon@jonsantmyer.com> | 2025-08-19 15:04:04 -0400 |
---|---|---|
committer | Jon Santmyer <jon@jonsantmyer.com> | 2025-08-19 15:04:04 -0400 |
commit | 858a52c06a4615bd58a6a906333f2ad707d41c0a (patch) | |
tree | 16870cd4d67da283567a72a74d28c04464da292a /lib/libjove/include/syscall.h | |
parent | 65ba015d6c1f248d36ad01a653bc49637804b15b (diff) | |
download | jove-os-858a52c06a4615bd58a6a906333f2ad707d41c0a.tar.gz jove-os-858a52c06a4615bd58a6a906333f2ad707d41c0a.tar.bz2 jove-os-858a52c06a4615bd58a6a906333f2ad707d41c0a.zip |
usermode pager
Diffstat (limited to 'lib/libjove/include/syscall.h')
-rw-r--r-- | lib/libjove/include/syscall.h | 11 |
1 files changed, 7 insertions, 4 deletions
diff --git a/lib/libjove/include/syscall.h b/lib/libjove/include/syscall.h index 432be85..5d872a3 100644 --- a/lib/libjove/include/syscall.h +++ b/lib/libjove/include/syscall.h @@ -7,25 +7,28 @@ #include <jove/object.h> #define SYSCALL_PAYLOAD_PUTL(buf, at, v, type) \ - if(at + sizeof(type) > KO_MESSAGE_BYTES) return -1; \ + if(at + sizeof(type) > KO_MESSAGE_BYTES) return EJOVE_TOOBIG; \ *((type*)(&buf[at])) = v; \ at += sizeof(type) #define SYSCALL_PAYLOAD_SAVEPTR(buf, at, type, val) \ - if(at + sizeof(type) >= KO_MESSAGE_BYTES) return -1; \ + if(at + sizeof(type) >= KO_MESSAGE_BYTES) return EJOVE_TOOBIG; \ val = (type*)(&buf[at]); \ at += sizeof(type) #define SYSCALL_PAYLOAD_PUTOBJ(buf, at, obj) \ at = path_tobuf(JOVE_OBJECT_TYPED(obj), buf, at, KO_MESSAGE_BYTES); \ - if(at < 0) return at + if(at < 0) return -at int _syscall_invoke(void); void _syscall_debug_putc(char c); -int _syscall_invoke_objdir_nmemb(KernelObjectDirectory *dir, uint8_t *result); int _syscall_invoke_objdir_getmemb(KernelObjectDirectory *dir, uint8_t member, obj_type_t *result); +int _syscall_invoke_objdir_lastmemb(KernelObjectDirectory *dir, uint8_t *result); +int _syscall_invoke_objdir_move( + KernelObjectDirectory *dir, uint8_t memb, + KernelObjectDirectory *dest_dir, uint8_t dest_memb); int _syscall_invoke_untyped_size(KernelObjectUntyped *untyped, size_t *bytes); int _syscall_invoke_untyped_split(KernelObjectUntyped *path, size_t bytes, KernelObjectUntyped *dest); |