[LTP] [PATCH 0/4] Automatically generate syscalls.h

Andrea Cervesato andrea.cervesato@suse.com
Tue Sep 24 10:46:20 CEST 2024


Hi!

Please consider this patchset as a draft open for discussion.

Andrea

On 9/24/24 10:06, Andrea Cervesato wrote:
> The problem we have at the moment is that all syscalls input files must
> be changed by hand each time we need to test a new syscall. The idea is
> to simplify this process, providing a script that is able to read from
> kernel sources and to generate all syscalls files we need.
>
> This is done by the generate_syscalls.sh script that can be used as
> following:
>
> ./generate_syscalls.sh path/to/kernel/source path/to/syscalls.h
>
> This approach requires a certain type of attention, due to the fact that
> we need to generate syscalls.h at each kernel version, or when new
> syscalls have been added in the kernel.
>
> Signed-off-by: Andrea Cervesato <andrea.cervesato@suse.com>
> ---
> Andrea Cervesato (4):
>        Rename syscalls order file to supported-arch.txt
>        Add script to generate syscalls.h
>        Deprecate old syscalls input files
>        Save syscalls.h inside repo
>
>   include/lapi/.gitignore                            |     1 -
>   include/lapi/syscalls.h                            | 34272 +++++++++++++++++++
>   include/lapi/syscalls/aarch64.in                   |   306 -
>   include/lapi/syscalls/arc.in                       |   325 -
>   include/lapi/syscalls/arm.in                       |   404 -
>   include/lapi/syscalls/blacklist-syscalls.txt       |     6 +
>   include/lapi/syscalls/generate_syscalls.sh         |   292 +
>   include/lapi/syscalls/hppa.in                      |    52 -
>   include/lapi/syscalls/i386.in                      |   439 -
>   include/lapi/syscalls/ia64.in                      |   956 +-
>   include/lapi/syscalls/loongarch.in                 |   310 -
>   include/lapi/syscalls/mips_n32.in                  |   379 -
>   include/lapi/syscalls/mips_n64.in                  |   355 -
>   include/lapi/syscalls/mips_o32.in                  |   425 -
>   include/lapi/syscalls/powerpc.in                   |   432 -
>   include/lapi/syscalls/powerpc64.in                 |   432 -
>   include/lapi/syscalls/regen.sh                     |   129 -
>   include/lapi/syscalls/s390.in                      |   419 -
>   include/lapi/syscalls/s390x.in                     |   367 -
>   include/lapi/syscalls/sh.in                        |   413 -
>   include/lapi/syscalls/sparc.in                     |   418 -
>   include/lapi/syscalls/sparc64.in                   |   383 -
>   include/lapi/syscalls/strip_syscall.awk            |    19 -
>   .../lapi/syscalls/{order => supported-arch.txt}    |     1 -
>   include/lapi/syscalls/x86_64.in                    |   396 -
>   25 files changed, 35174 insertions(+), 6757 deletions(-)
> ---
> base-commit: 968e6245d93bc91723e72086a71e6bc50f495d0b
> change-id: 20240923-generate_syscalls-780dc2227bdb
>
> Best regards,


More information about the ltp mailing list