signal future where it would have been called,
and move contents into stack manager
Bug:
159815595
Tag: #refactor
Test: compile & verify basic functions working
Change-Id: I30f310f6e0481fd653b66598f99e72e47b4d51e3
* BTIF_Events
*/
void btif_enable_bluetooth_evt();
-void btif_disable_bluetooth_evt(void);
void btif_adapter_properties_evt(bt_status_t status, uint32_t num_props,
bt_property_t* p_props);
void btif_remote_properties_evt(bt_status_t status, RawAddress* remote_addr,
/*******************************************************************************
*
- * Function btif_disable_bluetooth_evt
- *
- * Description Event notifying BT disable is now complete.
- * Terminates main stack tasks and notifies HAL
- * user with updated BT state.
- *
- * Returns void
- *
- ******************************************************************************/
-
-void btif_disable_bluetooth_evt() {
- LOG_INFO("%s entered", __func__);
-
- bte_main_disable();
-
- /* callback to HAL */
- future_ready(stack_manager_get_hack_future(), FUTURE_SUCCESS);
-
- LOG_INFO("%s finished", __func__);
-}
-
-/*******************************************************************************
- *
* Function btif_cleanup_bluetooth
*
* Description Cleanup BTIF state.
#include "advertise_data_parser.h"
#include "bt_common.h"
#include "bta_gatt_api.h"
+#include "btif/include/stack_manager.h"
#include "btif_api.h"
#include "btif_av.h"
#include "btif_bqr.h"
}
}
bluetooth::bqr::EnableBtQualityReport(false);
- btif_disable_bluetooth_evt();
+ future_ready(stack_manager_get_hack_future(), FUTURE_SUCCESS);
break;
case BTA_DM_PIN_REQ_EVT:
module_shut_down(get_module(BTIF_CONFIG_MODULE));
future_await(local_hack_future);
+ bte_main_disable();
module_shut_down(get_module(CONTROLLER_MODULE)); // Doesn't do any work, just
// puts it in a restartable
// state