diff options
| author | Vignesh Viswanathan <viswanat@codeaurora.org> | 2017-08-02 15:34:44 +0530 |
|---|---|---|
| committer | snandini <snandini@codeaurora.org> | 2017-08-07 12:22:35 -0700 |
| commit | 4999d612cd659e08e79a8bf4d4b397ee3bf8e8f0 (patch) | |
| tree | 9ad99fe22a931fea32082553032c83fc4ae1f6da | |
| parent | 0c7b50729f00bdf459d8a80ba3090575f0f50526 (diff) | |
qcacld-3.0: Fix improper handling of lkSmeGlobalLock
sme_acquire_global_lock was used in couple of places without proper
handling of releasing the acquired lock.
Fix the improper handling of lkSmeGlobalLock in multiple functions.
Change-Id: Ib6cd43fae3fe522fc6388815581389592d3e70f8
CRs-Fixed: 2086102
| -rw-r--r-- | core/sme/src/common/sme_api.c | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/core/sme/src/common/sme_api.c b/core/sme/src/common/sme_api.c index 8cca780992b3..ff558e5e9358 100644 --- a/core/sme/src/common/sme_api.c +++ b/core/sme/src/common/sme_api.c @@ -13949,7 +13949,7 @@ QDF_STATUS sme_set_epno_list(tHalHandle hal, } status = sme_acquire_global_lock(&mac->sme); - if (QDF_IS_STATUS_SUCCESS(status)) { + if (!QDF_IS_STATUS_SUCCESS(status)) { sme_err("sme_acquire_global_lock failed!(status=%d)", status); qdf_mem_free(req_msg); @@ -14016,7 +14016,7 @@ QDF_STATUS sme_set_passpoint_list(tHalHandle hal, } status = sme_acquire_global_lock(&mac->sme); - if (QDF_IS_STATUS_SUCCESS(status)) { + if (!QDF_IS_STATUS_SUCCESS(status)) { sme_err("sme_acquire_global_lock failed!(status=%d)", status); qdf_mem_free(req_msg); @@ -14063,7 +14063,7 @@ QDF_STATUS sme_reset_passpoint_list(tHalHandle hal, req_msg->session_id = input->session_id; status = sme_acquire_global_lock(&mac->sme); - if (QDF_IS_STATUS_SUCCESS(status)) { + if (!QDF_IS_STATUS_SUCCESS(status)) { sme_err("sme_acquire_global_lock failed!(status=%d)", status); qdf_mem_free(req_msg); @@ -16733,6 +16733,7 @@ void sme_set_vdev_ies_per_band(uint8_t vdev_id, uint8_t is_hw_mode_dbs) p_msg = qdf_mem_malloc(sizeof(*p_msg)); if (NULL == p_msg) { sme_err("mem alloc failed for sme msg"); + sme_release_global_lock(&p_mac->sme); return; } |
