aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJustin P. Mattock <justinmattock@gmail.com>2010-11-08 16:41:46 -0500
committerGreg Kroah-Hartman <gregkh@suse.de>2010-11-09 19:43:01 -0500
commit6ccb5d7c62845788be9aafef26132333a07708bb (patch)
tree369b3078487b825a00821ea6f358c43f7cf7026e
parent1ac586445db8e46f0007855c5c7161ff55484836 (diff)
staging: Fix typos in rt2860
Here is a patch that fixes some typos, and comments in drivers/staging/rt2860 Signed-off-by: Justin P. Mattock <justinmattock@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
-rw-r--r--drivers/staging/rt2860/chip/mac_pci.h7
-rw-r--r--drivers/staging/rt2860/chip/mac_usb.h5
-rw-r--r--drivers/staging/rt2860/chip/rtmp_mac.h19
-rw-r--r--drivers/staging/rt2860/chips/rt3090.c5
-rw-r--r--drivers/staging/rt2860/chips/rt30xx.c9
-rw-r--r--drivers/staging/rt2860/mlme.h41
-rw-r--r--drivers/staging/rt2860/oid.h13
-rw-r--r--drivers/staging/rt2860/pci_main_dev.c17
-rw-r--r--drivers/staging/rt2860/rt_linux.c12
-rw-r--r--drivers/staging/rt2860/rt_linux.h5
-rw-r--r--drivers/staging/rt2860/rt_main_dev.c9
-rw-r--r--drivers/staging/rt2860/rt_pci_rbus.c7
-rw-r--r--drivers/staging/rt2860/rt_usb.c13
-rw-r--r--drivers/staging/rt2860/rtmp.h69
-rw-r--r--drivers/staging/rt2860/rtmp_def.h37
-rw-r--r--drivers/staging/rt2860/rtmp_timer.h13
-rw-r--r--drivers/staging/rt2860/spectrum.h12
-rw-r--r--drivers/staging/rt2860/sta/assoc.c13
-rw-r--r--drivers/staging/rt2860/sta/auth.c7
-rw-r--r--drivers/staging/rt2860/sta/connect.c35
-rw-r--r--drivers/staging/rt2860/sta/rtmp_data.c33
-rw-r--r--drivers/staging/rt2860/sta/sanity.c5
-rw-r--r--drivers/staging/rt2860/sta/sync.c19
-rw-r--r--drivers/staging/rt2860/sta/wpa.c5
-rw-r--r--drivers/staging/rt2860/sta_ioctl.c25
-rw-r--r--drivers/staging/rt2860/usb_main_dev.c8
-rw-r--r--drivers/staging/rt2860/wpa.h5
27 files changed, 236 insertions, 212 deletions
diff --git a/drivers/staging/rt2860/chip/mac_pci.h b/drivers/staging/rt2860/chip/mac_pci.h
index 9f25ef047f5..b8868a5b9e0 100644
--- a/drivers/staging/rt2860/chip/mac_pci.h
+++ b/drivers/staging/rt2860/chip/mac_pci.h
@@ -30,7 +30,8 @@
30 Abstract: 30 Abstract:
31 31
32 Revision History: 32 Revision History:
33 Who When What 33 Who When What
34 Justin P. Mattock 11/07/2010 Fix some typos
34 --------- ---------- ---------------------------------------------- 35 --------- ---------- ----------------------------------------------
35 */ 36 */
36 37
@@ -45,7 +46,7 @@
45 46
46/* */ 47/* */
47/* Device ID & Vendor ID related definitions, */ 48/* Device ID & Vendor ID related definitions, */
48/* NOTE: you should not add the new VendorID/DeviceID here unless you not sure it belongs to what chip. */ 49/* NOTE: you should not add the new VendorID/DeviceID here unless you know for sure what chip it belongs too. */
49/* */ 50/* */
50#define NIC_PCI_VENDOR_ID 0x1814 51#define NIC_PCI_VENDOR_ID 0x1814
51#define PCIBUS_INTEL_VENDOR 0x8086 52#define PCIBUS_INTEL_VENDOR 0x8086
@@ -83,7 +84,7 @@ struct PACKED rt_txd {
83 u32 SDPtr1; 84 u32 SDPtr1;
84 /*Word3 */ 85 /*Word3 */
85 u32 rsv2:24; 86 u32 rsv2:24;
86 u32 WIV:1; /* Wireless Info Valid. 1 if Driver already fill WI, o if DMA needs to copy WI to correctposition */ 87 u32 WIV:1; /* Wireless Info Valid. 1 if Driver already fill WI, o if DMA needs to copy WI to correct position */
87 u32 QSEL:2; /* select on-chip FIFO ID for 2nd-stage output scheduler.0:MGMT, 1:HCCA 2:EDCA */ 88 u32 QSEL:2; /* select on-chip FIFO ID for 2nd-stage output scheduler.0:MGMT, 1:HCCA 2:EDCA */
88 u32 rsv:2; 89 u32 rsv:2;
89 u32 TCO:1; /* */ 90 u32 TCO:1; /* */
diff --git a/drivers/staging/rt2860/chip/mac_usb.h b/drivers/staging/rt2860/chip/mac_usb.h
index ed0c0b43b05..e8158fb5864 100644
--- a/drivers/staging/rt2860/chip/mac_usb.h
+++ b/drivers/staging/rt2860/chip/mac_usb.h
@@ -30,7 +30,8 @@
30 Abstract: 30 Abstract:
31 31
32 Revision History: 32 Revision History:
33 Who When What 33 Who When What
34 Justin P. Mattock 11/07/2010 Fix a typo
34 --------- ---------- ---------------------------------------------- 35 --------- ---------- ----------------------------------------------
35 */ 36 */
36 37
@@ -93,7 +94,7 @@ struct rt_txinfo {
93 /* Word 0 */ 94 /* Word 0 */
94 u32 USBDMATxPktLen:16; /*used ONLY in USB bulk Aggregation, Total byte counts of all sub-frame. */ 95 u32 USBDMATxPktLen:16; /*used ONLY in USB bulk Aggregation, Total byte counts of all sub-frame. */
95 u32 rsv:8; 96 u32 rsv:8;
96 u32 WIV:1; /* Wireless Info Valid. 1 if Driver already fill WI, o if DMA needs to copy WI to correctposition */ 97 u32 WIV:1; /* Wireless Info Valid. 1 if Driver already fill WI, o if DMA needs to copy WI to correct position */
97 u32 QSEL:2; /* select on-chip FIFO ID for 2nd-stage output scheduler.0:MGMT, 1:HCCA 2:EDCA */ 98 u32 QSEL:2; /* select on-chip FIFO ID for 2nd-stage output scheduler.0:MGMT, 1:HCCA 2:EDCA */
98 u32 SwUseLastRound:1; /* Software use. */ 99 u32 SwUseLastRound:1; /* Software use. */
99 u32 rsv2:2; /* Software use. */ 100 u32 rsv2:2; /* Software use. */
diff --git a/drivers/staging/rt2860/chip/rtmp_mac.h b/drivers/staging/rt2860/chip/rtmp_mac.h
index e8f7172ce42..3d1e4915b95 100644
--- a/drivers/staging/rt2860/chip/rtmp_mac.h
+++ b/drivers/staging/rt2860/chip/rtmp_mac.h
@@ -32,6 +32,7 @@
32 32
33 Revision History: 33 Revision History:
34 Who When What 34 Who When What
35 Justin P. Mattock 11/07/2010 Fix a comments, and typos
35 -------- ---------- ---------------------------------------------- 36 -------- ---------- ----------------------------------------------
36*/ 37*/
37 38
@@ -43,7 +44,7 @@
43/* ================================================================================= */ 44/* ================================================================================= */
44 45
45/* the first 24-byte in TXD is called TXINFO and will be DMAed to MAC block through TXFIFO. */ 46/* the first 24-byte in TXD is called TXINFO and will be DMAed to MAC block through TXFIFO. */
46/* MAC block use this TXINFO to control the transmission behavior of this frame. */ 47/* MAC block uses this TXINFO to control the transmission behavior of this frame. */
47#define FIFO_MGMT 0 48#define FIFO_MGMT 0
48#define FIFO_HCCA 1 49#define FIFO_HCCA 1
49#define FIFO_EDCA 2 50#define FIFO_EDCA 2
@@ -458,8 +459,8 @@ typedef union _BBP_CSR_CFG_STRUC {
458/* */ 459/* */
459typedef union _RF_CSR_CFG0_STRUC { 460typedef union _RF_CSR_CFG0_STRUC {
460 struct { 461 struct {
461 u32 RegIdAndContent:24; /* Register value to program into BBP */ 462 u32 RegIdAndContent:24; /* Register value to program into BBP */
462 u32 bitwidth:5; /* Selected BBP register */ 463 u32 bitwidth:5; /* Selected BBP register */
463 u32 StandbyMode:1; /* 0: high when stand by 1: low when standby */ 464 u32 StandbyMode:1; /* 0: high when stand by 1: low when standby */
464 u32 Sel:1; /* 0:RF_LE0 activate 1:RF_LE1 activate */ 465 u32 Sel:1; /* 0:RF_LE0 activate 1:RF_LE1 activate */
465 u32 Busy:1; /* 0: idle 1: 8busy */ 466 u32 Busy:1; /* 0: idle 1: 8busy */
@@ -469,7 +470,7 @@ typedef union _RF_CSR_CFG0_STRUC {
469#define RF_CSR_CFG1 0x1024 470#define RF_CSR_CFG1 0x1024
470typedef union _RF_CSR_CFG1_STRUC { 471typedef union _RF_CSR_CFG1_STRUC {
471 struct { 472 struct {
472 u32 RegIdAndContent:24; /* Register value to program into BBP */ 473 u32 RegIdAndContent:24; /* Register value to program into BBP */
473 u32 RFGap:5; /* Gap between BB_CONTROL_RF and RF_LE. 0: 3 system clock cycle (37.5usec) 1: 5 system clock cycle (62.5usec) */ 474 u32 RFGap:5; /* Gap between BB_CONTROL_RF and RF_LE. 0: 3 system clock cycle (37.5usec) 1: 5 system clock cycle (62.5usec) */
474 u32 rsv:7; /* 0: idle 1: 8busy */ 475 u32 rsv:7; /* 0: idle 1: 8busy */
475 } field; 476 } field;
@@ -478,7 +479,7 @@ typedef union _RF_CSR_CFG1_STRUC {
478#define RF_CSR_CFG2 0x1028 /* */ 479#define RF_CSR_CFG2 0x1028 /* */
479typedef union _RF_CSR_CFG2_STRUC { 480typedef union _RF_CSR_CFG2_STRUC {
480 struct { 481 struct {
481 u32 RegIdAndContent:24; /* Register value to program into BBP */ 482 u32 RegIdAndContent:24; /* Register value to program into BBP */
482 u32 rsv:8; /* 0: idle 1: 8busy */ 483 u32 rsv:8; /* 0: idle 1: 8busy */
483 } field; 484 } field;
484 u32 word; 485 u32 word;
@@ -490,7 +491,7 @@ typedef union _LED_CFG_STRUC {
490 u32 OffPeriod:8; /* blinking off period unit 1ms */ 491 u32 OffPeriod:8; /* blinking off period unit 1ms */
491 u32 SlowBlinkPeriod:6; /* slow blinking period. unit:1ms */ 492 u32 SlowBlinkPeriod:6; /* slow blinking period. unit:1ms */
492 u32 rsv:2; 493 u32 rsv:2;
493 u32 RLedMode:2; /* red Led Mode 0: off1: blinking upon TX2: periodic slow blinking3: always on */ 494 u32 RLedMode:2; /* red Led Mode 0: off1: blinking upon TX2: periodic slow blinking3: always on */
494 u32 GLedMode:2; /* green Led Mode */ 495 u32 GLedMode:2; /* green Led Mode */
495 u32 YLedMode:2; /* yellow Led Mode */ 496 u32 YLedMode:2; /* yellow Led Mode */
496 u32 LedPolar:1; /* Led Polarity. 0: active low1: active high */ 497 u32 LedPolar:1; /* Led Polarity. 0: active low1: active high */
@@ -621,9 +622,9 @@ typedef union _TX_TIMEOUT_CFG_STRUC {
621#define TX_RTY_CFG 0x134c 622#define TX_RTY_CFG 0x134c
622typedef union PACKED _TX_RTY_CFG_STRUC { 623typedef union PACKED _TX_RTY_CFG_STRUC {
623 struct { 624 struct {
624 u32 ShortRtyLimit:8; /* short retry limit */ 625 u32 ShortRtyLimit:8; /* short retry limit */
625 u32 LongRtyLimit:8; /*long retry limit */ 626 u32 LongRtyLimit:8; /* long retry limit */
626 u32 LongRtyThre:12; /* Long retry threshoold */ 627 u32 LongRtyThre:12; /* Long retry threshold */
627 u32 NonAggRtyMode:1; /* Non-Aggregate MPDU retry mode. 0:expired by retry limit, 1: expired by mpdu life timer */ 628 u32 NonAggRtyMode:1; /* Non-Aggregate MPDU retry mode. 0:expired by retry limit, 1: expired by mpdu life timer */
628 u32 AggRtyMode:1; /* Aggregate MPDU retry mode. 0:expired by retry limit, 1: expired by mpdu life timer */ 629 u32 AggRtyMode:1; /* Aggregate MPDU retry mode. 0:expired by retry limit, 1: expired by mpdu life timer */
629 u32 TxautoFBEnable:1; /* Tx retry PHY rate auto fallback enable */ 630 u32 TxautoFBEnable:1; /* Tx retry PHY rate auto fallback enable */
diff --git a/drivers/staging/rt2860/chips/rt3090.c b/drivers/staging/rt2860/chips/rt3090.c
index c2933c69bc0..156eb36e56f 100644
--- a/drivers/staging/rt2860/chips/rt3090.c
+++ b/drivers/staging/rt2860/chips/rt3090.c
@@ -28,10 +28,11 @@
28 rt3090.c 28 rt3090.c
29 29
30 Abstract: 30 Abstract:
31 Specific funcitons and variables for RT3070 31 Specific functions and variables for RT3070
32 32
33 Revision History: 33 Revision History:
34 Who When What 34 Who When What
35 Justin P. Mattock 11/07/2010 Fix a typo
35 -------- ---------- ---------------------------------------------- 36 -------- ---------- ----------------------------------------------
36*/ 37*/
37 38
diff --git a/drivers/staging/rt2860/chips/rt30xx.c b/drivers/staging/rt2860/chips/rt30xx.c
index 4367a196aef..c8f72825719 100644
--- a/drivers/staging/rt2860/chips/rt30xx.c
+++ b/drivers/staging/rt2860/chips/rt30xx.c
@@ -28,10 +28,11 @@
28 rt30xx.c 28 rt30xx.c
29 29
30 Abstract: 30 Abstract:
31 Specific funcitons and variables for RT30xx. 31 Specific functions and variables for RT30xx.
32 32
33 Revision History: 33 Revision History:
34 Who When What 34 Who When What
35 Justin P. Mattock 11/07/2010 Fix some typos
35 -------- ---------- ---------------------------------------------- 36 -------- ---------- ----------------------------------------------
36*/ 37*/
37 38
@@ -89,7 +90,7 @@ struct rt_reg_pair RT30xx_RFRegTable[] = {
89 90
90u8 NUM_RF_REG_PARMS = (sizeof(RT30xx_RFRegTable) / sizeof(struct rt_reg_pair)); 91u8 NUM_RF_REG_PARMS = (sizeof(RT30xx_RFRegTable) / sizeof(struct rt_reg_pair));
91 92
92/* Antenna divesity use GPIO3 and EESK pin for control */ 93/* Antenna diversity use GPIO3 and EESK pin for control */
93/* Antenna and EEPROM access are both using EESK pin, */ 94/* Antenna and EEPROM access are both using EESK pin, */
94/* Therefor we should avoid accessing EESK at the same time */ 95/* Therefor we should avoid accessing EESK at the same time */
95/* Then restore antenna after EEPROM access */ 96/* Then restore antenna after EEPROM access */
@@ -243,7 +244,7 @@ void RTMPFilterCalibration(struct rt_rtmp_adapter *pAd)
243 break; 244 break;
244 } 245 }
245 246
246 /* prevent infinite loop cause driver hang. */ 247 /* prevent infinite loop; causes driver hang. */
247 if (loopcnt++ > 100) { 248 if (loopcnt++ > 100) {
248 DBGPRINT(RT_DEBUG_ERROR, 249 DBGPRINT(RT_DEBUG_ERROR,
249 ("RTMPFilterCalibration - can't find a valid value, loopcnt=%d stop calibrating", 250 ("RTMPFilterCalibration - can't find a valid value, loopcnt=%d stop calibrating",
diff --git a/drivers/staging/rt2860/mlme.h b/drivers/staging/rt2860/mlme.h
index 01414c3b488..cd1ee3d7a91 100644
--- a/drivers/staging/rt2860/mlme.h
+++ b/drivers/staging/rt2860/mlme.h
@@ -32,8 +32,9 @@
32 Revision History: 32 Revision History:
33 Who When What 33 Who When What
34 -------- ---------- ------------------------------ 34 -------- ---------- ------------------------------
35 John Chang 2003-08-28 Created 35 John Chang 2003-08-28 Created
36 John Chang 2004-09-06 modified for RT2600 36 John Chang 2004-09-06 modified for RT2600
37 Justin P. Mattock 11/07/2010 Fix typos in comments
37 38
38*/ 39*/
39#ifndef __MLME_H__ 40#ifndef __MLME_H__
@@ -41,7 +42,7 @@
41 42
42#include "rtmp_dot11.h" 43#include "rtmp_dot11.h"
43 44
44/* maximum supported capability information - */ 45/* maximum supported capability information */
45/* ESS, IBSS, Privacy, Short Preamble, Spectrum mgmt, Short Slot */ 46/* ESS, IBSS, Privacy, Short Preamble, Spectrum mgmt, Short Slot */
46#define SUPPORTED_CAPABILITY_INFO 0x0533 47#define SUPPORTED_CAPABILITY_INFO 0x0533
47 48
@@ -77,7 +78,7 @@
77#define CW_MAX_IN_BITS 10 /* actual CwMax = 2^CW_MAX_IN_BITS - 1 */ 78#define CW_MAX_IN_BITS 10 /* actual CwMax = 2^CW_MAX_IN_BITS - 1 */
78 79
79/* Note: RSSI_TO_DBM_OFFSET has been changed to variable for new RF (2004-0720). */ 80/* Note: RSSI_TO_DBM_OFFSET has been changed to variable for new RF (2004-0720). */
80/* SHould not refer to this constant anymore */ 81/* Should not refer to this constant anymore */
81/*#define RSSI_TO_DBM_OFFSET 120 // for RT2530 RSSI-115 = dBm */ 82/*#define RSSI_TO_DBM_OFFSET 120 // for RT2530 RSSI-115 = dBm */
82#define RSSI_FOR_MID_TX_POWER -55 /* -55 db is considered mid-distance */ 83#define RSSI_FOR_MID_TX_POWER -55 /* -55 db is considered mid-distance */
83#define RSSI_FOR_LOW_TX_POWER -45 /* -45 db is considered very short distance and */ 84#define RSSI_FOR_LOW_TX_POWER -45 /* -45 db is considered very short distance and */
@@ -123,7 +124,7 @@
123#define TID_MAC_HASH_INDEX(Addr, TID) (TID_MAC_HASH(Addr, TID) % HASH_TABLE_SIZE) 124#define TID_MAC_HASH_INDEX(Addr, TID) (TID_MAC_HASH(Addr, TID) % HASH_TABLE_SIZE)
124 125
125/* LED Control */ 126/* LED Control */
126/* assoiation ON. one LED ON. another blinking when TX, OFF when idle */ 127/* association ON. one LED ON. another blinking when TX, OFF when idle */
127/* no association, both LED off */ 128/* no association, both LED off */
128#define ASIC_LED_ACT_ON(pAd) RTMP_IO_WRITE32(pAd, MAC_CSR14, 0x00031e46) 129#define ASIC_LED_ACT_ON(pAd) RTMP_IO_WRITE32(pAd, MAC_CSR14, 0x00031e46)
129#define ASIC_LED_ACT_OFF(pAd) RTMP_IO_WRITE32(pAd, MAC_CSR14, 0x00001e46) 130#define ASIC_LED_ACT_OFF(pAd) RTMP_IO_WRITE32(pAd, MAC_CSR14, 0x00001e46)
@@ -284,8 +285,8 @@ struct PACKED rt_ht_capability_ie {
284 285
285/* 802.11n draft3 related structure definitions. */ 286/* 802.11n draft3 related structure definitions. */
286/* 7.3.2.60 */ 287/* 7.3.2.60 */
287#define dot11OBSSScanPassiveDwell 20 /* in TU. min amount of time that the STA continously scans each channel when performing an active OBSS scan. */ 288#define dot11OBSSScanPassiveDwell 20 /* in TU. min amount of time that the STA continuously scans each channel when performing an active OBSS scan. */
288#define dot11OBSSScanActiveDwell 10 /* in TU.min amount of time that the STA continously scans each channel when performing an passive OBSS scan. */ 289#define dot11OBSSScanActiveDwell 10 /* in TU.min amount of time that the STA continuously scans each channel when performing an passive OBSS scan. */
289#define dot11BSSWidthTriggerScanInterval 300 /* in sec. max interval between scan operations to be performed to detect BSS channel width trigger events. */ 290#define dot11BSSWidthTriggerScanInterval 300 /* in sec. max interval between scan operations to be performed to detect BSS channel width trigger events. */
290#define dot11OBSSScanPassiveTotalPerChannel 200 /* in TU. min total amount of time that the STA scans each channel when performing a passive OBSS scan. */ 291#define dot11OBSSScanPassiveTotalPerChannel 200 /* in TU. min total amount of time that the STA scans each channel when performing a passive OBSS scan. */
291#define dot11OBSSScanActiveTotalPerChannel 20 /*in TU. min total amount of time that the STA scans each channel when performing a active OBSS scan */ 292#define dot11OBSSScanActiveTotalPerChannel 20 /*in TU. min total amount of time that the STA scans each channel when performing a active OBSS scan */
@@ -325,7 +326,7 @@ struct rt_trigger_eventa {
325}; 326};
326 327
327/* 20/40 trigger event table */ 328/* 20/40 trigger event table */
328/* If one Event A delete or created, or if Event B is detected or not detected, STA should send 2040BSSCoexistence to AP. */ 329/* If one Event (A) is deleted or created, or if Event (B) is detected or not detected, STA should send 2040BSSCoexistence to AP. */
329#define MAX_TRIGGER_EVENT 64 330#define MAX_TRIGGER_EVENT 64
330struct rt_trigger_event_tab { 331struct rt_trigger_event_tab {
331 u8 EventANo; 332 u8 EventANo;
@@ -357,14 +358,14 @@ struct PACKED rt_bss_2040_intolerant_ch_report {
357 u8 ChList[0]; 358 u8 ChList[0];
358}; 359};
359 360
360/* The structure for channel switch annoucement IE. This is in 802.11n D3.03 */ 361/* The structure for channel switch announcement IE. This is in 802.11n D3.03 */
361struct PACKED rt_cha_switch_announce_ie { 362struct PACKED rt_cha_switch_announce_ie {
362 u8 SwitchMode; /*channel switch mode */ 363 u8 SwitchMode; /*channel switch mode */
363 u8 NewChannel; /* */ 364 u8 NewChannel; /* */
364 u8 SwitchCount; /* */ 365 u8 SwitchCount; /* */
365}; 366};
366 367
367/* The structure for channel switch annoucement IE. This is in 802.11n D3.03 */ 368/* The structure for channel switch announcement IE. This is in 802.11n D3.03 */
368struct PACKED rt_sec_cha_offset_ie { 369struct PACKED rt_sec_cha_offset_ie {
369 u8 SecondaryChannelOffset; /* 1: Secondary above, 3: Secondary below, 0: no Secondary */ 370 u8 SecondaryChannelOffset; /* 1: Secondary above, 3: Secondary below, 0: no Secondary */
370}; 371};
@@ -377,7 +378,7 @@ struct rt_ht_phy_info {
377 u8 MCSSet[16]; 378 u8 MCSSet[16];
378}; 379};
379 380
380/*This structure substracts ralink supports from all 802.11n-related features. */ 381/*This structure subtracts ralink supports from all 802.11n-related features. */
381/*Features not listed here but contained in 802.11n spec are not supported in rt2860. */ 382/*Features not listed here but contained in 802.11n spec are not supported in rt2860. */
382struct rt_ht_capability { 383struct rt_ht_capability {
383 u16 ChannelWidth:1; 384 u16 ChannelWidth:1;
@@ -387,14 +388,14 @@ struct rt_ht_capability {
387 u16 ShortGIfor40:1; /*for40MHz */ 388 u16 ShortGIfor40:1; /*for40MHz */
388 u16 TxSTBC:1; 389 u16 TxSTBC:1;
389 u16 RxSTBC:2; /* 2 bits */ 390 u16 RxSTBC:2; /* 2 bits */
390 u16 AmsduEnable:1; /* Enable to transmit A-MSDU. Suggest disable. We should use A-MPDU to gain best benifit of 802.11n */ 391 u16 AmsduEnable:1; /* Enable to transmit A-MSDU. Suggest disable. We should use A-MPDU to gain best benefit of 802.11n */
391 u16 AmsduSize:1; /* Max receiving A-MSDU size */ 392 u16 AmsduSize:1; /* Max receiving A-MSDU size */
392 u16 rsv:5; 393 u16 rsv:5;
393 394
394 /*Substract from Addiont HT INFO IE */ 395 /*Substract from Addiont HT INFO IE */
395 u8 MaxRAmpduFactor:2; 396 u8 MaxRAmpduFactor:2;
396 u8 MpduDensity:3; 397 u8 MpduDensity:3;
397 u8 ExtChanOffset:2; /* Please not the difference with following u8 NewExtChannelOffset; from 802.11n */ 398 u8 ExtChanOffset:2; /* Please note the difference with following u8 NewExtChannelOffset; from 802.11n */
398 u8 RecomWidth:1; 399 u8 RecomWidth:1;
399 400
400 u16 OperaionMode:2; 401 u16 OperaionMode:2;
@@ -481,7 +482,7 @@ struct PACKED rt_ba_parm {
481 u16 AMSDUSupported:1; /* 0: not permitted 1: permitted */ 482 u16 AMSDUSupported:1; /* 0: not permitted 1: permitted */
482 u16 BAPolicy:1; /* 1: immediately BA 0:delayed BA */ 483 u16 BAPolicy:1; /* 1: immediately BA 0:delayed BA */
483 u16 TID:4; /* value of TC os TS */ 484 u16 TID:4; /* value of TC os TS */
484 u16 BufSize:10; /* number of buffe of size 2304 octetsr */ 485 u16 BufSize:10; /* number of buffer of size 2304 octetsr */
485}; 486};
486 487
487/* 2-byte BA Starting Seq CONTROL field */ 488/* 2-byte BA Starting Seq CONTROL field */
@@ -551,7 +552,7 @@ struct PACKED rt_frame_mtba_req {
551 BASEQ_CONTROL BAStartingSeq; 552 BASEQ_CONTROL BAStartingSeq;
552}; 553};
553 554
554/* Compressed format is mandantory in HT STA */ 555/* Compressed format is mandatory in HT STA */
555struct PACKED rt_frame_mtba { 556struct PACKED rt_frame_mtba {
556 struct rt_frame_control FC; 557 struct rt_frame_control FC;
557 u16 Duration; 558 u16 Duration;
@@ -647,7 +648,7 @@ struct PACKED rt_frame_ba {
647 u8 bitmask[8]; 648 u8 bitmask[8];
648}; 649};
649 650
650/* Radio Measuement Request Frame Format */ 651/* Radio Measurement Request Frame Format */
651struct PACKED rt_frame_rm_req_action { 652struct PACKED rt_frame_rm_req_action {
652 struct rt_header_802_11 Hdr; 653 struct rt_header_802_11 Hdr;
653 u8 Category; 654 u8 Category;
@@ -709,7 +710,7 @@ struct rt_edca_parm {
709 u8 Cwmin[4]; 710 u8 Cwmin[4];
710 u8 Cwmax[4]; 711 u8 Cwmax[4];
711 u16 Txop[4]; /* in unit of 32-us */ 712 u16 Txop[4]; /* in unit of 32-us */
712 BOOLEAN bACM[4]; /* 1: Admission Control of AC_BK is mandattory */ 713 BOOLEAN bACM[4]; /* 1: Admission Control of AC_BK is mandatory */
713}; 714};
714 715
715/* QBSS LOAD information from QAP's BEACON/ProbeRsp */ 716/* QBSS LOAD information from QAP's BEACON/ProbeRsp */
@@ -757,7 +758,7 @@ struct rt_wpa_ie {
757struct rt_bss_entry { 758struct rt_bss_entry {
758 u8 Bssid[MAC_ADDR_LEN]; 759 u8 Bssid[MAC_ADDR_LEN];
759 u8 Channel; 760 u8 Channel;
760 u8 CentralChannel; /*Store the wide-band central channel for 40MHz. .used in 40MHz AP. Or this is the same as Channel. */ 761 u8 CentralChannel; /*Store the wide-band central channel for 40MHz. used in 40MHz AP. Or this is the same as Channel. */
761 u8 BssType; 762 u8 BssType;
762 u16 AtimWin; 763 u16 AtimWin;
763 u16 BeaconPeriod; 764 u16 BeaconPeriod;
@@ -855,7 +856,7 @@ struct rt_state_machine {
855 STATE_MACHINE_FUNC *TransFunc; 856 STATE_MACHINE_FUNC *TransFunc;
856}; 857};
857 858
858/* MLME AUX data structure that hold temporarliy settings during a connection attempt. */ 859/* MLME AUX data structure that holds temporarliy settings during a connection attempt. */
859/* Once this attemp succeeds, all settings will be copy to pAd->StaActive. */ 860/* Once this attemp succeeds, all settings will be copy to pAd->StaActive. */
860/* A connection attempt (user set OID, roaming, CCX fast roaming,..) consists of */ 861/* A connection attempt (user set OID, roaming, CCX fast roaming,..) consists of */
861/* several steps (JOIN, AUTH, ASSOC or REASSOC) and may fail at any step. We purposely */ 862/* several steps (JOIN, AUTH, ASSOC or REASSOC) and may fail at any step. We purposely */
@@ -996,7 +997,7 @@ struct PACKED rt_rtmp_tx_rate_switch {
996#define MAC_TABLE_ASSOC_TIMEOUT 5 /* unit: sec */ 997#define MAC_TABLE_ASSOC_TIMEOUT 5 /* unit: sec */
997#define MAC_TABLE_FULL(Tab) ((Tab).size == MAX_LEN_OF_MAC_TABLE) 998#define MAC_TABLE_FULL(Tab) ((Tab).size == MAX_LEN_OF_MAC_TABLE)
998 999
999/* AP shall drop the sta if contine Tx fail count reach it. */ 1000/* AP shall drop the sta if continue Tx fail count reach it. */
1000#define MAC_ENTRY_LIFE_CHECK_CNT 20 /* packet cnt. */ 1001#define MAC_ENTRY_LIFE_CHECK_CNT 20 /* packet cnt. */
1001 1002
1002/* Value domain of pMacEntry->Sst */ 1003/* Value domain of pMacEntry->Sst */
diff --git a/drivers/staging/rt2860/oid.h b/drivers/staging/rt2860/oid.h
index 1704c27b273..eaa3fe00508 100644
--- a/drivers/staging/rt2860/oid.h
+++ b/drivers/staging/rt2860/oid.h
@@ -32,7 +32,8 @@
32 Revision History: 32 Revision History:
33 Who When What 33 Who When What
34 -------- ---------- ---------------------------------------------- 34 -------- ---------- ----------------------------------------------
35 Name Date Modification logs 35 Name Date Modification logs
36 Justin P. Mattock 11/07/2010 Fix typos in comments
36*/ 37*/
37#ifndef _OID_H_ 38#ifndef _OID_H_
38#define _OID_H_ 39#define _OID_H_
@@ -78,7 +79,7 @@
78#define NDIS_802_11_LENGTH_RATES 8 79#define NDIS_802_11_LENGTH_RATES 8
79#define NDIS_802_11_LENGTH_RATES_EX 16 80#define NDIS_802_11_LENGTH_RATES_EX 16
80#define MAC_ADDR_LENGTH 6 81#define MAC_ADDR_LENGTH 6
81/*#define MAX_NUM_OF_CHS 49 // 14 channels @2.4G + 12@UNII + 4 @MMAC + 11 @HiperLAN2 + 7 @Japan + 1 as NULL terminationc */ 82/*#define MAX_NUM_OF_CHS 49 // 14 channels @2.4G + 12@UNII + 4 @MMAC + 11 @HiperLAN2 + 7 @Japan + 1 as NULL termination */
82#define MAX_NUM_OF_CHS 54 /* 14 channels @2.4G + 12@UNII(lower/middle) + 16@HiperLAN2 + 11@UNII(upper) + 0 @Japan + 1 as NULL termination */ 83#define MAX_NUM_OF_CHS 54 /* 14 channels @2.4G + 12@UNII(lower/middle) + 16@HiperLAN2 + 11@UNII(upper) + 0 @Japan + 1 as NULL termination */
83#define MAX_NUMBER_OF_EVENT 10 /* entry # in EVENT table */ 84#define MAX_NUMBER_OF_EVENT 10 /* entry # in EVENT table */
84#define MAX_NUMBER_OF_MAC 32 /* if MAX_MBSSID_NUM is 8, this value can't be larger than 211 */ 85#define MAX_NUMBER_OF_MAC 32 /* if MAX_MBSSID_NUM is 8, this value can't be larger than 211 */
@@ -610,7 +611,7 @@ struct rt_802_11_event_log {
610 611
611struct rt_802_11_event_table { 612struct rt_802_11_event_table {
612 unsigned long Num; 613 unsigned long Num;
613 unsigned long Rsv; /* to align Log[] at LARGE_INEGER boundary */ 614 unsigned long Rsv; /* to align Log[] at LARGE_INTEGER boundary */
614 struct rt_802_11_event_log Log[MAX_NUMBER_OF_EVENT]; 615 struct rt_802_11_event_log Log[MAX_NUMBER_OF_EVENT];
615}; 616};
616 617
@@ -721,9 +722,9 @@ struct rt_802_11_tx_rates {
721#define AUTH_FAIL 0x4 /* Open authentication fail */ 722#define AUTH_FAIL 0x4 /* Open authentication fail */
722#define AUTH_FAIL_KEYS 0x5 /* Shared authentication fail */ 723#define AUTH_FAIL_KEYS 0x5 /* Shared authentication fail */
723#define ASSOC_FAIL 0x6 /* Association failed */ 724#define ASSOC_FAIL 0x6 /* Association failed */
724#define EAP_MIC_FAILURE 0x7 /* Deauthencation because MIC failure */ 725#define EAP_MIC_FAILURE 0x7 /* Deauthentication because MIC failure */
725#define EAP_4WAY_TIMEOUT 0x8 /* Deauthencation on 4-way handshake timeout */ 726#define EAP_4WAY_TIMEOUT 0x8 /* Deauthentication on 4-way handshake timeout */
726#define EAP_GROUP_KEY_TIMEOUT 0x9 /* Deauthencation on group key handshake timeout */ 727#define EAP_GROUP_KEY_TIMEOUT 0x9 /* Deauthentication on group key handshake timeout */
727#define EAP_SUCCESS 0xa /* EAP succeed */ 728#define EAP_SUCCESS 0xa /* EAP succeed */
728#define DETECT_RADAR_SIGNAL 0xb /* Radar signal occur in current channel */ 729#define DETECT_RADAR_SIGNAL 0xb /* Radar signal occur in current channel */
729#define EXTRA_INFO_MAX 0xb /* Indicate Last OID */ 730#define EXTRA_INFO_MAX 0xb /* Indicate Last OID */
diff --git a/drivers/staging/rt2860/pci_main_dev.c b/drivers/staging/rt2860/pci_main_dev.c
index 321facd6b0a..c35c804a083 100644
--- a/drivers/staging/rt2860/pci_main_dev.c
+++ b/drivers/staging/rt2860/pci_main_dev.c
@@ -31,7 +31,8 @@
31 Create and register network interface for PCI based chipsets in Linux platform. 31 Create and register network interface for PCI based chipsets in Linux platform.
32 32
33 Revision History: 33 Revision History:
34 Who When What 34 Who When What
35 Justin P. Mattock 11/07/2010 Fix typos in some comments
35 -------- ---------- ---------------------------------------------- 36 -------- ---------- ----------------------------------------------
36*/ 37*/
37 38
@@ -40,8 +41,8 @@
40#include <linux/slab.h> 41#include <linux/slab.h>
41 42
42/* Following information will be show when you run 'modinfo' */ 43/* Following information will be show when you run 'modinfo' */
43/* *** If you have a solution for the bug in current version of driver, please mail to me. */ 44/* If you have a solution for a bug in current version of driver, please e-mail me. */
44/* Otherwise post to forum in ralinktech's web site(www.ralinktech.com) and let all users help you. *** */ 45/* Otherwise post to forum in ralinktech's web site(www.ralinktech.com) and let all users help you. */
45MODULE_AUTHOR("Jett Chen <jett_chen@ralinktech.com>"); 46MODULE_AUTHOR("Jett Chen <jett_chen@ralinktech.com>");
46MODULE_DESCRIPTION("RT2860/RT3090 Wireless Lan Linux Driver"); 47MODULE_DESCRIPTION("RT2860/RT3090 Wireless Lan Linux Driver");
47MODULE_LICENSE("GPL"); 48MODULE_LICENSE("GPL");
@@ -599,7 +600,7 @@ void RTMPInitPCIeLinkCtrlValue(struct rt_rtmp_adapter *pAd)
599 DBGPRINT_RAW(RT_DEBUG_ERROR, 600 DBGPRINT_RAW(RT_DEBUG_ERROR,
600 (" AUX_CTRL = 0x%32x\n", MacValue)); 601 (" AUX_CTRL = 0x%32x\n", MacValue));
601 602
602 /* for RT30xx F and after, PCIe infterface, and for power solution 3 */ 603 /* for RT30xx F and after, PCIe interface, and for power solution 3 */
603 if ((IS_VERSION_AFTER_F(pAd)) 604 if ((IS_VERSION_AFTER_F(pAd))
604 && (pAd->StaCfg.PSControl.field.rt30xxPowerMode >= 2) 605 && (pAd->StaCfg.PSControl.field.rt30xxPowerMode >= 2)
605 && (pAd->StaCfg.PSControl.field.rt30xxPowerMode <= 3)) { 606 && (pAd->StaCfg.PSControl.field.rt30xxPowerMode <= 3)) {
@@ -902,7 +903,7 @@ void RTMPPCIeLinkCtrlValueRestore(struct rt_rtmp_adapter *pAd, u8 Level)
902 Configuration); 903 Configuration);
903 if ((Configuration != 0) && (Configuration != 0xFFFF)) { 904 if ((Configuration != 0) && (Configuration != 0xFFFF)) {
904 Configuration &= 0xfefc; 905 Configuration &= 0xfefc;
905 /* If call from interface down, restore to orginial setting. */ 906 /* If call from interface down, restore to original setting. */
906 if (Level == RESTORE_CLOSE) 907 if (Level == RESTORE_CLOSE)
907 Configuration |= pAd->HostLnkCtrlConfiguration; 908 Configuration |= pAd->HostLnkCtrlConfiguration;
908 else 909 else
@@ -924,7 +925,7 @@ void RTMPPCIeLinkCtrlValueRestore(struct rt_rtmp_adapter *pAd, u8 Level)
924 Configuration); 925 Configuration);
925 if ((Configuration != 0) && (Configuration != 0xFFFF)) { 926 if ((Configuration != 0) && (Configuration != 0xFFFF)) {
926 Configuration &= 0xfefc; 927 Configuration &= 0xfefc;
927 /* If call from interface down, restore to orginial setting. */ 928 /* If call from interface down, restore to original setting. */
928 if (Level == RESTORE_CLOSE) 929 if (Level == RESTORE_CLOSE)
929 Configuration |= pAd->RLnkCtrlConfiguration; 930 Configuration |= pAd->RLnkCtrlConfiguration;
930 else 931 else
@@ -1106,12 +1107,12 @@ void RTMPrt3xSetPCIePowerLinkCtrl(struct rt_rtmp_adapter *pAd)
1106 if (pos != 0) 1107 if (pos != 0)
1107 pAd->HostLnkCtrlOffset = pos + PCI_EXP_LNKCTL; 1108 pAd->HostLnkCtrlOffset = pos + PCI_EXP_LNKCTL;
1108 1109
1109 /* If configurared to turn on L1. */ 1110 /* If configured to turn on L1. */
1110 HostConfiguration = 0; 1111 HostConfiguration = 0;
1111 if (pAd->StaCfg.PSControl.field.rt30xxForceASPMTest == 1) { 1112 if (pAd->StaCfg.PSControl.field.rt30xxForceASPMTest == 1) {
1112 DBGPRINT(RT_DEBUG_TRACE, ("Enter,PSM : Force ASPM\n")); 1113 DBGPRINT(RT_DEBUG_TRACE, ("Enter,PSM : Force ASPM\n"));
1113 1114
1114 /* Skip non-exist deice right away */ 1115 /* Skip non-exist device right away */
1115 if ((pAd->HostLnkCtrlOffset != 0)) { 1116 if ((pAd->HostLnkCtrlOffset != 0)) {
1116 PCI_REG_READ_WORD(pObj->parent_pci_dev, 1117 PCI_REG_READ_WORD(pObj->parent_pci_dev,
1117 pAd->HostLnkCtrlOffset, 1118 pAd->HostLnkCtrlOffset,
diff --git a/drivers/staging/rt2860/rt_linux.c b/drivers/staging/rt2860/rt_linux.c
index abfeea11721..e680b0d97f7 100644
--- a/drivers/staging/rt2860/rt_linux.c
+++ b/drivers/staging/rt2860/rt_linux.c
@@ -767,13 +767,13 @@ void send_monitor_packets(struct rt_rtmp_adapter *pAd, struct rt_rx_blk *pRxBlk)
767 /* QOS */ 767 /* QOS */
768 if (pRxBlk->pHeader->FC.SubType & 0x08) { 768 if (pRxBlk->pHeader->FC.SubType & 0x08) {
769 header_len += 2; 769 header_len += 2;
770 /* Data skip QOS contorl field */ 770 /* Data skip QOS control field */
771 pRxBlk->DataSize -= 2; 771 pRxBlk->DataSize -= 2;
772 } 772 }
773 /* Order bit: A-Ralink or HTC+ */ 773 /* Order bit: A-Ralink or HTC+ */
774 if (pRxBlk->pHeader->FC.Order) { 774 if (pRxBlk->pHeader->FC.Order) {
775 header_len += 4; 775 header_len += 4;
776 /* Data skip HTC contorl field */ 776 /* Data skip HTC control field */
777 pRxBlk->DataSize -= 4; 777 pRxBlk->DataSize -= 4;
778 } 778 }
779 /* Copy Header */ 779 /* Copy Header */
@@ -1175,7 +1175,7 @@ int RtmpOSNetDevAddrSet(struct net_device *pNetDev, u8 *pMacAddr)
1175 net_dev = pNetDev; 1175 net_dev = pNetDev;
1176 GET_PAD_FROM_NET_DEV(pAd, net_dev); 1176 GET_PAD_FROM_NET_DEV(pAd, net_dev);
1177 1177
1178 /* work-around for the SuSE due to it has it's own interface name management system. */ 1178 /* work-around for SuSE, due to them having their own interface name management system. */
1179 { 1179 {
1180 NdisZeroMemory(pAd->StaCfg.dev_name, 16); 1180 NdisZeroMemory(pAd->StaCfg.dev_name, 16);
1181 NdisMoveMemory(pAd->StaCfg.dev_name, net_dev->name, 1181 NdisMoveMemory(pAd->StaCfg.dev_name, net_dev->name,
@@ -1300,7 +1300,7 @@ int RtmpOSNetDevAttach(struct net_device *pNetDev,
1300 int ret, rtnl_locked = FALSE; 1300 int ret, rtnl_locked = FALSE;
1301 1301
1302 DBGPRINT(RT_DEBUG_TRACE, ("RtmpOSNetDevAttach()--->\n")); 1302 DBGPRINT(RT_DEBUG_TRACE, ("RtmpOSNetDevAttach()--->\n"));
1303 /* If we need hook some callback function to the net device structrue, now do it. */ 1303 /* If we need hook some callback function to the net device structure, now do it. */
1304 if (pDevOpHook) { 1304 if (pDevOpHook) {
1305 struct rt_rtmp_adapter *pAd = NULL; 1305 struct rt_rtmp_adapter *pAd = NULL;
1306 1306
@@ -1351,10 +1351,10 @@ struct net_device *RtmpOSNetDevCreate(struct rt_rtmp_adapter *pAd,
1351 return NULL; 1351 return NULL;
1352 } 1352 }
1353 1353
1354 /* find a available interface name, max 32 interfaces */ 1354 /* find an available interface name, max 32 interfaces */
1355 status = RtmpOSNetDevRequestName(pAd, pNetDev, pNamePrefix, devNum); 1355 status = RtmpOSNetDevRequestName(pAd, pNetDev, pNamePrefix, devNum);
1356 if (status != NDIS_STATUS_SUCCESS) { 1356 if (status != NDIS_STATUS_SUCCESS) {
1357 /* error! no any available ra name can be used! */ 1357 /* error! no available ra name can be used! */
1358 DBGPRINT(RT_DEBUG_ERROR, 1358 DBGPRINT(RT_DEBUG_ERROR,
1359 ("Assign interface name (%s with suffix 0~32) failed...\n", 1359 ("Assign interface name (%s with suffix 0~32) failed...\n",
1360 pNamePrefix)); 1360 pNamePrefix));
diff --git a/drivers/staging/rt2860/rt_linux.h b/drivers/staging/rt2860/rt_linux.h
index 5acedf18b1a..a449b0bb85f 100644
--- a/drivers/staging/rt2860/rt_linux.h
+++ b/drivers/staging/rt2860/rt_linux.h
@@ -30,7 +30,8 @@
30 Abstract: 30 Abstract:
31 31
32 Revision History: 32 Revision History:
33 Who When What 33 Who When What
34 Justin P. Mattock 11/07/2010 Fix typo in a comment
34 --------- ---------- ---------------------------------------------- 35 --------- ---------- ----------------------------------------------
35*/ 36*/
36 37
@@ -726,7 +727,7 @@ void linux_pci_unmap_single(struct rt_rtmp_adapter *pAd, dma_addr_t dma_addr,
726#define RTMP_GET_PACKET_MOREDATA(_p) (RTPKT_TO_OSPKT(_p)->cb[CB_OFF+7]) 727#define RTMP_GET_PACKET_MOREDATA(_p) (RTPKT_TO_OSPKT(_p)->cb[CB_OFF+7])
727 728
728/* */ 729/* */
729/* Sepcific Pakcet Type definition */ 730/* Specific Packet Type definition */
730/* */ 731/* */
731#define RTMP_PACKET_SPECIFIC_CB_OFFSET 11 732#define RTMP_PACKET_SPECIFIC_CB_OFFSET 11
732 733
diff --git a/drivers/staging/rt2860/rt_main_dev.c b/drivers/staging/rt2860/rt_main_dev.c
index ad60ceaf4b8..19e9bc6569f 100644
--- a/drivers/staging/rt2860/rt_main_dev.c
+++ b/drivers/staging/rt2860/rt_main_dev.c
@@ -31,7 +31,8 @@
31 Create and register network interface. 31 Create and register network interface.
32 32
33 Revision History: 33 Revision History:
34 Who When What 34 Who When What
35 Justin P. Mattock 11/07/2010 Fix typos in comments
35 -------- ---------- ---------------------------------------------- 36 -------- ---------- ----------------------------------------------
36*/ 37*/
37 38
@@ -234,7 +235,7 @@ int rt28xx_close(struct net_device *dev)
234 RTMPPCIeLinkCtrlValueRestore(pAd, RESTORE_CLOSE); 235 RTMPPCIeLinkCtrlValueRestore(pAd, RESTORE_CLOSE);
235#endif /* RTMP_MAC_PCI // */ 236#endif /* RTMP_MAC_PCI // */
236 237
237 /* If dirver doesn't wake up firmware here, */ 238 /* If driver doesn't wake up firmware here, */
238 /* NICLoadFirmware will hang forever when interface is up again. */ 239 /* NICLoadFirmware will hang forever when interface is up again. */
239 if (OPSTATUS_TEST_FLAG(pAd, fOP_STATUS_DOZE)) { 240 if (OPSTATUS_TEST_FLAG(pAd, fOP_STATUS_DOZE)) {
240 AsicForceWakeup(pAd, TRUE); 241 AsicForceWakeup(pAd, TRUE);
@@ -310,8 +311,8 @@ int rt28xx_close(struct net_device *dev)
310 RTMP_ASIC_INTERRUPT_DISABLE(pAd); 311 RTMP_ASIC_INTERRUPT_DISABLE(pAd);
311 } 312 }
312 /* Receive packets to clear DMA index after disable interrupt. */ 313 /* Receive packets to clear DMA index after disable interrupt. */
313 /*RTMPHandleRxDoneInterrupt(pAd); */ 314 /* RTMPHandleRxDoneInterrupt(pAd); */
314 /* put to radio off to save power when driver unload. After radiooff, can't write /read register. So need to finish all */ 315 /* put radio off to save power when driver unloads. After radiooff, can't write/read register, so need to finish all. */
315 /* register access before Radio off. */ 316 /* register access before Radio off. */
316 317
317 brc = RT28xxPciAsicRadioOff(pAd, RTMP_HALT, 0); 318 brc = RT28xxPciAsicRadioOff(pAd, RTMP_HALT, 0);
diff --git a/drivers/staging/rt2860/rt_pci_rbus.c b/drivers/staging/rt2860/rt_pci_rbus.c
index 3004be6da00..e5fb67cd9a6 100644
--- a/drivers/staging/rt2860/rt_pci_rbus.c
+++ b/drivers/staging/rt2860/rt_pci_rbus.c
@@ -31,7 +31,8 @@
31 Create and register network interface. 31 Create and register network interface.
32 32
33 Revision History: 33 Revision History:
34 Who When What 34 Who When What
35 Justin P. Mattock 11/07/2010 Fix a typo
35 -------- ---------- ---------------------------------------------- 36 -------- ---------- ----------------------------------------------
36*/ 37*/
37 38
@@ -356,7 +357,7 @@ static void mgmt_dma_done_tasklet(unsigned long data)
356 357
357 RTMPHandleMgmtRingDmaDoneInterrupt(pAd); 358 RTMPHandleMgmtRingDmaDoneInterrupt(pAd);
358 359
359 /* if you use RTMP_SEM_LOCK, sometimes kernel will hang up, no any */ 360 /* if you use RTMP_SEM_LOCK, sometimes kernel will hang up, without any */
360 /* bug report output */ 361 /* bug report output */
361 RTMP_INT_LOCK(&pAd->irq_lock, flags); 362 RTMP_INT_LOCK(&pAd->irq_lock, flags);
362 /* 363 /*
@@ -787,7 +788,7 @@ IRQ_HANDLE_TYPE rt2860_interrupt(int irq, void *dev_instance)
787} 788}
788 789
789/* 790/*
790 * invaild or writeback cache 791 * invalid or writeback cache
791 * and convert virtual address to physical address 792 * and convert virtual address to physical address
792 */ 793 */
793dma_addr_t linux_pci_map_single(struct rt_rtmp_adapter *pAd, void *ptr, 794dma_addr_t linux_pci_map_single(struct rt_rtmp_adapter *pAd, void *ptr,
diff --git a/drivers/staging/rt2860/rt_usb.c b/drivers/staging/rt2860/rt_usb.c
index bcfc0f54d2a..580a20dd6e9 100644
--- a/drivers/staging/rt2860/rt_usb.c
+++ b/drivers/staging/rt2860/rt_usb.c
@@ -32,7 +32,8 @@
32 Revision History: 32 Revision History:
33 Who When What 33 Who When What
34 -------- ---------- ---------------------------------------------- 34 -------- ---------- ----------------------------------------------
35 Name Date Modification logs 35 Name Date Modification logs
36 Justin P. Mattock 11/07/2010 Fix some typos.
36 37
37*/ 38*/
38 39
@@ -279,7 +280,7 @@ static void rtusb_dataout_complete(unsigned long data)
279 && !RTUSB_TEST_BULK_FLAG(pAd, 280 && !RTUSB_TEST_BULK_FLAG(pAd,
280 (fRTUSB_BULK_OUT_DATA_FRAG << 281 (fRTUSB_BULK_OUT_DATA_FRAG <<
281 BulkOutPipeId))) { 282 BulkOutPipeId))) {
282 /* Indicate There is data avaliable */ 283 /* Indicate There is data available */
283 RTUSB_SET_BULK_FLAG(pAd, 284 RTUSB_SET_BULK_FLAG(pAd,
284 (fRTUSB_BULK_OUT_DATA_NORMAL << 285 (fRTUSB_BULK_OUT_DATA_NORMAL <<
285 BulkOutPipeId)); 286 BulkOutPipeId));
@@ -335,7 +336,7 @@ static void rtusb_null_frame_done_tasklet(unsigned long data)
335 } 336 }
336 337
337 /* Always call Bulk routine, even reset bulk. */ 338 /* Always call Bulk routine, even reset bulk. */
338 /* The protectioon of rest bulk should be in BulkOut routine */ 339 /* The protection of rest bulk should be in BulkOut routine */
339 RTUSBKickBulkOut(pAd); 340 RTUSBKickBulkOut(pAd);
340} 341}
341 342
@@ -383,7 +384,7 @@ static void rtusb_rts_frame_done_tasklet(unsigned long data)
383 RTMP_SEM_UNLOCK(&pAd->BulkOutLock[pRTSContext->BulkOutPipeId]); 384 RTMP_SEM_UNLOCK(&pAd->BulkOutLock[pRTSContext->BulkOutPipeId]);
384 385
385 /* Always call Bulk routine, even reset bulk. */ 386 /* Always call Bulk routine, even reset bulk. */
386 /* The protectioon of rest bulk should be in BulkOut routine */ 387 /* The protection of rest bulk should be in BulkOut routine */
387 RTUSBKickBulkOut(pAd); 388 RTUSBKickBulkOut(pAd);
388 389
389} 390}
@@ -427,7 +428,7 @@ static void rtusb_pspoll_frame_done_tasklet(unsigned long data)
427 RTMP_SEM_UNLOCK(&pAd->BulkOutLock[0]); 428 RTMP_SEM_UNLOCK(&pAd->BulkOutLock[0]);
428 429
429 /* Always call Bulk routine, even reset bulk. */ 430 /* Always call Bulk routine, even reset bulk. */
430 /* The protectioon of rest bulk should be in BulkOut routine */ 431 /* The protection of rest bulk should be in BulkOut routine */
431 RTUSBKickBulkOut(pAd); 432 RTUSBKickBulkOut(pAd);
432 433
433} 434}
@@ -575,7 +576,7 @@ static void rtusb_mgmt_dma_done_tasklet(unsigned long data)
575 } else { 576 } else {
576 577
577 /* Always call Bulk routine, even reset bulk. */ 578 /* Always call Bulk routine, even reset bulk. */
578 /* The protectioon of rest bulk should be in BulkOut routine */ 579 /* The protection of rest bulk should be in BulkOut routine */
579 if (pAd->MgmtRing.TxSwFreeIdx < 580 if (pAd->MgmtRing.TxSwFreeIdx <
580 MGMT_RING_SIZE 581 MGMT_RING_SIZE
581 /* pMLMEContext->bWaitingBulkOut == TRUE */) { 582 /* pMLMEContext->bWaitingBulkOut == TRUE */) {
diff --git a/drivers/staging/rt2860/rtmp.h b/drivers/staging/rt2860/rtmp.h
index ca54e53b660..caf466242a1 100644
--- a/drivers/staging/rt2860/rtmp.h
+++ b/drivers/staging/rt2860/rtmp.h
@@ -31,11 +31,12 @@
31 Miniport generic portion header file 31 Miniport generic portion header file
32 32
33 Revision History: 33 Revision History:
34 Who When What 34 Who When What
35 -------- ---------- ---------------------------------------------- 35 -------- ---------- ----------------------------------------------
36 Paul Lin 2002-08-01 created 36 Paul Lin 2002-08-01 created
37 James Tan 2002-09-06 modified (Revise NTCRegTable) 37 James Tan 2002-09-06 modified (Revise NTCRegTable)
38 John Chang 2004-09-06 modified for RT2600 38 John Chang 2004-09-06 modified for RT2600
39 Justin P. Mattock 11/07/2010 Fix some typos
39*/ 40*/
40#ifndef __RTMP_H__ 41#ifndef __RTMP_H__
41#define __RTMP_H__ 42#define __RTMP_H__
@@ -337,7 +338,7 @@ struct rt_rtmp_sg_list {
337#define LEAP_ON(_p) (((_p)->StaCfg.LeapAuthMode) == CISCO_AuthModeLEAP) 338#define LEAP_ON(_p) (((_p)->StaCfg.LeapAuthMode) == CISCO_AuthModeLEAP)
338#define LEAP_CCKM_ON(_p) ((((_p)->StaCfg.LeapAuthMode) == CISCO_AuthModeLEAP) && ((_p)->StaCfg.LeapAuthInfo.CCKM == TRUE)) 339#define LEAP_CCKM_ON(_p) ((((_p)->StaCfg.LeapAuthMode) == CISCO_AuthModeLEAP) && ((_p)->StaCfg.LeapAuthInfo.CCKM == TRUE))
339 340
340/* if orginal Ethernet frame contains no LLC/SNAP, then an extra LLC/SNAP encap is required */ 341/* if original Ethernet frame contains no LLC/SNAP, then an extra LLC/SNAP encap is required */
341#define EXTRA_LLCSNAP_ENCAP_FROM_PKT_START(_pBufVA, _pExtraLlcSnapEncap) \ 342#define EXTRA_LLCSNAP_ENCAP_FROM_PKT_START(_pBufVA, _pExtraLlcSnapEncap) \
342{ \ 343{ \
343 if (((*(_pBufVA + 12) << 8) + *(_pBufVA + 13)) > 1500) { \ 344 if (((*(_pBufVA + 12) << 8) + *(_pBufVA + 13)) > 1500) { \
@@ -466,7 +467,7 @@ struct rt_rtmp_dmabuf {
466/* Control block (Descriptor) for all ring descriptor DMA operation, buffer must be */ 467/* Control block (Descriptor) for all ring descriptor DMA operation, buffer must be */
467/* contiguous physical memory. char stored the binding Rx packet descriptor */ 468/* contiguous physical memory. char stored the binding Rx packet descriptor */
468/* which won't be released, driver has to wait until upper layer return the packet */ 469/* which won't be released, driver has to wait until upper layer return the packet */
469/* before giveing up this rx ring descriptor to ASIC. NDIS_BUFFER is assocaited pair */ 470/* before giving up this rx ring descriptor to ASIC. NDIS_BUFFER is associated pair */
470/* to describe the packet buffer. For Tx, char stored the tx packet descriptor */ 471/* to describe the packet buffer. For Tx, char stored the tx packet descriptor */
471/* which driver should ACK upper layer when the tx is physically done or failed. */ 472/* which driver should ACK upper layer when the tx is physically done or failed. */
472/* */ 473/* */
@@ -602,7 +603,7 @@ struct rt_counter_ralink {
602}; 603};
603 604
604struct rt_counter_drs { 605struct rt_counter_drs {
605 /* to record the each TX rate's quality. 0 is best, the bigger the worse. */ 606 /* record each TX rate's quality. 0 is best, the bigger the worse. */
606 u16 TxQuality[MAX_STEP_OF_TX_RATE_SWITCH]; 607 u16 TxQuality[MAX_STEP_OF_TX_RATE_SWITCH];
607 u8 PER[MAX_STEP_OF_TX_RATE_SWITCH]; 608 u8 PER[MAX_STEP_OF_TX_RATE_SWITCH];
608 u8 TxRateUpPenalty; /* extra # of second penalty due to last unstable condition */ 609 u8 TxRateUpPenalty; /* extra # of second penalty due to last unstable condition */
@@ -719,7 +720,7 @@ struct rt_fragment_frame {
719/* Packet information for NdisQueryPacket */ 720/* Packet information for NdisQueryPacket */
720/* */ 721/* */
721struct rt_packet_info { 722struct rt_packet_info {
722 u32 PhysicalBufferCount; /* Physical breaks of buffer descripor chained */ 723 u32 PhysicalBufferCount; /* Physical breaks of buffer descriptor chained */
723 u32 BufferCount; /* Number of Buffer descriptor chained */ 724 u32 BufferCount; /* Number of Buffer descriptor chained */
724 u32 TotalPacketLength; /* Self explained */ 725 u32 TotalPacketLength; /* Self explained */
725 char *pFirstBuffer; /* Pointer to first buffer descriptor */ 726 char *pFirstBuffer; /* Pointer to first buffer descriptor */
@@ -846,8 +847,8 @@ typedef enum _ABGBAND_STATE_ {
846/* Power save method control */ 847/* Power save method control */
847typedef union _PS_CONTROL { 848typedef union _PS_CONTROL {
848 struct { 849 struct {
849 unsigned long EnablePSinIdle:1; /* Enable radio off when not connect to AP. radio on only when sitesurvey, */ 850 unsigned long EnablePSinIdle:1; /* Enable radio off when not connected to AP. radio on only when sitesurvey, */
850 unsigned long EnableNewPS:1; /* Enable new Chip power save fucntion . New method can only be applied in chip version after 2872. and PCIe. */ 851 unsigned long EnableNewPS:1; /* Enable new Chip power save function . New method can only be applied in chip version after 2872. and PCIe. */
851 unsigned long rt30xxPowerMode:2; /* Power Level Mode for rt30xx chip */ 852 unsigned long rt30xxPowerMode:2; /* Power Level Mode for rt30xx chip */
852 unsigned long rt30xxFollowHostASPM:1; /* Card Follows Host's setting for rt30xx chip. */ 853 unsigned long rt30xxFollowHostASPM:1; /* Card Follows Host's setting for rt30xx chip. */
853 unsigned long rt30xxForceASPMTest:1; /* Force enable L1 for rt30xx chip. This has higher priority than rt30xxFollowHostASPM Mode. */ 854 unsigned long rt30xxForceASPMTest:1; /* Force enable L1 for rt30xx chip. This has higher priority than rt30xxFollowHostASPM Mode. */
@@ -1117,8 +1118,8 @@ struct rt_beacon_sync {
1117 unsigned long TimIELocationInBeacon[HW_BEACON_MAX_COUNT]; 1118 unsigned long TimIELocationInBeacon[HW_BEACON_MAX_COUNT];
1118 unsigned long CapabilityInfoLocationInBeacon[HW_BEACON_MAX_COUNT]; 1119 unsigned long CapabilityInfoLocationInBeacon[HW_BEACON_MAX_COUNT];
1119 BOOLEAN EnableBeacon; /* trigger to enable beacon transmission. */ 1120 BOOLEAN EnableBeacon; /* trigger to enable beacon transmission. */
1120 u8 BeaconBitMap; /* NOTE: If the MAX_MBSSID_NUM is larger than 8, this parameter need to change. */ 1121 u8 BeaconBitMap; /* NOTE: If the MAX_MBSSID_NUM is larger than 8, this parameter needs to change. */
1121 u8 DtimBitOn; /* NOTE: If the MAX_MBSSID_NUM is larger than 8, this parameter need to change. */ 1122 u8 DtimBitOn; /* NOTE: If the MAX_MBSSID_NUM is larger than 8, this parameter needs to change. */
1122}; 1123};
1123#endif /* RTMP_MAC_USB // */ 1124#endif /* RTMP_MAC_USB // */
1124 1125
@@ -1211,7 +1212,7 @@ struct rt_common_config {
1211 /*BOOLEAN bAutoTxRateSwitch; */ 1212 /*BOOLEAN bAutoTxRateSwitch; */
1212 u8 MinTxRate; /* RATE_1, RATE_2, RATE_5_5, RATE_11 */ 1213 u8 MinTxRate; /* RATE_1, RATE_2, RATE_5_5, RATE_11 */
1213 u8 RtsRate; /* RATE_xxx */ 1214 u8 RtsRate; /* RATE_xxx */
1214 HTTRANSMIT_SETTING MlmeTransmit; /* MGMT frame PHY rate setting when operatin at Ht rate. */ 1215 HTTRANSMIT_SETTING MlmeTransmit; /* MGMT frame PHY rate setting when operation at Ht rate. */
1215 u8 MlmeRate; /* RATE_xxx, used to send MLME frames */ 1216 u8 MlmeRate; /* RATE_xxx, used to send MLME frames */
1216 u8 BasicMlmeRate; /* Default Rate for sending MLME frames */ 1217 u8 BasicMlmeRate; /* Default Rate for sending MLME frames */
1217 1218
@@ -1264,7 +1265,7 @@ struct rt_common_config {
1264 struct rt_ht_capability_ie HtCapability; 1265 struct rt_ht_capability_ie HtCapability;
1265 struct rt_add_ht_info_ie AddHTInfo; /* Useful as AP. */ 1266 struct rt_add_ht_info_ie AddHTInfo; /* Useful as AP. */
1266 /*This IE is used with channel switch announcement element when changing to a new 40MHz. */ 1267 /*This IE is used with channel switch announcement element when changing to a new 40MHz. */
1267 /*This IE is included in channel switch ammouncement frames 7.4.1.5, beacons, probe Rsp. */ 1268 /*This IE is included in channel switch announcement frames 7.4.1.5, beacons, probe Rsp. */
1268 struct rt_new_ext_chan_ie NewExtChanOffset; /*7.3.2.20A, 1 if extension channel is above the control channel, 3 if below, 0 if not present */ 1269 struct rt_new_ext_chan_ie NewExtChanOffset; /*7.3.2.20A, 1 if extension channel is above the control channel, 3 if below, 0 if not present */
1269 1270
1270 BOOLEAN bHTProtect; 1271 BOOLEAN bHTProtect;
@@ -1329,7 +1330,7 @@ struct rt_sta_admin_config {
1329 /* GROUP 1 - */ 1330 /* GROUP 1 - */
1330 /* User configuration loaded from Registry, E2PROM or OID_xxx. These settings describe */ 1331 /* User configuration loaded from Registry, E2PROM or OID_xxx. These settings describe */
1331 /* the user intended configuration, but not necessary fully equal to the final */ 1332 /* the user intended configuration, but not necessary fully equal to the final */
1332 /* settings in ACTIVE BSS after negotiation/compromize with the BSS holder (either */ 1333 /* settings in ACTIVE BSS after negotiation/compromise with the BSS holder (either */
1333 /* AP or IBSS holder). */ 1334 /* AP or IBSS holder). */
1334 /* Once initialized, user configuration can only be changed via OID_xxx */ 1335 /* Once initialized, user configuration can only be changed via OID_xxx */
1335 u8 BssType; /* BSS_INFRA or BSS_ADHOC */ 1336 u8 BssType; /* BSS_INFRA or BSS_ADHOC */
@@ -1386,12 +1387,12 @@ struct rt_sta_admin_config {
1386 1387
1387 /* For WPA countermeasures */ 1388 /* For WPA countermeasures */
1388 unsigned long LastMicErrorTime; /* record last MIC error time */ 1389 unsigned long LastMicErrorTime; /* record last MIC error time */
1389 unsigned long MicErrCnt; /* Should be 0, 1, 2, then reset to zero (after disassoiciation). */ 1390 unsigned long MicErrCnt; /* Should be 0, 1, 2, then reset to zero (after disassociation). */
1390 BOOLEAN bBlockAssoc; /* Block associate attempt for 60 seconds after counter measure occurred. */ 1391 BOOLEAN bBlockAssoc; /* Block associate attempt for 60 seconds after counter measure occurred. */
1391 /* For WPA-PSK supplicant state */ 1392 /* For WPA-PSK supplicant state */
1392 WPA_STATE WpaState; /* Default is SS_NOTUSE and handled by microsoft 802.1x */ 1393 WPA_STATE WpaState; /* Default is SS_NOTUSE and handled by microsoft 802.1x */
1393 u8 ReplayCounter[8]; 1394 u8 ReplayCounter[8];
1394 u8 ANonce[32]; /* ANonce for WPA-PSK from aurhenticator */ 1395 u8 ANonce[32]; /* ANonce for WPA-PSK from auhenticator */
1395 u8 SNonce[32]; /* SNonce for WPA-PSK */ 1396 u8 SNonce[32]; /* SNonce for WPA-PSK */
1396 1397
1397 u8 LastSNR0; /* last received BEACON's SNR */ 1398 u8 LastSNR0; /* last received BEACON's SNR */
@@ -1423,7 +1424,7 @@ struct rt_sta_admin_config {
1423 u8 RSNIE_Len; 1424 u8 RSNIE_Len;
1424 u8 RSN_IE[MAX_LEN_OF_RSNIE]; /* The content saved here should be little-endian format. */ 1425 u8 RSN_IE[MAX_LEN_OF_RSNIE]; /* The content saved here should be little-endian format. */
1425 1426
1426 unsigned long CLBusyBytes; /* Save the total bytes received durning channel load scan time */ 1427 unsigned long CLBusyBytes; /* Save the total bytes received during channel load scan time */
1427 u16 RPIDensity[8]; /* Array for RPI density collection */ 1428 u16 RPIDensity[8]; /* Array for RPI density collection */
1428 1429
1429 u8 RMReqCnt; /* Number of measurement request saved. */ 1430 u8 RMReqCnt; /* Number of measurement request saved. */
@@ -1489,9 +1490,9 @@ struct rt_sta_admin_config {
1489 BOOLEAN bForceTxBurst; /* 1: force enble TX PACKET BURST, 0: disable */ 1490 BOOLEAN bForceTxBurst; /* 1: force enble TX PACKET BURST, 0: disable */
1490}; 1491};
1491 1492
1492/* This data structure keep the current active BSS/IBSS's configuration that this STA */ 1493/* This data structure keeps the current active BSS/IBSS's configuration that this STA */
1493/* had agreed upon joining the network. Which means these parameters are usually decided */ 1494/* had agreed upon joining the network. Which means these parameters are usually decided */
1494/* by the BSS/IBSS creator instead of user configuration. Data in this data structurre */ 1495/* by the BSS/IBSS creator instead of user configuration. Data in this data structure */
1495/* is valid only when either ADHOC_ON(pAd) or INFRA_ON(pAd) is TRUE. */ 1496/* is valid only when either ADHOC_ON(pAd) or INFRA_ON(pAd) is TRUE. */
1496/* Normally, after SCAN or failed roaming attempts, we need to recover back to */ 1497/* Normally, after SCAN or failed roaming attempts, we need to recover back to */
1497/* the current active settings. */ 1498/* the current active settings. */
@@ -1519,7 +1520,7 @@ struct rt_mac_table_entry {
1519 /*Choose 1 from ValidAsWDS and ValidAsCLI to validize. */ 1520 /*Choose 1 from ValidAsWDS and ValidAsCLI to validize. */
1520 BOOLEAN ValidAsCLI; /* Sta mode, set this TRUE after Linkup,too. */ 1521 BOOLEAN ValidAsCLI; /* Sta mode, set this TRUE after Linkup,too. */
1521 BOOLEAN ValidAsWDS; /* This is WDS Entry. only for AP mode. */ 1522 BOOLEAN ValidAsWDS; /* This is WDS Entry. only for AP mode. */
1522 BOOLEAN ValidAsApCli; /*This is a AP-Client entry, only for AP mode which enable AP-Client functions. */ 1523 BOOLEAN ValidAsApCli; /* This is a AP-Client entry, only for AP mode which enable AP-Client functions. */
1523 BOOLEAN ValidAsMesh; 1524 BOOLEAN ValidAsMesh;
1524 BOOLEAN ValidAsDls; /* This is DLS Entry. only for STA mode. */ 1525 BOOLEAN ValidAsDls; /* This is DLS Entry. only for STA mode. */
1525 BOOLEAN isCached; 1526 BOOLEAN isCached;
@@ -1527,7 +1528,7 @@ struct rt_mac_table_entry {
1527 1528
1528 u8 EnqueueEapolStartTimerRunning; /* Enqueue EAPoL-Start for triggering EAP SM */ 1529 u8 EnqueueEapolStartTimerRunning; /* Enqueue EAPoL-Start for triggering EAP SM */
1529 /*jan for wpa */ 1530 /*jan for wpa */
1530 /* record which entry revoke MIC Failure , if it leaves the BSS itself, AP won't update aMICFailTime MIB */ 1531 /* record which entry revoke MIC Failure, if it leaves the BSS itself, AP won't update aMICFailTime MIB */
1531 u8 CMTimerRunning; 1532 u8 CMTimerRunning;
1532 u8 apidx; /* MBSS number */ 1533 u8 apidx; /* MBSS number */
1533 u8 RSNIE_Len; 1534 u8 RSNIE_Len;
@@ -1722,7 +1723,7 @@ struct rt_rtmp_adapter {
1722 unsigned long Rt3xxRalinkLinkCtrl; /* USed for 3090F chip */ 1723 unsigned long Rt3xxRalinkLinkCtrl; /* USed for 3090F chip */
1723 u16 DeviceID; /* Read from PCI config */ 1724 u16 DeviceID; /* Read from PCI config */
1724 unsigned long AccessBBPFailCount; 1725 unsigned long AccessBBPFailCount;
1725 BOOLEAN bPCIclkOff; /* flag that indicate if the PICE power status in Configuration SPace.. */ 1726 BOOLEAN bPCIclkOff; /* flag that indicates if the PICE power status in Configuration Space.. */
1726 BOOLEAN bPCIclkOffDisableTx; /* */ 1727 BOOLEAN bPCIclkOffDisableTx; /* */
1727 1728
1728 BOOLEAN brt30xxBanMcuCmd; /*when = 0xff means all commands are ok to set . */ 1729 BOOLEAN brt30xxBanMcuCmd; /*when = 0xff means all commands are ok to set . */
@@ -1871,9 +1872,9 @@ struct rt_rtmp_adapter {
1871 /* ---------------------------- */ 1872 /* ---------------------------- */
1872 u8 RfIcType; /* RFIC_xxx */ 1873 u8 RfIcType; /* RFIC_xxx */
1873 unsigned long RfFreqOffset; /* Frequency offset for channel switching */ 1874 unsigned long RfFreqOffset; /* Frequency offset for channel switching */
1874 struct rt_rtmp_rf_regs LatchRfRegs; /* latch th latest RF programming value since RF IC doesn't support READ */ 1875 struct rt_rtmp_rf_regs LatchRfRegs; /* latch the latest RF programming value since RF IC doesn't support READ */
1875 1876
1876 EEPROM_ANTENNA_STRUC Antenna; /* Since ANtenna definition is different for a & g. We need to save it for future reference. */ 1877 EEPROM_ANTENNA_STRUC Antenna; /* Since Antenna definition is different for a & g. We need to save it for future reference. */
1877 EEPROM_NIC_CONFIG2_STRUC NicConfig2; 1878 EEPROM_NIC_CONFIG2_STRUC NicConfig2;
1878 1879
1879 /* This soft Rx Antenna Diversity mechanism is used only when user set */ 1880 /* This soft Rx Antenna Diversity mechanism is used only when user set */
@@ -1990,7 +1991,7 @@ struct rt_rtmp_adapter {
1990 struct rt_common_config CommonCfg; 1991 struct rt_common_config CommonCfg;
1991 struct rt_mlme Mlme; 1992 struct rt_mlme Mlme;
1992 1993
1993 /* AP needs those vaiables for site survey feature. */ 1994 /* AP needs those variables for site survey feature. */
1994 struct rt_mlme_aux MlmeAux; /* temporary settings used during MLME state machine */ 1995 struct rt_mlme_aux MlmeAux; /* temporary settings used during MLME state machine */
1995 struct rt_bss_table ScanTab; /* store the latest SCAN result */ 1996 struct rt_bss_table ScanTab; /* store the latest SCAN result */
1996 1997
@@ -2012,7 +2013,7 @@ struct rt_rtmp_adapter {
2012 /* various Counters */ 2013 /* various Counters */
2013 struct rt_counter_802_3 Counters8023; /* 802.3 counters */ 2014 struct rt_counter_802_3 Counters8023; /* 802.3 counters */
2014 struct rt_counter_802_11 WlanCounters; /* 802.11 MIB counters */ 2015 struct rt_counter_802_11 WlanCounters; /* 802.11 MIB counters */
2015 struct rt_counter_ralink RalinkCounters; /* Ralink propriety counters */ 2016 struct rt_counter_ralink RalinkCounters; /* Ralink proprietary counters */
2016 struct rt_counter_drs DrsCounters; /* counters for Dynamic TX Rate Switching */ 2017 struct rt_counter_drs DrsCounters; /* counters for Dynamic TX Rate Switching */
2017 struct rt_private PrivateInfo; /* Private information & counters */ 2018 struct rt_private PrivateInfo; /* Private information & counters */
2018 2019
@@ -2024,7 +2025,7 @@ struct rt_rtmp_adapter {
2024 u16 Sequence; 2025 u16 Sequence;
2025 2026
2026 /* Control disconnect / connect event generation */ 2027 /* Control disconnect / connect event generation */
2027 /*+++Didn't used anymore */ 2028 /*+++Not used anymore */
2028 unsigned long LinkDownTime; 2029 unsigned long LinkDownTime;
2029 /*--- */ 2030 /*--- */
2030 unsigned long LastRxRate; 2031 unsigned long LastRxRate;
@@ -2036,7 +2037,7 @@ struct rt_rtmp_adapter {
2036 unsigned long ExtraInfo; /* Extra information for displaying status */ 2037 unsigned long ExtraInfo; /* Extra information for displaying status */
2037 unsigned long SystemErrorBitmap; /* b0: E2PROM version error */ 2038 unsigned long SystemErrorBitmap; /* b0: E2PROM version error */
2038 2039
2039 /*+++Didn't used anymore */ 2040 /*+++Not used anymore */
2040 unsigned long MacIcVersion; /* MAC/BBP serial interface issue solved after ver.D */ 2041 unsigned long MacIcVersion; /* MAC/BBP serial interface issue solved after ver.D */
2041 /*--- */ 2042 /*--- */
2042 2043
@@ -2089,7 +2090,7 @@ struct rt_rtmp_adapter {
2089 unsigned long BulkOutReq; 2090 unsigned long BulkOutReq;
2090 unsigned long BulkOutComplete; 2091 unsigned long BulkOutComplete;
2091 unsigned long BulkOutCompleteOther; 2092 unsigned long BulkOutCompleteOther;
2092 unsigned long BulkOutCompleteCancel; /* seems not use now? */ 2093 unsigned long BulkOutCompleteCancel; /* seems not used now? */
2093 unsigned long BulkInReq; 2094 unsigned long BulkInReq;
2094 unsigned long BulkInComplete; 2095 unsigned long BulkInComplete;
2095 unsigned long BulkInCompleteFail; 2096 unsigned long BulkInCompleteFail;
@@ -2196,9 +2197,9 @@ struct rt_rx_blk {
2196struct rt_tx_blk { 2197struct rt_tx_blk {
2197 u8 QueIdx; 2198 u8 QueIdx;
2198 u8 TxFrameType; /* Indicate the Transmission type of the all frames in one batch */ 2199 u8 TxFrameType; /* Indicate the Transmission type of the all frames in one batch */
2199 u8 TotalFrameNum; /* Total frame number want to send-out in one batch */ 2200 u8 TotalFrameNum; /* Total frame number that wants to send-out in one batch */
2200 u16 TotalFragNum; /* Total frame fragments required in one batch */ 2201 u16 TotalFragNum; /* Total frame fragments required in one batch */
2201 u16 TotalFrameLen; /* Total length of all frames want to send-out in one batch */ 2202 u16 TotalFrameLen; /* Total length of all frames that wants to send-out in one batch */
2202 2203
2203 struct rt_queue_header TxPacketList; 2204 struct rt_queue_header TxPacketList;
2204 struct rt_mac_table_entry *pMacEntry; /* NULL: packet with 802.11 RA field is multicast/broadcast address */ 2205 struct rt_mac_table_entry *pMacEntry; /* NULL: packet with 802.11 RA field is multicast/broadcast address */
@@ -2207,7 +2208,7 @@ struct rt_tx_blk {
2207 /* Following structure used for the characteristics of a specific packet. */ 2208 /* Following structure used for the characteristics of a specific packet. */
2208 void *pPacket; 2209 void *pPacket;
2209 u8 *pSrcBufHeader; /* Reference to the head of sk_buff->data */ 2210 u8 *pSrcBufHeader; /* Reference to the head of sk_buff->data */
2210 u8 *pSrcBufData; /* Reference to the sk_buff->data, will changed depends on hanlding progresss */ 2211 u8 *pSrcBufData; /* Reference to the sk_buff->data, will change depending on the handling progresss */
2211 u32 SrcBufLen; /* Length of packet payload which not including Layer 2 header */ 2212 u32 SrcBufLen; /* Length of packet payload which not including Layer 2 header */
2212 u8 *pExtraLlcSnapEncap; /* NULL means no extra LLC/SNAP is required */ 2213 u8 *pExtraLlcSnapEncap; /* NULL means no extra LLC/SNAP is required */
2213 u8 HeaderBuf[128]; /* TempBuffer for TX_INFO + TX_WI + 802.11 Header + padding + AMSDU SubHeader + LLC/SNAP */ 2214 u8 HeaderBuf[128]; /* TempBuffer for TX_INFO + TX_WI + 802.11 Header + padding + AMSDU SubHeader + LLC/SNAP */
@@ -2219,7 +2220,7 @@ struct rt_tx_blk {
2219 u8 apidx; /* The interface associated to this packet */ 2220 u8 apidx; /* The interface associated to this packet */
2220 u8 Wcid; /* The MAC entry associated to this packet */ 2221 u8 Wcid; /* The MAC entry associated to this packet */
2221 u8 UserPriority; /* priority class of packet */ 2222 u8 UserPriority; /* priority class of packet */
2222 u8 FrameGap; /* what kind of IFS this packet use */ 2223 u8 FrameGap; /* what kind of IFS does this packet use */
2223 u8 MpduReqNum; /* number of fragments of this frame */ 2224 u8 MpduReqNum; /* number of fragments of this frame */
2224 u8 TxRate; /* TODO: Obsoleted? Should change to MCS? */ 2225 u8 TxRate; /* TODO: Obsoleted? Should change to MCS? */
2225 u8 CipherAlg; /* cipher alogrithm */ 2226 u8 CipherAlg; /* cipher alogrithm */
diff --git a/drivers/staging/rt2860/rtmp_def.h b/drivers/staging/rt2860/rtmp_def.h
index 9c54bacb845..6ac617e7c9b 100644
--- a/drivers/staging/rt2860/rtmp_def.h
+++ b/drivers/staging/rt2860/rtmp_def.h
@@ -31,10 +31,11 @@
31 Miniport related definition header 31 Miniport related definition header
32 32
33 Revision History: 33 Revision History:
34 Who When What 34 Who When What
35 -------- ---------- ---------------------------------------------- 35 -------- ---------- ----------------------------------------------
36 Paul Lin 08-01-2002 created 36 Paul Lin 08-01-2002 created
37 John Chang 08-05-2003 add definition for 11g & other drafts 37 John Chang 08-05-2003 add definition for 11g & other drafts
38 Justin P. Mattock 11/07/2010 Fix some typos
38*/ 39*/
39#ifndef __RTMP_DEF_H__ 40#ifndef __RTMP_DEF_H__
40#define __RTMP_DEF_H__ 41#define __RTMP_DEF_H__
@@ -111,11 +112,11 @@
111 WMM Note: If memory of your system is not much, please reduce the definition; 112 WMM Note: If memory of your system is not much, please reduce the definition;
112 or when you do WMM test, the queue for low priority AC will be full, i.e. 113 or when you do WMM test, the queue for low priority AC will be full, i.e.
113 TX_RING_SIZE + MAX_PACKETS_IN_QUEUE packets for the AC will be buffered in 114 TX_RING_SIZE + MAX_PACKETS_IN_QUEUE packets for the AC will be buffered in
114 WLAN, maybe no any packet buffer can be got in Ethernet driver. 115 WLAN, maybe no packet buffers can get into the Ethernet driver.
115 116
116 Sometimes no packet buffer can be got in Ethernet driver, the system will 117 Sometimes no packet buffer can be get into the Ethernet driver, the system will
117 send flow control packet to the sender to slow down its sending rate. 118 send flow control packet to the sender to slow down its sending rate.
118 So no WMM can be saw in the air. 119 So no WMM can be seen in the air.
119*/ 120*/
120 121
121/* 122/*
@@ -125,7 +126,7 @@
125 And in rt_main_end.c, clConfig.clNum = RX_RING_SIZE * 3; is changed to 126 And in rt_main_end.c, clConfig.clNum = RX_RING_SIZE * 3; is changed to
126 clConfig.clNum = RX_RING_SIZE * 4; 127 clConfig.clNum = RX_RING_SIZE * 4;
127*/ 128*/
128/* TODO: For VxWorks the size is 256. Shall we cahnge the value as 256 for all OS????? */ 129/* TODO: For VxWorks the size is 256. Shall we change the value as 256 for all OS? */
129#define MAX_PACKETS_IN_QUEUE (512) /*(512) // to pass WMM A5-WPAPSK */ 130#define MAX_PACKETS_IN_QUEUE (512) /*(512) // to pass WMM A5-WPAPSK */
130 131
131#define MAX_PACKETS_IN_MCAST_PS_QUEUE 32 132#define MAX_PACKETS_IN_MCAST_PS_QUEUE 32
@@ -171,7 +172,7 @@
171#define fRTMP_ADAPTER_SCAN_2040 0x04000000 172#define fRTMP_ADAPTER_SCAN_2040 0x04000000
172#define fRTMP_ADAPTER_RADIO_MEASUREMENT 0x08000000 173#define fRTMP_ADAPTER_RADIO_MEASUREMENT 0x08000000
173 174
174#define fRTMP_ADAPTER_START_UP 0x10000000 /*Devive already initialized and enabled Tx/Rx. */ 175#define fRTMP_ADAPTER_START_UP 0x10000000 /*Device already initialized and enabled Tx/Rx. */
175#define fRTMP_ADAPTER_MEDIA_STATE_CHANGE 0x20000000 176#define fRTMP_ADAPTER_MEDIA_STATE_CHANGE 0x20000000
176#define fRTMP_ADAPTER_IDLE_RADIO_OFF 0x40000000 177#define fRTMP_ADAPTER_IDLE_RADIO_OFF 0x40000000
177 178
@@ -205,8 +206,8 @@
205#define fRTMP_PS_SET_PCI_CLK_OFF_COMMAND 0x00000002 206#define fRTMP_PS_SET_PCI_CLK_OFF_COMMAND 0x00000002
206/* Indicate driver should disable kick off hardware to send packets from now. */ 207/* Indicate driver should disable kick off hardware to send packets from now. */
207#define fRTMP_PS_DISABLE_TX 0x00000004 208#define fRTMP_PS_DISABLE_TX 0x00000004
208/* Indicate driver should IMMEDIATELY fo to sleep after receiving AP's beacon in which doesn't indicate unicate nor multicast packets for me */ 209/* Indicate driver should IMMEDIATELY go to sleep after receiving AP's beacon in which doesn't indicate unicate nor multicast packets for me */
209/*. This flag is used ONLY in RTMPHandleRxDoneInterrupt routine. */ 210/* This flag is used ONLY in RTMPHandleRxDoneInterrupt routine. */
210#define fRTMP_PS_GO_TO_SLEEP_NOW 0x00000008 211#define fRTMP_PS_GO_TO_SLEEP_NOW 0x00000008
211#define fRTMP_PS_TOGGLE_L1 0x00000010 /* Use Toggle L1 mechanism for rt28xx PCIe */ 212#define fRTMP_PS_TOGGLE_L1 0x00000010 /* Use Toggle L1 mechanism for rt28xx PCIe */
212 213
@@ -303,7 +304,7 @@
303 304
304/* WDS definition */ 305/* WDS definition */
305#define MAX_WDS_ENTRY 4 306#define MAX_WDS_ENTRY 4
306#define WDS_PAIRWISE_KEY_OFFSET 60 /* WDS links uses pairwise key#60 ~ 63 in ASIC pairwise key table */ 307#define WDS_PAIRWISE_KEY_OFFSET 60 /* WDS links use pairwise key#60 ~ 63 in ASIC pairwise key table */
307 308
308#define WDS_DISABLE_MODE 0 309#define WDS_DISABLE_MODE 0
309#define WDS_RESTRICT_MODE 1 310#define WDS_RESTRICT_MODE 1
@@ -559,7 +560,7 @@
559#define IE_ADD_HT2 53 /* 802.11n d1. ADDITIONAL HT CAPABILITY. ELEMENT ID TBD */ 560#define IE_ADD_HT2 53 /* 802.11n d1. ADDITIONAL HT CAPABILITY. ELEMENT ID TBD */
560 561
561/* For 802.11n D3.03 */ 562/* For 802.11n D3.03 */
562/*#define IE_NEW_EXT_CHA_OFFSET 62 // 802.11n d1. New extension channel offset elemet */ 563/*#define IE_NEW_EXT_CHA_OFFSET 62 // 802.11n d1. New extension channel offset element */
563#define IE_SECONDARY_CH_OFFSET 62 /* 802.11n D3.03 Secondary Channel Offset element */ 564#define IE_SECONDARY_CH_OFFSET 62 /* 802.11n D3.03 Secondary Channel Offset element */
564#define IE_WAPI 68 /* WAPI information element */ 565#define IE_WAPI 68 /* WAPI information element */
565#define IE_2040_BSS_COEXIST 72 /* 802.11n D3.0.3 */ 566#define IE_2040_BSS_COEXIST 72 /* 802.11n D3.0.3 */
@@ -678,7 +679,7 @@
678 679
679#define ACT_MACHINE_BASE 0 680#define ACT_MACHINE_BASE 0
680 681
681/*Those PEER_xx_CATE number is based on real Categary value in IEEE spec. Please don'es modify it by your self. */ 682/*Those PEER_xx_CATE number is based on real Categary value in IEEE spec. Please do not modify it by your self. */
682/*Category */ 683/*Category */
683#define MT2_PEER_SPECTRUM_CATE 0 684#define MT2_PEER_SPECTRUM_CATE 0
684#define MT2_PEER_QOS_CATE 1 685#define MT2_PEER_QOS_CATE 1
@@ -748,7 +749,7 @@
748 749
749#define ACT_FUNC_SIZE (MAX_ACT_STATE * MAX_ACT_MSG) 750#define ACT_FUNC_SIZE (MAX_ACT_STATE * MAX_ACT_MSG)
750/* */ 751/* */
751/* STA's AUTHENTICATION state machine: states, evvents, total function # */ 752/* STA's AUTHENTICATION state machine: states, events, total function # */
752/* */ 753/* */
753#define AUTH_REQ_IDLE 0 754#define AUTH_REQ_IDLE 0
754#define AUTH_WAIT_SEQ2 1 755#define AUTH_WAIT_SEQ2 1
@@ -948,7 +949,7 @@
948#define BLOCK_ACK 0x60 /* b6:5 = 11 */ 949#define BLOCK_ACK 0x60 /* b6:5 = 11 */
949 950
950/* */ 951/* */
951/* rtmp_data.c use these definition */ 952/* rtmp_data.c uses this definition */
952/* */ 953/* */
953#define LENGTH_802_11 24 954#define LENGTH_802_11 24
954#define LENGTH_802_11_AND_H 30 955#define LENGTH_802_11_AND_H 30
@@ -1288,7 +1289,7 @@
1288#define IW_STA_LINKDOWN_EVENT_FLAG 0x0210 1289#define IW_STA_LINKDOWN_EVENT_FLAG 0x0210
1289#define IW_SCAN_COMPLETED_EVENT_FLAG 0x0211 1290#define IW_SCAN_COMPLETED_EVENT_FLAG 0x0211
1290#define IW_SCAN_ENQUEUE_FAIL_EVENT_FLAG 0x0212 1291#define IW_SCAN_ENQUEUE_FAIL_EVENT_FLAG 0x0212
1291/* if add new system event flag, please upadte the IW_SYS_EVENT_FLAG_END */ 1292/* if add new system event flag, please update the IW_SYS_EVENT_FLAG_END */
1292#define IW_SYS_EVENT_FLAG_END 0x0212 1293#define IW_SYS_EVENT_FLAG_END 0x0212
1293#define IW_SYS_EVENT_TYPE_NUM (IW_SYS_EVENT_FLAG_END - IW_SYS_EVENT_FLAG_START + 1) 1294#define IW_SYS_EVENT_TYPE_NUM (IW_SYS_EVENT_FLAG_END - IW_SYS_EVENT_FLAG_START + 1)
1294/* For system event - end */ 1295/* For system event - end */
@@ -1305,7 +1306,7 @@
1305#define IW_SPOOF_DEAUTH_EVENT_FLAG 0x0307 1306#define IW_SPOOF_DEAUTH_EVENT_FLAG 0x0307
1306#define IW_SPOOF_UNKNOWN_MGMT_EVENT_FLAG 0x0308 1307#define IW_SPOOF_UNKNOWN_MGMT_EVENT_FLAG 0x0308
1307#define IW_REPLAY_ATTACK_EVENT_FLAG 0x0309 1308#define IW_REPLAY_ATTACK_EVENT_FLAG 0x0309
1308/* if add new spoof attack event flag, please upadte the IW_SPOOF_EVENT_FLAG_END */ 1309/* if add new spoof attack event flag, please update the IW_SPOOF_EVENT_FLAG_END */
1309#define IW_SPOOF_EVENT_FLAG_END 0x0309 1310#define IW_SPOOF_EVENT_FLAG_END 0x0309
1310#define IW_SPOOF_EVENT_TYPE_NUM (IW_SPOOF_EVENT_FLAG_END - IW_SPOOF_EVENT_FLAG_START + 1) 1311#define IW_SPOOF_EVENT_TYPE_NUM (IW_SPOOF_EVENT_FLAG_END - IW_SPOOF_EVENT_FLAG_START + 1)
1311/* For spoof attack event - end */ 1312/* For spoof attack event - end */
@@ -1319,7 +1320,7 @@
1319#define IW_FLOOD_DISASSOC_EVENT_FLAG 0x0404 1320#define IW_FLOOD_DISASSOC_EVENT_FLAG 0x0404
1320#define IW_FLOOD_DEAUTH_EVENT_FLAG 0x0405 1321#define IW_FLOOD_DEAUTH_EVENT_FLAG 0x0405
1321#define IW_FLOOD_EAP_REQ_EVENT_FLAG 0x0406 1322#define IW_FLOOD_EAP_REQ_EVENT_FLAG 0x0406
1322/* if add new flooding attack event flag, please upadte the IW_FLOOD_EVENT_FLAG_END */ 1323/* if add new flooding attack event flag, please update the IW_FLOOD_EVENT_FLAG_END */
1323#define IW_FLOOD_EVENT_FLAG_END 0x0406 1324#define IW_FLOOD_EVENT_FLAG_END 0x0406
1324#define IW_FLOOD_EVENT_TYPE_NUM (IW_FLOOD_EVENT_FLAG_END - IW_FLOOD_EVENT_FLAG_START + 1) 1325#define IW_FLOOD_EVENT_TYPE_NUM (IW_FLOOD_EVENT_FLAG_END - IW_FLOOD_EVENT_FLAG_START + 1)
1325/* For flooding attack - end */ 1326/* For flooding attack - end */
diff --git a/drivers/staging/rt2860/rtmp_timer.h b/drivers/staging/rt2860/rtmp_timer.h
index 28b8ac6e835..15b62874350 100644
--- a/drivers/staging/rt2860/rtmp_timer.h
+++ b/drivers/staging/rt2860/rtmp_timer.h
@@ -28,13 +28,14 @@
28 rtmp_timer.h 28 rtmp_timer.h
29 29
30 Abstract: 30 Abstract:
31 Ralink Wireless Driver timer related data structures and delcarations 31 Ralink Wireless Driver timer related data structures and declarations
32 32
33 Revision History: 33 Revision History:
34 Who When What 34 Who When What
35 -------- ---------- ---------------------------------------------- 35 -------- ---------- ----------------------------------------------
36 Name Date Modification logs 36 Name Date Modification logs
37 Shiang Tu Aug-28-2008 init version 37 Shiang Tu Aug-28-2008 init version
38 Justin P. Mattock 11/07/2010 Fix a typo
38 39
39*/ 40*/
40 41
@@ -51,8 +52,8 @@
51 52
52/* ----------------- Timer Related MARCO ---------------*/ 53/* ----------------- Timer Related MARCO ---------------*/
53/* In some os or chipset, we have a lot of timer functions and will read/write register, */ 54/* In some os or chipset, we have a lot of timer functions and will read/write register, */
54/* it's not allowed in Linux USB sub-system to do it ( because of sleep issue when */ 55/* it's not allowed in Linux USB sub-system to do it ( because of sleep issue when */
55/* submit to ctrl pipe). So we need a wrapper function to take care it. */ 56/* submit to ctrl pipe). So we need a wrapper function to take care it. */
56 57
57#ifdef RTMP_TIMER_TASK_SUPPORT 58#ifdef RTMP_TIMER_TASK_SUPPORT
58typedef void(*RTMP_TIMER_TASK_HANDLE) (void *SystemSpecific1, 59typedef void(*RTMP_TIMER_TASK_HANDLE) (void *SystemSpecific1,
diff --git a/drivers/staging/rt2860/spectrum.h b/drivers/staging/rt2860/spectrum.h
index 648fd632b60..4c325ba7ba2 100644
--- a/drivers/staging/rt2860/spectrum.h
+++ b/drivers/staging/rt2860/spectrum.h
@@ -37,7 +37,7 @@ char RTMP_GetTxPwr(struct rt_rtmp_adapter *pAd, IN HTTRANSMIT_SETTING HTTxMode);
37 ========================================================================== 37 ==========================================================================
38 Description: 38 Description:
39 Prepare Measurement request action frame and enqueue it into 39 Prepare Measurement request action frame and enqueue it into
40 management queue waiting for transmition. 40 management queue waiting for transmission.
41 41
42 Parametrs: 42 Parametrs:
43 1. the destination mac address of the frame. 43 1. the destination mac address of the frame.
@@ -60,7 +60,7 @@ void MakeMeasurementReqFrame(struct rt_rtmp_adapter *pAd,
60 ========================================================================== 60 ==========================================================================
61 Description: 61 Description:
62 Prepare Measurement report action frame and enqueue it into 62 Prepare Measurement report action frame and enqueue it into
63 management queue waiting for transmition. 63 management queue waiting for transmission.
64 64
65 Parametrs: 65 Parametrs:
66 1. the destination mac address of the frame. 66 1. the destination mac address of the frame.
@@ -80,7 +80,7 @@ void EnqueueMeasurementRep(struct rt_rtmp_adapter *pAd,
80 ========================================================================== 80 ==========================================================================
81 Description: 81 Description:
82 Prepare TPC Request action frame and enqueue it into 82 Prepare TPC Request action frame and enqueue it into
83 management queue waiting for transmition. 83 management queue waiting for transmission.
84 84
85 Parametrs: 85 Parametrs:
86 1. the destination mac address of the frame. 86 1. the destination mac address of the frame.
@@ -94,7 +94,7 @@ void EnqueueTPCReq(struct rt_rtmp_adapter *pAd, u8 *pDA, u8 DialogToken);
94 ========================================================================== 94 ==========================================================================
95 Description: 95 Description:
96 Prepare TPC Report action frame and enqueue it into 96 Prepare TPC Report action frame and enqueue it into
97 management queue waiting for transmition. 97 management queue waiting for transmission.
98 98
99 Parametrs: 99 Parametrs:
100 1. the destination mac address of the frame. 100 1. the destination mac address of the frame.
@@ -110,7 +110,7 @@ void EnqueueTPCRep(struct rt_rtmp_adapter *pAd,
110 ========================================================================== 110 ==========================================================================
111 Description: 111 Description:
112 Prepare Channel Switch Announcement action frame and enqueue it into 112 Prepare Channel Switch Announcement action frame and enqueue it into
113 management queue waiting for transmition. 113 management queue waiting for transmission.
114 114
115 Parametrs: 115 Parametrs:
116 1. the destination mac address of the frame. 116 1. the destination mac address of the frame.
@@ -126,7 +126,7 @@ void EnqueueChSwAnn(struct rt_rtmp_adapter *pAd,
126/* 126/*
127 ========================================================================== 127 ==========================================================================
128 Description: 128 Description:
129 Spectrun action frames Handler such as channel switch annoucement, 129 Spectrun action frames Handler such as channel switch announcement,
130 measurement report, measurement request actions frames. 130 measurement report, measurement request actions frames.
131 131
132 Parametrs: 132 Parametrs:
diff --git a/drivers/staging/rt2860/sta/assoc.c b/drivers/staging/rt2860/sta/assoc.c
index b7efb0b6b3f..ab0a83bf76e 100644
--- a/drivers/staging/rt2860/sta/assoc.c
+++ b/drivers/staging/rt2860/sta/assoc.c
@@ -32,7 +32,8 @@
32 Revision History: 32 Revision History:
33 Who When What 33 Who When What
34 -------- ---------- ---------------------------------------------- 34 -------- ---------- ----------------------------------------------
35 John 2004-9-3 porting from RT2500 35 John 2004-9-3 porting from RT2500
36 Justin P. Mattock 11/07/2010 Fix typos
36*/ 37*/
37#include "../rt_config.h" 38#include "../rt_config.h"
38 39
@@ -277,10 +278,10 @@ void MlmeAssocReqAction(struct rt_rtmp_adapter *pAd, struct rt_mlme_queue_elem *
277 u16 VarIesOffset; 278 u16 VarIesOffset;
278 u16 Status; 279 u16 Status;
279 280
280 /* Block all authentication request durning WPA block period */ 281 /* Block all authentication request during WPA block period */
281 if (pAd->StaCfg.bBlockAssoc == TRUE) { 282 if (pAd->StaCfg.bBlockAssoc == TRUE) {
282 DBGPRINT(RT_DEBUG_TRACE, 283 DBGPRINT(RT_DEBUG_TRACE,
283 ("ASSOC - Block Assoc request durning WPA block period!\n")); 284 ("ASSOC - Block Assoc request during WPA block period!\n"));
284 pAd->Mlme.AssocMachine.CurrState = ASSOC_IDLE; 285 pAd->Mlme.AssocMachine.CurrState = ASSOC_IDLE;
285 Status = MLME_STATE_MACHINE_REJECT; 286 Status = MLME_STATE_MACHINE_REJECT;
286 MlmeEnqueue(pAd, MLME_CNTL_STATE_MACHINE, MT2_ASSOC_CONF, 2, 287 MlmeEnqueue(pAd, MLME_CNTL_STATE_MACHINE, MT2_ASSOC_CONF, 2,
@@ -605,10 +606,10 @@ void MlmeReassocReqAction(struct rt_rtmp_adapter *pAd, struct rt_mlme_queue_elem
605 u8 *pOutBuffer = NULL; 606 u8 *pOutBuffer = NULL;
606 u16 Status; 607 u16 Status;
607 608
608 /* Block all authentication request durning WPA block period */ 609 /* Block all authentication request during WPA block period */
609 if (pAd->StaCfg.bBlockAssoc == TRUE) { 610 if (pAd->StaCfg.bBlockAssoc == TRUE) {
610 DBGPRINT(RT_DEBUG_TRACE, 611 DBGPRINT(RT_DEBUG_TRACE,
611 ("ASSOC - Block ReAssoc request durning WPA block period!\n")); 612 ("ASSOC - Block ReAssoc request during WPA block period!\n"));
612 pAd->Mlme.AssocMachine.CurrState = ASSOC_IDLE; 613 pAd->Mlme.AssocMachine.CurrState = ASSOC_IDLE;
613 Status = MLME_STATE_MACHINE_REJECT; 614 Status = MLME_STATE_MACHINE_REJECT;
614 MlmeEnqueue(pAd, MLME_CNTL_STATE_MACHINE, MT2_REASSOC_CONF, 2, 615 MlmeEnqueue(pAd, MLME_CNTL_STATE_MACHINE, MT2_REASSOC_CONF, 2,
@@ -1001,7 +1002,7 @@ void AssocPostProc(struct rt_rtmp_adapter *pAd, u8 *pAddr2, u16 CapabilityInfo,
1001 pAd->MlmeAux.CapabilityInfo = 1002 pAd->MlmeAux.CapabilityInfo =
1002 CapabilityInfo & SUPPORTED_CAPABILITY_INFO; 1003 CapabilityInfo & SUPPORTED_CAPABILITY_INFO;
1003 1004
1004 /* Some HT AP might lost WMM IE. We add WMM ourselves. beacuase HT requires QoS on. */ 1005 /* Some HT AP might lost WMM IE. We add WMM ourselves. because HT requires QoS on. */
1005 if ((HtCapabilityLen > 0) && (pEdcaParm->bValid == FALSE)) { 1006 if ((HtCapabilityLen > 0) && (pEdcaParm->bValid == FALSE)) {
1006 pEdcaParm->bValid = TRUE; 1007 pEdcaParm->bValid = TRUE;
1007 pEdcaParm->Aifsn[0] = 3; 1008 pEdcaParm->Aifsn[0] = 3;
diff --git a/drivers/staging/rt2860/sta/auth.c b/drivers/staging/rt2860/sta/auth.c
index 404bd220679..a2bfafddb20 100644
--- a/drivers/staging/rt2860/sta/auth.c
+++ b/drivers/staging/rt2860/sta/auth.c
@@ -32,7 +32,8 @@
32 Revision History: 32 Revision History:
33 Who When What 33 Who When What
34 -------- ---------- ---------------------------------------------- 34 -------- ---------- ----------------------------------------------
35 John 2004-9-3 porting from RT2500 35 John 2004-9-3 porting from RT2500
36 Justin P. Mattock 11/07/2010 Fix typos
36*/ 37*/
37#include "../rt_config.h" 38#include "../rt_config.h"
38 39
@@ -455,10 +456,10 @@ BOOLEAN AUTH_ReqSend(struct rt_rtmp_adapter *pAd,
455 u8 *pOutBuffer = NULL; 456 u8 *pOutBuffer = NULL;
456 unsigned long FrameLen = 0, tmp = 0; 457 unsigned long FrameLen = 0, tmp = 0;
457 458
458 /* Block all authentication request durning WPA block period */ 459 /* Block all authentication request during WPA block period */
459 if (pAd->StaCfg.bBlockAssoc == TRUE) { 460 if (pAd->StaCfg.bBlockAssoc == TRUE) {
460 DBGPRINT(RT_DEBUG_TRACE, 461 DBGPRINT(RT_DEBUG_TRACE,
461 ("%s - Block Auth request durning WPA block period!\n", 462 ("%s - Block Auth request during WPA block period!\n",
462 pSMName)); 463 pSMName));
463 pAd->Mlme.AuthMachine.CurrState = AUTH_REQ_IDLE; 464 pAd->Mlme.AuthMachine.CurrState = AUTH_REQ_IDLE;
464 Status = MLME_STATE_MACHINE_REJECT; 465 Status = MLME_STATE_MACHINE_REJECT;
diff --git a/drivers/staging/rt2860/sta/connect.c b/drivers/staging/rt2860/sta/connect.c
index c380551c035..4b2c84e6509 100644
--- a/drivers/staging/rt2860/sta/connect.c
+++ b/drivers/staging/rt2860/sta/connect.c
@@ -32,7 +32,8 @@
32 Revision History: 32 Revision History:
33 Who When What 33 Who When What
34 -------- ---------- ---------------------------------------------- 34 -------- ---------- ----------------------------------------------
35 John 2004-08-08 Major modification from RT2560 35 John 2004-08-08 Major modification from RT2560
36 Justin P. Mattock 11/07/2010 Fix typos
36*/ 37*/
37#include "../rt_config.h" 38#include "../rt_config.h"
38 39
@@ -64,7 +65,7 @@ u8 CipherSuiteWpaNoneAesLen =
64 65
65/* The following MACRO is called after 1. starting an new IBSS, 2. successfully JOIN an IBSS, */ 66/* The following MACRO is called after 1. starting an new IBSS, 2. successfully JOIN an IBSS, */
66/* or 3. successfully ASSOCIATE to a BSS, 4. successfully RE_ASSOCIATE to a BSS */ 67/* or 3. successfully ASSOCIATE to a BSS, 4. successfully RE_ASSOCIATE to a BSS */
67/* All settings successfuly negotiated furing MLME state machines become final settings */ 68/* All settings successfuly negotiated firing MLME state machines become final settings */
68/* and are copied to pAd->StaActive */ 69/* and are copied to pAd->StaActive */
69#define COPY_SETTINGS_FROM_MLME_AUX_TO_ACTIVE_CFG(_pAd) \ 70#define COPY_SETTINGS_FROM_MLME_AUX_TO_ACTIVE_CFG(_pAd) \
70{ \ 71{ \
@@ -553,7 +554,7 @@ void CntlOidRTBssidProc(struct rt_rtmp_adapter *pAd, struct rt_mlme_queue_elem *
553 NdisMoveMemory(&pAd->MlmeAux.SsidBssTab.BssEntry[0], 554 NdisMoveMemory(&pAd->MlmeAux.SsidBssTab.BssEntry[0],
554 &pAd->ScanTab.BssEntry[BssIdx], sizeof(struct rt_bss_entry)); 555 &pAd->ScanTab.BssEntry[BssIdx], sizeof(struct rt_bss_entry));
555 556
556 /* Add SSID into MlmeAux for site surey joining hidden SSID */ 557 /* Add SSID into MlmeAux for site survey joining hidden SSID */
557 pAd->MlmeAux.SsidLen = pAd->ScanTab.BssEntry[BssIdx].SsidLen; 558 pAd->MlmeAux.SsidLen = pAd->ScanTab.BssEntry[BssIdx].SsidLen;
558 NdisMoveMemory(pAd->MlmeAux.Ssid, pAd->ScanTab.BssEntry[BssIdx].Ssid, 559 NdisMoveMemory(pAd->MlmeAux.Ssid, pAd->ScanTab.BssEntry[BssIdx].Ssid,
559 pAd->MlmeAux.SsidLen); 560 pAd->MlmeAux.SsidLen);
@@ -666,7 +667,7 @@ void CntlOidRTBssidProc(struct rt_rtmp_adapter *pAd, struct rt_mlme_queue_elem *
666} 667}
667 668
668/* Roaming is the only external request triggering CNTL state machine */ 669/* Roaming is the only external request triggering CNTL state machine */
669/* despite of other "SET OID" operation. All "SET OID" related oerations */ 670/* despite of other "SET OID" operation. All "SET OID" related operations */
670/* happen in sequence, because no other SET OID will be sent to this device */ 671/* happen in sequence, because no other SET OID will be sent to this device */
671/* until the the previous SET operation is complete (successful o failed). */ 672/* until the the previous SET operation is complete (successful o failed). */
672/* So, how do we quarantee this ROAMING request won't corrupt other "SET OID"? */ 673/* So, how do we quarantee this ROAMING request won't corrupt other "SET OID"? */
@@ -1224,7 +1225,7 @@ void LinkUp(struct rt_rtmp_adapter *pAd, u8 BssType)
1224 /* Change to AP channel */ 1225 /* Change to AP channel */
1225 if ((pAd->CommonCfg.CentralChannel > pAd->CommonCfg.Channel) 1226 if ((pAd->CommonCfg.CentralChannel > pAd->CommonCfg.Channel)
1226 && (pAd->MlmeAux.HtCapability.HtCapInfo.ChannelWidth == BW_40)) { 1227 && (pAd->MlmeAux.HtCapability.HtCapInfo.ChannelWidth == BW_40)) {
1227 /* Must using 40MHz. */ 1228 /* Must use 40MHz. */
1228 pAd->CommonCfg.BBPCurrentBW = BW_40; 1229 pAd->CommonCfg.BBPCurrentBW = BW_40;
1229 AsicSwitchChannel(pAd, pAd->CommonCfg.CentralChannel, FALSE); 1230 AsicSwitchChannel(pAd, pAd->CommonCfg.CentralChannel, FALSE);
1230 AsicLockChannel(pAd, pAd->CommonCfg.CentralChannel); 1231 AsicLockChannel(pAd, pAd->CommonCfg.CentralChannel);
@@ -1259,7 +1260,7 @@ void LinkUp(struct rt_rtmp_adapter *pAd, u8 BssType)
1259 } else if ((pAd->CommonCfg.CentralChannel < pAd->CommonCfg.Channel) 1260 } else if ((pAd->CommonCfg.CentralChannel < pAd->CommonCfg.Channel)
1260 && (pAd->MlmeAux.HtCapability.HtCapInfo.ChannelWidth == 1261 && (pAd->MlmeAux.HtCapability.HtCapInfo.ChannelWidth ==
1261 BW_40)) { 1262 BW_40)) {
1262 /* Must using 40MHz. */ 1263 /* Must use 40MHz. */
1263 pAd->CommonCfg.BBPCurrentBW = BW_40; 1264 pAd->CommonCfg.BBPCurrentBW = BW_40;
1264 AsicSwitchChannel(pAd, pAd->CommonCfg.CentralChannel, FALSE); 1265 AsicSwitchChannel(pAd, pAd->CommonCfg.CentralChannel, FALSE);
1265 AsicLockChannel(pAd, pAd->CommonCfg.CentralChannel); 1266 AsicLockChannel(pAd, pAd->CommonCfg.CentralChannel);
@@ -1343,12 +1344,12 @@ void LinkUp(struct rt_rtmp_adapter *pAd, u8 BssType)
1343 AsicSetSlotTime(pAd, TRUE); 1344 AsicSetSlotTime(pAd, TRUE);
1344 AsicSetEdcaParm(pAd, &pAd->CommonCfg.APEdcaParm); 1345 AsicSetEdcaParm(pAd, &pAd->CommonCfg.APEdcaParm);
1345 1346
1346 /* Call this for RTS protectionfor legacy rate, we will always enable RTS threshold, but normally it will not hit */ 1347 /* Call this for RTS protection for legacy rate, we will always enable RTS threshold, but normally it will not hit */
1347 AsicUpdateProtect(pAd, 0, (OFDMSETPROTECT | CCKSETPROTECT), TRUE, 1348 AsicUpdateProtect(pAd, 0, (OFDMSETPROTECT | CCKSETPROTECT), TRUE,
1348 FALSE); 1349 FALSE);
1349 1350
1350 if ((pAd->StaActive.SupportedPhyInfo.bHtEnable == TRUE)) { 1351 if ((pAd->StaActive.SupportedPhyInfo.bHtEnable == TRUE)) {
1351 /* Update HT protectionfor based on AP's operating mode. */ 1352 /* Update HT protection for based on AP's operating mode. */
1352 if (pAd->MlmeAux.AddHtInfo.AddHtInfo2.NonGfPresent == 1) { 1353 if (pAd->MlmeAux.AddHtInfo.AddHtInfo2.NonGfPresent == 1) {
1353 AsicUpdateProtect(pAd, 1354 AsicUpdateProtect(pAd,
1354 pAd->MlmeAux.AddHtInfo.AddHtInfo2. 1355 pAd->MlmeAux.AddHtInfo.AddHtInfo2.
@@ -1530,7 +1531,7 @@ void LinkUp(struct rt_rtmp_adapter *pAd, u8 BssType)
1530 /* Add BSSID to WCID search table */ 1531 /* Add BSSID to WCID search table */
1531 AsicUpdateRxWCIDTable(pAd, BSSID_WCID, pAd->CommonCfg.Bssid); 1532 AsicUpdateRxWCIDTable(pAd, BSSID_WCID, pAd->CommonCfg.Bssid);
1532 1533
1533 /* If WEP is enabled, add paiewise and shared key */ 1534 /* If WEP is enabled, add pairwise and shared key */
1534 if (((pAd->StaCfg.WpaSupplicantUP) && 1535 if (((pAd->StaCfg.WpaSupplicantUP) &&
1535 (pAd->StaCfg.WepStatus == Ndis802_11WEPEnabled) && 1536 (pAd->StaCfg.WepStatus == Ndis802_11WEPEnabled) &&
1536 (pAd->StaCfg.PortSecured == WPA_802_1X_PORT_SECURED)) || 1537 (pAd->StaCfg.PortSecured == WPA_802_1X_PORT_SECURED)) ||
@@ -1681,9 +1682,9 @@ void LinkUp(struct rt_rtmp_adapter *pAd, u8 BssType)
1681 pAd->Mlme.PeriodicRound = 0; 1682 pAd->Mlme.PeriodicRound = 0;
1682 pAd->Mlme.OneSecPeriodicRound = 0; 1683 pAd->Mlme.OneSecPeriodicRound = 0;
1683 pAd->bConfigChanged = FALSE; /* Reset config flag */ 1684 pAd->bConfigChanged = FALSE; /* Reset config flag */
1684 pAd->ExtraInfo = GENERAL_LINK_UP; /* Update extra information to link is up */ 1685 pAd->ExtraInfo = GENERAL_LINK_UP; /* Update extra information after link is up */
1685 1686
1686 /* Set asic auto fall back */ 1687 /* Set basic auto fall back */
1687 { 1688 {
1688 u8 *pTable; 1689 u8 *pTable;
1689 u8 TableSize = 0; 1690 u8 TableSize = 0;
@@ -1854,8 +1855,8 @@ void LinkUp(struct rt_rtmp_adapter *pAd, u8 BssType)
1854 Note: 1855 Note:
1855 We need more information to know it's this requst from AP. 1856 We need more information to know it's this requst from AP.
1856 If yes! we need to do extra handling, for example, remove the WPA key. 1857 If yes! we need to do extra handling, for example, remove the WPA key.
1857 Otherwise on 4-way handshaking will faied, since the WPA key didn't be 1858 Otherwise on 4-way handshaking will fail, since the WPA key didn't get
1858 remove while auto reconnect. 1859 removed while auto reconnect.
1859 Disconnect request from AP, it means we will start afresh 4-way handshaking 1860 Disconnect request from AP, it means we will start afresh 4-way handshaking
1860 on WPA mode. 1861 on WPA mode.
1861 1862
@@ -1870,9 +1871,9 @@ void LinkDown(struct rt_rtmp_adapter *pAd, IN BOOLEAN IsReqFromAP)
1870 return; 1871 return;
1871 1872
1872 RTMP_CLEAR_PSFLAG(pAd, fRTMP_PS_GO_TO_SLEEP_NOW); 1873 RTMP_CLEAR_PSFLAG(pAd, fRTMP_PS_GO_TO_SLEEP_NOW);
1873 /*Comment the codes, beasue the line 2291 call the same function. */ 1874 /* Comment the codes, because the line 2291 call the same function. */
1874 /*RTMPCancelTimer(&pAd->Mlme.PsPollTimer, &Cancelled); */ 1875 /* RTMPCancelTimer(&pAd->Mlme.PsPollTimer, &Cancelled); */
1875 /* Not allow go to sleep within linkdown function. */ 1876 /* Not allowed go to sleep within the linkdown function. */
1876 RTMP_CLEAR_PSFLAG(pAd, fRTMP_PS_CAN_GO_SLEEP); 1877 RTMP_CLEAR_PSFLAG(pAd, fRTMP_PS_CAN_GO_SLEEP);
1877 1878
1878 if (pAd->CommonCfg.bWirelessEvent) { 1879 if (pAd->CommonCfg.bWirelessEvent) {
@@ -1970,7 +1971,7 @@ void LinkDown(struct rt_rtmp_adapter *pAd, IN BOOLEAN IsReqFromAP)
1970 /* Set LED */ 1971 /* Set LED */
1971 RTMPSetLED(pAd, LED_LINK_DOWN); 1972 RTMPSetLED(pAd, LED_LINK_DOWN);
1972 pAd->LedIndicatorStrength = 0xF0; 1973 pAd->LedIndicatorStrength = 0xF0;
1973 RTMPSetSignalLED(pAd, -100); /* Force signal strength Led to be turned off, firmware is not done it. */ 1974 RTMPSetSignalLED(pAd, -100); /* Force signal strength Led to be turned off, firmware has not done it. */
1974 1975
1975 AsicDisableSync(pAd); 1976 AsicDisableSync(pAd);
1976 1977
diff --git a/drivers/staging/rt2860/sta/rtmp_data.c b/drivers/staging/rt2860/sta/rtmp_data.c
index 23879b7cd49..d7c2012be8a 100644
--- a/drivers/staging/rt2860/sta/rtmp_data.c
+++ b/drivers/staging/rt2860/sta/rtmp_data.c
@@ -31,7 +31,8 @@
31 Data path subroutines 31 Data path subroutines
32 32
33 Revision History: 33 Revision History:
34 Who When What 34 Who When What
35 Justin P. Mattock 11/07/2010 Fix typos
35 -------- ---------- ---------------------------------------------- 36 -------- ---------- ----------------------------------------------
36*/ 37*/
37#include "../rt_config.h" 38#include "../rt_config.h"
@@ -257,8 +258,8 @@ void STARxDataFrameAnnounce(struct rt_rtmp_adapter *pAd,
257 && (pAd->CommonCfg.bDisableReordering == 0)) { 258 && (pAd->CommonCfg.bDisableReordering == 0)) {
258 Indicate_AMPDU_Packet(pAd, pRxBlk, FromWhichBSSID); 259 Indicate_AMPDU_Packet(pAd, pRxBlk, FromWhichBSSID);
259 } else { 260 } else {
260 /* Determin the destination of the EAP frame */ 261 /* Determine the destination of the EAP frame */
261 /* to WPA state machine or upper layer */ 262 /* to WPA state machine or upper layer */
262 STARxEAPOLFrameIndicate(pAd, pEntry, pRxBlk, 263 STARxEAPOLFrameIndicate(pAd, pEntry, pRxBlk,
263 FromWhichBSSID); 264 FromWhichBSSID);
264 } 265 }
@@ -853,7 +854,7 @@ Return Value:
853 NONE 854 NONE
854 855
855Note: 856Note:
856 This function do early checking and classification for send-out packet. 857 This function does early checking and classification for send-out packet.
857 You only can put OS-depened & STA related code in here. 858 You only can put OS-depened & STA related code in here.
858======================================================================== 859========================================================================
859*/ 860*/
@@ -943,7 +944,7 @@ int STASendPacket(struct rt_rtmp_adapter *pAd, void *pPacket)
943 DBGPRINT(RT_DEBUG_ERROR, 944 DBGPRINT(RT_DEBUG_ERROR,
944 ("STASendPacket --> pSrcBufVA == NULL !SrcBufLen=%x\n", 945 ("STASendPacket --> pSrcBufVA == NULL !SrcBufLen=%x\n",
945 SrcBufLen)); 946 SrcBufLen));
946 /* Resourece is low, system did not allocate virtual address */ 947 /* Resource is low, system did not allocate virtual address */
947 /* return NDIS_STATUS_FAILURE directly to upper layer */ 948 /* return NDIS_STATUS_FAILURE directly to upper layer */
948 RELEASE_NDIS_PACKET(pAd, pPacket, NDIS_STATUS_FAILURE); 949 RELEASE_NDIS_PACKET(pAd, pPacket, NDIS_STATUS_FAILURE);
949 return NDIS_STATUS_FAILURE; 950 return NDIS_STATUS_FAILURE;
@@ -979,7 +980,7 @@ int STASendPacket(struct rt_rtmp_adapter *pAd, void *pPacket)
979 DBGPRINT(RT_DEBUG_ERROR, 980 DBGPRINT(RT_DEBUG_ERROR,
980 ("STASendPacket->Cannot find pEntry(%pM) in MacTab!\n", 981 ("STASendPacket->Cannot find pEntry(%pM) in MacTab!\n",
981 pSrcBufVA)); 982 pSrcBufVA));
982 /* Resourece is low, system did not allocate virtual address */ 983 /* Resource is low, system did not allocate virtual address */
983 /* return NDIS_STATUS_FAILURE directly to upper layer */ 984 /* return NDIS_STATUS_FAILURE directly to upper layer */
984 RELEASE_NDIS_PACKET(pAd, pPacket, NDIS_STATUS_FAILURE); 985 RELEASE_NDIS_PACKET(pAd, pPacket, NDIS_STATUS_FAILURE);
985 return NDIS_STATUS_FAILURE; 986 return NDIS_STATUS_FAILURE;
@@ -1057,9 +1058,9 @@ int STASendPacket(struct rt_rtmp_adapter *pAd, void *pPacket)
1057 1058
1058 /* STEP 2. Check the requirement of RTS: */ 1059 /* STEP 2. Check the requirement of RTS: */
1059 /* If multiple fragment required, RTS is required only for the first fragment */ 1060 /* If multiple fragment required, RTS is required only for the first fragment */
1060 /* if the fragment size large than RTS threshold */ 1061 /* if the fragment size is larger than RTS threshold */
1061 /* For RT28xx, Let ASIC send RTS/CTS */ 1062 /* For RT28xx, Let ASIC send RTS/CTS */
1062/* RTMP_SET_PACKET_RTS(pPacket, 0); */ 1063 /* RTMP_SET_PACKET_RTS(pPacket, 0); */
1063 if (NumberOfFrag > 1) 1064 if (NumberOfFrag > 1)
1064 RTSRequired = 1065 RTSRequired =
1065 (pAd->CommonCfg.FragmentThreshold > 1066 (pAd->CommonCfg.FragmentThreshold >
@@ -1171,8 +1172,8 @@ int STASendPacket(struct rt_rtmp_adapter *pAd, void *pPacket)
1171 ======================================================================== 1172 ========================================================================
1172 1173
1173 Routine Description: 1174 Routine Description:
1174 This subroutine will scan through releative ring descriptor to find 1175 This subroutine will scan through relative ring descriptor to find
1175 out avaliable free ring descriptor and compare with request size. 1176 out available free ring descriptor and compare with request size.
1176 1177
1177 Arguments: 1178 Arguments:
1178 pAd Pointer to our adapter 1179 pAd Pointer to our adapter
@@ -1588,7 +1589,7 @@ static inline u8 *STA_Build_ARalink_Frame_Header(struct rt_rtmp_adapter *pAd,
1588 pHeaderBufPtr += 2; 1589 pHeaderBufPtr += 2;
1589 pTxBlk->MpduHeaderLen += 2; 1590 pTxBlk->MpduHeaderLen += 2;
1590 } 1591 }
1591 /* padding at front of LLC header. LLC header should at 4-bytes aligment. */ 1592 /* padding at front of LLC header. LLC header should at 4-bytes alignment. */
1592 pTxBlk->HdrPadLen = (unsigned long)pHeaderBufPtr; 1593 pTxBlk->HdrPadLen = (unsigned long)pHeaderBufPtr;
1593 pHeaderBufPtr = (u8 *)ROUND_UP(pHeaderBufPtr, 4); 1594 pHeaderBufPtr = (u8 *)ROUND_UP(pHeaderBufPtr, 4);
1594 pTxBlk->HdrPadLen = (unsigned long)(pHeaderBufPtr - pTxBlk->HdrPadLen); 1595 pTxBlk->HdrPadLen = (unsigned long)(pHeaderBufPtr - pTxBlk->HdrPadLen);
@@ -2014,7 +2015,7 @@ void STA_Legacy_Frame_Tx(struct rt_rtmp_adapter *pAd, struct rt_tx_blk *pTxBlk)
2014 pHeaderBufPtr += 2; 2015 pHeaderBufPtr += 2;
2015 pTxBlk->MpduHeaderLen += 2; 2016 pTxBlk->MpduHeaderLen += 2;
2016 } 2017 }
2017 /* The remaining content of MPDU header should locate at 4-octets aligment */ 2018 /* The remaining content of MPDU header should locate at 4-octets alignment */
2018 pTxBlk->HdrPadLen = (unsigned long)pHeaderBufPtr; 2019 pTxBlk->HdrPadLen = (unsigned long)pHeaderBufPtr;
2019 pHeaderBufPtr = (u8 *)ROUND_UP(pHeaderBufPtr, 4); 2020 pHeaderBufPtr = (u8 *)ROUND_UP(pHeaderBufPtr, 4);
2020 pTxBlk->HdrPadLen = (unsigned long)(pHeaderBufPtr - pTxBlk->HdrPadLen); 2021 pTxBlk->HdrPadLen = (unsigned long)(pHeaderBufPtr - pTxBlk->HdrPadLen);
@@ -2114,7 +2115,7 @@ void STA_ARalink_Frame_Tx(struct rt_rtmp_adapter *pAd, struct rt_tx_blk *pTxBlk)
2114 STA_Build_ARalink_Frame_Header(pAd, pTxBlk); 2115 STA_Build_ARalink_Frame_Header(pAd, pTxBlk);
2115 2116
2116 /* It's ok write the TxWI here, because the TxWI->MPDUtotalByteCount */ 2117 /* It's ok write the TxWI here, because the TxWI->MPDUtotalByteCount */
2117 /* will be updated after final frame was handled. */ 2118 /* will be updated after final frame was handled. */
2118 RTMPWriteTxWI_Data(pAd, 2119 RTMPWriteTxWI_Data(pAd,
2119 (struct rt_txwi *) (&pTxBlk-> 2120 (struct rt_txwi *) (&pTxBlk->
2120 HeaderBuf 2121 HeaderBuf
@@ -2291,8 +2292,8 @@ void STA_Fragment_Frame_Tx(struct rt_rtmp_adapter *pAd, struct rt_tx_blk *pTxBlk
2291 pTxBlk->pExtraLlcSnapEncap, pTxBlk->pKey, 2292 pTxBlk->pExtraLlcSnapEncap, pTxBlk->pKey,
2292 0); 2293 0);
2293 2294
2294 /* NOTE: DON'T refer the skb->len directly after following copy. Becasue the length is not adjust */ 2295 /* NOTE: DON'T refer the skb->len directly after following copy. Because the length is not adjusted */
2295 /* to correct lenght, refer to pTxBlk->SrcBufLen for the packet length in following progress. */ 2296 /* to correct length, refer to pTxBlk->SrcBufLen for the packet length in following progress. */
2296 NdisMoveMemory(pTxBlk->pSrcBufData + pTxBlk->SrcBufLen, 2297 NdisMoveMemory(pTxBlk->pSrcBufData + pTxBlk->SrcBufLen,
2297 &pAd->PrivateInfo.Tx.MIC[0], 8); 2298 &pAd->PrivateInfo.Tx.MIC[0], 8);
2298 /*skb_put((RTPKT_TO_OSPKT(pTxBlk->pPacket))->tail, 8); */ 2299 /*skb_put((RTPKT_TO_OSPKT(pTxBlk->pPacket))->tail, 8); */
@@ -2301,7 +2302,7 @@ void STA_Fragment_Frame_Tx(struct rt_rtmp_adapter *pAd, struct rt_tx_blk *pTxBlk
2301 pTxBlk->CipherAlg = CIPHER_TKIP_NO_MIC; 2302 pTxBlk->CipherAlg = CIPHER_TKIP_NO_MIC;
2302 } 2303 }
2303 /* */ 2304 /* */
2304 /* calcuate the overhead bytes that encryption algorithm may add. This */ 2305 /* calculate the overhead bytes that encryption algorithm may add. This */
2305 /* affects the calculate of "duration" field */ 2306 /* affects the calculate of "duration" field */
2306 /* */ 2307 /* */
2307 if ((pTxBlk->CipherAlg == CIPHER_WEP64) 2308 if ((pTxBlk->CipherAlg == CIPHER_WEP64)
diff --git a/drivers/staging/rt2860/sta/sanity.c b/drivers/staging/rt2860/sta/sanity.c
index 8f9fd19be15..0c32604f2d3 100644
--- a/drivers/staging/rt2860/sta/sanity.c
+++ b/drivers/staging/rt2860/sta/sanity.c
@@ -32,7 +32,8 @@
32 Revision History: 32 Revision History:
33 Who When What 33 Who When What
34 -------- ---------- ---------------------------------------------- 34 -------- ---------- ----------------------------------------------
35 John Chang 2004-09-01 add WMM support 35 John Chang 2004-09-01 add WMM support
36 Justin P. Mattock 11/07/2010 Fix typos
36*/ 37*/
37#include "../rt_config.h" 38#include "../rt_config.h"
38 39
@@ -118,7 +119,7 @@ BOOLEAN PeerAssocRspSanity(struct rt_rtmp_adapter *pAd, void * pMsg, unsigned lo
118 NdisMoveMemory(pAid, &pFrame->Octet[4], 2); 119 NdisMoveMemory(pAid, &pFrame->Octet[4], 2);
119 Length += 2; 120 Length += 2;
120 121
121 /* Aid already swaped byte order in RTMPFrameEndianChange() for big endian platform */ 122 /* Aid already swapped byte order in RTMPFrameEndianChange() for big endian platform */
122 *pAid = (*pAid) & 0x3fff; /* AID is low 14-bit */ 123 *pAid = (*pAid) & 0x3fff; /* AID is low 14-bit */
123 124
124 /* -- get supported rates from payload and advance the pointer */ 125 /* -- get supported rates from payload and advance the pointer */
diff --git a/drivers/staging/rt2860/sta/sync.c b/drivers/staging/rt2860/sta/sync.c
index 747d3c6d185..05007d9c9b6 100644
--- a/drivers/staging/rt2860/sta/sync.c
+++ b/drivers/staging/rt2860/sta/sync.c
@@ -32,8 +32,9 @@
32 Revision History: 32 Revision History:
33 Who When What 33 Who When What
34 -------- ---------- ---------------------------------------------- 34 -------- ---------- ----------------------------------------------
35 John Chang 2004-09-01 modified for rt2561/2661 35 John Chang 2004-09-01 modified for rt2561/2661
36 Jan Lee 2006-08-01 modified for rt2860 for 802.11n 36 Jan Lee 2006-08-01 modified for rt2860 for 802.11n
37 Justin P. Mattock 11/07/2010 Fix typos
37*/ 38*/
38#include "../rt_config.h" 39#include "../rt_config.h"
39 40
@@ -233,9 +234,9 @@ void MlmeScanReqAction(struct rt_rtmp_adapter *pAd, struct rt_mlme_queue_elem *E
233 RTMPSuspendMsduTransmission(pAd); 234 RTMPSuspendMsduTransmission(pAd);
234 235
235 /* */ 236 /* */
236 /* To prevent data lost. */ 237 /* To prevent data loss. */
237 /* Send an NULL data with turned PSM bit on to current associated AP before SCAN progress. */ 238 /* Send a NULL data with turned PSM bit on to current associated AP before SCAN progress. */
238 /* And should send an NULL data with turned PSM bit off to AP, when scan progress done */ 239 /* And should send a NULL data with turned PSM bit off to AP, when scan progress done */
239 /* */ 240 /* */
240 if (OPSTATUS_TEST_FLAG(pAd, fOP_STATUS_MEDIA_STATE_CONNECTED) 241 if (OPSTATUS_TEST_FLAG(pAd, fOP_STATUS_MEDIA_STATE_CONNECTED)
241 && (INFRA_ON(pAd))) { 242 && (INFRA_ON(pAd))) {
@@ -750,9 +751,9 @@ void PeerBeaconAtJoinAction(struct rt_rtmp_adapter *pAd, struct rt_mlme_queue_el
750 751
751 /* BEACON from desired BSS/IBSS found. We should be able to decide most */ 752 /* BEACON from desired BSS/IBSS found. We should be able to decide most */
752 /* BSS parameters here. */ 753 /* BSS parameters here. */
753 /* Q. But what happen if this JOIN doesn't conclude a successful ASSOCIATEION? */ 754 /* Q. But what happen if this JOIN doesn't conclude a successful ASSOCIATION? */
754 /* Do we need to receover back all parameters belonging to previous BSS? */ 755 /* Do we need to recover back all parameters belonging to previous BSS? */
755 /* A. Should be not. There's no back-door recover to previous AP. It still need */ 756 /* A. Should be not. There's no back-door recover to previous AP. It still needs */
756 /* a new JOIN-AUTH-ASSOC sequence. */ 757 /* a new JOIN-AUTH-ASSOC sequence. */
757 if (MAC_ADDR_EQUAL(pAd->MlmeAux.Bssid, Bssid)) { 758 if (MAC_ADDR_EQUAL(pAd->MlmeAux.Bssid, Bssid)) {
758 DBGPRINT(RT_DEBUG_TRACE, 759 DBGPRINT(RT_DEBUG_TRACE,
@@ -876,7 +877,7 @@ void PeerBeaconAtJoinAction(struct rt_rtmp_adapter *pAd, struct rt_mlme_queue_el
876 pAd->MlmeAux.CfpMaxDuration = Cf.CfpMaxDuration; 877 pAd->MlmeAux.CfpMaxDuration = Cf.CfpMaxDuration;
877 pAd->MlmeAux.APRalinkIe = RalinkIe; 878 pAd->MlmeAux.APRalinkIe = RalinkIe;
878 879
879 /* Copy AP's supported rate to MlmeAux for creating assoication request */ 880 /* Copy AP's supported rate to MlmeAux for creating association request */
880 /* Also filter out not supported rate */ 881 /* Also filter out not supported rate */
881 pAd->MlmeAux.SupRateLen = SupRateLen; 882 pAd->MlmeAux.SupRateLen = SupRateLen;
882 NdisMoveMemory(pAd->MlmeAux.SupRate, SupRate, 883 NdisMoveMemory(pAd->MlmeAux.SupRate, SupRate,
diff --git a/drivers/staging/rt2860/sta/wpa.c b/drivers/staging/rt2860/sta/wpa.c
index 69b8a24daa2..ff348325028 100644
--- a/drivers/staging/rt2860/sta/wpa.c
+++ b/drivers/staging/rt2860/sta/wpa.c
@@ -33,7 +33,8 @@
33 Who When What 33 Who When What
34 -------- ---------- ---------------------------------------------- 34 -------- ---------- ----------------------------------------------
35 Jan Lee 03-07-22 Initial 35 Jan Lee 03-07-22 Initial
36 Paul Lin 03-11-28 Modify for supplicant 36 Paul Lin 03-11-28 Modify for supplicant
37 Justin P. Mattock 11/07/2010 Fix typos
37*/ 38*/
38#include "../rt_config.h" 39#include "../rt_config.h"
39 40
@@ -86,7 +87,7 @@ void RTMPReportMicError(struct rt_rtmp_adapter *pAd, struct rt_cipher_key *pWpaK
86 /* Violate MIC error counts, MIC countermeasures kicks in */ 87 /* Violate MIC error counts, MIC countermeasures kicks in */
87 pAd->StaCfg.MicErrCnt++; 88 pAd->StaCfg.MicErrCnt++;
88 /* We shall block all reception */ 89 /* We shall block all reception */
89 /* We shall clean all Tx ring and disassoicate from AP after next EAPOL frame */ 90 /* We shall clean all Tx ring and disassociate from AP after next EAPOL frame */
90 /* */ 91 /* */
91 /* No necessary to clean all Tx ring, on RTMPHardTransmit will stop sending non-802.1X EAPOL packets */ 92 /* No necessary to clean all Tx ring, on RTMPHardTransmit will stop sending non-802.1X EAPOL packets */
92 /* if pAd->StaCfg.MicErrCnt greater than 2. */ 93 /* if pAd->StaCfg.MicErrCnt greater than 2. */
diff --git a/drivers/staging/rt2860/sta_ioctl.c b/drivers/staging/rt2860/sta_ioctl.c
index e095a44cbc0..5717e12a954 100644
--- a/drivers/staging/rt2860/sta_ioctl.c
+++ b/drivers/staging/rt2860/sta_ioctl.c
@@ -31,10 +31,11 @@
31 IOCTL related subroutines 31 IOCTL related subroutines
32 32
33 Revision History: 33 Revision History:
34 Who When What 34 Who When What
35 -------- ---------- ---------------------------------------------- 35 -------- ---------- ----------------------------------------------
36 Rory Chen 01-03-2003 created 36 Rory Chen 01-03-2003 created
37 Rory Chen 02-14-2005 modify to support RT61 37 Rory Chen 02-14-2005 modify to support RT61
38 Justin P. Mattock 11/07/2010 Fix typos
38*/ 39*/
39 40
40#include "rt_config.h" 41#include "rt_config.h"
@@ -851,7 +852,7 @@ int rt_ioctl_giwscan(struct net_device *dev,
851 852
852 /* 853 /*
853 Protocol: 854 Protocol:
854 it will show scanned AP's WirelessMode . 855 it will show scanned AP's WirelessMode.
855 it might be 856 it might be
856 802.11a 857 802.11a
857 802.11a/n 858 802.11a/n
@@ -875,13 +876,13 @@ int rt_ioctl_giwscan(struct net_device *dev,
875 strcpy(iwe.u.name, "802.11a"); 876 strcpy(iwe.u.name, "802.11a");
876 } else { 877 } else {
877 /* 878 /*
878 if one of non B mode rate is set supported rate . it mean G only. 879 if one of non B mode rate is set supported rate, it means G only.
879 */ 880 */
880 for (rateCnt = 0; 881 for (rateCnt = 0;
881 rateCnt < pBssEntry->SupRateLen; 882 rateCnt < pBssEntry->SupRateLen;
882 rateCnt++) { 883 rateCnt++) {
883 /* 884 /*
884 6Mbps(140) 9Mbps(146) and >=12Mbps(152) are supported rate , it mean G only. 885 6Mbps(140) 9Mbps(146) and >=12Mbps(152) are supported rate, it means G only.
885 */ 886 */
886 if (pBssEntry->SupRate[rateCnt] == 140 887 if (pBssEntry->SupRate[rateCnt] == 140
887 || pBssEntry->SupRate[rateCnt] == 888 || pBssEntry->SupRate[rateCnt] ==
@@ -1417,7 +1418,7 @@ int rt_ioctl_siwencode(struct net_device *dev,
1417 if ((index >= 0) && (index < 4)) { 1418 if ((index >= 0) && (index < 4)) {
1418 pAdapter->StaCfg.DefaultKeyId = index; 1419 pAdapter->StaCfg.DefaultKeyId = index;
1419 } else 1420 } else
1420 /* Don't complain if only change the mode */ 1421 /* Don't complain if the mode is only changed */
1421 if (!(erq->flags & IW_ENCODE_MODE)) 1422 if (!(erq->flags & IW_ENCODE_MODE))
1422 return -EINVAL; 1423 return -EINVAL;
1423 } 1424 }
@@ -2732,8 +2733,8 @@ int Set_NetworkType_Proc(struct rt_rtmp_adapter *pAdapter, char *arg)
2732 } 2733 }
2733 if (INFRA_ON(pAdapter)) { 2734 if (INFRA_ON(pAdapter)) {
2734 /*BOOLEAN Cancelled; */ 2735 /*BOOLEAN Cancelled; */
2735 /* Set the AutoReconnectSsid to prevent it reconnect to old SSID */ 2736 /* Set the AutoReconnectSsid to prevent it from reconnecting to the old SSID */
2736 /* Since calling this indicate user don't want to connect to that SSID anymore. */ 2737 /* Since calling this indicates users don't want to connect to that SSID anymore. */
2737 pAdapter->MlmeAux.AutoReconnectSsidLen = 32; 2738 pAdapter->MlmeAux.AutoReconnectSsidLen = 32;
2738 NdisZeroMemory(pAdapter->MlmeAux. 2739 NdisZeroMemory(pAdapter->MlmeAux.
2739 AutoReconnectSsid, 2740 AutoReconnectSsid,
@@ -2766,8 +2767,8 @@ int Set_NetworkType_Proc(struct rt_rtmp_adapter *pAdapter, char *arg)
2766 LinkDown(pAdapter, FALSE); 2767 LinkDown(pAdapter, FALSE);
2767 } 2768 }
2768 if (ADHOC_ON(pAdapter)) { 2769 if (ADHOC_ON(pAdapter)) {
2769 /* Set the AutoReconnectSsid to prevent it reconnect to old SSID */ 2770 /* Set the AutoReconnectSsid to prevent it from reconnecting to the old SSID */
2770 /* Since calling this indicate user don't want to connect to that SSID anymore. */ 2771 /* Since calling this indicates users don't want to connect to that SSID anymore. */
2771 pAdapter->MlmeAux.AutoReconnectSsidLen = 32; 2772 pAdapter->MlmeAux.AutoReconnectSsidLen = 32;
2772 NdisZeroMemory(pAdapter->MlmeAux. 2773 NdisZeroMemory(pAdapter->MlmeAux.
2773 AutoReconnectSsid, 2774 AutoReconnectSsid,
@@ -2884,7 +2885,7 @@ int Set_NetworkType_Proc(struct rt_rtmp_adapter *pAdapter, char *arg)
2884 } 2885 }
2885 /* Enable Rx with promiscuous reception */ 2886 /* Enable Rx with promiscuous reception */
2886 RTMP_IO_WRITE32(pAdapter, RX_FILTR_CFG, 0x3); 2887 RTMP_IO_WRITE32(pAdapter, RX_FILTR_CFG, 0x3);
2887 /* ASIC supporsts sniffer function with replacing RSSI with timestamp. */ 2888 /* ASIC supports sniffer function with replacing RSSI with timestamp. */
2888 /*RTMP_IO_READ32(pAdapter, MAC_SYS_CTRL, &Value); */ 2889 /*RTMP_IO_READ32(pAdapter, MAC_SYS_CTRL, &Value); */
2889 /*Value |= (0x80); */ 2890 /*Value |= (0x80); */
2890 /*RTMP_IO_WRITE32(pAdapter, MAC_SYS_CTRL, Value); */ 2891 /*RTMP_IO_WRITE32(pAdapter, MAC_SYS_CTRL, Value); */
diff --git a/drivers/staging/rt2860/usb_main_dev.c b/drivers/staging/rt2860/usb_main_dev.c
index ebf9074a908..a8820d3f6b3 100644
--- a/drivers/staging/rt2860/usb_main_dev.c
+++ b/drivers/staging/rt2860/usb_main_dev.c
@@ -27,8 +27,8 @@
27#include "rt_config.h" 27#include "rt_config.h"
28 28
29/* Following information will be show when you run 'modinfo' */ 29/* Following information will be show when you run 'modinfo' */
30/* *** If you have a solution for the bug in current version of driver, please mail to me. */ 30/* If you have a solution for the bug in current version of driver, please e-mail me. */
31/* Otherwise post to forum in ralinktech's web site(www.ralinktech.com) and let all users help you. *** */ 31/* Otherwise post to the forum at ralinktech's web site(www.ralinktech.com) and let all users help you. */
32MODULE_AUTHOR("Paul Lin <paul_lin@ralinktech.com>"); 32MODULE_AUTHOR("Paul Lin <paul_lin@ralinktech.com>");
33MODULE_DESCRIPTION("RT2870/RT3070 Wireless Lan Linux Driver"); 33MODULE_DESCRIPTION("RT2870/RT3070 Wireless Lan Linux Driver");
34MODULE_LICENSE("GPL"); 34MODULE_LICENSE("GPL");
@@ -882,8 +882,8 @@ static int __devinit rt2870_probe(IN struct usb_interface *intf,
882 if (net_dev == NULL) 882 if (net_dev == NULL)
883 goto err_out_free_radev; 883 goto err_out_free_radev;
884 884
885 /* Here are the net_device structure with usb specific parameters. */ 885 /* Here are the net_device structure with usb specific parameters.
886 /* for supporting Network Manager. 886 * for supporting Network Manager.
887 * Set the sysfs physical device reference for the network logical device if set prior to registration will 887 * Set the sysfs physical device reference for the network logical device if set prior to registration will
888 * cause a symlink during initialization. 888 * cause a symlink during initialization.
889 */ 889 */
diff --git a/drivers/staging/rt2860/wpa.h b/drivers/staging/rt2860/wpa.h
index 6199ae6cdcd..116fc2caa88 100644
--- a/drivers/staging/rt2860/wpa.h
+++ b/drivers/staging/rt2860/wpa.h
@@ -32,13 +32,14 @@
32 Revision History: 32 Revision History:
33 Who When What 33 Who When What
34 -------- ---------- ---------------------------------------------- 34 -------- ---------- ----------------------------------------------
35 Name Date Modification logs 35 Name Date Modification logs
36 Justin P. Mattock 11/07/2010 Fix a typo
36*/ 37*/
37 38
38#ifndef __WPA_H__ 39#ifndef __WPA_H__
39#define __WPA_H__ 40#define __WPA_H__
40 41
41/* EAPOL Key descripter frame format related length */ 42/* EAPOL Key descriptor frame format related length */
42#define LEN_KEY_DESC_NONCE 32 43#define LEN_KEY_DESC_NONCE 32
43#define LEN_KEY_DESC_IV 16 44#define LEN_KEY_DESC_IV 16
44#define LEN_KEY_DESC_RSC 8 45#define LEN_KEY_DESC_RSC 8