diff options
author | Marvin Borner | 2020-05-07 00:16:52 +0200 |
---|---|---|
committer | Marvin Borner | 2020-05-07 00:16:52 +0200 |
commit | 31767b532e69c5a63df0106fa08e137e3106a449 (patch) | |
tree | ea7a91347e030c0b120361b7d9975547a5af19d1 /src/kernel/syscall | |
parent | 8083536f321ad8a12ad4668c2bf41a65c3e3b2f6 (diff) |
Some fixes here and there...
Also implemented serial console in userspace
Diffstat (limited to 'src/kernel/syscall')
-rw-r--r-- | src/kernel/syscall/actions/sys_map.c | 2 | ||||
-rw-r--r-- | src/kernel/syscall/syscall.c | 2 | ||||
-rw-r--r-- | src/kernel/syscall/syscall.h | 2 |
3 files changed, 3 insertions, 3 deletions
diff --git a/src/kernel/syscall/actions/sys_map.c b/src/kernel/syscall/actions/sys_map.c index 63bfd9d..441722e 100644 --- a/src/kernel/syscall/actions/sys_map.c +++ b/src/kernel/syscall/actions/sys_map.c @@ -1,7 +1,7 @@ #include <stdint.h> #include <events/event.h> -u32 sys_map(u32 id, u32 *function) +u32 sys_map(u32 id, u8 *function) { event_map(id, function); return -1; diff --git a/src/kernel/syscall/syscall.c b/src/kernel/syscall/syscall.c index 820afc7..958428a 100644 --- a/src/kernel/syscall/syscall.c +++ b/src/kernel/syscall/syscall.c @@ -35,7 +35,7 @@ void syscall_handler(struct regs *r) log("[SYSCALL] %d at [0x%x] with 0x%x 0x%x 0x%x 0x%x", r->eax, location, r->ebx, r->ecx, r->edx, r->esi, r->edi); - if (r->eax == 2) // TODO: Fix hardcoded fork parameters + if (r->eax == SYS_FORK) // TODO: Fix hardcoded fork parameters r->eax = location(r); else r->eax = location(r->ebx, r->ecx, r->edx, r->esi, r->edi); diff --git a/src/kernel/syscall/syscall.h b/src/kernel/syscall/syscall.h index 0cfa3a7..bc52e74 100644 --- a/src/kernel/syscall/syscall.h +++ b/src/kernel/syscall/syscall.h @@ -26,6 +26,6 @@ u32 sys_free(u32 ptr); u32 sys_get(u32 id); -u32 sys_map(u32 id, u32 *function); +u32 sys_map(u32 id, u8 *function); #endif
\ No newline at end of file |