From e07894d21a0101b10ee6ad851773b725cbb9150d Mon Sep 17 00:00:00 2001 From: Marvin Borner Date: Wed, 15 Apr 2020 21:17:41 +0200 Subject: Used macro magic to implement function-based logs --- src/kernel/syscall/syscall.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'src/kernel/syscall/syscall.c') diff --git a/src/kernel/syscall/syscall.c b/src/kernel/syscall/syscall.c index d8bc4b8..1454198 100644 --- a/src/kernel/syscall/syscall.c +++ b/src/kernel/syscall/syscall.c @@ -17,7 +17,7 @@ uint32_t (*syscalls[])() = { [0] = (uint32_t(*)())halt_loop, // DEBUG! void syscall_handler(struct regs *r) { - serial_printf("Received syscall!"); + log("Received syscall!"); if (r->eax >= sizeof(syscalls) / sizeof(*syscalls)) return; @@ -26,8 +26,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); + log("[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); } -- cgit v1.2.3