From ea70106cdab5b10032d7f1b3cfeb4356647d4c7e Mon Sep 17 00:00:00 2001 From: Will Huang Date: Tue, 26 Jun 2018 14:03:18 +0800 Subject: [PATCH] qcacld-3.0: Fix HDD reassociate fail case for LFR2.0 If station connect with infrastructure network, might connect to AP different with the hint bssid, if reassociate command issued, it will invoke hdd_reassoc(). It might bring down connected station without bring down vdev of the LFR2.0 path if the process of scanning for ssid failed. Add back logic of checking uOsRequestedHandoff and route to correct LFR2.0 roaming path. Change-Id: I406b55270dc70e5d3494250d6013f7d35824970f CRs-Fixed: 2256194 --- core/sme/src/csr/csr_api_scan.c | 23 +++++++++++++++++++++++ 1 file changed, 23 insertions(+) diff --git a/core/sme/src/csr/csr_api_scan.c b/core/sme/src/csr/csr_api_scan.c index 85a032bcf7b5..af8de7796ff0 100644 --- a/core/sme/src/csr/csr_api_scan.c +++ b/core/sme/src/csr/csr_api_scan.c @@ -150,6 +150,18 @@ QDF_STATUS csr_scan_handle_search_for_ssid(tpAniSirGlobal mac_ctx, profile = session->scan_info.profile; sme_debug("session %d", session_id); do { + /* If this scan is for HDD reassociate */ + if (mac_ctx->roam.neighborRoamInfo[session_id]. + uOsRequestedHandoff) { + /* notify LFR state m/c */ + status = csr_neighbor_roam_sssid_scan_done + (mac_ctx, session_id, QDF_STATUS_SUCCESS); + if (!QDF_IS_STATUS_SUCCESS(status)) + csr_neighbor_roam_start_lfr_scan(mac_ctx, + session_id); + status = QDF_STATUS_SUCCESS; + break; + } /* * If there is roam command waiting, ignore this roam because * the newer roam command is the one to execute @@ -251,6 +263,17 @@ QDF_STATUS csr_scan_handle_search_for_ssid_failure(tpAniSirGlobal mac_ctx, sme_err("session %d not found", session_id); return QDF_STATUS_E_FAILURE; } + + /* If this scan is for HDD reassociate */ + if (mac_ctx->roam.neighborRoamInfo[session_id].uOsRequestedHandoff) { + /* notify LFR state m/c */ + status = csr_neighbor_roam_sssid_scan_done + (mac_ctx, session_id, QDF_STATUS_E_FAILURE); + if (!QDF_IS_STATUS_SUCCESS(status)) + csr_neighbor_roam_start_lfr_scan(mac_ctx, session_id); + return QDF_STATUS_SUCCESS; + } + profile = session->scan_info.profile; /*