diff options
author | John W. Linville <linville@tuxdriver.com> | 2012-06-11 14:32:24 -0400 |
---|---|---|
committer | John W. Linville <linville@tuxdriver.com> | 2012-06-11 14:32:24 -0400 |
commit | 3b4a39af75fed985f12d295786d397a9d8e9fd2f (patch) | |
tree | 982643f147601b2101eba169533b7736f996211b /net/bluetooth/l2cap_core.c | |
parent | b0fd49b7d7599dc87402df13ab6e571e2222601f (diff) | |
parent | 1c2e004183178e1947882cd2e74f37826f45230e (diff) |
Merge branch 'for-upstream' of git://git.kernel.org/pub/scm/linux/kernel/git/bluetooth/bluetooth
Diffstat (limited to 'net/bluetooth/l2cap_core.c')
-rw-r--r-- | net/bluetooth/l2cap_core.c | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/net/bluetooth/l2cap_core.c b/net/bluetooth/l2cap_core.c index 24f144b72a96..8394e3615ef6 100644 --- a/net/bluetooth/l2cap_core.c +++ b/net/bluetooth/l2cap_core.c @@ -1295,7 +1295,12 @@ static void security_timeout(struct work_struct *work) struct l2cap_conn *conn = container_of(work, struct l2cap_conn, security_timer.work); - l2cap_conn_del(conn->hcon, ETIMEDOUT); + BT_DBG("conn %p", conn); + + if (test_and_clear_bit(HCI_CONN_LE_SMP_PEND, &conn->hcon->flags)) { + smp_chan_destroy(conn); + l2cap_conn_del(conn->hcon, ETIMEDOUT); + } } static struct l2cap_conn *l2cap_conn_add(struct hci_conn *hcon, u8 status) |