Linux bluetooth development
 help / color / mirror / Atom feed
* [PATCH v3 0/2] Bluetooth: fix bonded LE peripheral reconnect completion and holds
@ 2026-11-24 21:11 Andrei A. Bykov
  2026-11-24 21:11 ` [PATCH v3 1/2] Bluetooth: hci_sync: keep unrelated replies away from event waiters Andrei A. Bykov
  2026-11-24 21:11 ` [PATCH v3 2/2] Bluetooth: hci_core: preserve LE feature holds across encryption events Andrei A. Bykov
  0 siblings, 2 replies; 3+ messages in thread
From: Andrei A. Bykov @ 2026-11-24 21:11 UTC (permalink / raw)
  To: linux-bluetooth; +Cc: marcel, luiz.dentz, linux-kernel

This series fixes two issues in the Bluetooth HCI layer seen when a
bonded Windows central reconnects to a Linux LE HID peripheral.

Changes since v2:
- Rebase onto bluetooth-next at 6a40daae69b0. The Bluetooth CI bot
  could not apply v2 because the key-refresh configuration code moved
  into hci_conn_refresh_key(). Update that shared helper in patch 2 so
  both Key Refresh Complete event formats use the same path.
- Preserve the LE setup abort checks in both feature-complete handlers
  on the new base. Patch 1 has no functional changes.

Changes since v1:
- Refresh the saved synchronous request after timeout or cancellation,
  preserving socket references across controller reset resends.
- Keep the LE feature hold across encryption and key refresh. Explicitly
  abort failed setup and prevent later events from reporting success.

Both v3 patches apply in order with git am on the pinned bluetooth-next
base and the GitHub workflow branch used by Bluetooth CI. Local model
tests pass 152 command-dispatch checks and 62 connection-lifetime checks
with GCC, Clang and ASan/UBSan.

The v2 backport to Linux 7.3.5 passed repeated bonded reconnects,
approximately seven hours without observed connection loss, and Windows
Bluetooth off/on. Those hardware results are from v2. In separate
Windows suspend/resume attempts, the test HID application could still
wait for an HID subscription after BlueZ reported a connection.

OpenAI Codex assisted with analysis, patch preparation and tests.
Sashiko provided the findings addressed in v2.

v1: https://lore.kernel.org/r/20261121033104.441146-1-andreiab9019@gmail.com
v2: https://lore.kernel.org/r/20261124140956.15296-1-andreiab9019@gmail.com
v2 CI: https://patchwork.kernel.org/comment/27404265/

Andrei A. Bykov (2):
  Bluetooth: hci_sync: keep unrelated replies away from event waiters
  Bluetooth: hci_core: preserve LE feature holds across encryption
    events

 include/net/bluetooth/hci_core.h |  9 +++++++-
 net/bluetooth/hci_core.c         | 16 +++++++++++++-
 net/bluetooth/hci_event.c        | 36 +++++++++++++++++++++++++-------
 3 files changed, 52 insertions(+), 9 deletions(-)


base-commit: 6a40daae69b0c45d4f8b6aa247fca165b8534f60
-- 
2.56.1


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

end of thread, other threads:[~2026-11-24 21:12 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-11-24 21:11 [PATCH v3 0/2] Bluetooth: fix bonded LE peripheral reconnect completion and holds Andrei A. Bykov
2026-11-24 21:11 ` [PATCH v3 1/2] Bluetooth: hci_sync: keep unrelated replies away from event waiters Andrei A. Bykov
2026-11-24 21:11 ` [PATCH v3 2/2] Bluetooth: hci_core: preserve LE feature holds across encryption events Andrei A. Bykov

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