]> pilppa.org Git - linux-2.6-omap-h63xx.git/blobdiff - net/bluetooth/hci_conn.c
arm ide breakage
[linux-2.6-omap-h63xx.git] / net / bluetooth / hci_conn.c
index a2f9efaa336143e5c74cde4db0294941220c7c22..b7002429f1525311053f14171a1d94a25bf1ff04 100644 (file)
@@ -376,6 +376,19 @@ struct hci_conn *hci_connect(struct hci_dev *hdev, int type, bdaddr_t *dst, __u8
 }
 EXPORT_SYMBOL(hci_connect);
 
+/* Check link security requirement */
+int hci_conn_check_link_mode(struct hci_conn *conn)
+{
+       BT_DBG("conn %p", conn);
+
+       if (conn->ssp_mode > 0 && conn->hdev->ssp_mode > 0 &&
+                                       !(conn->link_mode & HCI_LM_ENCRYPT))
+               return 0;
+
+       return 1;
+}
+EXPORT_SYMBOL(hci_conn_check_link_mode);
+
 /* Authenticate remote device */
 int hci_conn_auth(struct hci_conn *conn)
 {