linux/include/net/bluetooth
Andre Guedes a4790dbd43 Bluetooth: Introduce LE auto connection infrastructure
This patch introduces the LE auto connection infrastructure which
will be used to implement the LE auto connection options.

In summary, the auto connection mechanism works as follows: Once the
first pending LE connection is created, the background scanning is
started. When the target device is found in range, the kernel
autonomously starts the connection attempt. If connection is
established successfully, that pending LE connection is deleted and
the background is stopped.

To achieve that, this patch introduces the hci_update_background_scan()
which controls the background scanning state. This function starts or
stops the background scanning based on the hdev->pend_le_conns list. If
there is no pending LE connection, the background scanning is stopped.
Otherwise, we start the background scanning.

Then, every time a pending LE connection is added we call hci_update_
background_scan() so the background scanning is started (in case it is
not already running). Likewise, every time a pending LE connection is
deleted we call hci_update_background_scan() so the background scanning
is stopped (in case this was the last pending LE connection) or it is
started again (in case we have more pending LE connections). Finally,
we also call hci_update_background_scan() in hci_le_conn_failed() so
the background scan is restarted in case the connection establishment
fails. This way the background scanning keeps running until all pending
LE connection are established.

At this point, resolvable addresses are not support by this
infrastructure. The proper support is added in upcoming patches.

Signed-off-by: Andre Guedes <andre.guedes@openbossa.org>
Signed-off-by: Marcel Holtmann <marcel@holtmann.org>
2014-02-26 19:41:34 -08:00
..
bluetooth.h Bluetooth: Introduce requirements for security level 4 2014-02-13 09:51:35 +02:00
hci_core.h Bluetooth: Introduce LE auto connection infrastructure 2014-02-26 19:41:34 -08:00
hci_mon.h Bluetooth: Fix coding style in all .h files 2012-03-07 00:04:25 -03:00
hci.h Bluetooth: Stop scanning on LE connection 2014-02-26 19:41:33 -08:00
l2cap.h Bluetooth: Fix updating Identity Address in L2CAP channels 2014-02-18 11:48:55 -08:00
mgmt.h Bluetooth: Add mgmt defines for privacy 2014-02-22 09:59:24 -08:00
rfcomm.h Bluetooth: Don't fail RFCOMM tty writes 2014-02-14 13:39:32 -08:00
sco.h Bluetooth: Store SCO address information in its own socket structure 2013-10-13 21:11:20 +03:00