Bluetooth: Fix l2cap conn failures for ssp devices
authorPeter Hurley <peter@xxxxxxxxxxxxxxxxxx>
Tue, 9 Aug 2011 20:26:55 +0000 (16:26 -0400)
committermgross <mark.gross@intel.com>
Wed, 9 Nov 2011 20:23:20 +0000 (12:23 -0800)
commit427b17ee285d9e55db7e639c377340ce6eae3c93
treeeb888c1ae6988ea5ce781bbd694e6bcb131c266f
parentb4e2c90ab317db29e27d34b34203d5d6c9e99d0f
Bluetooth: Fix l2cap conn failures for ssp devices

Commit 330605423c fixed l2cap conn establishment for non-ssp remote
devices by not setting HCI_CONN_ENCRYPT_PEND every time conn security
is tested (which was always returning failure on any subsequent
security checks).

However, this broke l2cap conn establishment for ssp remote devices
when an ACL link was already established at SDP-level security. This
fix ensures that encryption must be pending whenever authentication
is also pending.

Change-Id: I6876ea5134e90d1f3d0f84e8ed40b92977b3df64
Signed-off-by: Peter Hurley <peter@xxxxxxxxxxxxxxxxxx>
net/bluetooth/hci_conn.c