summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSrinivas Girigowda <sgirigow@qca.qualcomm.com>2015-06-08 10:49:45 -0700
committerAnjaneedevi Kapparapu <akappa@codeaurora.org>2015-06-09 19:23:09 +0530
commitb31e64fa7a31a9f75bc121ffbb72043cc0837cc3 (patch)
tree1eca68e56cb9eec2b6852d66637c22a3640e23b0
parent8bc3ea519bb45b5691af5c497c8a84b08fb21212 (diff)
qcacld-2.0: SSR protection for wmm work queue
This is a prima to qcacld-2.0 propagation. If SSR trigger in middle of execution of wmm work queue, driver may access uninitialized data. Hence Driver need to protect this function from SSR. Change-Id: If0c861a8af3323b7227fcdd4e711be6a5686f5a7 CRs-Fixed: 799466
-rw-r--r--CORE/HDD/src/wlan_hdd_wmm.c30
1 files changed, 21 insertions, 9 deletions
diff --git a/CORE/HDD/src/wlan_hdd_wmm.c b/CORE/HDD/src/wlan_hdd_wmm.c
index a9a595841589..5be199cc68a0 100644
--- a/CORE/HDD/src/wlan_hdd_wmm.c
+++ b/CORE/HDD/src/wlan_hdd_wmm.c
@@ -1232,15 +1232,14 @@ int hdd_wmmps_helper(hdd_adapter_t *pAdapter, tANI_U8 *ptr)
return 0;
}
-/**============================================================================
- @brief hdd_wmm_do_implicit_qos() - Function which will attempt to setup
- QoS for any AC requiring it
-
- @param work : [in] pointer to work structure
-
- @return : void
- ===========================================================================*/
-static void hdd_wmm_do_implicit_qos(struct work_struct *work)
+/**
+ * __hdd_wmm_do_implicit_qos() - Function which will attempt to setup
+ * QoS for any AC requiring it.
+ * @work: [in] pointer to work structure.
+ *
+ * Return: none
+ */
+static void __hdd_wmm_do_implicit_qos(struct work_struct *work)
{
hdd_wmm_qos_context_t* pQosContext =
container_of(work, hdd_wmm_qos_context_t, wmmAcSetupImplicitQos);
@@ -1469,6 +1468,19 @@ static void hdd_wmm_do_implicit_qos(struct work_struct *work)
}
+/**
+ * hdd_wmm_do_implicit_qos() - SSR wraper function for hdd_wmm_do_implicit_qos
+ * @work: pointer to work_struct
+ *
+ * Return: none
+ */
+static void hdd_wmm_do_implicit_qos(struct work_struct *work)
+{
+ vos_ssr_protect(__func__);
+ __hdd_wmm_do_implicit_qos(work);
+ vos_ssr_unprotect(__func__);
+}
+
/**============================================================================
@brief hdd_wmm_init() - Function which will initialize the WMM configuration
and status to an initial state. The configuration can later be overwritten