This commit is contained in:
2026-08-11 17:48:20 +02:00
committed by Marvin Friedrich
parent cf33867e68
commit 0e2d4ed8c6
55 changed files with 279 additions and 346 deletions
+3 -3
View File
@@ -33,12 +33,12 @@ static const syscall_fn_t dispatch_table[] = {
};
void syscall_dispatch(struct arch_context* ctx) {
const size_t num = ctx->ARCH_CTX_NUM;
const size_t num = ctx->num;
if (num >= ARRAY_SIZE(dispatch_table)) {
ctx->ARCH_CTX_RET0 = ZN_ERR_BAD_SYSCALL;
ctx->ret0 = ZN_ERR_BAD_SYSCALL;
return;
}
ctx->ARCH_CTX_RET0 = dispatch_table[num](ctx);
ctx->ret0 = dispatch_table[num](ctx);
}