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

Commit e3ac6b02 authored by Dundi Raviteja's avatar Dundi Raviteja Committed by Gerrit - the friendly Code Review server
Browse files

wlan: Initialize sw_pta before vos_open

bt_profile_state can be triggered before initializing sw_pta
which can cause accessing elements that are not initialized.

To address this issue initialize sw_pta before registering
bt_profile_state.

Change-Id: I3eebf2dfd03658ca89b11e7b0b4a07ba96d6dc82
CRs-Fixed: 2899060
parent 51596a13
Loading
Loading
Loading
Loading
+2 −2
Original line number Diff line number Diff line
@@ -4039,7 +4039,6 @@ int hdd_process_bt_sco_profile(hdd_context_t *hdd_ctx,
static void hdd_init_sw_pta(hdd_context_t *hdd_ctx)
{
	init_completion(&hdd_ctx->sw_pta_comp);
	wcnss_update_bt_profile();
}
static void hdd_deinit_sw_pta(hdd_context_t *hdd_ctx)
@@ -14168,6 +14167,7 @@ int hdd_wlan_startup(struct device *dev )
#endif /* WLAN_KD_READY_NOTIFIER */
   vos_set_roam_delay_stats_enabled(pHddCtx->cfg_ini->gEnableRoamDelayStats);
   hdd_init_sw_pta(pHddCtx);
   status = vos_open( &pVosContext, pHddCtx->parent_dev);
   if ( !VOS_IS_STATUS_SUCCESS( status ))
   {
@@ -14800,7 +14800,7 @@ int hdd_wlan_startup(struct device *dev )
   mutex_init(&pHddCtx->cache_channel_lock);
   hdd_init_sw_pta(pHddCtx);
   wcnss_update_bt_profile();
   goto success;
err_open_cesium_nl_sock: