Merge "AudioService: fix cross deadlock" into qt-dev
am: 076b22f987
Change-Id: I3d48403142747f77ee786a084a60b6087aab831d
This commit is contained in:
@@ -4974,19 +4974,17 @@ public class AudioService extends IAudioService.Stub
|
||||
}
|
||||
|
||||
private void onSetVolumeIndexOnDevice(@NonNull DeviceVolumeUpdate update) {
|
||||
synchronized (VolumeStreamState.class) {
|
||||
final VolumeStreamState streamState = mStreamStates[update.mStreamType];
|
||||
if (update.hasVolumeIndex()) {
|
||||
final int index = update.getVolumeIndex();
|
||||
streamState.setIndex(index, update.mDevice, update.mCaller);
|
||||
sVolumeLogger.log(new AudioEventLogger.StringEvent(update.mCaller + " dev:0x"
|
||||
+ Integer.toHexString(update.mDevice) + " volIdx:" + index));
|
||||
} else {
|
||||
sVolumeLogger.log(new AudioEventLogger.StringEvent(update.mCaller
|
||||
+ " update vol on dev:0x" + Integer.toHexString(update.mDevice)));
|
||||
}
|
||||
setDeviceVolume(streamState, update.mDevice);
|
||||
final VolumeStreamState streamState = mStreamStates[update.mStreamType];
|
||||
if (update.hasVolumeIndex()) {
|
||||
final int index = update.getVolumeIndex();
|
||||
streamState.setIndex(index, update.mDevice, update.mCaller);
|
||||
sVolumeLogger.log(new AudioEventLogger.StringEvent(update.mCaller + " dev:0x"
|
||||
+ Integer.toHexString(update.mDevice) + " volIdx:" + index));
|
||||
} else {
|
||||
sVolumeLogger.log(new AudioEventLogger.StringEvent(update.mCaller
|
||||
+ " update vol on dev:0x" + Integer.toHexString(update.mDevice)));
|
||||
}
|
||||
setDeviceVolume(streamState, update.mDevice);
|
||||
}
|
||||
|
||||
/*package*/ void setDeviceVolume(VolumeStreamState streamState, int device) {
|
||||
|
||||
Reference in New Issue
Block a user