leaudio: Fix handling AvailableContext changes during streaming.
As per specification, when Unicast Acceptor accepts stream with given context type and later remove accepted Context Type from the Available Context Types, the Unicast Initiator should not close the stream. Above can be found in CAP 1.0.1, 7.1.1. Available Audio Contexts. Ideal behavior of Unicast Acceptor would be to keep Available Context per each connected device and notify about removed context only devices which are not streaming yet. In the real life, there are many devices out there which keeps global Available Context Type value and just use it for all the Unicast Client. This behavior cause troubles for Unicast Clients, expecialy when during the streaming, one of the set member disconnects and later reconnects. Android keeps available context type per each device and also keeps context types in the group trying to remember what context types where accepted during the stream creation. Unfortunatelly this approach has an issue especially when one set member disconnects and reconnects. With new approach, Android keeps streaming context types in the group and whenever group->GetAvailableContext() is called, it ORs Available Contexts from all the ASEs with currently Streaming Contexts. Bug: 396312681 Test: atest bluetooth_le_audio_test bluetooth_le_audio_client_test Test: manual test cases with recording, disable/enable 1 set member Flag: Exempt, day-to-day fix, regression verified with unit tests and QA Change-Id: Ib328d417498fe3f1ac65f07b7df77ff58c646063
Loading
Please register or sign in to comment