libraries/libnx/inc/public/nox/syscall.h

36 lines
1.7 KiB
C
Raw Normal View History

// This file is part of noxos and licensed under the MIT open source license
#ifndef LIBC_SYSCALL_H
#define LIBC_SYSCALL_H
#include "public/nox/stdtypes.h"
#include "public/nox/string.h"
uint64_t nx_fs_open (string_t path, uint64_t len, uint64_t* fd);
uint64_t nx_fs_close (uint64_t fd);
uint64_t nx_fs_read (uint64_t fd, uint64_t offset, void* mem, uint64_t n);
uint64_t nx_fs_write (uint64_t fd, uint64_t offset, void* mem, uint64_t n);
uint64_t nx_fs_delete (string_t path, uint64_t len);
uint64_t nx_fs_list (string_t path, uint64_t len, void* mem, uint64_t* needed_mem);
uint64_t nx_fs_info (uint64_t fd, uint64_t attr, void* mem);
uint64_t nx_mem_alloc (void* addr, uint64_t n, uint64_t flags);
uint64_t nx_mem_free (void* addr, uint64_t n);
uint64_t nx_mem_label (void* addr, uint64_t len, uint64_t* fd);
uint64_t nx_mem_unlabel (uint64_t* fd);
uint64_t nx_proc_create (void* conf, uint64_t* pid);
uint64_t nx_proc_signal_send (uint64_t pid, uint64_t signal);
uint64_t nx_proc_signal_set_handler (uint64_t signal, void* handler);
uint64_t nx_proc_thread_create (void* addr, uint64_t* tid);
uint64_t nx_proc_thread_start (uint64_t tid);
uint64_t nx_proc_thread_pause (uint64_t tid);
uint64_t nx_proc_thread_kill (uint64_t tid);
uint64_t nx_drv_register (uint64_t fd);
uint64_t nx_drv_init (void* conf);
uint64_t nx_drv_create_command_buffer (void* addr, uint64_t len);
uint64_t nx_drv_flush_command_buffer (void* addr);
#endif //LIBC_SYSCALL_H