Bluetooth: Don't forget to check for LE_LINK
authorGustavo F. Padovan <padovan@profusion.mobi>
Wed, 8 Jun 2011 22:09:13 +0000 (19:09 -0300)
committerJaikumar Ganesh <jaikumar@google.com>
Mon, 11 Jul 2011 18:59:20 +0000 (11:59 -0700)
Otherwise the wrong error can be returned.

Signed-off-by: Gustavo F. Padovan <padovan@profusion.mobi>
net/bluetooth/l2cap_core.c

index 22939eb3cd165d1a0087213899800faf27ba8a0c..2250217c6c5f0c54a4b3e30ab9262b355091b30e 100644 (file)
@@ -4128,7 +4128,7 @@ static int l2cap_disconn_ind(struct hci_conn *hcon)
 
        BT_DBG("hcon %p", hcon);
 
-       if (hcon->type != ACL_LINK || !conn)
+       if ((hcon->type != ACL_LINK && hcon->type != LE_LINK) || !conn)
                return 0x13;
 
        return conn->disc_reason;