qcacld-3.0: Fix SAP SSR reinit for uninitialized config
SSR can happen during SAP initialization. Thus check of SAP initialization complete before attempting to restart SAP instance during SSR. Change-Id: Ib26116cfc33684035df692ae6c7b5d83cb0a27b8 CRs-fixed: 2005281
This commit is contained in:

committed by
qcabuildsw

orang tua
cc544b3909
melakukan
0a0ac95919
@@ -108,6 +108,8 @@
|
||||
#define DEVICE_IFACE_OPENED (5)
|
||||
#define TDLS_INIT_DONE (6)
|
||||
#define ACS_PENDING (7)
|
||||
#define SOFTAP_INIT_DONE (8)
|
||||
|
||||
/* Waiting for event for vendor acs */
|
||||
#define VENDOR_ACS_RESPONSE_PENDING (8)
|
||||
|
||||
|
@@ -7735,6 +7735,7 @@ int wlan_hdd_cfg80211_start_bss(hdd_adapter_t *pHostapdAdapter,
|
||||
pSapEventCallback = hdd_hostapd_sap_event_cb;
|
||||
|
||||
(WLAN_HDD_GET_AP_CTX_PTR(pHostapdAdapter))->dfs_cac_block_tx = true;
|
||||
set_bit(SOFTAP_INIT_DONE, &pHostapdAdapter->event_flags);
|
||||
|
||||
qdf_event_reset(&pHostapdState->qdf_event);
|
||||
status = wlansap_start_bss(
|
||||
@@ -7795,6 +7796,7 @@ int wlan_hdd_cfg80211_start_bss(hdd_adapter_t *pHostapdAdapter,
|
||||
return 0;
|
||||
|
||||
error:
|
||||
clear_bit(SOFTAP_INIT_DONE, &pHostapdAdapter->event_flags);
|
||||
if (pHostapdAdapter->sessionCtx.ap.sapConfig.acs_cfg.ch_list) {
|
||||
qdf_mem_free(pHostapdAdapter->sessionCtx.ap.sapConfig.
|
||||
acs_cfg.ch_list);
|
||||
@@ -7980,6 +7982,7 @@ static int __wlan_hdd_cfg80211_stop_ap(struct wiphy *wiphy,
|
||||
}
|
||||
/* Reset WNI_CFG_PROBE_RSP Flags */
|
||||
wlan_hdd_reset_prob_rspies(pAdapter);
|
||||
clear_bit(SOFTAP_INIT_DONE, &pAdapter->event_flags);
|
||||
|
||||
#ifdef WLAN_FEATURE_P2P_DEBUG
|
||||
if ((pAdapter->device_mode == QDF_P2P_GO_MODE) &&
|
||||
@@ -8069,6 +8072,7 @@ static int __wlan_hdd_cfg80211_start_ap(struct wiphy *wiphy,
|
||||
|
||||
ENTER();
|
||||
|
||||
clear_bit(SOFTAP_INIT_DONE, &pAdapter->event_flags);
|
||||
if (QDF_GLOBAL_FTM_MODE == hdd_get_conparam()) {
|
||||
hdd_err("Command not allowed in FTM mode");
|
||||
return -EINVAL;
|
||||
|
@@ -1257,8 +1257,10 @@ static void hdd_ssr_restart_sap(hdd_context_t *hdd_ctx)
|
||||
while (NULL != adapter_node && QDF_STATUS_SUCCESS == status) {
|
||||
adapter = adapter_node->pAdapter;
|
||||
if (adapter && adapter->device_mode == QDF_SAP_MODE) {
|
||||
hdd_notice("in sap mode %p", adapter);
|
||||
wlan_hdd_start_sap(adapter, true);
|
||||
if (test_bit(SOFTAP_INIT_DONE, &adapter->event_flags)) {
|
||||
hdd_notice("Restart prev SAP session");
|
||||
wlan_hdd_start_sap(adapter, true);
|
||||
}
|
||||
}
|
||||
status = hdd_get_next_adapter(hdd_ctx, adapter_node, &next);
|
||||
adapter_node = next;
|
||||
|
Reference in New Issue
Block a user