SYSCALL(2) — NEWS-OS Programmer’s Manual
NAME
syscall − indirect system call
SYNOPSIS
#include <syscall.h>
syscall(number, arg, ...)
DESCRIPTION
syscall performs the system call whose assembly language interface has the specified number, register arguments a0 and a1 and further arguments arg. Symbolic constants for system calls can be found in the header file <syscall.h>.
The v0 value of the system call is returned.
DIAGNOSTICS
When the resigter v0 is set other than 0, syscall returns −1 and sets the external variable errno (see intro(2)).
BUGS
There is no way to simulate system calls such as pipe(2), which return values in register v1.
NEWS-OSRelease 4.2.1R