summaryrefslogtreecommitdiffstats
path: root/sound/soc/sof/ipc4.c
diff options
context:
space:
mode:
authorPeter Ujfalusi <peter.ujfalusi@linux.intel.com>2022-10-18 15:40:05 +0300
committerMark Brown <broonie@kernel.org>2022-10-18 19:16:42 +0100
commit2d91d5715f5f3b24456ede20dbbe967a1d2a0a3e (patch)
tree67c1514c7630a449a00fe6fa6e866b8c46bb761e /sound/soc/sof/ipc4.c
parenta474dce8aa95752eed03436515e80425f630a9da (diff)
downloadlinux-stable-2d91d5715f5f3b24456ede20dbbe967a1d2a0a3e.tar.gz
linux-stable-2d91d5715f5f3b24456ede20dbbe967a1d2a0a3e.tar.bz2
linux-stable-2d91d5715f5f3b24456ede20dbbe967a1d2a0a3e.zip
ASoC: SOF: ipc4: Log the tx message before sending it
It makes more sense to log the message before it is sent to the DSP. Signed-off-by: Peter Ujfalusi <peter.ujfalusi@linux.intel.com> Reviewed-by: Kai Vehmanen <kai.vehmanen@linux.intel.com> Reviewed-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com> Reviewed-by: Ranjani Sridharan <ranjani.sridharan@linux.intel.com> Reviewed-by: Rander Wang <rander.wang@intel.com> Link: https://lore.kernel.org/r/20221018124008.6846-2-peter.ujfalusi@linux.intel.com Signed-off-by: Mark Brown <broonie@kernel.org>
Diffstat (limited to 'sound/soc/sof/ipc4.c')
-rw-r--r--sound/soc/sof/ipc4.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/sound/soc/sof/ipc4.c b/sound/soc/sof/ipc4.c
index 6eaa18e27e5a..3c9b8692984a 100644
--- a/sound/soc/sof/ipc4.c
+++ b/sound/soc/sof/ipc4.c
@@ -342,6 +342,8 @@ static int ipc4_tx_msg_unlocked(struct snd_sof_ipc *ipc,
if (msg_bytes > ipc->max_payload_size || reply_bytes > ipc->max_payload_size)
return -EINVAL;
+ sof_ipc4_log_header(sdev->dev, "ipc tx ", msg_data, true);
+
ret = sof_ipc_send_msg(sdev, msg_data, msg_bytes, reply_bytes);
if (ret) {
dev_err_ratelimited(sdev->dev,
@@ -350,8 +352,6 @@ static int ipc4_tx_msg_unlocked(struct snd_sof_ipc *ipc,
return ret;
}
- sof_ipc4_log_header(sdev->dev, "ipc tx ", msg_data, true);
-
/* now wait for completion */
return ipc4_wait_tx_done(ipc, reply_data);
}