mirror of
https://github.com/espressif/esp-idf.git
synced 2026-10-02 11:10:54 +03:00
fix(ble/bluedroid): preserve HCI status on BLE 4.2 GAP failures
Return BTM_HCI_ERROR | hci_status from legacy BLE 4.2 GAP HCI command
paths instead of mapping failures to BTM_ILLEGAL_VALUE or
BTM_NO_RESOURCES. Add btm_ble_status_from_hci() helper and propagate
real status through scan start/stop completion callbacks.
(cherry picked from commit 47dd785a18)
Co-authored-by: zhanghaipeng <zhanghaipeng@espressif.com>
This commit is contained in:
@@ -5402,10 +5402,11 @@ void bta_dm_ble_scan (tBTA_DM_MSG *p_data)
|
|||||||
if ((status = BTM_BleScan(TRUE, p_data->ble_scan.duration,
|
if ((status = BTM_BleScan(TRUE, p_data->ble_scan.duration,
|
||||||
bta_dm_scan_results_cb, bta_dm_scan_cmpl_cb, bta_dm_scan_discard_cb)) != BTM_CMD_STARTED) {
|
bta_dm_scan_results_cb, bta_dm_scan_cmpl_cb, bta_dm_scan_discard_cb)) != BTM_CMD_STARTED) {
|
||||||
APPL_TRACE_WARNING(" %s start scan failed. status=0x%x\n", __FUNCTION__, status);
|
APPL_TRACE_WARNING(" %s start scan failed. status=0x%x\n", __FUNCTION__, status);
|
||||||
|
} else {
|
||||||
|
status = BTM_SUCCESS;
|
||||||
}
|
}
|
||||||
|
|
||||||
memset(&cb_params, 0, sizeof(cb_params));
|
memset(&cb_params, 0, sizeof(cb_params));
|
||||||
status = (status == BTM_CMD_STARTED ? BTA_SUCCESS : BTA_FAILURE);
|
|
||||||
cb_params.status = status;
|
cb_params.status = status;
|
||||||
BTM_LegacyBleCallbackTrigger(BTM_BLE_LEGACY_GAP_SCAN_START_COMPLETE_EVT, &cb_params);
|
BTM_LegacyBleCallbackTrigger(BTM_BLE_LEGACY_GAP_SCAN_START_COMPLETE_EVT, &cb_params);
|
||||||
|
|
||||||
@@ -5415,10 +5416,11 @@ void bta_dm_ble_scan (tBTA_DM_MSG *p_data)
|
|||||||
|
|
||||||
if (status != BTM_CMD_STARTED){
|
if (status != BTM_CMD_STARTED){
|
||||||
APPL_TRACE_WARNING(" %s stop scan failed, status=0x%x\n", __FUNCTION__, status);
|
APPL_TRACE_WARNING(" %s stop scan failed, status=0x%x\n", __FUNCTION__, status);
|
||||||
|
} else {
|
||||||
|
status = BTM_SUCCESS;
|
||||||
}
|
}
|
||||||
|
|
||||||
memset(&cb_params, 0, sizeof(cb_params));
|
memset(&cb_params, 0, sizeof(cb_params));
|
||||||
status = (status == BTM_CMD_STARTED ? BTA_SUCCESS : BTA_FAILURE);
|
|
||||||
cb_params.status = status;
|
cb_params.status = status;
|
||||||
BTM_LegacyBleCallbackTrigger(BTM_BLE_LEGACY_GAP_SCAN_STOP_COMPLETE_EVT, &cb_params);
|
BTM_LegacyBleCallbackTrigger(BTM_BLE_LEGACY_GAP_SCAN_STOP_COMPLETE_EVT, &cb_params);
|
||||||
#if (BLE_TOPOLOGY_CHECK == TRUE)
|
#if (BLE_TOPOLOGY_CHECK == TRUE)
|
||||||
|
|||||||
@@ -2387,7 +2387,7 @@ void btm_read_channel_map_complete(UINT8 *p)
|
|||||||
memcpy(results.rem_bda, p_acl_cb->remote_addr, BD_ADDR_LEN);
|
memcpy(results.rem_bda, p_acl_cb->remote_addr, BD_ADDR_LEN);
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
results.status = BTM_ERR_PROCESSING;
|
results.status = BTM_HCI_ERROR | results.hci_status;
|
||||||
BTM_TRACE_ERROR("BTM Channel Map Read Failed: hci status 0x%02x", results.hci_status);
|
BTM_TRACE_ERROR("BTM Channel Map Read Failed: hci status 0x%02x", results.hci_status);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -1117,15 +1117,17 @@ tBTM_STATUS BTM_BleStartAdvWithParams(UINT16 adv_int_min, UINT16 adv_int_max, UI
|
|||||||
|
|
||||||
tBTM_STATUS status = BTM_SUCCESS;
|
tBTM_STATUS status = BTM_SUCCESS;
|
||||||
/* update adv params */
|
/* update adv params */
|
||||||
if (btsnd_hcic_ble_write_adv_params (adv_int_min,
|
UINT8 hci_status = btsnd_hcic_ble_write_adv_params (adv_int_min,
|
||||||
adv_int_max,
|
adv_int_max,
|
||||||
adv_type,
|
adv_type,
|
||||||
own_bda_type,
|
own_bda_type,
|
||||||
p_dir_bda->type,
|
p_dir_bda->type,
|
||||||
p_dir_bda->bda,
|
p_dir_bda->bda,
|
||||||
chnl_map,
|
chnl_map,
|
||||||
p_cb->afp) != HCI_SUCCESS) {
|
p_cb->afp);
|
||||||
status = BTM_NO_RESOURCES;
|
if (hci_status != HCI_SUCCESS) {
|
||||||
|
BTM_BLE_TRACE_HCI_CMD_FAIL(__func__, hci_status);
|
||||||
|
status = btm_ble_status_from_hci(hci_status);
|
||||||
}
|
}
|
||||||
|
|
||||||
osi_mutex_unlock(&btm_lock);
|
osi_mutex_unlock(&btm_lock);
|
||||||
@@ -1175,13 +1177,13 @@ tBTM_STATUS BTM_BleSetScanFilterParams(tGATT_IF client_if, UINT32 scan_interval,
|
|||||||
(scan_mode == BTM_BLE_SCAN_MODE_ACTI || scan_mode == BTM_BLE_SCAN_MODE_PASS) &&
|
(scan_mode == BTM_BLE_SCAN_MODE_ACTI || scan_mode == BTM_BLE_SCAN_MODE_PASS) &&
|
||||||
(scan_duplicate_filter < BTM_BLE_SCAN_DUPLICATE_MAX) && (scan_window <= scan_interval)) {
|
(scan_duplicate_filter < BTM_BLE_SCAN_DUPLICATE_MAX) && (scan_window <= scan_interval)) {
|
||||||
|
|
||||||
if ((btsnd_hcic_ble_set_scan_params(scan_mode, (UINT16)scan_interval,
|
UINT8 hci_status = btsnd_hcic_ble_set_scan_params(scan_mode, (UINT16)scan_interval,
|
||||||
(UINT16)scan_window,
|
(UINT16)scan_window,
|
||||||
addr_type_own,
|
addr_type_own,
|
||||||
scan_filter_policy)) != HCI_SUCCESS) {
|
scan_filter_policy);
|
||||||
ret = BTM_ILLEGAL_VALUE;
|
if (hci_status != HCI_SUCCESS) {
|
||||||
BTM_TRACE_ERROR("Illegal params: scan_interval = %d scan_window = %d\n",
|
BTM_BLE_TRACE_HCI_CMD_FAIL(__func__, hci_status);
|
||||||
scan_interval, scan_window);
|
ret = btm_ble_status_from_hci(hci_status);
|
||||||
} else {
|
} else {
|
||||||
p_cb->scan_type = scan_mode;
|
p_cb->scan_type = scan_mode;
|
||||||
p_cb->scan_interval = scan_interval;
|
p_cb->scan_interval = scan_interval;
|
||||||
@@ -1232,8 +1234,10 @@ tBTM_STATUS BTM_BleWriteScanRsp(tBTM_BLE_AD_MASK data_mask, tBTM_BLE_ADV_DATA *p
|
|||||||
BTM_TRACE_WARNING("%s, Partial data write into ADV", __func__);
|
BTM_TRACE_WARNING("%s, Partial data write into ADV", __func__);
|
||||||
}
|
}
|
||||||
|
|
||||||
if (btsnd_hcic_ble_set_scan_rsp_data((UINT8)(p - rsp_data), rsp_data) != HCI_SUCCESS) {
|
UINT8 hci_status = btsnd_hcic_ble_set_scan_rsp_data((UINT8)(p - rsp_data), rsp_data);
|
||||||
ret = BTM_ILLEGAL_VALUE;
|
if (hci_status != HCI_SUCCESS) {
|
||||||
|
BTM_BLE_TRACE_HCI_CMD_FAIL(__func__, hci_status);
|
||||||
|
ret = btm_ble_status_from_hci(hci_status);
|
||||||
btm_cb.ble_ctr_cb.inq_var.scan_rsp = FALSE;
|
btm_cb.ble_ctr_cb.inq_var.scan_rsp = FALSE;
|
||||||
} else {
|
} else {
|
||||||
ret = BTM_SUCCESS;
|
ret = BTM_SUCCESS;
|
||||||
@@ -1265,8 +1269,10 @@ tBTM_STATUS BTM_BleWriteScanRspRaw(UINT8 *p_raw_scan_rsp, UINT32 raw_scan_rsp_le
|
|||||||
tBTM_STATUS ret = BTM_SUCCESS;
|
tBTM_STATUS ret = BTM_SUCCESS;
|
||||||
|
|
||||||
osi_mutex_lock(&btm_lock, OSI_MUTEX_MAX_TIMEOUT);
|
osi_mutex_lock(&btm_lock, OSI_MUTEX_MAX_TIMEOUT);
|
||||||
if (btsnd_hcic_ble_set_scan_rsp_data((UINT8)raw_scan_rsp_len, p_raw_scan_rsp) != HCI_SUCCESS) {
|
UINT8 hci_status = btsnd_hcic_ble_set_scan_rsp_data((UINT8)raw_scan_rsp_len, p_raw_scan_rsp);
|
||||||
ret = BTM_NO_RESOURCES;
|
if (hci_status != HCI_SUCCESS) {
|
||||||
|
BTM_BLE_TRACE_HCI_CMD_FAIL(__func__, hci_status);
|
||||||
|
ret = btm_ble_status_from_hci(hci_status);
|
||||||
}
|
}
|
||||||
osi_mutex_unlock(&btm_lock);
|
osi_mutex_unlock(&btm_lock);
|
||||||
|
|
||||||
@@ -1377,9 +1383,11 @@ tBTM_STATUS BTM_BleWriteAdvData(tBTM_BLE_AD_MASK data_mask, tBTM_BLE_ADV_DATA *p
|
|||||||
|
|
||||||
p_cb_data->data_mask &= ~mask;
|
p_cb_data->data_mask &= ~mask;
|
||||||
|
|
||||||
if ((btsnd_hcic_ble_set_adv_data((UINT8)(p_cb_data->p_pad - p_cb_data->ad_data),
|
UINT8 hci_status = btsnd_hcic_ble_set_adv_data((UINT8)(p_cb_data->p_pad - p_cb_data->ad_data),
|
||||||
p_cb_data->ad_data)) != HCI_SUCCESS) {
|
p_cb_data->ad_data);
|
||||||
ret = BTM_NO_RESOURCES;
|
if (hci_status != HCI_SUCCESS) {
|
||||||
|
BTM_BLE_TRACE_HCI_CMD_FAIL(__func__, hci_status);
|
||||||
|
ret = btm_ble_status_from_hci(hci_status);
|
||||||
}
|
}
|
||||||
osi_mutex_unlock(&btm_lock);
|
osi_mutex_unlock(&btm_lock);
|
||||||
return ret;
|
return ret;
|
||||||
@@ -1400,8 +1408,10 @@ tBTM_STATUS BTM_BleWriteAdvDataRaw(UINT8 *p_raw_adv, UINT32 raw_adv_len)
|
|||||||
{
|
{
|
||||||
tBTM_STATUS ret = BTM_SUCCESS;
|
tBTM_STATUS ret = BTM_SUCCESS;
|
||||||
osi_mutex_lock(&btm_lock, OSI_MUTEX_MAX_TIMEOUT);
|
osi_mutex_lock(&btm_lock, OSI_MUTEX_MAX_TIMEOUT);
|
||||||
if ((btsnd_hcic_ble_set_adv_data((UINT8)raw_adv_len, p_raw_adv)) != HCI_SUCCESS) {
|
UINT8 hci_status = btsnd_hcic_ble_set_adv_data((UINT8)raw_adv_len, p_raw_adv);
|
||||||
ret = BTM_NO_RESOURCES;
|
if (hci_status != HCI_SUCCESS) {
|
||||||
|
BTM_BLE_TRACE_HCI_CMD_FAIL(__func__, hci_status);
|
||||||
|
ret = btm_ble_status_from_hci(hci_status);
|
||||||
}
|
}
|
||||||
osi_mutex_unlock(&btm_lock);
|
osi_mutex_unlock(&btm_lock);
|
||||||
|
|
||||||
@@ -2065,15 +2075,17 @@ tBTM_STATUS btm_ble_set_discoverability(UINT16 combined_mode)
|
|||||||
#endif // #if (BLE_42_ADV_EN == TRUE)
|
#endif // #if (BLE_42_ADV_EN == TRUE)
|
||||||
|
|
||||||
/* update adv params */
|
/* update adv params */
|
||||||
if (btsnd_hcic_ble_write_adv_params (adv_int_min,
|
UINT8 hci_status = btsnd_hcic_ble_write_adv_params (adv_int_min,
|
||||||
adv_int_max,
|
adv_int_max,
|
||||||
evt_type,
|
evt_type,
|
||||||
own_addr_type,
|
own_addr_type,
|
||||||
init_addr_type,
|
init_addr_type,
|
||||||
p_addr_ptr,
|
p_addr_ptr,
|
||||||
p_cb->adv_chnl_map,
|
p_cb->adv_chnl_map,
|
||||||
p_cb->afp) != HCI_SUCCESS) {
|
p_cb->afp);
|
||||||
status = BTM_NO_RESOURCES;
|
if (hci_status != HCI_SUCCESS) {
|
||||||
|
BTM_BLE_TRACE_HCI_CMD_FAIL(__func__, hci_status);
|
||||||
|
status = btm_ble_status_from_hci(hci_status);
|
||||||
} else {
|
} else {
|
||||||
p_cb->evt_type = evt_type;
|
p_cb->evt_type = evt_type;
|
||||||
p_cb->adv_addr_type = own_addr_type;
|
p_cb->adv_addr_type = own_addr_type;
|
||||||
@@ -2163,15 +2175,17 @@ tBTM_STATUS btm_ble_set_connectability(UINT16 combined_mode)
|
|||||||
btm_ble_stop_adv();
|
btm_ble_stop_adv();
|
||||||
#endif // #if (BLE_42_ADV_EN == TRUE)
|
#endif // #if (BLE_42_ADV_EN == TRUE)
|
||||||
|
|
||||||
if (btsnd_hcic_ble_write_adv_params (adv_int_min,
|
UINT8 hci_status = btsnd_hcic_ble_write_adv_params (adv_int_min,
|
||||||
adv_int_max,
|
adv_int_max,
|
||||||
evt_type,
|
evt_type,
|
||||||
own_addr_type,
|
own_addr_type,
|
||||||
peer_addr_type,
|
peer_addr_type,
|
||||||
p_addr_ptr,
|
p_addr_ptr,
|
||||||
p_cb->adv_chnl_map,
|
p_cb->adv_chnl_map,
|
||||||
p_cb->afp) != HCI_SUCCESS) {
|
p_cb->afp);
|
||||||
status = BTM_NO_RESOURCES;
|
if (hci_status != HCI_SUCCESS) {
|
||||||
|
BTM_BLE_TRACE_HCI_CMD_FAIL(__func__, hci_status);
|
||||||
|
status = btm_ble_status_from_hci(hci_status);
|
||||||
} else {
|
} else {
|
||||||
p_cb->evt_type = evt_type;
|
p_cb->evt_type = evt_type;
|
||||||
p_cb->adv_addr_type = own_addr_type;
|
p_cb->adv_addr_type = own_addr_type;
|
||||||
@@ -3241,8 +3255,10 @@ tBTM_STATUS btm_ble_start_scan(void)
|
|||||||
p_inq->scan_duplicate_filter = BTM_BLE_DUPLICATE_DISABLE;
|
p_inq->scan_duplicate_filter = BTM_BLE_DUPLICATE_DISABLE;
|
||||||
}
|
}
|
||||||
/* start scan, disable duplicate filtering */
|
/* start scan, disable duplicate filtering */
|
||||||
if ((btsnd_hcic_ble_set_scan_enable (BTM_BLE_SCAN_ENABLE, p_inq->scan_duplicate_filter)) != HCI_SUCCESS) {
|
UINT8 hci_status = btsnd_hcic_ble_set_scan_enable (BTM_BLE_SCAN_ENABLE, p_inq->scan_duplicate_filter);
|
||||||
status = BTM_NO_RESOURCES;
|
if (hci_status != HCI_SUCCESS) {
|
||||||
|
BTM_BLE_TRACE_HCI_CMD_FAIL(__func__, hci_status);
|
||||||
|
status = btm_ble_status_from_hci(hci_status);
|
||||||
} else {
|
} else {
|
||||||
btm_cb.ble_ctr_cb.inq_var.state |= BTM_BLE_SCANNING;
|
btm_cb.ble_ctr_cb.inq_var.state |= BTM_BLE_SCANNING;
|
||||||
#if (BLE_TOPOLOGY_CHECK == TRUE)
|
#if (BLE_TOPOLOGY_CHECK == TRUE)
|
||||||
@@ -3312,8 +3328,10 @@ static tBTM_STATUS btm_ble_stop_discover(void)
|
|||||||
/* Clear the inquiry callback if set */
|
/* Clear the inquiry callback if set */
|
||||||
btm_cb.ble_ctr_cb.inq_var.state &= ~BTM_BLE_SCANNING;
|
btm_cb.ble_ctr_cb.inq_var.state &= ~BTM_BLE_SCANNING;
|
||||||
/* stop discovery now */
|
/* stop discovery now */
|
||||||
if (btsnd_hcic_ble_set_scan_enable (BTM_BLE_SCAN_DISABLE, BTM_BLE_DUPLICATE_ENABLE) != HCI_SUCCESS) {
|
UINT8 hci_status = btsnd_hcic_ble_set_scan_enable (BTM_BLE_SCAN_DISABLE, BTM_BLE_DUPLICATE_ENABLE);
|
||||||
status = BTM_NO_RESOURCES;
|
if (hci_status != HCI_SUCCESS) {
|
||||||
|
BTM_BLE_TRACE_HCI_CMD_FAIL(__func__, hci_status);
|
||||||
|
status = btm_ble_status_from_hci(hci_status);
|
||||||
}
|
}
|
||||||
#if (BLE_TOPOLOGY_CHECK == TRUE)
|
#if (BLE_TOPOLOGY_CHECK == TRUE)
|
||||||
/* reset status */
|
/* reset status */
|
||||||
@@ -3428,8 +3446,10 @@ tBTM_STATUS btm_ble_start_adv(void)
|
|||||||
#if (BLE_TOPOLOGY_CHECK == TRUE)
|
#if (BLE_TOPOLOGY_CHECK == TRUE)
|
||||||
btm_ble_adv_states_operation(btm_ble_set_topology_mask, p_cb->evt_type);
|
btm_ble_adv_states_operation(btm_ble_set_topology_mask, p_cb->evt_type);
|
||||||
#endif // (BLE_TOPOLOGY_CHECK == TRUE)
|
#endif // (BLE_TOPOLOGY_CHECK == TRUE)
|
||||||
if (btsnd_hcic_ble_set_adv_enable (BTM_BLE_ADV_ENABLE) != HCI_SUCCESS) {
|
UINT8 hci_status = btsnd_hcic_ble_set_adv_enable (BTM_BLE_ADV_ENABLE);
|
||||||
rt = BTM_NO_RESOURCES;
|
if (hci_status != HCI_SUCCESS) {
|
||||||
|
BTM_BLE_TRACE_HCI_CMD_FAIL(__func__, hci_status);
|
||||||
|
rt = btm_ble_status_from_hci(hci_status);
|
||||||
p_cb->state = temp_state;
|
p_cb->state = temp_state;
|
||||||
p_cb->adv_mode = adv_mode;
|
p_cb->adv_mode = adv_mode;
|
||||||
#if (BLE_TOPOLOGY_CHECK == TRUE)
|
#if (BLE_TOPOLOGY_CHECK == TRUE)
|
||||||
@@ -3472,7 +3492,8 @@ tBTM_STATUS btm_ble_stop_adv(void)
|
|||||||
/* clear all adv states */
|
/* clear all adv states */
|
||||||
btm_ble_clear_topology_mask (BTM_BLE_STATE_ALL_ADV_MASK);
|
btm_ble_clear_topology_mask (BTM_BLE_STATE_ALL_ADV_MASK);
|
||||||
#endif // (BLE_TOPOLOGY_CHECK == TRUE)
|
#endif // (BLE_TOPOLOGY_CHECK == TRUE)
|
||||||
if (btsnd_hcic_ble_set_adv_enable (BTM_BLE_ADV_DISABLE) != HCI_SUCCESS) {
|
UINT8 hci_status = btsnd_hcic_ble_set_adv_enable (BTM_BLE_ADV_DISABLE);
|
||||||
|
if (hci_status != HCI_SUCCESS) {
|
||||||
// reset state
|
// reset state
|
||||||
p_cb->fast_adv_on = temp_fast_adv_on;
|
p_cb->fast_adv_on = temp_fast_adv_on;
|
||||||
p_cb->adv_mode = temp_adv_mode;
|
p_cb->adv_mode = temp_adv_mode;
|
||||||
@@ -3481,7 +3502,8 @@ tBTM_STATUS btm_ble_stop_adv(void)
|
|||||||
#if (BLE_TOPOLOGY_CHECK == TRUE)
|
#if (BLE_TOPOLOGY_CHECK == TRUE)
|
||||||
btm_ble_set_topology_mask (temp_mask);
|
btm_ble_set_topology_mask (temp_mask);
|
||||||
#endif // (BLE_TOPOLOGY_CHECK == TRUE)
|
#endif // (BLE_TOPOLOGY_CHECK == TRUE)
|
||||||
rt = BTM_NO_RESOURCES;
|
BTM_BLE_TRACE_HCI_CMD_FAIL(__func__, hci_status);
|
||||||
|
rt = btm_ble_status_from_hci(hci_status);
|
||||||
}
|
}
|
||||||
if(rt != HCI_SUCCESS) {
|
if(rt != HCI_SUCCESS) {
|
||||||
p_cb->adv_mode = temp_adv_mode;
|
p_cb->adv_mode = temp_adv_mode;
|
||||||
|
|||||||
@@ -1327,12 +1327,8 @@ void btm_ble_set_channels_complete (UINT8 *p)
|
|||||||
case HCI_SUCCESS:
|
case HCI_SUCCESS:
|
||||||
cb_params.set_channels.status = BTM_SUCCESS;
|
cb_params.set_channels.status = BTM_SUCCESS;
|
||||||
break;
|
break;
|
||||||
case HCI_ERR_UNSUPPORTED_VALUE:
|
|
||||||
case HCI_ERR_ILLEGAL_PARAMETER_FMT:
|
|
||||||
cb_params.set_channels.status = BTM_ILLEGAL_VALUE;
|
|
||||||
break;
|
|
||||||
default:
|
default:
|
||||||
cb_params.set_channels.status = BTM_ERR_PROCESSING;
|
cb_params.set_channels.status = BTM_HCI_ERROR | cb_params.set_channels.hci_status;
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
BTM_LegacyBleCallbackTrigger(BTM_BLE_LEGACY_GAP_SET_CHANNELS_COMPLETE_EVT, &cb_params);
|
BTM_LegacyBleCallbackTrigger(BTM_BLE_LEGACY_GAP_SET_CHANNELS_COMPLETE_EVT, &cb_params);
|
||||||
|
|||||||
@@ -607,6 +607,14 @@ void btm_ble_cs_subevt_result_evt(tBTM_BLE_CS_SUBEVT_RESULT_CMPL_EVT *subevt_res
|
|||||||
void btm_ble_cs_subevt_continue_result_evt(tBTM_BLE_CS_SUBEVT_RESULT_CONTINUE_EVT *subevt_continue_result);
|
void btm_ble_cs_subevt_continue_result_evt(tBTM_BLE_CS_SUBEVT_RESULT_CONTINUE_EVT *subevt_continue_result);
|
||||||
#endif // (BT_BLE_FEAT_CHANNEL_SOUNDING == TRUE)
|
#endif // (BT_BLE_FEAT_CHANNEL_SOUNDING == TRUE)
|
||||||
|
|
||||||
|
static inline tBTM_STATUS btm_ble_status_from_hci(UINT8 hci_status)
|
||||||
|
{
|
||||||
|
return (hci_status == HCI_SUCCESS) ? BTM_SUCCESS : (tBTM_STATUS)(BTM_HCI_ERROR | hci_status);
|
||||||
|
}
|
||||||
|
|
||||||
|
#define BTM_BLE_TRACE_HCI_CMD_FAIL(func, hci_status) \
|
||||||
|
BTM_TRACE_ERROR("%s, fail to send the hci command, the error code = 0x%x", (func), (hci_status))
|
||||||
|
|
||||||
|
|
||||||
/*
|
/*
|
||||||
#ifdef __cplusplus
|
#ifdef __cplusplus
|
||||||
|
|||||||
Reference in New Issue
Block a user