summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorWolfgang Wiedmeyer <wolfgit@wiedmeyer.de>2017-05-12 15:25:47 +0200
committerWolfgang Wiedmeyer <wolfgit@wiedmeyer.de>2017-05-12 15:25:47 +0200
commitbab5ec20c6c0723102e9bb82a77ef9f7d6608419 (patch)
tree0edfa9b67f322a0d46d5a61f3c6634931bdad4c7
parent5473bc9aab6a479e3331f12a714518c82cfd2fcd (diff)
downloaddevice_samsung_maguro-bab5ec20c6c0723102e9bb82a77ef9f7d6608419.zip
device_samsung_maguro-bab5ec20c6c0723102e9bb82a77ef9f7d6608419.tar.gz
device_samsung_maguro-bab5ec20c6c0723102e9bb82a77ef9f7d6608419.tar.bz2
Audio-RIL-Interface: Mic mute implementation
Signed-off-by: Wolfgang Wiedmeyer <wolfgit@wiedmeyer.de>
-rw-r--r--audio-ril-interface/audio-ril-interface.c22
1 files changed, 22 insertions, 0 deletions
diff --git a/audio-ril-interface/audio-ril-interface.c b/audio-ril-interface/audio-ril-interface.c
index 9d1763f..b43250e 100644
--- a/audio-ril-interface/audio-ril-interface.c
+++ b/audio-ril-interface/audio-ril-interface.c
@@ -172,6 +172,28 @@ int SetCallAudioPath(void *data, enum ril_audio_path path)
return RIL_CLIENT_ERR_SUCCESS;
}
+int SetMute(void *data, enum ril_mic_mute mute)
+{
+ struct srs_client *client;
+ struct srs_snd_mic_mute_data mic_mute_state;
+ int rc;
+
+ ALOGD("%s(%p, %d)", __func__, data, mute);
+
+ if (data == NULL)
+ return RIL_CLIENT_ERR_INVAL;
+
+ client = (struct srs_client *) data;
+
+ mic_mute_state.mute = mute;
+
+ rc = srs_client_send(client, SRS_SND_SET_MIC_MUTE, &mic_mute_state, sizeof(mic_mute_state));
+ if (rc < 0)
+ return RIL_CLIENT_ERR_UNKNOWN;
+
+ return RIL_CLIENT_ERR_SUCCESS;
+}
+
int SetCallClockSync(void *data, enum ril_clock_state condition)
{
struct srs_client *client;