Re: [RFC PATCH v2 1/4] rtla/osnoise: Add IPI tracking cmdline option
From: Tomas Glozar <tglozar@redhat.com>
Date: 2026-06-29 10:51:34
Also in:
lkml
st 17. 6. 2026 v 15:18 odesílatel Valentin Schneider [off-list ref] napsal:
Later commits will add IPI tracking to osnoise top. To avoid breaking existing scripts, this new feature will be gated behind a new -i option. Suggested-by: Tomas Glozar <tglozar@redhat.com>
Thanks. Implementing this as a separate option also means we don't have to worry about the performance impact in the general use case, as the feature is not enabled by default. If we decide to enable IPI tracking by default in the future, we can just change the option to "--no-ipi" without breaking anything, as libsubcmd generates all options in a pair by default (i.e. it automatically recognizes --no-ipi when you define --ipi and vice versa, unless explicitly disabled).
quoted hunk ↗ jump to hunk
Signed-off-by: Valentin Schneider <vschneid@redhat.com> --- Documentation/tools/rtla/rtla-osnoise-top.rst | 4 ++++ tools/tracing/rtla/src/cli.c | 1 + tools/tracing/rtla/src/cli_p.h | 3 +++ tools/tracing/rtla/src/common.h | 1 + 4 files changed, 9 insertions(+) [truncated]--- a/tools/tracing/rtla/src/cli_p.h +++ b/tools/tracing/rtla/src/cli_p.h@@ -305,6 +305,9 @@ static int opt_filter_cb(const struct option *opt, const char *arg, int unset) "the minimum delta to be considered a noise", \ opt_llong_callback) +#define OSNOISE_OPT_IPI OPT_BOOLEAN('i', "ipi", ¶ms->common.ipi, \ + "track sources of IPIs") +
As IPI tracking is not a commonly used functionality, unlike e.g. "-p/--period", and -i is already a different option for timerlat tools (-i-/--irq), I'd suggest keeping just the long option, --ipi, like I did for --on-threshold/--on-end (on Arnaldo's suggestion based on his experience from perf [1]). This will make it clear to user the option means "IPI detection" and not something else beginning with the letter "i". We can always add a short option later if its use becomes common. [1] https://lore.kernel.org/linux-trace-kernel/aEmWyPqQw2Ly7Jlu@x1/ (local)
[truncated]
Tomas