linux-bluetooth.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH BlueZ 1/2] core/device: Fix attempting to connect to random address over BR/EDR
@ 2016-09-02 12:49 Luiz Augusto von Dentz
  2016-09-02 12:49 ` [PATCH BlueZ 2/2] core/gatt-client: Fix not return empty array for ReadValue Luiz Augusto von Dentz
                   ` (2 more replies)
  0 siblings, 3 replies; 6+ messages in thread
From: Luiz Augusto von Dentz @ 2016-09-02 12:49 UTC (permalink / raw)
  To: linux-bluetooth

From: Luiz Augusto von Dentz <luiz.von.dentz@intel.com>

BR/EDR don't have the concept of random addresses so the only option is
to over LE in that case.
---
 src/device.c | 4 ++++
 1 file changed, 4 insertions(+)

diff --git a/src/device.c b/src/device.c
index fb766d1..b8556f1 100644
--- a/src/device.c
+++ b/src/device.c
@@ -1748,6 +1748,10 @@ static uint8_t select_conn_bearer(struct btd_device *dev)
 	else if (!dev->bredr_state.bonded && dev->le_state.bonded)
 		return dev->bdaddr_type;
 
+	/* If the address is private it can only be connected over LE */
+	if (device_address_is_private(dev))
+		return dev->bdaddr_type;
+
 	if (dev->bredr_seen) {
 		bredr_last = current - dev->bredr_seen;
 		if (bredr_last > SEEN_TRESHHOLD)
-- 
2.7.4


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

end of thread, other threads:[~2016-09-06  4:57 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2016-09-02 12:49 [PATCH BlueZ 1/2] core/device: Fix attempting to connect to random address over BR/EDR Luiz Augusto von Dentz
2016-09-02 12:49 ` [PATCH BlueZ 2/2] core/gatt-client: Fix not return empty array for ReadValue Luiz Augusto von Dentz
2016-09-05  9:46 ` [PATCH BlueZ 1/2] core/device: Fix attempting to connect to random address over BR/EDR Luiz Augusto von Dentz
2016-09-05 18:02 ` Johan Hedberg
2016-09-05 18:35   ` Luiz Augusto von Dentz
2016-09-06  4:57     ` Johan Hedberg

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).