Fixes BLE HCI commands concurrency issue
Removes HCI LE Read Remote features command call
to prevent the concurrency between this command and
HCI LE start encryption command.
CRs-fixed: 517330
bug:11450568
Change-Id: I6445ab8095a4261c2a3f84acea1c546e6924f50d
Signed-off-by: Sunny Kapdi <sunnyk@codeaurora.org>
diff --git a/include/bt_target.h b/include/bt_target.h
index 5a22fb8..3ad4602 100644
--- a/include/bt_target.h
+++ b/include/bt_target.h
@@ -356,6 +356,11 @@
#define BTA_HOST_INTERLEAVE_SEARCH FALSE
#endif
+/* This feature is used to skip query of ble read remote features*/
+#ifndef BTA_SKIP_BLE_READ_REMOTE_FEAT
+#define BTA_SKIP_BLE_READ_REMOTE_FEAT FALSE
+#endif
+
#ifndef BT_TRACE_PROTOCOL
#define BT_TRACE_PROTOCOL TRUE
#endif
diff --git a/stack/btm/btm_acl.c b/stack/btm/btm_acl.c
index ea1c68e..ef552a6 100644
--- a/stack/btm/btm_acl.c
+++ b/stack/btm/btm_acl.c
@@ -251,10 +251,12 @@
{
btm_establish_continue(p);
+#if (!defined(BTA_SKIP_BLE_READ_REMOTE_FEAT) || BTA_SKIP_BLE_READ_REMOTE_FEAT == FALSE)
if (link_role == HCI_ROLE_MASTER)
{
btsnd_hcic_ble_read_remote_feat(p->hci_handle);
}
+#endif
}
else
#endif