staging: rtl8192e: Cleanup checkpatch -f warnings and errors - Part VIII
Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
This commit is contained in:
committed by
Greg Kroah-Hartman
parent
b6da7313e0
commit
1344ee2591
File diff suppressed because it is too large
Load Diff
@@ -45,7 +45,7 @@
|
||||
#include <linux/if_arp.h>
|
||||
#include <linux/random.h>
|
||||
#include <linux/version.h>
|
||||
#include <asm/io.h>
|
||||
#include <linux/io.h>
|
||||
#include "rtllib.h"
|
||||
|
||||
#include "dot11d.h"
|
||||
@@ -62,28 +62,35 @@
|
||||
#include "rtl_pci.h"
|
||||
#include "rtl_cam.h"
|
||||
|
||||
#define DRV_COPYRIGHT "Copyright(c) 2008 - 2010 Realsil Semiconductor Corporation"
|
||||
#define DRV_COPYRIGHT \
|
||||
"Copyright(c) 2008 - 2010 Realsil Semiconductor Corporation"
|
||||
#define DRV_AUTHOR "<wlanfae@realtek.com>"
|
||||
#define DRV_VERSION "0014.0401.2010"
|
||||
|
||||
#define DRV_NAME "rtl819xE"
|
||||
|
||||
#define IS_HARDWARE_TYPE_819xP(_priv) ((((struct r8192_priv *)rtllib_priv(dev))->card_8192==NIC_8190P)||\
|
||||
(((struct r8192_priv *)rtllib_priv(dev))->card_8192==NIC_8192E))
|
||||
#define IS_HARDWARE_TYPE_8192SE(_priv) (((struct r8192_priv *)rtllib_priv(dev))->card_8192==NIC_8192SE)
|
||||
#define IS_HARDWARE_TYPE_8192CE(_priv) (((struct r8192_priv *)rtllib_priv(dev))->card_8192==NIC_8192CE)
|
||||
#define IS_HARDWARE_TYPE_8192CU(_priv) (((struct r8192_priv *)rtllib_priv(dev))->card_8192==NIC_8192CU)
|
||||
#define IS_HARDWARE_TYPE_8192DE(_priv) (((struct r8192_priv *)rtllib_priv(dev))->card_8192==NIC_8192DE)
|
||||
#define IS_HARDWARE_TYPE_8192DU(_priv) (((struct r8192_priv *)rtllib_priv(dev))->card_8192==NIC_8192DU)
|
||||
#define IS_HARDWARE_TYPE_819xP(_priv) \
|
||||
((((struct r8192_priv *)rtllib_priv(dev))->card_8192 == NIC_8190P) || \
|
||||
(((struct r8192_priv *)rtllib_priv(dev))->card_8192 == NIC_8192E))
|
||||
#define IS_HARDWARE_TYPE_8192SE(_priv) \
|
||||
(((struct r8192_priv *)rtllib_priv(dev))->card_8192 == NIC_8192SE)
|
||||
#define IS_HARDWARE_TYPE_8192CE(_priv) \
|
||||
(((struct r8192_priv *)rtllib_priv(dev))->card_8192 == NIC_8192CE)
|
||||
#define IS_HARDWARE_TYPE_8192CU(_priv) \
|
||||
(((struct r8192_priv *)rtllib_priv(dev))->card_8192 == NIC_8192CU)
|
||||
#define IS_HARDWARE_TYPE_8192DE(_priv) \
|
||||
(((struct r8192_priv *)rtllib_priv(dev))->card_8192 == NIC_8192DE)
|
||||
#define IS_HARDWARE_TYPE_8192DU(_priv) \
|
||||
(((struct r8192_priv *)rtllib_priv(dev))->card_8192 == NIC_8192DU)
|
||||
|
||||
#define RTL_PCI_DEVICE(vend, dev, cfg) \
|
||||
.vendor = (vend), .device = (dev), \
|
||||
.subvendor = PCI_ANY_ID, .subdevice =PCI_ANY_ID , \
|
||||
.subvendor = PCI_ANY_ID, .subdevice = PCI_ANY_ID , \
|
||||
.driver_data = (kernel_ulong_t)&(cfg)
|
||||
|
||||
#define irqreturn_type irqreturn_t
|
||||
|
||||
#define rtl8192_interrupt(x,y,z) rtl8192_interrupt_rsl(x,y)
|
||||
#define rtl8192_interrupt(x, y, z) rtl8192_interrupt_rsl(x, y)
|
||||
|
||||
#define RTL_MAX_SCAN_SIZE 128
|
||||
|
||||
@@ -100,7 +107,8 @@
|
||||
|
||||
#define IS_ADAPTER_SENDS_BEACON(dev) 0
|
||||
|
||||
#define IS_UNDER_11N_AES_MODE(_rtllib) ((_rtllib->pHTInfo->bCurrentHTSupport == true) &&\
|
||||
#define IS_UNDER_11N_AES_MODE(_rtllib) \
|
||||
((_rtllib->pHTInfo->bCurrentHTSupport == true) && \
|
||||
(_rtllib->pairwise_key_type == KEY_TYPE_CCMP))
|
||||
|
||||
#define HAL_MEMORY_MAPPED_IO_RANGE_8190PCI 0x1000
|
||||
@@ -144,12 +152,14 @@
|
||||
|
||||
#define RTLLIB_WATCH_DOG_TIME 2000
|
||||
|
||||
#define MAX_DEV_ADDR_SIZE 8 /* support till 64 bit bus width OS */
|
||||
#define MAX_DEV_ADDR_SIZE 8 /*support till 64 bit bus width OS*/
|
||||
#define MAX_FIRMWARE_INFORMATION_SIZE 32
|
||||
#define MAX_802_11_HEADER_LENGTH (40 + MAX_FIRMWARE_INFORMATION_SIZE)
|
||||
#define ENCRYPTION_MAX_OVERHEAD 128
|
||||
#define MAX_FRAGMENT_COUNT 8
|
||||
#define MAX_TRANSMIT_BUFFER_SIZE (1600+(MAX_802_11_HEADER_LENGTH+ENCRYPTION_MAX_OVERHEAD)*MAX_FRAGMENT_COUNT)
|
||||
#define MAX_TRANSMIT_BUFFER_SIZE \
|
||||
(1600 + (MAX_802_11_HEADER_LENGTH + ENCRYPTION_MAX_OVERHEAD) * \
|
||||
MAX_FRAGMENT_COUNT)
|
||||
|
||||
#define scrclng 4
|
||||
|
||||
@@ -164,7 +174,7 @@
|
||||
|
||||
#define PHY_RSSI_SLID_WIN_MAX 100
|
||||
|
||||
#define RTL_IOCTL_WPA_SUPPLICANT SIOCIWFIRSTPRIV+30
|
||||
#define RTL_IOCTL_WPA_SUPPLICANT (SIOCIWFIRSTPRIV + 30)
|
||||
|
||||
#define TxBBGainTableLength 37
|
||||
#define CCKTxBBGainTableLength 23
|
||||
@@ -185,8 +195,8 @@
|
||||
enum RTL819x_PHY_PARAM {
|
||||
RTL819X_PHY_MACPHY_REG = 0,
|
||||
RTL819X_PHY_MACPHY_REG_PG = 1,
|
||||
RTL8188C_PHY_MACREG =2,
|
||||
RTL8192C_PHY_MACREG =3,
|
||||
RTL8188C_PHY_MACREG = 2,
|
||||
RTL8192C_PHY_MACREG = 3,
|
||||
RTL819X_PHY_REG = 4,
|
||||
RTL819X_PHY_REG_1T2R = 5,
|
||||
RTL819X_PHY_REG_to1T1R = 6,
|
||||
@@ -194,15 +204,15 @@ enum RTL819x_PHY_PARAM {
|
||||
RTL819X_PHY_REG_to2T2R = 8,
|
||||
RTL819X_PHY_REG_PG = 9,
|
||||
RTL819X_AGC_TAB = 10,
|
||||
RTL819X_PHY_RADIO_A =11,
|
||||
RTL819X_PHY_RADIO_A_1T =12,
|
||||
RTL819X_PHY_RADIO_A_2T =13,
|
||||
RTL819X_PHY_RADIO_B =14,
|
||||
RTL819X_PHY_RADIO_B_GM =15,
|
||||
RTL819X_PHY_RADIO_C =16,
|
||||
RTL819X_PHY_RADIO_D =17,
|
||||
RTL819X_EEPROM_MAP =18,
|
||||
RTL819X_EFUSE_MAP =19,
|
||||
RTL819X_PHY_RADIO_A = 11,
|
||||
RTL819X_PHY_RADIO_A_1T = 12,
|
||||
RTL819X_PHY_RADIO_A_2T = 13,
|
||||
RTL819X_PHY_RADIO_B = 14,
|
||||
RTL819X_PHY_RADIO_B_GM = 15,
|
||||
RTL819X_PHY_RADIO_C = 16,
|
||||
RTL819X_PHY_RADIO_D = 17,
|
||||
RTL819X_EEPROM_MAP = 18,
|
||||
RTL819X_EFUSE_MAP = 19,
|
||||
};
|
||||
|
||||
enum RTL_DEBUG {
|
||||
@@ -249,7 +259,7 @@ enum nic_t {
|
||||
NIC_8192CU = 6,
|
||||
NIC_8192DE = 7,
|
||||
NIC_8192DU = 8,
|
||||
};
|
||||
};
|
||||
|
||||
enum rt_eeprom_type {
|
||||
EEPROM_93C46,
|
||||
@@ -272,7 +282,7 @@ enum rt_rf_type_819xu {
|
||||
RF_8225,
|
||||
RF_8256,
|
||||
RF_8258,
|
||||
RF_6052=4,
|
||||
RF_6052 = 4,
|
||||
RF_PSEUDO_11N = 5,
|
||||
};
|
||||
|
||||
@@ -315,7 +325,7 @@ enum rt_customer_id {
|
||||
RT_CID_819x_CAMEO1 = 22,
|
||||
RT_CID_819x_MSI = 23,
|
||||
RT_CID_819x_Acer = 24,
|
||||
RT_CID_819x_HP =27,
|
||||
RT_CID_819x_HP = 27,
|
||||
RT_CID_819x_CLEVO = 28,
|
||||
RT_CID_819x_Arcadyan_Belkin = 29,
|
||||
RT_CID_819x_SAMSUNG = 30,
|
||||
@@ -505,9 +515,9 @@ struct init_gain {
|
||||
};
|
||||
|
||||
struct tx_ring {
|
||||
u32 * desc;
|
||||
u32 *desc;
|
||||
u8 nStuckCount;
|
||||
struct tx_ring * next;
|
||||
struct tx_ring *next;
|
||||
} __packed;
|
||||
|
||||
struct rtl8192_tx_ring {
|
||||
@@ -520,27 +530,39 @@ struct rtl8192_tx_ring {
|
||||
|
||||
|
||||
|
||||
struct rtl819x_ops{
|
||||
struct rtl819x_ops {
|
||||
enum nic_t nic_type;
|
||||
void (* get_eeprom_size)(struct net_device* dev);
|
||||
void (* init_adapter_variable)(struct net_device* dev);
|
||||
void (* init_before_adapter_start)(struct net_device* dev);
|
||||
bool (* initialize_adapter)(struct net_device* dev);
|
||||
void (*link_change)(struct net_device* dev);
|
||||
void (* tx_fill_descriptor)(struct net_device* dev, struct tx_desc *tx_desc, struct cb_desc *cb_desc, struct sk_buff *skb);
|
||||
void (* tx_fill_cmd_descriptor)(struct net_device* dev, struct tx_desc_cmd * entry, struct cb_desc *cb_desc, struct sk_buff *skb);
|
||||
bool (* rx_query_status_descriptor)(struct net_device* dev, struct rtllib_rx_stats* stats, struct rx_desc *pdesc, struct sk_buff* skb);
|
||||
bool (* rx_command_packet_handler)(struct net_device *dev, struct sk_buff* skb, struct rx_desc *pdesc);
|
||||
void (* stop_adapter)(struct net_device *dev, bool reset);
|
||||
void (* update_ratr_table)(struct net_device* dev);
|
||||
void (* irq_enable)(struct net_device* dev);
|
||||
void (* irq_disable)(struct net_device* dev);
|
||||
void (* irq_clear)(struct net_device* dev);
|
||||
void (* rx_enable)(struct net_device* dev);
|
||||
void (* tx_enable)(struct net_device* dev);
|
||||
void (* interrupt_recognized)(struct net_device *dev, u32 *p_inta, u32 *p_intb);
|
||||
bool (* TxCheckStuckHandler)(struct net_device* dev);
|
||||
bool (* RxCheckStuckHandler)(struct net_device* dev);
|
||||
void (*get_eeprom_size)(struct net_device *dev);
|
||||
void (*init_adapter_variable)(struct net_device *dev);
|
||||
void (*init_before_adapter_start)(struct net_device *dev);
|
||||
bool (*initialize_adapter)(struct net_device *dev);
|
||||
void (*link_change)(struct net_device *dev);
|
||||
void (*tx_fill_descriptor)(struct net_device *dev,
|
||||
struct tx_desc *tx_desc,
|
||||
struct cb_desc *cb_desc,
|
||||
struct sk_buff *skb);
|
||||
void (*tx_fill_cmd_descriptor)(struct net_device *dev,
|
||||
struct tx_desc_cmd *entry,
|
||||
struct cb_desc *cb_desc,
|
||||
struct sk_buff *skb);
|
||||
bool (*rx_query_status_descriptor)(struct net_device *dev,
|
||||
struct rtllib_rx_stats *stats,
|
||||
struct rx_desc *pdesc,
|
||||
struct sk_buff *skb);
|
||||
bool (*rx_command_packet_handler)(struct net_device *dev,
|
||||
struct sk_buff *skb,
|
||||
struct rx_desc *pdesc);
|
||||
void (*stop_adapter)(struct net_device *dev, bool reset);
|
||||
void (*update_ratr_table)(struct net_device *dev);
|
||||
void (*irq_enable)(struct net_device *dev);
|
||||
void (*irq_disable)(struct net_device *dev);
|
||||
void (*irq_clear)(struct net_device *dev);
|
||||
void (*rx_enable)(struct net_device *dev);
|
||||
void (*tx_enable)(struct net_device *dev);
|
||||
void (*interrupt_recognized)(struct net_device *dev,
|
||||
u32 *p_inta, u32 *p_intb);
|
||||
bool (*TxCheckStuckHandler)(struct net_device *dev);
|
||||
bool (*RxCheckStuckHandler)(struct net_device *dev);
|
||||
};
|
||||
|
||||
struct r8192_priv {
|
||||
@@ -630,8 +652,8 @@ struct r8192_priv {
|
||||
struct iw_statistics wstats;
|
||||
struct proc_dir_entry *dir_dev;
|
||||
|
||||
short (*rf_set_sens)(struct net_device *dev,short sens);
|
||||
u8 (*rf_set_chan)(struct net_device *dev,u8 ch);
|
||||
short (*rf_set_sens)(struct net_device *dev, short sens);
|
||||
u8 (*rf_set_chan)(struct net_device *dev, u8 ch);
|
||||
void (*rf_close)(struct net_device *dev);
|
||||
void (*rf_init)(struct net_device *dev);
|
||||
|
||||
@@ -672,7 +694,10 @@ struct r8192_priv {
|
||||
|
||||
/**********************************************************/
|
||||
|
||||
enum card_type {PCI,MINIPCI,CARDBUS,USB}card_type;
|
||||
enum card_type {
|
||||
PCI, MINIPCI,
|
||||
CARDBUS, USB
|
||||
} card_type;
|
||||
|
||||
struct work_struct qos_activate;
|
||||
|
||||
@@ -727,7 +752,6 @@ struct r8192_priv {
|
||||
u32 last_rxdesc_tsf_high;
|
||||
u32 last_rxdesc_tsf_low;
|
||||
|
||||
|
||||
u16 basic_rate;
|
||||
u8 short_preamble;
|
||||
u8 dot11CurrentPreambleMode;
|
||||
@@ -1016,41 +1040,42 @@ struct r8192_priv {
|
||||
extern const struct ethtool_ops rtl819x_ethtool_ops;
|
||||
|
||||
void rtl8192_tx_cmd(struct net_device *dev, struct sk_buff *skb);
|
||||
short rtl8192_tx(struct net_device *dev, struct sk_buff* skb);
|
||||
short rtl8192_tx(struct net_device *dev, struct sk_buff *skb);
|
||||
|
||||
u8 read_nic_io_byte(struct net_device *dev, int x);
|
||||
u32 read_nic_io_dword(struct net_device *dev, int x);
|
||||
u16 read_nic_io_word(struct net_device *dev, int x) ;
|
||||
void write_nic_io_byte(struct net_device *dev, int x,u8 y);
|
||||
void write_nic_io_word(struct net_device *dev, int x,u16 y);
|
||||
void write_nic_io_dword(struct net_device *dev, int x,u32 y);
|
||||
void write_nic_io_byte(struct net_device *dev, int x, u8 y);
|
||||
void write_nic_io_word(struct net_device *dev, int x, u16 y);
|
||||
void write_nic_io_dword(struct net_device *dev, int x, u32 y);
|
||||
|
||||
u8 read_nic_byte(struct net_device *dev, int x);
|
||||
u32 read_nic_dword(struct net_device *dev, int x);
|
||||
u16 read_nic_word(struct net_device *dev, int x) ;
|
||||
void write_nic_byte(struct net_device *dev, int x,u8 y);
|
||||
void write_nic_word(struct net_device *dev, int x,u16 y);
|
||||
void write_nic_dword(struct net_device *dev, int x,u32 y);
|
||||
void write_nic_byte(struct net_device *dev, int x, u8 y);
|
||||
void write_nic_word(struct net_device *dev, int x, u16 y);
|
||||
void write_nic_dword(struct net_device *dev, int x, u32 y);
|
||||
|
||||
void force_pci_posting(struct net_device *dev);
|
||||
|
||||
void rtl8192_rx_enable(struct net_device *);
|
||||
void rtl8192_tx_enable(struct net_device *);
|
||||
|
||||
int rtl8192_hard_start_xmit(struct sk_buff *skb,struct net_device *dev);
|
||||
void rtl8192_hard_data_xmit(struct sk_buff *skb, struct net_device *dev, int rate);
|
||||
int rtl8192_hard_start_xmit(struct sk_buff *skb, struct net_device *dev);
|
||||
void rtl8192_hard_data_xmit(struct sk_buff *skb, struct net_device *dev,
|
||||
int rate);
|
||||
void rtl8192_data_hard_stop(struct net_device *dev);
|
||||
void rtl8192_data_hard_resume(struct net_device *dev);
|
||||
void rtl8192_restart(void *data);
|
||||
void rtl819x_watchdog_wqcallback(void *data);
|
||||
void rtl8192_hw_sleep_wq (void *data);
|
||||
void rtl8192_hw_sleep_wq(void *data);
|
||||
void watch_dog_timer_callback(unsigned long data);
|
||||
void rtl8192_irq_rx_tasklet(struct r8192_priv *priv);
|
||||
void rtl8192_irq_tx_tasklet(struct r8192_priv *priv);
|
||||
int rtl8192_down(struct net_device *dev,bool shutdownrf);
|
||||
int rtl8192_down(struct net_device *dev, bool shutdownrf);
|
||||
int rtl8192_up(struct net_device *dev);
|
||||
void rtl8192_commit(struct net_device *dev);
|
||||
void rtl8192_set_chan(struct net_device *dev,short ch);
|
||||
void rtl8192_set_chan(struct net_device *dev, short ch);
|
||||
|
||||
void check_rfctrl_gpio_timer(unsigned long data);
|
||||
|
||||
@@ -1059,44 +1084,42 @@ irqreturn_type rtl8192_interrupt(int irq, void *netdev, struct pt_regs *regs);
|
||||
|
||||
short rtl8192_pci_initdescring(struct net_device *dev);
|
||||
|
||||
void rtl8192_cancel_deferred_work(struct r8192_priv * priv);
|
||||
void rtl8192_cancel_deferred_work(struct r8192_priv *priv);
|
||||
|
||||
int _rtl8192_up(struct net_device *dev,bool is_silent_reset);
|
||||
int _rtl8192_up(struct net_device *dev, bool is_silent_reset);
|
||||
|
||||
short rtl8192_is_tx_queue_empty(struct net_device *dev);
|
||||
void rtl8192_irq_disable(struct net_device *dev);
|
||||
|
||||
void rtl8192_tx_timeout(struct net_device *dev);
|
||||
void rtl8192_pci_resetdescring(struct net_device *dev);
|
||||
void rtl8192_SetWirelessMode(struct net_device* dev, u8 wireless_mode);
|
||||
void rtl8192_SetWirelessMode(struct net_device *dev, u8 wireless_mode);
|
||||
void rtl8192_irq_enable(struct net_device *dev);
|
||||
void rtl8192_config_rate(struct net_device* dev, u16* rate_config);
|
||||
void rtl8192_update_cap(struct net_device* dev, u16 cap);
|
||||
void rtl8192_config_rate(struct net_device *dev, u16 *rate_config);
|
||||
void rtl8192_update_cap(struct net_device *dev, u16 cap);
|
||||
void rtl8192_irq_disable(struct net_device *dev);
|
||||
|
||||
void rtl819x_UpdateRxPktTimeStamp (struct net_device *dev, struct rtllib_rx_stats *stats);
|
||||
long rtl819x_translate_todbm(struct r8192_priv * priv, u8 signal_strength_index );
|
||||
void rtl819x_update_rxsignalstatistics8190pci(struct r8192_priv * priv,struct rtllib_rx_stats * pprevious_stats);
|
||||
void rtl819x_UpdateRxPktTimeStamp(struct net_device *dev,
|
||||
struct rtllib_rx_stats *stats);
|
||||
long rtl819x_translate_todbm(struct r8192_priv *priv, u8 signal_strength_index);
|
||||
void rtl819x_update_rxsignalstatistics8190pci(struct r8192_priv *priv,
|
||||
struct rtllib_rx_stats *pprevious_stats);
|
||||
u8 rtl819x_evm_dbtopercentage(char value);
|
||||
void rtl819x_process_cck_rxpathsel(struct r8192_priv * priv,struct rtllib_rx_stats * pprevious_stats);
|
||||
u8 rtl819x_query_rxpwrpercentage( char antpower );
|
||||
void rtl8192_record_rxdesc_forlateruse(struct rtllib_rx_stats * psrc_stats,struct rtllib_rx_stats * ptarget_stats);
|
||||
void rtl819x_process_cck_rxpathsel(struct r8192_priv *priv,
|
||||
struct rtllib_rx_stats *pprevious_stats);
|
||||
u8 rtl819x_query_rxpwrpercentage(char antpower);
|
||||
void rtl8192_record_rxdesc_forlateruse(struct rtllib_rx_stats *psrc_stats,
|
||||
struct rtllib_rx_stats *ptarget_stats);
|
||||
|
||||
bool NicIFEnableNIC(struct net_device* dev);
|
||||
bool NicIFDisableNIC(struct net_device* dev);
|
||||
bool NicIFEnableNIC(struct net_device *dev);
|
||||
bool NicIFDisableNIC(struct net_device *dev);
|
||||
|
||||
bool
|
||||
MgntActSet_RF_State(
|
||||
struct net_device* dev,
|
||||
bool MgntActSet_RF_State(struct net_device *dev,
|
||||
enum rt_rf_power_state StateToSet,
|
||||
RT_RF_CHANGE_SOURCE ChangeSource,
|
||||
bool ProtectOrNot
|
||||
);
|
||||
void
|
||||
ActUpdateChannelAccessSetting(
|
||||
struct net_device* dev,
|
||||
bool ProtectOrNot);
|
||||
void ActUpdateChannelAccessSetting(struct net_device *dev,
|
||||
enum wireless_mode WirelessMode,
|
||||
struct channel_access_setting *ChnlAccessSetting
|
||||
);
|
||||
struct channel_access_setting *ChnlAccessSetting);
|
||||
|
||||
#endif
|
||||
|
Reference in New Issue
Block a user