diff options
Diffstat (limited to 'src/kernel/syscall')
-rw-r--r-- | src/kernel/syscall/actions/sys_paging_alloc.c | 1 | ||||
-rw-r--r-- | src/kernel/syscall/actions/sys_read.c | 1 | ||||
-rw-r--r-- | src/kernel/syscall/actions/sys_write.c | 2 | ||||
-rw-r--r-- | src/kernel/syscall/syscall.c | 7 |
4 files changed, 4 insertions, 7 deletions
diff --git a/src/kernel/syscall/actions/sys_paging_alloc.c b/src/kernel/syscall/actions/sys_paging_alloc.c index fb4e415..57ffd39 100644 --- a/src/kernel/syscall/actions/sys_paging_alloc.c +++ b/src/kernel/syscall/actions/sys_paging_alloc.c @@ -1,6 +1,5 @@ #include <stdint.h> #include <kernel/paging/paging.h> -#include <kernel/io/io.h> uint32_t sys_paging_alloc(uint32_t count) { diff --git a/src/kernel/syscall/actions/sys_read.c b/src/kernel/syscall/actions/sys_read.c index 83e645c..ed2cca8 100644 --- a/src/kernel/syscall/actions/sys_read.c +++ b/src/kernel/syscall/actions/sys_read.c @@ -3,7 +3,6 @@ #include <kernel/input/input.h> #include <kernel/lib/lib.h> #include <kernel/lib/string.h> -#include <kernel/io/io.h> uint32_t sys_read(char *buf) { diff --git a/src/kernel/syscall/actions/sys_write.c b/src/kernel/syscall/actions/sys_write.c index d395384..76d88b8 100644 --- a/src/kernel/syscall/actions/sys_write.c +++ b/src/kernel/syscall/actions/sys_write.c @@ -1,7 +1,6 @@ #include <stdint.h> #include <kernel/lib/stdio.h> #include <kernel/lib/string.h> -#include <kernel/io/io.h> uint32_t sys_write(char *buf) { @@ -11,7 +10,6 @@ uint32_t sys_write(char *buf) uint32_t sys_writec(char ch) { - serial_write_hex(ch); writec((char) ch); return 0; }
\ No newline at end of file diff --git a/src/kernel/syscall/syscall.c b/src/kernel/syscall/syscall.c index 7d5420d..5f32c42 100644 --- a/src/kernel/syscall/syscall.c +++ b/src/kernel/syscall/syscall.c @@ -1,9 +1,8 @@ #include <stdint.h> #include <kernel/syscall/syscall.h> #include <kernel/interrupts/interrupts.h> -#include <kernel/io/io.h> -#include <kernel/paging/paging.h> #include <kernel/system.h> +#include <kernel/lib/stdio.h> typedef uint32_t (*syscall_func)(unsigned int, ...); @@ -20,7 +19,7 @@ uint32_t (*syscalls[])() = { void syscall_handler(struct regs *r) { - serial_write("Received syscall!\n"); + serial_printf("Received syscall!"); if (r->eax >= sizeof(syscalls) / sizeof(*syscalls)) return; @@ -29,6 +28,8 @@ void syscall_handler(struct regs *r) if (!location) return; + //serial_printf("[SYSCALL] %d (0x%x) 0x%x 0x%x 0x%x 0x%x 0x%x", r->eax, location, r->ebx, r->ecx, r->edx, r->esi, r->edi); + r->eax = location(r->ebx, r->ecx, r->edx, r->esi, r->edi); } |