Re: [PATCH 3/3] Bluetooth: Don't leave abandoned SCO links up in the controller
From: Hitalo Souza
Date: Thu Oct 08 2026 - 11:36:36 EST
Hi Luiz,
On Wed, Oct 7, 2026 at 2:15 PM Luiz Augusto von Dentz <luiz.dentz@xxxxxxxxx> wrote:
> Sashiko flagged quite a few problems:
>
> https://sashiko.dev/#/patchset/20261007154353.148223-1-enghitalo%40gmail.com
>
> We need to check if the logic of hci_sco_disconnect_orphan couldn't be
> made more generically, so in case the connection was aborted but we
> received the connection complete that shall always result in
> HCI_OP_DISCONNECT so the handle don't stay active in the controller.
Thanks, agreed. v2 does that in two patches:
- when hci_conn_set_handle() refuses the handle because the connection
is being aborted, the Connection Complete, Synchronous Connection
Complete and LE Connection Complete handlers now disconnect the link,
with the abort reason;
- an ACL link that completes after its connection was already aborted
and deleted (an incoming connection, where Create Connection Cancel
fails at once) is disconnected too, as SCO links already are.
Both reproduce in an emulator (ACL outgoing and incoming, and LE):
without them the link stays up. The SCO patch now uses the same helper.
The other two Sashiko findings are addressed as well: the legacy
Connection Complete path in the SCO patch, and the air mode
notification of a SCO link that failed in a separate patch, as it
predates this series (1f8330ea1692).
v2 is here:
https://lore.kernel.org/linux-bluetooth/20261008151238.2138665-1-enghitalo@xxxxxxxxx/
Hitalo