summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAshish Kumar Dhanotiya <adhanoti@codeaurora.org>2017-03-01 15:48:12 +0530
committerqcabuildsw <qcabuildsw@localhost>2017-03-02 03:59:42 -0800
commitbc560a15feff49aa674c1793fd7c741138bb7c1a (patch)
treeefb80b1746f59883c867ddb409a1cfa5f823fc66
parentdac083367c6f1087e9033c73d7b446697cd67e1c (diff)
qcacld-3.0: Check WIFI module status during wifi logger start
During wifi logger start if the modules are in close state, it will access uninitialized lock. To handle this, check module status during start of the wifi logger. Change-Id: I10b3fffa45475c602c22b548d521f75c627b133e CRs-Fixed: 2012742
-rw-r--r--core/hdd/src/wlan_hdd_cfg80211.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/core/hdd/src/wlan_hdd_cfg80211.c b/core/hdd/src/wlan_hdd_cfg80211.c
index bb7fdbebf490..2ac8896683ec 100644
--- a/core/hdd/src/wlan_hdd_cfg80211.c
+++ b/core/hdd/src/wlan_hdd_cfg80211.c
@@ -4486,6 +4486,10 @@ static int __wlan_hdd_cfg80211_wifi_logger_start(struct wiphy *wiphy,
if (status)
return status;
+ if (hdd_ctx->driver_status == DRIVER_MODULES_CLOSED) {
+ hdd_err("Driver Modules are closed, can not start logger");
+ return -EINVAL;
+ }
if (nla_parse(tb, QCA_WLAN_VENDOR_ATTR_WIFI_LOGGER_START_MAX,
data, data_len,