aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAndre Guedes <andre.guedes@openbossa.org>2011-05-31 14:20:55 -0300
committerJaikumar Ganesh <jaikumar@google.com>2011-07-11 11:59:15 -0700
commit92398c8163acd942de0a7c7d2d7abcf5ca3d02af (patch)
tree3df585a9991d66852a9d7d9f385b914a281948af
parent149c097ce73e6f301c8d257828334506028be307 (diff)
downloadkernel_samsung_tuna-92398c8163acd942de0a7c7d2d7abcf5ca3d02af.zip
kernel_samsung_tuna-92398c8163acd942de0a7c7d2d7abcf5ca3d02af.tar.gz
kernel_samsung_tuna-92398c8163acd942de0a7c7d2d7abcf5ca3d02af.tar.bz2
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>
-rw-r--r--net/bluetooth/hci_conn.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/net/bluetooth/hci_conn.c b/net/bluetooth/hci_conn.c
index 803628d..0903eff 100644
--- a/net/bluetooth/hci_conn.c
+++ b/net/bluetooth/hci_conn.c
@@ -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);