summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorHanumanth Reddy Pothula <c_hpothu@codeaurora.org>2018-06-13 13:41:44 +0530
committernshrivas <nshrivas@codeaurora.org>2018-06-21 12:25:16 -0700
commit4ec877da984b382659768401d06194e9a13983dc (patch)
treebea183cdbbfc5ef852c5f226d76b51ae89245b4a
parentcec6a0ea34a334d2429869382f1d50e4ec9e90ff (diff)
qcacld-3.0: Initialize start logging object
While processing WIFI_LOGGER_START vendor command, HDD passes uninitialized 'user_triggered' variable(member of start logging object), to down layers, which may lead to enable packet logging, not in the way user intended. Make sure valid data is passed to down layers by initialize start logging object and assigning valid data to the user_triggered variable. Change-Id: I38ac09a6b658eefb52ab113c885ce3ab54f36535 CRs-Fixed: 2235153
-rw-r--r--core/hdd/src/wlan_hdd_cfg80211.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/core/hdd/src/wlan_hdd_cfg80211.c b/core/hdd/src/wlan_hdd_cfg80211.c
index 643b695adf3d..9b99ed4c38ef 100644
--- a/core/hdd/src/wlan_hdd_cfg80211.c
+++ b/core/hdd/src/wlan_hdd_cfg80211.c
@@ -6374,7 +6374,7 @@ static int __wlan_hdd_cfg80211_wifi_logger_start(struct wiphy *wiphy,
QDF_STATUS status;
hdd_context_t *hdd_ctx = wiphy_priv(wiphy);
struct nlattr *tb[QCA_WLAN_VENDOR_ATTR_WIFI_LOGGER_START_MAX + 1];
- struct sir_wifi_start_log start_log;
+ struct sir_wifi_start_log start_log = { 0 };
ENTER_DEV(wdev->netdev);
@@ -6426,6 +6426,8 @@ static int __wlan_hdd_cfg80211_wifi_logger_start(struct wiphy *wiphy,
tb[QCA_WLAN_VENDOR_ATTR_WIFI_LOGGER_FLAGS]);
hdd_debug("is_iwpriv_command =%d", start_log.is_iwpriv_command);
+ start_log.user_triggered = 1;
+
/* size is buff size which can be set using iwpriv command*/
start_log.size = 0;
start_log.is_pktlog_buff_clear = false;