rtl8723ds: Make fixes for more Sparse errors

Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net>
This commit is contained in:
Larry Finger 2017-10-25 11:34:05 -05:00
parent 525d5256f5
commit 1621248cc1
12 changed files with 73 additions and 89 deletions

View File

@ -43,7 +43,7 @@ u8 fakeBTEfuseModifiedMap[EFUSE_BT_MAX_MAP_LEN] = {0};
u8 maskfileBuffer[64]; u8 maskfileBuffer[64];
/*------------------------Define local variable------------------------------*/ /*------------------------Define local variable------------------------------*/
BOOLEAN rtw_file_efuse_IsMasked(PADAPTER pAdapter, u16 Offset) static BOOLEAN rtw_file_efuse_IsMasked(PADAPTER pAdapter, u16 Offset)
{ {
int r = Offset / 16; int r = Offset / 16;
int c = (Offset % 16) / 2; int c = (Offset % 16) / 2;
@ -60,7 +60,7 @@ BOOLEAN rtw_file_efuse_IsMasked(PADAPTER pAdapter, u16 Offset)
return (result > 0) ? 0 : 1; return (result > 0) ? 0 : 1;
} }
BOOLEAN efuse_IsMasked(PADAPTER pAdapter, u16 Offset) static BOOLEAN efuse_IsMasked(PADAPTER pAdapter, u16 Offset)
{ {
PHAL_DATA_TYPE pHalData = GET_HAL_DATA(pAdapter); PHAL_DATA_TYPE pHalData = GET_HAL_DATA(pAdapter);
@ -1506,7 +1506,7 @@ Efuse_PgPacketWrite(IN PADAPTER pAdapter,
} }
int static int
Efuse_PgPacketWrite_BT(IN PADAPTER pAdapter, Efuse_PgPacketWrite_BT(IN PADAPTER pAdapter,
IN u8 offset, IN u8 offset,
IN u8 word_en, IN u8 word_en,

View File

@ -4233,9 +4233,9 @@ static void session_tracker_cmd_hdl(_adapter *adapter, struct st_cmd_parm *parm)
} else if (cmd == ST_CMD_ADD || cmd == ST_CMD_DEL) { } else if (cmd == ST_CMD_ADD || cmd == ST_CMD_DEL) {
struct st_ctl_t *st_ctl; struct st_ctl_t *st_ctl;
u32 local_naddr = parm->local_naddr; u32 local_naddr = parm->local_naddr;
u16 local_port = parm->local_port; __be16 local_port = parm->local_port;
u32 remote_naddr = parm->remote_naddr; u32 remote_naddr = parm->remote_naddr;
u16 remote_port = parm->remote_port; __be16 remote_port = parm->remote_port;
struct session_tracker *st = NULL; struct session_tracker *st = NULL;
_irqL irqL; _irqL irqL;
_list *plist, *phead; _list *plist, *phead;

View File

@ -23,7 +23,7 @@
#include <hal_data.h> #include <hal_data.h>
#ifdef CONFIG_RTW_DEBUG #ifdef CONFIG_RTW_DEBUG
const char *rtw_log_level_str[] = { static const char *rtw_log_level_str[] = {
"_DRV_NONE_ = 0", "_DRV_NONE_ = 0",
"_DRV_ALWAYS_ = 1", "_DRV_ALWAYS_ = 1",
"_DRV_ERR_ = 2", "_DRV_ERR_ = 2",
@ -358,7 +358,7 @@ void rtw_sink_rtp_seq_dbg(_adapter *adapter, _pkt *pkt)
{ {
struct recv_priv *precvpriv = &(adapter->recvpriv); struct recv_priv *precvpriv = &(adapter->recvpriv);
if (precvpriv->sink_udpport > 0) { if (precvpriv->sink_udpport > 0) {
if (*((u16 *)((pkt->data) + 0x24)) == cpu_to_be16(precvpriv->sink_udpport)) { if (*((__be16 *)((pkt->data) + 0x24)) == cpu_to_be16(precvpriv->sink_udpport)) {
precvpriv->pre_rtp_rxseq = precvpriv->cur_rtp_rxseq; precvpriv->pre_rtp_rxseq = precvpriv->cur_rtp_rxseq;
precvpriv->cur_rtp_rxseq = be16_to_cpu(*((u16 *)((pkt->data) + 0x2C))); precvpriv->cur_rtp_rxseq = be16_to_cpu(*((u16 *)((pkt->data) + 0x2C)));
if (precvpriv->pre_rtp_rxseq + 1 != precvpriv->cur_rtp_rxseq) if (precvpriv->pre_rtp_rxseq + 1 != precvpriv->cur_rtp_rxseq)

View File

@ -442,20 +442,20 @@ int rtw_generate_ie(struct registry_priv *pregistrypriv)
ie += sz; ie += sz;
/* beacon interval : 2bytes */ /* beacon interval : 2bytes */
*(u16 *)ie = cpu_to_le16((u16)pdev_network->Configuration.BeaconPeriod); /* BCN_INTERVAL; */ *(__le16 *)ie = cpu_to_le16((u16)pdev_network->Configuration.BeaconPeriod); /* BCN_INTERVAL; */
sz += 2; sz += 2;
ie += 2; ie += 2;
/* capability info */ /* capability info */
*(u16 *)ie = 0; *(u16 *)ie = 0;
*(u16 *)ie |= cpu_to_le16(cap_IBSS); *(__le16 *)ie |= cpu_to_le16(cap_IBSS);
if (pregistrypriv->preamble == PREAMBLE_SHORT) if (pregistrypriv->preamble == PREAMBLE_SHORT)
*(u16 *)ie |= cpu_to_le16(cap_ShortPremble); *(__le16 *)ie |= cpu_to_le16(cap_ShortPremble);
if (pdev_network->Privacy) if (pdev_network->Privacy)
*(u16 *)ie |= cpu_to_le16(cap_Privacy); *(__le16 *)ie |= cpu_to_le16(cap_Privacy);
sz += 2; sz += 2;
ie += 2; ie += 2;
@ -1447,7 +1447,7 @@ void dump_ht_cap_ie_content(void *sel, u8 *buf, u32 buf_len)
, HT_SUP_MCS_SET_ARG(HT_CAP_ELE_SUP_MCS_SET(buf))); , HT_SUP_MCS_SET_ARG(HT_CAP_ELE_SUP_MCS_SET(buf)));
} }
void dump_ht_cap_ie(void *sel, u8 *ie, u32 ie_len) static void dump_ht_cap_ie(void *sel, u8 *ie, u32 ie_len)
{ {
u8 *pos = (u8 *)ie; u8 *pos = (u8 *)ie;
u16 id; u16 id;
@ -2487,7 +2487,7 @@ int ieee80211_get_hdrlen(u16 fc)
return hdrlen; return hdrlen;
} }
int rtw_get_cipher_info(struct wlan_network *pnetwork) static int rtw_get_cipher_info(struct wlan_network *pnetwork)
{ {
u32 wpa_ielen; u32 wpa_ielen;
unsigned char *pbuf; unsigned char *pbuf;

View File

@ -4521,7 +4521,7 @@ void issue_p2p_GO_response(_adapter *padapter, u8 *raddr, u8 *frame_body, uint l
p2pie[p2pielen++] = P2P_ATTR_STATUS; p2pie[p2pielen++] = P2P_ATTR_STATUS;
/* Length: */ /* Length: */
*(u16 *)(p2pie + p2pielen) = cpu_to_le16(0x0001); *(__le16 *)(p2pie + p2pielen) = cpu_to_le16(0x0001);
p2pielen += 2; p2pielen += 2;
/* Value: */ /* Value: */
@ -4532,7 +4532,7 @@ void issue_p2p_GO_response(_adapter *padapter, u8 *raddr, u8 *frame_body, uint l
p2pie[p2pielen++] = P2P_ATTR_CAPABILITY; p2pie[p2pielen++] = P2P_ATTR_CAPABILITY;
/* Length: */ /* Length: */
*(u16 *)(p2pie + p2pielen) = cpu_to_le16(0x0002); *(__le16 *)(p2pie + p2pielen) = cpu_to_le16(0x0002);
p2pielen += 2; p2pielen += 2;
/* Value: */ /* Value: */
@ -4559,7 +4559,7 @@ void issue_p2p_GO_response(_adapter *padapter, u8 *raddr, u8 *frame_body, uint l
p2pie[p2pielen++] = P2P_ATTR_GO_INTENT; p2pie[p2pielen++] = P2P_ATTR_GO_INTENT;
/* Length: */ /* Length: */
*(u16 *)(p2pie + p2pielen) = cpu_to_le16(0x0001); *(__le16 *)(p2pie + p2pielen) = cpu_to_le16(0x0001);
p2pielen += 2; p2pielen += 2;
/* Value: */ /* Value: */
@ -4577,7 +4577,7 @@ void issue_p2p_GO_response(_adapter *padapter, u8 *raddr, u8 *frame_body, uint l
p2pie[p2pielen++] = P2P_ATTR_CONF_TIMEOUT; p2pie[p2pielen++] = P2P_ATTR_CONF_TIMEOUT;
/* Length: */ /* Length: */
*(u16 *)(p2pie + p2pielen) = cpu_to_le16(0x0002); *(__le16 *)(p2pie + p2pielen) = cpu_to_le16(0x0002);
p2pielen += 2; p2pielen += 2;
/* Value: */ /* Value: */
@ -4589,7 +4589,7 @@ void issue_p2p_GO_response(_adapter *padapter, u8 *raddr, u8 *frame_body, uint l
p2pie[p2pielen++] = P2P_ATTR_OPERATING_CH; p2pie[p2pielen++] = P2P_ATTR_OPERATING_CH;
/* Length: */ /* Length: */
*(u16 *)(p2pie + p2pielen) = cpu_to_le16(0x0005); *(__le16 *)(p2pie + p2pielen) = cpu_to_le16(0x0005);
p2pielen += 2; p2pielen += 2;
/* Value: */ /* Value: */
@ -4621,7 +4621,7 @@ void issue_p2p_GO_response(_adapter *padapter, u8 *raddr, u8 *frame_body, uint l
p2pie[p2pielen++] = P2P_ATTR_INTENDED_IF_ADDR; p2pie[p2pielen++] = P2P_ATTR_INTENDED_IF_ADDR;
/* Length: */ /* Length: */
*(u16 *)(p2pie + p2pielen) = cpu_to_le16(ETH_ALEN); *(__le16 *)(p2pie + p2pielen) = cpu_to_le16(ETH_ALEN);
p2pielen += 2; p2pielen += 2;
/* Value: */ /* Value: */
@ -4641,11 +4641,11 @@ void issue_p2p_GO_response(_adapter *padapter, u8 *raddr, u8 *frame_body, uint l
#ifdef CONFIG_CONCURRENT_MODE #ifdef CONFIG_CONCURRENT_MODE
if (rtw_mi_check_status(padapter, MI_LINKED) && padapter->registrypriv.full_ch_in_p2p_handshake == 0) if (rtw_mi_check_status(padapter, MI_LINKED) && padapter->registrypriv.full_ch_in_p2p_handshake == 0)
*(u16 *)(p2pie + p2pielen) = cpu_to_le16(5 + 1); *(__le16 *)(p2pie + p2pielen) = cpu_to_le16(5 + 1);
else else
*(u16 *)(p2pie + p2pielen) = cpu_to_le16(len_channellist_attr); *(__le16 *)(p2pie + p2pielen) = cpu_to_le16(len_channellist_attr);
#else #else
*(u16 *)(p2pie + p2pielen) = cpu_to_le16(len_channellist_attr); *(__le16 *)(p2pie + p2pielen) = cpu_to_le16(len_channellist_attr);
#endif #endif
p2pielen += 2; p2pielen += 2;
@ -4721,7 +4721,7 @@ void issue_p2p_GO_response(_adapter *padapter, u8 *raddr, u8 *frame_body, uint l
/* Length: */ /* Length: */
/* 21->P2P Device Address (6bytes) + Config Methods (2bytes) + Primary Device Type (8bytes) */ /* 21->P2P Device Address (6bytes) + Config Methods (2bytes) + Primary Device Type (8bytes) */
/* + NumofSecondDevType (1byte) + WPS Device Name ID field (2bytes) + WPS Device Name Len field (2bytes) */ /* + NumofSecondDevType (1byte) + WPS Device Name ID field (2bytes) + WPS Device Name Len field (2bytes) */
*(u16 *)(p2pie + p2pielen) = cpu_to_le16(21 + pwdinfo->device_name_len); *(__be16 *)(p2pie + p2pielen) = cpu_to_le16(21 + pwdinfo->device_name_len);
p2pielen += 2; p2pielen += 2;
/* Value: */ /* Value: */
@ -4732,21 +4732,21 @@ void issue_p2p_GO_response(_adapter *padapter, u8 *raddr, u8 *frame_body, uint l
/* Config Method */ /* Config Method */
/* This field should be big endian. Noted by P2P specification. */ /* This field should be big endian. Noted by P2P specification. */
*(u16 *)(p2pie + p2pielen) = cpu_to_be16(pwdinfo->supported_wps_cm); *(__be16 *)(p2pie + p2pielen) = cpu_to_be16(pwdinfo->supported_wps_cm);
p2pielen += 2; p2pielen += 2;
/* Primary Device Type */ /* Primary Device Type */
/* Category ID */ /* Category ID */
*(u16 *)(p2pie + p2pielen) = cpu_to_be16(WPS_PDT_CID_MULIT_MEDIA); *(__be16 *)(p2pie + p2pielen) = cpu_to_be16(WPS_PDT_CID_MULIT_MEDIA);
p2pielen += 2; p2pielen += 2;
/* OUI */ /* OUI */
*(u32 *)(p2pie + p2pielen) = cpu_to_be32(WPSOUI); *(__be32 *)(p2pie + p2pielen) = cpu_to_be32(WPSOUI);
p2pielen += 4; p2pielen += 4;
/* Sub Category ID */ /* Sub Category ID */
*(u16 *)(p2pie + p2pielen) = cpu_to_be16(WPS_PDT_SCID_MEDIA_SERVER); *(__be16 *)(p2pie + p2pielen) = cpu_to_be16(WPS_PDT_SCID_MEDIA_SERVER);
p2pielen += 2; p2pielen += 2;
/* Number of Secondary Device Types */ /* Number of Secondary Device Types */
@ -4754,11 +4754,11 @@ void issue_p2p_GO_response(_adapter *padapter, u8 *raddr, u8 *frame_body, uint l
/* Device Name */ /* Device Name */
/* Type: */ /* Type: */
*(u16 *)(p2pie + p2pielen) = cpu_to_be16(WPS_ATTR_DEVICE_NAME); *(__be16 *)(p2pie + p2pielen) = cpu_to_be16(WPS_ATTR_DEVICE_NAME);
p2pielen += 2; p2pielen += 2;
/* Length: */ /* Length: */
*(u16 *)(p2pie + p2pielen) = cpu_to_be16(pwdinfo->device_name_len); *(__be16 *)(p2pie + p2pielen) = cpu_to_be16(pwdinfo->device_name_len);
p2pielen += 2; p2pielen += 2;
/* Value: */ /* Value: */
@ -4771,7 +4771,7 @@ void issue_p2p_GO_response(_adapter *padapter, u8 *raddr, u8 *frame_body, uint l
p2pie[p2pielen++] = P2P_ATTR_GROUP_ID; p2pie[p2pielen++] = P2P_ATTR_GROUP_ID;
/* Length: */ /* Length: */
*(u16 *)(p2pie + p2pielen) = cpu_to_le16(ETH_ALEN + pwdinfo->nego_ssidlen); *(__le16 *)(p2pie + p2pielen) = cpu_to_le16(ETH_ALEN + pwdinfo->nego_ssidlen);
p2pielen += 2; p2pielen += 2;
/* Value: */ /* Value: */
@ -5056,7 +5056,7 @@ void issue_p2p_invitation_request(_adapter *padapter, u8 *raddr)
struct pkt_attrib *pattrib; struct pkt_attrib *pattrib;
unsigned char *pframe; unsigned char *pframe;
struct rtw_ieee80211_hdr *pwlanhdr; struct rtw_ieee80211_hdr *pwlanhdr;
unsigned short *fctrl; __le16 *fctrl;
struct xmit_priv *pxmitpriv = &(padapter->xmitpriv); struct xmit_priv *pxmitpriv = &(padapter->xmitpriv);
struct mlme_ext_priv *pmlmeext = &(padapter->mlmeextpriv); struct mlme_ext_priv *pmlmeext = &(padapter->mlmeextpriv);
struct mlme_ext_info *pmlmeinfo = &(pmlmeext->mlmext_info); struct mlme_ext_info *pmlmeinfo = &(pmlmeext->mlmext_info);

View File

@ -278,7 +278,7 @@ void rtw_wep_encrypt(_adapter *padapter, u8 *pxmitframe)
length = pattrib->last_txcmdsz - pattrib->hdrlen - pattrib->iv_len - pattrib->icv_len; length = pattrib->last_txcmdsz - pattrib->hdrlen - pattrib->iv_len - pattrib->icv_len;
*((u32 *)crc) = cpu_to_le32(getcrc32(payload, length)); *((__le32 *)crc) = cpu_to_le32(getcrc32(payload, length));
arcfour_init(&mycontext, wepkey, 3 + keylength); arcfour_init(&mycontext, wepkey, 3 + keylength);
arcfour_encrypt(&mycontext, payload, payload, length); arcfour_encrypt(&mycontext, payload, payload, length);
@ -286,7 +286,7 @@ void rtw_wep_encrypt(_adapter *padapter, u8 *pxmitframe)
} else { } else {
length = pxmitpriv->frag_len - pattrib->hdrlen - pattrib->iv_len - pattrib->icv_len ; length = pxmitpriv->frag_len - pattrib->hdrlen - pattrib->iv_len - pattrib->icv_len ;
*((u32 *)crc) = cpu_to_le32(getcrc32(payload, length)); *((__le32 *)crc) = cpu_to_le32(getcrc32(payload, length));
arcfour_init(&mycontext, wepkey, 3 + keylength); arcfour_init(&mycontext, wepkey, 3 + keylength);
arcfour_encrypt(&mycontext, payload, payload, length); arcfour_encrypt(&mycontext, payload, payload, length);
arcfour_encrypt(&mycontext, payload + length, crc, 4); arcfour_encrypt(&mycontext, payload + length, crc, 4);
@ -337,7 +337,7 @@ void rtw_wep_decrypt(_adapter *padapter, u8 *precvframe)
arcfour_encrypt(&mycontext, payload, payload, length); arcfour_encrypt(&mycontext, payload, payload, length);
/* calculate icv and compare the icv */ /* calculate icv and compare the icv */
*((u32 *)crc) = le32_to_cpu(getcrc32(payload, length - 4)); *((__le32 *)crc) = le32_to_cpu(getcrc32(payload, length - 4));
WEP_SW_DEC_CNT_INC(psecuritypriv, prxattrib->ra); WEP_SW_DEC_CNT_INC(psecuritypriv, prxattrib->ra);
@ -761,7 +761,7 @@ u32 rtw_tkip_encrypt(_adapter *padapter, u8 *pxmitframe)
if ((curfragnum + 1) == pattrib->nr_frags) { /* 4 the last fragment */ if ((curfragnum + 1) == pattrib->nr_frags) { /* 4 the last fragment */
length = pattrib->last_txcmdsz - pattrib->hdrlen - pattrib->iv_len - pattrib->icv_len; length = pattrib->last_txcmdsz - pattrib->hdrlen - pattrib->iv_len - pattrib->icv_len;
*((u32 *)crc) = cpu_to_le32(getcrc32(payload, length)); /* modified by Amy*/ *((__le32 *)crc) = cpu_to_le32(getcrc32(payload, length)); /* modified by Amy*/
arcfour_init(&mycontext, rc4key, 16); arcfour_init(&mycontext, rc4key, 16);
arcfour_encrypt(&mycontext, payload, payload, length); arcfour_encrypt(&mycontext, payload, payload, length);
@ -769,7 +769,7 @@ u32 rtw_tkip_encrypt(_adapter *padapter, u8 *pxmitframe)
} else { } else {
length = pxmitpriv->frag_len - pattrib->hdrlen - pattrib->iv_len - pattrib->icv_len ; length = pxmitpriv->frag_len - pattrib->hdrlen - pattrib->iv_len - pattrib->icv_len ;
*((u32 *)crc) = cpu_to_le32(getcrc32(payload, length)); /* modified by Amy*/ *((__le32 *)crc) = cpu_to_le32(getcrc32(payload, length)); /* modified by Amy*/
arcfour_init(&mycontext, rc4key, 16); arcfour_init(&mycontext, rc4key, 16);
arcfour_encrypt(&mycontext, payload, payload, length); arcfour_encrypt(&mycontext, payload, payload, length);
arcfour_encrypt(&mycontext, payload + length, crc, 4); arcfour_encrypt(&mycontext, payload + length, crc, 4);
@ -887,7 +887,7 @@ u32 rtw_tkip_decrypt(_adapter *padapter, u8 *precvframe)
arcfour_init(&mycontext, rc4key, 16); arcfour_init(&mycontext, rc4key, 16);
arcfour_encrypt(&mycontext, payload, payload, length); arcfour_encrypt(&mycontext, payload, payload, length);
*((u32 *)crc) = le32_to_cpu(getcrc32(payload, length - 4)); *((__le32 *)crc) = le32_to_cpu(getcrc32(payload, length - 4));
if (crc[3] != payload[length - 1] || crc[2] != payload[length - 2] || crc[1] != payload[length - 3] || crc[0] != payload[length - 4]) { if (crc[3] != payload[length - 1] || crc[2] != payload[length - 2] || crc[1] != payload[length - 3] || crc[0] != payload[length - 4]) {
res = _FAIL; res = _FAIL;
@ -1373,8 +1373,8 @@ static sint aes_cipher(u8 *key, uint hdrlen,
u8 padded_buffer[16]; u8 padded_buffer[16];
u8 mic[8]; u8 mic[8];
/* uint offset = 0; */ /* uint offset = 0; */
uint frtype = GetFrameType(pframe); __le16 frtype = GetFrameType(pframe);
uint frsubtype = GetFrameSubType(pframe); __le16 frsubtype = GetFrameSubType(pframe);
frsubtype = frsubtype >> 4; frsubtype = frsubtype >> 4;
@ -1682,8 +1682,8 @@ static sint aes_decipher(u8 *key, uint hdrlen,
/* uint offset = 0; */ /* uint offset = 0; */
uint frtype = GetFrameType(pframe); __le16 frtype = GetFrameType(pframe);
uint frsubtype = GetFrameSubType(pframe); __le16 frsubtype = GetFrameSubType(pframe);
frsubtype = frsubtype >> 4; frsubtype = frsubtype >> 4;
@ -2840,7 +2840,7 @@ static int omac1_aes_128_vector(u8 *key, size_t num_elem,
* OMAC1 was standardized with the name CMAC by NIST in a Special Publication * OMAC1 was standardized with the name CMAC by NIST in a Special Publication
* (SP) 800-38B. * (SP) 800-38B.
*/ /* modify for CONFIG_IEEE80211W */ */ /* modify for CONFIG_IEEE80211W */
int omac1_aes_128(u8 *key, u8 *data, size_t data_len, u8 *mac) static int omac1_aes_128(u8 *key, u8 *data, size_t data_len, u8 *mac)
{ {
return omac1_aes_128_vector(key, 1, &data, &data_len, mac); return omac1_aes_128_vector(key, 1, &data, &data_len, mac);
} }

View File

@ -77,7 +77,7 @@ PHYDM_InitDebugSetting(
pDM_Odm->pre_c2h_seq = 0; pDM_Odm->pre_c2h_seq = 0;
} }
VOID static VOID
phydm_BB_RxHang_Info( phydm_BB_RxHang_Info(
IN PVOID pDM_VOID, IN PVOID pDM_VOID,
IN u4Byte *_used, IN u4Byte *_used,
@ -254,7 +254,7 @@ phydm_BB_RxHang_Info(
} }
VOID static VOID
phydm_BB_Debug_Info( phydm_BB_Debug_Info(
IN PVOID pDM_VOID, IN PVOID pDM_VOID,
IN u4Byte *_used, IN u4Byte *_used,
@ -1245,7 +1245,7 @@ phydm_api_trx_mode(
} }
#endif #endif
VOID static VOID
phydm_get_per_path_txagc( phydm_get_per_path_txagc(
IN PVOID pDM_VOID, IN PVOID pDM_VOID,
IN u1Byte path, IN u1Byte path,
@ -1296,7 +1296,7 @@ phydm_get_per_path_txagc(
} }
VOID static VOID
phydm_get_txagc( phydm_get_txagc(
IN PVOID pDM_VOID, IN PVOID pDM_VOID,
IN u4Byte *_used, IN u4Byte *_used,
@ -1326,7 +1326,7 @@ phydm_get_txagc(
} }
VOID static VOID
phydm_set_txagc( phydm_set_txagc(
IN PVOID pDM_VOID, IN PVOID pDM_VOID,
IN u4Byte *const dm_value, IN u4Byte *const dm_value,
@ -1380,7 +1380,7 @@ phydm_set_txagc(
#endif #endif
} }
VOID static VOID
phydm_debug_trace( phydm_debug_trace(
IN PVOID pDM_VOID, IN PVOID pDM_VOID,
IN u4Byte *const dm_value, IN u4Byte *const dm_value,
@ -1445,7 +1445,7 @@ phydm_debug_trace(
PHYDM_SNPRINTF((output + used, out_len - used, "%s\n", "================================")); PHYDM_SNPRINTF((output + used, out_len - used, "%s\n", "================================"));
} }
VOID static VOID
phydm_fw_debug_trace( phydm_fw_debug_trace(
IN PVOID pDM_VOID, IN PVOID pDM_VOID,
IN u4Byte *const dm_value, IN u4Byte *const dm_value,
@ -1497,7 +1497,7 @@ phydm_fw_debug_trace(
} }
} }
VOID static VOID
phydm_DumpBbReg( phydm_DumpBbReg(
IN PVOID pDM_VOID, IN PVOID pDM_VOID,
IN u4Byte *_used, IN u4Byte *_used,
@ -1542,7 +1542,7 @@ phydm_DumpBbReg(
} }
} }
VOID static VOID
phydm_DumpAllReg( phydm_DumpAllReg(
IN PVOID pDM_VOID, IN PVOID pDM_VOID,
IN u4Byte *_used, IN u4Byte *_used,
@ -1591,7 +1591,7 @@ phydm_DumpAllReg(
} }
} }
VOID static VOID
phydm_EnableBigJump( phydm_EnableBigJump(
IN PDM_ODM_T pDM_Odm, IN PDM_ODM_T pDM_Odm,
IN BOOLEAN state IN BOOLEAN state
@ -1693,7 +1693,7 @@ enum PHYDM_CMD_ID {
PHYDM_ANT_SWITCH PHYDM_ANT_SWITCH
}; };
struct _PHYDM_COMMAND phy_dm_ary[] = { static struct _PHYDM_COMMAND phy_dm_ary[] = {
{"-h", PHYDM_HELP}, /*do not move this element to other position*/ {"-h", PHYDM_HELP}, /*do not move this element to other position*/
{"demo", PHYDM_DEMO}, /*do not move this element to other position*/ {"demo", PHYDM_DEMO}, /*do not move this element to other position*/
{"ra", PHYDM_RA}, {"ra", PHYDM_RA},
@ -2969,7 +2969,7 @@ phydm_fw_trace_handler_8051(
int i = 0; int i = 0;
u1Byte Extend_c2hSubID = 0, Extend_c2hDbgLen = 0, Extend_c2hDbgSeq = 0; u1Byte Extend_c2hSubID = 0, Extend_c2hDbgLen = 0, Extend_c2hDbgSeq = 0;
u1Byte fw_debug_trace[128]; u1Byte fw_debug_trace[128];
pu1Byte Extend_c2hDbgContent = 0; pu1Byte Extend_c2hDbgContent = NULL;
if (CmdLen > 127) if (CmdLen > 127)
return; return;

View File

@ -481,7 +481,7 @@ odm_TXPowerTrackingInit(
odm_TXPowerTrackingThermalMeterInit(pDM_Odm); odm_TXPowerTrackingThermalMeterInit(pDM_Odm);
} }
u1Byte static u1Byte
getSwingIndex( getSwingIndex(
IN PVOID pDM_VOID IN PVOID pDM_VOID
) )

View File

@ -848,7 +848,7 @@ phydm_modify_RA_PCR_threshold(
ODM_RT_TRACE(pDM_Odm, ODM_COMP_RA_MASK, ODM_DBG_LOUD, ("Set RA_threshold_offset = (( %s%d ))\n", ((RA_threshold_offset == 0) ? " " : ((RA_offset_direction) ? "+" : "-")), RA_threshold_offset)); ODM_RT_TRACE(pDM_Odm, ODM_COMP_RA_MASK, ODM_DBG_LOUD, ("Set RA_threshold_offset = (( %s%d ))\n", ((RA_threshold_offset == 0) ? " " : ((RA_offset_direction) ? "+" : "-")), RA_threshold_offset));
} }
VOID static VOID
odm_RSSIMonitorCheckMP( odm_RSSIMonitorCheckMP(
IN PVOID pDM_VOID IN PVOID pDM_VOID
) )
@ -1120,7 +1120,7 @@ odm_RSSIMonitorCheckMP(
#if (DM_ODM_SUPPORT_TYPE == ODM_CE) #if (DM_ODM_SUPPORT_TYPE == ODM_CE)
/*H2C_RSSI_REPORT*/ /*H2C_RSSI_REPORT*/
s8 phydm_rssi_report(PDM_ODM_T pDM_Odm, u8 mac_id) static s8 phydm_rssi_report(PDM_ODM_T pDM_Odm, u8 mac_id)
{ {
PADAPTER Adapter = pDM_Odm->Adapter; PADAPTER Adapter = pDM_Odm->Adapter;
pRA_T pRA_Table = &pDM_Odm->DM_RA_Table; pRA_T pRA_Table = &pDM_Odm->DM_RA_Table;
@ -1233,7 +1233,7 @@ s8 phydm_rssi_report(PDM_ODM_T pDM_Odm, u8 mac_id)
return _SUCCESS; return _SUCCESS;
} }
void phydm_ra_rssi_rpt_wk_hdl(PVOID pContext) static void phydm_ra_rssi_rpt_wk_hdl(PVOID pContext)
{ {
PDM_ODM_T pDM_Odm = (PDM_ODM_T)pContext; PDM_ODM_T pDM_Odm = (PDM_ODM_T)pContext;
int i; int i;
@ -1262,7 +1262,7 @@ void phydm_ra_rssi_rpt_wk(PVOID pContext)
} }
#endif #endif
VOID static VOID
odm_RSSIMonitorCheckCE( odm_RSSIMonitorCheckCE(
IN PVOID pDM_VOID IN PVOID pDM_VOID
) )
@ -1317,7 +1317,7 @@ odm_RSSIMonitorCheckCE(
} }
VOID static VOID
odm_RSSIMonitorCheckAP( odm_RSSIMonitorCheckAP(
IN PVOID pDM_VOID IN PVOID pDM_VOID
) )
@ -1582,7 +1582,7 @@ odm_RefreshRateAdaptiveMask(
} }
u1Byte static u1Byte
phydm_trans_platform_bw( phydm_trans_platform_bw(
IN PVOID pDM_VOID, IN PVOID pDM_VOID,
IN u1Byte BW IN u1Byte BW
@ -1646,7 +1646,7 @@ phydm_trans_platform_bw(
} }
u1Byte static u1Byte
phydm_trans_platform_rf_type( phydm_trans_platform_rf_type(
IN PVOID pDM_VOID, IN PVOID pDM_VOID,
IN u1Byte RfType IN u1Byte RfType
@ -1741,7 +1741,7 @@ phydm_trans_platform_rf_type(
} }
u4Byte static u4Byte
phydm_trans_platform_wireless_mode( phydm_trans_platform_wireless_mode(
IN PVOID pDM_VOID, IN PVOID pDM_VOID,
IN u4Byte wireless_mode IN u4Byte wireless_mode
@ -2486,7 +2486,7 @@ phydm_rate_order_compute(
} }
VOID static VOID
phydm_ra_common_info_update( phydm_ra_common_info_update(
IN PVOID pDM_VOID IN PVOID pDM_VOID
) )
@ -2655,7 +2655,7 @@ odm_Find_RTS_Rate(
} }
VOID static VOID
odm_Set_RA_DM_ARFB_by_Noisy( odm_Set_RA_DM_ARFB_by_Noisy(
IN PDM_ODM_T pDM_Odm IN PDM_ODM_T pDM_Odm
) )
@ -3045,7 +3045,7 @@ PhyDM_Get_Rate_Bitmap_Ex(
{ {
PDM_ODM_T pDM_Odm = (PDM_ODM_T)pDM_VOID; PDM_ODM_T pDM_Odm = (PDM_ODM_T)pDM_VOID;
PSTA_INFO_T pEntry; PSTA_INFO_T pEntry;
u8Byte rate_bitmap = 0; u64 rate_bitmap = 0;
u1Byte WirelessMode; u1Byte WirelessMode;
pEntry = pDM_Odm->pODM_StaInfo[macid]; pEntry = pDM_Odm->pODM_StaInfo[macid];
@ -3112,7 +3112,7 @@ PhyDM_Get_Rate_Bitmap_Ex(
if (*(pDM_Odm->pBandWidth) == ODM_BW40M) if (*(pDM_Odm->pBandWidth) == ODM_BW40M)
rate_bitmap = 0x0000000ffffff015; rate_bitmap = 0x0000000ffffff015;
else else
rate_bitmap = 0x0000000ffffff005; rate_bitmap = 0x000000ffffff005;
} }
} }
} }

View File

@ -160,26 +160,8 @@ typedef struct tag_HAL_VERSION {
/* ---------------------------------------------------------------------------- /* ----------------------------------------------------------------------------
* Chip version Macro. -- * Chip version Macro. --
* ---------------------------------------------------------------------------- */ * ---------------------------------------------------------------------------- */
#if 0
#define IS_81XXC_TEST_CHIP(version) ((IS_81XXC(version) && (!IS_NORMAL_CHIP(version))) ? TRUE : FALSE)
#define IS_92C_SERIAL(version) ((IS_81XXC(version) && IS_2T2R(version)) ? TRUE : FALSE) #define IS_VENDOR_8188E_I_CUT_SERIES(_Adapter) ((IS_8188E(GET_HAL_DATA((PADAPTER)_Adapter)->VersionID)) ? ((GET_CVID_CUT_VERSION(GET_HAL_DATA((PADAPTER)_Adapter)->VersionID) >= I_CUT_VERSION) ? TRUE : FALSE) : FALSE)
#define IS_81xxC_VENDOR_UMC_A_CUT(version) (IS_81XXC(version) ? (IS_CHIP_VENDOR_UMC(version) ? (IS_A_CUT(version) ? TRUE : FALSE) : FALSE) : FALSE)
#define IS_81xxC_VENDOR_UMC_B_CUT(version) (IS_81XXC(version) ? (IS_CHIP_VENDOR_UMC(version) ? (IS_B_CUT(version) ? TRUE : FALSE) : FALSE) : FALSE)
#define IS_81xxC_VENDOR_UMC_C_CUT(version) (IS_81XXC(version) ? (IS_CHIP_VENDOR_UMC(version) ? (IS_C_CUT(version) ? TRUE : FALSE) : FALSE) : FALSE)
#define IS_NORMAL_CHIP92D(version) ((IS_92D(version)) ? ((GET_CVID_CHIP_TYPE(version) == NORMAL_CHIP) ? TRUE : FALSE) : FALSE)
#define IS_92D_SINGLEPHY(version) ((IS_92D(version)) ? (IS_2T2R(version) ? TRUE : FALSE) : FALSE)
#define IS_92D_C_CUT(version) ((IS_92D(version)) ? (IS_C_CUT(version) ? TRUE : FALSE) : FALSE)
#define IS_92D_D_CUT(version) ((IS_92D(version)) ? (IS_D_CUT(version) ? TRUE : FALSE) : FALSE)
#define IS_92D_E_CUT(version) ((IS_92D(version)) ? (IS_E_CUT(version) ? TRUE : FALSE) : FALSE)
#define IS_8723A_A_CUT(version) ((IS_8723_SERIES(version)) ? (IS_A_CUT(version) ? TRUE : FALSE) : FALSE)
#define IS_8723A_B_CUT(version) ((IS_8723_SERIES(version)) ? (IS_B_CUT(version) ? TRUE : FALSE) : FALSE)
#endif
#define IS_VENDOR_8188E_I_CUT_SERIES(_Adapter) ((IS_8188E(GET_HAL_DATA(_Adapter)->VersionID)) ? ((GET_CVID_CUT_VERSION(GET_HAL_DATA(_Adapter)->VersionID) >= I_CUT_VERSION) ? TRUE : FALSE) : FALSE)
#define IS_VENDOR_8812A_TEST_CHIP(_Adapter) ((IS_8812_SERIES(GET_HAL_DATA(_Adapter)->VersionID)) ? ((IS_NORMAL_CHIP(GET_HAL_DATA(_Adapter)->VersionID)) ? FALSE : TRUE) : FALSE) #define IS_VENDOR_8812A_TEST_CHIP(_Adapter) ((IS_8812_SERIES(GET_HAL_DATA(_Adapter)->VersionID)) ? ((IS_NORMAL_CHIP(GET_HAL_DATA(_Adapter)->VersionID)) ? FALSE : TRUE) : FALSE)
#define IS_VENDOR_8812A_MP_CHIP(_Adapter) ((IS_8812_SERIES(GET_HAL_DATA(_Adapter)->VersionID)) ? ((IS_NORMAL_CHIP(GET_HAL_DATA(_Adapter)->VersionID)) ? TRUE : FALSE) : FALSE) #define IS_VENDOR_8812A_MP_CHIP(_Adapter) ((IS_8812_SERIES(GET_HAL_DATA(_Adapter)->VersionID)) ? ((IS_NORMAL_CHIP(GET_HAL_DATA(_Adapter)->VersionID)) ? TRUE : FALSE) : FALSE)

View File

@ -20,6 +20,8 @@
#ifndef __RTW_DEBUG_H__ #ifndef __RTW_DEBUG_H__
#define __RTW_DEBUG_H__ #define __RTW_DEBUG_H__
#include <linux/trace_seq.h>
/* driver log level*/ /* driver log level*/
enum { enum {
_DRV_NONE_ = 0, _DRV_NONE_ = 0,
@ -257,7 +259,7 @@ extern uint rtw_drv_log_level;
if (sel == RTW_DBGDUMP)\ if (sel == RTW_DBGDUMP)\
RTW_PRINT(fmt, ##arg); \ RTW_PRINT(fmt, ##arg); \
else {\ else {\
_seqdump(sel, fmt, ##arg) /*rtw_warn_on(1)*/; \ _seqdump((struct seq_file *)sel, fmt, ##arg) /*rtw_warn_on(1)*/; \
} \ } \
} while (0) } while (0)

View File

@ -147,9 +147,9 @@ struct st_cmd_parm {
u8 cmd; u8 cmd;
struct sta_info *sta; struct sta_info *sta;
u32 local_naddr; /* TODO: IPV6 */ u32 local_naddr; /* TODO: IPV6 */
u16 local_port; __be16 local_port;
u32 remote_naddr; /* TODO: IPV6 */ u32 remote_naddr; /* TODO: IPV6 */
u16 remote_port; __be16 remote_port;
}; };
typedef bool (*st_match_rule)(_adapter *adapter, u8 *local_naddr, u8 *local_port, u8 *remote_naddr, u8 *remote_port); typedef bool (*st_match_rule)(_adapter *adapter, u8 *local_naddr, u8 *local_port, u8 *remote_naddr, u8 *remote_port);