alistair23-linux/net/bluetooth
Marcel Holtmann 052b30b0a8 Bluetooth: Add different pairing timeout for Legacy Pairing
The Bluetooth stack uses a reference counting for all established ACL
links and if no user (L2CAP connection) is present, the link will be
terminated to save power. The problem part is the dedicated pairing
when using Legacy Pairing (Bluetooth 2.0 and before). At that point
no user is present and pairing attempts will be disconnected within
10 seconds or less. In previous kernel version this was not a problem
since the disconnect timeout wasn't triggered on incoming connections
for the first time. However this caused issues with broken host stacks
that kept the connections around after dedicated pairing. When the
support for Simple Pairing got added, the link establishment procedure
needed to be changed and now causes issues when using Legacy Pairing

When using Simple Pairing it is possible to do a proper reference
counting of ACL link users. With Legacy Pairing this is not possible
since the specification is unclear in some areas and too many broken
Bluetooth devices have already been deployed. So instead of trying to
deal with all the broken devices, a special pairing timeout will be
introduced that increases the timeout to 60 seconds when pairing is
triggered.

If a broken devices now puts the stack into an unforeseen state, the
worst that happens is the disconnect timeout triggers after 120 seconds
instead of 4 seconds. This allows successful pairings with legacy and
broken devices now.

Based on a report by Johan Hedberg <johan.hedberg@nokia.com>

Signed-off-by: Marcel Holtmann <marcel@holtmann.org>
2009-04-28 09:31:38 -07:00
..
bnep bluetooth: driver API update 2009-01-07 17:23:17 -08:00
cmtp Bluetooth: Remove some pointless conditionals before kfree_skb() 2009-02-27 06:14:49 +01:00
hidp Bluetooth: Enable per-module dynamic debug messages 2008-11-30 12:17:28 +01:00
rfcomm Bluetooth: Fix removing of RFCOMM DLC timer with DEFER_SETUP 2009-04-19 18:56:45 +02:00
af_bluetooth.c Bluetooth: Fix poll() misbehavior when using BT_DEFER_SETUP 2009-02-27 06:14:46 +01:00
hci_conn.c Bluetooth: Add different pairing timeout for Legacy Pairing 2009-04-28 09:31:38 -07:00
hci_core.c Bluetooth: Remove some pointless conditionals before kfree_skb() 2009-02-27 06:14:49 +01:00
hci_event.c Bluetooth: Add different pairing timeout for Legacy Pairing 2009-04-28 09:31:38 -07:00
hci_sock.c Bluetooth: Enable per-module dynamic debug messages 2008-11-30 12:17:28 +01:00
hci_sysfs.c Bluetooth: Ensure that HCI sysfs add/del is preempt safe 2009-04-28 09:31:38 -07:00
Kconfig
l2cap.c Bluetooth: Remove some pointless conditionals before kfree_skb() 2009-02-27 06:14:49 +01:00
lib.c
Makefile
sco.c Bluetooth: Ask upper layers for HCI disconnect reason 2009-02-27 06:14:43 +01:00