1 /* $NetBSD: SYS.h,v 1.13 2014/08/23 02:24:22 matt Exp $ */
3 #include <machine/asm.h>
4 #include <sys/syscall.h>
6 #define BRANCH_TO_CERROR() b _C_LABEL(__cerror)
8 #define _DOSYSCALL(x) li %r0,(SYS_ ## x) ;\
11 #define _SYSCALL_NOERROR(x,y) .text ;\
16 #define _SYSCALL(x,y) .text ;\
18 2: BRANCH_TO_CERROR() ;\
19 _SYSCALL_NOERROR(x,y) ;\
22 #define SYSCALL_NOERROR(x) _SYSCALL_NOERROR(x,x)
24 #define SYSCALL(x) _SYSCALL(x,x)
26 #define PSEUDO_NOERROR(x,y) _SYSCALL_NOERROR(x,y) ;\
30 #define PSEUDO(x,y) _SYSCALL_NOERROR(x,y) ;\
35 #define RSYSCALL_NOERROR(x) PSEUDO_NOERROR(x,x)
37 #define RSYSCALL(x) PSEUDO(x,x)
39 #define WSYSCALL(weak,strong) WEAK_ALIAS(weak,strong) ;\