Go to the source code of this file.
|
#define | __sfsyscall_return(type, res) |
|
#define | _sfsyscall0(type, name) |
|
#define | _sfsyscall1(type, name, type1, arg1) |
|
#define | _sfsyscall2(type, name, type1, arg1, type2, arg2) |
|
#define | _sfsyscall3(type, name, type1, arg1, type2, arg2, type3, arg3) |
|
#define | _sfsyscall4(type, name, type1, arg1, type2, arg2, type3, arg3, type4, arg4) |
|
#define | _sfsyscall5(type, name, type1, arg1, type2, arg2, type3, arg3, type4, arg4, type5, arg5) |
|
#define | _sfsyscall6(type, name, type1, arg1, type2, arg2, type3, arg3, type4, arg4, type5, arg5, type6, arg6) |
|
◆ __sfsyscall_return
#define __sfsyscall_return |
( |
|
type, |
|
|
|
res |
|
) |
| |
◆ _sfsyscall0
Value:
long __res; \
__asm__
volatile(
"###> " #
name " <###\n\t" \
"svc 0" \
: "=a"(__res) \
: "memory", "cc"); \
__sfsyscall_return(
type, __res); \
}
Definition at line 32 of file sfsyscall.h.
◆ _sfsyscall1
#define _sfsyscall1 |
( |
|
type, |
|
|
|
name, |
|
|
|
type1, |
|
|
|
arg1 |
|
) |
| |
Value:
long __res; \
register type1
x1 asm(
"x0"); \
x1 = arg1; \
asm
volatile(
"###> " #
name "(%2) <###\n\t" \
"mov x8, %0\n\t" \
"svc 0" \
: "=g"(__res) \
:
"0"(__NR_##
name),
"r"(
x1)); \
__sfsyscall_return(
type, __res); \
}
Definition at line 43 of file sfsyscall.h.
◆ _sfsyscall2
#define _sfsyscall2 |
( |
|
type, |
|
|
|
name, |
|
|
|
type1, |
|
|
|
arg1, |
|
|
|
type2, |
|
|
|
arg2 |
|
) |
| |
Value:
long __res; \
register type1
x1 asm(
"x1"); \
register type2
x2 asm(
"x2"); \
x1 = arg1; \
x2 = arg2; \
__asm__
volatile(
"###> " #
name "(%2, %3) <###\n\t" \
"svc 0" \
: "=g"(__res) \
__sfsyscall_return(
type, __res); \
}
Definition at line 56 of file sfsyscall.h.
◆ _sfsyscall3
#define _sfsyscall3 |
( |
|
type, |
|
|
|
name, |
|
|
|
type1, |
|
|
|
arg1, |
|
|
|
type2, |
|
|
|
arg2, |
|
|
|
type3, |
|
|
|
arg3 |
|
) |
| |
Value: type name(type1 arg1, type2 arg2, type3 arg3) { \
long __res; \
register type1
x0 asm(
"x0"); \
register type2
x1 asm(
"x1"); \
register type3
x2 asm(
"x2"); \
x0 = arg1; \
x1 = arg2; \
x2 = arg3; \
__asm__ __volatile__(
"###> " #
name "(%2, %3, %4) <###\n\t" \
"mov x8, %1\n\t" \
"svc 0" \
: "=g"(__res) \
: "memory", "cc"); \
__sfsyscall_return(
type, __res); \
}
Definition at line 72 of file sfsyscall.h.
◆ _sfsyscall4
#define _sfsyscall4 |
( |
|
type, |
|
|
|
name, |
|
|
|
type1, |
|
|
|
arg1, |
|
|
|
type2, |
|
|
|
arg2, |
|
|
|
type3, |
|
|
|
arg3, |
|
|
|
type4, |
|
|
|
arg4 |
|
) |
| |
Value: type name(type1 arg1, type2 arg2, type3 arg3, type4 arg4) { \
long __res; \
register type1
x1 asm(
"x1"); \
; \
register type2
x2 asm(
"x2"); \
register type3
x3 asm(
"x3"); \
register type4
x4 asm(
"x4"); \
x1 = arg1; \
x2 = arg2; \
x3 = arg3; \
x4 = arg4; \
asm
volatile(
"###> " #
name "(%2, %3, %4, %5) <###\n\t" \
"svc 0" \
: "=g"(__res) \
: "memory", "cc"); \
__sfsyscall_return(
type, __res); \
}
Definition at line 93 of file sfsyscall.h.
◆ _sfsyscall5
#define _sfsyscall5 |
( |
|
type, |
|
|
|
name, |
|
|
|
type1, |
|
|
|
arg1, |
|
|
|
type2, |
|
|
|
arg2, |
|
|
|
type3, |
|
|
|
arg3, |
|
|
|
type4, |
|
|
|
arg4, |
|
|
|
type5, |
|
|
|
arg5 |
|
) |
| |
Value: type name(type1 arg1, type2 arg2, type3 arg3, type4 arg4, \
type5 arg5) { \
long __res; \
register type1
x1 asm(
"x1"); \
register type2
x2 asm(
"x2"); \
register type3
x3 asm(
"x3"); \
register type4
x4 asm(
"x4"); \
register type5
x5 asm(
"x5"); \
x1 = arg1; \
x2 = arg2; \
x3 = arg3; \
x4 = arg4; \
x5 = arg5; \
asm
volatile(
"###> " #
name "(%2, %3, %4, %5, %6) <###\n\t" \
"svc 0" \
: "=g"(__res) \
: "memory", "cc"); \
__sfsyscall_return(
type, __res); \
}
Definition at line 117 of file sfsyscall.h.
◆ _sfsyscall6
#define _sfsyscall6 |
( |
|
type, |
|
|
|
name, |
|
|
|
type1, |
|
|
|
arg1, |
|
|
|
type2, |
|
|
|
arg2, |
|
|
|
type3, |
|
|
|
arg3, |
|
|
|
type4, |
|
|
|
arg4, |
|
|
|
type5, |
|
|
|
arg5, |
|
|
|
type6, |
|
|
|
arg6 |
|
) |
| |
Value: type name(type1 arg1, type2 arg2, type3 arg3, type4 arg4, \
type5 arg5, type6 arg6) { \
long __res; \
register type1
x1 asm(
"x1"); \
register type2
x2 asm(
"x2"); \
register type3
x3 asm(
"x3"); \
register type4
x4 asm(
"x4"); \
register type5
x5 asm(
"x5"); \
register type6
x6 asm(
"x6"); \
x1 = arg1; \
x2 = arg2; \
x3 = arg3; \
x4 = arg4; \
x5 = arg5; \
x6 = arg6; \
asm
volatile(
"###> " #
name "(%2, %3, %4, %5, %6, %7) <###\n\t" \
"svc 0" \
: "=a"(__res) \
: "memory", "cc"); \
__sfsyscall_return(
type, __res); \
}
Definition at line 144 of file sfsyscall.h.