diff options
| author | Pradeep Reddy POTTETI <c_ppotte@qti.qualcomm.com> | 2016-03-30 17:49:44 +0530 |
|---|---|---|
| committer | Anjaneedevi Kapparapu <akappa@codeaurora.org> | 2016-04-05 12:52:54 +0530 |
| commit | fc2f06074b7799acc7e96e2dff7f5dc1eefdd234 (patch) | |
| tree | d298b86c4a2c6bc814cbb9122c6561987e2f8bc2 | |
| parent | 1b188335a282cebdff03e9e9e9e0af1a2af004c8 (diff) | |
TDLS: Don't delete TDLS forced peers as part of STA disconnection
Don't delete TDLS forced peers as part of STA disconnection. TDLS
forced peer entry should exist until there is a explicit deconfig
from the application.
CRs-Fixed: 993297
Change-Id: Ie1bb6bc92849182b82e01e5b5237cead1538f4d7
| -rw-r--r-- | CORE/HDD/src/wlan_hdd_tdls.c | 10 |
1 files changed, 7 insertions, 3 deletions
diff --git a/CORE/HDD/src/wlan_hdd_tdls.c b/CORE/HDD/src/wlan_hdd_tdls.c index 155e0bee4de2..44a51bffb183 100644 --- a/CORE/HDD/src/wlan_hdd_tdls.c +++ b/CORE/HDD/src/wlan_hdd_tdls.c @@ -414,7 +414,8 @@ static v_VOID_t wlan_hdd_tdls_discovery_timeout_peer_cb(v_PVOID_t userData) return; } -static void wlan_hdd_tdls_free_list(tdlsCtx_t *pHddTdlsCtx) +static void wlan_hdd_tdls_free_list(tdlsCtx_t *pHddTdlsCtx, + bool del_forced_peer) { int i; struct list_head *head; @@ -432,6 +433,9 @@ static void wlan_hdd_tdls_free_list(tdlsCtx_t *pHddTdlsCtx) head = &pHddTdlsCtx->peer_list[i]; list_for_each_safe (pos, q, head) { tmp = list_entry(pos, hddTdlsPeer_t, node); + /* Don't delete TDLS forced peers during STA disconnection */ + if (!del_forced_peer && tmp->isForcedPeer) + continue; list_del(pos); vos_mem_free(tmp); tmp = NULL; @@ -800,7 +804,7 @@ void wlan_hdd_tdls_exit(hdd_adapter_t *pAdapter) /* must stop timer here before freeing peer list, because peerIdleTimer is part of peer list structure. */ wlan_hdd_tdls_timers_destroy(pHddTdlsCtx); - wlan_hdd_tdls_free_list(pHddTdlsCtx); + wlan_hdd_tdls_free_list(pHddTdlsCtx, true); mutex_unlock(&pHddCtx->tdls_lock); @@ -2181,7 +2185,7 @@ void wlan_hdd_tdls_disconnection_callback(hdd_adapter_t *pAdapter) wlan_hdd_tdls_check_power_save_prohibited(pHddTdlsCtx->pAdapter); wlan_hdd_tdls_monitor_timers_stop(pHddTdlsCtx); - wlan_hdd_tdls_free_list(pHddTdlsCtx); + wlan_hdd_tdls_free_list(pHddTdlsCtx, false); pHddTdlsCtx->curr_candidate = NULL; |
