]> pilppa.org Git - linux-2.6-omap-h63xx.git/blobdiff - drivers/net/wireless/iwlwifi/iwl-power.h
Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/geert/linux...
[linux-2.6-omap-h63xx.git] / drivers / net / wireless / iwlwifi / iwl-power.h
index fa098d8975cec38d84161e51a1f5db3a9ea006ad..18963392121e9606b258d6764491e72282d1d2e5 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,22 +42,26 @@ enum {
        IWL_POWER_INDEX_5,
        IWL_POWER_AUTO,
        IWL_POWER_MAX = IWL_POWER_AUTO,
-       IWL_POWER_AC,
-       IWL_POWER_BATTERY,
 };
 
 enum {
        IWL_POWER_SYS_AUTO,
        IWL_POWER_SYS_AC,
        IWL_POWER_SYS_BATTERY,
+       IWL_POWER_SYS_MAX,
 };
 
-#define IWL_POWER_LIMIT                0x08
-#define IWL_POWER_MASK         0x0F
-#define IWL_POWER_ENABLED      0x10
 
 /* Power management (not Tx power) structures */
 
+#define NOSLP cpu_to_le16(0), 0, 0
+#define SLP IWL_POWER_DRIVER_ALLOW_SLEEP_MSK, 0, 0
+#define SLP_TOUT(T) cpu_to_le32((T) * MSEC_TO_USEC)
+#define SLP_VEC(X0, X1, X2, X3, X4) {cpu_to_le32(X0), \
+                                    cpu_to_le32(X1), \
+                                    cpu_to_le32(X2), \
+                                    cpu_to_le32(X3), \
+                                    cpu_to_le32(X4)}
 struct iwl_power_vec_entry {
        struct iwl_powertable_cmd cmd;
        u8 no_dtim;