aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/wireless/iwlwifi/iwl-dev.h
diff options
context:
space:
mode:
authorWey-Yi Guy <wey-yi.w.guy@intel.com>2011-01-21 18:26:39 -0500
committerWey-Yi Guy <wey-yi.w.guy@intel.com>2011-01-21 18:26:39 -0500
commit5ed540aecc2aae92d5c97b9a9306a5bf88ad5574 (patch)
tree0b19e77d0f5ed9ac4d88ab733440d7ea6348ea4e /drivers/net/wireless/iwlwifi/iwl-dev.h
parent4a4fdf2e0b9e3534f6ec4f3e7077470bd66924ab (diff)
iwlwifi: use mac80211 throughput trigger
Instead of keeping track of LED blink speed in the driver, use the new mac80211 trigger and link it up with an LED classdev that we now register. This also allows users more flexibility in how they want to have the LED blink or not. Signed-off-by: Johannes Berg <johannes.berg@intel.com> Signed-off-by: Wey-Yi Guy <wey-yi.w.guy@intel.com>
Diffstat (limited to 'drivers/net/wireless/iwlwifi/iwl-dev.h')
-rw-r--r--drivers/net/wireless/iwlwifi/iwl-dev.h18
1 files changed, 7 insertions, 11 deletions
diff --git a/drivers/net/wireless/iwlwifi/iwl-dev.h b/drivers/net/wireless/iwlwifi/iwl-dev.h
index 2ec680bb8f6d..6dd6508c93b0 100644
--- a/drivers/net/wireless/iwlwifi/iwl-dev.h
+++ b/drivers/net/wireless/iwlwifi/iwl-dev.h
@@ -35,6 +35,7 @@
35#include <linux/pci.h> /* for struct pci_device_id */ 35#include <linux/pci.h> /* for struct pci_device_id */
36#include <linux/kernel.h> 36#include <linux/kernel.h>
37#include <linux/wait.h> 37#include <linux/wait.h>
38#include <linux/leds.h>
38#include <net/ieee80211_radiotap.h> 39#include <net/ieee80211_radiotap.h>
39 40
40#include "iwl-eeprom.h" 41#include "iwl-eeprom.h"
@@ -996,7 +997,6 @@ struct reply_agg_tx_error_statistics {
996 u32 unknown; 997 u32 unknown;
997}; 998};
998 999
999#ifdef CONFIG_IWLWIFI_DEBUGFS
1000/* management statistics */ 1000/* management statistics */
1001enum iwl_mgmt_stats { 1001enum iwl_mgmt_stats {
1002 MANAGEMENT_ASSOC_REQ = 0, 1002 MANAGEMENT_ASSOC_REQ = 0,
@@ -1027,16 +1027,13 @@ enum iwl_ctrl_stats {
1027}; 1027};
1028 1028
1029struct traffic_stats { 1029struct traffic_stats {
1030#ifdef CONFIG_IWLWIFI_DEBUGFS
1030 u32 mgmt[MANAGEMENT_MAX]; 1031 u32 mgmt[MANAGEMENT_MAX];
1031 u32 ctrl[CONTROL_MAX]; 1032 u32 ctrl[CONTROL_MAX];
1032 u32 data_cnt; 1033 u32 data_cnt;
1033 u64 data_bytes; 1034 u64 data_bytes;
1034};
1035#else
1036struct traffic_stats {
1037 u64 data_bytes;
1038};
1039#endif 1035#endif
1036};
1040 1037
1041/* 1038/*
1042 * iwl_switch_rxon: "channel switch" structure 1039 * iwl_switch_rxon: "channel switch" structure
@@ -1338,11 +1335,6 @@ struct iwl_priv {
1338 struct iwl_init_alive_resp card_alive_init; 1335 struct iwl_init_alive_resp card_alive_init;
1339 struct iwl_alive_resp card_alive; 1336 struct iwl_alive_resp card_alive;
1340 1337
1341 unsigned long last_blink_time;
1342 u8 last_blink_rate;
1343 u8 allow_blinking;
1344 u64 led_tpt;
1345
1346 u16 active_rate; 1338 u16 active_rate;
1347 1339
1348 u8 start_calib; 1340 u8 start_calib;
@@ -1580,6 +1572,10 @@ struct iwl_priv {
1580 bool hw_ready; 1572 bool hw_ready;
1581 1573
1582 struct iwl_event_log event_log; 1574 struct iwl_event_log event_log;
1575
1576 struct led_classdev led;
1577 unsigned long blink_on, blink_off;
1578 bool led_registered;
1583}; /*iwl_priv */ 1579}; /*iwl_priv */
1584 1580
1585static inline void iwl_txq_ctx_activate(struct iwl_priv *priv, int txq_id) 1581static inline void iwl_txq_ctx_activate(struct iwl_priv *priv, int txq_id)