rtl8188eu: Remove CONFIG_80211N_HT

This one is always selected.

Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net>
This commit is contained in:
Larry Finger 2015-02-20 20:30:23 -06:00
parent 37a28f802f
commit 2b27b83d40
21 changed files with 100 additions and 379 deletions

View file

@ -548,12 +548,10 @@ void add_RATid(struct adapter *padapter, struct sta_info *psta, u8 rssi_level)
struct mlme_priv *pmlmepriv = &(padapter->mlmepriv);
WLAN_BSSID_EX *pcur_network = (WLAN_BSSID_EX *)&pmlmepriv->cur_network.network;
#ifdef CONFIG_80211N_HT
if(psta)
psta_ht = &psta->htpriv;
else
return;
#endif /* CONFIG_80211N_HT */
if(!(psta->state & _FW_LINKED))
return;
@ -564,7 +562,6 @@ void add_RATid(struct adapter *padapter, struct sta_info *psta, u8 rssi_level)
if (psta->bssrateset[i])
tx_ra_bitmap |= rtw_get_bit_value_from_ieee_value(psta->bssrateset[i]&0x7f);
}
#ifdef CONFIG_80211N_HT
/* n mode ra_bitmap */
if(psta_ht->ht_option)
{
@ -582,7 +579,6 @@ void add_RATid(struct adapter *padapter, struct sta_info *psta, u8 rssi_level)
/* max short GI rate */
shortGIrate = psta_ht->sgi;
}
#endif /* CONFIG_80211N_HT */
if ( pcur_network->Configuration.DSConfig > 14 ) {
/* 5G band */
@ -664,9 +660,7 @@ void update_bmc_sta(struct adapter *padapter)
psta->mac_id = psta->aid + 1;
psta->qos_option = 0;
#ifdef CONFIG_80211N_HT
psta->htpriv.ht_option = false;
#endif /* CONFIG_80211N_HT */
psta->ieee8021x_blocked = 0;
@ -759,10 +753,8 @@ void update_sta_info_apmode(struct adapter *padapter, struct sta_info *psta)
struct mlme_priv *pmlmepriv = &(padapter->mlmepriv);
struct security_priv *psecuritypriv = &padapter->securitypriv;
struct mlme_ext_priv *pmlmeext = &(padapter->mlmeextpriv);
#ifdef CONFIG_80211N_HT
struct ht_priv *phtpriv_ap = &pmlmepriv->htpriv;
struct ht_priv *phtpriv_sta = &psta->htpriv;
#endif /* CONFIG_80211N_HT */
/* set intf_tag to if1 */
/* psta->intf_tag = 0; */
@ -783,7 +775,6 @@ void update_sta_info_apmode(struct adapter *padapter, struct sta_info *psta)
/* ERP */
VCS_update(padapter, psta);
#ifdef CONFIG_80211N_HT
/* HT related cap */
if(phtpriv_sta->ht_option)
{
@ -824,7 +815,6 @@ void update_sta_info_apmode(struct adapter *padapter, struct sta_info *psta)
send_delba(padapter, 1, psta->hwaddr);/* originator */
phtpriv_sta->agg_enable_bitmap = 0x0;/* reset */
phtpriv_sta->candidate_tid_bitmap = 0x0;/* reset */
#endif /* CONFIG_80211N_HT */
/* todo: init other variables */
@ -913,7 +903,6 @@ static void start_bss_network(struct adapter *padapter, u8 *pbuf)
/* pmlmeinfo->HT_enable; */
if(pmlmepriv->qospriv.qos_option)
pmlmeinfo->WMM_enable = true;
#ifdef CONFIG_80211N_HT
if(pmlmepriv->htpriv.ht_option)
{
pmlmeinfo->WMM_enable = true;
@ -923,8 +912,6 @@ static void start_bss_network(struct adapter *padapter, u8 *pbuf)
update_hw_ht_param(padapter);
}
#endif /* CONFIG_80211N_HT */
if(pmlmepriv->cur_network.join_res != true) /* setting only at first time */
{
@ -965,7 +952,6 @@ static void start_bss_network(struct adapter *padapter, u8 *pbuf)
/* turn on all dynamic functions */
Switch_DM_Func(padapter, DYNAMIC_ALL_FUNC_ENABLE, true);
}
#ifdef CONFIG_80211N_HT
/* set channel, bwmode */
p = rtw_get_ie((pnetwork->IEs + sizeof(NDIS_802_11_FIXED_IEs)), _HT_ADD_INFO_IE_, &ie_len, (pnetwork->IELength - sizeof(NDIS_802_11_FIXED_IEs)));
if( p && ie_len)
@ -998,7 +984,6 @@ static void start_bss_network(struct adapter *padapter, u8 *pbuf)
}
}
#endif /* CONFIG_80211N_HT */
/* TODO: need to judge the phy parameters on concurrent mode for single phy */
/* set_channel_bwmode(padapter, pmlmeext->cur_channel, pmlmeext->cur_ch_offset, pmlmeext->cur_bwmode); */
set_channel_bwmode(padapter, cur_channel, cur_ch_offset, cur_bwmode);
@ -1245,7 +1230,6 @@ int rtw_check_beacon_data(struct adapter *padapter, u8 *pbuf, int len)
}
}
}
#ifdef CONFIG_80211N_HT
/* parsing HT_CAP_IE */
p = rtw_get_ie(ie + _BEACON_IE_OFFSET_, _HT_CAPABILITY_IE_, &ie_len, (pbss_network->IELength - _BEACON_IE_OFFSET_));
if(p && ie_len>0)
@ -1291,7 +1275,6 @@ int rtw_check_beacon_data(struct adapter *padapter, u8 *pbuf, int len)
{
pHT_info_ie=p;
}
#endif /* CONFIG_80211N_HT */
switch(network_type)
{
case WIRELESS_11B:
@ -1313,7 +1296,6 @@ int rtw_check_beacon_data(struct adapter *padapter, u8 *pbuf, int len)
pmlmepriv->cur_network.network_type = network_type;
#ifdef CONFIG_80211N_HT
pmlmepriv->htpriv.ht_option = false;
if( (psecuritypriv->wpa2_pairwise_cipher&WPA_CIPHER_TKIP) ||
@ -1338,9 +1320,6 @@ int rtw_check_beacon_data(struct adapter *padapter, u8 *pbuf, int len)
HT_info_handler(padapter, (PNDIS_802_11_VARIABLE_IEs)pHT_info_ie);
}
#endif
pbss_network->Length = get_WLAN_BSSID_EX_sz((WLAN_BSSID_EX *)pbss_network);
/* issue beacon to start bss network */
@ -1733,8 +1712,6 @@ void update_beacon(struct adapter *padapter, u8 ie_id, u8 *oui, u8 tx)
set_tx_beacon_cmd(padapter);
}
#ifdef CONFIG_80211N_HT
/*
op_mode
Set to 0 (HT pure) under the followign conditions
@ -1818,8 +1795,6 @@ static int rtw_ht_operation_update(struct adapter *padapter)
}
#endif /* CONFIG_80211N_HT */
void associated_clients_update(struct adapter *padapter, u8 updated)
{
/* update associcated stations cap. */
@ -1944,8 +1919,6 @@ void bss_cap_update_on_sta_join(struct adapter *padapter, struct sta_info *psta)
}
}
#ifdef CONFIG_80211N_HT
if (psta->flags & WLAN_STA_HT)
{
u16 ht_capab = le16_to_cpu(psta->htpriv.ht_cap.cap_info);
@ -2001,8 +1974,6 @@ void bss_cap_update_on_sta_join(struct adapter *padapter, struct sta_info *psta)
update_beacon(padapter, _HT_ADD_INFO_IE_, NULL, true);
}
#endif /* CONFIG_80211N_HT */
/* update associcated stations cap. */
associated_clients_update(padapter, beacon_updated);
@ -2051,8 +2022,6 @@ u8 bss_cap_update_on_sta_leave(struct adapter *padapter, struct sta_info *psta)
}
}
#ifdef CONFIG_80211N_HT
if (psta->no_ht_gf_set) {
psta->no_ht_gf_set = 0;
pmlmepriv->num_sta_ht_no_gf--;
@ -2074,8 +2043,6 @@ u8 bss_cap_update_on_sta_leave(struct adapter *padapter, struct sta_info *psta)
update_beacon(padapter, _HT_ADD_INFO_IE_, NULL, true);
}
#endif /* CONFIG_80211N_HT */
DBG_871X("%s, updated=%d\n", __func__, beacon_updated);
return beacon_updated;
@ -2095,18 +2062,14 @@ u8 ap_free_sta(struct adapter *padapter, struct sta_info *psta, bool active, u16
if (active == true)
{
#ifdef CONFIG_80211N_HT
/* tear down Rx AMPDU */
send_delba(padapter, 0, psta->hwaddr);/* recipient */
/* tear down TX AMPDU */
send_delba(padapter, 1, psta->hwaddr);/* originator */
#endif /* CONFIG_80211N_HT */
issue_deauth(padapter, psta->hwaddr, reason);
}
psta->htpriv.agg_enable_bitmap = 0x0;/* reset */
psta->htpriv.candidate_tid_bitmap = 0x0;/* reset */
@ -2256,8 +2219,6 @@ void sta_info_update(struct adapter *padapter, struct sta_info *psta)
if(pmlmepriv->qospriv.qos_option == 0)
psta->qos_option = 0;
#ifdef CONFIG_80211N_HT
/* update 802.11n ht cap. */
if(WLAN_STA_HT&flags)
{
@ -2271,12 +2232,8 @@ void sta_info_update(struct adapter *padapter, struct sta_info *psta)
if(pmlmepriv->htpriv.ht_option == false)
psta->htpriv.ht_option = false;
#endif
update_sta_info_apmode(padapter, psta);
}
/* called >= TSR LEVEL for USB or SDIO Interface*/
@ -2376,18 +2333,14 @@ void start_ap_mode(struct adapter *padapter)
pmlmepriv->num_sta_no_short_preamble = 0;
pmlmepriv->num_sta_ht_no_gf = 0;
#ifdef CONFIG_80211N_HT
pmlmepriv->num_sta_no_ht = 0;
#endif /* CONFIG_80211N_HT */
pmlmepriv->num_sta_ht_20mhz = 0;
pmlmepriv->olbc = false;
pmlmepriv->olbc_ht = false;
#ifdef CONFIG_80211N_HT
pmlmepriv->ht_op_mode = 0;
#endif
for(i=0; i<NUM_STA; i++)
pstapriv->sta_aid[i] = NULL;

View file

@ -1144,9 +1144,7 @@ u8 rtw_joinbss_cmd(struct adapter *padapter, struct wlan_network* pnetwork)
struct qos_priv *pqospriv= &pmlmepriv->qospriv;
struct security_priv *psecuritypriv=&padapter->securitypriv;
struct registry_priv *pregistrypriv = &padapter->registrypriv;
#ifdef CONFIG_80211N_HT
struct ht_priv *phtpriv = &pmlmepriv->htpriv;
#endif /* CONFIG_80211N_HT */
NDIS_802_11_NETWORK_INFRASTRUCTURE ndis_network_mode = pnetwork->network.InfrastructureMode;
struct mlme_ext_priv *pmlmeext = &padapter->mlmeextpriv;
struct mlme_ext_info *pmlmeinfo = &(pmlmeext->mlmext_info);
@ -1251,7 +1249,6 @@ u8 rtw_joinbss_cmd(struct adapter *padapter, struct wlan_network* pnetwork)
}
}
#ifdef CONFIG_80211N_HT
phtpriv->ht_option = false;
if(pregistrypriv->ht_enable)
{
@ -1267,9 +1264,6 @@ u8 rtw_joinbss_cmd(struct adapter *padapter, struct wlan_network* pnetwork)
pnetwork->network.IELength, &psecnetwork->IELength);
}
}
#endif
pmlmeinfo->assoc_AP_vendor = check_assoc_AP(pnetwork->network.IEs, pnetwork->network.IELength);
if (pmlmeinfo->assoc_AP_vendor == HT_IOT_PEER_TENDA)

