]> git.ipfire.org Git - thirdparty/kernel/linux.git/commit
tools/rtla: Consolidate code between osnoise/timerlat and hist/top
authorCrystal Wood <crwood@redhat.com>
Sun, 7 Sep 2025 02:23:22 +0000 (21:23 -0500)
committerSteven Rostedt (Google) <rostedt@goodmis.org>
Sat, 27 Sep 2025 08:52:57 +0000 (04:52 -0400)
commit2f3172f9dd58cca0f188bc0766b619d24f8116ad
treecc93dc99458a7b4d9f7969cfd91c9593ca5aaec7
parent263d7eacf8d17d66078700ff6b4b540d66f56278
tools/rtla: Consolidate code between osnoise/timerlat and hist/top

Currently a lot of code is duplicated between the different rtla tools,
making maintenance more difficult, and encouraging divergence such as
features that are only implemented for certain tools even though they
could be more broadly applicable.

Merge the various main() functions into a common run_tool() with an ops
struct for tool-specific details.

Implement enough support for actions on osnoise to not need to keep the
old params->trace_output path.

Cc: John Kacur <jkacur@redhat.com>
Cc: Costa Shulyupin <costa.shul@redhat.com>
Link: https://lore.kernel.org/20250907022325.243930-5-crwood@redhat.com
Reviewed-by: Tomas Glozar <tglozar@redhat.com>
Signed-off-by: Crystal Wood <crwood@redhat.com>
Signed-off-by: Steven Rostedt (Google) <rostedt@goodmis.org>
12 files changed:
tools/tracing/rtla/src/common.c
tools/tracing/rtla/src/common.h
tools/tracing/rtla/src/osnoise.c
tools/tracing/rtla/src/osnoise.h
tools/tracing/rtla/src/osnoise_hist.c
tools/tracing/rtla/src/osnoise_top.c
tools/tracing/rtla/src/timerlat.c
tools/tracing/rtla/src/timerlat.h
tools/tracing/rtla/src/timerlat_bpf.c
tools/tracing/rtla/src/timerlat_hist.c
tools/tracing/rtla/src/timerlat_top.c
tools/tracing/rtla/src/trace.h