summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSanjay Devnani <sdevnani@qca.qualcomm.com>2014-10-15 09:23:41 -0700
committerAnjaneeDevi Kapparapu <c_akappa@qti.qualcomm.com>2014-10-20 17:06:25 +0530
commit9510742a7c15c47d5faa2a86b2a656ee089b1888 (patch)
treef3ab9c4c5a7d28a97a835b7b403a53fa55805502
parente8b2fab4abdceacefc53b01071d4e5e9c5bec811 (diff)
WLAN: Null check CE handle before dereferncing it
For error recovery and system stability Change-Id: I450ea438d988659fd9a4cefabe4bd0b1ce68a195 CRs-Fixed: 739135
-rw-r--r--CORE/SERVICES/HIF/PCIe/hif_pci.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/CORE/SERVICES/HIF/PCIe/hif_pci.c b/CORE/SERVICES/HIF/PCIe/hif_pci.c
index 623f0916394a..7995d2841ea4 100644
--- a/CORE/SERVICES/HIF/PCIe/hif_pci.c
+++ b/CORE/SERVICES/HIF/PCIe/hif_pci.c
@@ -330,6 +330,12 @@ HIFSend_head(HIF_DEVICE *hif_device,
pipe_info->num_sends_allowed -= nfrags;
adf_os_spin_unlock_bh(&pipe_info->completion_freeq_lock);
+ if(adf_os_unlikely(ce_hdl == NULL)) {
+ AR_DEBUG_PRINTF(ATH_DEBUG_ERR,
+ ("%s: error CE handle is null\n", __func__));
+ return A_ERROR;
+ }
+
status = CE_sendlist_send(ce_hdl, nbuf, &sendlist, transfer_id);
A_ASSERT(status == A_OK);