aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/net')
-rw-r--r--drivers/net/wireless/iwlwifi/iwl-3945-commands.h12
-rw-r--r--drivers/net/wireless/iwlwifi/iwl-3945-debug.h58
-rw-r--r--drivers/net/wireless/iwlwifi/iwl-3945-hw.h46
-rw-r--r--drivers/net/wireless/iwlwifi/iwl-3945-rs.h26
-rw-r--r--drivers/net/wireless/iwlwifi/iwl-4965-commands.h40
-rw-r--r--drivers/net/wireless/iwlwifi/iwl-4965-debug.h58
-rw-r--r--drivers/net/wireless/iwlwifi/iwl-4965-hw.h36
-rw-r--r--drivers/net/wireless/iwlwifi/iwl-4965-rs.h28
-rw-r--r--drivers/net/wireless/iwlwifi/iwl-4965.c12
-rw-r--r--drivers/net/wireless/iwlwifi/iwl3945-base.c2
-rw-r--r--drivers/net/wireless/iwlwifi/iwl4965-base.c2
11 files changed, 160 insertions, 160 deletions
diff --git a/drivers/net/wireless/iwlwifi/iwl-3945-commands.h b/drivers/net/wireless/iwlwifi/iwl-3945-commands.h
index 0c80ed5d7ea6..46bb2c7d11dd 100644
--- a/drivers/net/wireless/iwlwifi/iwl-3945-commands.h
+++ b/drivers/net/wireless/iwlwifi/iwl-3945-commands.h
@@ -508,8 +508,8 @@ struct iwl3945_qosparam_cmd {
508#define IWL_STATION_COUNT 32 /* MAX(3945,4965)*/ 508#define IWL_STATION_COUNT 32 /* MAX(3945,4965)*/
509#define IWL_INVALID_STATION 255 509#define IWL_INVALID_STATION 255
510 510
511#define STA_FLG_TX_RATE_MSK __constant_cpu_to_le32(1<<2); 511#define STA_FLG_TX_RATE_MSK __constant_cpu_to_le32(1 << 2);
512#define STA_FLG_PWR_SAVE_MSK __constant_cpu_to_le32(1<<8); 512#define STA_FLG_PWR_SAVE_MSK __constant_cpu_to_le32(1 << 8);
513 513
514/* Use in mode field. 1: modify existing entry, 0: add new station entry */ 514/* Use in mode field. 1: modify existing entry, 0: add new station entry */
515#define STA_CONTROL_MODIFY_MSK 0x01 515#define STA_CONTROL_MODIFY_MSK 0x01
@@ -1010,7 +1010,7 @@ struct iwl3945_rate_scaling_info {
1010 * For example, if you set 9MB (PLCP 0x0f) as the first 1010 * For example, if you set 9MB (PLCP 0x0f) as the first
1011 * rate in the rate table, the bit mask for that rate 1011 * rate in the rate table, the bit mask for that rate
1012 * when passed through ofdm_basic_rates on the REPLY_RXON 1012 * when passed through ofdm_basic_rates on the REPLY_RXON
1013 * command would be bit 0 (1<<0) 1013 * command would be bit 0 (1 << 0)
1014 */ 1014 */
1015struct iwl3945_rate_scaling_cmd { 1015struct iwl3945_rate_scaling_cmd {
1016 u8 table_id; 1016 u8 table_id;
@@ -1190,9 +1190,9 @@ struct iwl3945_spectrum_notification {
1190 */ 1190 */
1191#define IWL_POWER_VEC_SIZE 5 1191#define IWL_POWER_VEC_SIZE 5
1192 1192
1193#define IWL_POWER_DRIVER_ALLOW_SLEEP_MSK __constant_cpu_to_le32(1<<0) 1193#define IWL_POWER_DRIVER_ALLOW_SLEEP_MSK __constant_cpu_to_le32(1 << 0)
1194#define IWL_POWER_SLEEP_OVER_DTIM_MSK __constant_cpu_to_le32(1<<2) 1194#define IWL_POWER_SLEEP_OVER_DTIM_MSK __constant_cpu_to_le32(1 << 2)
1195#define IWL_POWER_PCI_PM_MSK __constant_cpu_to_le32(1<<3) 1195#define IWL_POWER_PCI_PM_MSK __constant_cpu_to_le32(1 << 3)
1196struct iwl3945_powertable_cmd { 1196struct iwl3945_powertable_cmd {
1197 __le32 flags; 1197 __le32 flags;
1198 __le32 rx_data_timeout; 1198 __le32 rx_data_timeout;
diff --git a/drivers/net/wireless/iwlwifi/iwl-3945-debug.h b/drivers/net/wireless/iwlwifi/iwl-3945-debug.h
index ebf016877fee..f853c6b9f76e 100644
--- a/drivers/net/wireless/iwlwifi/iwl-3945-debug.h
+++ b/drivers/net/wireless/iwlwifi/iwl-3945-debug.h
@@ -75,44 +75,44 @@ static inline void IWL_DEBUG_LIMIT(int level, const char *fmt, ...)
75 * 75 *
76 */ 76 */
77 77
78#define IWL_DL_INFO (1<<0) 78#define IWL_DL_INFO (1 << 0)
79#define IWL_DL_MAC80211 (1<<1) 79#define IWL_DL_MAC80211 (1 << 1)
80#define IWL_DL_HOST_COMMAND (1<<2) 80#define IWL_DL_HOST_COMMAND (1 << 2)
81#define IWL_DL_STATE (1<<3) 81#define IWL_DL_STATE (1 << 3)
82 82
83#define IWL_DL_RADIO (1<<7) 83#define IWL_DL_RADIO (1 << 7)
84#define IWL_DL_POWER (1<<8) 84#define IWL_DL_POWER (1 << 8)
85#define IWL_DL_TEMP (1<<9) 85#define IWL_DL_TEMP (1 << 9)
86 86
87#define IWL_DL_NOTIF (1<<10) 87#define IWL_DL_NOTIF (1 << 10)
88#define IWL_DL_SCAN (1<<11) 88#define IWL_DL_SCAN (1 << 11)
89#define IWL_DL_ASSOC (1<<12) 89#define IWL_DL_ASSOC (1 << 12)
90#define IWL_DL_DROP (1<<13) 90#define IWL_DL_DROP (1 << 13)
91 91
92#define IWL_DL_TXPOWER (1<<14) 92#define IWL_DL_TXPOWER (1 << 14)
93 93
94#define IWL_DL_AP (1<<15) 94#define IWL_DL_AP (1 << 15)
95 95
96#define IWL_DL_FW (1<<16) 96#define IWL_DL_FW (1 << 16)
97#define IWL_DL_RF_KILL (1<<17) 97#define IWL_DL_RF_KILL (1 << 17)
98#define IWL_DL_FW_ERRORS (1<<18) 98#define IWL_DL_FW_ERRORS (1 << 18)
99 99
100#define IWL_DL_LED (1<<19) 100#define IWL_DL_LED (1 << 19)
101 101
102#define IWL_DL_RATE (1<<20) 102#define IWL_DL_RATE (1 << 20)
103 103
104#define IWL_DL_CALIB (1<<21) 104#define IWL_DL_CALIB (1 << 21)
105#define IWL_DL_WEP (1<<22) 105#define IWL_DL_WEP (1 << 22)
106#define IWL_DL_TX (1<<23) 106#define IWL_DL_TX (1 << 23)
107#define IWL_DL_RX (1<<24) 107#define IWL_DL_RX (1 << 24)
108#define IWL_DL_ISR (1<<25) 108#define IWL_DL_ISR (1 << 25)
109#define IWL_DL_HT (1<<26) 109#define IWL_DL_HT (1 << 26)
110#define IWL_DL_IO (1<<27) 110#define IWL_DL_IO (1 << 27)
111#define IWL_DL_11H (1<<28) 111#define IWL_DL_11H (1 << 28)
112 112
113#define IWL_DL_STATS (1<<29) 113#define IWL_DL_STATS (1 << 29)
114#define IWL_DL_TX_REPLY (1<<30) 114#define IWL_DL_TX_REPLY (1 << 30)
115#define IWL_DL_QOS (1<<31) 115#define IWL_DL_QOS (1 << 31)
116 116
117#define IWL_ERROR(f, a...) printk(KERN_ERR DRV_NAME ": " f, ## a) 117#define IWL_ERROR(f, a...) printk(KERN_ERR DRV_NAME ": " f, ## a)
118#define IWL_WARNING(f, a...) printk(KERN_WARNING DRV_NAME ": " f, ## a) 118#define IWL_WARNING(f, a...) printk(KERN_WARNING DRV_NAME ": " f, ## a)
diff --git a/drivers/net/wireless/iwlwifi/iwl-3945-hw.h b/drivers/net/wireless/iwlwifi/iwl-3945-hw.h
index 2c955a6070f9..6e0187393af4 100644
--- a/drivers/net/wireless/iwlwifi/iwl-3945-hw.h
+++ b/drivers/net/wireless/iwlwifi/iwl-3945-hw.h
@@ -369,17 +369,17 @@ struct iwl3945_eeprom {
369 369
370/* interrupt flags in INTA, set by uCode or hardware (e.g. dma), 370/* interrupt flags in INTA, set by uCode or hardware (e.g. dma),
371 * acknowledged (reset) by host writing "1" to flagged bits. */ 371 * acknowledged (reset) by host writing "1" to flagged bits. */
372#define CSR_INT_BIT_FH_RX (1<<31) /* Rx DMA, cmd responses, FH_INT[17:16] */ 372#define CSR_INT_BIT_FH_RX (1 << 31) /* Rx DMA, cmd responses, FH_INT[17:16] */
373#define CSR_INT_BIT_HW_ERR (1<<29) /* DMA hardware error FH_INT[31] */ 373#define CSR_INT_BIT_HW_ERR (1 << 29) /* DMA hardware error FH_INT[31] */
374#define CSR_INT_BIT_DNLD (1<<28) /* uCode Download */ 374#define CSR_INT_BIT_DNLD (1 << 28) /* uCode Download */
375#define CSR_INT_BIT_FH_TX (1<<27) /* Tx DMA FH_INT[1:0] */ 375#define CSR_INT_BIT_FH_TX (1 << 27) /* Tx DMA FH_INT[1:0] */
376#define CSR_INT_BIT_MAC_CLK_ACTV (1<<26) /* NIC controller's clock toggled on/off */ 376#define CSR_INT_BIT_MAC_CLK_ACTV (1 << 26) /* NIC controller's clock toggled on/off */
377#define CSR_INT_BIT_SW_ERR (1<<25) /* uCode error */ 377#define CSR_INT_BIT_SW_ERR (1 << 25) /* uCode error */
378#define CSR_INT_BIT_RF_KILL (1<<7) /* HW RFKILL switch GP_CNTRL[27] toggled */ 378#define CSR_INT_BIT_RF_KILL (1 << 7) /* HW RFKILL switch GP_CNTRL[27] toggled */
379#define CSR_INT_BIT_CT_KILL (1<<6) /* Critical temp (chip too hot) rfkill */ 379#define CSR_INT_BIT_CT_KILL (1 << 6) /* Critical temp (chip too hot) rfkill */
380#define CSR_INT_BIT_SW_RX (1<<3) /* Rx, command responses, 3945 */ 380#define CSR_INT_BIT_SW_RX (1 << 3) /* Rx, command responses, 3945 */
381#define CSR_INT_BIT_WAKEUP (1<<1) /* NIC controller waking up (pwr mgmt) */ 381#define CSR_INT_BIT_WAKEUP (1 << 1) /* NIC controller waking up (pwr mgmt) */
382#define CSR_INT_BIT_ALIVE (1<<0) /* uCode interrupts once it initializes */ 382#define CSR_INT_BIT_ALIVE (1 << 0) /* uCode interrupts once it initializes */
383 383
384#define CSR_INI_SET_MASK (CSR_INT_BIT_FH_RX | \ 384#define CSR_INI_SET_MASK (CSR_INT_BIT_FH_RX | \
385 CSR_INT_BIT_HW_ERR | \ 385 CSR_INT_BIT_HW_ERR | \
@@ -391,14 +391,14 @@ struct iwl3945_eeprom {
391 CSR_INT_BIT_ALIVE) 391 CSR_INT_BIT_ALIVE)
392 392
393/* interrupt flags in FH (flow handler) (PCI busmaster DMA) */ 393/* interrupt flags in FH (flow handler) (PCI busmaster DMA) */
394#define CSR_FH_INT_BIT_ERR (1<<31) /* Error */ 394#define CSR_FH_INT_BIT_ERR (1 << 31) /* Error */
395#define CSR_FH_INT_BIT_HI_PRIOR (1<<30) /* High priority Rx, bypass coalescing */ 395#define CSR_FH_INT_BIT_HI_PRIOR (1 << 30) /* High priority Rx, bypass coalescing */
396#define CSR_FH_INT_BIT_RX_CHNL2 (1<<18) /* Rx channel 2 (3945 only) */ 396#define CSR_FH_INT_BIT_RX_CHNL2 (1 << 18) /* Rx channel 2 (3945 only) */
397#define CSR_FH_INT_BIT_RX_CHNL1 (1<<17) /* Rx channel 1 */ 397#define CSR_FH_INT_BIT_RX_CHNL1 (1 << 17) /* Rx channel 1 */
398#define CSR_FH_INT_BIT_RX_CHNL0 (1<<16) /* Rx channel 0 */ 398#define CSR_FH_INT_BIT_RX_CHNL0 (1 << 16) /* Rx channel 0 */
399#define CSR_FH_INT_BIT_TX_CHNL6 (1<<6) /* Tx channel 6 (3945 only) */ 399#define CSR_FH_INT_BIT_TX_CHNL6 (1 << 6) /* Tx channel 6 (3945 only) */
400#define CSR_FH_INT_BIT_TX_CHNL1 (1<<1) /* Tx channel 1 */ 400#define CSR_FH_INT_BIT_TX_CHNL1 (1 << 1) /* Tx channel 1 */
401#define CSR_FH_INT_BIT_TX_CHNL0 (1<<0) /* Tx channel 0 */ 401#define CSR_FH_INT_BIT_TX_CHNL0 (1 << 0) /* Tx channel 0 */
402 402
403#define CSR_FH_INT_RX_MASK (CSR_FH_INT_BIT_HI_PRIOR | \ 403#define CSR_FH_INT_RX_MASK (CSR_FH_INT_BIT_HI_PRIOR | \
404 CSR_FH_INT_BIT_RX_CHNL2 | \ 404 CSR_FH_INT_BIT_RX_CHNL2 | \
@@ -629,10 +629,10 @@ struct iwl3945_eeprom {
629 629
630#define U32_PAD(n) ((4-(n))&0x3) 630#define U32_PAD(n) ((4-(n))&0x3)
631 631
632#define TFD_CTL_COUNT_SET(n) (n<<24) 632#define TFD_CTL_COUNT_SET(n) (n << 24)
633#define TFD_CTL_COUNT_GET(ctl) ((ctl>>24) & 7) 633#define TFD_CTL_COUNT_GET(ctl) ((ctl >> 24) & 7)
634#define TFD_CTL_PAD_SET(n) (n<<28) 634#define TFD_CTL_PAD_SET(n) (n << 28)
635#define TFD_CTL_PAD_GET(ctl) (ctl>>28) 635#define TFD_CTL_PAD_GET(ctl) (ctl >> 28)
636 636
637#define TFD_TX_CMD_SLOTS 256 637#define TFD_TX_CMD_SLOTS 256
638#define TFD_CMD_SLOTS 32 638#define TFD_CMD_SLOTS 32
diff --git a/drivers/net/wireless/iwlwifi/iwl-3945-rs.h b/drivers/net/wireless/iwlwifi/iwl-3945-rs.h
index e21a5bae687f..d5e9220f871d 100644
--- a/drivers/net/wireless/iwlwifi/iwl-3945-rs.h
+++ b/drivers/net/wireless/iwlwifi/iwl-3945-rs.h
@@ -86,18 +86,18 @@ enum {
86}; 86};
87 87
88/* #define vs. enum to keep from defaulting to 'large integer' */ 88/* #define vs. enum to keep from defaulting to 'large integer' */
89#define IWL_RATE_6M_MASK (1<<IWL_RATE_6M_INDEX) 89#define IWL_RATE_6M_MASK (1 << IWL_RATE_6M_INDEX)
90#define IWL_RATE_9M_MASK (1<<IWL_RATE_9M_INDEX) 90#define IWL_RATE_9M_MASK (1 << IWL_RATE_9M_INDEX)
91#define IWL_RATE_12M_MASK (1<<IWL_RATE_12M_INDEX) 91#define IWL_RATE_12M_MASK (1 << IWL_RATE_12M_INDEX)
92#define IWL_RATE_18M_MASK (1<<IWL_RATE_18M_INDEX) 92#define IWL_RATE_18M_MASK (1 << IWL_RATE_18M_INDEX)
93#define IWL_RATE_24M_MASK (1<<IWL_RATE_24M_INDEX) 93#define IWL_RATE_24M_MASK (1 << IWL_RATE_24M_INDEX)
94#define IWL_RATE_36M_MASK (1<<IWL_RATE_36M_INDEX) 94#define IWL_RATE_36M_MASK (1 << IWL_RATE_36M_INDEX)
95#define IWL_RATE_48M_MASK (1<<IWL_RATE_48M_INDEX) 95#define IWL_RATE_48M_MASK (1 << IWL_RATE_48M_INDEX)
96#define IWL_RATE_54M_MASK (1<<IWL_RATE_54M_INDEX) 96#define IWL_RATE_54M_MASK (1 << IWL_RATE_54M_INDEX)
97#define IWL_RATE_1M_MASK (1<<IWL_RATE_1M_INDEX) 97#define IWL_RATE_1M_MASK (1 << IWL_RATE_1M_INDEX)
98#define IWL_RATE_2M_MASK (1<<IWL_RATE_2M_INDEX) 98#define IWL_RATE_2M_MASK (1 << IWL_RATE_2M_INDEX)
99#define IWL_RATE_5M_MASK (1<<IWL_RATE_5M_INDEX) 99#define IWL_RATE_5M_MASK (1 << IWL_RATE_5M_INDEX)
100#define IWL_RATE_11M_MASK (1<<IWL_RATE_11M_INDEX) 100#define IWL_RATE_11M_MASK (1 << IWL_RATE_11M_INDEX)
101 101
102/* 3945 uCode API values for (legacy) bit rates, both OFDM and CCK */ 102/* 3945 uCode API values for (legacy) bit rates, both OFDM and CCK */
103enum { 103enum {
@@ -157,7 +157,7 @@ enum {
157 (IWL_OFDM_BASIC_RATES_MASK | \ 157 (IWL_OFDM_BASIC_RATES_MASK | \
158 IWL_CCK_BASIC_RATES_MASK) 158 IWL_CCK_BASIC_RATES_MASK)
159 159
160#define IWL_RATES_MASK ((1<<IWL_RATE_COUNT)-1) 160#define IWL_RATES_MASK ((1 << IWL_RATE_COUNT) - 1)
161 161
162#define IWL_INVALID_VALUE -1 162#define IWL_INVALID_VALUE -1
163 163
diff --git a/drivers/net/wireless/iwlwifi/iwl-4965-commands.h b/drivers/net/wireless/iwlwifi/iwl-4965-commands.h
index 9237f8b3bb88..f3470c896d9a 100644
--- a/drivers/net/wireless/iwlwifi/iwl-4965-commands.h
+++ b/drivers/net/wireless/iwlwifi/iwl-4965-commands.h
@@ -492,18 +492,18 @@ enum {
492}; 492};
493 493
494 494
495#define RXON_RX_CHAIN_DRIVER_FORCE_MSK __constant_cpu_to_le16(0x1<<0) 495#define RXON_RX_CHAIN_DRIVER_FORCE_MSK __constant_cpu_to_le16(0x1 << 0)
496#define RXON_RX_CHAIN_VALID_MSK __constant_cpu_to_le16(0x7<<1) 496#define RXON_RX_CHAIN_VALID_MSK __constant_cpu_to_le16(0x7 << 1)
497#define RXON_RX_CHAIN_VALID_POS (1) 497#define RXON_RX_CHAIN_VALID_POS (1)
498#define RXON_RX_CHAIN_FORCE_SEL_MSK __constant_cpu_to_le16(0x7<<4) 498#define RXON_RX_CHAIN_FORCE_SEL_MSK __constant_cpu_to_le16(0x7 << 4)
499#define RXON_RX_CHAIN_FORCE_SEL_POS (4) 499#define RXON_RX_CHAIN_FORCE_SEL_POS (4)
500#define RXON_RX_CHAIN_FORCE_MIMO_SEL_MSK __constant_cpu_to_le16(0x7<<7) 500#define RXON_RX_CHAIN_FORCE_MIMO_SEL_MSK __constant_cpu_to_le16(0x7 << 7)
501#define RXON_RX_CHAIN_FORCE_MIMO_SEL_POS (7) 501#define RXON_RX_CHAIN_FORCE_MIMO_SEL_POS (7)
502#define RXON_RX_CHAIN_CNT_MSK __constant_cpu_to_le16(0x3<<10) 502#define RXON_RX_CHAIN_CNT_MSK __constant_cpu_to_le16(0x3 << 10)
503#define RXON_RX_CHAIN_CNT_POS (10) 503#define RXON_RX_CHAIN_CNT_POS (10)
504#define RXON_RX_CHAIN_MIMO_CNT_MSK __constant_cpu_to_le16(0x3<<12) 504#define RXON_RX_CHAIN_MIMO_CNT_MSK __constant_cpu_to_le16(0x3 << 12)
505#define RXON_RX_CHAIN_MIMO_CNT_POS (12) 505#define RXON_RX_CHAIN_MIMO_CNT_POS (12)
506#define RXON_RX_CHAIN_MIMO_FORCE_MSK __constant_cpu_to_le16(0x1<<14) 506#define RXON_RX_CHAIN_MIMO_FORCE_MSK __constant_cpu_to_le16(0x1 << 14)
507#define RXON_RX_CHAIN_MIMO_FORCE_POS (14) 507#define RXON_RX_CHAIN_MIMO_FORCE_POS (14)
508 508
509/* rx_config flags */ 509/* rx_config flags */
@@ -532,17 +532,17 @@ enum {
532 532
533/* HT flags */ 533/* HT flags */
534#define RXON_FLG_CTRL_CHANNEL_LOC_POS (22) 534#define RXON_FLG_CTRL_CHANNEL_LOC_POS (22)
535#define RXON_FLG_CTRL_CHANNEL_LOC_HI_MSK __constant_cpu_to_le32(0x1<<22) 535#define RXON_FLG_CTRL_CHANNEL_LOC_HI_MSK __constant_cpu_to_le32(0x1 << 22)
536 536
537#define RXON_FLG_HT_OPERATING_MODE_POS (23) 537#define RXON_FLG_HT_OPERATING_MODE_POS (23)
538 538
539#define RXON_FLG_HT_PROT_MSK __constant_cpu_to_le32(0x1<<23) 539#define RXON_FLG_HT_PROT_MSK __constant_cpu_to_le32(0x1 << 23)
540#define RXON_FLG_FAT_PROT_MSK __constant_cpu_to_le32(0x2<<23) 540#define RXON_FLG_FAT_PROT_MSK __constant_cpu_to_le32(0x2 << 23)
541 541
542#define RXON_FLG_CHANNEL_MODE_POS (25) 542#define RXON_FLG_CHANNEL_MODE_POS (25)
543#define RXON_FLG_CHANNEL_MODE_MSK __constant_cpu_to_le32(0x3<<25) 543#define RXON_FLG_CHANNEL_MODE_MSK __constant_cpu_to_le32(0x3 << 25)
544#define RXON_FLG_CHANNEL_MODE_PURE_40_MSK __constant_cpu_to_le32(0x1<<25) 544#define RXON_FLG_CHANNEL_MODE_PURE_40_MSK __constant_cpu_to_le32(0x1 << 25)
545#define RXON_FLG_CHANNEL_MODE_MIXED_MSK __constant_cpu_to_le32(0x2<<25) 545#define RXON_FLG_CHANNEL_MODE_MIXED_MSK __constant_cpu_to_le32(0x2 << 25)
546 546
547/* rx_config filter flags */ 547/* rx_config filter flags */
548/* accept all data frames */ 548/* accept all data frames */
@@ -713,7 +713,7 @@ struct iwl4965_qosparam_cmd {
713#define IWL_STATION_COUNT 32 /* MAX(3945,4965)*/ 713#define IWL_STATION_COUNT 32 /* MAX(3945,4965)*/
714#define IWL_INVALID_STATION 255 714#define IWL_INVALID_STATION 255
715 715
716#define STA_FLG_PWR_SAVE_MSK __constant_cpu_to_le32(1<<8); 716#define STA_FLG_PWR_SAVE_MSK __constant_cpu_to_le32(1 << 8);
717#define STA_FLG_RTS_MIMO_PROT_MSK __constant_cpu_to_le32(1 << 17) 717#define STA_FLG_RTS_MIMO_PROT_MSK __constant_cpu_to_le32(1 << 17)
718#define STA_FLG_AGG_MPDU_8US_MSK __constant_cpu_to_le32(1 << 18) 718#define STA_FLG_AGG_MPDU_8US_MSK __constant_cpu_to_le32(1 << 18)
719#define STA_FLG_MAX_AGG_SIZE_POS (19) 719#define STA_FLG_MAX_AGG_SIZE_POS (19)
@@ -1333,7 +1333,7 @@ struct iwl4965_txpowertable_cmd {
1333} __attribute__ ((packed)); 1333} __attribute__ ((packed));
1334 1334
1335/*RS_NEW_API: only TLC_RTS remains and moved to bit 0 */ 1335/*RS_NEW_API: only TLC_RTS remains and moved to bit 0 */
1336#define LINK_QUAL_FLAGS_SET_STA_TLC_RTS_MSK (1<<0) 1336#define LINK_QUAL_FLAGS_SET_STA_TLC_RTS_MSK (1 << 0)
1337 1337
1338/* # of EDCA prioritized tx fifos */ 1338/* # of EDCA prioritized tx fifos */
1339#define LINK_QUAL_AC_NUM AC_NUM 1339#define LINK_QUAL_AC_NUM AC_NUM
@@ -1342,8 +1342,8 @@ struct iwl4965_txpowertable_cmd {
1342#define LINK_QUAL_MAX_RETRY_NUM 16 1342#define LINK_QUAL_MAX_RETRY_NUM 16
1343 1343
1344/* Tx antenna selection values */ 1344/* Tx antenna selection values */
1345#define LINK_QUAL_ANT_A_MSK (1<<0) 1345#define LINK_QUAL_ANT_A_MSK (1 << 0)
1346#define LINK_QUAL_ANT_B_MSK (1<<1) 1346#define LINK_QUAL_ANT_B_MSK (1 << 1)
1347#define LINK_QUAL_ANT_MSK (LINK_QUAL_ANT_A_MSK|LINK_QUAL_ANT_B_MSK) 1347#define LINK_QUAL_ANT_MSK (LINK_QUAL_ANT_A_MSK|LINK_QUAL_ANT_B_MSK)
1348 1348
1349 1349
@@ -1785,9 +1785,9 @@ struct iwl4965_spectrum_notification {
1785 */ 1785 */
1786#define IWL_POWER_VEC_SIZE 5 1786#define IWL_POWER_VEC_SIZE 5
1787 1787
1788#define IWL_POWER_DRIVER_ALLOW_SLEEP_MSK __constant_cpu_to_le16(1<<0) 1788#define IWL_POWER_DRIVER_ALLOW_SLEEP_MSK __constant_cpu_to_le16(1 << 0)
1789#define IWL_POWER_SLEEP_OVER_DTIM_MSK __constant_cpu_to_le16(1<<2) 1789#define IWL_POWER_SLEEP_OVER_DTIM_MSK __constant_cpu_to_le16(1 << 2)
1790#define IWL_POWER_PCI_PM_MSK __constant_cpu_to_le16(1<<3) 1790#define IWL_POWER_PCI_PM_MSK __constant_cpu_to_le16(1 << 3)
1791 1791
1792struct iwl4965_powertable_cmd { 1792struct iwl4965_powertable_cmd {
1793 __le16 flags; 1793 __le16 flags;
diff --git a/drivers/net/wireless/iwlwifi/iwl-4965-debug.h b/drivers/net/wireless/iwlwifi/iwl-4965-debug.h
index 00bc1faece92..36696bbf170c 100644
--- a/drivers/net/wireless/iwlwifi/iwl-4965-debug.h
+++ b/drivers/net/wireless/iwlwifi/iwl-4965-debug.h
@@ -75,44 +75,44 @@ static inline void IWL_DEBUG_LIMIT(int level, const char *fmt, ...)
75 * 75 *
76 */ 76 */
77 77
78#define IWL_DL_INFO (1<<0) 78#define IWL_DL_INFO (1 << 0)
79#define IWL_DL_MAC80211 (1<<1) 79#define IWL_DL_MAC80211 (1 << 1)
80#define IWL_DL_HOST_COMMAND (1<<2) 80#define IWL_DL_HOST_COMMAND (1 << 2)
81#define IWL_DL_STATE (1<<3) 81#define IWL_DL_STATE (1 << 3)
82 82
83#define IWL_DL_RADIO (1<<7) 83#define IWL_DL_RADIO (1 << 7)
84#define IWL_DL_POWER (1<<8) 84#define IWL_DL_POWER (1 << 8)
85#define IWL_DL_TEMP (1<<9) 85#define IWL_DL_TEMP (1 << 9)
86 86
87#define IWL_DL_NOTIF (1<<10) 87#define IWL_DL_NOTIF (1 << 10)
88#define IWL_DL_SCAN (1<<11) 88#define IWL_DL_SCAN (1 << 11)
89#define IWL_DL_ASSOC (1<<12) 89#define IWL_DL_ASSOC (1 << 12)
90#define IWL_DL_DROP (1<<13) 90#define IWL_DL_DROP (1 << 13)
91 91
92#define IWL_DL_TXPOWER (1<<14) 92#define IWL_DL_TXPOWER (1 << 14)
93 93
94#define IWL_DL_AP (1<<15) 94#define IWL_DL_AP (1 << 15)
95 95
96#define IWL_DL_FW (1<<16) 96#define IWL_DL_FW (1 << 16)
97#define IWL_DL_RF_KILL (1<<17) 97#define IWL_DL_RF_KILL (1 << 17)
98#define IWL_DL_FW_ERRORS (1<<18) 98#define IWL_DL_FW_ERRORS (1 << 18)
99 99
100#define IWL_DL_LED (1<<19) 100#define IWL_DL_LED (1 << 19)
101 101
102#define IWL_DL_RATE (1<<20) 102#define IWL_DL_RATE (1 << 20)
103 103
104#define IWL_DL_CALIB (1<<21) 104#define IWL_DL_CALIB (1 << 21)
105#define IWL_DL_WEP (1<<22) 105#define IWL_DL_WEP (1 << 22)
106#define IWL_DL_TX (1<<23) 106#define IWL_DL_TX (1 << 23)
107#define IWL_DL_RX (1<<24) 107#define IWL_DL_RX (1 << 24)
108#define IWL_DL_ISR (1<<25) 108#define IWL_DL_ISR (1 << 25)
109#define IWL_DL_HT (1<<26) 109#define IWL_DL_HT (1 << 26)
110#define IWL_DL_IO (1<<27) 110#define IWL_DL_IO (1 << 27)
111#define IWL_DL_11H (1<<28) 111#define IWL_DL_11H (1 << 28)
112 112
113#define IWL_DL_STATS (1<<29) 113#define IWL_DL_STATS (1 << 29)
114#define IWL_DL_TX_REPLY (1<<30) 114#define IWL_DL_TX_REPLY (1 << 30)
115#define IWL_DL_QOS (1<<31) 115#define IWL_DL_QOS (1 << 31)
116 116
117#define IWL_ERROR(f, a...) printk(KERN_ERR DRV_NAME ": " f, ## a) 117#define IWL_ERROR(f, a...) printk(KERN_ERR DRV_NAME ": " f, ## a)
118#define IWL_WARNING(f, a...) printk(KERN_WARNING DRV_NAME ": " f, ## a) 118#define IWL_WARNING(f, a...) printk(KERN_WARNING DRV_NAME ": " f, ## a)
diff --git a/drivers/net/wireless/iwlwifi/iwl-4965-hw.h b/drivers/net/wireless/iwlwifi/iwl-4965-hw.h
index 7e7d6e497e0f..ff71c09ab1a7 100644
--- a/drivers/net/wireless/iwlwifi/iwl-4965-hw.h
+++ b/drivers/net/wireless/iwlwifi/iwl-4965-hw.h
@@ -461,17 +461,17 @@ struct iwl4965_eeprom {
461 461
462/* interrupt flags in INTA, set by uCode or hardware (e.g. dma), 462/* interrupt flags in INTA, set by uCode or hardware (e.g. dma),
463 * acknowledged (reset) by host writing "1" to flagged bits. */ 463 * acknowledged (reset) by host writing "1" to flagged bits. */
464#define CSR_INT_BIT_FH_RX (1<<31) /* Rx DMA, cmd responses, FH_INT[17:16] */ 464#define CSR_INT_BIT_FH_RX (1 << 31) /* Rx DMA, cmd responses, FH_INT[17:16] */
465#define CSR_INT_BIT_HW_ERR (1<<29) /* DMA hardware error FH_INT[31] */ 465#define CSR_INT_BIT_HW_ERR (1 << 29) /* DMA hardware error FH_INT[31] */
466#define CSR_INT_BIT_DNLD (1<<28) /* uCode Download */ 466#define CSR_INT_BIT_DNLD (1 << 28) /* uCode Download */
467#define CSR_INT_BIT_FH_TX (1<<27) /* Tx DMA FH_INT[1:0] */ 467#define CSR_INT_BIT_FH_TX (1 << 27) /* Tx DMA FH_INT[1:0] */
468#define CSR_INT_BIT_MAC_CLK_ACTV (1<<26) /* NIC controller's clock toggled on/off */ 468#define CSR_INT_BIT_MAC_CLK_ACTV (1 << 26) /* NIC controller's clock toggled on/off */
469#define CSR_INT_BIT_SW_ERR (1<<25) /* uCode error */ 469#define CSR_INT_BIT_SW_ERR (1 << 25) /* uCode error */
470#define CSR_INT_BIT_RF_KILL (1<<7) /* HW RFKILL switch GP_CNTRL[27] toggled */ 470#define CSR_INT_BIT_RF_KILL (1 << 7) /* HW RFKILL switch GP_CNTRL[27] toggled */
471#define CSR_INT_BIT_CT_KILL (1<<6) /* Critical temp (chip too hot) rfkill */ 471#define CSR_INT_BIT_CT_KILL (1 << 6) /* Critical temp (chip too hot) rfkill */
472#define CSR_INT_BIT_SW_RX (1<<3) /* Rx, command responses, 3945 */ 472#define CSR_INT_BIT_SW_RX (1 << 3) /* Rx, command responses, 3945 */
473#define CSR_INT_BIT_WAKEUP (1<<1) /* NIC controller waking up (pwr mgmt) */ 473#define CSR_INT_BIT_WAKEUP (1 << 1) /* NIC controller waking up (pwr mgmt) */
474#define CSR_INT_BIT_ALIVE (1<<0) /* uCode interrupts once it initializes */ 474#define CSR_INT_BIT_ALIVE (1 << 0) /* uCode interrupts once it initializes */
475 475
476#define CSR_INI_SET_MASK (CSR_INT_BIT_FH_RX | \ 476#define CSR_INI_SET_MASK (CSR_INT_BIT_FH_RX | \
477 CSR_INT_BIT_HW_ERR | \ 477 CSR_INT_BIT_HW_ERR | \
@@ -483,12 +483,12 @@ struct iwl4965_eeprom {
483 CSR_INT_BIT_ALIVE) 483 CSR_INT_BIT_ALIVE)
484 484
485/* interrupt flags in FH (flow handler) (PCI busmaster DMA) */ 485/* interrupt flags in FH (flow handler) (PCI busmaster DMA) */
486#define CSR_FH_INT_BIT_ERR (1<<31) /* Error */ 486#define CSR_FH_INT_BIT_ERR (1 << 31) /* Error */
487#define CSR_FH_INT_BIT_HI_PRIOR (1<<30) /* High priority Rx, bypass coalescing */ 487#define CSR_FH_INT_BIT_HI_PRIOR (1 << 30) /* High priority Rx, bypass coalescing */
488#define CSR_FH_INT_BIT_RX_CHNL1 (1<<17) /* Rx channel 1 */ 488#define CSR_FH_INT_BIT_RX_CHNL1 (1 << 17) /* Rx channel 1 */
489#define CSR_FH_INT_BIT_RX_CHNL0 (1<<16) /* Rx channel 0 */ 489#define CSR_FH_INT_BIT_RX_CHNL0 (1 << 16) /* Rx channel 0 */
490#define CSR_FH_INT_BIT_TX_CHNL1 (1<<1) /* Tx channel 1 */ 490#define CSR_FH_INT_BIT_TX_CHNL1 (1 << 1) /* Tx channel 1 */
491#define CSR_FH_INT_BIT_TX_CHNL0 (1<<0) /* Tx channel 0 */ 491#define CSR_FH_INT_BIT_TX_CHNL0 (1 << 0) /* Tx channel 0 */
492 492
493#define CSR_FH_INT_RX_MASK (CSR_FH_INT_BIT_HI_PRIOR | \ 493#define CSR_FH_INT_RX_MASK (CSR_FH_INT_BIT_HI_PRIOR | \
494 CSR_FH_INT_BIT_RX_CHNL1 | \ 494 CSR_FH_INT_BIT_RX_CHNL1 | \
@@ -1683,7 +1683,7 @@ enum {
1683 1683
1684/* Mask to enable contiguous Tx DMA/FIFO channels between "lo" and "hi". */ 1684/* Mask to enable contiguous Tx DMA/FIFO channels between "lo" and "hi". */
1685#define SCD_TXFACT_REG_TXFIFO_MASK(lo, hi) \ 1685#define SCD_TXFACT_REG_TXFIFO_MASK(lo, hi) \
1686 ((1<<(hi))|((1<<(hi))-(1<<(lo)))) 1686 ((1 << (hi)) | ((1 << (hi)) - (1 << (lo))))
1687 1687
1688/* 1688/*
1689 * Queue (x) Write Pointers (indexes, really!), one for each Tx queue. 1689 * Queue (x) Write Pointers (indexes, really!), one for each Tx queue.
diff --git a/drivers/net/wireless/iwlwifi/iwl-4965-rs.h b/drivers/net/wireless/iwlwifi/iwl-4965-rs.h
index 31e21e29bbad..55f707382787 100644
--- a/drivers/net/wireless/iwlwifi/iwl-4965-rs.h
+++ b/drivers/net/wireless/iwlwifi/iwl-4965-rs.h
@@ -73,19 +73,19 @@ enum {
73}; 73};
74 74
75/* #define vs. enum to keep from defaulting to 'large integer' */ 75/* #define vs. enum to keep from defaulting to 'large integer' */
76#define IWL_RATE_6M_MASK (1<<IWL_RATE_6M_INDEX) 76#define IWL_RATE_6M_MASK (1 << IWL_RATE_6M_INDEX)
77#define IWL_RATE_9M_MASK (1<<IWL_RATE_9M_INDEX) 77#define IWL_RATE_9M_MASK (1 << IWL_RATE_9M_INDEX)
78#define IWL_RATE_12M_MASK (1<<IWL_RATE_12M_INDEX) 78#define IWL_RATE_12M_MASK (1 << IWL_RATE_12M_INDEX)
79#define IWL_RATE_18M_MASK (1<<IWL_RATE_18M_INDEX) 79#define IWL_RATE_18M_MASK (1 << IWL_RATE_18M_INDEX)
80#define IWL_RATE_24M_MASK (1<<IWL_RATE_24M_INDEX) 80#define IWL_RATE_24M_MASK (1 << IWL_RATE_24M_INDEX)
81#define IWL_RATE_36M_MASK (1<<IWL_RATE_36M_INDEX) 81#define IWL_RATE_36M_MASK (1 << IWL_RATE_36M_INDEX)
82#define IWL_RATE_48M_MASK (1<<IWL_RATE_48M_INDEX) 82#define IWL_RATE_48M_MASK (1 << IWL_RATE_48M_INDEX)
83#define IWL_RATE_54M_MASK (1<<IWL_RATE_54M_INDEX) 83#define IWL_RATE_54M_MASK (1 << IWL_RATE_54M_INDEX)
84#define IWL_RATE_60M_MASK (1<<IWL_RATE_60M_INDEX) 84#define IWL_RATE_60M_MASK (1 << IWL_RATE_60M_INDEX)
85#define IWL_RATE_1M_MASK (1<<IWL_RATE_1M_INDEX) 85#define IWL_RATE_1M_MASK (1 << IWL_RATE_1M_INDEX)
86#define IWL_RATE_2M_MASK (1<<IWL_RATE_2M_INDEX) 86#define IWL_RATE_2M_MASK (1 << IWL_RATE_2M_INDEX)
87#define IWL_RATE_5M_MASK (1<<IWL_RATE_5M_INDEX) 87#define IWL_RATE_5M_MASK (1 << IWL_RATE_5M_INDEX)
88#define IWL_RATE_11M_MASK (1<<IWL_RATE_11M_INDEX) 88#define IWL_RATE_11M_MASK (1 << IWL_RATE_11M_INDEX)
89 89
90/* 4965 uCode API values for legacy bit rates, both OFDM and CCK */ 90/* 4965 uCode API values for legacy bit rates, both OFDM and CCK */
91enum { 91enum {
@@ -169,7 +169,7 @@ enum {
169 (IWL_OFDM_BASIC_RATES_MASK | \ 169 (IWL_OFDM_BASIC_RATES_MASK | \
170 IWL_CCK_BASIC_RATES_MASK) 170 IWL_CCK_BASIC_RATES_MASK)
171 171
172#define IWL_RATES_MASK ((1<<IWL_RATE_COUNT)-1) 172#define IWL_RATES_MASK ((1 << IWL_RATE_COUNT) - 1)
173 173
174#define IWL_INVALID_VALUE -1 174#define IWL_INVALID_VALUE -1
175 175
diff --git a/drivers/net/wireless/iwlwifi/iwl-4965.c b/drivers/net/wireless/iwlwifi/iwl-4965.c
index 5fcc2a6f5bf4..04db34ba814b 100644
--- a/drivers/net/wireless/iwlwifi/iwl-4965.c
+++ b/drivers/net/wireless/iwlwifi/iwl-4965.c
@@ -815,11 +815,11 @@ static int iwl4965_sens_energy_cck(struct iwl4965_priv *priv,
815 * This is background noise, which may include transmissions from other 815 * This is background noise, which may include transmissions from other
816 * networks, measured during silence before our network's beacon */ 816 * networks, measured during silence before our network's beacon */
817 silence_rssi_a = (u8)((rx_info->beacon_silence_rssi_a & 817 silence_rssi_a = (u8)((rx_info->beacon_silence_rssi_a &
818 ALL_BAND_FILTER)>>8); 818 ALL_BAND_FILTER) >> 8);
819 silence_rssi_b = (u8)((rx_info->beacon_silence_rssi_b & 819 silence_rssi_b = (u8)((rx_info->beacon_silence_rssi_b &
820 ALL_BAND_FILTER)>>8); 820 ALL_BAND_FILTER) >> 8);
821 silence_rssi_c = (u8)((rx_info->beacon_silence_rssi_c & 821 silence_rssi_c = (u8)((rx_info->beacon_silence_rssi_c &
822 ALL_BAND_FILTER)>>8); 822 ALL_BAND_FILTER) >> 8);
823 823
824 val = max(silence_rssi_b, silence_rssi_c); 824 val = max(silence_rssi_b, silence_rssi_c);
825 max_silence_rssi = max(silence_rssi_a, (u8) val); 825 max_silence_rssi = max(silence_rssi_a, (u8) val);
@@ -4233,14 +4233,14 @@ static int iwl4965_tx_status_reply_compressed_ba(struct iwl4965_priv *priv,
4233 IWL_DEBUG_TX_REPLY("BA %d %d\n", agg->start_idx, ba_resp->ba_seq_ctl); 4233 IWL_DEBUG_TX_REPLY("BA %d %d\n", agg->start_idx, ba_resp->ba_seq_ctl);
4234 4234
4235 /* Calculate shift to align block-ack bits with our Tx window bits */ 4235 /* Calculate shift to align block-ack bits with our Tx window bits */
4236 sh = agg->start_idx - SEQ_TO_INDEX(ba_seq_ctl>>4); 4236 sh = agg->start_idx - SEQ_TO_INDEX(ba_seq_ctl >> 4);
4237 if (sh < 0) /* tbw something is wrong with indices */ 4237 if (sh < 0) /* tbw something is wrong with indices */
4238 sh += 0x100; 4238 sh += 0x100;
4239 4239
4240 /* don't use 64-bit values for now */ 4240 /* don't use 64-bit values for now */
4241 bitmap0 = resp_bitmap0 >> sh; 4241 bitmap0 = resp_bitmap0 >> sh;
4242 bitmap1 = resp_bitmap1 >> sh; 4242 bitmap1 = resp_bitmap1 >> sh;
4243 bitmap0 |= (resp_bitmap1 & ((1<<sh)|((1<<sh)-1))) << (32 - sh); 4243 bitmap0 |= (resp_bitmap1 & ((1 << sh) | ((1 << sh) - 1))) << (32 - sh);
4244 4244
4245 if (agg->frame_count > (64 - sh)) { 4245 if (agg->frame_count > (64 - sh)) {
4246 IWL_DEBUG_TX_REPLY("more frames than bitmap size"); 4246 IWL_DEBUG_TX_REPLY("more frames than bitmap size");
@@ -4425,7 +4425,7 @@ static int iwl4965_tx_queue_agg_enable(struct iwl4965_priv *priv, int txq_id,
4425 iwl4965_tx_queue_set_q2ratid(priv, ra_tid, txq_id); 4425 iwl4965_tx_queue_set_q2ratid(priv, ra_tid, txq_id);
4426 4426
4427 /* Set this queue as a chain-building queue */ 4427 /* Set this queue as a chain-building queue */
4428 iwl4965_set_bits_prph(priv, KDR_SCD_QUEUECHAIN_SEL, (1<<txq_id)); 4428 iwl4965_set_bits_prph(priv, KDR_SCD_QUEUECHAIN_SEL, (1 << txq_id));
4429 4429
4430 /* Place first TFD at index corresponding to start sequence number. 4430 /* Place first TFD at index corresponding to start sequence number.
4431 * Assumes that ssn_idx is valid (!= 0xFFF) */ 4431 * Assumes that ssn_idx is valid (!= 0xFFF) */
diff --git a/drivers/net/wireless/iwlwifi/iwl3945-base.c b/drivers/net/wireless/iwlwifi/iwl3945-base.c
index 5b9dbddce55e..748ac1222abb 100644
--- a/drivers/net/wireless/iwlwifi/iwl3945-base.c
+++ b/drivers/net/wireless/iwlwifi/iwl3945-base.c
@@ -5267,7 +5267,7 @@ static int iwl3945_get_channels_for_scan(struct iwl3945_priv *priv, int phymode,
5267 scan_ch->tpc.tx_gain = ((1 << 5) | (5 << 3)); 5267 scan_ch->tpc.tx_gain = ((1 << 5) | (5 << 3));
5268 /* NOTE: if we were doing 6Mb OFDM for scans we'd use 5268 /* NOTE: if we were doing 6Mb OFDM for scans we'd use
5269 * power level: 5269 * power level:
5270 * scan_ch->tpc.tx_gain = ((1<<5) | (2 << 3)) | 3; 5270 * scan_ch->tpc.tx_gain = ((1 << 5) | (2 << 3)) | 3;
5271 */ 5271 */
5272 } 5272 }
5273 5273
diff --git a/drivers/net/wireless/iwlwifi/iwl4965-base.c b/drivers/net/wireless/iwlwifi/iwl4965-base.c
index e34a477c8e3f..c86da5cd1df1 100644
--- a/drivers/net/wireless/iwlwifi/iwl4965-base.c
+++ b/drivers/net/wireless/iwlwifi/iwl4965-base.c
@@ -5698,7 +5698,7 @@ static int iwl4965_get_channels_for_scan(struct iwl4965_priv *priv, int phymode,
5698 scan_ch->tpc.tx_gain = ((1 << 5) | (5 << 3)); 5698 scan_ch->tpc.tx_gain = ((1 << 5) | (5 << 3));
5699 /* NOTE: if we were doing 6Mb OFDM for scans we'd use 5699 /* NOTE: if we were doing 6Mb OFDM for scans we'd use
5700 * power level: 5700 * power level:
5701 * scan_ch->tpc.tx_gain = ((1<<5) | (2 << 3)) | 3; 5701 * scan_ch->tpc.tx_gain = ((1 << 5) | (2 << 3)) | 3;
5702 */ 5702 */
5703 } 5703 }
5704 5704