* [PATCH] ASoC: tracing: Export SND_SOC_DAPM_DIR_OUT to its value
@ 2024-04-16 4:03 Steven Rostedt
2024-04-17 0:12 ` Mark Brown
0 siblings, 1 reply; 2+ messages in thread
From: Steven Rostedt @ 2024-04-16 4:03 UTC (permalink / raw)
To: LKML, Linux trace kernel
Cc: Masami Hiramatsu, Mathieu Desnoyers, Luca Ceresoli, Mark Brown,
Lars-Peter Clausen
The string SND_SOC_DAPM_DIR_OUT is printed in the snd_soc_dapm_path trace
event instead of its value:
(((REC->path_dir) == SND_SOC_DAPM_DIR_OUT) ? "->" : "<-")
User space cannot parse this, as it has no idea what SND_SOC_DAPM_DIR_OUT
is. Use TRACE_DEFINE_ENUM() to convert it to its value:
(((REC->path_dir) == 1) ? "->" : "<-")
So that user space tools, such as perf and trace-cmd, can parse it
correctly.
Reported-by: Luca Ceresoli <luca.ceresoli@bootlin.com>
Fixes: 6e588a0d839b5 ("ASoC: dapm: Consolidate path trace events")
Signed-off-by: Steven Rostedt (Google) <rostedt@goodmis.org>
---
include/trace/events/asoc.h | 2 ++
1 file changed, 2 insertions(+)
diff --git a/include/trace/events/asoc.h b/include/trace/events/asoc.h
index 4eed9028bb11..517015ef36a8 100644
--- a/include/trace/events/asoc.h
+++ b/include/trace/events/asoc.h
@@ -12,6 +12,8 @@
#define DAPM_DIRECT "(direct)"
#define DAPM_ARROW(dir) (((dir) == SND_SOC_DAPM_DIR_OUT) ? "->" : "<-")
+TRACE_DEFINE_ENUM(SND_SOC_DAPM_DIR_OUT);
+
struct snd_soc_jack;
struct snd_soc_card;
struct snd_soc_dapm_widget;
--
2.43.0
^ permalink raw reply related [flat|nested] 2+ messages in thread* Re: [PATCH] ASoC: tracing: Export SND_SOC_DAPM_DIR_OUT to its value
2024-04-16 4:03 [PATCH] ASoC: tracing: Export SND_SOC_DAPM_DIR_OUT to its value Steven Rostedt
@ 2024-04-17 0:12 ` Mark Brown
0 siblings, 0 replies; 2+ messages in thread
From: Mark Brown @ 2024-04-17 0:12 UTC (permalink / raw)
To: LKML, Linux trace kernel, Steven Rostedt
Cc: Masami Hiramatsu, Mathieu Desnoyers, Luca Ceresoli,
Lars-Peter Clausen
On Tue, 16 Apr 2024 00:03:03 -0400, Steven Rostedt wrote:
> The string SND_SOC_DAPM_DIR_OUT is printed in the snd_soc_dapm_path trace
> event instead of its value:
>
> (((REC->path_dir) == SND_SOC_DAPM_DIR_OUT) ? "->" : "<-")
>
> User space cannot parse this, as it has no idea what SND_SOC_DAPM_DIR_OUT
> is. Use TRACE_DEFINE_ENUM() to convert it to its value:
>
> [...]
Applied to
https://git.kernel.org/pub/scm/linux/kernel/git/broonie/sound.git for-next
Thanks!
[1/1] ASoC: tracing: Export SND_SOC_DAPM_DIR_OUT to its value
commit: 58300f8d6a48e58d1843199be743f819e2791ea3
All being well this means that it will be integrated into the linux-next
tree (usually sometime in the next 24 hours) and sent to Linus during
the next merge window (or sooner if it is a bug fix), however if
problems are discovered then the patch may be dropped or reverted.
You may get further e-mails resulting from automated or manual testing
and review of the tree, please engage with people reporting problems and
send followup patches addressing any issues that are reported if needed.
If any updates are required or you are submitting further changes they
should be sent as incremental updates against current git, existing
patches will not be replaced.
Please add any relevant lists and maintainers to the CCs when replying
to this mail.
Thanks,
Mark
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2024-04-17 0:12 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-04-16 4:03 [PATCH] ASoC: tracing: Export SND_SOC_DAPM_DIR_OUT to its value Steven Rostedt
2024-04-17 0:12 ` Mark Brown
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox