d0b9b0df |
1 | #include <stdlib.h> |
2 | |
3 | struct timespec; |
4 | |
5 | void sys_cacheflush(const void *start_addr, const void *end_addr); |
6 | |
7 | long g_syscall(long number, ...); |
8 | |
9 | // arg6 is func ptr, for convenience |
10 | long g_clone(unsigned long flags, void *child_stack, ...); |
11 | |
b4f4cb40 |
12 | long g_syscall_error(long kret); |
d0b9b0df |
13 | |
14 | // raw - no errno handling |
15 | long g_open_raw(const char *pathname, int flags, ...); |
16 | long g_read_raw(int fd, void *buf, size_t count); |
17 | long g_write_raw(int fd, const void *buf, size_t count); |
b4f4cb40 |
18 | long g_mmap2_raw(void *addr, size_t length, int prot, int flags, |
19 | int fd, off_t offset); |
20 | long g_munmap_raw(void *addr, size_t length); |
21 | long g_ioctl_raw(int fd, unsigned long request, ...); |
22 | long g_close_raw(int fd); |
23 | long g_chdir_raw(const char *path); |
d0b9b0df |
24 | long g_futex_raw(int *uaddr, int op, int val, |
25 | const struct timespec *timeout); |
26 | long g_nanosleep_raw(const struct timespec *req, struct timespec *rem); |
c3831532 |
27 | long g_readlink_raw(const char *pathname, char *buf, size_t bufsiz); |
78684356 |
28 | long g_execve_raw(const char *filename, char * const argv[], |
29 | char * const envp[]); |
d0b9b0df |
30 | long g_clock_gettime_raw(int clk_id, const struct timespec *tp); |
31 | long g_rt_sigprocmask_raw(int how, const void *set, void *oldset, |
b4f4cb40 |
32 | size_t sigsetsize); |
33 | long __attribute__((noreturn)) |
34 | g_exit_group_raw(int status); |
35 | |