From 4f8e35e4094edd88953b189385b116c4601d2909 Mon Sep 17 00:00:00 2001 From: "Justin C. Miller" Date: Thu, 4 Feb 2021 19:44:28 -0800 Subject: [PATCH] [kernel] system_get_log should take a void* Since it's not just text that's being returned in the buffer, switch the argument from a char* to a void*. --- src/include/j6/tables/syscalls.inc | 2 +- src/kernel/syscalls/system.cpp | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/include/j6/tables/syscalls.inc b/src/include/j6/tables/syscalls.inc index 8fa78fb..fdd3351 100644 --- a/src/include/j6/tables/syscalls.inc +++ b/src/include/j6/tables/syscalls.inc @@ -1,6 +1,6 @@ SYSCALL(0x00, system_log, const char *) SYSCALL(0x01, system_noop, void) -SYSCALL(0x02, system_get_log, j6_handle_t, char *, size_t *) +SYSCALL(0x02, system_get_log, j6_handle_t, void *, size_t *) SYSCALL(0x03, system_bind_irq, j6_handle_t, j6_handle_t, unsigned) SYSCALL(0x04, system_map_mmio, j6_handle_t, j6_handle_t *, uintptr_t, size_t, uint32_t) diff --git a/src/kernel/syscalls/system.cpp b/src/kernel/syscalls/system.cpp index e47bfdf..97f443d 100644 --- a/src/kernel/syscalls/system.cpp +++ b/src/kernel/syscalls/system.cpp @@ -33,7 +33,7 @@ system_noop() } j6_status_t -system_get_log(j6_handle_t sys, char *buffer, size_t *size) +system_get_log(j6_handle_t sys, void *buffer, size_t *size) { if (!size || (*size && !buffer)) return j6_err_invalid_arg;