diff options
author | Ritu Sharma <quic_ritushar@quicinc.com> | 2022-01-25 12:55:06 +0530 |
---|---|---|
committer | Gerrit - the friendly Code Review server <code-review@localhost> | 2022-07-25 02:54:39 -0700 |
commit | cd090cb9e90b19ddb512c9b395995f2dd1cf2c60 (patch) | |
tree | dc68e69f6d9a6cc3c664b7e4185febe4b9c75dcd /dsp | |
parent | 290f69973e89968b5fab399cb9f32eb651c2eb22 (diff) | |
download | msm-extra-cd090cb9e90b19ddb512c9b395995f2dd1cf2c60.tar.gz |
dsp: Correct the condition check of apm ready.
Correct the condition check of apm ready status during
prm_send_pkt, loop should exit if apm is ready or retry
count exceeds max count.
Change-Id: I0c32731cb3696ef388a0d17d873a8b1485b54805
Signed-off-by: Ritu Sharma <quic_ritushar@quicinc.com>
Diffstat (limited to 'dsp')
-rw-r--r-- | dsp/audio_prm.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/dsp/audio_prm.c b/dsp/audio_prm.c index 974c025a..c77c69f0 100644 --- a/dsp/audio_prm.c +++ b/dsp/audio_prm.c @@ -102,9 +102,9 @@ static int prm_gpr_send_pkt(struct gpr_pkt *pkt, wait_queue_head_t *wait) (gpr_get_q6_state() == GPR_SUBSYS_LOADED)) { pr_info("%s: apm ready check not done\n", __func__); retry = 0; - while (!spf_core_is_apm_ready() || retry < MAX_RETRY_COUNT) { + while (!spf_core_is_apm_ready() && retry < MAX_RETRY_COUNT) { msleep(APM_READY_WAIT_DURATION); - retry++; + ++retry; } is_apm_ready_check_done = true; pr_info("%s: apm ready check done\n", __func__); |