Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Skip to content
Commit 00abf0d0 authored by Eric Laurent's avatar Eric Laurent
Browse files

AudioFlinger: fix getMicrophones implementation

getMicrophones() should return aggregated mic information
from all HW modules, not just primary.

Also:
- Fix assignment of mPrimaryHardwareDev that should be
first from HW module name and then according to primary output
if no module with name "primary" is loaded.

- Make sure we do not dereference mPrimaryHardwareDev if null.
Note that this should not happen with current rule that a primary module
must be present.

- Implement consistent locking scheme where both mPrimaryHardwareDev and
mAudioHwDevs are guarded by mHardwareLock

Bug: 154772890
Test: AudioManagerTest#testGetMicrophones
Change-Id: I7c9449bb705a6fbebdc0642166e58348d47b7ee8
parent 369ad274
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment