****************************************************/
struct sACL_CB {
private:
- friend bool btm_pm_is_le_link(const RawAddress& remote_bda);
friend int btm_pm_find_acl_ind(const RawAddress& remote_bda);
friend tBTM_PM_MCB* acl_power_mode_from_handle(uint16_t hci_handle);
friend tBTM_STATUS BTM_SetPowerMode(uint8_t pm_id,
return xx;
}
-bool btm_pm_is_le_link(const RawAddress& remote_bda) {
- const tACL_CONN* p_acl = &btm_cb.acl_cb_.acl_db[0];
- for (uint8_t xx = 0; xx < MAX_L2CAP_LINKS; xx++, p_acl++) {
- if (p_acl->in_use && p_acl->remote_addr == remote_bda &&
- p_acl->is_transport_ble()) {
- return true;
- }
- }
- return false;
-}
-
/*******************************************************************************
*
* Function btm_ble_refresh_local_resolvable_private_addr
int acl_ind = btm_pm_find_acl_ind(remote_bda);
if (acl_ind == MAX_L2CAP_LINKS) {
- if (btm_pm_is_le_link(remote_bda)) {
- LOG_ERROR("Setting power mode on le link is unsupported");
- return BTM_MODE_UNSUPPORTED;
- }
LOG_ERROR("br_edr acl addr:%s is unknown", PRIVATE_ADDRESS(remote_bda));
return BTM_UNKNOWN_ADDR;
}
const RawAddress acl_address_from_handle(uint16_t hci_handle);
tBTM_PM_MCB* acl_power_mode_from_handle(uint16_t hci_handle);
int btm_pm_find_acl_ind(const RawAddress& remote_bda);
-bool btm_pm_is_le_link(const RawAddress& remote_bda);
void btm_ble_refresh_local_resolvable_private_addr(
const RawAddress& pseudo_addr, const RawAddress& local_rpa);