libbpf: Improve syscall tracing support in bpf_tracing.h
authorAndrii Nakryiko <andrii@kernel.org>
Fri, 20 Jan 2023 20:09:01 +0000 (12:09 -0800)
committerDaniel Borkmann <daniel@iogearbox.net>
Mon, 23 Jan 2023 19:53:00 +0000 (20:53 +0100)
commit8ccabeef913311eb54599abc52a6bcfc3e7bf1d8
tree94760da5a6edc0a16085578dfc6fcb1907ed152b
parentbc72742bebec8e0766af1e07e13169a873f9119c
libbpf: Improve syscall tracing support in bpf_tracing.h

Set up generic support in bpf_tracing.h for up to 7 syscall arguments
tracing with BPF_KSYSCALL, which seems to be the limit according to
syscall(2) manpage. Also change the way that syscall convention is
specified to be more explicit. Subsequent patches will adjust and define
proper per-architecture syscall conventions.

__PT_PARM1_SYSCALL_REG through __PT_PARM6_SYSCALL_REG is added
temporarily to keep everything working before each architecture has
syscall reg tables defined. They will be removed afterwards.

Signed-off-by: Andrii Nakryiko <andrii@kernel.org>
Signed-off-by: Daniel Borkmann <daniel@iogearbox.net>
Tested-by: Alan Maguire <alan.maguire@oracle.com> # arm64
Link: https://lore.kernel.org/bpf/20230120200914.3008030-13-andrii@kernel.org
tools/lib/bpf/bpf_tracing.h