Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 4d6cb74c authored by Zach Johnson's avatar Zach Johnson
Browse files

Flatten bte_main_cleanup

Bug: 159815595
Tag: #refactor
Test: compile & verify basic functions working
Change-Id: If8adec407ca8c134fc359088ff1a5beaead487d4
parent af6015f4
Loading
Loading
Loading
Loading
+0 −1
Original line number Diff line number Diff line
@@ -211,7 +211,6 @@ void btif_remote_properties_evt(bt_status_t status, RawAddress* remote_addr,

void bte_load_did_conf(const char* p_path);
void bte_main_init(void);
void bte_main_cleanup(void);

bt_status_t btif_transfer_context(tBTIF_CBACK* p_cback, uint16_t event,
                                  char* p_params, int param_len,
+4 −1
Original line number Diff line number Diff line
@@ -341,7 +341,10 @@ static void event_clean_up_stack(void* context) {
  stack_is_initialized = false;

  btif_cleanup_bluetooth();
  bte_main_cleanup();

  module_clean_up(get_module(STACK_CONFIG_MODULE));
  module_clean_up(get_module(INTEROP_MODULE));

  module_clean_up(get_module(BTIF_CONFIG_MODULE));
  module_clean_up(get_module(BT_UTILS_MODULE));
  module_clean_up(get_module(OSI_MODULE));
+0 −15
Original line number Diff line number Diff line
@@ -102,21 +102,6 @@ void bte_main_init(void) {
  hci->set_data_cb(base::Bind(&post_to_main_message_loop));
}

/******************************************************************************
 *
 * Function         bte_main_cleanup
 *
 * Description      BTE MAIN API - Cleanup code for BTE chip/stack
 *
 * Returns          None
 *
 *****************************************************************************/
void bte_main_cleanup() {
  module_clean_up(get_module(STACK_CONFIG_MODULE));

  module_clean_up(get_module(INTEROP_MODULE));
}

/******************************************************************************
 *
 * Function         bte_main_hci_send