hal: Fix VoIP Mute failure in SIP call during Voice call HOLD
- Unable to apply the mute in MT SIP call during Voice call
in CALL_HOLD.
- Mute is only applied if the voice call state is INACTIVE.
Thus when SIP call is made during Voice call in CALL_HOLD,
the mute is not being reflected.
- Fix this issue by checking voice stream type to allow
the mute to be applied.
Change-Id: I3af5225edd8e9a4123867b647de9405d5c4b9efc
CRs-Fixed: 642893
diff --git a/hal/voice.c b/hal/voice.c
index 62d01db..bad9255 100644
--- a/hal/voice.c
+++ b/hal/voice.c
@@ -197,6 +197,19 @@
return in_call;
}
+bool voice_is_in_call_rec_stream(struct stream_in *in)
+{
+ bool in_call_rec = false;
+ int ret = 0;
+
+ ret = voice_extn_is_in_call_rec_stream(in, &in_call_rec);
+ if (ret == -ENOSYS) {
+ in_call_rec = false;
+ }
+
+ return in_call_rec;
+}
+
uint32_t voice_get_active_session_id(struct audio_device *adev)
{
int ret = 0;