From: "Andrei A. Bykov" <andreiab9019@gmail.com>
To: linux-bluetooth@vger.kernel.org
Cc: marcel@holtmann.org, luiz.dentz@gmail.com, linux-kernel@vger.kernel.org
Subject: [PATCH v4 0/2] Bluetooth: fix bonded LE peripheral reconnect completion and holds
Date: Wed, 25 Nov 2026 10:08:26 -0300 [thread overview]
Message-ID: <20261125130828.18441-1-andreiab9019@gmail.com> (raw)
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 v3:
- Rebase onto bluetooth-next at f57f78086ab5. IncrementalBuild reset to
origin/master, where the newly added MT7922 data-length block changed
the context of patch 2. Keep that block intact and apply the same LE
setup check below it. Patch 1 is unchanged.
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 v4 patches apply in order with git am on the pinned bluetooth-next
base and the GitHub workflow branch used by Bluetooth CI. I reproduced
the IncrementalBuild sequence on f57f78086ab5 using BlueZ's ci.config:
make olddefconfig, then git am and make net/bluetooth/ drivers/bluetooth/
after each patch. Both builds passed. Local model tests pass 152
command-dispatch checks and 66 connection-lifetime checks with GCC,
Clang and ASan/UBSan, including checks for the MT7922 path.
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/
v3: https://lore.kernel.org/r/20261124211127.41609-1-andreiab9019@gmail.com
v3 CI: https://github.com/bluez/bluetooth-next/pull/1221#issuecomment-7151355640
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: f57f78086ab54f3b3122fbaeba2c842ba7bb6d00
--
2.56.1
next reply other threads:[~2026-11-25 13:09 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-11-25 13:08 Andrei A. Bykov [this message]
2026-11-25 13:08 ` [PATCH v4 1/2] Bluetooth: hci_sync: keep unrelated replies away from event waiters Andrei A. Bykov
2026-11-25 13:08 ` [PATCH v4 2/2] Bluetooth: hci_core: preserve LE feature holds across encryption events Andrei A. Bykov
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20261125130828.18441-1-andreiab9019@gmail.com \
--to=andreiab9019@gmail.com \
--cc=linux-bluetooth@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=luiz.dentz@gmail.com \
--cc=marcel@holtmann.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®