* [PATCH BlueZ] adapter: Fix failed bonding attempt after LE link disconnection
@ 2026-06-08 11:10 Simon Mikuda
2026-06-08 12:21 ` [BlueZ] " bluez.test.bot
0 siblings, 1 reply; 2+ messages in thread
From: Simon Mikuda @ 2026-06-08 11:10 UTC (permalink / raw)
To: linux-bluetooth; +Cc: Simon Mikuda
What happens when issue occurs:
- device is connected to both bearers BR/EDR and LE
- bonding is requested
- LE link disconnects
- pairing keys arrive
BlueZ would finish bonding request with error and mark device as
temporary. Then it would be disconnected+removed after default
temporary timeout (30 seconds).
---
src/adapter.c | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
diff --git a/src/adapter.c b/src/adapter.c
index 03593d962..a08847663 100644
--- a/src/adapter.c
+++ b/src/adapter.c
@@ -8622,7 +8622,9 @@ static void dev_disconnected(struct btd_adapter *adapter,
disconnect_notify(device, reason);
}
- bonding_attempt_complete(adapter, &addr->bdaddr, addr->type,
+ /* device could be still connected to different bearer */
+ if (!btd_device_is_connected(device))
+ bonding_attempt_complete(adapter, &addr->bdaddr, addr->type,
MGMT_STATUS_DISCONNECTED);
}
--
2.43.0
^ permalink raw reply related [flat|nested] 2+ messages in thread
end of thread, other threads:[~2026-06-08 12:21 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-06-08 11:10 [PATCH BlueZ] adapter: Fix failed bonding attempt after LE link disconnection Simon Mikuda
2026-06-08 12:21 ` [BlueZ] " bluez.test.bot
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox