summaryrefslogtreecommitdiff
path: root/drivers/net/wireless/iwlwifi/mvm/debugfs.c
diff options
context:
space:
mode:
authorLuciano Coelho <luciano.coelho@intel.com>2014-11-10 23:21:55 +0200
committerEmmanuel Grumbach <emmanuel.grumbach@intel.com>2014-11-23 20:08:30 +0200
commitcc4c1ab5d22b22b945141edcbb74d0ab8caecbad (patch)
treeb2987e1481d3f03125a35da683be9417872d89db /drivers/net/wireless/iwlwifi/mvm/debugfs.c
parent522713c81e4ec98c554d74bcf8c26ddbfa6a30ee (diff)
iwlwifi: mvm: make nd_ies part of the mvm struct
Instead of allocating nd_ies separately, make it part of the iwl_mvm structure so it's easier to handle its lifetime. Signed-off-by: Luciano Coelho <luciano.coelho@intel.com> Reviewed-by: Johannes Berg <johannes.berg@intel.com> Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com>
Diffstat (limited to 'drivers/net/wireless/iwlwifi/mvm/debugfs.c')
-rw-r--r--drivers/net/wireless/iwlwifi/mvm/debugfs.c8
1 files changed, 0 insertions, 8 deletions
diff --git a/drivers/net/wireless/iwlwifi/mvm/debugfs.c b/drivers/net/wireless/iwlwifi/mvm/debugfs.c
index 8212b00096f9..5a0f1049e099 100644
--- a/drivers/net/wireless/iwlwifi/mvm/debugfs.c
+++ b/drivers/net/wireless/iwlwifi/mvm/debugfs.c
@@ -1198,14 +1198,8 @@ static ssize_t iwl_dbgfs_netdetect_write(struct iwl_mvm *mvm, char *buf,
kfree(mvm->nd_config->match_sets);
kfree(mvm->nd_config);
mvm->nd_config = NULL;
- kfree(mvm->nd_ies);
- mvm->nd_ies = NULL;
}
- mvm->nd_ies = kzalloc(sizeof(*mvm->nd_ies), GFP_KERNEL);
- if (!mvm->nd_ies)
- return -ENOMEM;
-
mvm->nd_config = kzalloc(sizeof(*mvm->nd_config) +
(11 * sizeof(struct ieee80211_channel *)),
GFP_KERNEL);
@@ -1262,8 +1256,6 @@ out_free:
kfree(mvm->nd_config->match_sets);
kfree(mvm->nd_config);
mvm->nd_config = NULL;
- kfree(mvm->nd_ies);
- mvm->nd_ies = NULL;
out:
return ret;
}