Selaa lähdekoodia

qcacld-3.0: Restructure TDLS function to fix the compilation issue

If TDLS disabled at the build level, it triggers
build failures in some of the projects, which does
not support TDLS feature.
Restructure the TDLS function to avoid build
failures, when TDLS is not enabled.

Change-Id: I3b63546f22d0187fb42d400fd7e15ff7a3d64653
CRs-Fixed: 2056022
Kabilan Kannan 8 vuotta sitten
vanhempi
sitoutus
00d2041f9b
3 muutettua tiedostoa jossa 3 lisäystä ja 8 poistoa
  1. 0 1
      core/hdd/inc/wlan_hdd_tdls.h
  2. 2 6
      core/hdd/src/wlan_hdd_main.c
  3. 1 1
      core/hdd/src/wlan_hdd_tdls.c

+ 0 - 1
core/hdd/inc/wlan_hdd_tdls.h

@@ -890,5 +890,4 @@ static inline void hdd_wlan_block_scan_by_tdls_event(void) {}
 #endif /* FEATURE_WLAN_DIAG_SUPPORT */
 bool cds_check_is_tdls_allowed(enum tQDF_ADAPTER_MODE device_mode);
 void cds_set_tdls_ct_mode(hdd_context_t *hdd_ctx);
-void wlan_hdd_tdls_timers_stop(tdlsCtx_t *hdd_tdls_ctx);
 #endif /* __HDD_TDLS_H */

+ 2 - 6
core/hdd/src/wlan_hdd_main.c

@@ -4350,7 +4350,6 @@ QDF_STATUS hdd_reset_all_adapters(hdd_context_t *hdd_ctx)
 	hdd_adapter_t *adapter;
 	hdd_station_ctx_t *pHddStaCtx;
 	struct qdf_mac_addr peerMacAddr;
-	tdlsCtx_t *tdls_ctx;
 
 	ENTER();
 
@@ -4364,12 +4363,9 @@ QDF_STATUS hdd_reset_all_adapters(hdd_context_t *hdd_ctx)
 			   adapter->device_mode);
 
 		if ((adapter->device_mode == QDF_STA_MODE) ||
-			(adapter->device_mode == QDF_P2P_CLIENT_MODE)) {
+		    (adapter->device_mode == QDF_P2P_CLIENT_MODE))
 			/* Stop tdls timers */
-			tdls_ctx = WLAN_HDD_GET_TDLS_CTX_PTR(adapter);
-			if (tdls_ctx)
-				wlan_hdd_tdls_timers_stop(tdls_ctx);
-		}
+			hdd_notify_tdls_reset_adapter(adapter->hdd_vdev);
 
 		if (hdd_ctx->config->sap_internal_restart &&
 		    adapter->device_mode == QDF_SAP_MODE) {

+ 1 - 1
core/hdd/src/wlan_hdd_tdls.c

@@ -613,7 +613,7 @@ static void wlan_hdd_tdls_ct_timers_stop(tdlsCtx_t *hdd_tdls_ctx)
  *
  * Return: none
  */
-void wlan_hdd_tdls_timers_stop(tdlsCtx_t *hdd_tdls_ctx)
+static void wlan_hdd_tdls_timers_stop(tdlsCtx_t *hdd_tdls_ctx)
 {
 	wlan_hdd_tdls_monitor_timers_stop(hdd_tdls_ctx);
 	wlan_hdd_tdls_ct_timers_stop(hdd_tdls_ctx);