alistair23-linux/include/net/bluetooth
Johan Hedberg c16900cf28 Bluetooth: Fix hci_conn reference counting for fixed channels
Now that SMP has been converted to use fixed channels we've got a bit of
a problem with the hci_conn reference counting. So far the L2CAP code
has kept a reference for each L2CAP channel that was notified of the
connection. With SMP however this would mean that the connection is
never dropped even though there are no other users of it. Furthermore,
SMP already does its own hci_conn reference counting internally,
starting from a security or pairing request and ending with the key
distribution.

This patch makes L2CAP fixed channels default to the L2CAP core not
keeping a hci_conn reference for them. A new FLAG_HOLD_HCI_CONN flag is
added so that L2CAP users can declare an exception to this rule and hold
a reference even for their fixed channels. One such exception is the
L2CAP socket layer which does want a reference for each socket (e.g. an
ATT socket which uses a fixed channel).

Signed-off-by: Johan Hedberg <johan.hedberg@intel.com>
Signed-off-by: Marcel Holtmann <marcel@holtmann.org>
2014-09-08 19:07:52 +02:00
..
bluetooth.h Bluetooth: Shrink size of struct l2cap_ctrl fields 2014-07-03 17:42:41 +02:00
hci.h Bluetooth: Rename HCI_PAIRABLE to HCI_BONDABLE 2014-07-30 19:28:41 +02:00
hci_core.h Merge branch 'master' of git://git.kernel.org/pub/scm/linux/kernel/git/linville/wireless 2014-09-08 11:14:56 -04:00
hci_mon.h Bluetooth: Fix coding style in all .h files 2012-03-07 00:04:25 -03:00
hci_sock.h Bluetooth: Move HCI socket definitions into its own header file 2014-07-11 13:53:04 +03:00
l2cap.h Bluetooth: Fix hci_conn reference counting for fixed channels 2014-09-08 19:07:52 +02:00
mgmt.h Bluetooth: Rename pairable mgmt setting to bondable 2014-07-30 19:28:41 +02:00
rfcomm.h Bluetooth: Convert RFCOMM spinlocks into mutexes 2014-05-05 19:25:06 -07:00
sco.h Bluetooth: Move SCO timeout constants into net/bluetooth/sco.c 2014-07-11 13:58:58 +03:00