[PATCH] ASoC: SOF: amd: Add support for IPC with a reply_size set to zero

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Add support for IPC tx_message with a reply_size set to zero,
return zero when message reply_size is zero at acp_dsp_ipc_get_reply().

Signed-off-by: Venkata Prasad Potturu <venkataprasad.potturu@xxxxxxx>
---
 sound/soc/sof/amd/acp-ipc.c | 7 +++++++
 1 file changed, 7 insertions(+)

diff --git a/sound/soc/sof/amd/acp-ipc.c b/sound/soc/sof/amd/acp-ipc.c
index 749e856dc601..8a0fc635a997 100644
--- a/sound/soc/sof/amd/acp-ipc.c
+++ b/sound/soc/sof/amd/acp-ipc.c
@@ -130,6 +130,13 @@ static void acp_dsp_ipc_get_reply(struct snd_sof_dev *sdev)
 		memcpy(msg->reply_data, &reply, sizeof(reply));
 		ret = reply.error;
 	} else {
+		/*
+		 * To support an IPC tx_message with a
+		 * reply_size set to zero.
+		 */
+		if (!msg->reply_size)
+			goto out;
+
 		/* reply correct size ? */
 		if (reply.hdr.size != msg->reply_size &&
 		    !(reply.hdr.cmd & SOF_IPC_GLB_PROBE)) {
-- 
2.25.1




[Index of Archives]     [ALSA User]     [Linux Audio Users]     [Pulse Audio]     [Kernel Archive]     [Asterisk PBX]     [Photo Sharing]     [Linux Sound]     [Video 4 Linux]     [Gimp]     [Yosemite News]

  Powered by Linux