Merge "ASoC: msm: qdsp6v2: Handle subsystem restart event"
diff --git a/sound/soc/msm/qdsp6v2/q6lsm.c b/sound/soc/msm/qdsp6v2/q6lsm.c
index 49e5ede..daa2916 100644
--- a/sound/soc/msm/qdsp6v2/q6lsm.c
+++ b/sound/soc/msm/qdsp6v2/q6lsm.c
@@ -83,6 +83,13 @@
 		return -EINVAL;
 	}
 
+	if (data->opcode == RESET_EVENTS) {
+		pr_debug("%s: SSR event received 0x%x, event 0x%x, proc 0x%x\n",
+			 __func__, data->opcode, data->reset_event,
+			 data->reset_proc);
+		return 0;
+	}
+
 	payload = data->payload;
 	pr_debug("%s: Session %d opcode 0x%x token 0x%x payload size %d\n",
 		__func__, client->session,
@@ -649,12 +656,21 @@
 static int q6lsm_mmapcallback(struct apr_client_data *data, void *priv)
 {
 	unsigned long flags;
-	uint32_t sid = 0;
+	uint32_t command;
+	uint32_t retcode;
+	uint32_t sid;
 	const uint32_t *payload = data->payload;
-	const uint32_t command = payload[0];
-	const uint32_t retcode = payload[1];
 	struct lsm_client *client = NULL;
 
+	if (data->opcode == RESET_EVENTS) {
+		pr_debug("%s: SSR event received 0x%x, event 0x%x, proc 0x%x\n",
+			 __func__, data->opcode, data->reset_event,
+			 data->reset_proc);
+		return 0;
+	}
+
+	command = payload[0];
+	retcode = payload[1];
 	pr_debug("%s: opcode 0x%x command 0x%x return code 0x%x\n", __func__,
 		 data->opcode, command, retcode);