View file

@ -289,9 +289,7 @@ int proc_get_ht_option(char *page, char **start,
struct mlme_priv *pmlmepriv = &(padapter->mlmepriv);
int len = 0;
#ifdef CONFIG_80211N_HT
len += snprintf(page + len, count - len, "ht_option=%d\n", pmlmepriv->htpriv.ht_option);
#endif /* CONFIG_80211N_HT */
*eof = 1;
return len;
}
@ -338,12 +336,10 @@ int proc_get_ap_info(char *page, char **start,
len += snprintf(page + len, count - len, "cur_channel=%d, cur_bwmode=%d, cur_ch_offset=%d\n", pmlmeext->cur_channel, pmlmeext->cur_bwmode, pmlmeext->cur_ch_offset);
len += snprintf(page + len, count - len, "rtsen=%d, cts2slef=%d\n", psta->rtsen, psta->cts2self);
len += snprintf(page + len, count - len, "state=0x%x, aid=%d, macid=%d, raid=%d\n", psta->state, psta->aid, psta->mac_id, psta->raid);
#ifdef CONFIG_80211N_HT
len += snprintf(page + len, count - len, "qos_en=%d, ht_en=%d, init_rate=%d\n", psta->qos_option, psta->htpriv.ht_option, psta->init_rate);
len += snprintf(page + len, count - len, "bwmode=%d, ch_offset=%d, sgi=%d\n", psta->htpriv.bwmode, psta->htpriv.ch_offset, psta->htpriv.sgi);
len += snprintf(page + len, count - len, "ampdu_enable = %d\n", psta->htpriv.ampdu_enable);
len += snprintf(page + len, count - len, "agg_enable_bitmap=%x, candidate_tid_bitmap=%x\n", psta->htpriv.agg_enable_bitmap, psta->htpriv.candidate_tid_bitmap);
#endif /* CONFIG_80211N_HT */
for(i=0;i<16;i++)
{
@ -711,7 +707,6 @@ int proc_set_rx_signal(struct file *file, const char __user *buffer,
return count;
}
#ifdef CONFIG_80211N_HT
int proc_get_ht_enable(char *page, char **start,
off_t offset, int count,
@ -856,7 +851,6 @@ int proc_set_ampdu_enable(struct file *file, const char __user *buffer,
return count;
}
#endif /* CONFIG_80211N_HT */
int proc_get_two_path_rssi(char *page, char **start,
off_t offset, int count,
@ -877,7 +871,7 @@ int proc_get_two_path_rssi(char *page, char **start,
*eof = 1;
return len;
}
#ifdef CONFIG_80211N_HT
int proc_get_rx_stbc(char *page, char **start,
off_t offset, int count,
int *eof, void *data)
@ -924,8 +918,6 @@ int proc_set_rx_stbc(struct file *file, const char __user *buffer,
return count;
}
#endif /* CONFIG_80211N_HT */
int proc_get_rssi_disp(char *page, char **start,
off_t offset, int count,
@ -1013,12 +1005,10 @@ int proc_get_all_sta_info(char *page, char **start,
len += snprintf(page + len, count - len, "sta's macaddr:" MAC_FMT "\n", MAC_ARG(psta->hwaddr));
len += snprintf(page + len, count - len, "rtsen=%d, cts2slef=%d\n", psta->rtsen, psta->cts2self);
len += snprintf(page + len, count - len, "state=0x%x, aid=%d, macid=%d, raid=%d\n", psta->state, psta->aid, psta->mac_id, psta->raid);
#ifdef CONFIG_80211N_HT
len += snprintf(page + len, count - len, "qos_en=%d, ht_en=%d, init_rate=%d\n", psta->qos_option, psta->htpriv.ht_option, psta->init_rate);
len += snprintf(page + len, count - len, "bwmode=%d, ch_offset=%d, sgi=%d\n", psta->htpriv.bwmode, psta->htpriv.ch_offset, psta->htpriv.sgi);
len += snprintf(page + len, count - len, "ampdu_enable = %d\n", psta->htpriv.ampdu_enable);
len += snprintf(page + len, count - len, "agg_enable_bitmap=%x, candidate_tid_bitmap=%x\n", psta->htpriv.agg_enable_bitmap, psta->htpriv.candidate_tid_bitmap);
#endif /* CONFIG_80211N_HT */
len += snprintf(page + len, count - len, "sleepq_len=%d\n", psta->sleepq_len);
len += snprintf(page + len, count - len, "capability=0x%x\n", psta->capability);
len += snprintf(page + len, count - len, "flags=0x%x\n", psta->flags);

View file

@ -478,14 +478,12 @@ int rtw_generate_ie(struct registry_priv *pregistrypriv)
ie = rtw_set_ie(ie, _EXT_SUPPORTEDRATES_IE_, (rateLen - 8), (pdev_network->SupportedRates + 8), &sz);
}
#ifdef CONFIG_80211N_HT
/* HT Cap. */
if(((pregistrypriv->wireless_mode&WIRELESS_11_5N)||(pregistrypriv->wireless_mode&WIRELESS_11_24N))
&& (pregistrypriv->ht_enable==true))
{
/* todo: */
}
#endif /* CONFIG_80211N_HT */
/* return _SUCCESS; */
return sz;

View file

@ -1223,19 +1223,16 @@ u16 rtw_get_cur_max_rate(struct adapter *adapter)
struct registry_priv *pregistrypriv = &adapter->registrypriv;
struct mlme_priv *pmlmepriv = &adapter->mlmepriv;
WLAN_BSSID_EX *pcur_bss = &pmlmepriv->cur_network.network;
#ifdef CONFIG_80211N_HT
struct rtw_ieee80211_ht_cap *pht_capie;
u8 rf_type = 0;
u8 bw_40MHz=0, short_GI_20=0, short_GI_40=0;
u16 mcs_rate=0;
u32 ht_ielen = 0;
#endif
if((check_fwstate(pmlmepriv, _FW_LINKED) != true)
&& (check_fwstate(pmlmepriv, WIFI_ADHOC_MASTER_STATE) != true))
return 0;
#ifdef CONFIG_80211N_HT
if (pmlmeext->cur_wireless_mode & (WIRELESS_11_24N|WIRELESS_11_5N)) {
p = rtw_get_ie(&pcur_bss->IEs[12], _HT_CAPABILITY_IE_, &ht_ielen, pcur_bss->IELength-12);
if(p && ht_ielen>0)
@ -1263,7 +1260,6 @@ u16 rtw_get_cur_max_rate(struct adapter *adapter)
}
}
else
#endif /* CONFIG_80211N_HT */
{
while( (pcur_bss->SupportedRates[i]!=0) && (pcur_bss->SupportedRates[i]!=0xFF))
{

View file

@ -1693,15 +1693,9 @@ static void rtw_joinbss_update_network(struct adapter *padapter, struct wlan_net
RT_TRACE(_module_rtl871x_mlme_c_,_drv_err_,("Invalid network_mode\n"));
break;
}
rtw_update_protection(padapter, (cur_network->network.IEs) + sizeof (NDIS_802_11_FIXED_IEs),
(cur_network->network.IELength));
#ifdef CONFIG_80211N_HT
rtw_update_ht_cap(padapter, cur_network->network.IEs, cur_network->network.IELength);
#endif
}
/* Notes: the fucntion could be > passive_level (the same context as Rx tasklet) */
@ -3005,18 +2999,10 @@ void rtw_joinbss_reset(struct adapter *padapter)
{
u8 threshold;
struct mlme_priv *pmlmepriv = &padapter->mlmepriv;
#ifdef CONFIG_80211N_HT
struct ht_priv *phtpriv = &pmlmepriv->htpriv;
#endif
/* todo: if you want to do something io/reg/hw setting before join_bss, please add code here */
#ifdef CONFIG_80211N_HT
pmlmepriv->num_FortyMHzIntolerant = 0;
pmlmepriv->num_sta_no_ht = 0;
@ -3038,12 +3024,8 @@ void rtw_joinbss_reset(struct adapter *padapter)
threshold = 1;
rtw_hal_set_hwreg(padapter, HW_VAR_RXDMA_AGG_PG_TH, (u8 *)(&threshold));
}
#endif
}
#ifdef CONFIG_80211N_HT
/* the fucntion is >= passive_level */
unsigned int rtw_restructure_ht_ie(struct adapter *padapter, u8 *in_ie, u8 *out_ie, uint in_len, uint *pout_len)
{
@ -3303,8 +3285,6 @@ void rtw_issue_addbareq_cmd(struct adapter *padapter, struct xmit_frame *pxmitfr
}
#endif
#ifdef CONFIG_LAYER2_ROAMING
inline void rtw_set_roaming(struct adapter *adapter, u8 to_roaming)
{

View file

@ -1748,8 +1748,6 @@ unsigned int OnAssocReq(struct adapter *padapter, union recv_frame *precv_frame)
}
}
#ifdef CONFIG_80211N_HT
/* save HT capabilities in the sta object */
memset(&pstat->htpriv.ht_cap, 0, sizeof(struct rtw_ieee80211_ht_cap));
if (elems.ht_capabilities && elems.ht_capabilities_len >= sizeof(struct rtw_ieee80211_ht_cap))
@ -1781,7 +1779,6 @@ unsigned int OnAssocReq(struct adapter *padapter, union recv_frame *precv_frame)
/* status = WLAN_STATUS_CIPHER_REJECTED_PER_POLICY; */
/* goto OnAssocReqFail; */
}
#endif /* CONFIG_80211N_HT */
/* */
pstat->flags |= WLAN_STA_NONERP;
@ -2359,7 +2356,6 @@ unsigned int OnAction_back(struct adapter *padapter, union recv_frame *precv_fra
struct mlme_ext_info *pmlmeinfo = &(pmlmeext->mlmext_info);
u8 *pframe = precv_frame->u.hdr.rx_data;
struct sta_priv *pstapriv = &padapter->stapriv;
#ifdef CONFIG_80211N_HT
/* check RA matches or not */
if (!_rtw_memcmp(myid(&(padapter->eeprompriv)), GetAddr1Ptr(pframe), ETH_ALEN))/* for if1, sta/ap mode */
return _SUCCESS;
@ -2463,7 +2459,6 @@ unsigned int OnAction_back(struct adapter *padapter, union recv_frame *precv_fra
break;
}
}
#endif /* CONFIG_80211N_HT */
return _SUCCESS;
}
@ -6713,7 +6708,6 @@ void issue_asocrsp(struct adapter *padapter, unsigned short status, struct sta_i
pframe = rtw_set_ie(pframe, _EXT_SUPPORTEDRATES_IE_, (pstat->bssratelen-8), pstat->bssrateset+8, &(pattrib->pktlen));
}
#ifdef CONFIG_80211N_HT
if ((pstat->flags & WLAN_STA_HT) && (pmlmepriv->htpriv.ht_option)) {
uint ie_len=0;
@ -6736,7 +6730,6 @@ void issue_asocrsp(struct adapter *padapter, unsigned short status, struct sta_i
}
}
#endif
/* FILL WMM IE */
if ((pstat->flags & WLAN_STA_WME) && (pmlmepriv->qospriv.qos_option)) {
@ -6947,7 +6940,6 @@ void issue_assocreq(struct adapter *padapter)
if (p != NULL)
pframe = rtw_set_ie(pframe, _RSN_IE_2_, ie_len, (p + 2), &(pattrib->pktlen));
#ifdef CONFIG_80211N_HT
/* HT caps */
if(padapter->mlmepriv.htpriv.ht_option==true) {
p = rtw_get_ie((pmlmeinfo->network.IEs + sizeof(NDIS_802_11_FIXED_IEs)), _HT_CAPABILITY_IE_, &ie_len, (pmlmeinfo->network.IELength - sizeof(NDIS_802_11_FIXED_IEs)));
@ -7006,7 +6998,6 @@ void issue_assocreq(struct adapter *padapter)
{
/* set to 8K */
pmlmeinfo->HT_caps.u.HT_cap_element.AMPDU_para &= (u8)~IEEE80211_HT_CAP_AMPDU_FACTOR;
/* pmlmeinfo->HT_caps.u.HT_cap_element.AMPDU_para |= MAX_AMPDU_FACTOR_8K */
}
#endif
@ -7014,7 +7005,6 @@ void issue_assocreq(struct adapter *padapter)
}
}
#endif
/* vendor specific IE, such as WPA, WMM, WPS */
for (i = sizeof(NDIS_802_11_FIXED_IEs); i < pmlmeinfo->network.IELength;)
@ -7798,7 +7788,6 @@ static void issue_action_BA(struct adapter *padapter, unsigned char *raddr,
u8 tendaAPMac[] = {0xC8, 0x3A, 0x35};
#endif
#ifdef CONFIG_80211N_HT
DBG_871X("%s, category=%d, action=%d, status=%d\n", __FUNCTION__, category, action, status);
if ((pmgntframe = alloc_mgtxmitframe(pxmitpriv)) == NULL)
@ -7932,7 +7921,6 @@ static void issue_action_BA(struct adapter *padapter, unsigned char *raddr,
pattrib->last_txcmdsz = pattrib->pktlen;
dump_mgntframe(padapter, pmgntframe);
#endif /* CONFIG_80211N_HT */
}
static void issue_action_BSSCoexistPacket(struct adapter *padapter)
@ -7953,7 +7941,6 @@ static void issue_action_BSSCoexistPacket(struct adapter *padapter)
_queue *queue = &(pmlmepriv->scanned_queue);
u8 InfoContent[16] = {0};
u8 ICS[8][15];
#ifdef CONFIG_80211N_HT
if((pmlmepriv->num_FortyMHzIntolerant==0) || (pmlmepriv->num_sta_no_ht==0))
return;
@ -8044,16 +8031,13 @@ static void issue_action_BSSCoexistPacket(struct adapter *padapter)
continue;
ICS[0][pbss_network->Configuration.DSConfig]=1;
if(ICS[0][0] == 0)
ICS[0][0] = 1;
}
}
_exit_critical_bh(&(pmlmepriv->scanned_queue.lock), &irqL);
for(i= 0;i<8;i++)
{
if(ICS[i][0] == 1)
@ -8076,21 +8060,13 @@ static void issue_action_BSSCoexistPacket(struct adapter *padapter)
}
}
}
pframe = rtw_set_ie(pframe, EID_BSSIntolerantChlReport, k, InfoContent, &(pattrib->pktlen));
}
}
}
pattrib->last_txcmdsz = pattrib->pktlen;
dump_mgntframe(padapter, pmgntframe);
#endif /* CONFIG_80211N_HT */
}
unsigned int send_delba(struct adapter *padapter, u8 initiator, u8 *addr)
@ -8132,7 +8108,6 @@ unsigned int send_delba(struct adapter *padapter, u8 initiator, u8 *addr)
}
else if(initiator == 1)/* originator */
{
#ifdef CONFIG_80211N_HT
/* DBG_871X("tx agg_enable_bitmap(0x%08x)\n", psta->htpriv.agg_enable_bitmap); */
for(tid = 0;tid<MAXTID;tid++)
{
@ -8146,11 +8121,8 @@ unsigned int send_delba(struct adapter *padapter, u8 initiator, u8 *addr)
}
}
#endif /* CONFIG_80211N_HT */
}
return _SUCCESS;
}
unsigned int send_beacon(struct adapter *padapter)
@ -8664,7 +8636,6 @@ u8 collect_bss_info(struct adapter *padapter, union recv_frame *precv_frame, WLA
if((pregistrypriv->wifi_spec==1) && (false == pmlmeinfo->bwmode_updated))
{
struct mlme_priv *pmlmepriv = &padapter->mlmepriv;
#ifdef CONFIG_80211N_HT
p = rtw_get_ie(bssid->IEs + ie_offset, _HT_CAPABILITY_IE_, &len, bssid->IELength - ie_offset);
if (p && len > 0) {
struct HT_caps_element *pHT_caps;
@ -8675,8 +8646,6 @@ u8 collect_bss_info(struct adapter *padapter, union recv_frame *precv_frame, WLA
} else {
pmlmepriv->num_sta_no_ht++;
}
#endif /* CONFIG_80211N_HT */
}
#ifdef CONFIG_INTEL_WIDI
@ -9508,7 +9477,6 @@ void update_sta_info(struct adapter *padapter, struct sta_info *psta)
/* ERP */
VCS_update(padapter, psta);
#ifdef CONFIG_80211N_HT
/* HT */
if(pmlmepriv->htpriv.ht_option)
{
@ -9523,25 +9491,20 @@ void update_sta_info(struct adapter *padapter, struct sta_info *psta)
}
else
#endif /* CONFIG_80211N_HT */
{
#ifdef CONFIG_80211N_HT
psta->htpriv.ht_option = false;
psta->htpriv.ampdu_enable = false;
psta->htpriv.sgi = false;
#endif /* CONFIG_80211N_HT */
psta->qos_option = false;
}
#ifdef CONFIG_80211N_HT
psta->htpriv.bwmode = pmlmeext->cur_bwmode;
psta->htpriv.ch_offset = pmlmeext->cur_ch_offset;
psta->htpriv.agg_enable_bitmap = 0x0;/* reset */
psta->htpriv.candidate_tid_bitmap = 0x0;/* reset */
#endif /* CONFIG_80211N_HT */
/* QoS */
if(pmlmepriv->qospriv.qos_option)
@ -10079,7 +10042,6 @@ void link_timer_hdl(struct adapter *padapter)
void addba_timer_hdl(struct sta_info *psta)
{
#ifdef CONFIG_80211N_HT
struct ht_priv *phtpriv;
if(!psta)
@ -10093,7 +10055,6 @@ void addba_timer_hdl(struct sta_info *psta)
phtpriv->candidate_tid_bitmap=0x0;
}
#endif /* CONFIG_80211N_HT */
}
#ifdef CONFIG_IEEE80211W
@ -10315,7 +10276,6 @@ u8 join_cmd_hdl(struct adapter *padapter, u8 *pbuf)
break;
case _HT_EXTRA_INFO_IE_: /* Get HT Info IE. */
#ifdef CONFIG_80211N_HT
pmlmeinfo->HT_info_enable = 1;
/* spec case only for cisco's ap because cisco's ap issue assoc rsp using mcs rate @40MHz or @20MHz */
@ -10345,9 +10305,7 @@ u8 join_cmd_hdl(struct adapter *padapter, u8 *pbuf)
DBG_871X("set ch/bw before connected\n");
}
}
#endif /* CONFIG_80211N_HT */
break;
default:
break;
}
@ -10745,7 +10703,6 @@ u8 add_ba_hdl(struct adapter *padapter, unsigned char *pbuf)
if(!psta)
return H2C_SUCCESS;
#ifdef CONFIG_80211N_HT
if (((pmlmeinfo->state & WIFI_FW_ASSOC_SUCCESS) && (pmlmeinfo->HT_enable)) ||
((pmlmeinfo->state&0x03) == WIFI_FW_AP_STATE))
{
@ -10772,7 +10729,6 @@ u8 add_ba_hdl(struct adapter *padapter, unsigned char *pbuf)
{
psta->htpriv.candidate_tid_bitmap &= ~BIT(pparm->tid);
}
#endif /* CONFIG_80211N_HT */
return H2C_SUCCESS;
}

View file

@ -3239,9 +3239,6 @@ int process_recv_indicatepkts(struct adapter *padapter, union recv_frame *prfram
#ifdef CONFIG_TDLS
struct sta_info *psta = prframe->u.hdr.psta;
#endif /* CONFIG_TDLS */
#ifdef CONFIG_80211N_HT
struct ht_priv *phtpriv = &pmlmepriv->htpriv;
#ifdef CONFIG_TDLS
@ -3270,7 +3267,6 @@ int process_recv_indicatepkts(struct adapter *padapter, union recv_frame *prfram
}
}
else /* B/G mode */
#endif
{
retval=wlanhdr_to_ethhdr (prframe);
if(retval != _SUCCESS)
@ -3398,7 +3394,6 @@ static int recv_func_posthandle(struct adapter *padapter, union recv_frame *prfr
rtw_wapi_update_info(padapter, prframe);
#endif
#ifdef CONFIG_80211N_HT
ret = process_recv_indicatepkts(padapter, prframe);
if (ret != _SUCCESS)
{
@ -3409,68 +3404,6 @@ static int recv_func_posthandle(struct adapter *padapter, union recv_frame *prfr
rtw_free_recvframe(orig_prframe, pfree_recv_queue);/* free this recv_frame */
goto _recv_data_drop;
}
#else /* CONFIG_80211N_HT */
if (!pattrib->amsdu)
{
ret = wlanhdr_to_ethhdr (prframe);
if (ret != _SUCCESS)
{
RT_TRACE(_module_rtl871x_recv_c_,_drv_err_,("wlanhdr_to_ethhdr: drop pkt \n"));
#ifdef DBG_RX_DROP_FRAME
DBG_871X("DBG_RX_DROP_FRAME %s wlanhdr_to_ethhdr: drop pkt\n", __FUNCTION__);
#endif
rtw_free_recvframe(orig_prframe, pfree_recv_queue);/* free this recv_frame */
goto _recv_data_drop;
}
if ((padapter->bDriverStopped == false) && (padapter->bSurpriseRemoved == false))
{
RT_TRACE(_module_rtl871x_recv_c_, _drv_alert_, ("@@@@ recv_func: recv_func rtw_recv_indicatepkt\n" ));
/* indicate this recv_frame */
ret = rtw_recv_indicatepkt(padapter, prframe);
if (ret != _SUCCESS)
{
#ifdef DBG_RX_DROP_FRAME
DBG_871X("DBG_RX_DROP_FRAME %s rtw_recv_indicatepkt fail!\n", __FUNCTION__);
#endif
goto _recv_data_drop;
}
}
else
{
RT_TRACE(_module_rtl871x_recv_c_, _drv_alert_, ("@@@@ recv_func: rtw_free_recvframe\n" ));
RT_TRACE(_module_rtl871x_recv_c_, _drv_debug_, ("recv_func:bDriverStopped(%d) OR bSurpriseRemoved(%d)", padapter->bDriverStopped, padapter->bSurpriseRemoved));
#ifdef DBG_RX_DROP_FRAME
DBG_871X("DBG_RX_DROP_FRAME %s ecv_func:bDriverStopped(%d) OR bSurpriseRemoved(%d)\n", __FUNCTION__,
padapter->bDriverStopped, padapter->bSurpriseRemoved);
#endif
ret = _FAIL;
rtw_free_recvframe(orig_prframe, pfree_recv_queue); /* free this recv_frame */
}
}
else if(pattrib->amsdu==1)
{
ret = amsdu_to_msdu(padapter, prframe);
if(ret != _SUCCESS)
{
#ifdef DBG_RX_DROP_FRAME
DBG_871X("DBG_RX_DROP_FRAME %s amsdu_to_msdu fail\n", __FUNCTION__);
#endif
rtw_free_recvframe(orig_prframe, pfree_recv_queue);
goto _recv_data_drop;
}
}
else
{
#ifdef DBG_RX_DROP_FRAME
DBG_871X("DBG_RX_DROP_FRAME %s what is this condition??\n", __FUNCTION__);
#endif
goto _recv_data_drop;
}
#endif /* CONFIG_80211N_HT */
_exit_recv_func:
return ret;

View file

@ -880,7 +880,6 @@ void WMMOnAssocRsp(struct adapter *padapter)
static void bwmode_update_check(struct adapter *padapter, PNDIS_802_11_VARIABLE_IEs pIE)
{
#ifdef CONFIG_80211N_HT
unsigned char new_bwmode;
unsigned char new_ch_offset;
struct HT_info_element *pHT_info;
@ -972,12 +971,10 @@ static void bwmode_update_check(struct adapter *padapter, PNDIS_802_11_VARIABLE_
}
}
#endif /* CONFIG_80211N_HT */
}
void HT_caps_handler(struct adapter *padapter, PNDIS_802_11_VARIABLE_IEs pIE)
{
#ifdef CONFIG_80211N_HT
unsigned int i;
u8 rf_type;
u8 max_AMPDU_len, min_MPDU_spacing;
@ -1058,13 +1055,10 @@ void HT_caps_handler(struct adapter *padapter, PNDIS_802_11_VARIABLE_IEs pIE)
}
#endif
}
#endif /* CONFIG_80211N_HT */
return;
}
void HT_info_handler(struct adapter *padapter, PNDIS_802_11_VARIABLE_IEs pIE)
{
#ifdef CONFIG_80211N_HT
struct mlme_ext_priv *pmlmeext = &padapter->mlmeextpriv;
struct mlme_ext_info *pmlmeinfo = &(pmlmeext->mlmext_info);
struct mlme_priv *pmlmepriv = &padapter->mlmepriv;
@ -1080,8 +1074,6 @@ void HT_info_handler(struct adapter *padapter, PNDIS_802_11_VARIABLE_IEs pIE)
pmlmeinfo->HT_info_enable = 1;
memcpy(&(pmlmeinfo->HT_info), pIE->data, pIE->Length);
#endif /* CONFIG_80211N_HT */
return;
}
void HTOnAssocRsp(struct adapter *padapter)

View file

@ -546,22 +546,12 @@ static void update_attrib_phy_info(struct pkt_attrib *pattrib, struct sta_info *
pattrib->qos_en = psta->qos_option;
pattrib->raid = psta->raid;
#ifdef CONFIG_80211N_HT
pattrib->ht_en = psta->htpriv.ht_option;
pattrib->bwmode = psta->htpriv.bwmode;
pattrib->ch_offset = psta->htpriv.ch_offset;
pattrib->sgi= psta->htpriv.sgi;
pattrib->ampdu_en = false;
#endif /* CONFIG_80211N_HT */
/* if(pattrib->ht_en && psta->htpriv.ampdu_enable) */
/* */
/* if(psta->htpriv.agg_enable_bitmap & BIT(pattrib->priority)) */
/* pattrib->ampdu_en = true; */
/* */
pattrib->retry_ctrl = false;
}
u8 qos_acm(u8 acm_mask, u8 priority)
@ -1221,7 +1211,6 @@ s32 rtw_make_wlanhdr (struct adapter *padapter , u8 *hdr, struct pkt_attrib *pat
SetSeqNum(hdr, pattrib->seqnum);
#ifdef CONFIG_80211N_HT
/* check if enable ampdu */
if(pattrib->ht_en && psta->htpriv.ampdu_enable)
{
@ -1256,7 +1245,6 @@ s32 rtw_make_wlanhdr (struct adapter *padapter , u8 *hdr, struct pkt_attrib *pat
}
}
#endif /* CONFIG_80211N_HT */
#ifdef CONFIG_TDLS
if(direct_link==1)
{
@ -1270,12 +1258,10 @@ s32 rtw_make_wlanhdr (struct adapter *padapter , u8 *hdr, struct pkt_attrib *pat
/* pattrib->qos_en = ptdls_sta->qos_option; */
pattrib->raid = ptdls_sta->raid;
#ifdef CONFIG_80211N_HT
pattrib->bwmode = ptdls_sta->htpriv.bwmode;
pattrib->ht_en = ptdls_sta->htpriv.ht_option;
pattrib->ch_offset = ptdls_sta->htpriv.ch_offset;
pattrib->sgi= ptdls_sta->htpriv.sgi;
#endif /* CONFIG_80211N_HT */
pattrib->mac_id = ptdls_sta->mac_id;
psta = psta_backup;

View file

@ -571,16 +571,12 @@ static s32 rtw_dump_xframe(struct adapter *padapter, struct xmit_frame *pxmitfra
struct pkt_attrib *pattrib = &pxmitframe->attrib;
struct xmit_priv *pxmitpriv = &padapter->xmitpriv;
struct security_priv *psecuritypriv = &padapter->securitypriv;
#ifdef CONFIG_80211N_HT
if ((pxmitframe->frame_tag == DATA_FRAMETAG) &&
(pxmitframe->attrib.ether_type != 0x0806) &&
(pxmitframe->attrib.ether_type != 0x888e) &&
(pxmitframe->attrib.ether_type != 0x88b4) &&
(pxmitframe->attrib.dhcp_pkt != 1))
{
rtw_issue_addbareq_cmd(padapter, pxmitframe);
}
#endif /* CONFIG_80211N_HT */
mem_addr = pxmitframe->buf_addr;
RT_TRACE(_module_rtl871x_xmit_c_,_drv_info_,("rtw_dump_xframe()\n"));
@ -920,7 +916,6 @@ s32 rtl8188eu_xmitframe_complete(struct adapter *padapter, struct xmit_priv *pxm
rtw_list_delete(&ptxservq->tx_pending);
_exit_critical_bh(&pxmitpriv->lock, &irqL);
#ifdef CONFIG_80211N_HT
if ((pfirstframe->attrib.ether_type != 0x0806) &&
(pfirstframe->attrib.ether_type != 0x888e) &&
(pfirstframe->attrib.ether_type != 0x88b4) &&
@ -928,7 +923,6 @@ s32 rtl8188eu_xmitframe_complete(struct adapter *padapter, struct xmit_priv *pxm
{
rtw_issue_addbareq_cmd(padapter, pfirstframe);
}
#endif /* CONFIG_80211N_HT */
#ifndef CONFIG_USE_USB_BUFFER_ALLOC_TX
/* 3 3. update first frame txdesc */
if ((pbuf_tail % bulkSize) == 0) {

View file

@ -45,8 +45,6 @@
#define CONFIG_EMBEDDED_FWIMG
#define CONFIG_80211N_HT
#define CONFIG_RECV_REORDERING_CTRL
#define CONFIG_SUPPORT_USB_INT

View file

@ -42,10 +42,7 @@ enum _NIC_VERSION {
};
#ifdef CONFIG_80211N_HT
#include <rtw_ht.h>
#endif
#include <rtw_cmd.h>
#include <wlan_bssdef.h>
@ -144,13 +141,11 @@ struct registry_priv
WLAN_BSSID_EX dev_network;
#ifdef CONFIG_80211N_HT
u8 ht_enable;
u8 cbw40_enable;
u8 ampdu_enable;//for tx
u8 rx_stbc;
u8 ampdu_amsdu;//A-MPDU Supports A-MSDU is permitted
#endif
u8 lowrate_two_xmit;
u8 rf_config ;

View file

@ -87,11 +87,9 @@ extern int rtw_mc2u_disable;
extern char* rtw_initmac;
#ifdef CONFIG_80211N_HT
extern int rtw_ht_enable;
extern int rtw_cbw40_enable;
extern int rtw_ampdu_enable;//for enable tx_ampdu
#endif
#ifdef CONFIG_GLOBAL_UI_PID
extern int ui_pid[3];

View file

@ -387,7 +387,6 @@ extern u32 GlobalDebugLevel;
int proc_set_rx_signal(struct file *file, const char __user *buffer,
unsigned long count, void *data);
#ifdef CONFIG_80211N_HT
int proc_get_ht_enable(char *page, char **start,
off_t offset, int count,
@ -416,7 +415,6 @@ extern u32 GlobalDebugLevel;
int proc_set_rx_stbc(struct file *file, const char __user *buffer,
unsigned long count, void *data);
#endif //CONFIG_80211N_HT
int proc_get_two_path_rssi(char *page, char **start,
off_t offset, int count,

View file

@ -434,8 +434,6 @@ struct mlme_priv {
struct qos_priv qospriv;
#ifdef CONFIG_80211N_HT
/* Number of non-HT AP/stations */
int num_sta_no_ht;
@ -447,8 +445,6 @@ struct mlme_priv {
struct ht_priv htpriv;
#endif
RT_LINK_DETECT_T LinkDetectInfo;
_timer dynamic_chk_timer; //dynamic/periodic check timer
@ -486,9 +482,7 @@ struct mlme_priv {
/* Overlapping BSS information */
int olbc_ht;
#ifdef CONFIG_80211N_HT
u16 ht_op_mode;
#endif /* CONFIG_80211N_HT */
u8 *assoc_req;
u32 assoc_req_len;
@ -783,11 +777,9 @@ u8 *rtw_get_beacon_interval_from_ie(u8 *ie);
void rtw_joinbss_reset(struct adapter *padapter);
#ifdef CONFIG_80211N_HT
unsigned int rtw_restructure_ht_ie(struct adapter *padapter, u8 *in_ie, u8 *out_ie, uint in_len, uint *pout_len);
void rtw_update_ht_cap(struct adapter *padapter, u8 *pie, uint ie_len);
void rtw_issue_addbareq_cmd(struct adapter *padapter, struct xmit_frame *pxmitframe);
#endif
int rtw_is_same_ibss(struct adapter *adapter, struct wlan_network *pnetwork);
int is_same_network(WLAN_BSSID_EX *src, WLAN_BSSID_EX *dst, u8 feature);

View file

@ -175,10 +175,7 @@ struct sta_info {
//unsigned char ampdu_txen_bitmap;
u16 BA_starting_seqctrl[16];
#ifdef CONFIG_80211N_HT
struct ht_priv htpriv;
#endif
//Notes:
//STA_Mode:

View file

@ -21,7 +21,7 @@
#define _WIFI_H_
#ifdef BIT
//#error "BIT define occurred earlier elsewhere!\n"
/* error "BIT define occurred earlier elsewhere!\n" */
#undef BIT
#endif
#define BIT(x) (1 << (x))
@ -50,9 +50,9 @@
#define P80211CAPTURE_VERSION 0x80211001
// This value is tested by WiFi 11n Test Plan 5.2.3.
// This test verifies the WLAN NIC can update the NAV through sending the CTS with large duration.
#define WiFiNavUpperUs 30000 // 30 ms
/* This value is tested by WiFi 11n Test Plan 5.2.3. */
/* This test verifies the WLAN NIC can update the NAV through sending the CTS with large duration. */
#define WiFiNavUpperUs 30000 /* 30 ms */
#ifdef GREEN_HILL
#pragma pack(1)
@ -62,12 +62,12 @@ enum WIFI_FRAME_TYPE {
WIFI_MGT_TYPE = (0),
WIFI_CTRL_TYPE = (BIT(2)),
WIFI_DATA_TYPE = (BIT(3)),
WIFI_QOS_DATA_TYPE = (BIT(7)|BIT(3)), //!< QoS Data
WIFI_QOS_DATA_TYPE = (BIT(7)|BIT(3)), /* QoS Data */
};
enum WIFI_FRAME_SUBTYPE {
// below is for mgt frame
/* below is for mgt frame */
WIFI_ASSOCREQ = (0 | WIFI_MGT_TYPE),
WIFI_ASSOCRSP = (BIT(4) | WIFI_MGT_TYPE),
WIFI_REASSOCREQ = (BIT(5) | WIFI_MGT_TYPE),
@ -81,7 +81,7 @@ enum WIFI_FRAME_SUBTYPE {
WIFI_DEAUTH = (BIT(7) | BIT(6) | WIFI_MGT_TYPE),
WIFI_ACTION = (BIT(7) | BIT(6) | BIT(4) | WIFI_MGT_TYPE),
// below is for control frame
/* below is for control frame */
WIFI_PSPOLL = (BIT(7) | BIT(5) | WIFI_CTRL_TYPE),
WIFI_RTS = (BIT(7) | BIT(5) | BIT(4) | WIFI_CTRL_TYPE),
WIFI_CTS = (BIT(7) | BIT(6) | WIFI_CTRL_TYPE),
@ -89,7 +89,7 @@ enum WIFI_FRAME_SUBTYPE {
WIFI_CFEND = (BIT(7) | BIT(6) | BIT(5) | WIFI_CTRL_TYPE),
WIFI_CFEND_CFACK = (BIT(7) | BIT(6) | BIT(5) | BIT(4) | WIFI_CTRL_TYPE),
// below is for data frame
/* below is for data frame */
WIFI_DATA = (0 | WIFI_DATA_TYPE),
WIFI_DATA_CFACK = (BIT(4) | WIFI_DATA_TYPE),
WIFI_DATA_CFPOLL = (BIT(5) | WIFI_DATA_TYPE),
@ -113,7 +113,7 @@ enum WIFI_REASON_CODE {
_RSON_DISAOC_STA_LEAVING_ = 8,
_RSON_ASOC_NOT_AUTH_ = 9,
// WPA reason
/* WPA reason */
_RSON_INVALID_IE_ = 13,
_RSON_MIC_FAILURE_ = 14,
_RSON_4WAY_HNDSHK_TIMEOUT_ = 15,
@ -126,7 +126,7 @@ enum WIFI_REASON_CODE {
_RSON_INVALID_RSNE_CAP_ = 22,
_RSON_IEEE_802DOT1X_AUTH_FAIL_ = 23,
//belowing are Realtek definition
/* belowing are Realtek definition */
_RSON_PMK_NOT_AVAILABLE_ = 24,
_RSON_TDLS_TEAR_TOOFAR_ = 25,
_RSON_TDLS_TEAR_UN_RSN_ = 26,
@ -152,7 +152,7 @@ enum WIFI_STATUS_CODE {
};
/* Status codes (IEEE 802.11-2007, 7.3.1.9, Table 7-23) */
//entended
/* entended */
/* IEEE 802.11b */
#define WLAN_STATUS_ASSOC_DENIED_NOSHORT 19
#define WLAN_STATUS_ASSOC_DENIED_NOPBCC 20
@ -376,16 +376,16 @@ __inline static unsigned char * get_da(unsigned char *pframe)
unsigned int to_fr_ds = (GetToDs(pframe) << 1) | GetFrDs(pframe);
switch (to_fr_ds) {
case 0x00: // ToDs=0, FromDs=0
case 0x00: /* ToDs=0, FromDs=0 */
da = GetAddr1Ptr(pframe);
break;
case 0x01: // ToDs=0, FromDs=1
case 0x01: /* ToDs=0, FromDs=1 */
da = GetAddr1Ptr(pframe);
break;
case 0x02: // ToDs=1, FromDs=0
case 0x02: /* ToDs=1, FromDs=0 */
da = GetAddr3Ptr(pframe);
break;
default: // ToDs=1, FromDs=1
default: /* ToDs=1, FromDs=1 */
da = GetAddr3Ptr(pframe);
break;
}
@ -400,16 +400,16 @@ __inline static unsigned char * get_sa(unsigned char *pframe)
unsigned int to_fr_ds = (GetToDs(pframe) << 1) | GetFrDs(pframe);
switch (to_fr_ds) {
case 0x00: // ToDs=0, FromDs=0
case 0x00: /* ToDs=0, FromDs=0 */
sa = GetAddr2Ptr(pframe);
break;
case 0x01: // ToDs=0, FromDs=1
case 0x01: /* ToDs=0, FromDs=1 */
sa = GetAddr3Ptr(pframe);
break;
case 0x02: // ToDs=1, FromDs=0
case 0x02: /* ToDs=1, FromDs=0 */
sa = GetAddr2Ptr(pframe);
break;
default: // ToDs=1, FromDs=1
default: /* ToDs=1, FromDs=1 */
sa = GetAddr4Ptr(pframe);
break;
}
@ -423,20 +423,20 @@ __inline static unsigned char * get_hdr_bssid(unsigned char *pframe)
unsigned int to_fr_ds = (GetToDs(pframe) << 1) | GetFrDs(pframe);
switch (to_fr_ds) {
case 0x00: // ToDs=0, FromDs=0
case 0x00: /* ToDs=0, FromDs=0 */
sa = GetAddr3Ptr(pframe);
break;
case 0x01: // ToDs=0, FromDs=1
case 0x01: /* ToDs=0, FromDs=1 */
sa = GetAddr2Ptr(pframe);
break;
case 0x02: // ToDs=1, FromDs=0
case 0x02: /* ToDs=1, FromDs=0 */
sa = GetAddr1Ptr(pframe);
break;
case 0x03: // ToDs=1, FromDs=1
case 0x03: /* ToDs=1, FromDs=1 */
sa = GetAddr1Ptr(pframe);
break;
default:
sa =NULL; //???????
sa =NULL; /* */
break;
}
@ -463,10 +463,10 @@ __inline static int IsFrameTypeCtrl(unsigned char *pframe)
#define _PRE_ALLOCMICHDR_ 6
#define _SIFSTIME_ ((priv->pmib->dot11BssType.net_work_type&WIRELESS_11A)?16:10)
#define _ACKCTSLNG_ 14 //14 bytes long, including crclng
#define _ACKCTSLNG_ 14 /* 14 bytes long, including crclng */
#define _CRCLNG_ 4
#define _ASOCREQ_IE_OFFSET_ 4 // excluding wlan_hdr
#define _ASOCREQ_IE_OFFSET_ 4 /* excluding wlan_hdr */
#define _ASOCRSP_IE_OFFSET_ 6
#define _REASOCREQ_IE_OFFSET_ 10
#define _REASOCRSP_IE_OFFSET_ 6
@ -487,7 +487,7 @@ __inline static int IsFrameTypeCtrl(unsigned char *pframe)
#define _COUNTRY_IE_ 7
#define _CHLGETXT_IE_ 16
#define _SUPPORTED_CH_IE_ 36
#define _CH_SWTICH_ANNOUNCE_ 37 //Secondary Channel Offset
#define _CH_SWTICH_ANNOUNCE_ 37 /* Secondary Channel Offset */
#define _RSN_IE_2_ 48
#define _SSN_IE_1_ 221
#define _ERPINFO_IE_ 42
@ -498,16 +498,16 @@ __inline static int IsFrameTypeCtrl(unsigned char *pframe)
#define _TIMEOUT_ITVL_IE_ 56
#define _SRC_IE_ 59
#define _HT_EXTRA_INFO_IE_ 61
#define _HT_ADD_INFO_IE_ 61 //_HT_EXTRA_INFO_IE_
#define _HT_ADD_INFO_IE_ 61 /* _HT_EXTRA_INFO_IE_ */
#define _WAPI_IE_ 68
#define EID_BSSCoexistence 72 // 20/40 BSS Coexistence
#define EID_BSSCoexistence 72 /* 20/40 BSS Coexistence */
#define EID_BSSIntolerantChlReport 73
#define _RIC_Descriptor_IE_ 75
#ifdef CONFIG_IEEE80211W
#define _MME_IE_ 76 //802.11w Management MIC element
#endif //CONFIG_IEEE80211W
#define _MME_IE_ 76 /* 802.11w Management MIC element */
#endif /* CONFIG_IEEE80211W */
#define _LINK_ID_IE_ 101
#define _CH_SWITCH_TIMING_ 104
#define _PTI_BUFFER_STATUS_ 106
@ -552,8 +552,8 @@ __inline static int IsFrameTypeCtrl(unsigned char *pframe)
/*-----------------------------------------------------------------------------
Below is the definition for 802.11i / 802.1x
------------------------------------------------------------------------------*/
#define _IEEE8021X_MGT_ 1 // WPA
#define _IEEE8021X_PSK_ 2 // WPA with pre-shared key
#define _IEEE8021X_MGT_ 1 /* WPA */
#define _IEEE8021X_PSK_ 2 /* WPA with pre-shared key */
/*
#define _NO_PRIVACY_ 0
@ -562,16 +562,16 @@ __inline static int IsFrameTypeCtrl(unsigned char *pframe)
#define _WRAP_PRIVACY_ 3
#define _CCMP_PRIVACY_ 4
#define _WEP_104_PRIVACY_ 5
#define _WEP_WPA_MIXED_PRIVACY_ 6 // WEP + WPA
#define _WEP_WPA_MIXED_PRIVACY_ 6 WEP + WPA
*/
#ifdef CONFIG_IEEE80211W
#define _MME_IE_LENGTH_ 18
#endif //CONFIG_IEEE80211W
#endif /* CONFIG_IEEE80211W */
/*-----------------------------------------------------------------------------
Below is the definition for WMM
------------------------------------------------------------------------------*/
#define _WMM_IE_Length_ 7 // for WMM STA
#define _WMM_IE_Length_ 7 /* for WMM STA */
#define _WMM_Para_Element_Length_ 24
@ -579,8 +579,6 @@ __inline static int IsFrameTypeCtrl(unsigned char *pframe)
Below is the definition for 802.11n
------------------------------------------------------------------------------*/
//#ifdef CONFIG_80211N_HT
#define SetOrderBit(pbuf) \
do { \
*(unsigned short *)(pbuf) |= cpu_to_le16(_ORDER_); \
@ -767,14 +765,10 @@ typedef enum _HT_CAP_AMPDU_FACTOR {
#define HT_INFO_STBC_PARAM_PCO_ACTIVE ((u16) BIT(10))
#define HT_INFO_STBC_PARAM_PCO_PHASE ((u16) BIT(11))
//#endif
// ===============WPS Section===============
// For WPSv1.0
/* ===============WPS Section=============== */
/* For WPSv1.0 */
#define WPSOUI 0x0050f204
// WPS attribute ID
/* WPS attribute ID */
#define WPS_ATTR_VER1 0x104A
#define WPS_ATTR_SIMPLE_CONF_STATE 0x1044
#define WPS_ATTR_RESP_TYPE 0x103B
@ -795,29 +789,29 @@ typedef enum _HT_CAP_AMPDU_FACTOR {
#define WPS_ATTR_VENDOR_EXT 0x1049
#define WPS_ATTR_SELECTED_REGISTRAR 0x1041
// Value of WPS attribute "WPS_ATTR_DEVICE_NAME
/* Value of WPS attribute "WPS_ATTR_DEVICE_NAME */
#define WPS_MAX_DEVICE_NAME_LEN 32
// Value of WPS Request Type Attribute
/* Value of WPS Request Type Attribute */
#define WPS_REQ_TYPE_ENROLLEE_INFO_ONLY 0x00
#define WPS_REQ_TYPE_ENROLLEE_OPEN_8021X 0x01
#define WPS_REQ_TYPE_REGISTRAR 0x02
#define WPS_REQ_TYPE_WLAN_MANAGER_REGISTRAR 0x03
// Value of WPS Response Type Attribute
/* Value of WPS Response Type Attribute */
#define WPS_RESPONSE_TYPE_INFO_ONLY 0x00
#define WPS_RESPONSE_TYPE_8021X 0x01
#define WPS_RESPONSE_TYPE_REGISTRAR 0x02
#define WPS_RESPONSE_TYPE_AP 0x03
// Value of WPS WiFi Simple Configuration State Attribute
/* Value of WPS WiFi Simple Configuration State Attribute */
#define WPS_WSC_STATE_NOT_CONFIG 0x01
#define WPS_WSC_STATE_CONFIG 0x02
// Value of WPS Version Attribute
/* Value of WPS Version Attribute */
#define WPS_VERSION_1 0x10
// Value of WPS Configuration Method Attribute
/* Value of WPS Configuration Method Attribute */
#define WPS_CONFIG_METHOD_FLASH 0x0001
#define WPS_CONFIG_METHOD_ETHERNET 0x0002
#define WPS_CONFIG_METHOD_LABEL 0x0004
@ -832,16 +826,16 @@ typedef enum _HT_CAP_AMPDU_FACTOR {
#define WPS_CONFIG_METHOD_VDISPLAY 0x2008
#define WPS_CONFIG_METHOD_PDISPLAY 0x4008
// Value of Category ID of WPS Primary Device Type Attribute
/* Value of Category ID of WPS Primary Device Type Attribute */
#define WPS_PDT_CID_DISPLAYS 0x0007
#define WPS_PDT_CID_MULIT_MEDIA 0x0008
#define WPS_PDT_CID_RTK_WIDI WPS_PDT_CID_MULIT_MEDIA
// Value of Sub Category ID of WPS Primary Device Type Attribute
/* Value of Sub Category ID of WPS Primary Device Type Attribute */
#define WPS_PDT_SCID_MEDIA_SERVER 0x0005
#define WPS_PDT_SCID_RTK_DMP WPS_PDT_SCID_MEDIA_SERVER
// Value of Device Password ID
/* Value of Device Password ID */
#define WPS_DPID_PIN 0x0000
#define WPS_DPID_USER_SPEC 0x0001
#define WPS_DPID_MACHINE_SPEC 0x0002
@ -849,22 +843,22 @@ typedef enum _HT_CAP_AMPDU_FACTOR {
#define WPS_DPID_PBC 0x0004
#define WPS_DPID_REGISTRAR_SPEC 0x0005
// Value of WPS RF Bands Attribute
/* Value of WPS RF Bands Attribute */
#define WPS_RF_BANDS_2_4_GHZ 0x01
#define WPS_RF_BANDS_5_GHZ 0x02
// Value of WPS Association State Attribute
/* Value of WPS Association State Attribute */
#define WPS_ASSOC_STATE_NOT_ASSOCIATED 0x00
#define WPS_ASSOC_STATE_CONNECTION_SUCCESS 0x01
#define WPS_ASSOC_STATE_CONFIGURATION_FAILURE 0x02
#define WPS_ASSOC_STATE_ASSOCIATION_FAILURE 0x03
#define WPS_ASSOC_STATE_IP_FAILURE 0x04
// =====================P2P Section=====================
// For P2P
/* =====================P2P Section===================== */
/* For P2P */
#define P2POUI 0x506F9A09
// P2P Attribute ID
/* P2P Attribute ID */
#define P2P_ATTR_STATUS 0x00
#define P2P_ATTR_MINOR_REASON_CODE 0x01
#define P2P_ATTR_CAPABILITY 0x02
@ -885,7 +879,7 @@ typedef enum _HT_CAP_AMPDU_FACTOR {
#define P2P_ATTR_OPERATING_CH 0x11
#define P2P_ATTR_INVITATION_FLAGS 0x12
// Value of Status Attribute
/* Value of Status Attribute */
#define P2P_STATUS_SUCCESS 0x00
#define P2P_STATUS_FAIL_INFO_UNAVAILABLE 0x01
#define P2P_STATUS_FAIL_INCOMPATIBLE_PARAM 0x02
@ -899,7 +893,7 @@ typedef enum _HT_CAP_AMPDU_FACTOR {
#define P2P_STATUS_FAIL_INCOMPATIBLE_PROVSION 0x0A
#define P2P_STATUS_FAIL_USER_REJECT 0x0B
// Value of Inviation Flags Attribute
/* Value of Inviation Flags Attribute */
#define P2P_INVITATION_FLAGS_PERSISTENT BIT(0)
#define DMP_P2P_DEVCAP_SUPPORT (P2P_DEVCAP_SERVICE_DISCOVERY | \
@ -909,7 +903,7 @@ typedef enum _HT_CAP_AMPDU_FACTOR {
#define DMP_P2P_GRPCAP_SUPPORT (P2P_GRPCAP_INTRABSS)
// Value of Device Capability Bitmap
/* Value of Device Capability Bitmap */
#define P2P_DEVCAP_SERVICE_DISCOVERY BIT(0)
#define P2P_DEVCAP_CLIENT_DISCOVERABILITY BIT(1)
#define P2P_DEVCAP_CONCURRENT_OPERATION BIT(2)
@ -917,7 +911,7 @@ typedef enum _HT_CAP_AMPDU_FACTOR {
#define P2P_DEVCAP_DEVICE_LIMIT BIT(4)
#define P2P_DEVCAP_INVITATION_PROC BIT(5)
// Value of Group Capability Bitmap
/* Value of Group Capability Bitmap */
#define P2P_GRPCAP_GO BIT(0)
#define P2P_GRPCAP_PERSISTENT_GROUP BIT(1)
#define P2P_GRPCAP_GROUP_LIMIT BIT(2)
@ -926,10 +920,10 @@ typedef enum _HT_CAP_AMPDU_FACTOR {
#define P2P_GRPCAP_PERSISTENT_RECONN BIT(5)
#define P2P_GRPCAP_GROUP_FORMATION BIT(6)
// P2P Public Action Frame ( Management Frame )
/* P2P Public Action Frame ( Management Frame ) */
#define P2P_PUB_ACTION_ACTION 0x09
// P2P Public Action Frame Type
/* P2P Public Action Frame Type */
#define P2P_GO_NEGO_REQ 0
#define P2P_GO_NEGO_RESP 1
#define P2P_GO_NEGO_CONF 2
@ -940,7 +934,7 @@ typedef enum _HT_CAP_AMPDU_FACTOR {
#define P2P_PROVISION_DISC_REQ 7
#define P2P_PROVISION_DISC_RESP 8
// P2P Action Frame Type
/* P2P Action Frame Type */
#define P2P_NOTICE_OF_ABSENCE 0
#define P2P_PRESENCE_REQUEST 1
#define P2P_PRESENCE_RESPONSE 2
@ -953,25 +947,25 @@ typedef enum _HT_CAP_AMPDU_FACTOR {
#define P2P_WILDCARD_SSID_LEN 7
#define P2P_FINDPHASE_EX_NONE 0 // default value, used when: (1)p2p disabed or (2)p2p enabled but only do 1 scan phase
#define P2P_FINDPHASE_EX_FULL 1 // used when p2p enabled and want to do 1 scan phase and P2P_FINDPHASE_EX_MAX-1 find phase
#define P2P_FINDPHASE_EX_NONE 0 /* default value, used when: (1)p2p disabed or (2)p2p enabled but only do 1 scan phase */
#define P2P_FINDPHASE_EX_FULL 1 /* used when p2p enabled and want to do 1 scan phase and P2P_FINDPHASE_EX_MAX-1 find phase */
#define P2P_FINDPHASE_EX_SOCIAL_FIRST (P2P_FINDPHASE_EX_FULL+1)
#define P2P_FINDPHASE_EX_MAX 4
#define P2P_FINDPHASE_EX_SOCIAL_LAST P2P_FINDPHASE_EX_MAX
#define P2P_PROVISION_TIMEOUT 5000 // 5 seconds timeout for sending the provision discovery request
#define P2P_CONCURRENT_PROVISION_TIMEOUT 3000 // 3 seconds timeout for sending the provision discovery request under concurrent mode
#define P2P_GO_NEGO_TIMEOUT 5000 // 5 seconds timeout for receiving the group negotation response
#define P2P_CONCURRENT_GO_NEGO_TIMEOUT 3000 // 3 seconds timeout for sending the negotiation request under concurrent mode
#define P2P_TX_PRESCAN_TIMEOUT 100 // 100ms
#define P2P_INVITE_TIMEOUT 5000 // 5 seconds timeout for sending the invitation request
#define P2P_CONCURRENT_INVITE_TIMEOUT 3000 // 3 seconds timeout for sending the invitation request under concurrent mode
#define P2P_RESET_SCAN_CH 25000 // 25 seconds timeout to reset the scan channel ( based on channel plan )
#define P2P_PROVISION_TIMEOUT 5000 /* 5 seconds timeout for sending the provision discovery request */
#define P2P_CONCURRENT_PROVISION_TIMEOUT 3000 /* 3 seconds timeout for sending the provision discovery request under concurrent mode */
#define P2P_GO_NEGO_TIMEOUT 5000 /* 5 seconds timeout for receiving the group negotation response */
#define P2P_CONCURRENT_GO_NEGO_TIMEOUT 3000 /* 3 seconds timeout for sending the negotiation request under concurrent mode */
#define P2P_TX_PRESCAN_TIMEOUT 100 /* 100ms */
#define P2P_INVITE_TIMEOUT 5000 /* 5 seconds timeout for sending the invitation request */
#define P2P_CONCURRENT_INVITE_TIMEOUT 3000 /* 3 seconds timeout for sending the invitation request under concurrent mode */
#define P2P_RESET_SCAN_CH 25000 /* 25 seconds timeout to reset the scan channel ( based on channel plan ) */
#define P2P_MAX_INTENT 15
#define P2P_MAX_NOA_NUM 2
// WPS Configuration Method
/* WPS Configuration Method */
#define WPS_CM_NONE 0x0000
#define WPS_CM_LABEL 0x0004
#define WPS_CM_DISPLYA 0x0008
@ -993,29 +987,29 @@ enum P2P_ROLE {
};
enum P2P_STATE {
P2P_STATE_NONE = 0, // P2P disable
P2P_STATE_IDLE = 1, // P2P had enabled and do nothing
P2P_STATE_LISTEN = 2, // In pure listen state
P2P_STATE_SCAN = 3, // In scan phase
P2P_STATE_FIND_PHASE_LISTEN = 4, // In the listen state of find phase
P2P_STATE_FIND_PHASE_SEARCH = 5, // In the search state of find phase
P2P_STATE_TX_PROVISION_DIS_REQ = 6, // In P2P provisioning discovery
P2P_STATE_NONE = 0, /* P2P disable */
P2P_STATE_IDLE = 1, /* P2P had enabled and do nothing */
P2P_STATE_LISTEN = 2, /* In pure listen state */
P2P_STATE_SCAN = 3, /* In scan phase */
P2P_STATE_FIND_PHASE_LISTEN = 4, /* In the listen state of find phase */
P2P_STATE_FIND_PHASE_SEARCH = 5, /* In the search state of find phase */
P2P_STATE_TX_PROVISION_DIS_REQ = 6, /* In P2P provisioning discovery */
P2P_STATE_RX_PROVISION_DIS_RSP = 7,
P2P_STATE_RX_PROVISION_DIS_REQ = 8,
P2P_STATE_GONEGO_ING = 9, // Doing the group owner negoitation handshake
P2P_STATE_GONEGO_OK = 10, // finish the group negoitation handshake with success
P2P_STATE_GONEGO_FAIL = 11, // finish the group negoitation handshake with failure
P2P_STATE_RECV_INVITE_REQ_MATCH = 12, // receiving the P2P Inviation request and match with the profile.
P2P_STATE_PROVISIONING_ING = 13, // Doing the P2P WPS
P2P_STATE_PROVISIONING_DONE = 14, // Finish the P2P WPS
P2P_STATE_TX_INVITE_REQ = 15, // Transmit the P2P Invitation request
P2P_STATE_RX_INVITE_RESP_OK = 16, // Receiving the P2P Invitation response
P2P_STATE_RECV_INVITE_REQ_DISMATCH = 17, // receiving the P2P Inviation request and dismatch with the profile.
P2P_STATE_RECV_INVITE_REQ_GO = 18, // receiving the P2P Inviation request and this wifi is GO.
P2P_STATE_RECV_INVITE_REQ_JOIN = 19, // receiving the P2P Inviation request to join an existing P2P Group.
P2P_STATE_RX_INVITE_RESP_FAIL = 20, // recveing the P2P Inviation response with failure
P2P_STATE_RX_INFOR_NOREADY = 21, // receiving p2p negoitation response with information is not available
P2P_STATE_TX_INFOR_NOREADY = 22, // sending p2p negoitation response with information is not available
P2P_STATE_GONEGO_ING = 9, /* Doing the group owner negoitation handshake */
P2P_STATE_GONEGO_OK = 10, /* finish the group negoitation handshake with success */
P2P_STATE_GONEGO_FAIL = 11, /* finish the group negoitation handshake with failure */
P2P_STATE_RECV_INVITE_REQ_MATCH = 12, /* receiving the P2P Inviation request and match with the profile. */
P2P_STATE_PROVISIONING_ING = 13, /* Doing the P2P WPS */
P2P_STATE_PROVISIONING_DONE = 14, /* Finish the P2P WPS */
P2P_STATE_TX_INVITE_REQ = 15, /* Transmit the P2P Invitation request */
P2P_STATE_RX_INVITE_RESP_OK = 16, /* Receiving the P2P Invitation response */
P2P_STATE_RECV_INVITE_REQ_DISMATCH = 17, /* receiving the P2P Inviation request and dismatch with the profile. */
P2P_STATE_RECV_INVITE_REQ_GO = 18, /* receiving the P2P Inviation request and this wifi is GO. */
P2P_STATE_RECV_INVITE_REQ_JOIN = 19, /* receiving the P2P Inviation request to join an existing P2P Group. */
P2P_STATE_RX_INVITE_RESP_FAIL = 20, /* recveing the P2P Inviation response with failure */
P2P_STATE_RX_INFOR_NOREADY = 21, /* receiving p2p negoitation response with information is not available */
P2P_STATE_TX_INFOR_NOREADY = 22, /* sending p2p negoitation response with information is not available */
};
enum P2P_WPSINFO {
@ -1043,19 +1037,19 @@ enum P2P_PS_STATE {
P2P_PS_ENABLE = 1,
P2P_PS_SCAN = 2,
P2P_PS_SCAN_DONE = 3,
P2P_PS_ALLSTASLEEP = 4, // for P2P GO
P2P_PS_ALLSTASLEEP = 4, /* for P2P GO */
};
enum P2P_PS_MODE {
P2P_PS_NONE = 0,
P2P_PS_CTWINDOW = 1,
P2P_PS_NOA = 2,
P2P_PS_MIX = 3, // CTWindow and NoA
P2P_PS_MIX = 3, /* CTWindow and NoA */
};
#endif // CONFIG_P2P_PS
#endif /* CONFIG_P2P_PS */
// =====================WFD Section=====================
// For Wi-Fi Display
/* =====================WFD Section===================== */
/* For Wi-Fi Display */
#define WFD_ATTR_DEVICE_INFO 0x00
#define WFD_ATTR_ASSOC_BSSID 0x01
#define WFD_ATTR_COUPLED_SINK_INFO 0x06
@ -1063,7 +1057,7 @@ enum P2P_PS_MODE {
#define WFD_ATTR_SESSION_INFO 0x09
#define WFD_ATTR_ALTER_MAC 0x0a
// For WFD Device Information Attribute
/* For WFD Device Information Attribute */
#define WFD_DEVINFO_SOURCE 0x0000
#define WFD_DEVINFO_PSINK 0x0001
#define WFD_DEVINFO_SSINK 0x0002
@ -1092,4 +1086,4 @@ enum P2P_PS_MODE {
#endif
#endif
#endif // _WIFI_H_
#endif /* _WIFI_H_ */

View file

@ -6295,9 +6295,7 @@ static int rtw_dbg_port(struct net_device *dev,
break;
case 0x03:
DBG_871X("qos_option=%d\n", pmlmepriv->qospriv.qos_option);
#ifdef CONFIG_80211N_HT
DBG_871X("ht_option=%d\n", pmlmepriv->htpriv.ht_option);
#endif /* CONFIG_80211N_HT */
break;
case 0x04:
DBG_871X("cur_ch=%d\n", pmlmeext->cur_channel);
@ -6316,12 +6314,10 @@ static int rtw_dbg_port(struct net_device *dev,
DBG_871X("cur_channel=%d, cur_bwmode=%d, cur_ch_offset=%d\n", pmlmeext->cur_channel, pmlmeext->cur_bwmode, pmlmeext->cur_ch_offset);
DBG_871X("rtsen=%d, cts2slef=%d\n", psta->rtsen, psta->cts2self);
DBG_871X("state=0x%x, aid=%d, macid=%d, raid=%d\n", psta->state, psta->aid, psta->mac_id, psta->raid);
#ifdef CONFIG_80211N_HT
DBG_871X("qos_en=%d, ht_en=%d, init_rate=%d\n", psta->qos_option, psta->htpriv.ht_option, psta->init_rate);
DBG_871X("bwmode=%d, ch_offset=%d, sgi=%d\n", psta->htpriv.bwmode, psta->htpriv.ch_offset, psta->htpriv.sgi);
DBG_871X("ampdu_enable = %d\n", psta->htpriv.ampdu_enable);
DBG_871X("agg_enable_bitmap=%x, candidate_tid_bitmap=%x\n", psta->htpriv.agg_enable_bitmap, psta->htpriv.candidate_tid_bitmap);
#endif /* CONFIG_80211N_HT */
for(i=0;i<16;i++)
{
@ -6393,12 +6389,10 @@ static int rtw_dbg_port(struct net_device *dev,
DBG_871X("sta's macaddr:" MAC_FMT "\n", MAC_ARG(psta->hwaddr));
DBG_871X("rtsen=%d, cts2slef=%d\n", psta->rtsen, psta->cts2self);
DBG_871X("state=0x%x, aid=%d, macid=%d, raid=%d\n", psta->state, psta->aid, psta->mac_id, psta->raid);
#ifdef CONFIG_80211N_HT
DBG_871X("qos_en=%d, ht_en=%d, init_rate=%d\n", psta->qos_option, psta->htpriv.ht_option, psta->init_rate);
DBG_871X("bwmode=%d, ch_offset=%d, sgi=%d\n", psta->htpriv.bwmode, psta->htpriv.ch_offset, psta->htpriv.sgi);
DBG_871X("ampdu_enable = %d\n", psta->htpriv.ampdu_enable);
DBG_871X("agg_enable_bitmap=%x, candidate_tid_bitmap=%x\n", psta->htpriv.agg_enable_bitmap, psta->htpriv.candidate_tid_bitmap);
#endif /* CONFIG_80211N_HT */
#ifdef CONFIG_AP_MODE
DBG_871X("capability=0x%x\n", psta->capability);
@ -7422,7 +7416,6 @@ static int rtw_add_sta(struct net_device *dev, struct ieee_param *param)
psta->qos_option = 0;
#ifdef CONFIG_80211N_HT
/* chec 802.11n ht cap. */
if(WLAN_STA_HT&flags)
{
@ -7437,12 +7430,8 @@ static int rtw_add_sta(struct net_device *dev, struct ieee_param *param)
if(pmlmepriv->htpriv.ht_option == false)
psta->htpriv.ht_option = false;
#endif
update_sta_info_apmode(padapter, psta);
}
else
{
@ -7549,9 +7538,7 @@ static int rtw_ioctl_get_sta_data(struct net_device *dev, struct ieee_param *par
psta_data->tx_supp_rates_len = psta->bssratelen;
memcpy(psta_data->tx_supp_rates, psta->bssrateset, psta->bssratelen);
#ifdef CONFIG_80211N_HT
memcpy(&psta_data->ht_cap, &psta->htpriv.ht_cap, sizeof(struct rtw_ieee80211_ht_cap));
#endif /* CONFIG_80211N_HT */
psta_data->rx_pkts = psta->sta_stats.rx_data_pkts;
psta_data->rx_bytes = psta->sta_stats.rx_bytes;
psta_data->rx_drops = psta->sta_stats.rx_drops;

View file

@ -109,13 +109,11 @@ static int rtw_uapsd_acbe_en = 0;
static int rtw_uapsd_acvi_en = 0;
static int rtw_uapsd_acvo_en = 0;
#ifdef CONFIG_80211N_HT
int rtw_ht_enable = 1;
int rtw_cbw40_enable = 3; /* 0 :diable, bit(0): enable 2.4g, bit(1): enable 5g */
int rtw_ampdu_enable = 1;/* for enable tx_ampdu */
static int rtw_rx_stbc = 1;/* 0: disable, bit(0):enable 2.4g, bit(1):enable 5g, default is set to enable 2.4GHZ for IOT issue with bufflao's AP at 5GHZ */
static int rtw_ampdu_amsdu = 0;/* 0: disabled, 1:enabled, 2:auto */
#endif
static int rtw_lowrate_two_xmit = 1;/* Use 2 path Tx to transmit MCS0~7 and legacy mode */
@ -208,13 +206,11 @@ module_param(rtw_wmm_enable, int, 0644);
module_param(rtw_vrtl_carrier_sense, int, 0644);
module_param(rtw_vcs_type, int, 0644);
module_param(rtw_busy_thresh, int, 0644);
#ifdef CONFIG_80211N_HT
module_param(rtw_ht_enable, int, 0644);
module_param(rtw_cbw40_enable, int, 0644);
module_param(rtw_ampdu_enable, int, 0644);
module_param(rtw_rx_stbc, int, 0644);
module_param(rtw_ampdu_amsdu, int, 0644);
#endif
module_param(rtw_lowrate_two_xmit, int, 0644);
@ -355,13 +351,11 @@ static uint loadparam( struct adapter *padapter, _nic_hdl pnetdev)
registry_par->uapsd_acvi_en = (u8)rtw_uapsd_acvi_en;
registry_par->uapsd_acvo_en = (u8)rtw_uapsd_acvo_en;
#ifdef CONFIG_80211N_HT
registry_par->ht_enable = (u8)rtw_ht_enable;
registry_par->cbw40_enable = (u8)rtw_cbw40_enable;
registry_par->ampdu_enable = (u8)rtw_ampdu_enable;
registry_par->rx_stbc = (u8)rtw_rx_stbc;
registry_par->ampdu_amsdu = (u8)rtw_ampdu_amsdu;
#endif
#ifdef CONFIG_TX_EARLY_MODE
registry_par->early_mode = (u8)rtw_early_mode;
#endif
@ -804,9 +798,7 @@ u8 rtw_init_default_value(struct adapter *padapter)
/* pmlmepriv->qospriv.qos_option = pregistrypriv->wmm_enable; */
/* ht_priv */
#ifdef CONFIG_80211N_HT
pmlmepriv->htpriv.ampdu_enable = false;/* set to disabled */
#endif
/* security_priv */
/* rtw_get_encrypt_decrypt_from_registrypriv(padapter); */

View file

@ -525,14 +525,12 @@ static void process_spec_devid(const struct usb_device_id *pdid)
pid = specific_device_id_tbl[i].idProduct;
flags = specific_device_id_tbl[i].flags;
#ifdef CONFIG_80211N_HT
if((pdid->idVendor==vid) && (pdid->idProduct==pid) && (flags&SPEC_DEV_ID_DISABLE_HT))
{
rtw_ht_enable = 0;
rtw_cbw40_enable = 0;
rtw_ampdu_enable = 0;
}
#endif
#ifdef RTK_DMP_PLATFORM
/* Change the ifname to wlan10 when PC side WFD dongle plugin on DMP platform. */