]> git.karo-electronics.de Git - mv-sheeva.git/blobdiff - drivers/net/wireless/iwlwifi/iwl-power.h
iwlwifi: update copyright year to 2009
[mv-sheeva.git] / drivers / net / wireless / iwlwifi / iwl-power.h
index fa098d8975cec38d84161e51a1f5db3a9ea006ad..476c2aa2bf7567ff4acc420679d10271339014f7 100644 (file)
@@ -1,6 +1,6 @@
 /******************************************************************************
  *
- * Copyright(c) 2007 - 2008 Intel Corporation. All rights reserved.
+ * Copyright(c) 2007 - 2009 Intel Corporation. All rights reserved.
  *
  * Portions of this file are derived from the ipw3945 project, as well
  * as portions of the ieee80211 subsystem header files.
@@ -42,7 +42,10 @@ enum {
        IWL_POWER_INDEX_5,
        IWL_POWER_AUTO,
        IWL_POWER_MAX = IWL_POWER_AUTO,
+       IWL39_POWER_AC = IWL_POWER_AUTO, /* 0x06 */
        IWL_POWER_AC,
+       IWL39_POWER_BATTERY = IWL_POWER_AC, /* 0x07 */
+       IWL39_POWER_LIMIT = IWL_POWER_AC,
        IWL_POWER_BATTERY,
 };
 
@@ -56,6 +59,11 @@ enum {
 #define IWL_POWER_MASK         0x0F
 #define IWL_POWER_ENABLED      0x10
 
+#define IWL_POWER_RANGE_0  (0)
+#define IWL_POWER_RANGE_1  (1)
+
+#define IWL_POWER_LEVEL(x)     ((x) & IWL_POWER_MASK)
+
 /* Power management (not Tx power) structures */
 
 struct iwl_power_vec_entry {
@@ -78,6 +86,14 @@ struct iwl_power_mgr {
        u8 power_disabled; /* flag to disable using power saving level */
 };
 
+struct iwl3945_power_mgr {
+       spinlock_t lock;
+       struct iwl_power_vec_entry pwr_range_0[IWL_POWER_AC];
+       struct iwl_power_vec_entry pwr_range_1[IWL_POWER_AC];
+       u8 active_index;
+       u32 dtim_val;
+};
+
 void iwl_setup_power_deferred_work(struct iwl_priv *priv);
 void iwl_power_cancel_timeout(struct iwl_priv *priv);
 int iwl_power_update_mode(struct iwl_priv *priv, bool force);