diff options
author | Zhangjin Wu <falcon@tinylab.org> | 2023-06-28 21:14:53 +0800 |
---|---|---|
committer | Willy Tarreau <w@1wt.eu> | 2023-07-05 10:57:19 +0200 |
commit | 5367755868c834a1329dd6280015fe1f84685f3f (patch) | |
tree | 2a92053ddf9d24468452534c451b9454aa452f37 | |
parent | abd87023b42f7b92686c25fb0541c394000b28f8 (diff) | |
download | nolibc-20230705-nolibc-series2.tar.gz |
tools/nolibc: unistd.h: reorder the syscall macros20230705-nolibc-series2
Tune the macros in the using order and align most of them.
Signed-off-by: Zhangjin Wu <falcon@tinylab.org>
Signed-off-by: Willy Tarreau <w@1wt.eu>
-rw-r--r-- | tools/include/nolibc/unistd.h | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/tools/include/nolibc/unistd.h b/tools/include/nolibc/unistd.h index fabc846f797b82..e38f3660c0517d 100644 --- a/tools/include/nolibc/unistd.h +++ b/tools/include/nolibc/unistd.h @@ -56,9 +56,9 @@ int tcsetpgrp(int fd, pid_t pid) return ioctl(fd, TIOCSPGRP, &pid); } -#define _syscall(N, ...) __sysret(my_syscall##N(__VA_ARGS__)) -#define _syscall_narg(...) __syscall_narg(__VA_ARGS__, 6, 5, 4, 3, 2, 1, 0) #define __syscall_narg(_0, _1, _2, _3, _4, _5, _6, N, ...) N +#define _syscall_narg(...) __syscall_narg(__VA_ARGS__, 6, 5, 4, 3, 2, 1, 0) +#define _syscall(N, ...) __sysret(my_syscall##N(__VA_ARGS__)) #define _syscall_n(N, ...) _syscall(N, __VA_ARGS__) #define syscall(...) _syscall_n(_syscall_narg(__VA_ARGS__), ##__VA_ARGS__) |