aboutsummaryrefslogtreecommitdiff
path: root/src/userspace/libc/syscall.c
blob: d5c6708bac752cabd2c15d1485acffeb081fa530 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
#include <stdint.h>
#include <common.h>
#include <syscall.h>

/**
 * DEFINITIONS
 */
DEFN_SYSCALL0(halt, SYS_HALT);

DEFN_SYSCALL1(exit, SYS_EXIT, u32);

DEFN_SYSCALL0(fork, SYS_FORK);

DEFN_SYSCALL4(read, SYS_READ, char *, u32, u32, u8 *);

DEFN_SYSCALL4(write, SYS_WRITE, char *, u32, u32, u8 *);

DEFN_SYSCALL1(exec, SYS_EXEC, char *);

DEFN_SYSCALL0(get_pid, SYS_GET_PID);

DEFN_SYSCALL1(malloc, SYS_MALLOC, u32);

DEFN_SYSCALL1(free, SYS_FREE, u32);

DEFN_SYSCALL1(get, SYS_GET, u32);

DEFN_SYSCALL2(map, SYS_MAP, u32, u8 *);