public inbox for linux-bluetooth@vger.kernel.org
 help / color / mirror / Atom feed
* [RFC PATCH BlueZ 0/9] BAP stream reconfiguration
@ 2025-03-01 15:57 Pauli Virtanen
  2025-03-01 15:57 ` [RFC PATCH BlueZ 1/9] org.bluez.MediaEndpoint: removing BAP streams with ClearConfiguration Pauli Virtanen
                   ` (8 more replies)
  0 siblings, 9 replies; 18+ messages in thread
From: Pauli Virtanen @ 2025-03-01 15:57 UTC (permalink / raw)
  To: linux-bluetooth; +Cc: Pauli Virtanen

Proposed DBus API extension is:

- org.bluez.MediaEndpoint.ClearConfiguration(transport_path):

  Destroy stream associated with transport

- org.bluez.MediaEndpoint.ClearConfiguration(remote_endpoint_path):

  Destroy all streams associated with endpoint

- org.bluez.MediaEndpoint.SelectProperties(remote_endpoint_path):

  Destroy streams of endpoint, and re-run same unicast configuration as
  on initial connect, which invokes SelectProperties() callbacks on
  sound server and it can return new configuration it wants.

For future:

- org.bluez.MediaEndpoint.SetConfiguration(...):

  I think how this already works for broadcast is good: one call creates
  one new stream. Unicast should be changed to work exactly the same
  way.

  This allows for more detailed control of the configuration than
  SelectProperties(), and sound server can use it if it wants to deal
  with the different ASE configurations by itself.

- We will need to figure out how to handle devices rejecting ASE
  configurations on Config Codec or Enable.

  Whose responsibility is it to try a different configuration, if the
  current configuration is rejected by device?

  Example: Sony Linkbuds S has 48kHz sink & 48kHz source PACs.  However,
  it does not support the duplx configuration with both 48kHz sink and
  48kHz source ASE -- it rejects that in Enable.  It does support 32 kHz
  sink + 32kHz source duplex configuration.  AFAICS it is not possible
  to know which combinations of sinks & sources are possible, except
  trying them one by one. How do we handle this?

Unicast works with this Pipewire branch (can reconfigure to
sink/source/duplex):
https://gitlab.freedesktop.org/pvir/pipewire/-/tree/bap-codec-switch-select

(With device sets, each device needs to be switched separately.  Some
more work is needed to make reconfiguration while CIG is active to work
correctly, sound server must release transports before reconfiguring.)

Broadcast has not been tested at all.

Pauli Virtanen (9):
  org.bluez.MediaEndpoint: removing BAP streams with ClearConfiguration
  org.bluez.MediaEndpoint: add client role SelectProperties
  bap: add and use chainable future abstraction
  bap: use futures for select operation
  shared/bap: bap_abort_stream_req() should cancel also current req
  shared/bap: make sure ucast client stream is destroyed after releasing
  bap: support removing streams with ClearConfiguration()
  bap: do not try QoS before links are updated & io created
  bap: implement client role SelectProperties()

 doc/org.bluez.MediaEndpoint.rst |  27 ++
 profiles/audio/bap.c            | 533 ++++++++++++++++++++++++++------
 profiles/audio/transport.c      |  17 +
 profiles/audio/transport.h      |   1 +
 src/shared/bap.c                |  39 ++-
 5 files changed, 522 insertions(+), 95 deletions(-)

-- 
2.48.1


^ permalink raw reply	[flat|nested] 18+ messages in thread

end of thread, other threads:[~2025-03-17 19:23 UTC | newest]

Thread overview: 18+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2025-03-01 15:57 [RFC PATCH BlueZ 0/9] BAP stream reconfiguration Pauli Virtanen
2025-03-01 15:57 ` [RFC PATCH BlueZ 1/9] org.bluez.MediaEndpoint: removing BAP streams with ClearConfiguration Pauli Virtanen
2025-03-01 17:12   ` BAP stream reconfiguration bluez.test.bot
2025-03-17 18:10   ` [RFC PATCH BlueZ 1/9] org.bluez.MediaEndpoint: removing BAP streams with ClearConfiguration Luiz Augusto von Dentz
2025-03-17 19:23     ` Pauli Virtanen
2025-03-01 15:57 ` [RFC PATCH BlueZ 2/9] org.bluez.MediaEndpoint: add client role SelectProperties Pauli Virtanen
2025-03-17 18:20   ` Luiz Augusto von Dentz
2025-03-01 15:57 ` [RFC PATCH BlueZ 3/9] bap: add and use chainable future abstraction Pauli Virtanen
2025-03-17 18:42   ` Luiz Augusto von Dentz
2025-03-01 15:57 ` [RFC PATCH BlueZ 4/9] bap: use futures for select operation Pauli Virtanen
2025-03-01 15:57 ` [RFC PATCH BlueZ 5/9] shared/bap: bap_abort_stream_req() should cancel also current req Pauli Virtanen
2025-03-01 15:57 ` [RFC PATCH BlueZ 6/9] shared/bap: make sure ucast client stream is destroyed after releasing Pauli Virtanen
2025-03-01 16:26   ` Pauli Virtanen
2025-03-17 18:55     ` Luiz Augusto von Dentz
2025-03-17 19:14       ` Pauli Virtanen
2025-03-01 15:57 ` [RFC PATCH BlueZ 7/9] bap: support removing streams with ClearConfiguration() Pauli Virtanen
2025-03-01 15:57 ` [RFC PATCH BlueZ 8/9] bap: do not try QoS before links are updated & io created Pauli Virtanen
2025-03-01 15:57 ` [RFC PATCH BlueZ 9/9] bap: implement client role SelectProperties() Pauli Virtanen

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox