[PATCH 0/4] tools/nolibc: add two new syscall helpers

Zhangjin Wu falcon at tinylab.org
Sat Jun 3 22:33:09 PDT 2023


Hi, Willy

When I worked on adding new syscalls and the related library routines,
I have seen most of the library routines share the same syscall call and
return logic, this patchset adds two macros to simplify and shrink them.

All of them have been tested on arm, aarch64, rv32 and rv64, no new
regressions found.

If this is ok, I will rebase the new syscalls and library routines on
this patchset.

Best regards,
Zhangjin
---

Zhangjin Wu (4):
  tools/nolibc: unistd.h: add __syscall() and __syscall_ret() helpers
  tools/nolibc: unistd.h: apply __syscall_ret() helper
  tools/nolibc: sys.h: apply __syscall_ret() helper
  tools/nolibc: sys.h: apply __syscall() helper

 tools/include/nolibc/sys.h    | 369 ++++++----------------------------
 tools/include/nolibc/unistd.h |  12 +-
 2 files changed, 65 insertions(+), 316 deletions(-)

-- 
2.25.1




More information about the linux-riscv mailing list