1// SPDX-License-Identifier: GPL-3.0-or-later
2// Syscall name table (const char *[])
3// This file was generated by scripts/gen_syscall.py
4
5#pragma once
6
7#include <mos/filesystem/fs_types.h>
8#include <mos/io/io_types.h>
9#include <mos/mos_global.h>
10#include <mos/tasks/signal_types.h>
11#include <mos/types.h>
12#include <sys/poll.h>
13#include <sys/select.h>
14#include <sys/uio.h>
15
16// syscall name table
17#include <mos/syscall/decl.h>
18#include <mos/syscall/number.h>
19
20static const char *get_syscall_names(int nr) {
21 switch (nr) {
22 case SYSCALL_vfs_openat: return "vfs_openat";
23 case SYSCALL_vfs_fstatat: return "vfs_fstatat";
24 case SYSCALL_io_read: return "io_read";
25 case SYSCALL_io_write: return "io_write";
26 case SYSCALL_io_close: return "io_close";
27 case SYSCALL_exit: return "exit";
28 case SYSCALL_yield_cpu: return "yield_cpu";
29 case SYSCALL_fork: return "fork";
30 case SYSCALL_get_pid: return "get_pid";
31 case SYSCALL_get_parent_pid: return "get_parent_pid";
32 case SYSCALL_spawn: return "spawn";
33 case SYSCALL_create_thread: return "create_thread";
34 case SYSCALL_get_tid: return "get_tid";
35 case SYSCALL_thread_exit: return "thread_exit";
36 case SYSCALL_wait_for_thread: return "wait_for_thread";
37 case SYSCALL_futex_wait: return "futex_wait";
38 case SYSCALL_futex_wake: return "futex_wake";
39 case SYSCALL_ipc_create: return "ipc_create";
40 case SYSCALL_ipc_accept: return "ipc_accept";
41 case SYSCALL_ipc_connect: return "ipc_connect";
42 case SYSCALL_arch_syscall: return "arch_syscall";
43 case SYSCALL_vfs_mount: return "vfs_mount";
44 case SYSCALL_vfs_readlinkat: return "vfs_readlinkat";
45 case SYSCALL_vfs_unlinkat: return "vfs_unlinkat";
46 case SYSCALL_vfs_symlink: return "vfs_symlink";
47 case SYSCALL_vfs_mkdir: return "vfs_mkdir";
48 case SYSCALL_vfs_list_dir: return "vfs_list_dir";
49 case SYSCALL_fd_manipulate: return "fd_manipulate";
50 case SYSCALL_mmap_anonymous: return "mmap_anonymous";
51 case SYSCALL_mmap_file: return "mmap_file";
52 case SYSCALL_wait_for_process: return "wait_for_process";
53 case SYSCALL_munmap: return "munmap";
54 case SYSCALL_vfs_chdirat: return "vfs_chdirat";
55 case SYSCALL_vfs_getcwd: return "vfs_getcwd";
56 case SYSCALL_io_seek: return "io_seek";
57 case SYSCALL_io_tell: return "io_tell";
58 case SYSCALL_signal_register: return "signal_register";
59 case SYSCALL_signal_process: return "signal_process";
60 case SYSCALL_signal_thread: return "signal_thread";
61 case SYSCALL_poweroff: return "poweroff";
62 case SYSCALL_signal_return: return "signal_return";
63 case SYSCALL_vm_protect: return "vm_protect";
64 case SYSCALL_io_poll: return "io_poll";
65 case SYSCALL_io_pselect: return "io_pselect";
66 case SYSCALL_execveat: return "execveat";
67 case SYSCALL_clock_msleep: return "clock_msleep";
68 case SYSCALL_io_dup: return "io_dup";
69 case SYSCALL_io_dup2: return "io_dup2";
70 case SYSCALL_dmabuf_alloc: return "dmabuf_alloc";
71 case SYSCALL_dmabuf_free: return "dmabuf_free";
72 case SYSCALL_dmabuf_share: return "dmabuf_share";
73 case SYSCALL_dmabuf_unshare: return "dmabuf_unshare";
74 case SYSCALL_pipe: return "pipe";
75 case SYSCALL_io_readv: return "io_readv";
76 case SYSCALL_vfs_unmount: return "vfs_unmount";
77 case SYSCALL_clock_gettimeofday: return "clock_gettimeofday";
78 case SYSCALL_thread_setname: return "thread_setname";
79 case SYSCALL_thread_getname: return "thread_getname";
80 case SYSCALL_vfs_fchmodat: return "vfs_fchmodat";
81 case SYSCALL_io_pread: return "io_pread";
82 case SYSCALL_memfd_create: return "memfd_create";
83 case SYSCALL_signal_mask_op: return "signal_mask_op";
84 case SYSCALL_vfs_fsync: return "vfs_fsync";
85 }
86return "<unknown>";
87}
88