summaryrefslogtreecommitdiff
path: root/sound_trigger_hw_iaxxx.c
diff options
context:
space:
mode:
Diffstat (limited to 'sound_trigger_hw_iaxxx.c')
-rw-r--r--sound_trigger_hw_iaxxx.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/sound_trigger_hw_iaxxx.c b/sound_trigger_hw_iaxxx.c
index fbbfa79..e3d34ff 100644
--- a/sound_trigger_hw_iaxxx.c
+++ b/sound_trigger_hw_iaxxx.c
@@ -2632,6 +2632,10 @@ static int stop_recognition(struct knowles_sound_trigger_device *stdev,
model->is_active = false;
goto exit;
}
+ if (model->is_active == false) {
+ ALOGW("%s: the model was disabled already", __func__);
+ goto exit;
+ }
if (stdev->adnc_strm_handle[handle] != 0) {
ALOGD("%s: stop tunnling for index:%d", __func__, handle);