Bluetooth: Remove useless check in hci_connect()

There is no need to check the connection's state since hci_conn_add()
has just created a new connection and its state has been set properly.

Signed-off-by: Andre Guedes <andre.guedes@openbossa.org>
Acked-by: Ville Tervo <ville.tervo@nokia.com>
Signed-off-by: Gustavo F. Padovan <padovan@profusion.mobi>
This commit is contained in:
Andre Guedes
2011-05-31 14:20:55 -03:00
committed by Jaikumar Ganesh
parent 149c097ce7
commit 92398c8163

View File

@@ -464,8 +464,8 @@ struct hci_conn *hci_connect(struct hci_dev *hdev, int type,
le = hci_conn_add(hdev, LE_LINK, 0, dst);
if (!le)
return ERR_PTR(-ENOMEM);
if (le->state == BT_OPEN)
hci_le_connect(le);
hci_le_connect(le);
hci_conn_hold(le);