diff options
| author | Sasha Levin <sashal@kernel.org> | 2026-05-29 09:15:29 -0400 |
|---|---|---|
| committer | Sasha Levin <sashal@kernel.org> | 2026-10-07 18:26:44 -0400 |
| commit | ef777ef05ebcc5ea5393b4bd5af6fc3ad1b3aec9 (patch) | |
| tree | 0ab7211d338ecb6195d0b5ac916af7345fb5356a /tools/perf/python | |
| parent | eddd14da6bede7b3f321fa6412ab7836b0a1ecfe (diff) | |
| download | linux-next-ef777ef05ebcc5ea5393b4bd5af6fc3ad1b3aec9.tar.gz linux-next-ef777ef05ebcc5ea5393b4bd5af6fc3ad1b3aec9.zip | |
kernel/api: add syscall enter/exit tracepoints
Add two tracepoints to the CONFIG_KAPI_RUNTIME_CHECKS syscall validation
path so the framework's behavior can be observed without the noise and
loss of pr_warn_ratelimited():
kapi_syscall_enter - the spec name, the raw argument values, and a
rendered "name=value" list of the specified
parameters (pointer-like values in hex, signed
integers and file descriptors in decimal)
kapi_syscall_exit - the spec name, the return value, and whether it
matched the specification (spec_match)
Both fire only for syscalls that have a KAPI specification and live
inside the existing CONFIG_KAPI_RUNTIME_CHECKS region, so they exist
exactly when the runtime checks do; they compile to no-ops without
CONFIG_TRACEPOINTS and stay dormant until enabled. The parameter list
is rendered only when the enter tracepoint is enabled.
kapi_syscall_exit is also emitted on the parameter-validation rejection
path -- where the validator returns -EINVAL and the real handler is
skipped -- with spec_match=0, so every kapi_syscall_enter has a matching
exit.
Assisted-by: LLM
Signed-off-by: Sasha Levin <sashal@kernel.org>
Diffstat (limited to 'tools/perf/python')
0 files changed, 0 insertions, 0 deletions
