Loading system/gd/hci/acl_manager/le_connection_callbacks.h +1 −1 Original line number Diff line number Diff line Loading @@ -32,7 +32,7 @@ class LeConnectionCallbacks { // Invoked when controller sends Connection Complete event with Success error code // AddressWithType is always equal to the object used in AclManager#CreateLeConnection virtual void OnLeConnectSuccess(AddressWithType, std::unique_ptr<LeAclConnection>) = 0; // Invoked when controller sends Connection Complete event with non-Success error code // Invoked when create connection timeout or controller sends Connection Complete event with non-Success error code virtual void OnLeConnectFail(AddressWithType, ErrorCode reason) = 0; }; Loading system/gd/hci/acl_manager/le_impl.h +5 −1 Original line number Diff line number Diff line Loading @@ -22,7 +22,6 @@ #include "hci/acl_manager/round_robin_scheduler.h" #include "hci/le_address_manager.h" #include "os/alarm.h" #include "os/rand.h" using bluetooth::crypto_toolbox::Octet16; Loading Loading @@ -549,6 +548,11 @@ struct le_impl : public bluetooth::hci::LeAddressManagerCallback { create_connection_timeout_alarms_.at(address_with_type).Cancel(); create_connection_timeout_alarms_.erase(address_with_type); cancel_connect(address_with_type); le_client_handler_->Post(common::BindOnce( &LeConnectionCallbacks::OnLeConnectFail, common::Unretained(le_client_callbacks_), address_with_type, ErrorCode::CONNECTION_ACCEPT_TIMEOUT)); } } Loading system/main/shim/acl.cc +1 −0 Original line number Diff line number Diff line Loading @@ -40,6 +40,7 @@ #include "gd/hci/acl_manager/connection_management_callbacks.h" #include "gd/hci/acl_manager/le_acl_connection.h" #include "gd/hci/acl_manager/le_connection_management_callbacks.h" #include "gd/hci/acl_manager/le_impl.h" #include "gd/hci/address.h" #include "gd/hci/class_of_device.h" #include "gd/hci/controller.h" Loading system/stack/acl/ble_acl.cc +2 −0 Original line number Diff line number Diff line Loading @@ -155,6 +155,8 @@ void acl_ble_connection_fail(const tBLE_BD_ADDR& address_with_type, btm_cb.ble_ctr_cb.set_connection_state_idle(); btm_ble_clear_topology_mask(BTM_BLE_STATE_INIT_BIT); btm_ble_disable_resolving_list(BTM_BLE_RL_INIT, true); connection_manager::on_connection_timed_out_from_shim( address_with_type.bda); } else { btm_cb.ble_ctr_cb.inq_var.adv_mode = BTM_BLE_ADV_DISABLE; btm_ble_disable_resolving_list(BTM_BLE_RL_ADV, true); Loading system/stack/gatt/connection_manager.cc +4 −0 Original line number Diff line number Diff line Loading @@ -200,6 +200,10 @@ void on_connection_complete(const RawAddress& address) { remove_all_clients_with_pending_connections(address); } void on_connection_timed_out_from_shim(const RawAddress& address) { on_connection_timed_out(0x00, address); } /** Reset bg device list. If called after controller reset, set |after_reset| to * true, as there is no need to wipe controller acceptlist in this case. */ void reset(bool after_reset) { Loading Loading
system/gd/hci/acl_manager/le_connection_callbacks.h +1 −1 Original line number Diff line number Diff line Loading @@ -32,7 +32,7 @@ class LeConnectionCallbacks { // Invoked when controller sends Connection Complete event with Success error code // AddressWithType is always equal to the object used in AclManager#CreateLeConnection virtual void OnLeConnectSuccess(AddressWithType, std::unique_ptr<LeAclConnection>) = 0; // Invoked when controller sends Connection Complete event with non-Success error code // Invoked when create connection timeout or controller sends Connection Complete event with non-Success error code virtual void OnLeConnectFail(AddressWithType, ErrorCode reason) = 0; }; Loading
system/gd/hci/acl_manager/le_impl.h +5 −1 Original line number Diff line number Diff line Loading @@ -22,7 +22,6 @@ #include "hci/acl_manager/round_robin_scheduler.h" #include "hci/le_address_manager.h" #include "os/alarm.h" #include "os/rand.h" using bluetooth::crypto_toolbox::Octet16; Loading Loading @@ -549,6 +548,11 @@ struct le_impl : public bluetooth::hci::LeAddressManagerCallback { create_connection_timeout_alarms_.at(address_with_type).Cancel(); create_connection_timeout_alarms_.erase(address_with_type); cancel_connect(address_with_type); le_client_handler_->Post(common::BindOnce( &LeConnectionCallbacks::OnLeConnectFail, common::Unretained(le_client_callbacks_), address_with_type, ErrorCode::CONNECTION_ACCEPT_TIMEOUT)); } } Loading
system/main/shim/acl.cc +1 −0 Original line number Diff line number Diff line Loading @@ -40,6 +40,7 @@ #include "gd/hci/acl_manager/connection_management_callbacks.h" #include "gd/hci/acl_manager/le_acl_connection.h" #include "gd/hci/acl_manager/le_connection_management_callbacks.h" #include "gd/hci/acl_manager/le_impl.h" #include "gd/hci/address.h" #include "gd/hci/class_of_device.h" #include "gd/hci/controller.h" Loading
system/stack/acl/ble_acl.cc +2 −0 Original line number Diff line number Diff line Loading @@ -155,6 +155,8 @@ void acl_ble_connection_fail(const tBLE_BD_ADDR& address_with_type, btm_cb.ble_ctr_cb.set_connection_state_idle(); btm_ble_clear_topology_mask(BTM_BLE_STATE_INIT_BIT); btm_ble_disable_resolving_list(BTM_BLE_RL_INIT, true); connection_manager::on_connection_timed_out_from_shim( address_with_type.bda); } else { btm_cb.ble_ctr_cb.inq_var.adv_mode = BTM_BLE_ADV_DISABLE; btm_ble_disable_resolving_list(BTM_BLE_RL_ADV, true); Loading
system/stack/gatt/connection_manager.cc +4 −0 Original line number Diff line number Diff line Loading @@ -200,6 +200,10 @@ void on_connection_complete(const RawAddress& address) { remove_all_clients_with_pending_connections(address); } void on_connection_timed_out_from_shim(const RawAddress& address) { on_connection_timed_out(0x00, address); } /** Reset bg device list. If called after controller reset, set |after_reset| to * true, as there is no need to wipe controller acceptlist in this case. */ void reset(bool after_reset) { Loading