alsa-devel.alsa-project.org archive mirror
 help / color / mirror / Atom feed
From: Cezary Rojewski <cezary.rojewski@intel.com>
To: alsa-devel@alsa-project.org, broonie@kernel.org
Cc: Cezary Rojewski <cezary.rojewski@intel.com>,
	pierre-louis.bossart@linux.intel.com, tiwai@suse.com,
	hdegoede@redhat.com, amadeuszx.slawinski@linux.intel.com
Subject: [PATCH 10/15] ASoC: Intel: avs: Do not reuse msg between different IPC handlers
Date: Mon, 10 Oct 2022 14:07:44 +0200	[thread overview]
Message-ID: <20221010120749.716499-11-cezary.rojewski@intel.com> (raw)
In-Reply-To: <20221010120749.716499-1-cezary.rojewski@intel.com>

While LOG_BUFFER_STATUS is a simple notification with only one
meaningful field, same message ptr shall not be reused for two different
handlers.

Signed-off-by: Cezary Rojewski <cezary.rojewski@intel.com>
---
 sound/soc/intel/avs/apl.c | 6 ++++--
 1 file changed, 4 insertions(+), 2 deletions(-)

diff --git a/sound/soc/intel/avs/apl.c b/sound/soc/intel/avs/apl.c
index b8e2b23c9f64..7c8ce98eda9d 100644
--- a/sound/soc/intel/avs/apl.c
+++ b/sound/soc/intel/avs/apl.c
@@ -133,12 +133,14 @@ static int apl_coredump(struct avs_dev *adev, union avs_notify_msg *msg)
 	buf = apl_log_payload_addr(addr);
 	memcpy_fromio(&layout, addr, sizeof(layout));
 	if (!apl_is_entry_stackdump(buf + layout.read_ptr)) {
+		union avs_notify_msg lbs_msg = AVS_NOTIFICATION(LOG_BUFFER_STATUS);
+
 		/*
 		 * DSP awaits the remaining logs to be
 		 * gathered before dumping stack
 		 */
-		msg->log.core = msg->ext.coredump.core_id;
-		avs_dsp_op(adev, log_buffer_status, msg);
+		lbs_msg.log.core = msg->ext.coredump.core_id;
+		avs_dsp_op(adev, log_buffer_status, &lbs_msg);
 	}
 
 	pos = dump + AVS_FW_REGS_SIZE;
-- 
2.25.1


  parent reply	other threads:[~2022-10-10 11:55 UTC|newest]

Thread overview: 17+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-10-10 12:07 [PATCH 00/15] ASoC: Intel: avs: Fixes and new boards support Cezary Rojewski
2022-10-10 11:57 ` Cezary Rojewski
2022-10-10 12:07 ` [PATCH 01/15] ASoC: Intel: avs: Fix DMA mask assignment Cezary Rojewski
2022-10-10 12:07 ` [PATCH 02/15] ASoC: Intel: avs: Fix potential RX buffer overflow Cezary Rojewski
2022-10-10 12:07 ` [PATCH 03/15] ASoC: codecs: rt298: Add quirk for KBL-R RVP platform Cezary Rojewski
2022-10-10 12:07 ` [PATCH 04/15] ASoC: Intel: avs: " Cezary Rojewski
2022-10-10 12:07 ` [PATCH 05/15] ASoC: Intel: avs: Support AML with rt286 configuration Cezary Rojewski
2022-10-10 12:07 ` [PATCH 06/15] ASoC: Intel: avs: Support da7219 on both KBL and APL Cezary Rojewski
2022-10-10 12:07 ` [PATCH 07/15] ASoC: Intel: avs: Add missing SKL-based device IDs Cezary Rojewski
2022-10-10 12:07 ` [PATCH 08/15] ASoC: Intel: avs: Simplify d0ix disabling routine Cezary Rojewski
2022-10-10 12:07 ` [PATCH 09/15] ASoC: Intel: avs: Add missing include to HDA board Cezary Rojewski
2022-10-10 12:07 ` Cezary Rojewski [this message]
2022-10-10 12:07 ` [PATCH 11/15] ASoC: Intel: avs: Do not treat unsupported IPCs as invalid Cezary Rojewski
2022-10-10 12:07 ` [PATCH 12/15] ASoC: Intel: avs: Do not print IPC error message twice Cezary Rojewski
2022-10-10 12:07 ` [PATCH 13/15] ASoC: Intel: avs: Simplify ignore_fw_version description Cezary Rojewski
2022-10-10 12:07 ` [PATCH 14/15] ASoC: Intel: avs: Simplify log control for SKL Cezary Rojewski
2022-10-10 12:07 ` [PATCH 15/15] ASoC: codecs: hda: Fix spelling error in log message Cezary Rojewski

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20221010120749.716499-11-cezary.rojewski@intel.com \
    --to=cezary.rojewski@intel.com \
    --cc=alsa-devel@alsa-project.org \
    --cc=amadeuszx.slawinski@linux.intel.com \
    --cc=broonie@kernel.org \
    --cc=hdegoede@redhat.com \
    --cc=pierre-louis.bossart@linux.intel.com \
    --cc=tiwai@suse.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).