audio: stop reading sound trigger lab data on SSR
While sound trigger lab data being read, if CPE SSR
happens the pcm read returns -ENETRESET. Instead of
updating the sound card sate, mark the sound trigger
state as inactive to avoid reading the lab data from
driver. Marking the session as inactive handle both
CPE and ADSP SSR scenarios where HAL is prevented
to read from kernel.
Change-Id: Id82eed597c01265a7d26f17e5ac3c5cd0e17adbf
CRs-fixed: 790726
diff --git a/hal/audio_extn/soundtrigger.c b/hal/audio_extn/soundtrigger.c
index 5f4c6ba..9051334 100644
--- a/hal/audio_extn/soundtrigger.c
+++ b/hal/audio_extn/soundtrigger.c
@@ -165,6 +165,7 @@
in->config = st_ses_info->st_ses.config;
in->channel_mask = audio_channel_in_mask_from_count(in->config.channels);
in->is_st_session = true;
+ in->is_st_session_active = true;
ALOGD("%s: capture_handle %d is sound trigger", __func__, in->capture_handle);
break;
}