rtl8188eu: More Sparse fixes

There are only a few more left. Most are in the P2P code

Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net>
This commit is contained in:
Larry Finger 2015-01-29 21:41:53 -06:00
parent 481d6c817d
commit 5b8f5bc69d
22 changed files with 212 additions and 393 deletions

View file

@ -29,22 +29,10 @@
#include <net/ip6_checksum.h>
#endif
#if 1 // rtw_wifi_driver
#include <drv_conf.h>
#include <drv_types.h>
#include "rtw_br_ext.h"
#else // rtw_wifi_driver
#include "./8192cd_cfg.h"
#ifndef __KERNEL__
#include "./sys-support.h"
#endif
#include "./8192cd.h"
#include "./8192cd_headers.h"
#include "./8192cd_br_ext.h"
#include "./8192cd_debug.h"
#endif // rtw_wifi_driver
#include <usb_osintf.h>
#ifdef CL_IPV6_PASS
#ifdef __KERNEL__
@ -99,7 +87,7 @@ static __inline__ unsigned char *__nat25_find_pppoe_tag(struct pppoe_hdr *ph, un
return cur_ptr;
cur_ptr = cur_ptr + TAG_HDR_LEN + tagLen;
}
return 0;
return NULL;
}
@ -1296,7 +1284,7 @@ int nat25_db_handle(struct adapter *priv, struct sk_buff *skb, int method)
unsigned short tagType, tagLen;
int offset=0;
if((ptr = __nat25_find_pppoe_tag(ph, ntohs(PTT_RELAY_SID))) == 0) {
if((ptr = __nat25_find_pppoe_tag(ph, ntohs(PTT_RELAY_SID))) == NULL) {
DEBUG_ERR("Fail to find PTT_RELAY_SID in FADO!\n");
return -1;
}

View file

@ -2423,7 +2423,7 @@ exit:
#endif
#if (RATE_ADAPTIVE_SUPPORT==1)
void rpt_timer_setting_wk_hdl(struct adapter *padapter, u16 minRptTime)
static void rpt_timer_setting_wk_hdl(struct adapter *padapter, u16 minRptTime)
{
rtw_hal_set_hwreg(padapter, HW_VAR_RPT_TIMER_SETTING, (u8 *)(&minRptTime));
}
@ -2466,7 +2466,7 @@ exit:
#endif
#ifdef CONFIG_ANTENNA_DIVERSITY
void antenna_select_wk_hdl(struct adapter *padapter, u8 antenna)
static void antenna_select_wk_hdl(struct adapter *padapter, u8 antenna)
{
rtw_hal_set_hwreg(padapter, HW_VAR_ANTENNA_DIVERSITY_SELECT, (u8 *)(&antenna));
}
@ -2524,12 +2524,12 @@ void power_saving_wk_hdl(struct adapter *padapter, u8 *pbuf, int sz)
}
//add for CONFIG_IEEE80211W, none 11w can use it
void reset_securitypriv_hdl(struct adapter *padapter)
static void reset_securitypriv_hdl(struct adapter *padapter)
{
rtw_reset_securitypriv(padapter);
}
void free_assoc_resources_hdl(struct adapter *padapter)
static void free_assoc_resources_hdl(struct adapter *padapter)
{
rtw_free_assoc_resources(padapter, 1);
}
@ -2738,7 +2738,7 @@ exit:
return res;
}
s32 c2h_evt_hdl(struct adapter *adapter, struct c2h_evt_hdr *c2h_evt, c2h_id_filter filter)
static s32 c2h_evt_hdl(struct adapter *adapter, struct c2h_evt_hdr *c2h_evt, c2h_id_filter filter)
{
s32 ret = _FAIL;
u8 buf[16];

View file

@ -98,7 +98,7 @@ int proc_get_write_reg(char *page, char **start,
return 0;
}
int proc_set_write_reg(struct file *file, const char *buffer,
int proc_set_write_reg(struct file *file, const char __user *buffer,
unsigned long count, void *data)
{
struct net_device *dev = (struct net_device *)data;
@ -182,7 +182,7 @@ int proc_get_read_reg(char *page, char **start,
}
int proc_set_read_reg(struct file *file, const char *buffer,
int proc_set_read_reg(struct file *file, const char __user *buffer,
unsigned long count, void *data)
{
char tmp[16];
@ -675,7 +675,7 @@ int proc_get_rx_signal(char *page, char **start,
return len;
}
int proc_set_rx_signal(struct file *file, const char *buffer,
int proc_set_rx_signal(struct file *file, const char __user *buffer,
unsigned long count, void *data)
{
struct net_device *dev = (struct net_device *)data;
@ -733,7 +733,7 @@ int proc_get_ht_enable(char *page, char **start,
return len;
}
int proc_set_ht_enable(struct file *file, const char *buffer,
int proc_set_ht_enable(struct file *file, const char __user *buffer,
unsigned long count, void *data)
{
struct net_device *dev = (struct net_device *)data;
@ -780,7 +780,7 @@ int proc_get_cbw40_enable(char *page, char **start,
return len;
}
int proc_set_cbw40_enable(struct file *file, const char *buffer,
int proc_set_cbw40_enable(struct file *file, const char __user *buffer,
unsigned long count, void *data)
{
struct net_device *dev = (struct net_device *)data;
@ -829,7 +829,7 @@ int proc_get_ampdu_enable(char *page, char **start,
return len;
}
int proc_set_ampdu_enable(struct file *file, const char *buffer,
int proc_set_ampdu_enable(struct file *file, const char __user *buffer,
unsigned long count, void *data)
{
struct net_device *dev = (struct net_device *)data;
@ -898,7 +898,7 @@ int proc_get_rx_stbc(char *page, char **start,
return len;
}
int proc_set_rx_stbc(struct file *file, const char *buffer,
int proc_set_rx_stbc(struct file *file, const char __user *buffer,
unsigned long count, void *data)
{
struct net_device *dev = (struct net_device *)data;
@ -935,7 +935,7 @@ int proc_get_rssi_disp(char *page, char **start,
return 0;
}
int proc_set_rssi_disp(struct file *file, const char *buffer,
int proc_set_rssi_disp(struct file *file, const char __user *buffer,
unsigned long count, void *data)
{
struct net_device *dev = (struct net_device *)data;
@ -1133,7 +1133,7 @@ int proc_get_best_channel(char *page, char **start,
}
int proc_set_best_channel(struct file *file, const char *buffer,
int proc_set_best_channel(struct file *file, const char __user *buffer,
unsigned long count, void *data)
{
struct net_device *dev = (struct net_device *)data;
@ -1183,7 +1183,7 @@ int proc_get_btcoex_dbg(char *page, char **start,
return len;
}
int proc_set_btcoex_dbg(struct file *file, const char *buffer,
int proc_set_btcoex_dbg(struct file *file, const char __user *buffer,
unsigned long count, void *data)
{
struct net_device *dev = (struct net_device *)data;
@ -1225,7 +1225,7 @@ int proc_get_sreset(char *page, char **start, off_t offset, int count, int *eof,
return len;
}
int proc_set_sreset(struct file *file, const char *buffer, unsigned long count, void *data)
int proc_set_sreset(struct file *file, const char __user *buffer, unsigned long count, void *data)
{
struct net_device *dev = (struct net_device *)data;
struct adapter *padapter = (struct adapter *)rtw_netdev_priv(dev);
@ -1262,7 +1262,7 @@ int proc_get_odm_dbg_comp(char *page, char **start, off_t offset, int count, int
return len;
}
int proc_set_odm_dbg_comp(struct file *file, const char *buffer, unsigned long count, void *data)
int proc_set_odm_dbg_comp(struct file *file, const char __user *buffer, unsigned long count, void *data)
{
struct net_device *dev = (struct net_device *)data;
struct adapter *adapter = (struct adapter *)rtw_netdev_priv(dev);
@ -1298,7 +1298,7 @@ int proc_get_odm_dbg_level(char *page, char **start, off_t offset, int count, in
return len;
}
int proc_set_odm_dbg_level(struct file *file, const char *buffer, unsigned long count, void *data)
int proc_set_odm_dbg_level(struct file *file, const char __user *buffer, unsigned long count, void *data)
{
struct net_device *dev = (struct net_device *)data;
struct adapter *adapter = (struct adapter *)rtw_netdev_priv(dev);
@ -1334,7 +1334,7 @@ int proc_get_odm_adaptivity(char *page, char **start, off_t offset, int count, i
return len;
}
int proc_set_odm_adaptivity(struct file *file, const char *buffer, unsigned long count, void *data)
int proc_set_odm_adaptivity(struct file *file, const char __user *buffer, unsigned long count, void *data)
{
struct net_device *dev = (struct net_device *)data;
struct adapter *padapter = (struct adapter *)rtw_netdev_priv(dev);

View file

@ -525,7 +525,7 @@ Efuse_PgPacketWrite(IN struct adapter *pAdapter,
}
int
static int
Efuse_PgPacketWrite_BT(IN struct adapter *pAdapter,
IN u8 offset,
IN u8 word_en,

View file

@ -1933,7 +1933,7 @@ int ieee80211_get_hdrlen(u16 fc)
return hdrlen;
}
int rtw_get_cipher_info(struct wlan_network *pnetwork)
static int rtw_get_cipher_info(struct wlan_network *pnetwork)
{
u32 wpa_ielen;
unsigned char *pbuf;

View file

@ -122,10 +122,7 @@ DeInitLed871x(
#define CONFIG_LED_REMOVE_HAL
void
SwLedBlink(
PLED_871x pLed
)
static void SwLedBlink(PLED_871x pLed)
{
struct adapter *padapter = pLed->padapter;
struct mlme_priv *pmlmepriv = &(padapter->mlmepriv);
@ -240,10 +237,7 @@ SwLedBlink(
}
}
void
SwLedBlink1(
PLED_871x pLed
)
static void SwLedBlink1(PLED_871x pLed)
{
struct adapter *padapter = pLed->padapter;
#ifndef CONFIG_LED_REMOVE_HAL
@ -449,13 +443,9 @@ SwLedBlink1(
default:
break;
}
}
void
SwLedBlink2(
PLED_871x pLed
)
static void SwLedBlink2(PLED_871x pLed)
{
struct adapter *padapter = pLed->padapter;
struct mlme_priv *pmlmepriv = &(padapter->mlmepriv);
@ -574,10 +564,7 @@ SwLedBlink2(
}
void
SwLedBlink3(
PLED_871x pLed
)
static void SwLedBlink3(PLED_871x pLed)
{
struct adapter *padapter = pLed->padapter;
struct mlme_priv *pmlmepriv = &(padapter->mlmepriv);
@ -741,14 +728,9 @@ SwLedBlink3(
default:
break;
}
}
void
SwLedBlink4(
PLED_871x pLed
)
static void SwLedBlink4(PLED_871x pLed)
{
struct adapter *padapter = pLed->padapter;
struct led_priv *ledpriv = &(padapter->ledpriv);
@ -940,14 +922,9 @@ SwLedBlink4(
}
RT_TRACE(_module_rtl8712_led_c_,_drv_info_,("SwLedBlink4 CurrLedState %d\n", pLed->CurrLedState));
}
void
SwLedBlink5(
PLED_871x pLed
)
static void SwLedBlink5(PLED_871x pLed)
{
struct adapter *padapter = pLed->padapter;
struct mlme_priv *pmlmepriv = &(padapter->mlmepriv);
@ -1058,14 +1035,9 @@ SwLedBlink5(
}
RT_TRACE(_module_rtl8712_led_c_,_drv_info_,("SwLedBlink5 CurrLedState %d\n", pLed->CurrLedState));
}
void
SwLedBlink6(
PLED_871x pLed
)
static void SwLedBlink6(PLED_871x pLed)
{
struct adapter *padapter = pLed->padapter;
struct mlme_priv *pmlmepriv = &(padapter->mlmepriv);

View file

@ -31,6 +31,7 @@
#include <wifi.h>
#include <wlan_bssdef.h>
#include <rtw_ioctl_set.h>
#include <usb_osintf.h>
extern void indicate_wx_scan_complete_event(struct adapter *padapter);
extern u8 rtw_do_join(struct adapter * padapter);
@ -2468,7 +2469,6 @@ void rtw_dynamic_check_timer_handlder(struct adapter *adapter)
&& (check_fwstate(pmlmepriv, WIFI_STATION_STATE|WIFI_ADHOC_STATE) == true) )
{
// expire NAT2.5 entry
void nat25_db_expire(struct adapter *priv);
nat25_db_expire(adapter);
if (adapter->pppoe_connection_in_progress > 0) {

View file

@ -119,7 +119,7 @@ extern void autosuspend_enter(struct adapter* padapter);
extern int autoresume_enter(struct adapter* padapter);
#endif
bool rtw_pwr_unassociated_idle(struct adapter *adapter)
static bool rtw_pwr_unassociated_idle(struct adapter *adapter)
{
struct adapter *buddy = adapter->pbuddy_adapter;
struct mlme_priv *pmlmepriv = &(adapter->mlmepriv);
@ -328,7 +328,7 @@ exit:
return;
}
void pwr_state_check_handler(void *FunctionContext)
static void pwr_state_check_handler(void *FunctionContext)
{
struct adapter *padapter = (struct adapter *)FunctionContext;
rtw_ps_cmd(padapter);

View file

@ -27,6 +27,7 @@
#include <if_ether.h>
#include <ethernet.h>
#include <usb_ops.h>
#include <usb_osintf.h>
#ifdef CONFIG_BT_COEXIST
#include <rtl8723a_hal.h>
@ -591,20 +592,16 @@ exit:
}
//decrypt and set the ivlen,icvlen of the recv_frame
union recv_frame * decryptor(struct adapter *padapter,union recv_frame *precv_frame);
union recv_frame * decryptor(struct adapter *padapter,union recv_frame *precv_frame)
static union recv_frame *decryptor(struct adapter *padapter,union recv_frame *precv_frame)
{
struct rx_pkt_attrib *prxattrib = &precv_frame->u.hdr.attrib;
struct security_priv *psecuritypriv=&padapter->securitypriv;
union recv_frame *return_packet=precv_frame;
u32 res=_SUCCESS;
;
RT_TRACE(_module_rtl871x_recv_c_,_drv_info_,("prxstat->decrypted=%x prxattrib->encrypt = 0x%03x\n",prxattrib->bdecrypted,prxattrib->encrypt));
if(prxattrib->encrypt>0)
{
if(prxattrib->encrypt>0) {
u8 *iv = precv_frame->u.hdr.rx_data+prxattrib->hdrlen;
prxattrib->key_index = ( ((iv[3])>>6)&0x3) ;
@ -693,7 +690,7 @@ union recv_frame * decryptor(struct adapter *padapter,union recv_frame *precv_fr
}
//###set the security information in the recv_frame
union recv_frame * portctrl(struct adapter *adapter,union recv_frame * precv_frame)
static union recv_frame * portctrl(struct adapter *adapter,union recv_frame * precv_frame)
{
u8 *psta_addr, *ptr;
uint auth_alg;
@ -2463,7 +2460,7 @@ exit:
//perform defrag
union recv_frame * recvframe_defrag(struct adapter *adapter,_queue *defrag_q)
static union recv_frame * recvframe_defrag(struct adapter *adapter,_queue *defrag_q)
{
_list *plist, *phead;
u8 *data,wlanhdr_offset;
@ -2826,7 +2823,6 @@ int amsdu_to_msdu(struct adapter *padapter, union recv_frame *prframe)
if( br_port && (check_fwstate(pmlmepriv, WIFI_STATION_STATE|WIFI_ADHOC_STATE) == true) )
{
int nat25_handle_frame(struct adapter *priv, struct sk_buff *skb);
if (nat25_handle_frame(padapter, sub_skb) == -1) {
//priv->ext_stats.rx_data_drops++;
//DEBUG_ERR("RX DROP: nat25_handle_frame fail!\n");
@ -2867,7 +2863,7 @@ exit:
return ret;
}
int check_indicate_seq(struct recv_reorder_ctrl *preorder_ctrl, u16 seq_num)
static int check_indicate_seq(struct recv_reorder_ctrl *preorder_ctrl, u16 seq_num)
{
u8 wsize = preorder_ctrl->wsize_b;
u16 wend = (preorder_ctrl->indicate_seq + wsize -1) & 0xFFF;//% 4096;
@ -3136,8 +3132,7 @@ int recv_indicatepkts_in_order(struct adapter *padapter, struct recv_reorder_ctr
}
int recv_indicatepkt_reorder(struct adapter *padapter, union recv_frame *prframe);
int recv_indicatepkt_reorder(struct adapter *padapter, union recv_frame *prframe)
static int recv_indicatepkt_reorder(struct adapter *padapter, union recv_frame *prframe)
{
_irqL irql;
int retval = _SUCCESS;
@ -3145,23 +3140,19 @@ int recv_indicatepkt_reorder(struct adapter *padapter, union recv_frame *prframe
struct recv_reorder_ctrl *preorder_ctrl = prframe->u.hdr.preorder_ctrl;
_queue *ppending_recvframe_queue = &preorder_ctrl->pending_recvframe_queue;
if(!pattrib->amsdu)
{
if(!pattrib->amsdu) {
//s1.
wlanhdr_to_ethhdr(prframe);
//if ((pattrib->qos!=1) /*|| pattrib->priority!=0 || IS_MCAST(pattrib->ra)*/
// || (pattrib->eth_type==0x0806) || (pattrib->ack_policy!=0))
if (pattrib->qos!=1)
{
if (pattrib->qos!=1) {
if ((padapter->bDriverStopped == false) &&
(padapter->bSurpriseRemoved == false))
{
(padapter->bSurpriseRemoved == false)) {
RT_TRACE(_module_rtl871x_recv_c_, _drv_notice_, ("@@@@ recv_indicatepkt_reorder -recv_func recv_indicatepkt\n" ));
rtw_recv_indicatepkt(padapter, prframe);
return _SUCCESS;
}
#ifdef DBG_RX_DROP_FRAME
@ -3169,11 +3160,8 @@ int recv_indicatepkt_reorder(struct adapter *padapter, union recv_frame *prframe
#endif
return _FAIL;
}
if (preorder_ctrl->enable == false)
{
if (preorder_ctrl->enable == false) {
//indicate this recv_frame
preorder_ctrl->indicate_seq = pattrib->seq_num;
#ifdef DBG_RX_SEQ
@ -3197,12 +3185,8 @@ int recv_indicatepkt_reorder(struct adapter *padapter, union recv_frame *prframe
rtw_recv_indicatepkt(padapter, prframe);
return _SUCCESS;
#endif
}
else if(pattrib->amsdu==1) //temp filter -> means didn't support A-MSDUs in a A-MPDU
{
if (preorder_ctrl->enable == false)
{
} else if(pattrib->amsdu==1) { //temp filter -> means didn't support A-MSDUs in a A-MPDU
if (preorder_ctrl->enable == false) {
preorder_ctrl->indicate_seq = pattrib->seq_num;
#ifdef DBG_RX_SEQ
DBG_871X("DBG_RX_SEQ %s:%d IndicateSeq: %d, NewSeq: %d\n", __FUNCTION__, __LINE__,
@ -3226,10 +3210,6 @@ int recv_indicatepkt_reorder(struct adapter *padapter, union recv_frame *prframe
return retval;
}
}
else
{
}
_enter_critical_bh(&ppending_recvframe_queue->lock, &irql);
@ -3238,34 +3218,21 @@ int recv_indicatepkt_reorder(struct adapter *padapter, union recv_frame *prframe
preorder_ctrl->indicate_seq, pattrib->seq_num));
//s2. check if winstart_b(indicate_seq) needs to been updated
if(!check_indicate_seq(preorder_ctrl, pattrib->seq_num))
{
//pHTInfo->RxReorderDropCounter++;
//ReturnRFDList(Adapter, pRfd);
//RT_TRACE(COMP_RX_REORDER, DBG_TRACE, ("RxReorderIndicatePacket() ==> Packet Drop!!\n"));
//_exit_critical_ex(&ppending_recvframe_queue->lock, &irql);
//return _FAIL;
if(!check_indicate_seq(preorder_ctrl, pattrib->seq_num)) {
#ifdef DBG_RX_DROP_FRAME
DBG_871X("DBG_RX_DROP_FRAME %s check_indicate_seq fail\n", __FUNCTION__);
#endif
goto _err_exit;
}
//s3. Insert all packet into Reorder Queue to maintain its ordering.
if(!enqueue_reorder_recvframe(preorder_ctrl, prframe))
{
//DbgPrint("recv_indicatepkt_reorder, enqueue_reorder_recvframe fail!\n");
//_exit_critical_ex(&ppending_recvframe_queue->lock, &irql);
//return _FAIL;
if(!enqueue_reorder_recvframe(preorder_ctrl, prframe)) {
#ifdef DBG_RX_DROP_FRAME
DBG_871X("DBG_RX_DROP_FRAME %s enqueue_reorder_recvframe fail\n", __FUNCTION__);
#endif
goto _err_exit;
}
//s4.
// Indication process.
// After Packet dropping and Sliding Window shifting as above, we can now just indicate the packets
@ -3276,31 +3243,20 @@ int recv_indicatepkt_reorder(struct adapter *padapter, union recv_frame *prframe
// 2. All packets with SeqNum larger than or equal to WinStart => Buffer it.
//
//recv_indicatepkts_in_order(padapter, preorder_ctrl, true);
if(recv_indicatepkts_in_order(padapter, preorder_ctrl, false)==true)
{
if(recv_indicatepkts_in_order(padapter, preorder_ctrl, false)) {
_set_timer(&preorder_ctrl->reordering_ctrl_timer, REORDER_WAIT_TIME);
_exit_critical_bh(&ppending_recvframe_queue->lock, &irql);
}
else
{
} else {
_exit_critical_bh(&ppending_recvframe_queue->lock, &irql);
_cancel_timer_ex(&preorder_ctrl->reordering_ctrl_timer);
}
_success_exit:
return _SUCCESS;
_err_exit:
_exit_critical_bh(&ppending_recvframe_queue->lock, &irql);
return _FAIL;
}
void rtw_reordering_ctrl_timeout_handler(void *pcontext)
{
_irqL irql;
@ -3403,7 +3359,7 @@ int process_recv_indicatepkts(struct adapter *padapter, union recv_frame *prfram
}
int recv_func_prehandle(struct adapter *padapter, union recv_frame *rframe)
static int recv_func_prehandle(struct adapter *padapter, union recv_frame *rframe)
{
int ret = _SUCCESS;
struct rx_pkt_attrib *pattrib = &rframe->u.hdr.attrib;
@ -3424,7 +3380,7 @@ exit:
return ret;
}
int recv_func_posthandle(struct adapter *padapter, union recv_frame *prframe)
static int recv_func_posthandle(struct adapter *padapter, union recv_frame *prframe)
{
int ret = _SUCCESS;
union recv_frame *orig_prframe = prframe;

View file

@ -31,7 +31,7 @@ struct ch_freq {
u32 frequency;
};
struct ch_freq ch_freq_map[] = {
static struct ch_freq ch_freq_map[] = {
{1, 2412},{2, 2417},{3, 2422},{4, 2427},{5, 2432},
{6, 2437},{7, 2442},{8, 2447},{9, 2452},{10, 2457},
{11, 2462},{12, 2467},{13, 2472},{14, 2484},
@ -53,7 +53,7 @@ struct ch_freq ch_freq_map[] = {
{216, 5080},/* Japan, means J16 */
};
int ch_freq_map_num = (sizeof(ch_freq_map) / sizeof(struct ch_freq));
static int ch_freq_map_num = (sizeof(ch_freq_map) / sizeof(struct ch_freq));
u32 rtw_ch2freq(u32 channel)
{

View file

@ -1971,42 +1971,27 @@ static sint aes_decipher(u8 *key, uint hdrlen,
u32 rtw_aes_decrypt(struct adapter *padapter, u8 *precvframe)
{ // exclude ICV
/*static*/
// unsigned char message[MAX_MSG_SIZE];
/* Intermediate Buffers */
sint length;
int length;
u8 *pframe,*prwskey; //, *payload,*iv
struct sta_info *stainfo;
struct rx_pkt_attrib *prxattrib = &((union recv_frame *)precvframe)->u.hdr.attrib;
struct security_priv *psecuritypriv=&padapter->securitypriv;
// struct recv_priv *precvpriv=&padapter->recvpriv;
u32 res=_SUCCESS;
;
pframe=(unsigned char *)((union recv_frame*)precvframe)->u.hdr.rx_data;
//4 start to encrypt each fragment
if((prxattrib->encrypt==_AES_)){
stainfo=rtw_get_stainfo(&padapter->stapriv ,&prxattrib->ta[0] );
if (stainfo!=NULL){
RT_TRACE(_module_rtl871x_security_c_,_drv_err_,("rtw_aes_decrypt: stainfo!=NULL!!!\n"));
if(IS_MCAST(prxattrib->ra))
{
if(IS_MCAST(prxattrib->ra)) {
static u32 start = 0;
static u32 no_gkey_bc_cnt = 0;
static u32 no_gkey_mc_cnt = 0;
//in concurrent we should use sw descrypt in group key, so we remove this message
//DBG_871X("rx bc/mc packets, to perform sw rtw_aes_decrypt\n");
//prwskey = psecuritypriv->dot118021XGrpKey[psecuritypriv->dot118021XGrpKeyid].skey;
if(psecuritypriv->binstallGrpkey==false)
{
if (!psecuritypriv->binstallGrpkey) {
res=_FAIL;
if (start == 0)
@ -2039,54 +2024,25 @@ u32 rtw_aes_decrypt(struct adapter *padapter, u8 *precvframe)
no_gkey_mc_cnt = 0;
prwskey = psecuritypriv->dot118021XGrpKey[prxattrib->key_index].skey;
if(psecuritypriv->dot118021XGrpKeyid != prxattrib->key_index)
{
if(psecuritypriv->dot118021XGrpKeyid != prxattrib->key_index) {
DBG_871X("not match packet_index=%d, install_index=%d \n"
, prxattrib->key_index, psecuritypriv->dot118021XGrpKeyid);
res=_FAIL;
goto exit;
}
}
else
{
} else {
prwskey=&stainfo->dot118021x_UncstKey.skey[0];
}
length= ((union recv_frame *)precvframe)->u.hdr.len-prxattrib->hdrlen-prxattrib->iv_len;
/*// add for CONFIG_IEEE80211W, debug
if(0)
printk("@@@@@@@@@@@@@@@@@@ length=%d, prxattrib->hdrlen=%d, prxattrib->pkt_len=%d \n"
, length, prxattrib->hdrlen, prxattrib->pkt_len);
if(0)
{
int no;
//test print PSK
printk("PSK key below:\n");
for(no=0;no<16;no++)
printk(" %02x ", prwskey[no]);
printk("\n");
}
if(0)
{
int no;
//test print PSK
printk("frame:\n");
for(no=0;no<prxattrib->pkt_len;no++)
printk(" %02x ", pframe[no]);
printk("\n");
}*/
res= aes_decipher(prwskey,prxattrib->hdrlen,pframe, length);
}
else{
} else {
RT_TRACE(_module_rtl871x_security_c_,_drv_err_,("rtw_aes_encrypt: stainfo==NULL!!!\n"));
res=_FAIL;
}
}
;
exit:
return res;
}

View file

@ -680,43 +680,29 @@ void read_cam(struct adapter *padapter ,u8 entry)
void write_cam(struct adapter *padapter, u8 entry, u16 ctrl, u8 *mac, u8 *key)
{
unsigned int i, val, addr;
//unsigned int cmd;
int j;
u32 cam_val[2];
addr = entry << 3;
for (j = 5; j >= 0; j--)
{
switch (j)
{
for (j = 5; j >= 0; j--) {
switch (j) {
case 0:
val = (ctrl | (mac[0] << 16) | (mac[1] << 24) );
break;
case 1:
val = (mac[2] | ( mac[3] << 8) | (mac[4] << 16) | (mac[5] << 24));
break;
default:
i = (j - 2) << 2;
val = (key[i] | (key[i+1] << 8) | (key[i+2] << 16) | (key[i+3] << 24));
break;
}
cam_val[0] = val;
cam_val[1] = addr + (unsigned int)j;
rtw_hal_set_hwreg(padapter, HW_VAR_CAM_WRITE, (u8 *)cam_val);
//rtw_write32(padapter, WCAMI, val);
//cmd = CAM_POLLINIG | CAM_WRITE | (addr + j);
//rtw_write32(padapter, RWCAM, cmd);
//DBG_871X("%s=> cam write: %x, %x\n",__FUNCTION__, cmd, val);
}
}
@ -724,7 +710,6 @@ void write_cam(struct adapter *padapter, u8 entry, u16 ctrl, u8 *mac, u8 *key)
void clear_cam_entry(struct adapter *padapter, u8 entry)
{
unsigned char null_sta[] = {0x00, 0x00, 0x00, 0x00, 0x00, 0x00};
unsigned char null_key[] = {0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,0x00, 0x00, 0x00, 0x00,0x00, 0x00, 0x00, 0x00};
write_cam(padapter, entry, 0, null_sta, null_key);
@ -736,10 +721,8 @@ int allocate_fw_sta_entry(struct adapter *padapter)
struct mlme_ext_priv *pmlmeext = &padapter->mlmeextpriv;
struct mlme_ext_info *pmlmeinfo = &(pmlmeext->mlmext_info);
for (mac_id = IBSS_START_MAC_ID; mac_id < NUM_STA; mac_id++)
{
if (pmlmeinfo->FW_sta_info[mac_id].status == 0)
{
for (mac_id = IBSS_START_MAC_ID; mac_id < NUM_STA; mac_id++) {
if (pmlmeinfo->FW_sta_info[mac_id].status == 0) {
pmlmeinfo->FW_sta_info[mac_id].status = 1;
pmlmeinfo->FW_sta_info[mac_id].retry = 0;
break;
@ -759,14 +742,10 @@ void flush_all_cam_entry(struct adapter *padapter)
struct mlme_priv *pmlmepriv = &(padapter->mlmepriv);
//if(check_buddy_mlmeinfo_state(padapter, _HW_STATE_NOLINK_))
if(check_buddy_fwstate(padapter, _FW_LINKED) == false)
{
if(check_buddy_fwstate(padapter, _FW_LINKED) == false) {
rtw_hal_set_hwreg(padapter, HW_VAR_CAM_INVALID_ALL, 0);
}
else
{
if(check_fwstate(pmlmepriv, WIFI_STATION_STATE))
{
} else {
if(check_fwstate(pmlmepriv, WIFI_STATION_STATE)) {
struct sta_priv *pstapriv = &padapter->stapriv;
struct sta_info *psta;
u8 cam_id;//cam_entry
@ -784,9 +763,7 @@ void flush_all_cam_entry(struct adapter *padapter)
//clear_cam_entry(padapter, cam_id);
rtw_clearstakey_cmd(padapter, (u8*)psta, cam_id, false);
}
}
else if(check_fwstate(pmlmepriv, WIFI_AP_STATE) == true)
{
} else if(check_fwstate(pmlmepriv, WIFI_AP_STATE) == true) {
//clear cam when ap free per sta_info
}
}
@ -796,8 +773,7 @@ void flush_all_cam_entry(struct adapter *padapter)
#endif //CONFIG_CONCURRENT_MODE
_rtw_memset((u8 *)(pmlmeinfo->FW_sta_info), 0, sizeof(pmlmeinfo->FW_sta_info));
memset((u8 *)(pmlmeinfo->FW_sta_info), 0, sizeof(pmlmeinfo->FW_sta_info));
}
#if defined(CONFIG_P2P) && defined(CONFIG_WFD)

View file

@ -28,6 +28,7 @@
#include <ip.h>
#include <usb_ops.h>
#include "rtw_br_ext.h"
#include <usb_osintf.h>
static u8 P802_1H_OUI[P80211_OUI_LEN] = { 0x00, 0x00, 0xf8 };
static u8 RFC1042_OUI[P80211_OUI_LEN] = { 0x00, 0x00, 0x00 };
@ -2984,7 +2985,6 @@ static int rtw_br_client_tx(struct adapter *padapter, struct sk_buff **pskb)
_irqL irqL;
//if(check_fwstate(pmlmepriv, WIFI_STATION_STATE|WIFI_ADHOC_STATE) == true)
{
void dhcp_flag_bcast(struct adapter *priv, struct sk_buff *skb);
int res, is_vlan_tag=0, i, do_nat25=1;
unsigned short vlan_hdr=0;
void *br_port = NULL;
@ -3052,7 +3052,6 @@ static int rtw_br_client_tx(struct adapter *padapter, struct sk_buff **pskb)
#endif // 1
if (do_nat25)
{
int nat25_db_handle(struct adapter *priv, struct sk_buff *skb, int method);
if (nat25_db_handle(padapter, skb, NAT25_CHECK) == 0) {
struct sk_buff *newskb;

View file

@ -281,7 +281,7 @@ exit:
rtw_mfree2d((void *)eFuseWord, EFUSE_MAX_SECTION_88E, EFUSE_MAX_WORD_UNIT, sizeof(u16));
}
void efuse_read_phymap_from_txpktbuf(
static void efuse_read_phymap_from_txpktbuf(
struct adapter *adapter,
int bcnhead, //beacon head, where FW store len(2-byte) and efuse physical map.
u8 *content, //buffer to store efuse physical map
@ -433,7 +433,7 @@ static s32 iol_ioconfig(
return rst;
}
int rtl8188e_IOL_exec_cmds_sync(struct adapter *adapter, struct xmit_frame *xmit_frame, u32 max_wating_ms,u32 bndy_cnt)
static int rtl8188e_IOL_exec_cmds_sync(struct adapter *adapter, struct xmit_frame *xmit_frame, u32 max_wating_ms,u32 bndy_cnt)
{
u32 start_time = rtw_get_current_time();
@ -704,7 +704,7 @@ exit:
return ret;
}
void _MCUIO_Reset88E(struct adapter *padapter,u8 bReset)
static void _MCUIO_Reset88E(struct adapter *padapter,u8 bReset)
{
u8 u1bTmp;
@ -1506,16 +1506,14 @@ rtl8188e_ReadEFuse(
}
//Do not support BT
void
Hal_EFUSEGetEfuseDefinition88E(
static void Hal_EFUSEGetEfuseDefinition88E(
IN struct adapter *pAdapter,
IN u8 efuseType,
IN u8 type,
OUT void * pOut
)
{
switch(type)
{
switch(type) {
case TYPE_EFUSE_MAX_SECTION:
{
u8* pMax_section;
@ -1574,8 +1572,8 @@ Hal_EFUSEGetEfuseDefinition88E(
break;
}
}
void
Hal_EFUSEGetEfuseDefinition_Pseudo88E(
static void Hal_EFUSEGetEfuseDefinition_Pseudo88E(
IN struct adapter *pAdapter,
IN u8 efuseType,
IN u8 type,
@ -2669,7 +2667,8 @@ static void rtl8188e_read_chip_version(struct adapter *padapter)
{
ReadChipVersion8188E(padapter);
}
void rtl8188e_GetHalODMVar(
static void rtl8188e_GetHalODMVar(
struct adapter * Adapter,
HAL_ODM_VARIABLE eVariable,
void * pValue1,
@ -2684,7 +2683,8 @@ void rtl8188e_GetHalODMVar(
break;
}
}
void rtl8188e_SetHalODMVar(
static void rtl8188e_SetHalODMVar(
struct adapter * Adapter,
HAL_ODM_VARIABLE eVariable,
void * pValue1,
@ -2732,7 +2732,7 @@ void rtl8188e_stop_thread(struct adapter *padapter)
{
}
void hal_notch_filter_8188e(struct adapter *adapter, bool enable)
static void hal_notch_filter_8188e(struct adapter *adapter, bool enable)
{
if (enable) {
DBG_871X("Enable notch filter\n");
@ -2742,6 +2742,7 @@ void hal_notch_filter_8188e(struct adapter *adapter, bool enable)
rtw_write8(adapter, rOFDM0_RxDSP+1, rtw_read8(adapter, rOFDM0_RxDSP+1) & ~BIT1);
}
}
void rtl8188e_set_hal_ops(struct hal_ops *pHalFunc)
{
pHalFunc->free_hal_data = &rtl8188e_free_hal_data;
@ -2825,7 +2826,7 @@ u8 GetEEPROMSize8188E(struct adapter *padapter)
// LLT R/W/Init function
//
//-------------------------------------------------------------------------
s32 _LLTWrite(struct adapter *padapter, u32 address, u32 data)
static s32 _LLTWrite(struct adapter *padapter, u32 address, u32 data)
{
s32 status = _SUCCESS;
s32 count = 0;
@ -2852,7 +2853,7 @@ s32 _LLTWrite(struct adapter *padapter, u32 address, u32 data)
return status;
}
u8 _LLTRead(struct adapter *padapter, u32 address)
static u8 _LLTRead(struct adapter *padapter, u32 address)
{
s32 count = 0;
u32 value = _LLT_INIT_ADDR(address) | _LLT_OP(_LLT_READ_ACCESS);

View file

@ -617,18 +617,9 @@ phy_RFSerialWrite(
* Return: u32 Readback value
* Note: This function is equal to "GetRFRegSetting" in PHY programming guide
*/
u32
rtl8188e_PHY_QueryRFReg(
IN struct adapter * Adapter,
IN RF_RADIO_PATH_E eRFPath,
IN u32 RegAddr,
IN u32 BitMask
)
u32 rtl8188e_PHY_QueryRFReg(struct adapter *Adapter, RF_RADIO_PATH_E eRFPath, u32 RegAddr, u32 BitMask)
{
u32 Original_Value, Readback_Value, BitShift;
//HAL_DATA_TYPE *pHalData = GET_HAL_DATA(Adapter);
//u8 RFWaitCounter = 0;
//_irqL irqL;
#if (DISABLE_BB_RF == 1)
return 0;
@ -985,7 +976,7 @@ phy_ConfigBBWithParaFile(
//****************************************
// The following is for High Power PA
//****************************************
void
static void
phy_ConfigBBExternalPA(
IN struct adapter * Adapter
)
@ -1564,7 +1555,7 @@ rtl8188e_PHY_ConfigRFWithParaFile(
//****************************************
#define HighPowerRadioAArrayLen 22
//This is for High power PA
u32 Rtl8192S_HighPower_RadioA_Array[HighPowerRadioAArrayLen] = {
static u32 Rtl8192S_HighPower_RadioA_Array[HighPowerRadioAArrayLen] = {
0x013,0x00029ea4,
0x013,0x00025e74,
0x013,0x00020ea4,
@ -1578,7 +1569,7 @@ u32 Rtl8192S_HighPower_RadioA_Array[HighPowerRadioAArrayLen] = {
0x013,0x00000240,
};
int
static int
PHY_ConfigRFExternalPA(
IN struct adapter * Adapter,
RF_RADIO_PATH_E eRFPath
@ -1794,7 +1785,7 @@ exit:
*
* Note: This function may be removed in the ASIC
*---------------------------------------------------------------------------*/
int
static int
PHY_CheckBBAndRFOK(
IN struct adapter * Adapter,
IN HW90_BLOCK_E CheckBlock,
@ -1957,7 +1948,7 @@ phy_DbmToTxPwrIdx(
// current wireless mode.
// By Bruce, 2008-01-29.
//
int
static int
phy_TxPwrIdxToDbm(
IN struct adapter * Adapter,
IN WIRELESS_MODE WirelessMode,
@ -2042,7 +2033,7 @@ PHY_GetTxPowerLevel8188E(
*powerlevel = TxPwrDbm;
}
void getTxPowerIndex88E(
static void getTxPowerIndex88E(
IN struct adapter * Adapter,
IN u8 channel,
IN OUT u8* cckPowerLevel,
@ -2140,7 +2131,7 @@ void getTxPowerIndex88E(
}
}
void phy_PowerIndexCheck88E(
static void phy_PowerIndexCheck88E(
IN struct adapter *Adapter,
IN u8 channel,
IN OUT u8 * cckPowerLevel,
@ -2263,7 +2254,7 @@ PHY_UpdateTxPowerDbm8188E(
*/
void
static void
rtl8192c_PHY_SetBeaconHwReg(
IN struct adapter * Adapter,
IN u16 BeaconInterval
@ -2535,8 +2526,7 @@ static void _PHY_SwChnl8192C(struct adapter *Adapter, u8 channel)
}
// <20130708, James> A workaround to eliminate the 2480MHz spur for 8188E I-Cut
void
phy_SpurCalibration_8188E(
static void phy_SpurCalibration_8188E(
IN struct adapter * Adapter
)
{
@ -2882,8 +2872,7 @@ _PHY_DumpRFReg(IN struct adapter *pAdapter)
// To dump all Tx FIFO LLT related link-list table.
// Added by Roger, 2009.03.10.
//
void
DumpBBDbgPort_92CU(
static void DumpBBDbgPort_92CU(
IN struct adapter * Adapter
)
{

View file

@ -285,7 +285,7 @@ rtl8188e_PHY_RF6052SetCckTxPower(
// powerbase0 for OFDM rates
// powerbase1 for HT MCS rates
void getPowerBase88E(
static void getPowerBase88E(
IN struct adapter *Adapter,
IN u8* pPowerLevelOFDM,
IN u8* pPowerLevelBW20,
@ -328,7 +328,7 @@ void getPowerBase88E(
}
}
void getTxPowerWriteValByRegulatory88E(
static void getTxPowerWriteValByRegulatory88E(
IN struct adapter *Adapter,
IN u8 Channel,
IN u8 index,
@ -814,7 +814,7 @@ PHY_RF6052_Config8188E(
* 11/20/2008 MHC Create Version 0.
*
*---------------------------------------------------------------------------*/
u32
static u32
PHY_RFShadowRead(
IN struct adapter * Adapter,
IN RF_RADIO_PATH_E eRFPath,
@ -825,7 +825,7 @@ PHY_RFShadowRead(
} /* PHY_RFShadowRead */
void
static void
PHY_RFShadowWrite(
IN struct adapter * Adapter,
IN RF_RADIO_PATH_E eRFPath,
@ -838,7 +838,7 @@ PHY_RFShadowWrite(
} /* PHY_RFShadowWrite */
BOOLEAN
static BOOLEAN
PHY_RFShadowCompare(
IN struct adapter * Adapter,
IN RF_RADIO_PATH_E eRFPath,
@ -864,7 +864,7 @@ PHY_RFShadowCompare(
} /* PHY_RFShadowCompare */
void
static void
PHY_RFShadowRecorver(
IN struct adapter * Adapter,
IN RF_RADIO_PATH_E eRFPath,
@ -887,7 +887,7 @@ PHY_RFShadowRecorver(
} /* PHY_RFShadowRecorver */
void
static void
PHY_RFShadowCompareAll(
IN struct adapter * Adapter)
{
@ -905,7 +905,7 @@ PHY_RFShadowCompareAll(
} /* PHY_RFShadowCompareAll */
void
static void
PHY_RFShadowRecorverAll(
IN struct adapter * Adapter)
{
@ -923,7 +923,7 @@ PHY_RFShadowRecorverAll(
} /* PHY_RFShadowRecorverAll */
void
static void
PHY_RFShadowCompareFlagSet(
IN struct adapter * Adapter,
IN RF_RADIO_PATH_E eRFPath,
@ -936,7 +936,7 @@ PHY_RFShadowCompareFlagSet(
} /* PHY_RFShadowCompareFlagSet */
void
static void
PHY_RFShadowRecorverFlagSet(
IN struct adapter * Adapter,
IN RF_RADIO_PATH_E eRFPath,
@ -949,7 +949,7 @@ PHY_RFShadowRecorverFlagSet(
} /* PHY_RFShadowRecorverFlagSet */
void
static void
PHY_RFShadowCompareFlagSetAll(
IN struct adapter * Adapter)
{
@ -971,7 +971,7 @@ PHY_RFShadowCompareFlagSetAll(
} /* PHY_RFShadowCompareFlagSetAll */
void
static void
PHY_RFShadowRecorverFlagSetAll(
IN struct adapter * Adapter)
{
@ -992,7 +992,7 @@ PHY_RFShadowRecorverFlagSetAll(
} /* PHY_RFShadowCompareFlagSetAll */
void
static void
PHY_RFShadowRefresh(
IN struct adapter * Adapter)
{

View file

@ -109,7 +109,7 @@ static BOOLEAN HalUsbSetQueuePipeMapping8188EUsb(
}
void rtl8188eu_interface_configure(struct adapter *padapter)
static void rtl8188eu_interface_configure(struct adapter *padapter)
{
HAL_DATA_TYPE *pHalData = GET_HAL_DATA(padapter);
struct dvobj_priv *pdvobjpriv = adapter_to_dvobj(padapter);
@ -985,8 +985,7 @@ InitUsbAggregationSetting(
// 201/12/10 MH Add for USB agg mode dynamic switch.
pHalData->UsbRxHighSpeedMode = false;
}
void
HalRxAggr8188EUsb(
static void HalRxAggr8188EUsb(
IN struct adapter *Adapter,
IN BOOLEAN Value
)
@ -1012,8 +1011,7 @@ HalRxAggr8188EUsb(
* 12/10/2010 MHC Create Version 0.
*
*---------------------------------------------------------------------------*/
void
USB_AggModeSwitch(
static void USB_AggModeSwitch(
IN struct adapter * Adapter
)
{
@ -1235,7 +1233,7 @@ rt_rf_power_state RfOnOffDetect(IN struct adapter *pAdapter )
void _ps_open_RF(struct adapter *padapter);
u32 rtl8188eu_hal_init(struct adapter *Adapter)
static u32 rtl8188eu_hal_init(struct adapter *Adapter)
{
u8 value8 = 0;
u16 value16;
@ -1740,13 +1738,7 @@ void _ps_open_RF(struct adapter *padapter) {
//phy_SsPwrSwitch92CU(padapter, rf_on, 1);
}
void _ps_close_RF(struct adapter *padapter){
//here call with bRegSSPwrLvl 1, bRegSSPwrLvl 2 needs to be verified
//phy_SsPwrSwitch92CU(padapter, rf_off, 1);
}
void hal_poweroff_rtl8188eu(
static void hal_poweroff_rtl8188eu(
IN struct adapter * Adapter
)
{
@ -1836,7 +1828,7 @@ static void rtl8188eu_hw_power_down(struct adapter *padapter)
rtw_write16(padapter, REG_APS_FSMCO, 0x8812);
}
u32 rtl8188eu_hal_deinit(struct adapter *Adapter)
static u32 rtl8188eu_hal_deinit(struct adapter *Adapter)
{
struct pwrctrl_priv *pwrctl = adapter_to_pwrctl(Adapter);
HAL_DATA_TYPE *pHalData = GET_HAL_DATA(Adapter);
@ -1851,7 +1843,6 @@ u32 rtl8188eu_hal_deinit(struct adapter *Adapter)
DBG_8192C("bkeepfwalive(%x)\n", pwrctl->bkeepfwalive);
if(pwrctl->bkeepfwalive)
{
_ps_close_RF(Adapter);
if((pwrctl->bHWPwrPindetect) && (pwrctl->bHWPowerdown))
rtl8188eu_hw_power_down(Adapter);
}
@ -1870,7 +1861,7 @@ u32 rtl8188eu_hal_deinit(struct adapter *Adapter)
}
unsigned int rtl8188eu_inirp_init(struct adapter *Adapter)
static unsigned int rtl8188eu_inirp_init(struct adapter *Adapter)
{
u8 i;
struct recv_buf *precvbuf;
@ -1934,7 +1925,7 @@ exit:
}
unsigned int rtl8188eu_inirp_deinit(struct adapter *Adapter)
static unsigned int rtl8188eu_inirp_deinit(struct adapter *Adapter)
{
RT_TRACE(_module_hci_hal_init_c_,_drv_info_,("\n ===> usb_rx_deinit \n"));
@ -2378,7 +2369,8 @@ static void ResumeTxBeacon(struct adapter *padapter)
pHalData->RegReg542 |= BIT0;
rtw_write8(padapter, REG_TBTT_PROHIBIT+2, pHalData->RegReg542);
}
void UpdateInterruptMask8188EU(struct adapter *padapter,u8 bHIMR0 ,u32 AddMSR, u32 RemoveMSR)
static void UpdateInterruptMask8188EU(struct adapter *padapter,u8 bHIMR0 ,u32 AddMSR, u32 RemoveMSR)
{
HAL_DATA_TYPE *pHalData;
@ -2995,7 +2987,7 @@ static void hw_var_set_mlme_join(struct adapter *Adapter, u8 variable, u8* val)
#endif
}
void SetHwReg8188EU(struct adapter *Adapter, u8 variable, u8* val)
static void SetHwReg8188EU(struct adapter *Adapter, u8 variable, u8* val)
{
HAL_DATA_TYPE *pHalData = GET_HAL_DATA(Adapter);
struct dm_priv *pdmpriv = &pHalData->dmpriv;
@ -3838,7 +3830,7 @@ void SetHwReg8188EU(struct adapter *Adapter, u8 variable, u8* val)
;
}
void GetHwReg8188EU(struct adapter *Adapter, u8 variable, u8* val)
static void GetHwReg8188EU(struct adapter *Adapter, u8 variable, u8* val)
{
HAL_DATA_TYPE *pHalData = GET_HAL_DATA(Adapter);
DM_ODM_T *podmpriv = &pHalData->odmpriv;
@ -3927,8 +3919,7 @@ void GetHwReg8188EU(struct adapter *Adapter, u8 variable, u8* val)
// Description:
// Query setting of specified variable.
//
u8
GetHalDefVar8188EUsb(
static u8 GetHalDefVar8188EUsb(
IN struct adapter * Adapter,
IN HAL_DEF_VARIABLE eVariable,
IN void * pValue
@ -4074,8 +4065,7 @@ GetHalDefVar8188EUsb(
// Description:
// Change default setting of specified variable.
//
u8
SetHalDefVar8188EUsb(
static u8 SetHalDefVar8188EUsb(
IN struct adapter * Adapter,
IN HAL_DEF_VARIABLE eVariable,
IN void * pValue
@ -4167,7 +4157,7 @@ u32 _update_92cu_basic_rate(struct adapter *padapter, unsigned int mask)
return BrateCfg;
}
*/
void _update_response_rate(struct adapter *padapter,unsigned int mask)
static void _update_response_rate(struct adapter *padapter,unsigned int mask)
{
u8 RateIndex = 0;
// Set RRSR rate table.
@ -4183,7 +4173,7 @@ void _update_response_rate(struct adapter *padapter,unsigned int mask)
rtw_write8(padapter, REG_INIRTS_RATE_SEL, RateIndex);
}
void UpdateHalRAMask8188EUsb(struct adapter *padapter, u32 mac_id, u8 rssi_level)
static void UpdateHalRAMask8188EUsb(struct adapter *padapter, u32 mac_id, u8 rssi_level)
{
//volatile unsigned int result;
u8 init_rate=0;

View file

@ -279,14 +279,14 @@ extern u32 GlobalDebugLevel;
off_t offset, int count,
int *eof, void *data);
int proc_set_write_reg(struct file *file, const char *buffer,
int proc_set_write_reg(struct file *file, const char __user *buffer,
unsigned long count, void *data);
int proc_get_read_reg(char *page, char **start,
off_t offset, int count,
int *eof, void *data);
int proc_set_read_reg(struct file *file, const char *buffer,
int proc_set_read_reg(struct file *file, const char __user *buffer,
unsigned long count, void *data);
@ -384,7 +384,7 @@ extern u32 GlobalDebugLevel;
int proc_get_best_channel(char *page, char **start,
off_t offset, int count,
int *eof, void *data);
int proc_set_best_channel(struct file *file, const char *buffer,
int proc_set_best_channel(struct file *file, const char __user *buffer,
unsigned long count, void *data);
#endif
@ -392,7 +392,7 @@ extern u32 GlobalDebugLevel;
off_t offset, int count,
int *eof, void *data);
int proc_set_rx_signal(struct file *file, const char *buffer,
int proc_set_rx_signal(struct file *file, const char __user *buffer,
unsigned long count, void *data);
#ifdef CONFIG_80211N_HT
@ -400,28 +400,28 @@ extern u32 GlobalDebugLevel;
off_t offset, int count,
int *eof, void *data);
int proc_set_ht_enable(struct file *file, const char *buffer,
int proc_set_ht_enable(struct file *file, const char __user *buffer,
unsigned long count, void *data);
int proc_get_cbw40_enable(char *page, char **start,
off_t offset, int count,
int *eof, void *data);
int proc_set_cbw40_enable(struct file *file, const char *buffer,
int proc_set_cbw40_enable(struct file *file, const char __user *buffer,
unsigned long count, void *data);
int proc_get_ampdu_enable(char *page, char **start,
off_t offset, int count,
int *eof, void *data);
int proc_set_ampdu_enable(struct file *file, const char *buffer,
int proc_set_ampdu_enable(struct file *file, const char __user *buffer,
unsigned long count, void *data);
int proc_get_rx_stbc(char *page, char **start,
off_t offset, int count,
int *eof, void *data);
int proc_set_rx_stbc(struct file *file, const char *buffer,
int proc_set_rx_stbc(struct file *file, const char __user *buffer,
unsigned long count, void *data);
#endif //CONFIG_80211N_HT
@ -433,7 +433,7 @@ extern u32 GlobalDebugLevel;
off_t offset, int count,
int *eof, void *data);
int proc_set_rssi_disp(struct file *file, const char *buffer,
int proc_set_rssi_disp(struct file *file, const char __user *buffer,
unsigned long count, void *data);
#ifdef CONFIG_BT_COEXIST
@ -441,23 +441,23 @@ extern u32 GlobalDebugLevel;
off_t offset, int count,
int *eof, void *data);
int proc_set_btcoex_dbg(struct file *file, const char *buffer,
int proc_set_btcoex_dbg(struct file *file, const char __user *buffer,
unsigned long count, void *data);
#endif //CONFIG_BT_COEXIST
#if defined(DBG_CONFIG_ERROR_DETECT)
int proc_get_sreset(char *page, char **start, off_t offset, int count, int *eof, void *data);
int proc_set_sreset(struct file *file, const char *buffer, unsigned long count, void *data);
int proc_set_sreset(struct file *file, const char __user *buffer, unsigned long count, void *data);
#endif /* DBG_CONFIG_ERROR_DETECT */
int proc_get_odm_dbg_comp(char *page, char **start, off_t offset, int count, int *eof, void *data);
int proc_set_odm_dbg_comp(struct file *file, const char *buffer, unsigned long count, void *data);
int proc_set_odm_dbg_comp(struct file *file, const char __user *buffer, unsigned long count, void *data);
int proc_get_odm_dbg_level(char *page, char **start, off_t offset, int count, int *eof, void *data);
int proc_set_odm_dbg_level(struct file *file, const char *buffer, unsigned long count, void *data);
int proc_set_odm_dbg_level(struct file *file, const char __user *buffer, unsigned long count, void *data);
int proc_get_odm_adaptivity(char *page, char **start, off_t offset, int count, int *eof, void *data);
int proc_set_odm_adaptivity(struct file *file, const char *buffer, unsigned long count, void *data);
int proc_set_odm_adaptivity(struct file *file, const char __user *buffer, unsigned long count, void *data);
#endif //CONFIG_PROC_DEBUG

View file

@ -485,17 +485,6 @@ s32 mp_start_test(struct adapter *padapter);
void mp_stop_test(struct adapter *padapter);
//=======================================================================
//void IQCalibrateBcut(struct adapter *pAdapter);
//u32 bb_reg_read(struct adapter *Adapter, u16 offset);
//u8 bb_reg_write(struct adapter *Adapter, u16 offset, u32 value);
//u32 rf_reg_read(struct adapter *Adapter, u8 path, u8 offset);
//u8 rf_reg_write(struct adapter *Adapter, u8 path, u8 offset, u32 value);
//u32 get_bb_reg(struct adapter *Adapter, u16 offset, u32 bitmask);
//u8 set_bb_reg(struct adapter *Adapter, u16 offset, u32 bitmask, u32 value);
//u32 get_rf_reg(struct adapter *Adapter, u8 path, u8 offset, u32 bitmask);
//u8 set_rf_reg(struct adapter *Adapter, u8 path, u8 offset, u32 bitmask, u32 value);
u32 _read_rfreg(struct adapter *padapter, u8 rfpath, u32 addr, u32 bitmask);
void _write_rfreg(struct adapter *padapter, u8 rfpath, u32 addr, u32 bitmask, u32 val);
@ -504,7 +493,7 @@ u32 read_macreg(struct adapter *padapter, u32 addr, u32 sz);
void write_macreg(struct adapter *padapter, u32 addr, u32 val, u32 sz);
u32 read_bbreg(struct adapter *padapter, u32 addr, u32 bitmask);
void write_bbreg(struct adapter *padapter, u32 addr, u32 bitmask, u32 val);
u32 read_rfreg(struct adapter *padapter, u8 rfpath, u32 addr);
u32 read_rfreg(struct adapter *padapter, RF_RADIO_PATH_E rfpath, u32 addr);
void write_rfreg(struct adapter *padapter, u8 rfpath, u32 addr, u32 val);
void SetChannel(struct adapter *pAdapter);

View file

@ -32,6 +32,9 @@
//void usb_dvobj_deinit(struct adapter * adapter);
u8 usbvendorrequest(struct dvobj_priv *pdvobjpriv, RT_USB_BREQUEST brequest, RT_USB_WVALUE wvalue, u8 windex, void* data, u8 datalen, u8 isdirectionin);
void dhcp_flag_bcast(struct adapter *priv, struct sk_buff *skb);
int nat25_db_handle(struct adapter *priv, struct sk_buff *skb, int method);
int nat25_handle_frame(struct adapter *priv, struct sk_buff *skb);
void nat25_db_expire(struct adapter *priv);
#endif

View file

@ -401,6 +401,7 @@ typedef struct _NDIS_802_11_CAPABILITY
} NDIS_802_11_CAPABILITY, *PNDIS_802_11_CAPABILITY;
#endif
u8 convert_ip_addr(u8 hch, u8 mch, u8 lch);
#endif //#ifndef WLAN_BSSDEF_H_

View file

@ -67,7 +67,6 @@
extern u8 key_2char2num(u8 hch, u8 lch);
extern u8 str_2char2num(u8 hch, u8 lch);
extern u8 convert_ip_addr(u8 hch, u8 mch, u8 lch);
static u32 rtw_rates[] = {1000000,2000000,5500000,11000000,
6000000,9000000,12000000,18000000,24000000,36000000,48000000,54000000};