From: Philipp Dunkel <noreply@github.com>
To: linux-bluetooth@vger.kernel.org
Subject: [bluez/bluez] 0e25b2: adapter: Infer BR/EDR only at public LE addresses
Date: Fri, 17 Jul 2026 03:14:52 -0700 [thread overview]
Message-ID: <bluez/bluez/push/refs/heads/1129413/000000-0e25b2@github.com> (raw)
Branch: refs/heads/1129413
Home: https://github.com/bluez/bluez
Commit: 0e25b2b3c57c5d086e3f08aae50444c9621361d2
https://github.com/bluez/bluez/commit/0e25b2b3c57c5d086e3f08aae50444c9621361d2
Author: Philipp Dunkel <pip@pipobscure.com>
Date: 2026-07-17 (Fri, 17 Jul 2026)
Changed paths:
M src/adapter.c
Log Message:
-----------
adapter: Infer BR/EDR only at public LE addresses
btd_adapter_device_found() records BR/EDR support for any LE device
whose advertising Flags lack "BR/EDR Not Supported" (EIR_BREDR_UNSUP).
The address type is not considered:
if (bdaddr_type != BDADDR_BREDR && eir_data.flags &&
!(eir_data.flags & EIR_BREDR_UNSUP)) {
device_set_bredr_support(dev);
When the advertisement uses a random address the device gets a BR/EDR
bearer whose address is that random address, and start_discovery_cb()
then prefers SDP over GATT:
if (device->bredr)
device_browse_sdp(device, NULL);
else
device_browse_gatt(device, NULL);
SDP requires a BR/EDR ACL, so bluetoothd pages the random address. A
random address is not a BD_ADDR and cannot be paged, so the attempt
always ends in Page Timeout, and the failure tears down the working LE
link:
connect_failed_callback() hci0 5A:B4:98:1F:CC:04 status 4
bonding_attempt_complete() hci0 bdaddr 5A:B4:98:1F:CC:04
type 0 status 0x4
device_bonding_complete() bonding (nil) status 0x04
browse_request_cancel()
btd_gatt_database_att_disconnected()
Nothing requested the connection ("bonding (nil)") and the LE link was
healthy. Any LE association that outlives the page timeout is killed by
it; measured on one host, applications get about 4.7 s from connect
before the link disappears, of which GATT discovery already takes 2.3 s.
Current phones advertise Flags 0x1a (LE General Discoverable plus
Simultaneous LE and BR/EDR, with BR/EDR Not Supported clear) from
resolvable private addresses, so this triggers routinely rather than in
some corner case.
The Flags bits describe what the device supports. They do not promise
that the address it is advertising from is a BD_ADDR. A dual-mode device
uses the same Public Device Address for BR/EDR and LE, so the inference
is sound only for BDADDR_LE_PUBLIC. Restrict it to that.
The other two device_set_bredr_support() callers already require the
device to have been seen over BR/EDR (bdaddr_type == BDADDR_BREDR), so
they are unaffected. A device later seen over BR/EDR, or whose RPA is
resolved to a public identity, still gets BR/EDR support recorded there.
To unsubscribe from these emails, change your notification settings at https://github.com/bluez/bluez/settings/notifications
reply other threads:[~2026-07-17 10:14 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
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=bluez/bluez/push/refs/heads/1129413/000000-0e25b2@github.com \
--to=noreply@github.com \
--cc=linux-bluetooth@vger.kernel.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