AudioService: make setCommunicationDevice asynchronous

Make setCommunicationDevice return immediately after basic
checks but before the new requested path is actually applied.

Add a synchronization mutex between setCommunicationDevice and
getCommunicationDevice to keep the getter result consistent.

Bug: 308879516
Test: AudioCommunicationDeviceTest
Test: AudioManagerTest
Change-Id: I14cef3fffab4ccdbc2b1ed5cfefc9ce87a91af71
1 file changed