Commit c77761d6 authored by Lukasz Szczesny's avatar Lukasz Szczesny Committed by Greg Kroah-Hartman

staging: rtl8723bs: Fix spacing issues

This patch fixes spacing issues reported by checkpatch.
Signed-off-by: default avatarLukasz Szczesny <luk@wybcz.pl>
Link: https://lore.kernel.org/r/20200212230834.GA294323@localhostSigned-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent e2327678
...@@ -201,7 +201,7 @@ int rtw_init_cmd_priv(struct cmd_priv *pcmdpriv) ...@@ -201,7 +201,7 @@ int rtw_init_cmd_priv(struct cmd_priv *pcmdpriv)
return res; return res;
} }
static void c2h_wk_callback(_workitem *work); static void c2h_wk_callback(_workitem * work);
int rtw_init_evt_priv(struct evt_priv *pevtpriv) int rtw_init_evt_priv(struct evt_priv *pevtpriv)
{ {
/* allocate DMA-able/Non-Page memory for cmd_buf and rsp_buf */ /* allocate DMA-able/Non-Page memory for cmd_buf and rsp_buf */
......
...@@ -44,14 +44,14 @@ ...@@ -44,14 +44,14 @@
#define BTC_ANT_WIFI_AT_CPL_MAIN 0 #define BTC_ANT_WIFI_AT_CPL_MAIN 0
#define BTC_ANT_WIFI_AT_CPL_AUX 1 #define BTC_ANT_WIFI_AT_CPL_AUX 1
typedef enum _BTC_POWERSAVE_TYPE{ typedef enum _BTC_POWERSAVE_TYPE {
BTC_PS_WIFI_NATIVE = 0, /* wifi original power save behavior */ BTC_PS_WIFI_NATIVE = 0, /* wifi original power save behavior */
BTC_PS_LPS_ON = 1, BTC_PS_LPS_ON = 1,
BTC_PS_LPS_OFF = 2, BTC_PS_LPS_OFF = 2,
BTC_PS_MAX BTC_PS_MAX
} BTC_POWERSAVE_TYPE, *PBTC_POWERSAVE_TYPE; } BTC_POWERSAVE_TYPE, *PBTC_POWERSAVE_TYPE;
typedef enum _BTC_BT_REG_TYPE{ typedef enum _BTC_BT_REG_TYPE {
BTC_BT_REG_RF = 0, BTC_BT_REG_RF = 0,
BTC_BT_REG_MODEM = 1, BTC_BT_REG_MODEM = 1,
BTC_BT_REG_BLUEWIZE = 2, BTC_BT_REG_BLUEWIZE = 2,
...@@ -60,7 +60,7 @@ typedef enum _BTC_BT_REG_TYPE{ ...@@ -60,7 +60,7 @@ typedef enum _BTC_BT_REG_TYPE{
BTC_BT_REG_MAX BTC_BT_REG_MAX
} BTC_BT_REG_TYPE, *PBTC_BT_REG_TYPE; } BTC_BT_REG_TYPE, *PBTC_BT_REG_TYPE;
typedef enum _BTC_CHIP_INTERFACE{ typedef enum _BTC_CHIP_INTERFACE {
BTC_INTF_UNKNOWN = 0, BTC_INTF_UNKNOWN = 0,
BTC_INTF_PCI = 1, BTC_INTF_PCI = 1,
BTC_INTF_USB = 2, BTC_INTF_USB = 2,
......
...@@ -849,7 +849,7 @@ typedef struct _ODM_PATH_DIVERSITY_ { ...@@ -849,7 +849,7 @@ typedef struct _ODM_PATH_DIVERSITY_ {
u32 PathB_Cnt[ODM_ASSOCIATE_ENTRY_NUM]; u32 PathB_Cnt[ODM_ASSOCIATE_ENTRY_NUM];
} PATHDIV_T, *pPATHDIV_T; } PATHDIV_T, *pPATHDIV_T;
typedef enum _BASEBAND_CONFIG_PHY_REG_PG_VALUE_TYPE{ typedef enum _BASEBAND_CONFIG_PHY_REG_PG_VALUE_TYPE {
PHY_REG_PG_RELATIVE_VALUE = 0, PHY_REG_PG_RELATIVE_VALUE = 0,
PHY_REG_PG_EXACT_VALUE = 1 PHY_REG_PG_EXACT_VALUE = 1
} PHY_REG_PG_TYPE; } PHY_REG_PG_TYPE;
......
...@@ -106,7 +106,7 @@ static void odm_RxPhyStatus92CSeries_Parsing( ...@@ -106,7 +106,7 @@ static void odm_RxPhyStatus92CSeries_Parsing(
/* (2)PWDB, Average PWDB cacluated by hardware (for rate adaptive) */ /* (2)PWDB, Average PWDB cacluated by hardware (for rate adaptive) */
/* */ /* */
cck_agc_rpt = pPhyStaRpt->cck_agc_rpt_ofdm_cfosho_a ; cck_agc_rpt = pPhyStaRpt->cck_agc_rpt_ofdm_cfosho_a;
/* 2011.11.28 LukeLee: 88E use different LNA & VGA gain table */ /* 2011.11.28 LukeLee: 88E use different LNA & VGA gain table */
/* The RSSI formula should be modified according to the gain table */ /* The RSSI formula should be modified according to the gain table */
......
...@@ -146,7 +146,7 @@ static void ConstructBeacon(struct adapter *padapter, u8 *pframe, u32 *pLength) ...@@ -146,7 +146,7 @@ static void ConstructBeacon(struct adapter *padapter, u8 *pframe, u32 *pLength)
SetFrameSubType(pframe, WIFI_BEACON); SetFrameSubType(pframe, WIFI_BEACON);
pframe += sizeof(struct ieee80211_hdr_3addr); pframe += sizeof(struct ieee80211_hdr_3addr);
pktlen = sizeof (struct ieee80211_hdr_3addr); pktlen = sizeof(struct ieee80211_hdr_3addr);
/* timestamp will be inserted by hardware */ /* timestamp will be inserted by hardware */
pframe += 8; pframe += 8;
...@@ -1652,7 +1652,7 @@ static void rtl8723b_set_FwRsvdPagePkt( ...@@ -1652,7 +1652,7 @@ static void rtl8723b_set_FwRsvdPagePkt(
TotalPacketLen = BufIndex-TxDescLen + 256; /* extension memory for FW */ TotalPacketLen = BufIndex-TxDescLen + 256; /* extension memory for FW */
#else #else
TotalPacketLen = BufIndex-TxDescLen + sizeof (union pn48); /* IV len */ TotalPacketLen = BufIndex - TxDescLen + sizeof(union pn48); /* IV len */
#endif /* CONFIG_GTK_OL */ #endif /* CONFIG_GTK_OL */
} else } else
#endif /* CONFIG_WOWLAN */ #endif /* CONFIG_WOWLAN */
......
...@@ -282,7 +282,7 @@ static s32 xmit_xmitframes(struct adapter *padapter, struct xmit_priv *pxmitpriv ...@@ -282,7 +282,7 @@ static s32 xmit_xmitframes(struct adapter *padapter, struct xmit_priv *pxmitpriv
/* check xmit_buf size enough or not */ /* check xmit_buf size enough or not */
txlen = txdesc_size + rtw_wlan_pkt_size(pxmitframe); txlen = txdesc_size + rtw_wlan_pkt_size(pxmitframe);
if( !pxmitbuf || if (!pxmitbuf ||
((_RND(pxmitbuf->len, 8) + txlen) > max_xmit_len) || ((_RND(pxmitbuf->len, 8) + txlen) > max_xmit_len) ||
(k >= (rtw_hal_sdio_max_txoqt_free_space(padapter) - 1)) (k >= (rtw_hal_sdio_max_txoqt_free_space(padapter) - 1))
) { ) {
......
...@@ -20,7 +20,7 @@ typedef enum tag_HAL_IC_Type_Definition ...@@ -20,7 +20,7 @@ typedef enum tag_HAL_IC_Type_Definition
CHIP_8821 = 7, CHIP_8821 = 7,
CHIP_8723B = 8, CHIP_8723B = 8,
CHIP_8192E = 9, CHIP_8192E = 9,
}HAL_IC_TYPE_E; } HAL_IC_TYPE_E;
/* HAL_CHIP_TYPE_E */ /* HAL_CHIP_TYPE_E */
typedef enum tag_HAL_CHIP_Type_Definition typedef enum tag_HAL_CHIP_Type_Definition
...@@ -28,7 +28,7 @@ typedef enum tag_HAL_CHIP_Type_Definition ...@@ -28,7 +28,7 @@ typedef enum tag_HAL_CHIP_Type_Definition
TEST_CHIP = 0, TEST_CHIP = 0,
NORMAL_CHIP = 1, NORMAL_CHIP = 1,
FPGA = 2, FPGA = 2,
}HAL_CHIP_TYPE_E; } HAL_CHIP_TYPE_E;
/* HAL_CUT_VERSION_E */ /* HAL_CUT_VERSION_E */
typedef enum tag_HAL_Cut_Version_Definition typedef enum tag_HAL_Cut_Version_Definition
...@@ -44,7 +44,7 @@ typedef enum tag_HAL_Cut_Version_Definition ...@@ -44,7 +44,7 @@ typedef enum tag_HAL_Cut_Version_Definition
I_CUT_VERSION = 8, I_CUT_VERSION = 8,
J_CUT_VERSION = 9, J_CUT_VERSION = 9,
K_CUT_VERSION = 10, K_CUT_VERSION = 10,
}HAL_CUT_VERSION_E; } HAL_CUT_VERSION_E;
/* HAL_Manufacturer */ /* HAL_Manufacturer */
typedef enum tag_HAL_Manufacturer_Version_Definition typedef enum tag_HAL_Manufacturer_Version_Definition
...@@ -52,7 +52,7 @@ typedef enum tag_HAL_Manufacturer_Version_Definition ...@@ -52,7 +52,7 @@ typedef enum tag_HAL_Manufacturer_Version_Definition
CHIP_VENDOR_TSMC = 0, CHIP_VENDOR_TSMC = 0,
CHIP_VENDOR_UMC = 1, CHIP_VENDOR_UMC = 1,
CHIP_VENDOR_SMIC = 2, CHIP_VENDOR_SMIC = 2,
}HAL_VENDOR_E; } HAL_VENDOR_E;
typedef enum tag_HAL_RF_Type_Definition typedef enum tag_HAL_RF_Type_Definition
{ {
...@@ -64,7 +64,7 @@ typedef enum tag_HAL_RF_Type_Definition ...@@ -64,7 +64,7 @@ typedef enum tag_HAL_RF_Type_Definition
RF_TYPE_3T3R = 5, RF_TYPE_3T3R = 5,
RF_TYPE_3T4R = 6, RF_TYPE_3T4R = 6,
RF_TYPE_4T4R = 7, RF_TYPE_4T4R = 7,
}HAL_RF_TYPE_E; } HAL_RF_TYPE_E;
typedef struct tag_HAL_VERSION typedef struct tag_HAL_VERSION
{ {
...@@ -74,14 +74,14 @@ typedef struct tag_HAL_VERSION ...@@ -74,14 +74,14 @@ typedef struct tag_HAL_VERSION
HAL_VENDOR_E VendorType; HAL_VENDOR_E VendorType;
HAL_RF_TYPE_E RFType; HAL_RF_TYPE_E RFType;
u8 ROMVer; u8 ROMVer;
}HAL_VERSION,*PHAL_VERSION; } HAL_VERSION, *PHAL_VERSION;
/* VERSION_8192C VersionID; */ /* VERSION_8192C VersionID; */
/* HAL_VERSION VersionID; */ /* HAL_VERSION VersionID; */
/* Get element */ /* Get element */
#define GET_CVID_IC_TYPE(version) ((HAL_IC_TYPE_E)((version).ICType) ) #define GET_CVID_IC_TYPE(version) ((HAL_IC_TYPE_E)((version).ICType))
#define GET_CVID_CHIP_TYPE(version) ((HAL_CHIP_TYPE_E)((version).ChipType) ) #define GET_CVID_CHIP_TYPE(version) ((HAL_CHIP_TYPE_E)((version).ChipType))
#define GET_CVID_RF_TYPE(version) ((HAL_RF_TYPE_E)((version).RFType)) #define GET_CVID_RF_TYPE(version) ((HAL_RF_TYPE_E)((version).RFType))
#define GET_CVID_MANUFACTUER(version) ((HAL_VENDOR_E)((version).VendorType)) #define GET_CVID_MANUFACTUER(version) ((HAL_VENDOR_E)((version).VendorType))
#define GET_CVID_CUT_VERSION(version) ((HAL_CUT_VERSION_E)((version).CUTVersion)) #define GET_CVID_CUT_VERSION(version) ((HAL_CUT_VERSION_E)((version).CUTVersion))
...@@ -93,8 +93,8 @@ typedef struct tag_HAL_VERSION ...@@ -93,8 +93,8 @@ typedef struct tag_HAL_VERSION
/* HAL_VERSION VersionID */ /* HAL_VERSION VersionID */
/* HAL_CHIP_TYPE_E */ /* HAL_CHIP_TYPE_E */
#define IS_TEST_CHIP(version) ((GET_CVID_CHIP_TYPE(version) ==TEST_CHIP)? true: false) #define IS_TEST_CHIP(version) ((GET_CVID_CHIP_TYPE(version) == TEST_CHIP) ? true : false)
#define IS_NORMAL_CHIP(version) ((GET_CVID_CHIP_TYPE(version) ==NORMAL_CHIP)? true: false) #define IS_NORMAL_CHIP(version) ((GET_CVID_CHIP_TYPE(version) == NORMAL_CHIP) ? true : false)
/* HAL_CUT_VERSION_E */ /* HAL_CUT_VERSION_E */
#define IS_A_CUT(version) ((GET_CVID_CUT_VERSION(version) == A_CUT_VERSION) ? true : false) #define IS_A_CUT(version) ((GET_CVID_CUT_VERSION(version) == A_CUT_VERSION) ? true : false)
...@@ -107,13 +107,13 @@ typedef struct tag_HAL_VERSION ...@@ -107,13 +107,13 @@ typedef struct tag_HAL_VERSION
#define IS_K_CUT(version) ((GET_CVID_CUT_VERSION(version) == K_CUT_VERSION) ? true : false) #define IS_K_CUT(version) ((GET_CVID_CUT_VERSION(version) == K_CUT_VERSION) ? true : false)
/* HAL_VENDOR_E */ /* HAL_VENDOR_E */
#define IS_CHIP_VENDOR_TSMC(version) ((GET_CVID_MANUFACTUER(version) == CHIP_VENDOR_TSMC)? true: false) #define IS_CHIP_VENDOR_TSMC(version) ((GET_CVID_MANUFACTUER(version) == CHIP_VENDOR_TSMC) ? true : false)
#define IS_CHIP_VENDOR_UMC(version) ((GET_CVID_MANUFACTUER(version) == CHIP_VENDOR_UMC)? true: false) #define IS_CHIP_VENDOR_UMC(version) ((GET_CVID_MANUFACTUER(version) == CHIP_VENDOR_UMC) ? true : false)
#define IS_CHIP_VENDOR_SMIC(version) ((GET_CVID_MANUFACTUER(version) == CHIP_VENDOR_SMIC)? true: false) #define IS_CHIP_VENDOR_SMIC(version) ((GET_CVID_MANUFACTUER(version) == CHIP_VENDOR_SMIC) ? true : false)
/* HAL_RF_TYPE_E */ /* HAL_RF_TYPE_E */
#define IS_1T1R(version) ((GET_CVID_RF_TYPE(version) == RF_TYPE_1T1R)? true : false) #define IS_1T1R(version) ((GET_CVID_RF_TYPE(version) == RF_TYPE_1T1R) ? true : false)
#define IS_1T2R(version) ((GET_CVID_RF_TYPE(version) == RF_TYPE_1T2R)? true : false) #define IS_1T2R(version) ((GET_CVID_RF_TYPE(version) == RF_TYPE_1T2R) ? true : false)
#define IS_2T2R(version) ((GET_CVID_RF_TYPE(version) == RF_TYPE_2T2R)? true : false) #define IS_2T2R(version) ((GET_CVID_RF_TYPE(version) == RF_TYPE_2T2R) ? true : false)
#endif #endif
...@@ -10,8 +10,8 @@ ...@@ -10,8 +10,8 @@
int rtw_init_cmd_priv(struct cmd_priv *pcmdpriv); int rtw_init_cmd_priv(struct cmd_priv *pcmdpriv);
int rtw_init_evt_priv(struct evt_priv *pevtpriv); int rtw_init_evt_priv(struct evt_priv *pevtpriv);
extern void _rtw_free_evt_priv (struct evt_priv *pevtpriv); extern void _rtw_free_evt_priv(struct evt_priv *pevtpriv);
extern void _rtw_free_cmd_priv (struct cmd_priv *pcmdpriv); extern void _rtw_free_cmd_priv(struct cmd_priv *pcmdpriv);
int _rtw_enqueue_cmd(struct __queue *queue, struct cmd_obj *obj); int _rtw_enqueue_cmd(struct __queue *queue, struct cmd_obj *obj);
extern struct cmd_obj *_rtw_dequeue_cmd(struct __queue *queue); extern struct cmd_obj *_rtw_dequeue_cmd(struct __queue *queue);
......
...@@ -77,7 +77,7 @@ enum _NIC_VERSION { ...@@ -77,7 +77,7 @@ enum _NIC_VERSION {
#define SPEC_DEV_ID_RF_CONFIG_2T2R BIT(4) #define SPEC_DEV_ID_RF_CONFIG_2T2R BIT(4)
#define SPEC_DEV_ID_ASSIGN_IFNAME BIT(5) #define SPEC_DEV_ID_ASSIGN_IFNAME BIT(5)
struct specific_device_id{ struct specific_device_id {
u32 flags; u32 flags;
...@@ -151,8 +151,8 @@ struct registry_priv ...@@ -151,8 +151,8 @@ struct registry_priv
u8 lowrate_two_xmit; u8 lowrate_two_xmit;
u8 rf_config ; u8 rf_config;
u8 low_power ; u8 low_power;
u8 wifi_spec;/* !turbo_mode */ u8 wifi_spec;/* !turbo_mode */
...@@ -498,11 +498,11 @@ enum ADAPTER_TYPE { ...@@ -498,11 +498,11 @@ enum ADAPTER_TYPE {
MAX_ADAPTER = 0xFF, MAX_ADAPTER = 0xFF,
}; };
typedef enum _DRIVER_STATE{ typedef enum _DRIVER_STATE {
DRIVER_NORMAL = 0, DRIVER_NORMAL = 0,
DRIVER_DISAPPEAR = 1, DRIVER_DISAPPEAR = 1,
DRIVER_REPLACE_DONGLE = 2, DRIVER_REPLACE_DONGLE = 2,
}DRIVER_STATE; } DRIVER_STATE;
struct adapter { struct adapter {
int DriverState;/* for disable driver using module, use dongle to replace module. */ int DriverState;/* for disable driver using module, use dongle to replace module. */
......
...@@ -111,54 +111,54 @@ ...@@ -111,54 +111,54 @@
#define DESC_RATEVHTSS4MCS9 0x53 #define DESC_RATEVHTSS4MCS9 0x53
#define HDATA_RATE(rate)\ #define HDATA_RATE(rate)\
(rate ==DESC_RATE1M)?"CCK_1M":\ (rate == DESC_RATE1M) ? "CCK_1M" : \
(rate ==DESC_RATE2M)?"CCK_2M":\ (rate == DESC_RATE2M) ? "CCK_2M" : \
(rate ==DESC_RATE5_5M)?"CCK5_5M":\ (rate == DESC_RATE5_5M) ? "CCK5_5M" : \
(rate ==DESC_RATE11M)?"CCK_11M":\ (rate == DESC_RATE11M) ? "CCK_11M" : \
(rate ==DESC_RATE6M)?"OFDM_6M":\ (rate == DESC_RATE6M) ? "OFDM_6M" : \
(rate ==DESC_RATE9M)?"OFDM_9M":\ (rate == DESC_RATE9M) ? "OFDM_9M" : \
(rate ==DESC_RATE12M)?"OFDM_12M":\ (rate == DESC_RATE12M) ? "OFDM_12M" : \
(rate ==DESC_RATE18M)?"OFDM_18M":\ (rate == DESC_RATE18M) ? "OFDM_18M" : \
(rate ==DESC_RATE24M)?"OFDM_24M":\ (rate == DESC_RATE24M) ? "OFDM_24M" : \
(rate ==DESC_RATE36M)?"OFDM_36M":\ (rate == DESC_RATE36M) ? "OFDM_36M" : \
(rate ==DESC_RATE48M)?"OFDM_48M":\ (rate == DESC_RATE48M) ? "OFDM_48M" : \
(rate ==DESC_RATE54M)?"OFDM_54M":\ (rate == DESC_RATE54M) ? "OFDM_54M" : \
(rate ==DESC_RATEMCS0)?"MCS0":\ (rate == DESC_RATEMCS0) ? "MCS0" : \
(rate ==DESC_RATEMCS1)?"MCS1":\ (rate == DESC_RATEMCS1) ? "MCS1" : \
(rate ==DESC_RATEMCS2)?"MCS2":\ (rate == DESC_RATEMCS2) ? "MCS2" : \
(rate ==DESC_RATEMCS3)?"MCS3":\ (rate == DESC_RATEMCS3) ? "MCS3" : \
(rate ==DESC_RATEMCS4)?"MCS4":\ (rate == DESC_RATEMCS4) ? "MCS4" : \
(rate ==DESC_RATEMCS5)?"MCS5":\ (rate == DESC_RATEMCS5) ? "MCS5" : \
(rate ==DESC_RATEMCS6)?"MCS6":\ (rate == DESC_RATEMCS6) ? "MCS6" : \
(rate ==DESC_RATEMCS7)?"MCS7":\ (rate == DESC_RATEMCS7) ? "MCS7" : \
(rate ==DESC_RATEMCS8)?"MCS8":\ (rate == DESC_RATEMCS8) ? "MCS8" : \
(rate ==DESC_RATEMCS9)?"MCS9":\ (rate == DESC_RATEMCS9) ? "MCS9" : \
(rate ==DESC_RATEMCS10)?"MCS10":\ (rate == DESC_RATEMCS10) ? "MCS10" : \
(rate ==DESC_RATEMCS11)?"MCS11":\ (rate == DESC_RATEMCS11) ? "MCS11" : \
(rate ==DESC_RATEMCS12)?"MCS12":\ (rate == DESC_RATEMCS12) ? "MCS12" : \
(rate ==DESC_RATEMCS13)?"MCS13":\ (rate == DESC_RATEMCS13) ? "MCS13" : \
(rate ==DESC_RATEMCS14)?"MCS14":\ (rate == DESC_RATEMCS14) ? "MCS14" : \
(rate ==DESC_RATEMCS15)?"MCS15":\ (rate == DESC_RATEMCS15) ? "MCS15" : \
(rate ==DESC_RATEVHTSS1MCS0)?"VHTSS1MCS0":\ (rate == DESC_RATEVHTSS1MCS0) ? "VHTSS1MCS0" : \
(rate ==DESC_RATEVHTSS1MCS1)?"VHTSS1MCS1":\ (rate == DESC_RATEVHTSS1MCS1) ? "VHTSS1MCS1" : \
(rate ==DESC_RATEVHTSS1MCS2)?"VHTSS1MCS2":\ (rate == DESC_RATEVHTSS1MCS2) ? "VHTSS1MCS2" : \
(rate ==DESC_RATEVHTSS1MCS3)?"VHTSS1MCS3":\ (rate == DESC_RATEVHTSS1MCS3) ? "VHTSS1MCS3" : \
(rate ==DESC_RATEVHTSS1MCS4)?"VHTSS1MCS4":\ (rate == DESC_RATEVHTSS1MCS4) ? "VHTSS1MCS4" : \
(rate ==DESC_RATEVHTSS1MCS5)?"VHTSS1MCS5":\ (rate == DESC_RATEVHTSS1MCS5) ? "VHTSS1MCS5" : \
(rate ==DESC_RATEVHTSS1MCS6)?"VHTSS1MCS6":\ (rate == DESC_RATEVHTSS1MCS6) ? "VHTSS1MCS6" : \
(rate ==DESC_RATEVHTSS1MCS7)?"VHTSS1MCS7":\ (rate == DESC_RATEVHTSS1MCS7) ? "VHTSS1MCS7" : \
(rate ==DESC_RATEVHTSS1MCS8)?"VHTSS1MCS8":\ (rate == DESC_RATEVHTSS1MCS8) ? "VHTSS1MCS8" : \
(rate ==DESC_RATEVHTSS1MCS9)?"VHTSS1MCS9":\ (rate == DESC_RATEVHTSS1MCS9) ? "VHTSS1MCS9" : \
(rate ==DESC_RATEVHTSS2MCS0)?"VHTSS2MCS0":\ (rate == DESC_RATEVHTSS2MCS0) ? "VHTSS2MCS0" : \
(rate ==DESC_RATEVHTSS2MCS1)?"VHTSS2MCS1":\ (rate == DESC_RATEVHTSS2MCS1) ? "VHTSS2MCS1" : \
(rate ==DESC_RATEVHTSS2MCS2)?"VHTSS2MCS2":\ (rate == DESC_RATEVHTSS2MCS2) ? "VHTSS2MCS2" : \
(rate ==DESC_RATEVHTSS2MCS3)?"VHTSS2MCS3":\ (rate == DESC_RATEVHTSS2MCS3) ? "VHTSS2MCS3" : \
(rate ==DESC_RATEVHTSS2MCS4)?"VHTSS2MCS4":\ (rate == DESC_RATEVHTSS2MCS4) ? "VHTSS2MCS4" : \
(rate ==DESC_RATEVHTSS2MCS5)?"VHTSS2MCS5":\ (rate == DESC_RATEVHTSS2MCS5) ? "VHTSS2MCS5" : \
(rate ==DESC_RATEVHTSS2MCS6)?"VHTSS2MCS6":\ (rate == DESC_RATEVHTSS2MCS6) ? "VHTSS2MCS6" : \
(rate ==DESC_RATEVHTSS2MCS7)?"VHTSS2MCS7":\ (rate == DESC_RATEVHTSS2MCS7) ? "VHTSS2MCS7" : \
(rate ==DESC_RATEVHTSS2MCS8)?"VHTSS2MCS8":\ (rate == DESC_RATEVHTSS2MCS8) ? "VHTSS2MCS8" : \
(rate ==DESC_RATEVHTSS2MCS9)?"VHTSS2MCS9":"UNKNOW" (rate == DESC_RATEVHTSS2MCS9) ? "VHTSS2MCS9" : "UNKNOW"
enum{ enum{
...@@ -235,7 +235,7 @@ s32 c2h_evt_read_88xx(struct adapter *adapter, u8 *buf); ...@@ -235,7 +235,7 @@ s32 c2h_evt_read_88xx(struct adapter *adapter, u8 *buf);
u8 rtw_get_mgntframe_raid(struct adapter *adapter, unsigned char network_type); u8 rtw_get_mgntframe_raid(struct adapter *adapter, unsigned char network_type);
void rtw_hal_update_sta_rate_mask(struct adapter *padapter, struct sta_info *psta); void rtw_hal_update_sta_rate_mask(struct adapter *padapter, struct sta_info *psta);
void hw_var_port_switch (struct adapter *adapter); void hw_var_port_switch(struct adapter *adapter);
void SetHwReg(struct adapter *padapter, u8 variable, u8 *val); void SetHwReg(struct adapter *padapter, u8 variable, u8 *val);
void GetHwReg(struct adapter *padapter, u8 variable, u8 *val); void GetHwReg(struct adapter *padapter, u8 variable, u8 *val);
......
...@@ -11,7 +11,7 @@ ...@@ -11,7 +11,7 @@
/* H2C CMD DEFINITION ------------------------------------------------ */ /* H2C CMD DEFINITION ------------------------------------------------ */
/* */ /* */
/* 88e, 8723b, 8812, 8821, 92e use the same FW code base */ /* 88e, 8723b, 8812, 8821, 92e use the same FW code base */
enum h2c_cmd{ enum h2c_cmd {
/* Common Class: 000 */ /* Common Class: 000 */
H2C_RSVD_PAGE = 0x00, H2C_RSVD_PAGE = 0x00,
H2C_MEDIA_STATUS_RPT = 0x01, H2C_MEDIA_STATUS_RPT = 0x01,
...@@ -96,9 +96,9 @@ enum h2c_cmd{ ...@@ -96,9 +96,9 @@ enum h2c_cmd{
#define H2C_PROBERSP_RSVDPAGE_LEN 5 #define H2C_PROBERSP_RSVDPAGE_LEN 5
#ifdef CONFIG_WOWLAN #ifdef CONFIG_WOWLAN
#define eqMacAddr(a, b) (((a)[0]==(b)[0] && (a)[1]==(b)[1] && (a)[2]==(b)[2] && (a)[3]==(b)[3] && (a)[4]==(b)[4] && (a)[5]==(b)[5]) ? 1:0) #define eqMacAddr(a, b) (((a)[0] == (b)[0] && (a)[1] == (b)[1] && (a)[2] == (b)[2] && (a)[3] == (b)[3] && (a)[4] == (b)[4] && (a)[5] == (b)[5]) ? 1 : 0)
#define cpMacAddr(des, src) ((des)[0]=(src)[0], (des)[1]=(src)[1], (des)[2]=(src)[2], (des)[3]=(src)[3], (des)[4]=(src)[4], (des)[5]=(src)[5]) #define cpMacAddr(des, src) ((des)[0] = (src)[0], (des)[1] = (src)[1], (des)[2] = (src)[2], (des)[3] = (src)[3], (des)[4] = (src)[4], (des)[5] = (src)[5])
#define cpIpAddr(des, src) ((des)[0]=(src)[0], (des)[1]=(src)[1], (des)[2]=(src)[2], (des)[3]=(src)[3]) #define cpIpAddr(des, src) ((des)[0] = (src)[0], (des)[1] = (src)[1], (des)[2] = (src)[2], (des)[3] = (src)[3])
/* */ /* */
/* ARP packet */ /* ARP packet */
......
...@@ -177,7 +177,7 @@ u8 Channel, ...@@ -177,7 +177,7 @@ u8 Channel,
bool *bIn24G bool *bIn24G
); );
s8 phy_get_tx_pwr_lmt (struct adapter *adapter, u32 RegPwrTblSel, s8 phy_get_tx_pwr_lmt(struct adapter *adapter, u32 RegPwrTblSel,
enum BAND_TYPE Band, enum CHANNEL_WIDTH Bandwidth, enum BAND_TYPE Band, enum CHANNEL_WIDTH Bandwidth,
u8 RfPath, u8 RfPath,
u8 DataRate, u8 DataRate,
......
...@@ -707,13 +707,13 @@ Default: 00b. ...@@ -707,13 +707,13 @@ Default: 00b.
/* ALL CCK Rate */ /* ALL CCK Rate */
#define RATE_ALL_CCK RATR_1M|RATR_2M|RATR_55M|RATR_11M #define RATE_ALL_CCK RATR_1M | RATR_2M | RATR_55M | RATR_11M
#define RATE_ALL_OFDM_AG RATR_6M|RATR_9M|RATR_12M|RATR_18M|RATR_24M|\ #define RATE_ALL_OFDM_AG RATR_6M | RATR_9M | RATR_12M | RATR_18M | RATR_24M |\
RATR_36M|RATR_48M|RATR_54M RATR_36M | RATR_48M | RATR_54M
#define RATE_ALL_OFDM_1SS RATR_MCS0|RATR_MCS1|RATR_MCS2|RATR_MCS3 |\ #define RATE_ALL_OFDM_1SS RATR_MCS0 | RATR_MCS1 | RATR_MCS2 | RATR_MCS3 |\
RATR_MCS4|RATR_MCS5|RATR_MCS6 |RATR_MCS7 RATR_MCS4 | RATR_MCS5 | RATR_MCS6 | RATR_MCS7
#define RATE_ALL_OFDM_2SS RATR_MCS8|RATR_MCS9 |RATR_MCS10|RATR_MCS11|\ #define RATE_ALL_OFDM_2SS RATR_MCS8 | RATR_MCS9 | RATR_MCS10 | RATR_MCS11 |\
RATR_MCS12|RATR_MCS13|RATR_MCS14|RATR_MCS15 RATR_MCS12 | RATR_MCS13 | RATR_MCS14 | RATR_MCS15
#define RATE_BITMAP_ALL 0xFFFFF #define RATE_BITMAP_ALL 0xFFFFF
......
...@@ -296,7 +296,7 @@ enum wowlan_subcode { ...@@ -296,7 +296,7 @@ enum wowlan_subcode {
WOWLAN_AP_DISABLE = 13 WOWLAN_AP_DISABLE = 13
}; };
struct wowlan_ioctl_param{ struct wowlan_ioctl_param {
unsigned int subcode; unsigned int subcode;
unsigned int subcode_value; unsigned int subcode_value;
unsigned int wakeup_reason; unsigned int wakeup_reason;
......
...@@ -25,7 +25,7 @@ ...@@ -25,7 +25,7 @@
#define RF6052_MAX_REG_92C 0x7F #define RF6052_MAX_REG_92C 0x7F
#define RF6052_MAX_REG \ #define RF6052_MAX_REG \
(RF6052_MAX_REG_88E > RF6052_MAX_REG_92C) ? RF6052_MAX_REG_88E: RF6052_MAX_REG_92C (RF6052_MAX_REG_88E > RF6052_MAX_REG_92C) ? RF6052_MAX_REG_88E : RF6052_MAX_REG_92C
#define GET_RF6052_REAL_MAX_REG(_Adapter) RF6052_MAX_REG_92C #define GET_RF6052_REAL_MAX_REG(_Adapter) RF6052_MAX_REG_92C
......
...@@ -58,9 +58,9 @@ u32 Data ...@@ -58,9 +58,9 @@ u32 Data
); );
/* MAC/BB/RF HAL config */ /* MAC/BB/RF HAL config */
int PHY_BBConfig8723B(struct adapter *Adapter ); int PHY_BBConfig8723B(struct adapter *Adapter);
int PHY_RFConfig8723B(struct adapter *Adapter ); int PHY_RFConfig8723B(struct adapter *Adapter);
s32 PHY_MACConfig8723B(struct adapter *padapter); s32 PHY_MACConfig8723B(struct adapter *padapter);
......
...@@ -46,9 +46,9 @@ ...@@ -46,9 +46,9 @@
{0x0001, PWR_CUT_ALL_MSK, PWR_FAB_ALL_MSK, PWR_INTF_USB_MSK|PWR_INTF_SDIO_MSK, PWR_BASEADDR_MAC, PWR_CMD_DELAY, 1, PWRSEQ_DELAY_MS},/*Delay 1ms*/ \ {0x0001, PWR_CUT_ALL_MSK, PWR_FAB_ALL_MSK, PWR_INTF_USB_MSK|PWR_INTF_SDIO_MSK, PWR_BASEADDR_MAC, PWR_CMD_DELAY, 1, PWRSEQ_DELAY_MS},/*Delay 1ms*/ \
{0x0000, PWR_CUT_ALL_MSK, PWR_FAB_ALL_MSK, PWR_INTF_USB_MSK|PWR_INTF_SDIO_MSK, PWR_BASEADDR_MAC, PWR_CMD_WRITE, BIT5, 0}, /*0x00[5] = 1b'0 release analog Ips to digital , 1:isolation*/ \ {0x0000, PWR_CUT_ALL_MSK, PWR_FAB_ALL_MSK, PWR_INTF_USB_MSK|PWR_INTF_SDIO_MSK, PWR_BASEADDR_MAC, PWR_CMD_WRITE, BIT5, 0}, /*0x00[5] = 1b'0 release analog Ips to digital , 1:isolation*/ \
{0x0005, PWR_CUT_ALL_MSK, PWR_FAB_ALL_MSK, PWR_INTF_ALL_MSK, PWR_BASEADDR_MAC, PWR_CMD_WRITE, (BIT4|BIT3|BIT2), 0},/* disable SW LPS 0x04[10]= 0 and WLSUS_EN 0x04[11]= 0*/ \ {0x0005, PWR_CUT_ALL_MSK, PWR_FAB_ALL_MSK, PWR_INTF_ALL_MSK, PWR_BASEADDR_MAC, PWR_CMD_WRITE, (BIT4|BIT3|BIT2), 0},/* disable SW LPS 0x04[10]= 0 and WLSUS_EN 0x04[11]= 0*/ \
{0x0075, PWR_CUT_ALL_MSK, PWR_FAB_ALL_MSK, PWR_INTF_PCI_MSK, PWR_BASEADDR_MAC, PWR_CMD_WRITE, BIT0 , BIT0},/* Disable USB suspend */ \ {0x0075, PWR_CUT_ALL_MSK, PWR_FAB_ALL_MSK, PWR_INTF_PCI_MSK, PWR_BASEADDR_MAC, PWR_CMD_WRITE, BIT0, BIT0},/* Disable USB suspend */ \
{0x0006, PWR_CUT_ALL_MSK, PWR_FAB_ALL_MSK, PWR_INTF_ALL_MSK, PWR_BASEADDR_MAC, PWR_CMD_POLLING, BIT1, BIT1},/* wait till 0x04[17] = 1 power ready*/ \ {0x0006, PWR_CUT_ALL_MSK, PWR_FAB_ALL_MSK, PWR_INTF_ALL_MSK, PWR_BASEADDR_MAC, PWR_CMD_POLLING, BIT1, BIT1},/* wait till 0x04[17] = 1 power ready*/ \
{0x0075, PWR_CUT_ALL_MSK, PWR_FAB_ALL_MSK, PWR_INTF_PCI_MSK, PWR_BASEADDR_MAC, PWR_CMD_WRITE, BIT0 , 0},/* Enable USB suspend */ \ {0x0075, PWR_CUT_ALL_MSK, PWR_FAB_ALL_MSK, PWR_INTF_PCI_MSK, PWR_BASEADDR_MAC, PWR_CMD_WRITE, BIT0, 0},/* Enable USB suspend */ \
{0x0006, PWR_CUT_ALL_MSK, PWR_FAB_ALL_MSK, PWR_INTF_ALL_MSK, PWR_BASEADDR_MAC, PWR_CMD_WRITE, BIT0, BIT0},/* release WLON reset 0x04[16]= 1*/ \ {0x0006, PWR_CUT_ALL_MSK, PWR_FAB_ALL_MSK, PWR_INTF_ALL_MSK, PWR_BASEADDR_MAC, PWR_CMD_WRITE, BIT0, BIT0},/* release WLON reset 0x04[16]= 1*/ \
{0x0005, PWR_CUT_ALL_MSK, PWR_FAB_ALL_MSK, PWR_INTF_ALL_MSK, PWR_BASEADDR_MAC, PWR_CMD_WRITE, BIT7, 0},/* disable HWPDN 0x04[15]= 0*/ \ {0x0005, PWR_CUT_ALL_MSK, PWR_FAB_ALL_MSK, PWR_INTF_ALL_MSK, PWR_BASEADDR_MAC, PWR_CMD_WRITE, BIT7, 0},/* disable HWPDN 0x04[15]= 0*/ \
{0x0005, PWR_CUT_ALL_MSK, PWR_FAB_ALL_MSK, PWR_INTF_ALL_MSK, PWR_BASEADDR_MAC, PWR_CMD_WRITE, (BIT4|BIT3), 0},/* disable WL suspend*/ \ {0x0005, PWR_CUT_ALL_MSK, PWR_FAB_ALL_MSK, PWR_INTF_ALL_MSK, PWR_BASEADDR_MAC, PWR_CMD_WRITE, (BIT4|BIT3), 0},/* disable WL suspend*/ \
......
...@@ -98,8 +98,8 @@ enum { ...@@ -98,8 +98,8 @@ enum {
#define WPA_SELECTOR_LEN 4 #define WPA_SELECTOR_LEN 4
extern u8 RTW_WPA_OUI_TYPE[] ; extern u8 RTW_WPA_OUI_TYPE[];
extern u16 RTW_WPA_VERSION ; extern u16 RTW_WPA_VERSION;
extern u8 WPA_AUTH_KEY_MGMT_NONE[]; extern u8 WPA_AUTH_KEY_MGMT_NONE[];
extern u8 WPA_AUTH_KEY_MGMT_UNSPEC_802_1X[]; extern u8 WPA_AUTH_KEY_MGMT_UNSPEC_802_1X[];
extern u8 WPA_AUTH_KEY_MGMT_PSK_OVER_802_1X[]; extern u8 WPA_AUTH_KEY_MGMT_PSK_OVER_802_1X[];
...@@ -139,7 +139,7 @@ typedef enum _RATEID_IDX_ { ...@@ -139,7 +139,7 @@ typedef enum _RATEID_IDX_ {
RATEID_IDX_VHT_1SS = 10, RATEID_IDX_VHT_1SS = 10,
} RATEID_IDX, *PRATEID_IDX; } RATEID_IDX, *PRATEID_IDX;
typedef enum _RATR_TABLE_MODE{ typedef enum _RATR_TABLE_MODE {
RATR_INX_WIRELESS_NGB = 0, /* BGN 40 Mhz 2SS 1SS */ RATR_INX_WIRELESS_NGB = 0, /* BGN 40 Mhz 2SS 1SS */
RATR_INX_WIRELESS_NG = 1, /* GN or N */ RATR_INX_WIRELESS_NG = 1, /* GN or N */
RATR_INX_WIRELESS_NB = 2, /* BGN 20 Mhz 2SS 1SS or BN */ RATR_INX_WIRELESS_NB = 2, /* BGN 20 Mhz 2SS 1SS or BN */
...@@ -149,7 +149,7 @@ typedef enum _RATR_TABLE_MODE{ ...@@ -149,7 +149,7 @@ typedef enum _RATR_TABLE_MODE{
RATR_INX_WIRELESS_B = 6, RATR_INX_WIRELESS_B = 6,
RATR_INX_WIRELESS_MC = 7, RATR_INX_WIRELESS_MC = 7,
RATR_INX_WIRELESS_AC_N = 8, RATR_INX_WIRELESS_AC_N = 8,
}RATR_TABLE_MODE, *PRATR_TABLE_MODE; } RATR_TABLE_MODE, *PRATR_TABLE_MODE;
enum NETWORK_TYPE enum NETWORK_TYPE
...@@ -248,7 +248,7 @@ struct ieee_param_ex { ...@@ -248,7 +248,7 @@ struct ieee_param_ex {
u8 data[0]; u8 data[0];
}; };
struct sta_data{ struct sta_data {
u16 aid; u16 aid;
u16 capability; u16 capability;
int flags; int flags;
...@@ -439,7 +439,7 @@ struct ieee80211_snap_hdr { ...@@ -439,7 +439,7 @@ struct ieee80211_snap_hdr {
#define IEEE80211_OFDM_SHIFT_MASK_A 4 #define IEEE80211_OFDM_SHIFT_MASK_A 4
enum MGN_RATE{ enum MGN_RATE {
MGN_1M = 0x02, MGN_1M = 0x02,
MGN_2M = 0x04, MGN_2M = 0x04,
MGN_5_5M = 0x0B, MGN_5_5M = 0x0B,
...@@ -906,7 +906,7 @@ enum rtw_ieee80211_spectrum_mgmt_actioncode { ...@@ -906,7 +906,7 @@ enum rtw_ieee80211_spectrum_mgmt_actioncode {
RTW_WLAN_ACTION_SPCT_EXT_CHL_SWITCH = 5, RTW_WLAN_ACTION_SPCT_EXT_CHL_SWITCH = 5,
}; };
enum _PUBLIC_ACTION{ enum _PUBLIC_ACTION {
ACT_PUBLIC_BSSCOEXIST = 0, /* 20/40 BSS Coexistence */ ACT_PUBLIC_BSSCOEXIST = 0, /* 20/40 BSS Coexistence */
ACT_PUBLIC_DSE_ENABLE = 1, ACT_PUBLIC_DSE_ENABLE = 1,
ACT_PUBLIC_DSE_DEENABLE = 2, ACT_PUBLIC_DSE_DEENABLE = 2,
...@@ -953,7 +953,7 @@ enum rtw_ieee80211_back_parties { ...@@ -953,7 +953,7 @@ enum rtw_ieee80211_back_parties {
}; };
/* VHT features action code */ /* VHT features action code */
enum rtw_ieee80211_vht_actioncode{ enum rtw_ieee80211_vht_actioncode {
RTW_WLAN_ACTION_VHT_COMPRESSED_BEAMFORMING = 0, RTW_WLAN_ACTION_VHT_COMPRESSED_BEAMFORMING = 0,
RTW_WLAN_ACTION_VHT_GROUPID_MANAGEMENT = 1, RTW_WLAN_ACTION_VHT_GROUPID_MANAGEMENT = 1,
RTW_WLAN_ACTION_VHT_OPMODE_NOTIFICATION = 2, RTW_WLAN_ACTION_VHT_OPMODE_NOTIFICATION = 2,
...@@ -1128,7 +1128,7 @@ u8 *rtw_get_ie(u8*pbuf, sint index, sint *len, sint limit); ...@@ -1128,7 +1128,7 @@ u8 *rtw_get_ie(u8*pbuf, sint index, sint *len, sint limit);
u8 *rtw_get_ie_ex(u8 *in_ie, uint in_len, u8 eid, u8 *oui, u8 oui_len, u8 *ie, uint *ielen); u8 *rtw_get_ie_ex(u8 *in_ie, uint in_len, u8 eid, u8 *oui, u8 oui_len, u8 *ie, uint *ielen);
int rtw_ies_remove_ie(u8 *ies, uint *ies_len, uint offset, u8 eid, u8 *oui, u8 oui_len); int rtw_ies_remove_ie(u8 *ies, uint *ies_len, uint offset, u8 eid, u8 *oui, u8 oui_len);
void rtw_set_supported_rate(u8 *SupportedRates, uint mode) ; void rtw_set_supported_rate(u8 *SupportedRates, uint mode);
unsigned char *rtw_get_wpa_ie(unsigned char *pie, int *wpa_ie_len, int limit); unsigned char *rtw_get_wpa_ie(unsigned char *pie, int *wpa_ie_len, int limit);
unsigned char *rtw_get_wpa2_ie(unsigned char *pie, int *rsn_ie_len, int limit); unsigned char *rtw_get_wpa2_ie(unsigned char *pie, int *rsn_ie_len, int limit);
...@@ -1142,8 +1142,8 @@ void rtw_get_sec_ie(u8 *in_ie, uint in_len, u8 *rsn_ie, u16 *rsn_len, u8 *wpa_ie ...@@ -1142,8 +1142,8 @@ void rtw_get_sec_ie(u8 *in_ie, uint in_len, u8 *rsn_ie, u16 *rsn_len, u8 *wpa_ie
u8 rtw_is_wps_ie(u8 *ie_ptr, uint *wps_ielen); u8 rtw_is_wps_ie(u8 *ie_ptr, uint *wps_ielen);
u8 *rtw_get_wps_ie(u8 *in_ie, uint in_len, u8 *wps_ie, uint *wps_ielen); u8 *rtw_get_wps_ie(u8 *in_ie, uint in_len, u8 *wps_ie, uint *wps_ielen);
u8 *rtw_get_wps_attr(u8 *wps_ie, uint wps_ielen, u16 target_attr_id , u8 *buf_attr, u32 *len_attr); u8 *rtw_get_wps_attr(u8 *wps_ie, uint wps_ielen, u16 target_attr_id, u8 *buf_attr, u32 *len_attr);
u8 *rtw_get_wps_attr_content(u8 *wps_ie, uint wps_ielen, u16 target_attr_id , u8 *buf_content, uint *len_content); u8 *rtw_get_wps_attr_content(u8 *wps_ie, uint wps_ielen, u16 target_attr_id, u8 *buf_content, uint *len_content);
/** /**
* for_each_ie - iterate over continuous IEs * for_each_ie - iterate over continuous IEs
......
...@@ -50,7 +50,7 @@ void rtw_reset_drv_sw(struct adapter *padapter); ...@@ -50,7 +50,7 @@ void rtw_reset_drv_sw(struct adapter *padapter);
void rtw_dev_unload(struct adapter *padapter); void rtw_dev_unload(struct adapter *padapter);
u32 rtw_start_drv_threads(struct adapter *padapter); u32 rtw_start_drv_threads(struct adapter *padapter);
void rtw_stop_drv_threads (struct adapter *padapter); void rtw_stop_drv_threads(struct adapter *padapter);
void rtw_cancel_all_timer(struct adapter *padapter); void rtw_cancel_all_timer(struct adapter *padapter);
int rtw_ioctl(struct net_device *dev, struct ifreq *rq, int cmd); int rtw_ioctl(struct net_device *dev, struct ifreq *rq, int cmd);
......
...@@ -80,7 +80,7 @@ enum mstat_f { ...@@ -80,7 +80,7 @@ enum mstat_f {
#define mstat_tf_idx(flags) ((flags)&0xff) #define mstat_tf_idx(flags) ((flags)&0xff)
#define mstat_ff_idx(flags) (((flags)&0xff00) >> 8) #define mstat_ff_idx(flags) (((flags)&0xff00) >> 8)
typedef enum mstat_status{ typedef enum mstat_status {
MSTAT_ALLOC_SUCCESS = 0, MSTAT_ALLOC_SUCCESS = 0,
MSTAT_ALLOC_FAIL, MSTAT_ALLOC_FAIL,
MSTAT_FREE MSTAT_FREE
...@@ -117,7 +117,7 @@ static inline void thread_enter(char *name) ...@@ -117,7 +117,7 @@ static inline void thread_enter(char *name)
static inline void flush_signals_thread(void) static inline void flush_signals_thread(void)
{ {
if (signal_pending (current)) if (signal_pending(current))
{ {
flush_signals(current); flush_signals(current);
} }
...@@ -134,14 +134,14 @@ static inline int rtw_bug_check(void *parg1, void *parg2, void *parg3, void *par ...@@ -134,14 +134,14 @@ static inline int rtw_bug_check(void *parg1, void *parg2, void *parg3, void *par
} }
#define _RND(sz, r) ((((sz)+((r)-1))/(r))*(r)) #define _RND(sz, r) ((((sz)+((r)-1))/(r))*(r))
#define RND4(x) (((x >> 2) + (((x & 3) == 0) ? 0: 1)) << 2) #define RND4(x) (((x >> 2) + (((x & 3) == 0) ? 0 : 1)) << 2)
static inline u32 _RND4(u32 sz) static inline u32 _RND4(u32 sz)
{ {
u32 val; u32 val;
val = ((sz >> 2) + ((sz & 3) ? 1: 0)) << 2; val = ((sz >> 2) + ((sz & 3) ? 1 : 0)) << 2;
return val; return val;
...@@ -152,7 +152,7 @@ static inline u32 _RND8(u32 sz) ...@@ -152,7 +152,7 @@ static inline u32 _RND8(u32 sz)
u32 val; u32 val;
val = ((sz >> 3) + ((sz & 7) ? 1: 0)) << 3; val = ((sz >> 3) + ((sz & 7) ? 1 : 0)) << 3;
return val; return val;
......
...@@ -80,7 +80,7 @@ static inline struct list_head *get_list_head(struct __queue *queue) ...@@ -80,7 +80,7 @@ static inline struct list_head *get_list_head(struct __queue *queue)
static inline void _set_timer(_timer *ptimer, u32 delay_time) static inline void _set_timer(_timer *ptimer, u32 delay_time)
{ {
mod_timer(ptimer , (jiffies+(delay_time*HZ/1000))); mod_timer(ptimer, (jiffies + (delay_time * HZ / 1000)));
} }
static inline void _cancel_timer(_timer *ptimer, u8 *bcancelled) static inline void _cancel_timer(_timer *ptimer, u8 *bcancelled)
......
...@@ -9,7 +9,7 @@ ...@@ -9,7 +9,7 @@
extern sint _rtw_init_recv_priv(struct recv_priv *precvpriv, struct adapter *padapter); extern sint _rtw_init_recv_priv(struct recv_priv *precvpriv, struct adapter *padapter);
extern void _rtw_free_recv_priv (struct recv_priv *precvpriv); extern void _rtw_free_recv_priv(struct recv_priv *precvpriv);
extern s32 rtw_recv_entry(union recv_frame *precv_frame); extern s32 rtw_recv_entry(union recv_frame *precv_frame);
...@@ -19,7 +19,7 @@ extern void rtw_recv_returnpacket(_nic_hdl cnxt, _pkt *preturnedpkt); ...@@ -19,7 +19,7 @@ extern void rtw_recv_returnpacket(_nic_hdl cnxt, _pkt *preturnedpkt);
extern void rtw_handle_tkip_mic_err(struct adapter *padapter, u8 bgroup); extern void rtw_handle_tkip_mic_err(struct adapter *padapter, u8 bgroup);
int rtw_init_recv_priv(struct recv_priv *precvpriv, struct adapter *padapter); int rtw_init_recv_priv(struct recv_priv *precvpriv, struct adapter *padapter);
void rtw_free_recv_priv (struct recv_priv *precvpriv); void rtw_free_recv_priv(struct recv_priv *precvpriv);
void rtw_os_recv_resource_alloc(struct adapter *padapter, union recv_frame *precvframe); void rtw_os_recv_resource_alloc(struct adapter *padapter, union recv_frame *precvframe);
......
...@@ -11,7 +11,7 @@ ...@@ -11,7 +11,7 @@
/* H2C CMD DEFINITION ------------------------------------------------ */ /* H2C CMD DEFINITION ------------------------------------------------ */
/* */ /* */
enum h2c_cmd_8723B{ enum h2c_cmd_8723B {
/* Common Class: 000 */ /* Common Class: 000 */
H2C_8723B_RSVD_PAGE = 0x00, H2C_8723B_RSVD_PAGE = 0x00,
H2C_8723B_MEDIA_STATUS_RPT = 0x01, H2C_8723B_MEDIA_STATUS_RPT = 0x01,
......
...@@ -8,7 +8,7 @@ ...@@ -8,7 +8,7 @@
#define __RTL8723B_RF_H__ #define __RTL8723B_RF_H__
int PHY_RF6052_Config8723B(struct adapter *Adapter ); int PHY_RF6052_Config8723B(struct adapter *Adapter);
void void
PHY_RF6052SetBandwidth8723B(struct adapter *Adapter, PHY_RF6052SetBandwidth8723B(struct adapter *Adapter,
......
...@@ -176,7 +176,7 @@ typedef struct txdesc_8723b ...@@ -176,7 +176,7 @@ typedef struct txdesc_8723b
u32 txbf_path:1; u32 txbf_path:1;
u32 seq:12; u32 seq:12;
u32 final_data_rate:8; u32 final_data_rate:8;
}TXDESC_8723B, *PTXDESC_8723B; } TXDESC_8723B, *PTXDESC_8723B;
#ifndef __INC_HAL8723BDESC_H #ifndef __INC_HAL8723BDESC_H
#define __INC_HAL8723BDESC_H #define __INC_HAL8723BDESC_H
......
...@@ -7,7 +7,7 @@ ...@@ -7,7 +7,7 @@
#ifndef _RTL871X_BYTEORDER_H_ #ifndef _RTL871X_BYTEORDER_H_
#define _RTL871X_BYTEORDER_H_ #define _RTL871X_BYTEORDER_H_
#if defined (__LITTLE_ENDIAN) #if defined(__LITTLE_ENDIAN)
#include <linux/byteorder/little_endian.h> #include <linux/byteorder/little_endian.h>
#else #else
# include <linux/byteorder/big_endian.h> # include <linux/byteorder/big_endian.h>
......
...@@ -75,7 +75,7 @@ do {\ ...@@ -75,7 +75,7 @@ do {\
INIT_LIST_HEAD(&pcmd->list);\ INIT_LIST_HEAD(&pcmd->list);\
pcmd->cmdcode = code;\ pcmd->cmdcode = code;\
pcmd->parmbuf = (u8 *)(pparm);\ pcmd->parmbuf = (u8 *)(pparm);\
pcmd->cmdsz = sizeof (*pparm);\ pcmd->cmdsz = sizeof(*pparm);\
pcmd->rsp = NULL;\ pcmd->rsp = NULL;\
pcmd->rspsz = 0;\ pcmd->rspsz = 0;\
} while (0) } while (0)
...@@ -129,9 +129,9 @@ extern void rtw_free_cmd_obj(struct cmd_obj *pcmd); ...@@ -129,9 +129,9 @@ extern void rtw_free_cmd_obj(struct cmd_obj *pcmd);
void rtw_stop_cmd_thread(struct adapter *adapter); void rtw_stop_cmd_thread(struct adapter *adapter);
int rtw_cmd_thread(void *context); int rtw_cmd_thread(void *context);
extern void rtw_free_cmd_priv (struct cmd_priv *pcmdpriv); extern void rtw_free_cmd_priv(struct cmd_priv *pcmdpriv);
extern void rtw_free_evt_priv (struct evt_priv *pevtpriv); extern void rtw_free_evt_priv(struct evt_priv *pevtpriv);
extern void rtw_evt_notify_isr(struct evt_priv *pevtpriv); extern void rtw_evt_notify_isr(struct evt_priv *pevtpriv);
enum rtw_drvextra_cmd_id enum rtw_drvextra_cmd_id
...@@ -163,10 +163,10 @@ enum LPS_CTRL_TYPE ...@@ -163,10 +163,10 @@ enum LPS_CTRL_TYPE
{ {
LPS_CTRL_SCAN = 0, LPS_CTRL_SCAN = 0,
LPS_CTRL_JOINBSS = 1, LPS_CTRL_JOINBSS = 1,
LPS_CTRL_CONNECT =2, LPS_CTRL_CONNECT = 2,
LPS_CTRL_DISCONNECT =3, LPS_CTRL_DISCONNECT = 3,
LPS_CTRL_SPECIAL_PACKET =4, LPS_CTRL_SPECIAL_PACKET = 4,
LPS_CTRL_LEAVE =5, LPS_CTRL_LEAVE = 5,
LPS_CTRL_TRAFFIC_BUSY = 6, LPS_CTRL_TRAFFIC_BUSY = 6,
}; };
...@@ -692,40 +692,40 @@ struct getratable_rsp { ...@@ -692,40 +692,40 @@ struct getratable_rsp {
/* to get TX, RX retry count */ /* to get TX, RX retry count */
struct gettxretrycnt_parm{ struct gettxretrycnt_parm {
unsigned int rsvd; unsigned int rsvd;
}; };
struct gettxretrycnt_rsp{ struct gettxretrycnt_rsp {
unsigned long tx_retrycnt; unsigned long tx_retrycnt;
}; };
struct getrxretrycnt_parm{ struct getrxretrycnt_parm {
unsigned int rsvd; unsigned int rsvd;
}; };
struct getrxretrycnt_rsp{ struct getrxretrycnt_rsp {
unsigned long rx_retrycnt; unsigned long rx_retrycnt;
}; };
/* to get BCNOK, BCNERR count */ /* to get BCNOK, BCNERR count */
struct getbcnokcnt_parm{ struct getbcnokcnt_parm {
unsigned int rsvd; unsigned int rsvd;
}; };
struct getbcnokcnt_rsp{ struct getbcnokcnt_rsp {
unsigned long bcnokcnt; unsigned long bcnokcnt;
}; };
struct getbcnerrcnt_parm{ struct getbcnerrcnt_parm {
unsigned int rsvd; unsigned int rsvd;
}; };
struct getbcnerrcnt_rsp{ struct getbcnerrcnt_rsp {
unsigned long bcnerrcnt; unsigned long bcnerrcnt;
}; };
/* to get current TX power level */ /* to get current TX power level */
struct getcurtxpwrlevel_parm{ struct getcurtxpwrlevel_parm {
unsigned int rsvd; unsigned int rsvd;
}; };
struct getcurtxpwrlevel_rsp{ struct getcurtxpwrlevel_rsp {
unsigned short tx_power; unsigned short tx_power;
}; };
...@@ -883,56 +883,56 @@ struct _cmd_callback { ...@@ -883,56 +883,56 @@ struct _cmd_callback {
enum rtw_h2c_cmd enum rtw_h2c_cmd
{ {
GEN_CMD_CODE(_Read_MACREG) , /*0*/ GEN_CMD_CODE(_Read_MACREG), /*0*/
GEN_CMD_CODE(_Write_MACREG) , GEN_CMD_CODE(_Write_MACREG),
GEN_CMD_CODE(_Read_BBREG) , GEN_CMD_CODE(_Read_BBREG),
GEN_CMD_CODE(_Write_BBREG) , GEN_CMD_CODE(_Write_BBREG),
GEN_CMD_CODE(_Read_RFREG) , GEN_CMD_CODE(_Read_RFREG),
GEN_CMD_CODE(_Write_RFREG) , /*5*/ GEN_CMD_CODE(_Write_RFREG), /*5*/
GEN_CMD_CODE(_Read_EEPROM) , GEN_CMD_CODE(_Read_EEPROM),
GEN_CMD_CODE(_Write_EEPROM) , GEN_CMD_CODE(_Write_EEPROM),
GEN_CMD_CODE(_Read_EFUSE) , GEN_CMD_CODE(_Read_EFUSE),
GEN_CMD_CODE(_Write_EFUSE) , GEN_CMD_CODE(_Write_EFUSE),
GEN_CMD_CODE(_Read_CAM) , /*10*/ GEN_CMD_CODE(_Read_CAM), /*10*/
GEN_CMD_CODE(_Write_CAM) , GEN_CMD_CODE(_Write_CAM),
GEN_CMD_CODE(_setBCNITV), GEN_CMD_CODE(_setBCNITV),
GEN_CMD_CODE(_setMBIDCFG), GEN_CMD_CODE(_setMBIDCFG),
GEN_CMD_CODE(_JoinBss), /*14*/ GEN_CMD_CODE(_JoinBss), /*14*/
GEN_CMD_CODE(_DisConnect) , /*15*/ GEN_CMD_CODE(_DisConnect), /*15*/
GEN_CMD_CODE(_CreateBss) , GEN_CMD_CODE(_CreateBss),
GEN_CMD_CODE(_SetOpMode) , GEN_CMD_CODE(_SetOpMode),
GEN_CMD_CODE(_SiteSurvey), /*18*/ GEN_CMD_CODE(_SiteSurvey), /*18*/
GEN_CMD_CODE(_SetAuth) , GEN_CMD_CODE(_SetAuth),
GEN_CMD_CODE(_SetKey) , /*20*/ GEN_CMD_CODE(_SetKey), /*20*/
GEN_CMD_CODE(_SetStaKey) , GEN_CMD_CODE(_SetStaKey),
GEN_CMD_CODE(_SetAssocSta) , GEN_CMD_CODE(_SetAssocSta),
GEN_CMD_CODE(_DelAssocSta) , GEN_CMD_CODE(_DelAssocSta),
GEN_CMD_CODE(_SetStaPwrState) , GEN_CMD_CODE(_SetStaPwrState),
GEN_CMD_CODE(_SetBasicRate) , /*25*/ GEN_CMD_CODE(_SetBasicRate), /*25*/
GEN_CMD_CODE(_GetBasicRate) , GEN_CMD_CODE(_GetBasicRate),
GEN_CMD_CODE(_SetDataRate) , GEN_CMD_CODE(_SetDataRate),
GEN_CMD_CODE(_GetDataRate) , GEN_CMD_CODE(_GetDataRate),
GEN_CMD_CODE(_SetPhyInfo) , GEN_CMD_CODE(_SetPhyInfo),
GEN_CMD_CODE(_GetPhyInfo) , /*30*/ GEN_CMD_CODE(_GetPhyInfo), /*30*/
GEN_CMD_CODE(_SetPhy) , GEN_CMD_CODE(_SetPhy),
GEN_CMD_CODE(_GetPhy) , GEN_CMD_CODE(_GetPhy),
GEN_CMD_CODE(_readRssi) , GEN_CMD_CODE(_readRssi),
GEN_CMD_CODE(_readGain) , GEN_CMD_CODE(_readGain),
GEN_CMD_CODE(_SetAtim) , /*35*/ GEN_CMD_CODE(_SetAtim), /*35*/
GEN_CMD_CODE(_SetPwrMode) , GEN_CMD_CODE(_SetPwrMode),
GEN_CMD_CODE(_JoinbssRpt), GEN_CMD_CODE(_JoinbssRpt),
GEN_CMD_CODE(_SetRaTable) , GEN_CMD_CODE(_SetRaTable),
GEN_CMD_CODE(_GetRaTable) , GEN_CMD_CODE(_GetRaTable),
GEN_CMD_CODE(_GetCCXReport), /*40*/ GEN_CMD_CODE(_GetCCXReport), /*40*/
GEN_CMD_CODE(_GetDTMReport), GEN_CMD_CODE(_GetDTMReport),
GEN_CMD_CODE(_GetTXRateStatistics), GEN_CMD_CODE(_GetTXRateStatistics),
GEN_CMD_CODE(_SetUsbSuspend), GEN_CMD_CODE(_SetUsbSuspend),
GEN_CMD_CODE(_SetH2cLbk), GEN_CMD_CODE(_SetH2cLbk),
GEN_CMD_CODE(_AddBAReq) , /*45*/ GEN_CMD_CODE(_AddBAReq), /*45*/
GEN_CMD_CODE(_SetChannel), /*46*/ GEN_CMD_CODE(_SetChannel), /*46*/
GEN_CMD_CODE(_SetTxPower), GEN_CMD_CODE(_SetTxPower),
GEN_CMD_CODE(_SwitchAntenna), GEN_CMD_CODE(_SwitchAntenna),
......
...@@ -131,13 +131,13 @@ ...@@ -131,13 +131,13 @@
#define _MODULE_DEFINE_ _module_efuse_ #define _MODULE_DEFINE_ _module_efuse_
#endif #endif
#define RT_TRACE(_Comp, _Level, Fmt) do{}while (0) #define RT_TRACE(_Comp, _Level, Fmt) do {} while (0)
#define RT_PRINT_DATA(_Comp, _Level, _TitleString, _HexData, _HexDataLen) do{}while (0) #define RT_PRINT_DATA(_Comp, _Level, _TitleString, _HexData, _HexDataLen) do {} while (0)
#define DBG_871X(x, ...) do {} while (0) #define DBG_871X(x, ...) do {} while (0)
#define MSG_8192C(x, ...) do {} while (0) #define MSG_8192C(x, ...) do {} while (0)
#define DBG_8192C(x,...) do {} while (0) #define DBG_8192C(x, ...) do {} while (0)
#define DBG_871X_LEVEL(x,...) do {} while (0) #define DBG_871X_LEVEL(x, ...) do {} while (0)
#undef _dbgdump #undef _dbgdump
...@@ -161,8 +161,8 @@ ...@@ -161,8 +161,8 @@
_dbgdump(DRIVER_PREFIX"ERROR " fmt, ##arg);\ _dbgdump(DRIVER_PREFIX"ERROR " fmt, ##arg);\
else \ else \
_dbgdump(DRIVER_PREFIX fmt, ##arg);\ _dbgdump(DRIVER_PREFIX fmt, ##arg);\
}\ } \
}while (0) } while (0)
/* without driver-defined prefix */ /* without driver-defined prefix */
#undef _DBG_871X_LEVEL #undef _DBG_871X_LEVEL
...@@ -173,8 +173,8 @@ ...@@ -173,8 +173,8 @@
_dbgdump("ERROR " fmt, ##arg);\ _dbgdump("ERROR " fmt, ##arg);\
else \ else \
_dbgdump(fmt, ##arg);\ _dbgdump(fmt, ##arg);\
}\ } \
}while (0) } while (0)
#define RTW_DBGDUMP NULL /* 'stream' for _dbgdump */ #define RTW_DBGDUMP NULL /* 'stream' for _dbgdump */
...@@ -203,17 +203,17 @@ ...@@ -203,17 +203,17 @@
#undef DBG_871X #undef DBG_871X
#define DBG_871X(...) do {\ #define DBG_871X(...) do {\
_dbgdump(DRIVER_PREFIX __VA_ARGS__);\ _dbgdump(DRIVER_PREFIX __VA_ARGS__);\
}while (0) } while (0)
#undef MSG_8192C #undef MSG_8192C
#define MSG_8192C(...) do {\ #define MSG_8192C(...) do {\
_dbgdump(DRIVER_PREFIX __VA_ARGS__);\ _dbgdump(DRIVER_PREFIX __VA_ARGS__);\
}while (0) } while (0)
#undef DBG_8192C #undef DBG_8192C
#define DBG_8192C(...) do {\ #define DBG_8192C(...) do {\
_dbgdump(DRIVER_PREFIX __VA_ARGS__);\ _dbgdump(DRIVER_PREFIX __VA_ARGS__);\
}while (0) } while (0)
#endif /* defined(_dbgdump) */ #endif /* defined(_dbgdump) */
#endif /* DEBUG */ #endif /* DEBUG */
...@@ -227,8 +227,8 @@ ...@@ -227,8 +227,8 @@
if ((_Comp & GlobalDebugComponents) && (_Level <= GlobalDebugLevel)) {\ if ((_Comp & GlobalDebugComponents) && (_Level <= GlobalDebugLevel)) {\
_dbgdump("%s [0x%08x,%d]", DRIVER_PREFIX, (unsigned int)_Comp, _Level);\ _dbgdump("%s [0x%08x,%d]", DRIVER_PREFIX, (unsigned int)_Comp, _Level);\
_dbgdump Fmt;\ _dbgdump Fmt;\
}\ } \
}while (0) } while (0)
#endif /* defined(_dbgdump) && defined(_MODULE_DEFINE_) */ #endif /* defined(_dbgdump) && defined(_MODULE_DEFINE_) */
...@@ -242,7 +242,7 @@ ...@@ -242,7 +242,7 @@
u8 *ptr = (u8 *)_HexData; \ u8 *ptr = (u8 *)_HexData; \
_dbgdump("%s", DRIVER_PREFIX); \ _dbgdump("%s", DRIVER_PREFIX); \
_dbgdump(_TitleString); \ _dbgdump(_TitleString); \
for (__i = 0; __i<(int)_HexDataLen; __i++) \ for (__i = 0; __i < (int)_HexDataLen; __i++) \
{ \ { \
_dbgdump("%02X%s", ptr[__i], (((__i + 1) % 4) == 0)?" ":" "); \ _dbgdump("%02X%s", ptr[__i], (((__i + 1) % 4) == 0)?" ":" "); \
if (((__i + 1) % 16) == 0) _dbgdump("\n"); \ if (((__i + 1) % 16) == 0) _dbgdump("\n"); \
......
...@@ -91,7 +91,7 @@ typedef enum _RT_CUSTOMER_ID ...@@ -91,7 +91,7 @@ typedef enum _RT_CUSTOMER_ID
RT_CID_819x_ALPHA_Dlink = 44,/* add by ylb 20121012 for customer led for alpha */ RT_CID_819x_ALPHA_Dlink = 44,/* add by ylb 20121012 for customer led for alpha */
RT_CID_WNC_NEC = 45,/* add by page for NEC */ RT_CID_WNC_NEC = 45,/* add by page for NEC */
RT_CID_DNI_BUFFALO = 46,/* add by page for NEC */ RT_CID_DNI_BUFFALO = 46,/* add by page for NEC */
}RT_CUSTOMER_ID, *PRT_CUSTOMER_ID; } RT_CUSTOMER_ID, *PRT_CUSTOMER_ID;
struct eeprom_priv struct eeprom_priv
{ {
......
...@@ -57,15 +57,15 @@ enum _EFUSE_DEF_TYPE { ...@@ -57,15 +57,15 @@ enum _EFUSE_DEF_TYPE {
#define EFUSE_MAX_WORD_UNIT 4 #define EFUSE_MAX_WORD_UNIT 4
/*------------------------------Define structure----------------------------*/ /*------------------------------Define structure----------------------------*/
typedef struct PG_PKT_STRUCT_A{ typedef struct PG_PKT_STRUCT_A {
u8 offset; u8 offset;
u8 word_en; u8 word_en;
u8 data[8]; u8 data[8];
u8 word_cnts; u8 word_cnts;
}PGPKT_STRUCT,*PPGPKT_STRUCT; } PGPKT_STRUCT, *PPGPKT_STRUCT;
/*------------------------------Define structure----------------------------*/ /*------------------------------Define structure----------------------------*/
typedef struct _EFUSE_HAL{ typedef struct _EFUSE_HAL {
u8 fakeEfuseBank; u8 fakeEfuseBank;
u32 fakeEfuseUsedBytes; u32 fakeEfuseUsedBytes;
u8 fakeEfuseContent[EFUSE_MAX_HW_SIZE]; u8 fakeEfuseContent[EFUSE_MAX_HW_SIZE];
...@@ -82,7 +82,7 @@ typedef struct _EFUSE_HAL{ ...@@ -82,7 +82,7 @@ typedef struct _EFUSE_HAL{
u8 fakeBTEfuseContent[EFUSE_MAX_BT_BANK][EFUSE_MAX_HW_SIZE]; u8 fakeBTEfuseContent[EFUSE_MAX_BT_BANK][EFUSE_MAX_HW_SIZE];
u8 fakeBTEfuseInitMap[EFUSE_BT_MAX_MAP_LEN]; u8 fakeBTEfuseInitMap[EFUSE_BT_MAX_MAP_LEN];
u8 fakeBTEfuseModifiedMap[EFUSE_BT_MAX_MAP_LEN]; u8 fakeBTEfuseModifiedMap[EFUSE_BT_MAX_MAP_LEN];
}EFUSE_HAL, *PEFUSE_HAL; } EFUSE_HAL, *PEFUSE_HAL;
/*------------------------Export global variable----------------------------*/ /*------------------------Export global variable----------------------------*/
......
...@@ -82,7 +82,7 @@ struct fwevent { ...@@ -82,7 +82,7 @@ struct fwevent {
#define C2HEVENT_SZ 32 #define C2HEVENT_SZ 32
struct event_node{ struct event_node {
unsigned char *node; unsigned char *node;
unsigned char evt_code; unsigned char evt_code;
unsigned short evt_sz; unsigned short evt_sz;
......
...@@ -38,7 +38,7 @@ struct ht_priv ...@@ -38,7 +38,7 @@ struct ht_priv
}; };
typedef enum AGGRE_SIZE{ typedef enum AGGRE_SIZE {
HT_AGG_SIZE_8K = 0, HT_AGG_SIZE_8K = 0,
HT_AGG_SIZE_16K = 1, HT_AGG_SIZE_16K = 1,
HT_AGG_SIZE_32K = 2, HT_AGG_SIZE_32K = 2,
...@@ -47,9 +47,9 @@ typedef enum AGGRE_SIZE{ ...@@ -47,9 +47,9 @@ typedef enum AGGRE_SIZE{
VHT_AGG_SIZE_256K = 5, VHT_AGG_SIZE_256K = 5,
VHT_AGG_SIZE_512K = 6, VHT_AGG_SIZE_512K = 6,
VHT_AGG_SIZE_1024K = 7, VHT_AGG_SIZE_1024K = 7,
}AGGRE_SIZE_E, *PAGGRE_SIZE_E; } AGGRE_SIZE_E, *PAGGRE_SIZE_E;
typedef enum _RT_HT_INF0_CAP{ typedef enum _RT_HT_INF0_CAP {
RT_HT_CAP_USE_TURBO_AGGR = 0x01, RT_HT_CAP_USE_TURBO_AGGR = 0x01,
RT_HT_CAP_USE_LONG_PREAMBLE = 0x02, RT_HT_CAP_USE_LONG_PREAMBLE = 0x02,
RT_HT_CAP_USE_AMPDU = 0x04, RT_HT_CAP_USE_AMPDU = 0x04,
...@@ -58,13 +58,13 @@ typedef enum _RT_HT_INF0_CAP{ ...@@ -58,13 +58,13 @@ typedef enum _RT_HT_INF0_CAP{
RT_HT_CAP_USE_92SE = 0x20, RT_HT_CAP_USE_92SE = 0x20,
RT_HT_CAP_USE_88C_92C = 0x40, RT_HT_CAP_USE_88C_92C = 0x40,
RT_HT_CAP_USE_AP_CLIENT_MODE = 0x80, /* AP team request to reserve this bit, by Emily */ RT_HT_CAP_USE_AP_CLIENT_MODE = 0x80, /* AP team request to reserve this bit, by Emily */
}RT_HT_INF0_CAPBILITY, *PRT_HT_INF0_CAPBILITY; } RT_HT_INF0_CAPBILITY, *PRT_HT_INF0_CAPBILITY;
typedef enum _RT_HT_INF1_CAP{ typedef enum _RT_HT_INF1_CAP {
RT_HT_CAP_USE_VIDEO_CLIENT = 0x01, RT_HT_CAP_USE_VIDEO_CLIENT = 0x01,
RT_HT_CAP_USE_JAGUAR_BCUT = 0x02, RT_HT_CAP_USE_JAGUAR_BCUT = 0x02,
RT_HT_CAP_USE_JAGUAR_CCUT = 0x04, RT_HT_CAP_USE_JAGUAR_CCUT = 0x04,
}RT_HT_INF1_CAPBILITY, *PRT_HT_INF1_CAPBILITY; } RT_HT_INF1_CAPBILITY, *PRT_HT_INF1_CAPBILITY;
#define LDPC_HT_ENABLE_RX BIT0 #define LDPC_HT_ENABLE_RX BIT0
#define LDPC_HT_ENABLE_TX BIT1 #define LDPC_HT_ENABLE_TX BIT1
......
...@@ -168,7 +168,7 @@ struct reg_protocol_rd { ...@@ -168,7 +168,7 @@ struct reg_protocol_rd {
u32 Byte2Access : 1; u32 Byte2Access : 1;
u32 Byte1Access : 1; u32 Byte1Access : 1;
u32 BurstMode :1 ; u32 BurstMode :1;
u32 FixOrContinuous : 1; u32 FixOrContinuous : 1;
u32 Reserved4 : 16; u32 Reserved4 : 16;
...@@ -224,7 +224,7 @@ struct reg_protocol_wt { ...@@ -224,7 +224,7 @@ struct reg_protocol_wt {
u32 Byte2Access : 1; u32 Byte2Access : 1;
u32 Byte1Access : 1; u32 Byte1Access : 1;
u32 BurstMode :1 ; u32 BurstMode :1;
u32 FixOrContinuous : 1; u32 FixOrContinuous : 1;
u32 Reserved4 : 16; u32 Reserved4 : 16;
...@@ -259,7 +259,7 @@ struct io_queue { ...@@ -259,7 +259,7 @@ struct io_queue {
struct intf_hdl intf; struct intf_hdl intf;
}; };
struct io_priv{ struct io_priv {
struct adapter *padapter; struct adapter *padapter;
......
...@@ -85,7 +85,7 @@ typedef enum _RT_SCAN_TYPE { ...@@ -85,7 +85,7 @@ typedef enum _RT_SCAN_TYPE {
SCAN_PASSIVE, SCAN_PASSIVE,
SCAN_ACTIVE, SCAN_ACTIVE,
SCAN_MIX, SCAN_MIX,
}RT_SCAN_TYPE, *PRT_SCAN_TYPE; } RT_SCAN_TYPE, *PRT_SCAN_TYPE;
enum _BAND { enum _BAND {
GHZ24_50 = 0, GHZ24_50 = 0,
...@@ -135,7 +135,7 @@ struct sitesurvey_ctrl { ...@@ -135,7 +135,7 @@ struct sitesurvey_ctrl {
_timer sitesurvey_ctrl_timer; _timer sitesurvey_ctrl_timer;
}; };
typedef struct _RT_LINK_DETECT_T{ typedef struct _RT_LINK_DETECT_T {
u32 NumTxOkInPeriod; u32 NumTxOkInPeriod;
u32 NumRxOkInPeriod; u32 NumRxOkInPeriod;
u32 NumRxUnicastOkInPeriod; u32 NumRxUnicastOkInPeriod;
...@@ -148,62 +148,62 @@ typedef struct _RT_LINK_DETECT_T{ ...@@ -148,62 +148,62 @@ typedef struct _RT_LINK_DETECT_T{
/* u8 TrafficBusyState; */ /* u8 TrafficBusyState; */
u8 TrafficTransitionCount; u8 TrafficTransitionCount;
u32 LowPowerTransitionCount; u32 LowPowerTransitionCount;
}RT_LINK_DETECT_T, *PRT_LINK_DETECT_T; } RT_LINK_DETECT_T, *PRT_LINK_DETECT_T;
struct profile_info { struct profile_info {
u8 ssidlen; u8 ssidlen;
u8 ssid[ WLAN_SSID_MAXLEN ]; u8 ssid[WLAN_SSID_MAXLEN];
u8 peermac[ ETH_ALEN ]; u8 peermac[ETH_ALEN];
}; };
struct tx_invite_req_info{ struct tx_invite_req_info {
u8 token; u8 token;
u8 benable; u8 benable;
u8 go_ssid[ WLAN_SSID_MAXLEN ]; u8 go_ssid[WLAN_SSID_MAXLEN];
u8 ssidlen; u8 ssidlen;
u8 go_bssid[ ETH_ALEN ]; u8 go_bssid[ETH_ALEN];
u8 peer_macaddr[ ETH_ALEN ]; u8 peer_macaddr[ETH_ALEN];
u8 operating_ch; /* This information will be set by using the p2p_set op_ch =x */ u8 operating_ch; /* This information will be set by using the p2p_set op_ch =x */
u8 peer_ch; /* The listen channel for peer P2P device */ u8 peer_ch; /* The listen channel for peer P2P device */
}; };
struct tx_invite_resp_info{ struct tx_invite_resp_info {
u8 token; /* Used to record the dialog token of p2p invitation request frame. */ u8 token; /* Used to record the dialog token of p2p invitation request frame. */
}; };
struct tx_provdisc_req_info{ struct tx_provdisc_req_info {
u16 wps_config_method_request; /* Used when sending the provisioning request frame */ u16 wps_config_method_request; /* Used when sending the provisioning request frame */
u16 peer_channel_num[2]; /* The channel number which the receiver stands. */ u16 peer_channel_num[2]; /* The channel number which the receiver stands. */
struct ndis_802_11_ssid ssid; struct ndis_802_11_ssid ssid;
u8 peerDevAddr[ ETH_ALEN ]; /* Peer device address */ u8 peerDevAddr[ETH_ALEN]; /* Peer device address */
u8 peerIFAddr[ ETH_ALEN ]; /* Peer interface address */ u8 peerIFAddr[ETH_ALEN]; /* Peer interface address */
u8 benable; /* This provision discovery request frame is trigger to send or not */ u8 benable; /* This provision discovery request frame is trigger to send or not */
}; };
struct rx_provdisc_req_info{ /* When peer device issue prov_disc_req first, we should store the following informations */ struct rx_provdisc_req_info { /* When peer device issue prov_disc_req first, we should store the following informations */
u8 peerDevAddr[ ETH_ALEN ]; /* Peer device address */ u8 peerDevAddr[ETH_ALEN]; /* Peer device address */
u8 strconfig_method_desc_of_prov_disc_req[4]; /* description for the config method located in the provisioning discovery request frame. */ u8 strconfig_method_desc_of_prov_disc_req[4]; /* description for the config method located in the provisioning discovery request frame. */
/* The UI must know this information to know which config method the remote p2p device is requiring. */ /* The UI must know this information to know which config method the remote p2p device is requiring. */
}; };
struct tx_nego_req_info{ struct tx_nego_req_info {
u16 peer_channel_num[2]; /* The channel number which the receiver stands. */ u16 peer_channel_num[2]; /* The channel number which the receiver stands. */
u8 peerDevAddr[ ETH_ALEN ]; /* Peer device address */ u8 peerDevAddr[ETH_ALEN]; /* Peer device address */
u8 benable; /* This negoitation request frame is trigger to send or not */ u8 benable; /* This negoitation request frame is trigger to send or not */
}; };
struct group_id_info{ struct group_id_info {
u8 go_device_addr[ ETH_ALEN ]; /* The GO's device address of this P2P group */ u8 go_device_addr[ETH_ALEN]; /* The GO's device address of this P2P group */
u8 ssid[ WLAN_SSID_MAXLEN ]; /* The SSID of this P2P group */ u8 ssid[WLAN_SSID_MAXLEN]; /* The SSID of this P2P group */
}; };
struct scan_limit_info{ struct scan_limit_info {
u8 scan_op_ch_only; /* When this flag is set, the driver should just scan the operation channel */ u8 scan_op_ch_only; /* When this flag is set, the driver should just scan the operation channel */
u8 operation_ch[2]; /* Store the operation channel of invitation request frame */ u8 operation_ch[2]; /* Store the operation channel of invitation request frame */
}; };
struct cfg80211_wifidirect_info{ struct cfg80211_wifidirect_info {
_timer remain_on_ch_timer; _timer remain_on_ch_timer;
u8 restore_channel; u8 restore_channel;
struct ieee80211_channel remain_on_ch_channel; struct ieee80211_channel remain_on_ch_channel;
...@@ -213,7 +213,7 @@ struct cfg80211_wifidirect_info{ ...@@ -213,7 +213,7 @@ struct cfg80211_wifidirect_info{
unsigned long last_ro_ch_time; /* this will be updated at the beginning and end of ro_ch */ unsigned long last_ro_ch_time; /* this will be updated at the beginning and end of ro_ch */
}; };
struct wifidirect_info{ struct wifidirect_info {
struct adapter * padapter; struct adapter * padapter;
_timer find_phase_timer; _timer find_phase_timer;
_timer restore_p2p_state_timer; _timer restore_p2p_state_timer;
...@@ -225,7 +225,7 @@ struct wifidirect_info{ ...@@ -225,7 +225,7 @@ struct wifidirect_info{
struct tx_provdisc_req_info tx_prov_disc_info; struct tx_provdisc_req_info tx_prov_disc_info;
struct rx_provdisc_req_info rx_prov_disc_info; struct rx_provdisc_req_info rx_prov_disc_info;
struct tx_invite_req_info invitereq_info; struct tx_invite_req_info invitereq_info;
struct profile_info profileinfo[ P2P_MAX_PERSISTENT_GROUP_NUM ]; /* Store the profile information of persistent group */ struct profile_info profileinfo[P2P_MAX_PERSISTENT_GROUP_NUM]; /* Store the profile information of persistent group */
struct tx_invite_resp_info inviteresp_info; struct tx_invite_resp_info inviteresp_info;
struct tx_nego_req_info nego_req_info; struct tx_nego_req_info nego_req_info;
struct group_id_info groupid_info; /* Store the group id information when doing the group negotiation handshake. */ struct group_id_info groupid_info; /* Store the group id information when doing the group negotiation handshake. */
...@@ -243,17 +243,17 @@ struct wifidirect_info{ ...@@ -243,17 +243,17 @@ struct wifidirect_info{
u8 support_rate[8]; u8 support_rate[8];
u8 p2p_wildcard_ssid[P2P_WILDCARD_SSID_LEN]; u8 p2p_wildcard_ssid[P2P_WILDCARD_SSID_LEN];
u8 intent; /* should only include the intent value. */ u8 intent; /* should only include the intent value. */
u8 p2p_peer_interface_addr[ ETH_ALEN ]; u8 p2p_peer_interface_addr[ETH_ALEN];
u8 p2p_peer_device_addr[ ETH_ALEN ]; u8 p2p_peer_device_addr[ETH_ALEN];
u8 peer_intent; /* Included the intent value and tie breaker value. */ u8 peer_intent; /* Included the intent value and tie breaker value. */
u8 device_name[ WPS_MAX_DEVICE_NAME_LEN ]; /* Device name for displaying on searching device screen */ u8 device_name[WPS_MAX_DEVICE_NAME_LEN]; /* Device name for displaying on searching device screen */
u8 device_name_len; u8 device_name_len;
u8 profileindex; /* Used to point to the index of profileinfo array */ u8 profileindex; /* Used to point to the index of profileinfo array */
u8 peer_operating_ch; u8 peer_operating_ch;
u8 find_phase_state_exchange_cnt; u8 find_phase_state_exchange_cnt;
u16 device_password_id_for_nego; /* The device password ID for group negotation */ u16 device_password_id_for_nego; /* The device password ID for group negotation */
u8 negotiation_dialog_token; u8 negotiation_dialog_token;
u8 nego_ssid[ WLAN_SSID_MAXLEN ]; /* SSID information for group negotitation */ u8 nego_ssid[WLAN_SSID_MAXLEN]; /* SSID information for group negotitation */
u8 nego_ssidlen; u8 nego_ssidlen;
u8 p2p_group_ssid[WLAN_SSID_MAXLEN]; u8 p2p_group_ssid[WLAN_SSID_MAXLEN];
u8 p2p_group_ssid_len; u8 p2p_group_ssid_len;
...@@ -287,13 +287,13 @@ struct wifidirect_info{ ...@@ -287,13 +287,13 @@ struct wifidirect_info{
u8 driver_interface; /* Indicate DRIVER_WEXT or DRIVER_CFG80211 */ u8 driver_interface; /* Indicate DRIVER_WEXT or DRIVER_CFG80211 */
}; };
struct tdls_ss_record{ /* signal strength record */ struct tdls_ss_record { /* signal strength record */
u8 macaddr[ETH_ALEN]; u8 macaddr[ETH_ALEN];
u8 rx_pwd_ba11; u8 rx_pwd_ba11;
u8 is_tdls_sta; /* true: direct link sta, false: else */ u8 is_tdls_sta; /* true: direct link sta, false: else */
}; };
struct tdls_info{ struct tdls_info {
u8 ap_prohibited; u8 ap_prohibited;
u8 link_established; u8 link_established;
u8 sta_cnt; u8 sta_cnt;
...@@ -489,7 +489,7 @@ int event_thread(void *context); ...@@ -489,7 +489,7 @@ int event_thread(void *context);
extern void rtw_free_network_queue(struct adapter *adapter, u8 isfreeall); extern void rtw_free_network_queue(struct adapter *adapter, u8 isfreeall);
extern int rtw_init_mlme_priv(struct adapter *adapter);/* (struct mlme_priv *pmlmepriv); */ extern int rtw_init_mlme_priv(struct adapter *adapter);/* (struct mlme_priv *pmlmepriv); */
extern void rtw_free_mlme_priv (struct mlme_priv *pmlmepriv); extern void rtw_free_mlme_priv(struct mlme_priv *pmlmepriv);
extern sint rtw_select_and_join_from_scanned_queue(struct mlme_priv *pmlmepriv); extern sint rtw_select_and_join_from_scanned_queue(struct mlme_priv *pmlmepriv);
...@@ -526,7 +526,7 @@ static inline void set_fwstate(struct mlme_priv *pmlmepriv, sint state) ...@@ -526,7 +526,7 @@ static inline void set_fwstate(struct mlme_priv *pmlmepriv, sint state)
{ {
pmlmepriv->fw_state |= state; pmlmepriv->fw_state |= state;
/* FOR HW integration */ /* FOR HW integration */
if (_FW_UNDER_SURVEY ==state) { if (_FW_UNDER_SURVEY == state) {
pmlmepriv->bScanInProcess = true; pmlmepriv->bScanInProcess = true;
} }
} }
...@@ -535,7 +535,7 @@ static inline void _clr_fwstate_(struct mlme_priv *pmlmepriv, sint state) ...@@ -535,7 +535,7 @@ static inline void _clr_fwstate_(struct mlme_priv *pmlmepriv, sint state)
{ {
pmlmepriv->fw_state &= ~state; pmlmepriv->fw_state &= ~state;
/* FOR HW integration */ /* FOR HW integration */
if (_FW_UNDER_SURVEY ==state) { if (_FW_UNDER_SURVEY == state) {
pmlmepriv->bScanInProcess = false; pmlmepriv->bScanInProcess = false;
} }
} }
......
...@@ -182,7 +182,7 @@ typedef enum _RT_CHANNEL_DOMAIN ...@@ -182,7 +182,7 @@ typedef enum _RT_CHANNEL_DOMAIN
/* Add new channel plan above this line =============== */ /* Add new channel plan above this line =============== */
RT_CHANNEL_DOMAIN_MAX, RT_CHANNEL_DOMAIN_MAX,
RT_CHANNEL_DOMAIN_REALTEK_DEFINE = 0x7F, RT_CHANNEL_DOMAIN_REALTEK_DEFINE = 0x7F,
}RT_CHANNEL_DOMAIN, *PRT_CHANNEL_DOMAIN; } RT_CHANNEL_DOMAIN, *PRT_CHANNEL_DOMAIN;
typedef enum _RT_CHANNEL_DOMAIN_2G typedef enum _RT_CHANNEL_DOMAIN_2G
{ {
...@@ -195,7 +195,7 @@ typedef enum _RT_CHANNEL_DOMAIN_2G ...@@ -195,7 +195,7 @@ typedef enum _RT_CHANNEL_DOMAIN_2G
RT_CHANNEL_DOMAIN_2G_NULL = 0x06, RT_CHANNEL_DOMAIN_2G_NULL = 0x06,
/* Add new channel plan above this line =============== */ /* Add new channel plan above this line =============== */
RT_CHANNEL_DOMAIN_2G_MAX, RT_CHANNEL_DOMAIN_2G_MAX,
}RT_CHANNEL_DOMAIN_2G, *PRT_CHANNEL_DOMAIN_2G; } RT_CHANNEL_DOMAIN_2G, *PRT_CHANNEL_DOMAIN_2G;
typedef enum _RT_CHANNEL_DOMAIN_5G typedef enum _RT_CHANNEL_DOMAIN_5G
{ {
...@@ -237,33 +237,33 @@ typedef enum _RT_CHANNEL_DOMAIN_5G ...@@ -237,33 +237,33 @@ typedef enum _RT_CHANNEL_DOMAIN_5G
RT_CHANNEL_DOMAIN_5G_JAPAN_NO_DFS = 0x21, RT_CHANNEL_DOMAIN_5G_JAPAN_NO_DFS = 0x21,
RT_CHANNEL_DOMAIN_5G_FCC4_NO_DFS = 0x22, RT_CHANNEL_DOMAIN_5G_FCC4_NO_DFS = 0x22,
RT_CHANNEL_DOMAIN_5G_MAX, RT_CHANNEL_DOMAIN_5G_MAX,
}RT_CHANNEL_DOMAIN_5G, *PRT_CHANNEL_DOMAIN_5G; } RT_CHANNEL_DOMAIN_5G, *PRT_CHANNEL_DOMAIN_5G;
#define rtw_is_channel_plan_valid(chplan) (chplan<RT_CHANNEL_DOMAIN_MAX || chplan == RT_CHANNEL_DOMAIN_REALTEK_DEFINE) #define rtw_is_channel_plan_valid(chplan) (chplan < RT_CHANNEL_DOMAIN_MAX || chplan == RT_CHANNEL_DOMAIN_REALTEK_DEFINE)
typedef struct _RT_CHANNEL_PLAN typedef struct _RT_CHANNEL_PLAN
{ {
unsigned char Channel[MAX_CHANNEL_NUM]; unsigned char Channel[MAX_CHANNEL_NUM];
unsigned char Len; unsigned char Len;
}RT_CHANNEL_PLAN, *PRT_CHANNEL_PLAN; } RT_CHANNEL_PLAN, *PRT_CHANNEL_PLAN;
typedef struct _RT_CHANNEL_PLAN_2G typedef struct _RT_CHANNEL_PLAN_2G
{ {
unsigned char Channel[MAX_CHANNEL_NUM_2G]; unsigned char Channel[MAX_CHANNEL_NUM_2G];
unsigned char Len; unsigned char Len;
}RT_CHANNEL_PLAN_2G, *PRT_CHANNEL_PLAN_2G; } RT_CHANNEL_PLAN_2G, *PRT_CHANNEL_PLAN_2G;
typedef struct _RT_CHANNEL_PLAN_5G typedef struct _RT_CHANNEL_PLAN_5G
{ {
unsigned char Channel[MAX_CHANNEL_NUM_5G]; unsigned char Channel[MAX_CHANNEL_NUM_5G];
unsigned char Len; unsigned char Len;
}RT_CHANNEL_PLAN_5G, *PRT_CHANNEL_PLAN_5G; } RT_CHANNEL_PLAN_5G, *PRT_CHANNEL_PLAN_5G;
typedef struct _RT_CHANNEL_PLAN_MAP typedef struct _RT_CHANNEL_PLAN_MAP
{ {
unsigned char Index2G; unsigned char Index2G;
unsigned char Index5G; unsigned char Index5G;
}RT_CHANNEL_PLAN_MAP, *PRT_CHANNEL_PLAN_MAP; } RT_CHANNEL_PLAN_MAP, *PRT_CHANNEL_PLAN_MAP;
enum Associated_AP enum Associated_AP
{ {
...@@ -299,7 +299,7 @@ typedef enum _HT_IOT_PEER ...@@ -299,7 +299,7 @@ typedef enum _HT_IOT_PEER
HT_IOT_PEER_REALTEK_JAGUAR_BCUTAP = 16, HT_IOT_PEER_REALTEK_JAGUAR_BCUTAP = 16,
HT_IOT_PEER_REALTEK_JAGUAR_CCUTAP = 17, HT_IOT_PEER_REALTEK_JAGUAR_CCUTAP = 17,
HT_IOT_PEER_MAX = 18 HT_IOT_PEER_MAX = 18
}HT_IOT_PEER_E, *PHTIOT_PEER_E; } HT_IOT_PEER_E, *PHTIOT_PEER_E;
enum SCAN_STATE enum SCAN_STATE
...@@ -353,7 +353,7 @@ struct ss_res ...@@ -353,7 +353,7 @@ struct ss_res
#define WIFI_FW_ASSOC_STATE 0x00002000 #define WIFI_FW_ASSOC_STATE 0x00002000
#define WIFI_FW_ASSOC_SUCCESS 0x00004000 #define WIFI_FW_ASSOC_SUCCESS 0x00004000
#define WIFI_FW_LINKING_STATE (WIFI_FW_AUTH_NULL | WIFI_FW_AUTH_STATE | WIFI_FW_AUTH_SUCCESS |WIFI_FW_ASSOC_STATE) #define WIFI_FW_LINKING_STATE (WIFI_FW_AUTH_NULL | WIFI_FW_AUTH_STATE | WIFI_FW_AUTH_SUCCESS | WIFI_FW_ASSOC_STATE)
struct FW_Sta_Info struct FW_Sta_Info
{ {
...@@ -434,7 +434,7 @@ typedef struct _RT_CHANNEL_INFO ...@@ -434,7 +434,7 @@ typedef struct _RT_CHANNEL_INFO
{ {
u8 ChannelNum; /* The channel number. */ u8 ChannelNum; /* The channel number. */
RT_SCAN_TYPE ScanType; /* Scan type such as passive or active scan. */ RT_SCAN_TYPE ScanType; /* Scan type such as passive or active scan. */
}RT_CHANNEL_INFO, *PRT_CHANNEL_INFO; } RT_CHANNEL_INFO, *PRT_CHANNEL_INFO;
int rtw_ch_set_search_ch(RT_CHANNEL_INFO *ch_set, const u32 ch); int rtw_ch_set_search_ch(RT_CHANNEL_INFO *ch_set, const u32 ch);
bool rtw_mlme_band_check(struct adapter *adapter, const u32 ch); bool rtw_mlme_band_check(struct adapter *adapter, const u32 ch);
...@@ -537,7 +537,7 @@ struct mlme_ext_priv ...@@ -537,7 +537,7 @@ struct mlme_ext_priv
void init_mlme_default_rate_set(struct adapter *padapter); void init_mlme_default_rate_set(struct adapter *padapter);
void init_mlme_ext_priv(struct adapter *padapter); void init_mlme_ext_priv(struct adapter *padapter);
int init_hw_mlme_ext(struct adapter *padapter); int init_hw_mlme_ext(struct adapter *padapter);
void free_mlme_ext_priv (struct mlme_ext_priv *pmlmeext); void free_mlme_ext_priv(struct mlme_ext_priv *pmlmeext);
extern void init_mlme_ext_timer(struct adapter *padapter); extern void init_mlme_ext_timer(struct adapter *padapter);
extern void init_addba_retry_timer(struct adapter *padapter, struct sta_info *psta); extern void init_addba_retry_timer(struct adapter *padapter, struct sta_info *psta);
extern struct xmit_frame *alloc_mgtxmitframe(struct xmit_priv *pxmitpriv); extern struct xmit_frame *alloc_mgtxmitframe(struct xmit_priv *pxmitpriv);
...@@ -571,7 +571,7 @@ void SelectChannel(struct adapter *padapter, unsigned char channel); ...@@ -571,7 +571,7 @@ void SelectChannel(struct adapter *padapter, unsigned char channel);
unsigned int decide_wait_for_beacon_timeout(unsigned int bcn_interval); unsigned int decide_wait_for_beacon_timeout(unsigned int bcn_interval);
void read_cam(struct adapter *padapter , u8 entry, u8 *get_key); void read_cam(struct adapter *padapter, u8 entry, u8 *get_key);
/* modify HW only */ /* modify HW only */
void _write_cam(struct adapter *padapter, u8 entry, u16 ctrl, u8 *mac, u8 *key); void _write_cam(struct adapter *padapter, u8 entry, u16 ctrl, u8 *mac, u8 *key);
...@@ -708,8 +708,8 @@ void linked_status_chk(struct adapter *padapter); ...@@ -708,8 +708,8 @@ void linked_status_chk(struct adapter *padapter);
void _linked_info_dump(struct adapter *padapter); void _linked_info_dump(struct adapter *padapter);
void survey_timer_hdl (struct timer_list *t); void survey_timer_hdl(struct timer_list *t);
void link_timer_hdl (struct timer_list *t); void link_timer_hdl(struct timer_list *t);
void addba_timer_hdl(struct timer_list *t); void addba_timer_hdl(struct timer_list *t);
void sa_query_timer_hdl(struct timer_list *t); void sa_query_timer_hdl(struct timer_list *t);
/* void reauth_timer_hdl(struct adapter *padapter); */ /* void reauth_timer_hdl(struct adapter *padapter); */
...@@ -802,8 +802,8 @@ struct C2HEvent_Header ...@@ -802,8 +802,8 @@ struct C2HEvent_Header
unsigned int rsvd; unsigned int rsvd;
}; };
void rtw_dummy_event_callback(struct adapter *adapter , u8 *pbuf); void rtw_dummy_event_callback(struct adapter *adapter, u8 *pbuf);
void rtw_fwdbg_event_callback(struct adapter *adapter , u8 *pbuf); void rtw_fwdbg_event_callback(struct adapter *adapter, u8 *pbuf);
enum rtw_c2h_event enum rtw_c2h_event
{ {
...@@ -818,10 +818,10 @@ enum rtw_c2h_event ...@@ -818,10 +818,10 @@ enum rtw_c2h_event
GEN_EVT_CODE(_Survey), /*8*/ GEN_EVT_CODE(_Survey), /*8*/
GEN_EVT_CODE(_SurveyDone), /*9*/ GEN_EVT_CODE(_SurveyDone), /*9*/
GEN_EVT_CODE(_JoinBss) , /*10*/ GEN_EVT_CODE(_JoinBss), /*10*/
GEN_EVT_CODE(_AddSTA), GEN_EVT_CODE(_AddSTA),
GEN_EVT_CODE(_DelSTA), GEN_EVT_CODE(_DelSTA),
GEN_EVT_CODE(_AtimDone) , GEN_EVT_CODE(_AtimDone),
GEN_EVT_CODE(_TX_Report), GEN_EVT_CODE(_TX_Report),
GEN_EVT_CODE(_CCX_Report), /*15*/ GEN_EVT_CODE(_CCX_Report), /*15*/
GEN_EVT_CODE(_DTM_Report), GEN_EVT_CODE(_DTM_Report),
...@@ -851,7 +851,7 @@ static struct fwevent wlanevents[] = ...@@ -851,7 +851,7 @@ static struct fwevent wlanevents[] =
{0, NULL}, {0, NULL},
{0, NULL}, {0, NULL},
{0, &rtw_survey_event_callback}, /*8*/ {0, &rtw_survey_event_callback}, /*8*/
{sizeof (struct surveydone_event), &rtw_surveydone_event_callback}, /*9*/ {sizeof(struct surveydone_event), &rtw_surveydone_event_callback}, /*9*/
{0, &rtw_joinbss_event_callback}, /*10*/ {0, &rtw_joinbss_event_callback}, /*10*/
{sizeof(struct stassoc_event), &rtw_stassoc_event_callback}, {sizeof(struct stassoc_event), &rtw_stassoc_event_callback},
......
...@@ -154,7 +154,7 @@ typedef struct _MPT_CONTEXT ...@@ -154,7 +154,7 @@ typedef struct _MPT_CONTEXT
u32 mptOutLen; u32 mptOutLen;
u8 mptOutBuf[100]; u8 mptOutBuf[100];
}MPT_CONTEXT, *PMPT_CONTEXT; } MPT_CONTEXT, *PMPT_CONTEXT;
/* endif */ /* endif */
/* E-Fuse */ /* E-Fuse */
...@@ -276,7 +276,7 @@ typedef struct _IOCMD_STRUCT_ { ...@@ -276,7 +276,7 @@ typedef struct _IOCMD_STRUCT_ {
u8 cmdclass; u8 cmdclass;
u16 value; u16 value;
u8 index; u8 index;
}IOCMD_STRUCT; } IOCMD_STRUCT;
struct rf_reg_param { struct rf_reg_param {
u32 path; u32 path;
...@@ -315,7 +315,7 @@ extern u8 mpdatarate[NumRates]; ...@@ -315,7 +315,7 @@ extern u8 mpdatarate[NumRates];
/* MP set force data rate base on the definition. */ /* MP set force data rate base on the definition. */
enum MPT_RATE_INDEX { enum MPT_RATE_INDEX {
/* CCK rate. */ /* CCK rate. */
MPT_RATE_1M = 0 , /* 0 */ MPT_RATE_1M = 0, /* 0 */
MPT_RATE_2M, MPT_RATE_2M,
MPT_RATE_55M, MPT_RATE_55M,
MPT_RATE_11M, /* 3 */ MPT_RATE_11M, /* 3 */
...@@ -473,9 +473,9 @@ void Hal_SetBandwidth(struct adapter *padapter); ...@@ -473,9 +473,9 @@ void Hal_SetBandwidth(struct adapter *padapter);
void Hal_SetTxPower(struct adapter *padapter); void Hal_SetTxPower(struct adapter *padapter);
void Hal_SetCarrierSuppressionTx(struct adapter *padapter, u8 bStart); void Hal_SetCarrierSuppressionTx(struct adapter *padapter, u8 bStart);
void Hal_SetSingleToneTx (struct adapter *padapter , u8 bStart); void Hal_SetSingleToneTx(struct adapter *padapter, u8 bStart);
void Hal_SetSingleCarrierTx (struct adapter *padapter, u8 bStart); void Hal_SetSingleCarrierTx(struct adapter *padapter, u8 bStart);
void Hal_SetContinuousTx (struct adapter *padapter, u8 bStart); void Hal_SetContinuousTx(struct adapter *padapter, u8 bStart);
void Hal_SetBandwidth(struct adapter *padapter); void Hal_SetBandwidth(struct adapter *padapter);
void Hal_SetDataRate(struct adapter *padapter); void Hal_SetDataRate(struct adapter *padapter);
...@@ -494,8 +494,8 @@ void Hal_TriggerRFThermalMeter(struct adapter *padapter); ...@@ -494,8 +494,8 @@ void Hal_TriggerRFThermalMeter(struct adapter *padapter);
u8 Hal_ReadRFThermalMeter(struct adapter *padapter); u8 Hal_ReadRFThermalMeter(struct adapter *padapter);
void Hal_SetCCKContinuousTx(struct adapter *padapter, u8 bStart); void Hal_SetCCKContinuousTx(struct adapter *padapter, u8 bStart);
void Hal_SetOFDMContinuousTx(struct adapter *padapter, u8 bStart); void Hal_SetOFDMContinuousTx(struct adapter *padapter, u8 bStart);
void Hal_ProSetCrystalCap (struct adapter *padapter , u32 CrystalCapVal); void Hal_ProSetCrystalCap(struct adapter *padapter, u32 CrystalCapVal);
void MP_PHY_SetRFPathSwitch(struct adapter *padapter , bool bMain); void MP_PHY_SetRFPathSwitch(struct adapter *padapter, bool bMain);
u32 mpt_ProQueryCalTxPower(struct adapter *padapter, u8 RfPath); u32 mpt_ProQueryCalTxPower(struct adapter *padapter, u8 RfPath);
void MPT_PwrCtlDM(struct adapter *padapter, u32 bstart); void MPT_PwrCtlDM(struct adapter *padapter, u32 bstart);
u8 MptToMgntRate(u32 MptRateIdx); u8 MptToMgntRate(u32 MptRateIdx);
......
...@@ -187,7 +187,7 @@ struct rx_pkt_attrib { ...@@ -187,7 +187,7 @@ struct rx_pkt_attrib {
/* These definition is used for Rx packet reordering. */ /* These definition is used for Rx packet reordering. */
#define SN_LESS(a, b) (((a-b)&0x800)!= 0) #define SN_LESS(a, b) (((a - b) & 0x800) != 0)
#define SN_EQUAL(a, b) (a == b) #define SN_EQUAL(a, b) (a == b)
/* define REORDER_WIN_SIZE 128 */ /* define REORDER_WIN_SIZE 128 */
/* define REORDER_ENTRY_NUM 128 */ /* define REORDER_ENTRY_NUM 128 */
...@@ -369,12 +369,12 @@ struct recv_frame_hdr ...@@ -369,12 +369,12 @@ struct recv_frame_hdr
}; };
union recv_frame{ union recv_frame {
union{ union{
struct list_head list; struct list_head list;
struct recv_frame_hdr hdr; struct recv_frame_hdr hdr;
uint mem[RECVFRAME_HDR_ALIGN>>2]; uint mem[RECVFRAME_HDR_ALIGN>>2];
}u; } u;
/* uint mem[MAX_RXSZ>>2]; */ /* uint mem[MAX_RXSZ>>2]; */
...@@ -388,8 +388,8 @@ enum RX_PACKET_TYPE { ...@@ -388,8 +388,8 @@ enum RX_PACKET_TYPE {
C2H_PACKET C2H_PACKET
}; };
extern union recv_frame *_rtw_alloc_recvframe (struct __queue *pfree_recv_queue); /* get a free recv_frame from pfree_recv_queue */ extern union recv_frame *_rtw_alloc_recvframe(struct __queue *pfree_recv_queue); /* get a free recv_frame from pfree_recv_queue */
extern union recv_frame *rtw_alloc_recvframe (struct __queue *pfree_recv_queue); /* get a free recv_frame from pfree_recv_queue */ extern union recv_frame *rtw_alloc_recvframe(struct __queue *pfree_recv_queue); /* get a free recv_frame from pfree_recv_queue */
extern int rtw_free_recvframe(union recv_frame *precvframe, struct __queue *pfree_recv_queue); extern int rtw_free_recvframe(union recv_frame *precvframe, struct __queue *pfree_recv_queue);
#define rtw_dequeue_recvframe(queue) rtw_alloc_recvframe(queue) #define rtw_dequeue_recvframe(queue) rtw_alloc_recvframe(queue)
...@@ -401,7 +401,7 @@ u32 rtw_free_uc_swdec_pending_queue(struct adapter *adapter); ...@@ -401,7 +401,7 @@ u32 rtw_free_uc_swdec_pending_queue(struct adapter *adapter);
sint rtw_enqueue_recvbuf_to_head(struct recv_buf *precvbuf, struct __queue *queue); sint rtw_enqueue_recvbuf_to_head(struct recv_buf *precvbuf, struct __queue *queue);
sint rtw_enqueue_recvbuf(struct recv_buf *precvbuf, struct __queue *queue); sint rtw_enqueue_recvbuf(struct recv_buf *precvbuf, struct __queue *queue);
struct recv_buf *rtw_dequeue_recvbuf (struct __queue *queue); struct recv_buf *rtw_dequeue_recvbuf(struct __queue *queue);
void rtw_reordering_ctrl_timeout_handler(struct timer_list *t); void rtw_reordering_ctrl_timeout_handler(struct timer_list *t);
...@@ -444,7 +444,7 @@ static inline u8 *recvframe_pull(union recv_frame *precvframe, sint sz) ...@@ -444,7 +444,7 @@ static inline u8 *recvframe_pull(union recv_frame *precvframe, sint sz)
return NULL; return NULL;
} }
precvframe->u.hdr.len -=sz; precvframe->u.hdr.len -= sz;
return precvframe->u.hdr.rx_data; return precvframe->u.hdr.rx_data;
...@@ -471,7 +471,7 @@ static inline u8 *recvframe_put(union recv_frame *precvframe, sint sz) ...@@ -471,7 +471,7 @@ static inline u8 *recvframe_put(union recv_frame *precvframe, sint sz)
return NULL; return NULL;
} }
precvframe->u.hdr.len +=sz; precvframe->u.hdr.len += sz;
return precvframe->u.hdr.rx_tail; return precvframe->u.hdr.rx_tail;
...@@ -497,7 +497,7 @@ static inline u8 *recvframe_pull_tail(union recv_frame *precvframe, sint sz) ...@@ -497,7 +497,7 @@ static inline u8 *recvframe_pull_tail(union recv_frame *precvframe, sint sz)
return NULL; return NULL;
} }
precvframe->u.hdr.len -=sz; precvframe->u.hdr.len -= sz;
return precvframe->u.hdr.rx_tail; return precvframe->u.hdr.rx_tail;
......
...@@ -208,7 +208,7 @@ struct sha256_state { ...@@ -208,7 +208,7 @@ struct sha256_state {
}; };
#define GET_ENCRY_ALGO(psecuritypriv, psta, encry_algo, bmcst)\ #define GET_ENCRY_ALGO(psecuritypriv, psta, encry_algo, bmcst)\
do{\ do {\
switch (psecuritypriv->dot11AuthAlgrthm)\ switch (psecuritypriv->dot11AuthAlgrthm)\
{\ {\
case dot11AuthAlgrthm_Open:\ case dot11AuthAlgrthm_Open:\
...@@ -220,18 +220,18 @@ do{\ ...@@ -220,18 +220,18 @@ do{\
if (bmcst)\ if (bmcst)\
encry_algo = (u8)psecuritypriv->dot118021XGrpPrivacy;\ encry_algo = (u8)psecuritypriv->dot118021XGrpPrivacy;\
else\ else\
encry_algo =(u8) psta->dot118021XPrivacy;\ encry_algo = (u8)psta->dot118021XPrivacy;\
break;\ break;\
case dot11AuthAlgrthm_WAPI:\ case dot11AuthAlgrthm_WAPI:\
encry_algo = (u8)psecuritypriv->dot11PrivacyAlgrthm;\ encry_algo = (u8)psecuritypriv->dot11PrivacyAlgrthm;\
break;\ break;\
}\ } \
}while (0) } while (0)
#define _AES_IV_LEN_ 8 #define _AES_IV_LEN_ 8
#define SET_ICE_IV_LEN(iv_len, icv_len, encrypt)\ #define SET_ICE_IV_LEN(iv_len, icv_len, encrypt)\
do{\ do {\
switch (encrypt)\ switch (encrypt)\
{\ {\
case _WEP40_:\ case _WEP40_:\
...@@ -255,19 +255,19 @@ do{\ ...@@ -255,19 +255,19 @@ do{\
iv_len = 0;\ iv_len = 0;\
icv_len = 0;\ icv_len = 0;\
break;\ break;\
}\ } \
}while (0) } while (0)
#define GET_TKIP_PN(iv, dot11txpn)\ #define GET_TKIP_PN(iv, dot11txpn)\
do{\ do {\
dot11txpn._byte_.TSC0 =iv[2];\ dot11txpn._byte_.TSC0 = iv[2];\
dot11txpn._byte_.TSC1 =iv[0];\ dot11txpn._byte_.TSC1 = iv[0];\
dot11txpn._byte_.TSC2 =iv[4];\ dot11txpn._byte_.TSC2 = iv[4];\
dot11txpn._byte_.TSC3 =iv[5];\ dot11txpn._byte_.TSC3 = iv[5];\
dot11txpn._byte_.TSC4 =iv[6];\ dot11txpn._byte_.TSC4 = iv[6];\
dot11txpn._byte_.TSC5 =iv[7];\ dot11txpn._byte_.TSC5 = iv[7];\
}while (0) } while (0)
#define ROL32(A, n) (((A) << (n)) | (((A)>>(32-(n))) & ((1UL << (n)) - 1))) #define ROL32(A, n) (((A) << (n)) | (((A)>>(32-(n))) & ((1UL << (n)) - 1)))
......
...@@ -40,17 +40,17 @@ ...@@ -40,17 +40,17 @@
#define HW_QUEUE_ENTRY 8 #define HW_QUEUE_ENTRY 8
#define WEP_IV(pattrib_iv, dot11txpn, keyidx)\ #define WEP_IV(pattrib_iv, dot11txpn, keyidx)\
do{\ do {\
pattrib_iv[0] = dot11txpn._byte_.TSC0;\ pattrib_iv[0] = dot11txpn._byte_.TSC0;\
pattrib_iv[1] = dot11txpn._byte_.TSC1;\ pattrib_iv[1] = dot11txpn._byte_.TSC1;\
pattrib_iv[2] = dot11txpn._byte_.TSC2;\ pattrib_iv[2] = dot11txpn._byte_.TSC2;\
pattrib_iv[3] = ((keyidx & 0x3)<<6);\ pattrib_iv[3] = ((keyidx & 0x3)<<6);\
dot11txpn.val = (dot11txpn.val == 0xffffff) ? 0: (dot11txpn.val+1);\ dot11txpn.val = (dot11txpn.val == 0xffffff) ? 0 : (dot11txpn.val + 1);\
}while (0) } while (0)
#define TKIP_IV(pattrib_iv, dot11txpn, keyidx)\ #define TKIP_IV(pattrib_iv, dot11txpn, keyidx)\
do{\ do {\
pattrib_iv[0] = dot11txpn._byte_.TSC1;\ pattrib_iv[0] = dot11txpn._byte_.TSC1;\
pattrib_iv[1] = (dot11txpn._byte_.TSC1 | 0x20) & 0x7f;\ pattrib_iv[1] = (dot11txpn._byte_.TSC1 | 0x20) & 0x7f;\
pattrib_iv[2] = dot11txpn._byte_.TSC0;\ pattrib_iv[2] = dot11txpn._byte_.TSC0;\
...@@ -59,11 +59,11 @@ do{\ ...@@ -59,11 +59,11 @@ do{\
pattrib_iv[5] = dot11txpn._byte_.TSC3;\ pattrib_iv[5] = dot11txpn._byte_.TSC3;\
pattrib_iv[6] = dot11txpn._byte_.TSC4;\ pattrib_iv[6] = dot11txpn._byte_.TSC4;\
pattrib_iv[7] = dot11txpn._byte_.TSC5;\ pattrib_iv[7] = dot11txpn._byte_.TSC5;\
dot11txpn.val = dot11txpn.val == 0xffffffffffffULL ? 0: (dot11txpn.val+1);\ dot11txpn.val = dot11txpn.val == 0xffffffffffffULL ? 0 : (dot11txpn.val + 1);\
}while (0) } while (0)
#define AES_IV(pattrib_iv, dot11txpn, keyidx)\ #define AES_IV(pattrib_iv, dot11txpn, keyidx)\
do{\ do {\
pattrib_iv[0] = dot11txpn._byte_.TSC0;\ pattrib_iv[0] = dot11txpn._byte_.TSC0;\
pattrib_iv[1] = dot11txpn._byte_.TSC1;\ pattrib_iv[1] = dot11txpn._byte_.TSC1;\
pattrib_iv[2] = 0;\ pattrib_iv[2] = 0;\
...@@ -72,8 +72,8 @@ do{\ ...@@ -72,8 +72,8 @@ do{\
pattrib_iv[5] = dot11txpn._byte_.TSC3;\ pattrib_iv[5] = dot11txpn._byte_.TSC3;\
pattrib_iv[6] = dot11txpn._byte_.TSC4;\ pattrib_iv[6] = dot11txpn._byte_.TSC4;\
pattrib_iv[7] = dot11txpn._byte_.TSC5;\ pattrib_iv[7] = dot11txpn._byte_.TSC5;\
dot11txpn.val = dot11txpn.val == 0xffffffffffffULL ? 0: (dot11txpn.val+1);\ dot11txpn.val = dot11txpn.val == 0xffffffffffffULL ? 0 : (dot11txpn.val + 1);\
}while (0) } while (0)
#define HWXMIT_ENTRY 4 #define HWXMIT_ENTRY 4
...@@ -217,7 +217,7 @@ enum { ...@@ -217,7 +217,7 @@ enum {
XMITBUF_CMD = 2, XMITBUF_CMD = 2,
}; };
struct submit_ctx{ struct submit_ctx {
unsigned long submit_time; /* */ unsigned long submit_time; /* */
u32 timeout_ms; /* <0: not synchronous, 0: wait forever, >0: up to ms waiting */ u32 timeout_ms; /* <0: not synchronous, 0: wait forever, >0: up to ms waiting */
int status; /* status for operation */ int status; /* status for operation */
...@@ -274,7 +274,7 @@ struct xmit_buf ...@@ -274,7 +274,7 @@ struct xmit_buf
u8 pg_num; u8 pg_num;
u8 agg_num; u8 agg_num;
#if defined(DBG_XMIT_BUF)|| defined(DBG_XMIT_BUF_EXT) #if defined(DBG_XMIT_BUF) || defined(DBG_XMIT_BUF_EXT)
u8 no; u8 no;
#endif #endif
...@@ -350,7 +350,7 @@ struct hw_txqueue { ...@@ -350,7 +350,7 @@ struct hw_txqueue {
sint ac_tag; sint ac_tag;
}; };
struct agg_pkt_info{ struct agg_pkt_info {
u16 offset; u16 offset;
u16 pkt_len; u16 pkt_len;
}; };
...@@ -484,7 +484,7 @@ void rtw_init_hwxmits(struct hw_xmit *phwxmit, sint entry); ...@@ -484,7 +484,7 @@ void rtw_init_hwxmits(struct hw_xmit *phwxmit, sint entry);
s32 _rtw_init_xmit_priv(struct xmit_priv *pxmitpriv, struct adapter *padapter); s32 _rtw_init_xmit_priv(struct xmit_priv *pxmitpriv, struct adapter *padapter);
void _rtw_free_xmit_priv (struct xmit_priv *pxmitpriv); void _rtw_free_xmit_priv(struct xmit_priv *pxmitpriv);
s32 rtw_alloc_hwxmits(struct adapter *padapter); s32 rtw_alloc_hwxmits(struct adapter *padapter);
......
...@@ -31,13 +31,13 @@ struct wlan_acl_pool { ...@@ -31,13 +31,13 @@ struct wlan_acl_pool {
struct __queue acl_node_q; struct __queue acl_node_q;
}; };
typedef struct _RSSI_STA{ typedef struct _RSSI_STA {
s32 UndecoratedSmoothedPWDB; s32 UndecoratedSmoothedPWDB;
s32 UndecoratedSmoothedCCK; s32 UndecoratedSmoothedCCK;
s32 UndecoratedSmoothedOFDM; s32 UndecoratedSmoothedOFDM;
u64 PacketMap; u64 PacketMap;
u8 ValidBit; u8 ValidBit;
}RSSI_STA, *PRSSI_STA; } RSSI_STA, *PRSSI_STA;
struct stainfo_stats { struct stainfo_stats {
...@@ -304,7 +304,7 @@ struct sta_info { ...@@ -304,7 +304,7 @@ struct sta_info {
#define STA_RX_PKTS_DIFF_ARG(sta) \ #define STA_RX_PKTS_DIFF_ARG(sta) \
sta->sta_stats.rx_mgnt_pkts - sta->sta_stats.last_rx_mgnt_pkts \ sta->sta_stats.rx_mgnt_pkts - sta->sta_stats.last_rx_mgnt_pkts \
, sta->sta_stats.rx_ctrl_pkts - sta->sta_stats.last_rx_ctrl_pkts \ , sta->sta_stats.rx_ctrl_pkts - sta->sta_stats.last_rx_ctrl_pkts \
, sta->sta_stats.rx_data_pkts -sta->sta_stats.last_rx_data_pkts , sta->sta_stats.rx_data_pkts - sta->sta_stats.last_rx_data_pkts
#define STA_PKTS_FMT "(m:%llu, c:%llu, d:%llu)" #define STA_PKTS_FMT "(m:%llu, c:%llu, d:%llu)"
...@@ -374,7 +374,7 @@ int rtw_stainfo_offset(struct sta_priv *stapriv, struct sta_info *sta); ...@@ -374,7 +374,7 @@ int rtw_stainfo_offset(struct sta_priv *stapriv, struct sta_info *sta);
struct sta_info *rtw_get_stainfo_by_offset(struct sta_priv *stapriv, int offset); struct sta_info *rtw_get_stainfo_by_offset(struct sta_priv *stapriv, int offset);
extern struct sta_info *rtw_alloc_stainfo(struct sta_priv *pstapriv, u8 *hwaddr); extern struct sta_info *rtw_alloc_stainfo(struct sta_priv *pstapriv, u8 *hwaddr);
extern u32 rtw_free_stainfo(struct adapter *padapter , struct sta_info *psta); extern u32 rtw_free_stainfo(struct adapter *padapter, struct sta_info *psta);
extern void rtw_free_all_stainfo(struct adapter *padapter); extern void rtw_free_all_stainfo(struct adapter *padapter);
extern struct sta_info *rtw_get_stainfo(struct sta_priv *pstapriv, u8 *hwaddr); extern struct sta_info *rtw_get_stainfo(struct sta_priv *pstapriv, u8 *hwaddr);
extern u32 rtw_init_bcmc_stainfo(struct adapter *padapter); extern u32 rtw_init_bcmc_stainfo(struct adapter *padapter);
......
...@@ -707,7 +707,7 @@ struct HT_caps_element ...@@ -707,7 +707,7 @@ struct HT_caps_element
unsigned char ASEL_caps; unsigned char ASEL_caps;
} HT_cap_element; } HT_cap_element;
unsigned char HT_cap[26]; unsigned char HT_cap[26];
}u; } u;
} __attribute__ ((packed)); } __attribute__ ((packed));
struct HT_info_element struct HT_info_element
...@@ -1102,7 +1102,7 @@ enum P2P_PROTO_WK_ID ...@@ -1102,7 +1102,7 @@ enum P2P_PROTO_WK_ID
P2P_PRE_TX_PROVDISC_PROCESS_WK = 2, P2P_PRE_TX_PROVDISC_PROCESS_WK = 2,
P2P_PRE_TX_NEGOREQ_PROCESS_WK = 3, P2P_PRE_TX_NEGOREQ_PROCESS_WK = 3,
P2P_PRE_TX_INVITEREQ_PROCESS_WK = 4, P2P_PRE_TX_INVITEREQ_PROCESS_WK = 4,
P2P_AP_P2P_CH_SWITCH_PROCESS_WK =5, P2P_AP_P2P_CH_SWITCH_PROCESS_WK = 5,
P2P_RO_CH_WK = 6, P2P_RO_CH_WK = 6,
}; };
...@@ -1126,8 +1126,8 @@ enum P2P_PROTO_WK_ID ...@@ -1126,8 +1126,8 @@ enum P2P_PROTO_WK_ID
#define WFD_DEVINFO_PC_TDLS 0x0080 #define WFD_DEVINFO_PC_TDLS 0x0080
#define WFD_DEVINFO_HDCP_SUPPORT 0x0100 #define WFD_DEVINFO_HDCP_SUPPORT 0x0100
#define IP_MCAST_MAC(mac) ((mac[0]== 0x01) && (mac[1]== 0x00) && (mac[2]== 0x5e)) #define IP_MCAST_MAC(mac) ((mac[0] == 0x01) && (mac[1] == 0x00) && (mac[2] == 0x5e))
#define ICMPV6_MCAST_MAC(mac) ((mac[0]== 0x33) && (mac[1]== 0x33) && (mac[2]!= 0xff)) #define ICMPV6_MCAST_MAC(mac) ((mac[0] == 0x33) && (mac[1] == 0x33) && (mac[2] != 0xff))
/* Regulatroy Domain */ /* Regulatroy Domain */
struct regd_pair_mapping { struct regd_pair_mapping {
......
...@@ -35,8 +35,8 @@ void rtw_os_xmit_resource_free(struct adapter *padapter, struct xmit_buf *pxmitb ...@@ -35,8 +35,8 @@ void rtw_os_xmit_resource_free(struct adapter *padapter, struct xmit_buf *pxmitb
extern uint rtw_remainder_len(struct pkt_file *pfile); extern uint rtw_remainder_len(struct pkt_file *pfile);
extern void _rtw_open_pktfile(_pkt *pkt, struct pkt_file *pfile); extern void _rtw_open_pktfile(_pkt *pkt, struct pkt_file *pfile);
extern uint _rtw_pktfile_read (struct pkt_file *pfile, u8 *rmem, uint rlen); extern uint _rtw_pktfile_read(struct pkt_file *pfile, u8 *rmem, uint rlen);
extern sint rtw_endofpktfile (struct pkt_file *pfile); extern sint rtw_endofpktfile(struct pkt_file *pfile);
extern void rtw_os_pkt_complete(struct adapter *padapter, _pkt *pkt); extern void rtw_os_pkt_complete(struct adapter *padapter, _pkt *pkt);
extern void rtw_os_xmit_complete(struct adapter *padapter, struct xmit_frame *pxframe); extern void rtw_os_xmit_complete(struct adapter *padapter, struct xmit_frame *pxframe);
......
...@@ -64,7 +64,7 @@ void rtw_os_indicate_scan_done(struct adapter *padapter, bool aborted) ...@@ -64,7 +64,7 @@ void rtw_os_indicate_scan_done(struct adapter *padapter, bool aborted)
indicate_wx_scan_complete_event(padapter); indicate_wx_scan_complete_event(padapter);
} }
static RT_PMKID_LIST backupPMKIDList[ NUM_PMKID_CACHE ]; static RT_PMKID_LIST backupPMKIDList[NUM_PMKID_CACHE];
void rtw_reset_securitypriv(struct adapter *adapter) void rtw_reset_securitypriv(struct adapter *adapter)
{ {
u8 backupPMKIDIndex = 0; u8 backupPMKIDIndex = 0;
...@@ -83,7 +83,7 @@ void rtw_reset_securitypriv(struct adapter *adapter) ...@@ -83,7 +83,7 @@ void rtw_reset_securitypriv(struct adapter *adapter)
/* Backup the btkip_countermeasure information. */ /* Backup the btkip_countermeasure information. */
/* When the countermeasure is trigger, the driver have to disconnect with AP for 60 seconds. */ /* When the countermeasure is trigger, the driver have to disconnect with AP for 60 seconds. */
memcpy(&backupPMKIDList[ 0 ], &adapter->securitypriv.PMKIDList[ 0 ], sizeof(RT_PMKID_LIST) * NUM_PMKID_CACHE); memcpy(&backupPMKIDList[0], &adapter->securitypriv.PMKIDList[0], sizeof(RT_PMKID_LIST) * NUM_PMKID_CACHE);
backupPMKIDIndex = adapter->securitypriv.PMKIDIndex; backupPMKIDIndex = adapter->securitypriv.PMKIDIndex;
backupTKIPCountermeasure = adapter->securitypriv.btkip_countermeasure; backupTKIPCountermeasure = adapter->securitypriv.btkip_countermeasure;
backupTKIPcountermeasure_time = adapter->securitypriv.btkip_countermeasure_time; backupTKIPcountermeasure_time = adapter->securitypriv.btkip_countermeasure_time;
...@@ -95,7 +95,7 @@ void rtw_reset_securitypriv(struct adapter *adapter) ...@@ -95,7 +95,7 @@ void rtw_reset_securitypriv(struct adapter *adapter)
/* Added by Albert 2009/02/18 */ /* Added by Albert 2009/02/18 */
/* Restore the PMK information to securitypriv structure for the following connection. */ /* Restore the PMK information to securitypriv structure for the following connection. */
memcpy(&adapter->securitypriv.PMKIDList[ 0 ], &backupPMKIDList[ 0 ], sizeof(RT_PMKID_LIST) * NUM_PMKID_CACHE); memcpy(&adapter->securitypriv.PMKIDList[0], &backupPMKIDList[0], sizeof(RT_PMKID_LIST) * NUM_PMKID_CACHE);
adapter->securitypriv.PMKIDIndex = backupPMKIDIndex; adapter->securitypriv.PMKIDIndex = backupPMKIDIndex;
adapter->securitypriv.btkip_countermeasure = backupTKIPCountermeasure; adapter->securitypriv.btkip_countermeasure = backupTKIPCountermeasure;
adapter->securitypriv.btkip_countermeasure_time = backupTKIPcountermeasure_time; adapter->securitypriv.btkip_countermeasure_time = backupTKIPcountermeasure_time;
......
...@@ -202,8 +202,8 @@ module_param(rtw_tx_pwr_by_rate, int, 0644); ...@@ -202,8 +202,8 @@ module_param(rtw_tx_pwr_by_rate, int, 0644);
MODULE_PARM_DESC(rtw_tx_pwr_by_rate, "0:Disable, 1:Enable, 2: Depend on efuse"); MODULE_PARM_DESC(rtw_tx_pwr_by_rate, "0:Disable, 1:Enable, 2: Depend on efuse");
int _netdev_open(struct net_device *pnetdev); int _netdev_open(struct net_device *pnetdev);
int netdev_open (struct net_device *pnetdev); int netdev_open(struct net_device *pnetdev);
static int netdev_close (struct net_device *pnetdev); static int netdev_close(struct net_device *pnetdev);
static void loadparam(struct adapter *padapter, _nic_hdl pnetdev) static void loadparam(struct adapter *padapter, _nic_hdl pnetdev)
{ {
...@@ -221,7 +221,7 @@ static void loadparam(struct adapter *padapter, _nic_hdl pnetdev) ...@@ -221,7 +221,7 @@ static void loadparam(struct adapter *padapter, _nic_hdl pnetdev)
registry_par->channel = (u8)rtw_channel; registry_par->channel = (u8)rtw_channel;
registry_par->wireless_mode = (u8)rtw_wireless_mode; registry_par->wireless_mode = (u8)rtw_wireless_mode;
registry_par->vrtl_carrier_sense = (u8)rtw_vrtl_carrier_sense ; registry_par->vrtl_carrier_sense = (u8)rtw_vrtl_carrier_sense;
registry_par->vcs_type = (u8)rtw_vcs_type; registry_par->vcs_type = (u8)rtw_vcs_type;
registry_par->rts_thresh = (u16)rtw_rts_thresh; registry_par->rts_thresh = (u16)rtw_rts_thresh;
registry_par->frag_thresh = (u16)rtw_frag_thresh; registry_par->frag_thresh = (u16)rtw_frag_thresh;
...@@ -554,7 +554,7 @@ u32 rtw_start_drv_threads(struct adapter *padapter) ...@@ -554,7 +554,7 @@ u32 rtw_start_drv_threads(struct adapter *padapter)
return _status; return _status;
} }
void rtw_stop_drv_threads (struct adapter *padapter) void rtw_stop_drv_threads(struct adapter *padapter)
{ {
RT_TRACE(_module_os_intfs_c_, _drv_info_, ("+rtw_stop_drv_threads\n")); RT_TRACE(_module_os_intfs_c_, _drv_info_, ("+rtw_stop_drv_threads\n"));
...@@ -1154,7 +1154,7 @@ void rtw_dev_unload(struct adapter *padapter) ...@@ -1154,7 +1154,7 @@ void rtw_dev_unload(struct adapter *padapter)
DBG_871X("stop cmdthd timeout\n"); DBG_871X("stop cmdthd timeout\n");
break; break;
} else { } else {
cnt ++; cnt++;
DBG_871X("cmdthd is running(%d)\n", cnt); DBG_871X("cmdthd is running(%d)\n", cnt);
msleep(10); msleep(10);
} }
...@@ -1799,7 +1799,7 @@ int rtw_resume_common(struct adapter *padapter) ...@@ -1799,7 +1799,7 @@ int rtw_resume_common(struct adapter *padapter)
pwrpriv->pno_in_resume = false; pwrpriv->pno_in_resume = false;
#endif #endif
} }
DBG_871X_LEVEL(_drv_always_, "%s:%d in %d ms\n", __func__ , ret, DBG_871X_LEVEL(_drv_always_, "%s:%d in %d ms\n", __func__, ret,
jiffies_to_msecs(jiffies - start_time)); jiffies_to_msecs(jiffies - start_time));
return ret; return ret;
......
...@@ -197,7 +197,7 @@ void rtw_handle_tkip_mic_err(struct adapter *padapter, u8 bgroup) ...@@ -197,7 +197,7 @@ void rtw_handle_tkip_mic_err(struct adapter *padapter, u8 bgroup)
key_type |= NL80211_KEYTYPE_PAIRWISE; key_type |= NL80211_KEYTYPE_PAIRWISE;
} }
cfg80211_michael_mic_failure(padapter->pnetdev, (u8 *)&pmlmepriv->assoc_bssid[ 0 ], key_type, -1, cfg80211_michael_mic_failure(padapter->pnetdev, (u8 *)&pmlmepriv->assoc_bssid[0], key_type, -1,
NULL, GFP_ATOMIC); NULL, GFP_ATOMIC);
memset(&ev, 0x00, sizeof(ev)); memset(&ev, 0x00, sizeof(ev));
...@@ -208,7 +208,7 @@ void rtw_handle_tkip_mic_err(struct adapter *padapter, u8 bgroup) ...@@ -208,7 +208,7 @@ void rtw_handle_tkip_mic_err(struct adapter *padapter, u8 bgroup)
} }
ev.src_addr.sa_family = ARPHRD_ETHER; ev.src_addr.sa_family = ARPHRD_ETHER;
memcpy(ev.src_addr.sa_data, &pmlmepriv->assoc_bssid[ 0 ], ETH_ALEN); memcpy(ev.src_addr.sa_data, &pmlmepriv->assoc_bssid[0], ETH_ALEN);
memset(&wrqu, 0x00, sizeof(wrqu)); memset(&wrqu, 0x00, sizeof(wrqu));
wrqu.data.length = sizeof(ev); wrqu.data.length = sizeof(ev);
...@@ -223,7 +223,7 @@ static void rtw_os_ksocket_send(struct adapter *padapter, union recv_frame *prec ...@@ -223,7 +223,7 @@ static void rtw_os_ksocket_send(struct adapter *padapter, union recv_frame *prec
DBG_871X("eth rx: got eth_type = 0x%x\n", pattrib->eth_type); DBG_871X("eth rx: got eth_type = 0x%x\n", pattrib->eth_type);
if (psta && psta->isrc && psta->pid>0) { if (psta && psta->isrc && psta->pid > 0) {
u16 rx_pid; u16 rx_pid;
rx_pid = *(u16*)(skb->data+ETH_HLEN); rx_pid = *(u16*)(skb->data+ETH_HLEN);
...@@ -239,7 +239,7 @@ static void rtw_os_ksocket_send(struct adapter *padapter, union recv_frame *prec ...@@ -239,7 +239,7 @@ static void rtw_os_ksocket_send(struct adapter *padapter, union recv_frame *prec
/* DBG_871X("eth, RC: len = 0x%x, ctrl_type = 0x%x\n", len, ctrl_type); */ /* DBG_871X("eth, RC: len = 0x%x, ctrl_type = 0x%x\n", len, ctrl_type); */
DBG_871X("eth, RC: len = 0x%x\n", len); DBG_871X("eth, RC: len = 0x%x\n", len);
for (i = 0;i<len;i++) for (i = 0; i < len; i++)
DBG_871X("0x%x\n", *(skb->data+ETH_HLEN+4+i)); DBG_871X("0x%x\n", *(skb->data+ETH_HLEN+4+i));
/* DBG_871X("0x%x\n", *(skb->data+ETH_HLEN+6+i)); */ /* DBG_871X("0x%x\n", *(skb->data+ETH_HLEN+6+i)); */
......
...@@ -108,7 +108,7 @@ static void sdio_free_irq(struct dvobj_priv *dvobj) ...@@ -108,7 +108,7 @@ static void sdio_free_irq(struct dvobj_priv *dvobj)
err = sdio_release_irq(func); err = sdio_release_irq(func);
if (err) { if (err) {
dvobj->drv_dbg.dbg_sdio_free_irq_error_cnt++; dvobj->drv_dbg.dbg_sdio_free_irq_error_cnt++;
DBG_871X_LEVEL(_drv_err_,"%s: sdio_release_irq FAIL(%d)!\n", __func__, err); DBG_871X_LEVEL(_drv_err_, "%s: sdio_release_irq FAIL(%d)!\n", __func__, err);
} else } else
dvobj->drv_dbg.dbg_sdio_free_irq_cnt++; dvobj->drv_dbg.dbg_sdio_free_irq_cnt++;
sdio_release_host(func); sdio_release_host(func);
...@@ -324,7 +324,7 @@ static struct adapter *rtw_sdio_if1_init(struct dvobj_priv *dvobj, const struct ...@@ -324,7 +324,7 @@ static struct adapter *rtw_sdio_if1_init(struct dvobj_priv *dvobj, const struct
padapter->dvobj = dvobj; padapter->dvobj = dvobj;
dvobj->if1 = padapter; dvobj->if1 = padapter;
padapter->bDriverStopped =true; padapter->bDriverStopped = true;
dvobj->padapters = padapter; dvobj->padapters = padapter;
padapter->iface_id = 0; padapter->iface_id = 0;
...@@ -430,7 +430,7 @@ static void rtw_sdio_if1_deinit(struct adapter *if1) ...@@ -430,7 +430,7 @@ static void rtw_sdio_if1_deinit(struct adapter *if1)
rtw_cancel_all_timer(if1); rtw_cancel_all_timer(if1);
#ifdef CONFIG_WOWLAN #ifdef CONFIG_WOWLAN
adapter_to_pwrctl(if1)->wowlan_mode =false; adapter_to_pwrctl(if1)->wowlan_mode = false;
DBG_871X_LEVEL(_drv_always_, "%s wowlan_mode:%d\n", __func__, adapter_to_pwrctl(if1)->wowlan_mode); DBG_871X_LEVEL(_drv_always_, "%s wowlan_mode:%d\n", __func__, adapter_to_pwrctl(if1)->wowlan_mode);
#endif /* CONFIG_WOWLAN */ #endif /* CONFIG_WOWLAN */
...@@ -500,7 +500,7 @@ static int rtw_drv_init( ...@@ -500,7 +500,7 @@ static int rtw_drv_init(
if (status != _SUCCESS) if (status != _SUCCESS)
sdio_dvobj_deinit(func); sdio_dvobj_deinit(func);
exit: exit:
return status == _SUCCESS?0:-ENODEV; return status == _SUCCESS ? 0 : -ENODEV;
} }
static void rtw_dev_remove(struct sdio_func *func) static void rtw_dev_remove(struct sdio_func *func)
...@@ -548,7 +548,7 @@ extern int pm_netdev_close(struct net_device *pnetdev, u8 bnormal); ...@@ -548,7 +548,7 @@ extern int pm_netdev_close(struct net_device *pnetdev, u8 bnormal);
static int rtw_sdio_suspend(struct device *dev) static int rtw_sdio_suspend(struct device *dev)
{ {
struct sdio_func *func =dev_to_sdio_func(dev); struct sdio_func *func = dev_to_sdio_func(dev);
struct dvobj_priv *psdpriv = sdio_get_drvdata(func); struct dvobj_priv *psdpriv = sdio_get_drvdata(func);
struct pwrctrl_priv *pwrpriv = dvobj_to_pwrctl(psdpriv); struct pwrctrl_priv *pwrpriv = dvobj_to_pwrctl(psdpriv);
struct adapter *padapter = psdpriv->if1; struct adapter *padapter = psdpriv->if1;
...@@ -585,7 +585,7 @@ static int rtw_resume_process(struct adapter *padapter) ...@@ -585,7 +585,7 @@ static int rtw_resume_process(struct adapter *padapter)
static int rtw_sdio_resume(struct device *dev) static int rtw_sdio_resume(struct device *dev)
{ {
struct sdio_func *func =dev_to_sdio_func(dev); struct sdio_func *func = dev_to_sdio_func(dev);
struct dvobj_priv *psdpriv = sdio_get_drvdata(func); struct dvobj_priv *psdpriv = sdio_get_drvdata(func);
struct adapter *padapter = psdpriv->if1; struct adapter *padapter = psdpriv->if1;
struct mlme_ext_priv *pmlmeext = &padapter->mlmeextpriv; struct mlme_ext_priv *pmlmeext = &padapter->mlmeextpriv;
......
...@@ -15,16 +15,16 @@ uint rtw_remainder_len(struct pkt_file *pfile) ...@@ -15,16 +15,16 @@ uint rtw_remainder_len(struct pkt_file *pfile)
return (pfile->buf_len - ((SIZE_PTR)(pfile->cur_addr) - (SIZE_PTR)(pfile->buf_start))); return (pfile->buf_len - ((SIZE_PTR)(pfile->cur_addr) - (SIZE_PTR)(pfile->buf_start)));
} }
void _rtw_open_pktfile (_pkt *pktptr, struct pkt_file *pfile) void _rtw_open_pktfile(_pkt *pktptr, struct pkt_file *pfile)
{ {
pfile->pkt = pktptr; pfile->pkt = pktptr;
pfile->cur_addr = pfile->buf_start = pktptr->data; pfile->cur_addr = pfile->buf_start = pktptr->data;
pfile->pkt_len = pfile->buf_len = pktptr->len; pfile->pkt_len = pfile->buf_len = pktptr->len;
pfile->cur_buffer = pfile->buf_start ; pfile->cur_buffer = pfile->buf_start;
} }
uint _rtw_pktfile_read (struct pkt_file *pfile, u8 *rmem, uint rlen) uint _rtw_pktfile_read(struct pkt_file *pfile, u8 *rmem, uint rlen)
{ {
uint len = 0; uint len = 0;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment