Commit 5cfa1b25 authored by Ana Rey's avatar Ana Rey Committed by Greg Kroah-Hartman

staging: rtl8187se: fix coding style in function declarations

Removed innecessary spaces and indentation errors in function definition
(including some curly braces wrongly placed and broke up at 80-chars per line).

I still see some errors if I run the checkpatch.pl script, but those are not
my fault. I'll address them in follow up patches.
Signed-off-by: default avatarAna Rey <anarey@gmail.com>
Acked-by: default avatarPablo Neira Ayuso <pablo@gnumonks.org>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent 5ee86a38
#include "dot11d.h" #include "dot11d.h"
void void Dot11d_Init(struct ieee80211_device *ieee)
Dot11d_Init(struct ieee80211_device *ieee)
{ {
PRT_DOT11D_INFO pDot11dInfo = GET_DOT11D_INFO(ieee); PRT_DOT11D_INFO pDot11dInfo = GET_DOT11D_INFO(ieee);
...@@ -17,8 +16,7 @@ Dot11d_Init(struct ieee80211_device *ieee) ...@@ -17,8 +16,7 @@ Dot11d_Init(struct ieee80211_device *ieee)
} }
/* Reset to the state as we are just entering a regulatory domain. */ /* Reset to the state as we are just entering a regulatory domain. */
void void Dot11d_Reset(struct ieee80211_device *ieee)
Dot11d_Reset(struct ieee80211_device *ieee)
{ {
u32 i; u32 i;
PRT_DOT11D_INFO pDot11dInfo = GET_DOT11D_INFO(ieee); PRT_DOT11D_INFO pDot11dInfo = GET_DOT11D_INFO(ieee);
...@@ -50,13 +48,8 @@ Dot11d_Reset(struct ieee80211_device *ieee) ...@@ -50,13 +48,8 @@ Dot11d_Reset(struct ieee80211_device *ieee)
* 1. IS_DOT11D_ENABLE() is TRUE. * 1. IS_DOT11D_ENABLE() is TRUE.
* 2. Input IE is an valid one. * 2. Input IE is an valid one.
*/ */
void void Dot11d_UpdateCountryIe(struct ieee80211_device *dev, u8 *pTaddr,
Dot11d_UpdateCountryIe( u16 CoutryIeLen, u8 *pCoutryIe)
struct ieee80211_device *dev,
u8 *pTaddr,
u16 CoutryIeLen,
u8 *pCoutryIe
)
{ {
PRT_DOT11D_INFO pDot11dInfo = GET_DOT11D_INFO(dev); PRT_DOT11D_INFO pDot11dInfo = GET_DOT11D_INFO(dev);
u8 i, j, NumTriples, MaxChnlNum; u8 i, j, NumTriples, MaxChnlNum;
...@@ -122,11 +115,7 @@ Dot11d_UpdateCountryIe( ...@@ -122,11 +115,7 @@ Dot11d_UpdateCountryIe(
pDot11dInfo->State = DOT11D_STATE_LEARNED; pDot11dInfo->State = DOT11D_STATE_LEARNED;
} }
u8 u8 DOT11D_GetMaxTxPwrInDbm(struct ieee80211_device *dev, u8 Channel)
DOT11D_GetMaxTxPwrInDbm(
struct ieee80211_device *dev,
u8 Channel
)
{ {
PRT_DOT11D_INFO pDot11dInfo = GET_DOT11D_INFO(dev); PRT_DOT11D_INFO pDot11dInfo = GET_DOT11D_INFO(dev);
u8 MaxTxPwrInDbm = 255; u8 MaxTxPwrInDbm = 255;
...@@ -142,10 +131,7 @@ DOT11D_GetMaxTxPwrInDbm( ...@@ -142,10 +131,7 @@ DOT11D_GetMaxTxPwrInDbm(
} }
void void DOT11D_ScanComplete(struct ieee80211_device *dev)
DOT11D_ScanComplete(
struct ieee80211_device *dev
)
{ {
PRT_DOT11D_INFO pDot11dInfo = GET_DOT11D_INFO(dev); PRT_DOT11D_INFO pDot11dInfo = GET_DOT11D_INFO(dev);
...@@ -165,10 +151,7 @@ DOT11D_ScanComplete( ...@@ -165,10 +151,7 @@ DOT11D_ScanComplete(
} }
} }
int IsLegalChannel( int IsLegalChannel(struct ieee80211_device *dev, u8 channel)
struct ieee80211_device *dev,
u8 channel
)
{ {
PRT_DOT11D_INFO pDot11dInfo = GET_DOT11D_INFO(dev); PRT_DOT11D_INFO pDot11dInfo = GET_DOT11D_INFO(dev);
...@@ -181,10 +164,7 @@ int IsLegalChannel( ...@@ -181,10 +164,7 @@ int IsLegalChannel(
return 0; return 0;
} }
int ToLegalChannel( int ToLegalChannel(struct ieee80211_device *dev, u8 channel)
struct ieee80211_device *dev,
u8 channel
)
{ {
PRT_DOT11D_INFO pDot11dInfo = GET_DOT11D_INFO(dev); PRT_DOT11D_INFO pDot11dInfo = GET_DOT11D_INFO(dev);
u8 default_chn = 0; u8 default_chn = 0;
......
...@@ -58,43 +58,13 @@ typedef struct _RT_DOT11D_INFO { ...@@ -58,43 +58,13 @@ typedef struct _RT_DOT11D_INFO {
#define IS_DOT11D_STATE_DONE(__pIeeeDev) (GET_DOT11D_INFO(__pIeeeDev)->State == DOT11D_STATE_DONE) #define IS_DOT11D_STATE_DONE(__pIeeeDev) (GET_DOT11D_INFO(__pIeeeDev)->State == DOT11D_STATE_DONE)
void Dot11d_Init(struct ieee80211_device *dev);
void Dot11d_Reset(struct ieee80211_device *dev);
void Dot11d_UpdateCountryIe(struct ieee80211_device *dev, u8 *pTaddr,
u16 CoutryIeLen, u8 *pCoutryIe);
u8 DOT11D_GetMaxTxPwrInDbm(struct ieee80211_device *dev, u8 Channel);
void DOT11D_ScanComplete(struct ieee80211_device *dev);
int IsLegalChannel(struct ieee80211_device *dev, u8 channel);
int ToLegalChannel(struct ieee80211_device *dev, u8 channel);
void
Dot11d_Init(
struct ieee80211_device *dev
);
void
Dot11d_Reset(
struct ieee80211_device *dev
);
void
Dot11d_UpdateCountryIe(
struct ieee80211_device *dev,
u8 * pTaddr,
u16 CoutryIeLen,
u8 * pCoutryIe
);
u8
DOT11D_GetMaxTxPwrInDbm(
struct ieee80211_device *dev,
u8 Channel
);
void
DOT11D_ScanComplete(
struct ieee80211_device * dev
);
int IsLegalChannel(
struct ieee80211_device * dev,
u8 channel
);
int ToLegalChannel(
struct ieee80211_device * dev,
u8 channel
);
#endif /* #ifndef __INC_DOT11D_H */ #endif /* #ifndef __INC_DOT11D_H */
...@@ -1240,7 +1240,8 @@ static inline int ieee80211_is_empty_essid(const char *essid, int essid_len) ...@@ -1240,7 +1240,8 @@ static inline int ieee80211_is_empty_essid(const char *essid, int essid_len)
return 1; return 1;
} }
static inline int ieee80211_is_valid_mode(struct ieee80211_device *ieee, int mode) static inline int ieee80211_is_valid_mode(struct ieee80211_device *ieee,
int mode)
{ {
/* /*
* It is possible for both access points and our device to support * It is possible for both access points and our device to support
...@@ -1303,19 +1304,16 @@ extern int ieee80211_set_encryption(struct ieee80211_device *ieee); ...@@ -1303,19 +1304,16 @@ extern int ieee80211_set_encryption(struct ieee80211_device *ieee);
/* ieee80211_tx.c */ /* ieee80211_tx.c */
extern int ieee80211_encrypt_fragment( extern int ieee80211_encrypt_fragment(struct ieee80211_device *ieee,
struct ieee80211_device *ieee, struct sk_buff *frag, int hdr_len);
struct sk_buff *frag,
int hdr_len);
extern int ieee80211_rtl_xmit(struct sk_buff *skb, extern int ieee80211_rtl_xmit(struct sk_buff *skb, struct net_device *dev);
struct net_device *dev);
extern void ieee80211_txb_free(struct ieee80211_txb *); extern void ieee80211_txb_free(struct ieee80211_txb *);
/* ieee80211_rx.c */ /* ieee80211_rx.c */
extern int ieee80211_rtl_rx(struct ieee80211_device *ieee, struct sk_buff *skb, extern int ieee80211_rtl_rx(struct ieee80211_device *ieee, struct sk_buff *skb,
struct ieee80211_rx_stats *rx_stats); struct ieee80211_rx_stats *rx_stats);
extern void ieee80211_rx_mgt(struct ieee80211_device *ieee, extern void ieee80211_rx_mgt(struct ieee80211_device *ieee,
struct ieee80211_hdr_4addr *header, struct ieee80211_hdr_4addr *header,
struct ieee80211_rx_stats *stats); struct ieee80211_rx_stats *stats);
...@@ -1331,25 +1329,28 @@ extern int ieee80211_wx_get_encode(struct ieee80211_device *ieee, ...@@ -1331,25 +1329,28 @@ extern int ieee80211_wx_get_encode(struct ieee80211_device *ieee,
struct iw_request_info *info, struct iw_request_info *info,
union iwreq_data *wrqu, char *key); union iwreq_data *wrqu, char *key);
extern int ieee80211_wx_set_encode_ext(struct ieee80211_device *ieee, extern int ieee80211_wx_set_encode_ext(struct ieee80211_device *ieee,
struct iw_request_info *info, struct iw_request_info *info,
union iwreq_data* wrqu, char *extra); union iwreq_data *wrqu, char *extra);
int ieee80211_wx_set_auth(struct ieee80211_device *ieee, int ieee80211_wx_set_auth(struct ieee80211_device *ieee,
struct iw_request_info *info, struct iw_request_info *info,
struct iw_param *data, char *extra); struct iw_param *data, char *extra);
int ieee80211_wx_set_mlme(struct ieee80211_device *ieee, int ieee80211_wx_set_mlme(struct ieee80211_device *ieee,
struct iw_request_info *info, struct iw_request_info *info,
union iwreq_data *wrqu, char *extra); union iwreq_data *wrqu, char *extra);
int ieee80211_wx_set_gen_ie(struct ieee80211_device *ieee, u8 *ie, size_t len); int ieee80211_wx_set_gen_ie(struct ieee80211_device *ieee, u8 *ie, size_t len);
/* ieee80211_softmac.c */ /* ieee80211_softmac.c */
extern short ieee80211_is_54g(const struct ieee80211_network *net); extern short ieee80211_is_54g(const struct ieee80211_network *net);
extern short ieee80211_is_shortslot(const struct ieee80211_network *net); extern short ieee80211_is_shortslot(const struct ieee80211_network *net);
extern int ieee80211_rx_frame_softmac(struct ieee80211_device *ieee, struct sk_buff *skb, extern int ieee80211_rx_frame_softmac(struct ieee80211_device *ieee,
struct ieee80211_rx_stats *rx_stats, u16 type, struct sk_buff *skb,
u16 stype); struct ieee80211_rx_stats *rx_stats,
extern void ieee80211_softmac_new_net(struct ieee80211_device *ieee, struct ieee80211_network *net); u16 type, u16 stype);
extern void ieee80211_softmac_new_net(struct ieee80211_device *ieee,
extern void ieee80211_softmac_xmit(struct ieee80211_txb *txb, struct ieee80211_device *ieee); struct ieee80211_network *net);
extern void ieee80211_softmac_xmit(struct ieee80211_txb *txb,
struct ieee80211_device *ieee);
extern void ieee80211_softmac_check_all_nets(struct ieee80211_device *ieee); extern void ieee80211_softmac_check_all_nets(struct ieee80211_device *ieee);
extern void ieee80211_start_bss(struct ieee80211_device *ieee); extern void ieee80211_start_bss(struct ieee80211_device *ieee);
extern void ieee80211_start_master_bss(struct ieee80211_device *ieee); extern void ieee80211_start_master_bss(struct ieee80211_device *ieee);
...@@ -1371,16 +1372,17 @@ extern void ieee80211_rtl_stop_queue(struct ieee80211_device *ieee); ...@@ -1371,16 +1372,17 @@ extern void ieee80211_rtl_stop_queue(struct ieee80211_device *ieee);
extern struct sk_buff *ieee80211_get_beacon(struct ieee80211_device *ieee); extern struct sk_buff *ieee80211_get_beacon(struct ieee80211_device *ieee);
extern void ieee80211_start_send_beacons(struct ieee80211_device *ieee); extern void ieee80211_start_send_beacons(struct ieee80211_device *ieee);
extern void ieee80211_stop_send_beacons(struct ieee80211_device *ieee); extern void ieee80211_stop_send_beacons(struct ieee80211_device *ieee);
extern int ieee80211_wpa_supplicant_ioctl(struct ieee80211_device *ieee, struct iw_point *p); extern int ieee80211_wpa_supplicant_ioctl(struct ieee80211_device *ieee,
struct iw_point *p);
extern void notify_wx_assoc_event(struct ieee80211_device *ieee); extern void notify_wx_assoc_event(struct ieee80211_device *ieee);
extern void ieee80211_ps_tx_ack(struct ieee80211_device *ieee, short success); extern void ieee80211_ps_tx_ack(struct ieee80211_device *ieee, short success);
extern void SendDisassociation(struct ieee80211_device *ieee,u8* asSta,u8 asRsn); extern void SendDisassociation(struct ieee80211_device *ieee, u8 *asSta,
u8 asRsn);
extern void ieee80211_rtl_start_scan(struct ieee80211_device *ieee); extern void ieee80211_rtl_start_scan(struct ieee80211_device *ieee);
//Add for RF power on power off by lizhaoming 080512 //Add for RF power on power off by lizhaoming 080512
extern void SendDisassociation(struct ieee80211_device *ieee, extern void SendDisassociation(struct ieee80211_device *ieee, u8 *asSta,
u8* asSta, u8 asRsn);
u8 asRsn);
/* ieee80211_crypt_ccmp&tkip&wep.c */ /* ieee80211_crypt_ccmp&tkip&wep.c */
extern void ieee80211_tkip_null(void); extern void ieee80211_tkip_null(void);
...@@ -1389,64 +1391,72 @@ extern void ieee80211_ccmp_null(void); ...@@ -1389,64 +1391,72 @@ extern void ieee80211_ccmp_null(void);
/* ieee80211_softmac_wx.c */ /* ieee80211_softmac_wx.c */
extern int ieee80211_wx_get_wap(struct ieee80211_device *ieee, extern int ieee80211_wx_get_wap(struct ieee80211_device *ieee,
struct iw_request_info *info, struct iw_request_info *info,
union iwreq_data *wrqu, char *ext); union iwreq_data *wrqu, char *ext);
extern int ieee80211_wx_set_wap(struct ieee80211_device *ieee, extern int ieee80211_wx_set_wap(struct ieee80211_device *ieee,
struct iw_request_info *info, struct iw_request_info *info,
union iwreq_data *awrq, union iwreq_data *awrq,
char *extra); char *extra);
extern int ieee80211_wx_get_essid(struct ieee80211_device *ieee, struct iw_request_info *a,union iwreq_data *wrqu,char *b); extern int ieee80211_wx_get_essid(struct ieee80211_device *ieee,
struct iw_request_info *a,
union iwreq_data *wrqu, char *b);
extern int ieee80211_wx_set_rate(struct ieee80211_device *ieee, extern int ieee80211_wx_set_rate(struct ieee80211_device *ieee,
struct iw_request_info *info, struct iw_request_info *info,
union iwreq_data *wrqu, char *extra); union iwreq_data *wrqu, char *extra);
extern int ieee80211_wx_get_rate(struct ieee80211_device *ieee, extern int ieee80211_wx_get_rate(struct ieee80211_device *ieee,
struct iw_request_info *info, struct iw_request_info *info,
union iwreq_data *wrqu, char *extra); union iwreq_data *wrqu, char *extra);
extern int ieee80211_wx_set_mode(struct ieee80211_device *ieee, struct iw_request_info *a, extern int ieee80211_wx_set_mode(struct ieee80211_device *ieee,
union iwreq_data *wrqu, char *b); struct iw_request_info *a,
union iwreq_data *wrqu, char *b);
extern int ieee80211_wx_set_scan(struct ieee80211_device *ieee, struct iw_request_info *a, extern int ieee80211_wx_set_scan(struct ieee80211_device *ieee,
union iwreq_data *wrqu, char *b); struct iw_request_info *a,
union iwreq_data *wrqu, char *b);
extern int ieee80211_wx_set_essid(struct ieee80211_device *ieee, extern int ieee80211_wx_set_essid(struct ieee80211_device *ieee,
struct iw_request_info *a, struct iw_request_info *a,
union iwreq_data *wrqu, char *extra); union iwreq_data *wrqu, char *extra);
extern int ieee80211_wx_get_mode(struct ieee80211_device *ieee, struct iw_request_info *a, extern int ieee80211_wx_get_mode(struct ieee80211_device *ieee,
union iwreq_data *wrqu, char *b); struct iw_request_info *a,
union iwreq_data *wrqu, char *b);
extern int ieee80211_wx_set_freq(struct ieee80211_device *ieee, struct iw_request_info *a, extern int ieee80211_wx_set_freq(struct ieee80211_device *ieee,
union iwreq_data *wrqu, char *b); struct iw_request_info *a,
union iwreq_data *wrqu, char *b);
extern int ieee80211_wx_get_freq(struct ieee80211_device *ieee, struct iw_request_info *a, extern int ieee80211_wx_get_freq(struct ieee80211_device *ieee,
union iwreq_data *wrqu, char *b); struct iw_request_info *a,
union iwreq_data *wrqu, char *b);
extern void ieee80211_wx_sync_scan_wq(struct work_struct *work); extern void ieee80211_wx_sync_scan_wq(struct work_struct *work);
extern int ieee80211_wx_set_rawtx(struct ieee80211_device *ieee, extern int ieee80211_wx_set_rawtx(struct ieee80211_device *ieee,
struct iw_request_info *info, struct iw_request_info *info,
union iwreq_data *wrqu, char *extra); union iwreq_data *wrqu, char *extra);
extern int ieee80211_wx_get_name(struct ieee80211_device *ieee, extern int ieee80211_wx_get_name(struct ieee80211_device *ieee,
struct iw_request_info *info,
union iwreq_data *wrqu, char *extra);
extern int ieee80211_wx_set_power(struct ieee80211_device *ieee,
struct iw_request_info *info, struct iw_request_info *info,
union iwreq_data *wrqu, char *extra); union iwreq_data *wrqu, char *extra);
extern int ieee80211_wx_set_power(struct ieee80211_device *ieee,
struct iw_request_info *info,
union iwreq_data *wrqu, char *extra);
extern int ieee80211_wx_get_power(struct ieee80211_device *ieee, extern int ieee80211_wx_get_power(struct ieee80211_device *ieee,
struct iw_request_info *info, struct iw_request_info *info,
union iwreq_data *wrqu, char *extra); union iwreq_data *wrqu, char *extra);
extern void ieee80211_softmac_ips_scan_syncro(struct ieee80211_device *ieee); extern void ieee80211_softmac_ips_scan_syncro(struct ieee80211_device *ieee);
extern void ieee80211_sta_ps_send_null_frame(struct ieee80211_device *ieee, short pwr); extern void ieee80211_sta_ps_send_null_frame(struct ieee80211_device *ieee,
short pwr);
extern const long ieee80211_wlan_frequencies[]; extern const long ieee80211_wlan_frequencies[];
......
...@@ -39,8 +39,7 @@ struct ieee80211_crypto { ...@@ -39,8 +39,7 @@ struct ieee80211_crypto {
static struct ieee80211_crypto *hcrypt; static struct ieee80211_crypto *hcrypt;
void ieee80211_crypt_deinit_entries(struct ieee80211_device *ieee, void ieee80211_crypt_deinit_entries(struct ieee80211_device *ieee, int force)
int force)
{ {
struct list_head *ptr, *n; struct list_head *ptr, *n;
struct ieee80211_crypt_data *entry; struct ieee80211_crypt_data *entry;
......
...@@ -60,7 +60,7 @@ struct ieee80211_ccmp_data { ...@@ -60,7 +60,7 @@ struct ieee80211_ccmp_data {
}; };
void ieee80211_ccmp_aes_encrypt(struct crypto_tfm *tfm, void ieee80211_ccmp_aes_encrypt(struct crypto_tfm *tfm,
const u8 pt[16], u8 ct[16]) const u8 pt[16], u8 ct[16])
{ {
crypto_cipher_encrypt_one((void *)tfm, ct, pt); crypto_cipher_encrypt_one((void *)tfm, ct, pt);
} }
......
...@@ -520,7 +520,8 @@ static void michael_mic_hdr(struct sk_buff *skb, u8 *hdr) ...@@ -520,7 +520,8 @@ static void michael_mic_hdr(struct sk_buff *skb, u8 *hdr)
} }
static int ieee80211_michael_mic_add(struct sk_buff *skb, int hdr_len, void *priv) static int ieee80211_michael_mic_add(struct sk_buff *skb, int hdr_len,
void *priv)
{ {
struct ieee80211_tkip_data *tkey = priv; struct ieee80211_tkip_data *tkey = priv;
u8 *pos; u8 *pos;
...@@ -550,8 +551,8 @@ static int ieee80211_michael_mic_add(struct sk_buff *skb, int hdr_len, void *pri ...@@ -550,8 +551,8 @@ static int ieee80211_michael_mic_add(struct sk_buff *skb, int hdr_len, void *pri
} }
static void ieee80211_michael_mic_failure(struct net_device *dev, static void ieee80211_michael_mic_failure(struct net_device *dev,
struct ieee80211_hdr_4addr *hdr, struct ieee80211_hdr_4addr *hdr,
int keyidx) int keyidx)
{ {
union iwreq_data wrqu; union iwreq_data wrqu;
struct iw_michaelmicfailure ev; struct iw_michaelmicfailure ev;
...@@ -571,7 +572,7 @@ static void ieee80211_michael_mic_failure(struct net_device *dev, ...@@ -571,7 +572,7 @@ static void ieee80211_michael_mic_failure(struct net_device *dev,
} }
static int ieee80211_michael_mic_verify(struct sk_buff *skb, int keyidx, static int ieee80211_michael_mic_verify(struct sk_buff *skb, int keyidx,
int hdr_len, void *priv) int hdr_len, void *priv)
{ {
struct ieee80211_tkip_data *tkey = priv; struct ieee80211_tkip_data *tkey = priv;
u8 mic[8]; u8 mic[8];
......
...@@ -337,8 +337,9 @@ ieee80211_rx_frame_decrypt(struct ieee80211_device *ieee, struct sk_buff *skb, ...@@ -337,8 +337,9 @@ ieee80211_rx_frame_decrypt(struct ieee80211_device *ieee, struct sk_buff *skb,
/* Called only as a tasklet (software IRQ), by ieee80211_rx */ /* Called only as a tasklet (software IRQ), by ieee80211_rx */
static inline int static inline int
ieee80211_rx_frame_decrypt_msdu(struct ieee80211_device *ieee, struct sk_buff *skb, ieee80211_rx_frame_decrypt_msdu(struct ieee80211_device *ieee,
int keyidx, struct ieee80211_crypt_data *crypt) struct sk_buff *skb, int keyidx,
struct ieee80211_crypt_data *crypt)
{ {
struct ieee80211_hdr_4addr *hdr; struct ieee80211_hdr_4addr *hdr;
int res, hdrlen; int res, hdrlen;
...@@ -366,7 +367,7 @@ ieee80211_rx_frame_decrypt_msdu(struct ieee80211_device *ieee, struct sk_buff *s ...@@ -366,7 +367,7 @@ ieee80211_rx_frame_decrypt_msdu(struct ieee80211_device *ieee, struct sk_buff *s
/* this function is stolen from ipw2200 driver*/ /* this function is stolen from ipw2200 driver*/
#define IEEE_PACKET_RETRY_TIME (5*HZ) #define IEEE_PACKET_RETRY_TIME (5*HZ)
static int is_duplicate_packet(struct ieee80211_device *ieee, static int is_duplicate_packet(struct ieee80211_device *ieee,
struct ieee80211_hdr_4addr *header) struct ieee80211_hdr_4addr *header)
{ {
u16 fc = le16_to_cpu(header->frame_ctl); u16 fc = le16_to_cpu(header->frame_ctl);
u16 sc = le16_to_cpu(header->seq_ctl); u16 sc = le16_to_cpu(header->seq_ctl);
...@@ -467,7 +468,7 @@ static int is_duplicate_packet(struct ieee80211_device *ieee, ...@@ -467,7 +468,7 @@ static int is_duplicate_packet(struct ieee80211_device *ieee,
* IEEE 802.11 format, i.e., in the format it was sent over air. * IEEE 802.11 format, i.e., in the format it was sent over air.
* This function is called only as a tasklet (software IRQ). */ * This function is called only as a tasklet (software IRQ). */
int ieee80211_rtl_rx(struct ieee80211_device *ieee, struct sk_buff *skb, int ieee80211_rtl_rx(struct ieee80211_device *ieee, struct sk_buff *skb,
struct ieee80211_rx_stats *rx_stats) struct ieee80211_rx_stats *rx_stats)
{ {
struct net_device *dev = ieee->dev; struct net_device *dev = ieee->dev;
//struct r8180_priv *priv = (struct r8180_priv *)ieee80211_priv(dev); //struct r8180_priv *priv = (struct r8180_priv *)ieee80211_priv(dev);
...@@ -794,9 +795,7 @@ static inline int ieee80211_is_ofdm_rate(u8 rate) ...@@ -794,9 +795,7 @@ static inline int ieee80211_is_ofdm_rate(u8 rate)
return 0; return 0;
} }
static inline int ieee80211_SignalStrengthTranslate( static inline int ieee80211_SignalStrengthTranslate(int CurrSS)
int CurrSS
)
{ {
int RetSS; int RetSS;
...@@ -831,12 +830,10 @@ static inline int ieee80211_SignalStrengthTranslate( ...@@ -831,12 +830,10 @@ static inline int ieee80211_SignalStrengthTranslate(
return RetSS; return RetSS;
} }
static inline void ieee80211_extract_country_ie( static inline void
struct ieee80211_device *ieee, ieee80211_extract_country_ie(struct ieee80211_device *ieee,
struct ieee80211_info_element *info_element, struct ieee80211_info_element *info_element,
struct ieee80211_network *network, struct ieee80211_network *network, u8 *addr2)
u8 *addr2
)
{ {
if (IS_DOT11D_ENABLE(ieee)) { if (IS_DOT11D_ENABLE(ieee)) {
if (info_element->len != 0) { if (info_element->len != 0) {
...@@ -858,10 +855,8 @@ static inline void ieee80211_extract_country_ie( ...@@ -858,10 +855,8 @@ static inline void ieee80211_extract_country_ie(
} }
static int /* SignalStrengthIndex is 0-100 */
ieee80211_TranslateToDbm( static int ieee80211_TranslateToDbm(unsigned char SignalStrengthIndex)
unsigned char SignalStrengthIndex // 0-100 index.
)
{ {
unsigned char SignalPower; // in dBm. unsigned char SignalPower; // in dBm.
...@@ -1197,7 +1192,7 @@ static inline int is_same_network(struct ieee80211_network *src, ...@@ -1197,7 +1192,7 @@ static inline int is_same_network(struct ieee80211_network *src,
} }
inline void update_network(struct ieee80211_network *dst, inline void update_network(struct ieee80211_network *dst,
struct ieee80211_network *src) struct ieee80211_network *src)
{ {
unsigned char quality = src->stats.signalstrength; unsigned char quality = src->stats.signalstrength;
unsigned char signal = 0; unsigned char signal = 0;
...@@ -1281,10 +1276,10 @@ inline void update_network(struct ieee80211_network *dst, ...@@ -1281,10 +1276,10 @@ inline void update_network(struct ieee80211_network *dst,
} }
inline void ieee80211_process_probe_response( inline void
struct ieee80211_device *ieee, ieee80211_process_probe_response(struct ieee80211_device *ieee,
struct ieee80211_probe_response *beacon, struct ieee80211_probe_response *beacon,
struct ieee80211_rx_stats *stats) struct ieee80211_rx_stats *stats)
{ {
struct ieee80211_network network; struct ieee80211_network network;
struct ieee80211_network *target; struct ieee80211_network *target;
......
...@@ -186,7 +186,8 @@ void init_mgmt_queue(struct ieee80211_device *ieee) ...@@ -186,7 +186,8 @@ void init_mgmt_queue(struct ieee80211_device *ieee)
void ieee80211_sta_wakeup(struct ieee80211_device *ieee, short nl); void ieee80211_sta_wakeup(struct ieee80211_device *ieee, short nl);
inline void softmac_mgmt_xmit(struct sk_buff *skb, struct ieee80211_device *ieee) inline void softmac_mgmt_xmit(struct sk_buff *skb,
struct ieee80211_device *ieee)
{ {
unsigned long flags; unsigned long flags;
short single = ieee->softmac_features & IEEE_SOFTMAC_SINGLE_QUEUE; short single = ieee->softmac_features & IEEE_SOFTMAC_SINGLE_QUEUE;
...@@ -237,7 +238,8 @@ inline void softmac_mgmt_xmit(struct sk_buff *skb, struct ieee80211_device *ieee ...@@ -237,7 +238,8 @@ inline void softmac_mgmt_xmit(struct sk_buff *skb, struct ieee80211_device *ieee
} }
inline void softmac_ps_mgmt_xmit(struct sk_buff *skb, struct ieee80211_device *ieee) inline void softmac_ps_mgmt_xmit(struct sk_buff *skb,
struct ieee80211_device *ieee)
{ {
short single = ieee->softmac_features & IEEE_SOFTMAC_SINGLE_QUEUE; short single = ieee->softmac_features & IEEE_SOFTMAC_SINGLE_QUEUE;
...@@ -275,10 +277,9 @@ inline void softmac_ps_mgmt_xmit(struct sk_buff *skb, struct ieee80211_device *i ...@@ -275,10 +277,9 @@ inline void softmac_ps_mgmt_xmit(struct sk_buff *skb, struct ieee80211_device *i
// dev_kfree_skb_any(skb);//edit by thomas // dev_kfree_skb_any(skb);//edit by thomas
} }
//by amy for power save //by amy for power save
inline struct sk_buff *ieee80211_disassociate_skb( inline struct sk_buff *
struct ieee80211_network *beacon, ieee80211_disassociate_skb(struct ieee80211_network *beacon,
struct ieee80211_device *ieee, struct ieee80211_device *ieee, u8 asRsn)
u8 asRsn)
{ {
struct sk_buff *skb; struct sk_buff *skb;
struct ieee80211_disassoc_frame *disass; struct ieee80211_disassoc_frame *disass;
...@@ -298,12 +299,7 @@ inline struct sk_buff *ieee80211_disassociate_skb( ...@@ -298,12 +299,7 @@ inline struct sk_buff *ieee80211_disassociate_skb(
disass->reasoncode = asRsn; disass->reasoncode = asRsn;
return skb; return skb;
} }
void void SendDisassociation(struct ieee80211_device *ieee, u8 *asSta, u8 asRsn)
SendDisassociation(
struct ieee80211_device *ieee,
u8* asSta,
u8 asRsn
)
{ {
struct ieee80211_network *beacon = &ieee->current_network; struct ieee80211_network *beacon = &ieee->current_network;
struct sk_buff *skb; struct sk_buff *skb;
...@@ -734,8 +730,9 @@ void ieee80211_start_scan_syncro(struct ieee80211_device *ieee) ...@@ -734,8 +730,9 @@ void ieee80211_start_scan_syncro(struct ieee80211_device *ieee)
} }
inline struct sk_buff *ieee80211_authentication_req(struct ieee80211_network *beacon, inline struct sk_buff *
struct ieee80211_device *ieee, int challengelen) ieee80211_authentication_req(struct ieee80211_network *beacon,
struct ieee80211_device *ieee, int challengelen)
{ {
struct sk_buff *skb; struct sk_buff *skb;
struct ieee80211_authentication *auth; struct ieee80211_authentication *auth;
...@@ -767,7 +764,8 @@ inline struct sk_buff *ieee80211_authentication_req(struct ieee80211_network *be ...@@ -767,7 +764,8 @@ inline struct sk_buff *ieee80211_authentication_req(struct ieee80211_network *be
} }
static struct sk_buff* ieee80211_probe_resp(struct ieee80211_device *ieee, u8 *dest) static struct sk_buff *ieee80211_probe_resp(struct ieee80211_device *ieee,
u8 *dest)
{ {
u8 *tag; u8 *tag;
int beacon_size; int beacon_size;
...@@ -968,7 +966,7 @@ static struct sk_buff *ieee80211_auth_resp(struct ieee80211_device *ieee, ...@@ -968,7 +966,7 @@ static struct sk_buff *ieee80211_auth_resp(struct ieee80211_device *ieee,
} }
struct sk_buff* ieee80211_null_func(struct ieee80211_device *ieee,short pwr) struct sk_buff *ieee80211_null_func(struct ieee80211_device *ieee, short pwr)
{ {
struct sk_buff *skb; struct sk_buff *skb;
struct ieee80211_hdr_3addr* hdr; struct ieee80211_hdr_3addr* hdr;
...@@ -994,7 +992,7 @@ struct sk_buff* ieee80211_null_func(struct ieee80211_device *ieee,short pwr) ...@@ -994,7 +992,7 @@ struct sk_buff* ieee80211_null_func(struct ieee80211_device *ieee,short pwr)
} }
void ieee80211_resp_to_assoc_rq(struct ieee80211_device *ieee, u8* dest) void ieee80211_resp_to_assoc_rq(struct ieee80211_device *ieee, u8 *dest)
{ {
struct sk_buff *buf = ieee80211_assoc_resp(ieee, dest); struct sk_buff *buf = ieee80211_assoc_resp(ieee, dest);
...@@ -1005,7 +1003,7 @@ void ieee80211_resp_to_assoc_rq(struct ieee80211_device *ieee, u8* dest) ...@@ -1005,7 +1003,7 @@ void ieee80211_resp_to_assoc_rq(struct ieee80211_device *ieee, u8* dest)
} }
void ieee80211_resp_to_auth(struct ieee80211_device *ieee, int s, u8* dest) void ieee80211_resp_to_auth(struct ieee80211_device *ieee, int s, u8 *dest)
{ {
struct sk_buff *buf = ieee80211_auth_resp(ieee, s, dest); struct sk_buff *buf = ieee80211_auth_resp(ieee, s, dest);
...@@ -1028,7 +1026,9 @@ void ieee80211_resp_to_probe(struct ieee80211_device *ieee, u8 *dest) ...@@ -1028,7 +1026,9 @@ void ieee80211_resp_to_probe(struct ieee80211_device *ieee, u8 *dest)
} }
inline struct sk_buff *ieee80211_association_req(struct ieee80211_network *beacon,struct ieee80211_device *ieee) inline struct sk_buff *
ieee80211_association_req(struct ieee80211_network *beacon,
struct ieee80211_device *ieee)
{ {
struct sk_buff *skb; struct sk_buff *skb;
//unsigned long flags; //unsigned long flags;
...@@ -1199,7 +1199,8 @@ void ieee80211_associate_step1(struct ieee80211_device *ieee) ...@@ -1199,7 +1199,8 @@ void ieee80211_associate_step1(struct ieee80211_device *ieee)
} }
} }
void ieee80211_rtl_auth_challenge(struct ieee80211_device *ieee, u8 *challenge, int chlen) void ieee80211_rtl_auth_challenge(struct ieee80211_device *ieee, u8 *challenge,
int chlen)
{ {
u8 *c; u8 *c;
struct sk_buff *skb; struct sk_buff *skb;
...@@ -1309,7 +1310,8 @@ void ieee80211_associate_procedure_wq(struct work_struct *work) ...@@ -1309,7 +1310,8 @@ void ieee80211_associate_procedure_wq(struct work_struct *work)
up(&ieee->wx_sem); up(&ieee->wx_sem);
} }
inline void ieee80211_softmac_new_net(struct ieee80211_device *ieee, struct ieee80211_network *net) inline void ieee80211_softmac_new_net(struct ieee80211_device *ieee,
struct ieee80211_network *net)
{ {
u8 tmp_ssid[IW_ESSID_MAX_SIZE+1]; u8 tmp_ssid[IW_ESSID_MAX_SIZE+1];
int tmp_ssid_len = 0; int tmp_ssid_len = 0;
...@@ -1422,7 +1424,7 @@ void ieee80211_softmac_check_all_nets(struct ieee80211_device *ieee) ...@@ -1422,7 +1424,7 @@ void ieee80211_softmac_check_all_nets(struct ieee80211_device *ieee)
} }
static inline u16 auth_parse(struct sk_buff *skb, u8** challenge, int *chlen) static inline u16 auth_parse(struct sk_buff *skb, u8 **challenge, int *chlen)
{ {
struct ieee80211_authentication *a; struct ieee80211_authentication *a;
u8 *t; u8 *t;
...@@ -1448,7 +1450,7 @@ static inline u16 auth_parse(struct sk_buff *skb, u8** challenge, int *chlen) ...@@ -1448,7 +1450,7 @@ static inline u16 auth_parse(struct sk_buff *skb, u8** challenge, int *chlen)
} }
int auth_rq_parse(struct sk_buff *skb,u8* dest) int auth_rq_parse(struct sk_buff *skb, u8 *dest)
{ {
struct ieee80211_authentication *a; struct ieee80211_authentication *a;
...@@ -1466,7 +1468,8 @@ int auth_rq_parse(struct sk_buff *skb,u8* dest) ...@@ -1466,7 +1468,8 @@ int auth_rq_parse(struct sk_buff *skb,u8* dest)
return WLAN_STATUS_SUCCESS; return WLAN_STATUS_SUCCESS;
} }
static short probe_rq_parse(struct ieee80211_device *ieee, struct sk_buff *skb, u8 *src) static short probe_rq_parse(struct ieee80211_device *ieee, struct sk_buff *skb,
u8 *src)
{ {
u8 *tag; u8 *tag;
u8 *skbend; u8 *skbend;
...@@ -1504,7 +1507,7 @@ static short probe_rq_parse(struct ieee80211_device *ieee, struct sk_buff *skb, ...@@ -1504,7 +1507,7 @@ static short probe_rq_parse(struct ieee80211_device *ieee, struct sk_buff *skb,
} }
int assoc_rq_parse(struct sk_buff *skb,u8* dest) int assoc_rq_parse(struct sk_buff *skb, u8 *dest)
{ {
struct ieee80211_assoc_request_frame *a; struct ieee80211_assoc_request_frame *a;
...@@ -1535,8 +1538,8 @@ static inline u16 assoc_parse(struct sk_buff *skb, int *aid) ...@@ -1535,8 +1538,8 @@ static inline u16 assoc_parse(struct sk_buff *skb, int *aid)
return le16_to_cpu(a->status); return le16_to_cpu(a->status);
} }
static inline void static inline void ieee80211_rx_probe_rq(struct ieee80211_device *ieee,
ieee80211_rx_probe_rq(struct ieee80211_device *ieee, struct sk_buff *skb) struct sk_buff *skb)
{ {
u8 dest[ETH_ALEN]; u8 dest[ETH_ALEN];
...@@ -1550,8 +1553,8 @@ ieee80211_rx_probe_rq(struct ieee80211_device *ieee, struct sk_buff *skb) ...@@ -1550,8 +1553,8 @@ ieee80211_rx_probe_rq(struct ieee80211_device *ieee, struct sk_buff *skb)
} }
} }
inline void inline void ieee80211_rx_auth_rq(struct ieee80211_device *ieee,
ieee80211_rx_auth_rq(struct ieee80211_device *ieee, struct sk_buff *skb) struct sk_buff *skb)
{ {
u8 dest[ETH_ALEN]; u8 dest[ETH_ALEN];
int status; int status;
...@@ -1594,7 +1597,8 @@ void ieee80211_sta_ps_send_null_frame(struct ieee80211_device *ieee, short pwr) ...@@ -1594,7 +1597,8 @@ void ieee80211_sta_ps_send_null_frame(struct ieee80211_device *ieee, short pwr)
} }
short ieee80211_sta_ps_sleep(struct ieee80211_device *ieee, u32 *time_h, u32 *time_l) short ieee80211_sta_ps_sleep(struct ieee80211_device *ieee, u32 *time_h,
u32 *time_l)
{ {
int timeout = 0; int timeout = 0;
...@@ -1769,10 +1773,10 @@ void ieee80211_ps_tx_ack(struct ieee80211_device *ieee, short success) ...@@ -1769,10 +1773,10 @@ void ieee80211_ps_tx_ack(struct ieee80211_device *ieee, short success)
spin_unlock_irqrestore(&ieee->lock, flags); spin_unlock_irqrestore(&ieee->lock, flags);
} }
inline int inline int ieee80211_rx_frame_softmac(struct ieee80211_device *ieee,
ieee80211_rx_frame_softmac(struct ieee80211_device *ieee, struct sk_buff *skb, struct sk_buff *skb,
struct ieee80211_rx_stats *rx_stats, u16 type, struct ieee80211_rx_stats *rx_stats,
u16 stype) u16 type, u16 stype)
{ {
struct ieee80211_hdr_3addr *header = (struct ieee80211_hdr_3addr *) skb->data; struct ieee80211_hdr_3addr *header = (struct ieee80211_hdr_3addr *) skb->data;
u16 errcode; u16 errcode;
...@@ -1975,7 +1979,8 @@ ieee80211_rx_frame_softmac(struct ieee80211_device *ieee, struct sk_buff *skb, ...@@ -1975,7 +1979,8 @@ ieee80211_rx_frame_softmac(struct ieee80211_device *ieee, struct sk_buff *skb,
* to the driver later, when it wakes the queue. * to the driver later, when it wakes the queue.
*/ */
void ieee80211_softmac_xmit(struct ieee80211_txb *txb, struct ieee80211_device *ieee) void ieee80211_softmac_xmit(struct ieee80211_txb *txb,
struct ieee80211_device *ieee)
{ {
...@@ -2618,7 +2623,8 @@ static int ieee80211_wpa_enable(struct ieee80211_device *ieee, int value) ...@@ -2618,7 +2623,8 @@ static int ieee80211_wpa_enable(struct ieee80211_device *ieee, int value)
} }
void ieee80211_wpa_assoc_frame(struct ieee80211_device *ieee, char *wpa_ie, int wpa_ie_len) void ieee80211_wpa_assoc_frame(struct ieee80211_device *ieee, char *wpa_ie,
int wpa_ie_len)
{ {
/* make sure WPA is enabled */ /* make sure WPA is enabled */
ieee80211_wpa_enable(ieee, 1); ieee80211_wpa_enable(ieee, 1);
...@@ -2627,7 +2633,8 @@ void ieee80211_wpa_assoc_frame(struct ieee80211_device *ieee, char *wpa_ie, int ...@@ -2627,7 +2633,8 @@ void ieee80211_wpa_assoc_frame(struct ieee80211_device *ieee, char *wpa_ie, int
} }
static int ieee80211_wpa_mlme(struct ieee80211_device *ieee, int command, int reason) static int ieee80211_wpa_mlme(struct ieee80211_device *ieee, int command,
int reason)
{ {
int ret = 0; int ret = 0;
...@@ -2651,7 +2658,7 @@ static int ieee80211_wpa_mlme(struct ieee80211_device *ieee, int command, int re ...@@ -2651,7 +2658,7 @@ static int ieee80211_wpa_mlme(struct ieee80211_device *ieee, int command, int re
static int ieee80211_wpa_set_wpa_ie(struct ieee80211_device *ieee, static int ieee80211_wpa_set_wpa_ie(struct ieee80211_device *ieee,
struct ieee_param *param, int plen) struct ieee_param *param, int plen)
{ {
u8 *buf; u8 *buf;
...@@ -2705,7 +2712,8 @@ static int ieee80211_wpa_set_auth_algs(struct ieee80211_device *ieee, int value) ...@@ -2705,7 +2712,8 @@ static int ieee80211_wpa_set_auth_algs(struct ieee80211_device *ieee, int value)
return ret; return ret;
} }
static int ieee80211_wpa_set_param(struct ieee80211_device *ieee, u8 name, u32 value) static int ieee80211_wpa_set_param(struct ieee80211_device *ieee, u8 name,
u32 value)
{ {
int ret=0; int ret=0;
unsigned long flags; unsigned long flags;
...@@ -2783,7 +2791,7 @@ static int ieee80211_wpa_set_param(struct ieee80211_device *ieee, u8 name, u32 v ...@@ -2783,7 +2791,7 @@ static int ieee80211_wpa_set_param(struct ieee80211_device *ieee, u8 name, u32 v
/* implementation borrowed from hostap driver */ /* implementation borrowed from hostap driver */
static int ieee80211_wpa_set_encryption(struct ieee80211_device *ieee, static int ieee80211_wpa_set_encryption(struct ieee80211_device *ieee,
struct ieee_param *param, int param_len) struct ieee_param *param, int param_len)
{ {
int ret = 0; int ret = 0;
...@@ -2930,7 +2938,8 @@ static int ieee80211_wpa_set_encryption(struct ieee80211_device *ieee, ...@@ -2930,7 +2938,8 @@ static int ieee80211_wpa_set_encryption(struct ieee80211_device *ieee,
return ret; return ret;
} }
int ieee80211_wpa_supplicant_ioctl(struct ieee80211_device *ieee, struct iw_point *p) int ieee80211_wpa_supplicant_ioctl(struct ieee80211_device *ieee,
struct iw_point *p)
{ {
struct ieee_param *param; struct ieee_param *param;
int ret=0; int ret=0;
......
...@@ -28,8 +28,9 @@ const long ieee80211_wlan_frequencies[] = { ...@@ -28,8 +28,9 @@ const long ieee80211_wlan_frequencies[] = {
}; };
int ieee80211_wx_set_freq(struct ieee80211_device *ieee, struct iw_request_info *a, int ieee80211_wx_set_freq(struct ieee80211_device *ieee,
union iwreq_data *wrqu, char *b) struct iw_request_info *a, union iwreq_data *wrqu,
char *b)
{ {
int ret; int ret;
struct iw_freq *fwrq = &wrqu->freq; struct iw_freq *fwrq = &wrqu->freq;
...@@ -82,8 +83,8 @@ int ieee80211_wx_set_freq(struct ieee80211_device *ieee, struct iw_request_info ...@@ -82,8 +83,8 @@ int ieee80211_wx_set_freq(struct ieee80211_device *ieee, struct iw_request_info
int ieee80211_wx_get_freq(struct ieee80211_device *ieee, int ieee80211_wx_get_freq(struct ieee80211_device *ieee,
struct iw_request_info *a, struct iw_request_info *a, union iwreq_data *wrqu,
union iwreq_data *wrqu, char *b) char *b)
{ {
struct iw_freq *fwrq = &wrqu->freq; struct iw_freq *fwrq = &wrqu->freq;
...@@ -97,8 +98,8 @@ int ieee80211_wx_get_freq(struct ieee80211_device *ieee, ...@@ -97,8 +98,8 @@ int ieee80211_wx_get_freq(struct ieee80211_device *ieee,
} }
int ieee80211_wx_get_wap(struct ieee80211_device *ieee, int ieee80211_wx_get_wap(struct ieee80211_device *ieee,
struct iw_request_info *info, struct iw_request_info *info, union iwreq_data *wrqu,
union iwreq_data *wrqu, char *extra) char *extra)
{ {
unsigned long flags; unsigned long flags;
...@@ -126,8 +127,7 @@ int ieee80211_wx_get_wap(struct ieee80211_device *ieee, ...@@ -126,8 +127,7 @@ int ieee80211_wx_get_wap(struct ieee80211_device *ieee,
int ieee80211_wx_set_wap(struct ieee80211_device *ieee, int ieee80211_wx_set_wap(struct ieee80211_device *ieee,
struct iw_request_info *info, struct iw_request_info *info, union iwreq_data *awrq,
union iwreq_data *awrq,
char *extra) char *extra)
{ {
...@@ -174,8 +174,9 @@ int ieee80211_wx_set_wap(struct ieee80211_device *ieee, ...@@ -174,8 +174,9 @@ int ieee80211_wx_set_wap(struct ieee80211_device *ieee,
return ret; return ret;
} }
int ieee80211_wx_get_essid(struct ieee80211_device *ieee, struct iw_request_info *a, int ieee80211_wx_get_essid(struct ieee80211_device *ieee,
union iwreq_data *wrqu, char *b) struct iw_request_info *a, union iwreq_data *wrqu,
char *b)
{ {
int len, ret = 0; int len, ret = 0;
unsigned long flags; unsigned long flags;
...@@ -211,8 +212,8 @@ int ieee80211_wx_get_essid(struct ieee80211_device *ieee, struct iw_request_info ...@@ -211,8 +212,8 @@ int ieee80211_wx_get_essid(struct ieee80211_device *ieee, struct iw_request_info
} }
int ieee80211_wx_set_rate(struct ieee80211_device *ieee, int ieee80211_wx_set_rate(struct ieee80211_device *ieee,
struct iw_request_info *info, struct iw_request_info *info, union iwreq_data *wrqu,
union iwreq_data *wrqu, char *extra) char *extra)
{ {
u32 target_rate = wrqu->bitrate.value; u32 target_rate = wrqu->bitrate.value;
...@@ -230,8 +231,8 @@ int ieee80211_wx_set_rate(struct ieee80211_device *ieee, ...@@ -230,8 +231,8 @@ int ieee80211_wx_set_rate(struct ieee80211_device *ieee,
int ieee80211_wx_get_rate(struct ieee80211_device *ieee, int ieee80211_wx_get_rate(struct ieee80211_device *ieee,
struct iw_request_info *info, struct iw_request_info *info, union iwreq_data *wrqu,
union iwreq_data *wrqu, char *extra) char *extra)
{ {
wrqu->bitrate.value = ieee->rate * 100000; wrqu->bitrate.value = ieee->rate * 100000;
...@@ -239,8 +240,9 @@ int ieee80211_wx_get_rate(struct ieee80211_device *ieee, ...@@ -239,8 +240,9 @@ int ieee80211_wx_get_rate(struct ieee80211_device *ieee,
return 0; return 0;
} }
int ieee80211_wx_set_mode(struct ieee80211_device *ieee, struct iw_request_info *a, int ieee80211_wx_set_mode(struct ieee80211_device *ieee,
union iwreq_data *wrqu, char *b) struct iw_request_info *a, union iwreq_data *wrqu,
char *b)
{ {
ieee->sync_scan_hurryup = 1; ieee->sync_scan_hurryup = 1;
...@@ -305,8 +307,9 @@ void ieee80211_wx_sync_scan_wq(struct work_struct *work) ...@@ -305,8 +307,9 @@ void ieee80211_wx_sync_scan_wq(struct work_struct *work)
} }
int ieee80211_wx_set_scan(struct ieee80211_device *ieee, struct iw_request_info *a, int ieee80211_wx_set_scan(struct ieee80211_device *ieee,
union iwreq_data *wrqu, char *b) struct iw_request_info *a, union iwreq_data *wrqu,
char *b)
{ {
int ret = 0; int ret = 0;
...@@ -333,8 +336,8 @@ int ieee80211_wx_set_scan(struct ieee80211_device *ieee, struct iw_request_info ...@@ -333,8 +336,8 @@ int ieee80211_wx_set_scan(struct ieee80211_device *ieee, struct iw_request_info
} }
int ieee80211_wx_set_essid(struct ieee80211_device *ieee, int ieee80211_wx_set_essid(struct ieee80211_device *ieee,
struct iw_request_info *a, struct iw_request_info *a, union iwreq_data *wrqu,
union iwreq_data *wrqu, char *extra) char *extra)
{ {
int ret = 0, len; int ret = 0, len;
...@@ -395,8 +398,9 @@ int ieee80211_wx_set_essid(struct ieee80211_device *ieee, ...@@ -395,8 +398,9 @@ int ieee80211_wx_set_essid(struct ieee80211_device *ieee,
return ret; return ret;
} }
int ieee80211_wx_get_mode(struct ieee80211_device *ieee, struct iw_request_info *a, int ieee80211_wx_get_mode(struct ieee80211_device *ieee,
union iwreq_data *wrqu, char *b) struct iw_request_info *a, union iwreq_data *wrqu,
char *b)
{ {
wrqu->mode = ieee->iw_mode; wrqu->mode = ieee->iw_mode;
...@@ -404,8 +408,8 @@ int ieee80211_wx_get_mode(struct ieee80211_device *ieee, struct iw_request_info ...@@ -404,8 +408,8 @@ int ieee80211_wx_get_mode(struct ieee80211_device *ieee, struct iw_request_info
} }
int ieee80211_wx_set_rawtx(struct ieee80211_device *ieee, int ieee80211_wx_set_rawtx(struct ieee80211_device *ieee,
struct iw_request_info *info, struct iw_request_info *info, union iwreq_data *wrqu,
union iwreq_data *wrqu, char *extra) char *extra)
{ {
int *parms = (int *)extra; int *parms = (int *)extra;
...@@ -440,8 +444,8 @@ int ieee80211_wx_set_rawtx(struct ieee80211_device *ieee, ...@@ -440,8 +444,8 @@ int ieee80211_wx_set_rawtx(struct ieee80211_device *ieee,
} }
int ieee80211_wx_get_name(struct ieee80211_device *ieee, int ieee80211_wx_get_name(struct ieee80211_device *ieee,
struct iw_request_info *info, struct iw_request_info *info, union iwreq_data *wrqu,
union iwreq_data *wrqu, char *extra) char *extra)
{ {
strlcpy(wrqu->name, "802.11", IFNAMSIZ); strlcpy(wrqu->name, "802.11", IFNAMSIZ);
if (ieee->modulation & IEEE80211_CCK_MODULATION) { if (ieee->modulation & IEEE80211_CCK_MODULATION) {
...@@ -464,8 +468,8 @@ int ieee80211_wx_get_name(struct ieee80211_device *ieee, ...@@ -464,8 +468,8 @@ int ieee80211_wx_get_name(struct ieee80211_device *ieee,
/* this is mostly stolen from hostap */ /* this is mostly stolen from hostap */
int ieee80211_wx_set_power(struct ieee80211_device *ieee, int ieee80211_wx_set_power(struct ieee80211_device *ieee,
struct iw_request_info *info, struct iw_request_info *info, union iwreq_data *wrqu,
union iwreq_data *wrqu, char *extra) char *extra)
{ {
int ret = 0; int ret = 0;
...@@ -525,8 +529,8 @@ int ieee80211_wx_set_power(struct ieee80211_device *ieee, ...@@ -525,8 +529,8 @@ int ieee80211_wx_set_power(struct ieee80211_device *ieee,
/* this is stolen from hostap */ /* this is stolen from hostap */
int ieee80211_wx_get_power(struct ieee80211_device *ieee, int ieee80211_wx_get_power(struct ieee80211_device *ieee,
struct iw_request_info *info, struct iw_request_info *info, union iwreq_data *wrqu,
union iwreq_data *wrqu, char *extra) char *extra)
{ {
int ret = 0; int ret = 0;
......
...@@ -177,10 +177,8 @@ static inline int ieee80211_put_snap(u8 *data, u16 h_proto) ...@@ -177,10 +177,8 @@ static inline int ieee80211_put_snap(u8 *data, u16 h_proto)
return SNAP_SIZE + sizeof(u16); return SNAP_SIZE + sizeof(u16);
} }
int ieee80211_encrypt_fragment( int ieee80211_encrypt_fragment(struct ieee80211_device *ieee,
struct ieee80211_device *ieee, struct sk_buff *frag, int hdr_len)
struct sk_buff *frag,
int hdr_len)
{ {
struct ieee80211_crypt_data* crypt = ieee->crypt[ieee->tx_keyidx]; struct ieee80211_crypt_data* crypt = ieee->crypt[ieee->tx_keyidx];
int res; int res;
...@@ -279,8 +277,8 @@ static struct ieee80211_txb *ieee80211_alloc_txb(int nr_frags, int txb_size, ...@@ -279,8 +277,8 @@ static struct ieee80211_txb *ieee80211_alloc_txb(int nr_frags, int txb_size,
* Classify the to-be send data packet * Classify the to-be send data packet
* Need to acquire the sent queue index. * Need to acquire the sent queue index.
*/ */
static int static int ieee80211_classify(struct sk_buff *skb,
ieee80211_classify(struct sk_buff *skb, struct ieee80211_network *network) struct ieee80211_network *network)
{ {
struct ether_header *eh = (struct ether_header *)skb->data; struct ether_header *eh = (struct ether_header *)skb->data;
unsigned int wme_UP = 0; unsigned int wme_UP = 0;
...@@ -310,8 +308,7 @@ ieee80211_classify(struct sk_buff *skb, struct ieee80211_network *network) ...@@ -310,8 +308,7 @@ ieee80211_classify(struct sk_buff *skb, struct ieee80211_network *network)
} }
/* SKBs are added to the ieee->tx_queue. */ /* SKBs are added to the ieee->tx_queue. */
int ieee80211_rtl_xmit(struct sk_buff *skb, int ieee80211_rtl_xmit(struct sk_buff *skb, struct net_device *dev)
struct net_device *dev)
{ {
struct ieee80211_device *ieee = netdev_priv(dev); struct ieee80211_device *ieee = netdev_priv(dev);
struct ieee80211_txb *txb = NULL; struct ieee80211_txb *txb = NULL;
......
...@@ -633,8 +633,8 @@ int ieee80211_wx_set_encode_ext(struct ieee80211_device *ieee, ...@@ -633,8 +633,8 @@ int ieee80211_wx_set_encode_ext(struct ieee80211_device *ieee,
return ret; return ret;
} }
int ieee80211_wx_set_mlme(struct ieee80211_device *ieee, int ieee80211_wx_set_mlme(struct ieee80211_device *ieee,
struct iw_request_info *info, struct iw_request_info *info,
union iwreq_data *wrqu, char *extra) union iwreq_data *wrqu, char *extra)
{ {
struct iw_mlme *mlme = (struct iw_mlme *) extra; struct iw_mlme *mlme = (struct iw_mlme *) extra;
// printk("\ndkgadfslkdjgalskdf===============>%s(), cmd:%x\n", __func__, mlme->cmd); // printk("\ndkgadfslkdjgalskdf===============>%s(), cmd:%x\n", __func__, mlme->cmd);
...@@ -653,8 +653,8 @@ int ieee80211_wx_set_mlme(struct ieee80211_device *ieee, ...@@ -653,8 +653,8 @@ int ieee80211_wx_set_mlme(struct ieee80211_device *ieee,
} }
int ieee80211_wx_set_auth(struct ieee80211_device *ieee, int ieee80211_wx_set_auth(struct ieee80211_device *ieee,
struct iw_request_info *info, struct iw_request_info *info,
struct iw_param *data, char *extra) struct iw_param *data, char *extra)
{ {
/* /*
struct ieee80211_security sec = { struct ieee80211_security sec = {
......
...@@ -639,20 +639,20 @@ typedef struct r8180_priv ...@@ -639,20 +639,20 @@ typedef struct r8180_priv
((_ac) == WME_AC_BK) ? BK_PRIORITY : \ ((_ac) == WME_AC_BK) ? BK_PRIORITY : \
BE_PRIORITY) BE_PRIORITY)
short rtl8180_tx(struct net_device *dev,u8* skbuf, int len,int priority, short rtl8180_tx(struct net_device *dev, u8 *skbuf, int len, int priority,
short morefrag,short fragdesc,int rate); short morefrag, short fragdesc, int rate);
u8 read_nic_byte(struct net_device *dev, int x); u8 read_nic_byte(struct net_device *dev, int x);
u32 read_nic_dword(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) ; 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_byte(struct net_device *dev, int x, u8 y);
void write_nic_word(struct net_device *dev, int x,u16 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_dword(struct net_device *dev, int x, u32 y);
void force_pci_posting(struct net_device *dev); void force_pci_posting(struct net_device *dev);
void rtl8180_rtx_disable(struct net_device *); void rtl8180_rtx_disable(struct net_device *);
void rtl8180_set_anaparam(struct net_device *dev,u32 a); void rtl8180_set_anaparam(struct net_device *dev, u32 a);
void rtl8185_set_anaparam2(struct net_device *dev,u32 a); void rtl8185_set_anaparam2(struct net_device *dev, u32 a);
void rtl8180_set_hw_wep(struct net_device *dev); void rtl8180_set_hw_wep(struct net_device *dev);
void rtl8180_no_hw_wep(struct net_device *dev); void rtl8180_no_hw_wep(struct net_device *dev);
void rtl8180_update_msr(struct net_device *dev); void rtl8180_update_msr(struct net_device *dev);
...@@ -661,7 +661,7 @@ void rtl8180_beacon_rx_disable(struct net_device *dev); ...@@ -661,7 +661,7 @@ void rtl8180_beacon_rx_disable(struct net_device *dev);
int rtl8180_down(struct net_device *dev); int rtl8180_down(struct net_device *dev);
int rtl8180_up(struct net_device *dev); int rtl8180_up(struct net_device *dev);
void rtl8180_commit(struct net_device *dev); void rtl8180_commit(struct net_device *dev);
void rtl8180_set_chan(struct net_device *dev,short ch); void rtl8180_set_chan(struct net_device *dev, short ch);
void write_phy(struct net_device *dev, u8 adr, u8 data); void write_phy(struct net_device *dev, u8 adr, u8 data);
void write_phy_cck(struct net_device *dev, u8 adr, u32 data); void write_phy_cck(struct net_device *dev, u8 adr, u32 data);
void write_phy_ofdm(struct net_device *dev, u8 adr, u32 data); void write_phy_ofdm(struct net_device *dev, u8 adr, u32 data);
...@@ -671,7 +671,8 @@ void IPSEnter(struct net_device *dev); ...@@ -671,7 +671,8 @@ void IPSEnter(struct net_device *dev);
void IPSLeave(struct net_device *dev); void IPSLeave(struct net_device *dev);
int get_curr_tx_free_desc(struct net_device *dev, int priority); int get_curr_tx_free_desc(struct net_device *dev, int priority);
void UpdateInitialGain(struct net_device *dev); void UpdateInitialGain(struct net_device *dev);
bool SetAntennaConfig87SE(struct net_device *dev, u8 DefaultAnt, bool bAntDiversity); bool SetAntennaConfig87SE(struct net_device *dev, u8 DefaultAnt,
bool bAntDiversity);
//#ifdef CONFIG_RTL8185B //#ifdef CONFIG_RTL8185B
void rtl8185b_adapter_start(struct net_device *dev); void rtl8185b_adapter_start(struct net_device *dev);
...@@ -684,7 +685,8 @@ void fix_tx_fifo(struct net_device *dev); ...@@ -684,7 +685,8 @@ void fix_tx_fifo(struct net_device *dev);
void rtl8225z2_SetTXPowerLevel(struct net_device *dev, short ch); void rtl8225z2_SetTXPowerLevel(struct net_device *dev, short ch);
void rtl8180_rate_adapter(struct work_struct * work); void rtl8180_rate_adapter(struct work_struct * work);
//#endif //#endif
bool MgntActSet_RF_State(struct net_device *dev, RT_RF_POWER_STATE StateToSet, u32 ChangeSource); bool MgntActSet_RF_State(struct net_device *dev, RT_RF_POWER_STATE StateToSet,
u32 ChangeSource);
#endif #endif
......
...@@ -79,7 +79,7 @@ module_param(hwwep, int, S_IRUGO|S_IWUSR); ...@@ -79,7 +79,7 @@ module_param(hwwep, int, S_IRUGO|S_IWUSR);
MODULE_PARM_DESC(hwwep, " Try to use hardware WEP support. Still broken and not available on all cards"); MODULE_PARM_DESC(hwwep, " Try to use hardware WEP support. Still broken and not available on all cards");
static int rtl8180_pci_probe(struct pci_dev *pdev, static int rtl8180_pci_probe(struct pci_dev *pdev,
const struct pci_device_id *id); const struct pci_device_id *id);
static void rtl8180_pci_remove(struct pci_dev *pdev); static void rtl8180_pci_remove(struct pci_dev *pdev);
...@@ -387,7 +387,8 @@ static short buffer_add(struct buffer **buffer, u32 *buf, dma_addr_t dma, ...@@ -387,7 +387,8 @@ static short buffer_add(struct buffer **buffer, u32 *buf, dma_addr_t dma,
return 0; return 0;
} }
void buffer_free(struct net_device *dev, struct buffer **buffer, int len, short consistent) void buffer_free(struct net_device *dev, struct buffer **buffer, int len,
short consistent)
{ {
struct buffer *tmp, *next; struct buffer *tmp, *next;
...@@ -2238,7 +2239,8 @@ static CHANNEL_LIST ChannelPlan[] = { ...@@ -2238,7 +2239,8 @@ static CHANNEL_LIST ChannelPlan[] = {
{{1,2,3,4,5,6,7,8,9,10,11,12,13},13} /* world wide 13: ch1~ch11 active scan, ch12~13 passive //lzm add 080826 */ {{1,2,3,4,5,6,7,8,9,10,11,12,13},13} /* world wide 13: ch1~ch11 active scan, ch12~13 passive //lzm add 080826 */
}; };
static void rtl8180_set_channel_map(u8 channel_plan, struct ieee80211_device *ieee) static void rtl8180_set_channel_map(u8 channel_plan,
struct ieee80211_device *ieee)
{ {
int i; int i;
...@@ -2830,11 +2832,8 @@ static struct net_device_stats *rtl8180_stats(struct net_device *dev) ...@@ -2830,11 +2832,8 @@ static struct net_device_stats *rtl8180_stats(struct net_device *dev)
/* /*
* Change current and default preamble mode. * Change current and default preamble mode.
*/ */
bool bool MgntActSet_802_11_PowerSaveMode(struct r8180_priv *priv,
MgntActSet_802_11_PowerSaveMode( RT_PS_MODE rtPsMode)
struct r8180_priv *priv,
RT_PS_MODE rtPsMode
)
{ {
/* Currently, we do not change power save mode on IBSS mode. */ /* Currently, we do not change power save mode on IBSS mode. */
if (priv->ieee80211->iw_mode == IW_MODE_ADHOC) if (priv->ieee80211->iw_mode == IW_MODE_ADHOC)
...@@ -3161,7 +3160,7 @@ static const struct net_device_ops rtl8180_netdev_ops = { ...@@ -3161,7 +3160,7 @@ static const struct net_device_ops rtl8180_netdev_ops = {
}; };
static int rtl8180_pci_probe(struct pci_dev *pdev, static int rtl8180_pci_probe(struct pci_dev *pdev,
const struct pci_device_id *id) const struct pci_device_id *id)
{ {
unsigned long ioaddr = 0; unsigned long ioaddr = 0;
struct net_device *dev = NULL; struct net_device *dev = NULL;
......
...@@ -5,7 +5,7 @@ ...@@ -5,7 +5,7 @@
/* #include "r8180_hw.h" */ /* #include "r8180_hw.h" */
/* #include "r8180_93cx6.h" */ /* #include "r8180_93cx6.h" */
void SwAntennaDiversityRxOk8185(struct net_device *dev, u8 SignalStrength); void SwAntennaDiversityRxOk8185(struct net_device *dev, u8 SignalStrength);
bool SetAntenna8185(struct net_device *dev, u8 u1bAntennaIndex); bool SetAntenna8185(struct net_device *dev, u8 u1bAntennaIndex);
bool SwitchAntenna(struct net_device *dev); bool SwitchAntenna(struct net_device *dev);
void SwAntennaDiversity(struct net_device *dev); void SwAntennaDiversity(struct net_device *dev);
void SwAntennaDiversityTimerCallback(struct net_device *dev); void SwAntennaDiversityTimerCallback(struct net_device *dev);
......
...@@ -28,7 +28,8 @@ u16 RF_ReadReg(struct net_device *dev, u8 offset); ...@@ -28,7 +28,8 @@ u16 RF_ReadReg(struct net_device *dev, u8 offset);
void rtl8180_set_mode(struct net_device *dev, int mode); void rtl8180_set_mode(struct net_device *dev, int mode);
void rtl8180_set_mode(struct net_device *dev, int mode); void rtl8180_set_mode(struct net_device *dev, int mode);
bool SetZebraRFPowerState8185(struct net_device *dev, RT_RF_POWER_STATE eRFPowerState); bool SetZebraRFPowerState8185(struct net_device *dev,
RT_RF_POWER_STATE eRFPowerState);
void rtl8225z4_rf_sleep(struct net_device *dev); void rtl8225z4_rf_sleep(struct net_device *dev);
void rtl8225z4_rf_wakeup(struct net_device *dev); void rtl8225z4_rf_wakeup(struct net_device *dev);
...@@ -75,8 +75,9 @@ static int r8180_wx_set_key(struct net_device *dev, ...@@ -75,8 +75,9 @@ static int r8180_wx_set_key(struct net_device *dev,
} }
static int r8180_wx_set_beaconinterval(struct net_device *dev, struct iw_request_info *aa, static int r8180_wx_set_beaconinterval(struct net_device *dev,
union iwreq_data *wrqu, char *b) struct iw_request_info *aa,
union iwreq_data *wrqu, char *b)
{ {
int *parms = (int *)b; int *parms = (int *)b;
int bi = parms[0]; int bi = parms[0];
...@@ -474,9 +475,8 @@ static int r8180_wx_get_frag(struct net_device *dev, ...@@ -474,9 +475,8 @@ static int r8180_wx_get_frag(struct net_device *dev,
static int r8180_wx_set_wap(struct net_device *dev, static int r8180_wx_set_wap(struct net_device *dev,
struct iw_request_info *info, struct iw_request_info *info,
union iwreq_data *awrq, union iwreq_data *awrq, char *extra)
char *extra)
{ {
int ret; int ret;
struct r8180_priv *priv = ieee80211_priv(dev); struct r8180_priv *priv = ieee80211_priv(dev);
...@@ -538,8 +538,10 @@ static int r8180_wx_get_enc(struct net_device *dev, ...@@ -538,8 +538,10 @@ static int r8180_wx_get_enc(struct net_device *dev,
} }
static int r8180_wx_set_scan_type(struct net_device *dev, struct iw_request_info *aa, union static int r8180_wx_set_scan_type(struct net_device *dev,
iwreq_data *wrqu, char *p) { struct iw_request_info *aa,
union iwreq_data *wrqu, char *p)
{
struct r8180_priv *priv = ieee80211_priv(dev); struct r8180_priv *priv = ieee80211_priv(dev);
int *parms = (int*)p; int *parms = (int*)p;
...@@ -554,8 +556,8 @@ static int r8180_wx_set_scan_type(struct net_device *dev, struct iw_request_info ...@@ -554,8 +556,8 @@ static int r8180_wx_set_scan_type(struct net_device *dev, struct iw_request_info
} }
static int r8180_wx_set_retry(struct net_device *dev, static int r8180_wx_set_retry(struct net_device *dev,
struct iw_request_info *info, struct iw_request_info *info,
union iwreq_data *wrqu, char *extra) union iwreq_data *wrqu, char *extra)
{ {
struct r8180_priv *priv = ieee80211_priv(dev); struct r8180_priv *priv = ieee80211_priv(dev);
int err = 0; int err = 0;
...@@ -602,8 +604,8 @@ static int r8180_wx_set_retry(struct net_device *dev, ...@@ -602,8 +604,8 @@ static int r8180_wx_set_retry(struct net_device *dev,
} }
static int r8180_wx_get_retry(struct net_device *dev, static int r8180_wx_get_retry(struct net_device *dev,
struct iw_request_info *info, struct iw_request_info *info,
union iwreq_data *wrqu, char *extra) union iwreq_data *wrqu, char *extra)
{ {
struct r8180_priv *priv = ieee80211_priv(dev); struct r8180_priv *priv = ieee80211_priv(dev);
...@@ -626,8 +628,8 @@ static int r8180_wx_get_retry(struct net_device *dev, ...@@ -626,8 +628,8 @@ static int r8180_wx_get_retry(struct net_device *dev,
} }
static int r8180_wx_get_sens(struct net_device *dev, static int r8180_wx_get_sens(struct net_device *dev,
struct iw_request_info *info, struct iw_request_info *info,
union iwreq_data *wrqu, char *extra) union iwreq_data *wrqu, char *extra)
{ {
struct r8180_priv *priv = ieee80211_priv(dev); struct r8180_priv *priv = ieee80211_priv(dev);
if (priv->rf_set_sens == NULL) if (priv->rf_set_sens == NULL)
...@@ -638,8 +640,8 @@ static int r8180_wx_get_sens(struct net_device *dev, ...@@ -638,8 +640,8 @@ static int r8180_wx_get_sens(struct net_device *dev,
static int r8180_wx_set_sens(struct net_device *dev, static int r8180_wx_set_sens(struct net_device *dev,
struct iw_request_info *info, struct iw_request_info *info,
union iwreq_data *wrqu, char *extra) union iwreq_data *wrqu, char *extra)
{ {
struct r8180_priv *priv = ieee80211_priv(dev); struct r8180_priv *priv = ieee80211_priv(dev);
...@@ -667,8 +669,8 @@ static int r8180_wx_set_sens(struct net_device *dev, ...@@ -667,8 +669,8 @@ static int r8180_wx_set_sens(struct net_device *dev,
static int r8180_wx_set_rawtx(struct net_device *dev, static int r8180_wx_set_rawtx(struct net_device *dev,
struct iw_request_info *info, struct iw_request_info *info,
union iwreq_data *wrqu, char *extra) union iwreq_data *wrqu, char *extra)
{ {
struct r8180_priv *priv = ieee80211_priv(dev); struct r8180_priv *priv = ieee80211_priv(dev);
int ret; int ret;
...@@ -687,8 +689,8 @@ static int r8180_wx_set_rawtx(struct net_device *dev, ...@@ -687,8 +689,8 @@ static int r8180_wx_set_rawtx(struct net_device *dev,
} }
static int r8180_wx_get_power(struct net_device *dev, static int r8180_wx_get_power(struct net_device *dev,
struct iw_request_info *info, struct iw_request_info *info,
union iwreq_data *wrqu, char *extra) union iwreq_data *wrqu, char *extra)
{ {
int ret; int ret;
struct r8180_priv *priv = ieee80211_priv(dev); struct r8180_priv *priv = ieee80211_priv(dev);
...@@ -703,8 +705,8 @@ static int r8180_wx_get_power(struct net_device *dev, ...@@ -703,8 +705,8 @@ static int r8180_wx_get_power(struct net_device *dev,
} }
static int r8180_wx_set_power(struct net_device *dev, static int r8180_wx_set_power(struct net_device *dev,
struct iw_request_info *info, struct iw_request_info *info,
union iwreq_data *wrqu, char *extra) union iwreq_data *wrqu, char *extra)
{ {
int ret; int ret;
struct r8180_priv *priv = ieee80211_priv(dev); struct r8180_priv *priv = ieee80211_priv(dev);
...@@ -729,8 +731,8 @@ static int r8180_wx_set_power(struct net_device *dev, ...@@ -729,8 +731,8 @@ static int r8180_wx_set_power(struct net_device *dev,
} }
static int r8180_wx_set_rts(struct net_device *dev, static int r8180_wx_set_rts(struct net_device *dev,
struct iw_request_info *info, struct iw_request_info *info,
union iwreq_data *wrqu, char *extra) union iwreq_data *wrqu, char *extra)
{ {
struct r8180_priv *priv = ieee80211_priv(dev); struct r8180_priv *priv = ieee80211_priv(dev);
...@@ -751,8 +753,8 @@ static int r8180_wx_set_rts(struct net_device *dev, ...@@ -751,8 +753,8 @@ static int r8180_wx_set_rts(struct net_device *dev,
return 0; return 0;
} }
static int r8180_wx_get_rts(struct net_device *dev, static int r8180_wx_get_rts(struct net_device *dev,
struct iw_request_info *info, struct iw_request_info *info,
union iwreq_data *wrqu, char *extra) union iwreq_data *wrqu, char *extra)
{ {
struct r8180_priv *priv = ieee80211_priv(dev); struct r8180_priv *priv = ieee80211_priv(dev);
...@@ -842,8 +844,8 @@ static int r8180_wx_set_iwmode(struct net_device *dev, ...@@ -842,8 +844,8 @@ static int r8180_wx_set_iwmode(struct net_device *dev,
return ret; return ret;
} }
static int r8180_wx_get_preamble(struct net_device *dev, static int r8180_wx_get_preamble(struct net_device *dev,
struct iw_request_info *info, struct iw_request_info *info,
union iwreq_data *wrqu, char *extra) union iwreq_data *wrqu, char *extra)
{ {
struct r8180_priv *priv = ieee80211_priv(dev); struct r8180_priv *priv = ieee80211_priv(dev);
...@@ -859,8 +861,8 @@ static int r8180_wx_get_preamble(struct net_device *dev, ...@@ -859,8 +861,8 @@ static int r8180_wx_get_preamble(struct net_device *dev,
return 0; return 0;
} }
static int r8180_wx_set_preamble(struct net_device *dev, static int r8180_wx_set_preamble(struct net_device *dev,
struct iw_request_info *info, struct iw_request_info *info,
union iwreq_data *wrqu, char *extra) union iwreq_data *wrqu, char *extra)
{ {
struct r8180_priv *priv = ieee80211_priv(dev); struct r8180_priv *priv = ieee80211_priv(dev);
int ret = 0; int ret = 0;
...@@ -882,8 +884,8 @@ static int r8180_wx_set_preamble(struct net_device *dev, ...@@ -882,8 +884,8 @@ static int r8180_wx_set_preamble(struct net_device *dev,
return ret; return ret;
} }
static int r8180_wx_get_siglevel(struct net_device *dev, static int r8180_wx_get_siglevel(struct net_device *dev,
struct iw_request_info *info, struct iw_request_info *info,
union iwreq_data *wrqu, char *extra) union iwreq_data *wrqu, char *extra)
{ {
struct r8180_priv *priv = ieee80211_priv(dev); struct r8180_priv *priv = ieee80211_priv(dev);
int ret = 0; int ret = 0;
...@@ -901,8 +903,8 @@ static int r8180_wx_get_siglevel(struct net_device *dev, ...@@ -901,8 +903,8 @@ static int r8180_wx_get_siglevel(struct net_device *dev,
return ret; return ret;
} }
static int r8180_wx_get_sigqual(struct net_device *dev, static int r8180_wx_get_sigqual(struct net_device *dev,
struct iw_request_info *info, struct iw_request_info *info,
union iwreq_data *wrqu, char *extra) union iwreq_data *wrqu, char *extra)
{ {
struct r8180_priv *priv = ieee80211_priv(dev); struct r8180_priv *priv = ieee80211_priv(dev);
int ret = 0; int ret = 0;
...@@ -960,8 +962,8 @@ static int r8180_wx_reset_stats(struct net_device *dev, ...@@ -960,8 +962,8 @@ static int r8180_wx_reset_stats(struct net_device *dev,
} }
static int r8180_wx_radio_on(struct net_device *dev, static int r8180_wx_radio_on(struct net_device *dev,
struct iw_request_info *info, struct iw_request_info *info,
union iwreq_data *wrqu, char *extra) union iwreq_data *wrqu, char *extra)
{ {
struct r8180_priv *priv = ieee80211_priv(dev); struct r8180_priv *priv = ieee80211_priv(dev);
...@@ -979,8 +981,8 @@ static int r8180_wx_radio_on(struct net_device *dev, ...@@ -979,8 +981,8 @@ static int r8180_wx_radio_on(struct net_device *dev,
} }
static int r8180_wx_radio_off(struct net_device *dev, static int r8180_wx_radio_off(struct net_device *dev,
struct iw_request_info *info, struct iw_request_info *info,
union iwreq_data *wrqu, char *extra) union iwreq_data *wrqu, char *extra)
{ {
struct r8180_priv *priv = ieee80211_priv(dev); struct r8180_priv *priv = ieee80211_priv(dev);
...@@ -997,8 +999,8 @@ static int r8180_wx_radio_off(struct net_device *dev, ...@@ -997,8 +999,8 @@ static int r8180_wx_radio_off(struct net_device *dev,
} }
static int r8180_wx_get_channelplan(struct net_device *dev, static int r8180_wx_get_channelplan(struct net_device *dev,
struct iw_request_info *info, struct iw_request_info *info,
union iwreq_data *wrqu, char *extra) union iwreq_data *wrqu, char *extra)
{ {
struct r8180_priv *priv = ieee80211_priv(dev); struct r8180_priv *priv = ieee80211_priv(dev);
...@@ -1014,8 +1016,8 @@ static int r8180_wx_get_channelplan(struct net_device *dev, ...@@ -1014,8 +1016,8 @@ static int r8180_wx_get_channelplan(struct net_device *dev,
return 0; return 0;
} }
static int r8180_wx_set_channelplan(struct net_device *dev, static int r8180_wx_set_channelplan(struct net_device *dev,
struct iw_request_info *info, struct iw_request_info *info,
union iwreq_data *wrqu, char *extra) union iwreq_data *wrqu, char *extra)
{ {
struct r8180_priv *priv = ieee80211_priv(dev); struct r8180_priv *priv = ieee80211_priv(dev);
int *val = (int *)extra; int *val = (int *)extra;
...@@ -1044,8 +1046,8 @@ static int r8180_wx_set_channelplan(struct net_device *dev, ...@@ -1044,8 +1046,8 @@ static int r8180_wx_set_channelplan(struct net_device *dev,
} }
static int r8180_wx_get_version(struct net_device *dev, static int r8180_wx_get_version(struct net_device *dev,
struct iw_request_info *info, struct iw_request_info *info,
union iwreq_data *wrqu, char *extra) union iwreq_data *wrqu, char *extra)
{ {
struct r8180_priv *priv = ieee80211_priv(dev); struct r8180_priv *priv = ieee80211_priv(dev);
/* struct ieee80211_device *ieee; */ /* struct ieee80211_device *ieee; */
...@@ -1060,8 +1062,8 @@ static int r8180_wx_get_version(struct net_device *dev, ...@@ -1060,8 +1062,8 @@ static int r8180_wx_get_version(struct net_device *dev,
/* added by amy 080818 */ /* added by amy 080818 */
/*receive datarate from user typing valid rate is from 2 to 108 (1 - 54M), if input 0, return to normal rate adaptive. */ /*receive datarate from user typing valid rate is from 2 to 108 (1 - 54M), if input 0, return to normal rate adaptive. */
static int r8180_wx_set_forcerate(struct net_device *dev, static int r8180_wx_set_forcerate(struct net_device *dev,
struct iw_request_info *info, struct iw_request_info *info,
union iwreq_data *wrqu, char *extra) union iwreq_data *wrqu, char *extra)
{ {
struct r8180_priv *priv = ieee80211_priv(dev); struct r8180_priv *priv = ieee80211_priv(dev);
u8 forcerate = *extra; u8 forcerate = *extra;
...@@ -1085,8 +1087,8 @@ static int r8180_wx_set_forcerate(struct net_device *dev, ...@@ -1085,8 +1087,8 @@ static int r8180_wx_set_forcerate(struct net_device *dev,
} }
static int r8180_wx_set_enc_ext(struct net_device *dev, static int r8180_wx_set_enc_ext(struct net_device *dev,
struct iw_request_info *info, struct iw_request_info *info,
union iwreq_data *wrqu, char *extra) union iwreq_data *wrqu, char *extra)
{ {
struct r8180_priv *priv = ieee80211_priv(dev); struct r8180_priv *priv = ieee80211_priv(dev);
...@@ -1119,8 +1121,8 @@ static int r8180_wx_set_auth(struct net_device *dev, ...@@ -1119,8 +1121,8 @@ static int r8180_wx_set_auth(struct net_device *dev,
} }
static int r8180_wx_set_mlme(struct net_device *dev, static int r8180_wx_set_mlme(struct net_device *dev,
struct iw_request_info *info, struct iw_request_info *info,
union iwreq_data *wrqu, char *extra) union iwreq_data *wrqu, char *extra)
{ {
int ret = 0; int ret = 0;
struct r8180_priv *priv = ieee80211_priv(dev); struct r8180_priv *priv = ieee80211_priv(dev);
...@@ -1334,7 +1336,7 @@ static iw_handler r8180_private_handler[] = { ...@@ -1334,7 +1336,7 @@ static iw_handler r8180_private_handler[] = {
}; };
static inline int is_same_network(struct ieee80211_network *src, static inline int is_same_network(struct ieee80211_network *src,
struct ieee80211_network *dst, struct ieee80211_network *dst,
struct ieee80211_device *ieee) struct ieee80211_device *ieee)
{ {
/* A network is only a duplicate if the channel, BSSID, ESSID /* A network is only a duplicate if the channel, BSSID, ESSID
......
...@@ -870,9 +870,10 @@ static u8 GetSupportedWirelessMode8185(struct net_device *dev) ...@@ -870,9 +870,10 @@ static u8 GetSupportedWirelessMode8185(struct net_device *dev)
return WIRELESS_MODE_B | WIRELESS_MODE_G; return WIRELESS_MODE_B | WIRELESS_MODE_G;
} }
static void ActUpdateChannelAccessSetting(struct net_device *dev, static void
WIRELESS_MODE WirelessMode, ActUpdateChannelAccessSetting(struct net_device *dev,
PCHANNEL_ACCESS_SETTING ChnlAccessSetting) WIRELESS_MODE WirelessMode,
PCHANNEL_ACCESS_SETTING ChnlAccessSetting)
{ {
AC_CODING eACI; AC_CODING eACI;
...@@ -1084,7 +1085,7 @@ static bool MgntDisconnect(struct net_device *dev, u8 asRsn) ...@@ -1084,7 +1085,7 @@ static bool MgntDisconnect(struct net_device *dev, u8 asRsn)
* PASSIVE LEVEL. * PASSIVE LEVEL.
*/ */
static bool SetRFPowerState(struct net_device *dev, static bool SetRFPowerState(struct net_device *dev,
RT_RF_POWER_STATE eRFPowerState) RT_RF_POWER_STATE eRFPowerState)
{ {
struct r8180_priv *priv = (struct r8180_priv *)ieee80211_priv(dev); struct r8180_priv *priv = (struct r8180_priv *)ieee80211_priv(dev);
bool bResult = false; bool bResult = false;
...@@ -1097,8 +1098,8 @@ static bool SetRFPowerState(struct net_device *dev, ...@@ -1097,8 +1098,8 @@ static bool SetRFPowerState(struct net_device *dev,
return bResult; return bResult;
} }
bool MgntActSet_RF_State(struct net_device *dev, bool MgntActSet_RF_State(struct net_device *dev, RT_RF_POWER_STATE StateToSet,
RT_RF_POWER_STATE StateToSet, u32 ChangeSource) u32 ChangeSource)
{ {
struct r8180_priv *priv = (struct r8180_priv *)ieee80211_priv(dev); struct r8180_priv *priv = (struct r8180_priv *)ieee80211_priv(dev);
bool bActionAllowed = false; bool bActionAllowed = false;
......
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