linux-bluetooth.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [RFC] Auto Connections
@ 2011-03-11 21:30 Claudio Takahasi
  2011-03-16  2:56 ` jaikumar Ganesh
                   ` (2 more replies)
  0 siblings, 3 replies; 8+ messages in thread
From: Claudio Takahasi @ 2011-03-11 21:30 UTC (permalink / raw)
  To: BlueZ development; +Cc: Ville Tervo

Hi guys,

It is time to get opinions from some gurus!

We need to implement automatic connections to implement the Profiles.
At the moment BlueZ supports only dual mode adapters, as consequence
BlueZ needs to start the LE connection. IMHO, it is better to leave
the responsibility to the controller, implementing "selective"
connections will only introduce more code without concrete benefits.
Configuring the controller to autonomously establish connections seems
to be the right approach to proceed.

This topic is NOT about StartDiscovery() + CreateDevice.
StartDiscovery uses active scanning and CreateDevice uses direct
connection establishment. We need a mechanism to automatically connect
to "trusted" devices or devices flagged as "AutoConnect".


My initial idea is: change the LE server socket to report
outgoing(host initiated) connections through the server socket.
Awkward?
To achieve that we need to manage the LE Create Connection(using
whitelist) in the kernel, extend the management interface to control
devices in the whitelist, change the LE Connection Complete Event
handling to get the Role properly.
Pros:
- Controller manage connections
- Flexible to support  connections to "trusted" resolvable address and
passive scanning
- Only one "flow" for the connections: LE server socket
- Maybe we could hide resolvable address from the userspace, mapping
it directly to public or static random
Cons:
- Risky
- Less control of the connection establishment process


Another approach can be to manage the LE connections(using whitelist)
from the userspace. BDADDR_ANY in the destination field(sockaddr_l2)
can be used to define LE connections using white list.
Pros:
- It will not be necessary to extend the management interface now,
address can be added directly to the controller's white list
- Doesn't require changes in the LE server socket
Cons:
- BDADDR_ANY in the destination field has no meaning for Basic Rate
- Needs to expose the resolvable address to the userspace
- Different "flows" for incoming/outgoing connections


Open issue(s):
* How to handle timeouts when sending LE Create Connection
* Passive scanning management


Cheers,
Claudio

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

end of thread, other threads:[~2011-03-23 19:11 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2011-03-11 21:30 [RFC] Auto Connections Claudio Takahasi
2011-03-16  2:56 ` jaikumar Ganesh
2011-03-16  2:57 ` jaikumar Ganesh
2011-03-16 20:40 ` Gustavo F. Padovan
2011-03-16 22:20   ` Claudio Takahasi
2011-03-21 11:00     ` Arun K. Singh
     [not found]     ` <AANLkTinVZEW7WrkTRP-cjxrgk8xy=QLgNE2WX0BF+aoC@mail.gmail.com>
2011-03-21 13:26       ` Claudio Takahasi
     [not found]         ` <AFCDDB4A3EA003429EEF1E7B211FDBBA334C4DE29C@EXDCVYMBSTM005.EQ1STM.local>
2011-03-23 19:11           ` Claudio Takahasi

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).