Browse Source

soc: swr-mstr: Register for wakeup irq after disabling clk

During clock stop, Register for lpass wakeup only after
disabling the clock to avoid flooding of interrupts when
master is turned on for pending slave irq.

Change-Id: Ifbf604048d4972beb22b6286930193b83a2249e8
Signed-off-by: Ramprasad Katkam <[email protected]>
Ramprasad Katkam 6 năm trước cách đây
mục cha
commit
6a3050d838
1 tập tin đã thay đổi với 7 bổ sung5 xóa
  1. 7 5
      soc/swr-mstr-ctrl.c

+ 7 - 5
soc/swr-mstr-ctrl.c

@@ -1976,13 +1976,15 @@ static int swrm_runtime_suspend(struct device *dev)
 			swrm_cmd_fifo_wr_cmd(swrm, 0x2, 0xF, 0xF,
 					SWRS_SCP_CONTROL);
 			usleep_range(100, 105);
-			if (swrm->wakeup_req) {
-				msm_aud_evt_blocking_notifier_call_chain(
-					SWR_WAKE_IRQ_REGISTER, (void *)swrm);
-				swrm->wakeup_triggered = false;
-			}
 		}
 		swrm_clk_request(swrm, false);
+
+		if (swrm->clk_stop_mode0_supp && swrm->wakeup_req) {
+			msm_aud_evt_blocking_notifier_call_chain(
+				SWR_WAKE_IRQ_REGISTER, (void *)swrm);
+			swrm->wakeup_triggered = false;
+		}
+
 	}
 	/* Retain  SSR state until resume */
 	if (current_state != SWR_MSTR_SSR)