summaryrefslogtreecommitdiffstats
path: root/drivers/net/wireless/iwlwifi/iwl-agn.c
diff options
context:
space:
mode:
authorMeenakshi Venkataraman <meenakshi.venkataraman@intel.com>2012-03-14 23:49:37 +0100
committerWey-Yi Guy <wey-yi.w.guy@intel.com>2012-04-12 23:23:21 +0200
commit1591129d545760e6925bd48b15ce1ff7c25a5df8 (patch)
tree41f1e0c528343cac38f6f394ceb38ea395a80658 /drivers/net/wireless/iwlwifi/iwl-agn.c
parentiwlwifi: move iwl_print_rx_config_cmd to iwl-agn-rxon.c (diff)
downloadlinux-1591129d545760e6925bd48b15ce1ff7c25a5df8.tar.xz
linux-1591129d545760e6925bd48b15ce1ff7c25a5df8.zip
iwlwifi: move iwl_send_statistics_request to iwl-agn.c
Move this as part of iwl-core.c cleanup. Signed-off-by: Meenakshi Venkataraman <meenakshi.venkataraman@intel.com> Signed-off-by: Wey-Yi Guy <wey-yi.w.guy@intel.com>
Diffstat (limited to 'drivers/net/wireless/iwlwifi/iwl-agn.c')
-rw-r--r--drivers/net/wireless/iwlwifi/iwl-agn.c19
1 files changed, 19 insertions, 0 deletions
diff --git a/drivers/net/wireless/iwlwifi/iwl-agn.c b/drivers/net/wireless/iwlwifi/iwl-agn.c
index 3d3302a6df73..09367d430120 100644
--- a/drivers/net/wireless/iwlwifi/iwl-agn.c
+++ b/drivers/net/wireless/iwlwifi/iwl-agn.c
@@ -289,6 +289,25 @@ out:
mutex_unlock(&priv->mutex);
}
+int iwl_send_statistics_request(struct iwl_priv *priv, u8 flags, bool clear)
+{
+ struct iwl_statistics_cmd statistics_cmd = {
+ .configuration_flags =
+ clear ? IWL_STATS_CONF_CLEAR_STATS : 0,
+ };
+
+ if (flags & CMD_ASYNC)
+ return iwl_dvm_send_cmd_pdu(priv, REPLY_STATISTICS_CMD,
+ CMD_ASYNC,
+ sizeof(struct iwl_statistics_cmd),
+ &statistics_cmd);
+ else
+ return iwl_dvm_send_cmd_pdu(priv, REPLY_STATISTICS_CMD,
+ CMD_SYNC,
+ sizeof(struct iwl_statistics_cmd),
+ &statistics_cmd);
+}
+
/**
* iwl_bg_statistics_periodic - Timer callback to queue statistics
*