Skip to content

nolibc: add generic part1 of prepare for rv32

Zhangjin Wu linux-kselftest linux-riscv lkml 2 versions – In review

Get series with b4
b4 am [email protected]

Versions newest first · linked by author and title

  1. v3 Latest12 patches 11 repliesIn review
  2. v27 patches 2 repliesSuperseded

Changes in v3 from the cover letter

* selftests/nolibc: fix up compile warning with glibc on x86_64

Patches in v3 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/12selftests/nolibc: syscall_args: use generic __NR_statxtools/testing/selftests/nolibc/nolibc-test.c+1 -10 replies
2/12tools/nolibc: add missing nanoseconds support for __NR_statxtools/include/nolibc/sys.h+20 -173 replies
3/12selftests/nolibc: allow specify extra arguments for qemutools/testing/selftests/nolibc/Makefile+1 -10 replies
4/12selftests/nolibc: fix up compile warning with glibc on x86_64tools/testing/selftests/nolibc/nolibc-test.c+1 -10 replies
5/12selftests/nolibc: not include limits.h for nolibctools/include/nolibc/stdint.h tools/testing/selftests/nolibc/nolibc-test.c+15 -30 replies
6/12selftests/nolibc: use INT_MAX instead of __INT_MAX__tools/testing/selftests/nolibc/nolibc-test.c+2 -20 replies
7/12tools/nolibc: arm: add missing my_syscall6tools/include/nolibc/arch-arm.h+23 -00 replies
8/12tools/nolibc: open: fix up compile warning for armtools/include/nolibc/sys.h+1 -10 replies
9/12selftests/nolibc: support two errnos with EXPECT_SYSER2()tools/testing/selftests/nolibc/nolibc-test.c+10 -40 replies
10/12selftests/nolibc: remove gettimeofday_bad1/2 completelytools/testing/selftests/nolibc/nolibc-test.c+0 -40 replies
11/12selftests/nolibc: add new gettimeofday test casestools/testing/selftests/nolibc/nolibc-test.c+4 -06 replies
12/12selftests/nolibc: test_fork: fix up duplicated printtools/testing/selftests/nolibc/nolibc-test.c+7 -10 replies

Reviews trailers per patch

1 of 12 patches has a Reviewed-by or Acked-by of their own; the series has one for all of them.

PatchThomas Weißschuh
SeriesR-b
1/12
2/12
3/12
4/12
5/12
6/12
7/12
8/12
9/12
10/12
11/12
12/12R-b

Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes.

Read the v3 thread

Cover letter [PATCH v3 00/12] nolibc: add generic part1 of prepare for rv32

Hi, Willy

This is the v3 generic part1 for rv32, all of the found issues of v2 part1 [1] have been fixed up, several generic patches have been fixed up and merged from v2 part2 [2] to this series, the standalone test_fork patch [4] is merged with a Reviewed-by line into this series too.

This series is based on 20230528-nolibc-rv32+stkp5 branch of [5].

Changes from v2 -> v3:

* selftests/nolibc: fix up compile warning with glibc on x86_64

Use simpler 'long long' conversion instead of old #ifdef ... (Suggestion from Willy)

* tools/nolibc: add missing nanoseconds support for __NR_statx

Split the compound assignment into two single assignments (Suggestion from Thomas)

* selftests/nolibc: add new gettimeofday test cases

Removed the gettimeofday(NULL, &tz)
(Suggestion from Thomas)

All of the commit messages have been re-checked, some missing Suggested-by lines are added.

The whole patchset have been tested on arm, aarch64, rv32 and rv64, no regressions (the next compile patchset is required to do rv32 test).

The nolibc-test has been tested with glibc on x86_64 too.

Btw, we have found such poll failures on arm (not introduced by this patchset), this will be fixed in our coming ppoll_time64 patchset:

48 poll_null = -1 ENOSYS                                        [FAIL]
49 poll_stdout = -1 ENOSYS                                      [FAIL]
50 poll_fault = -1 ENOSYS  != (-1 EFAULT)                       [FAIL]

And the gettimeofday_null removal patch from Thomas [3] may conflicts with the gettimeofday removal and addition patches, but it is not hard to fix.

Best regards,
Zhangjin
---

[1]: https://lore.kernel.org/linux-riscv/[email protected]/T/#t
[2]: https://lore.kernel.org/linux-riscv/[email protected]/T/#t
[3]: https://lore.kernel.org/lkml/[email protected]/
[4]: https://lore.kernel.org/lkml/61bdfe7bacebdef8aa9195f6f2550a5b0d33aab3.1685426545.git.falcon@tinylab.org/
[5]: https://git.kernel.org/pub/scm/linux/kernel/git/wtarreau/nolibc.git

Zhangjin Wu (12):
selftests/nolibc: syscall_args: use generic __NR_statx tools/nolibc: add missing nanoseconds support for __NR_statx selftests/nolibc: allow specify extra arguments for qemu selftests/nolibc: fix up compile warning with glibc on x86_64 selftests/nolibc: not include limits.h for nolibc selftests/nolibc: use INT_MAX instead of __INT_MAX__ tools/nolibc: arm: add missing my_syscall6 tools/nolibc: open: fix up compile warning for arm selftests/nolibc: support two errnos with EXPECT_SYSER2() selftests/nolibc: remove gettimeofday_bad1/2 completely selftests/nolibc: add new gettimeofday test cases selftests/nolibc: test_fork: fix up duplicated print

 tools/include/nolibc/arch-arm.h              | 23 +++++++++++
 tools/include/nolibc/stdint.h                | 14 +++++++
 tools/include/nolibc/sys.h                   | 39 +++++++++---------
 tools/testing/selftests/nolibc/Makefile      |  2 +-
 tools/testing/selftests/nolibc/nolibc-test.c | 42 ++++++++++++--------
 5 files changed, 85 insertions(+), 35 deletions(-)
Signature · 1 line
2.25.1