fix on data len change cmd malfunction
@@ -4301,10 +4301,11 @@ void btm_ble_read_remote_features_complete(UINT8 *p)
btsnd_hcic_rmt_ver_req (p_acl_cb->hci_handle);
}
else{
- if (p_acl_cb->transport == BT_TRANSPORT_LE) {
- if (HCI_LE_DATA_LEN_EXT_SUPPORTED(p_acl_cb->peer_le_features)) {
uint16_t data_length = controller_get_interface()->get_ble_default_data_packet_length();
uint16_t data_txtime = controller_get_interface()->get_ble_default_data_packet_txtime();
+ if (p_acl_cb->transport == BT_TRANSPORT_LE) {
+ if (HCI_LE_DATA_LEN_EXT_SUPPORTED(p_acl_cb->peer_le_features) &&
+ (p_acl_cb->data_length_params.tx_len != data_length)) {
p_acl_cb->data_len_updating = true;
btsnd_hcic_ble_set_data_length(p_acl_cb->hci_handle, data_length, data_txtime);
}
