diff options
author | Eric Laurent <elaurent@google.com> | 2014-09-15 17:40:22 +0000 |
---|---|---|
committer | Android (Google) Code Review <android-gerrit@google.com> | 2014-09-15 17:40:23 +0000 |
commit | 2a6074c4f7dd6f5b85ea8d858199d4970ff404ac (patch) | |
tree | fc7a0d51f11e9e25f35d8e3f6d9476dbc0498385 /services | |
parent | 83a23e1e1e45d9e2f5497e214796250f74aad1d4 (diff) | |
parent | 2f035f59d1e28728d38d18a7f0f7a9c6e8b0c11b (diff) | |
download | frameworks_av-2a6074c4f7dd6f5b85ea8d858199d4970ff404ac.zip frameworks_av-2a6074c4f7dd6f5b85ea8d858199d4970ff404ac.tar.gz frameworks_av-2a6074c4f7dd6f5b85ea8d858199d4970ff404ac.tar.bz2 |
Merge "audioflinger: send mic mute command to all audio HALs" into lmp-dev
Diffstat (limited to 'services')
-rw-r--r-- | services/audioflinger/AudioFlinger.cpp | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/services/audioflinger/AudioFlinger.cpp b/services/audioflinger/AudioFlinger.cpp index 1843722..cee7feb 100644 --- a/services/audioflinger/AudioFlinger.cpp +++ b/services/audioflinger/AudioFlinger.cpp @@ -796,9 +796,14 @@ status_t AudioFlinger::setMicMute(bool state) } AutoMutex lock(mHardwareLock); - audio_hw_device_t *dev = mPrimaryHardwareDev->hwDevice(); mHardwareStatus = AUDIO_HW_SET_MIC_MUTE; - ret = dev->set_mic_mute(dev, state); + for (size_t i = 0; i < mAudioHwDevs.size(); i++) { + audio_hw_device_t *dev = mAudioHwDevs.valueAt(i)->hwDevice(); + status_t result = dev->set_mic_mute(dev, state); + if (result != NO_ERROR) { + ret = result; + } + } mHardwareStatus = AUDIO_HW_IDLE; return ret; } |