Removed syscallret_t typedef.

Syscalls just return an int
This commit is contained in:
2023-11-09 21:24:07 -06:00
parent b4ea4b8ca1
commit 58ae7f9f89
3 changed files with 44 additions and 51 deletions

View File

@@ -5,19 +5,18 @@
#include "types/sigaction.h"
#include "types/pid.h"
#include "types/oid.h"
#include "types/syscallret.h"
#include <stdbool.h>
#include <stddef.h>
extern void *syscall_table[];
typedef syscallret_t (*syscall_ptr_0_t)();
typedef int (*syscall_ptr_0_t)();
typedef syscallret_t (*syscall_ptr_1_t)(syscall_arg_t);
typedef int (*syscall_ptr_1_t)(syscall_arg_t);
typedef syscallret_t (*syscall_ptr_2_t)(syscall_arg_t, syscall_arg_t);
typedef int (*syscall_ptr_2_t)(syscall_arg_t, syscall_arg_t);
typedef syscallret_t (*syscall_ptr_3_t)(syscall_arg_t, syscall_arg_t, syscall_arg_t);
typedef int (*syscall_ptr_3_t)(syscall_arg_t, syscall_arg_t, syscall_arg_t);
struct syscall_t
{
@@ -38,101 +37,101 @@ struct syscall_t
*
* @param str The string to output.
*/
syscallret_t test_syscall(syscall_arg_t str);
int test_syscall(syscall_arg_t str);
/**
*
*/
syscallret_t syscall_map_anon(syscall_arg_t location, syscall_arg_t length, syscall_arg_t flags);
int syscall_map_anon(syscall_arg_t location, syscall_arg_t length, syscall_arg_t flags);
/**
*
*/
syscallret_t syscall_unmap_anon(syscall_arg_t location, syscall_arg_t length);
int syscall_unmap_anon(syscall_arg_t location, syscall_arg_t length);
/**
*
*/
syscallret_t syscall_map_physical(syscall_arg_t arg_addr, syscall_arg_t arg_phys_addr, syscall_arg_t arg_length);
int syscall_map_physical(syscall_arg_t arg_addr, syscall_arg_t arg_phys_addr, syscall_arg_t arg_length);
/**
*
*/
syscallret_t syscall_unmap_physical(syscall_arg_t arg_addr, syscall_arg_t arg_length);
int syscall_unmap_physical(syscall_arg_t arg_addr, syscall_arg_t arg_length);
/**
*
*/
syscallret_t syscall_open_port(syscall_arg_t id);
int syscall_open_port(syscall_arg_t id);
/**
*
*/
syscallret_t syscall_close_port(syscall_arg_t id);
int syscall_close_port(syscall_arg_t id);
/**
*
*/
syscallret_t syscall_send_pid(syscall_arg_t recipient, syscall_arg_t message, syscall_arg_t flags);
int syscall_send_pid(syscall_arg_t recipient, syscall_arg_t message, syscall_arg_t flags);
/**
*
*/
syscallret_t syscall_send_port(syscall_arg_t recipient, syscall_arg_t message, syscall_arg_t flags);
int syscall_send_port(syscall_arg_t recipient, syscall_arg_t message, syscall_arg_t flags);
/**
*
*/
syscallret_t syscall_receive(syscall_arg_t buffer, syscall_arg_t flags);
int syscall_receive(syscall_arg_t buffer, syscall_arg_t flags);
/**
*
*/
syscallret_t syscall_create_object(void *location, size_t size, int flags);
int syscall_create_object(void *location, size_t size, int flags);
/**
*
*/
syscallret_t syscall_aquire_object(oid_t id, void *location);
int syscall_aquire_object(oid_t id, void *location);
/**
*
*/
syscallret_t syscall_release_object(oid_t id);
int syscall_release_object(oid_t id);
/**
*
*/
syscallret_t syscall_get_pid();
int syscall_get_pid();
/**
*
*/
syscallret_t syscall_clone(void (*entry)(void*), void *arg, void *stack, int flags);
int syscall_clone(void (*entry)(void*), void *arg, void *stack, int flags);
/**
*
*/
syscallret_t syscall_signal_action(int id, struct signal_action_t *action, int flags);
int syscall_signal_action(int id, struct signal_action_t *action, int flags);
/**
*
*/
syscallret_t syscall_signal_return();
int syscall_signal_return();
/**
*
*/
syscallret_t syscall_signal_raise(pid_t pid, int sigid);
int syscall_signal_raise(pid_t pid, int sigid);
/**
*
*/
syscallret_t syscall_intr_action(int id, struct signal_action_t *action, int flags);
int syscall_intr_action(int id, struct signal_action_t *action, int flags);
/**
*
*/
syscallret_t syscall_intr_return();
int syscall_intr_return();
#endif

View File

@@ -1,6 +0,0 @@
#ifndef QUARK_SYSCALLRET_H
#define QUARK_SYSCALLRET_H
typedef long syscallret_t;
#endif