summaryrefslogtreecommitdiff
path: root/sound
diff options
context:
space:
mode:
authorLinus Torvalds <torvalds@linux-foundation.org>2024-05-23 22:28:01 +0300
committerLinus Torvalds <torvalds@linux-foundation.org>2024-05-23 22:28:01 +0300
commitd6a326d694e77fd1d90ae40ad3c73a6af0eb1b8d (patch)
tree65620f42b46c745e16298f31b45d54b33ec0ebea /sound
parentbca2a25d3be779fbdf912de8e1ded6dcd483845d (diff)
parent2c92ca849fcc6ee7d0c358e9959abc9f58661aea (diff)
downloadlinux-d6a326d694e77fd1d90ae40ad3c73a6af0eb1b8d.tar.xz
Merge tag 'trace-assign-str-v6.10' of git://git.kernel.org/pub/scm/linux/kernel/git/trace/linux-trace
Pull tracing cleanup from Steven Rostedt: "Remove second argument of __assign_str() The __assign_str() macro logic of the TRACE_EVENT() macro was optimized so that it no longer needs the second argument. The __assign_str() is always matched with __string() field that takes a field name and the source for that field: __string(field, source) The TRACE_EVENT() macro logic will save off the source value and then use that value to copy into the ring buffer via the __assign_str(). Before commit c1fa617caeb0 ("tracing: Rework __assign_str() and __string() to not duplicate getting the string"), the __assign_str() needed the second argument which would perform the same logic as the __string() source parameter did. Not only would this add overhead, but it was error prone as if the __assign_str() source produced something different, it may not have allocated enough for the string in the ring buffer (as the __string() source was used to determine how much to allocate) Now that the __assign_str() just uses the same string that was used in __string() it no longer needs the source parameter. It can now be removed" * tag 'trace-assign-str-v6.10' of git://git.kernel.org/pub/scm/linux/kernel/git/trace/linux-trace: tracing/treewide: Remove second parameter of __assign_str()
Diffstat (limited to 'sound')
-rw-r--r--sound/core/pcm_trace.h2
-rw-r--r--sound/hda/trace.h6
-rw-r--r--sound/soc/intel/avs/trace.h4
3 files changed, 6 insertions, 6 deletions
diff --git a/sound/core/pcm_trace.h b/sound/core/pcm_trace.h
index 350b40b906ca..adb9b1f3bbfa 100644
--- a/sound/core/pcm_trace.h
+++ b/sound/core/pcm_trace.h
@@ -95,7 +95,7 @@ TRACE_EVENT(hw_ptr_error,
__entry->device = (substream)->pcm->device;
__entry->number = (substream)->number;
__entry->stream = (substream)->stream;
- __assign_str(reason, why);
+ __assign_str(reason);
),
TP_printk("pcmC%dD%d%s/sub%d: ERROR: %s",
__entry->card, __entry->device,
diff --git a/sound/hda/trace.h b/sound/hda/trace.h
index 2cc493434a8f..280c42f3eb75 100644
--- a/sound/hda/trace.h
+++ b/sound/hda/trace.h
@@ -24,7 +24,7 @@ TRACE_EVENT(hda_send_cmd,
__field(u32, cmd)
),
TP_fast_assign(
- __assign_str(name, dev_name((bus)->dev));
+ __assign_str(name);
__entry->cmd = cmd;
),
TP_printk("[%s:%d] val=0x%08x", __get_str(name), __entry->cmd >> 28, __entry->cmd)
@@ -39,7 +39,7 @@ TRACE_EVENT(hda_get_response,
__field(u32, res)
),
TP_fast_assign(
- __assign_str(name, dev_name((bus)->dev));
+ __assign_str(name);
__entry->addr = addr;
__entry->res = res;
),
@@ -55,7 +55,7 @@ TRACE_EVENT(hda_unsol_event,
__field(u32, res_ex)
),
TP_fast_assign(
- __assign_str(name, dev_name((bus)->dev));
+ __assign_str(name);
__entry->res = res;
__entry->res_ex = res_ex;
),
diff --git a/sound/soc/intel/avs/trace.h b/sound/soc/intel/avs/trace.h
index 855b06bb14b0..c9eaa5a60ed3 100644
--- a/sound/soc/intel/avs/trace.h
+++ b/sound/soc/intel/avs/trace.h
@@ -24,7 +24,7 @@ TRACE_EVENT(avs_dsp_core_op,
TP_fast_assign(
__entry->reg = reg;
__entry->mask = mask;
- __assign_str(op, op);
+ __assign_str(op);
__entry->flag = flag;
),
@@ -135,7 +135,7 @@ TRACE_EVENT(avs_d0ix,
),
TP_fast_assign(
- __assign_str(op, op);
+ __assign_str(op);
__entry->proceed = proceed;
__entry->header = header;
),