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

Skip to content
Commit 0c280aa1 authored by François Gaffie's avatar François Gaffie Committed by Eric Laurent
Browse files

AudioFlinger: update cache in/out configuration on device port id change



In case of creation of AudioPatch with the same device type but a different
device id (typically: a device has been connected / disconnection, so
removed and re-attached to its corresponding module, a new Id is assigned),
the cache configuration of the clients is not updated.
If the client calls getRoutedDevice, the id will not be up to date and even
may refer to unknown port id.

Test: as follows:
1 / Calls setDeviceConnectionState AUDIO_DEVICE_OUT_HDMI state=1 mame=y_dummy_hdmi @=my_dummy_hdmi
2 / Plays explicititely on this device (by getting the id
	AudioSystem::listAudioPorts

2 / Calls setDeviceConnectionState AUDIO_DEVICE_OUT_HDMI state=0

3 / Calls setDeviceConnectionState AUDIO_DEVICE_OUT_HDMI state=1  mame=y_dummy_hdmi @=my_dummy_hdmi
    Plays explicititely on this device (by getting the id
        AudioSystem::listAudioPorts

4 / Calls AudioTrack->getRoutedDeviceId()
	The id shall match the second one, NOT the first one
that does not exist any more

Change-Id: I608ed8d78907b5ea1c9b6ef13c6cbfe528d88f44
Signed-off-by: default avatarFrançois Gaffie <francois.gaffie@renault.com>
parent 3305c11a
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