ccflags-y += -DUSE_FW_SOURCE_IMG_FILE
ccflags-y += -DCONFIG_PM_RTL
ccflags-y += -DCONFIG_PM
-ccflags-y += -DENABLE_DOT11D
ccflags-y += -DHAVE_NET_DEVICE_OPS
ccflags-y += -DENABLE_DOT11D
if (priv->ChannelPlan > CHANNEL_PLAN_LEN - 1)
priv->ChannelPlan = 0;
-#ifdef ENABLE_DOT11D
priv->ChannelPlan = COUNTRY_CODE_WORLD_WIDE_13;
-#endif
if ( priv->eeprom_vid == 0x1186 && priv->eeprom_did == 0x3304)
priv->rtllib->bSupportRemoteWakeUp = true;
#include "r8190P_rtl8256.h"
#include "r8192E_phy.h"
#include "rtl_dm.h"
-#ifdef ENABLE_DOT11D
#include "dot11d.h"
-#endif
#include "r8192E_hwimg.h"
RT_TRACE(COMP_TRACE, "====>%s()====stage:%d, step:%d, channel:%d\n", __func__, *stage, *step, channel);
-#ifdef ENABLE_DOT11D
if (!IsLegalChannel(priv->rtllib, channel))
{
RT_TRACE(COMP_ERR, "=============>set to illegal channel:%d\n", channel);
return true;
}
-#endif
{
PreCommonCmdCnt = 0;
{
int i;
-#ifdef ENABLE_DOT11D
struct r8192_priv *priv = rtllib_priv(dev);
if ((priv->rf_chip != RF_8225) && (priv->rf_chip != RF_8256)
&& (priv->rf_chip != RF_6052)) {
Dot11d_Init(priv->rtllib);
#ifndef CONFIG_CRDA
Dot11d_Channelmap(priv->ChannelPlan, priv->rtllib);
-#endif
-#else
- struct r8192_priv *priv = rtllib_priv(dev);
- int ch;
- if (!channels){
- DMESG("No channels, aborting");
- return -1;
- }
-
- ch = channels;
- priv->ChannelPlan = 0;
- for (i = 1; i <= 14; i++) {
- (priv->rtllib->channel_map)[i] = (u8)(ch & 0x01);
- ch >>= 1;
- }
- priv->rtllib->IbssStartChnl= 10;
- priv->rtllib->ibss_maxjoin_chal = 11;
#endif
for (i = 1; i <= 11; i++) {
(priv->rtllib->active_channel_map)[i] = 1;
#include <asm/io.h>
#include "rtllib.h"
-#ifdef ENABLE_DOT11D
#include "dot11d.h"
-#endif
#include "r8192E_firmware.h"
#include "r8192E_hw.h"
#include <linux/string.h>
#include "rtl_core.h"
-#ifdef ENABLE_DOT11D
#include "dot11d.h"
-#endif
#define RATE_COUNT 12
u32 rtl8192_rates[] = {1000000,2000000,5500000,11000000,
u8 wmm_info;
struct rtllib_wmm_ac_param wmm_param[4];
u8 Turbo_Enable;
-#ifdef ENABLE_DOT11D
u16 CountryIeLen;
u8 CountryIeBuf[MAX_IE_LEN];
-#endif
BSS_HT bssht;
bool broadcom_cap_exist;
bool realtek_cap_exit;
u16 prev_seq_ctl; /* used to drop duplicate frames */
/* map of allowed channels. 0 is dummy */
-#ifdef ENABLE_DOT11D
void* pDot11dInfo;
bool bGlobalDomain;
-#else
- u8 channel_map[MAX_CHANNEL_NUMBER+1];
-#endif
u8 active_channel_map[MAX_CHANNEL_NUMBER+1];
u8 IbssStartChnl;
#include <linux/ctype.h>
#include "rtllib.h"
-#ifdef ENABLE_DOT11D
#include "dot11d.h"
-#endif
#if defined CONFIG_CFG_80211
#include <linux/crc32.h>
}
#endif
-#ifdef ENABLE_DOT11D
static inline void rtllib_extract_country_ie(
struct rtllib_device *ieee,
struct rtllib_info_element *info_element,
}
}
-#endif
int rtllib_parse_info_param(struct rtllib_device *ieee,
struct rtllib_info_element *info_element,
"QoS Error need to parse QOS_PARAMETER IE\n");
break;
-#ifdef ENABLE_DOT11D
case MFIE_TYPE_COUNTRY:
RTLLIB_DEBUG_SCAN("MFIE_TYPE_COUNTRY: %d bytes\n",
info_element->len);
rtllib_extract_country_ie(ieee, info_element, network, network->bssid);
break;
-#endif
/* TODO */
default:
RTLLIB_DEBUG_MGMT
network->Turbo_Enable = 0;
network->SignalStrength = stats->SignalStrength;
network->RSSI = stats->SignalStrength;
-#ifdef ENABLE_DOT11D
network->CountryIeLen = 0;
memset(network->CountryIeBuf, 0, MAX_IE_LEN);
-#endif
HTInitializeBssDesc(&network->bssht);
if (stats->freq == RTLLIB_52GHZ_BAND) {
/* for A band (No DS info) */
dst->RSSI = src->RSSI;
dst->Turbo_Enable = src->Turbo_Enable;
-#ifdef ENABLE_DOT11D
dst->CountryIeLen = src->CountryIeLen;
memcpy(dst->CountryIeBuf, src->CountryIeBuf, src->CountryIeLen);
-#endif
dst->bWithAironetIE = src->bWithAironetIE;
dst->bCkipSupported = src->bCkipSupported;
#include <linux/delay.h>
#include <linux/version.h>
#include <asm/uaccess.h>
-#ifdef ENABLE_DOT11D
#include "dot11d.h"
-#endif
#ifdef RTK_DMP_PLATFORM
#include <linux/usb_setting.h>
void rtllib_update_active_chan_map(struct rtllib_device *ieee)
{
-#ifdef ENABLE_DOT11D
memcpy(ieee->active_channel_map, GET_DOT11D_INFO(ieee)->channel_map, MAX_CHANNEL_NUMBER+1);
-#else
- memcpy(ieee->active_channel_map, ieee->channel_map, MAX_CHANNEL_NUMBER+1);
-#endif
}
/* this performs syncro scan blocking the caller until all channels
ieee->sync_scan_hurryup = 0;
if (ieee->state >= RTLLIB_LINKED){
-#ifdef ENABLE_DOT11D
if (IS_DOT11D_ENABLE(ieee))
DOT11D_ScanComplete(ieee);
-#endif
}
up(&ieee->scan_sem);
return;
out:
-#ifdef ENABLE_DOT11D
if (IS_DOT11D_ENABLE(ieee))
DOT11D_ScanComplete(ieee);
-#endif
ieee->current_network.channel = last_channel;
out1:
ieee->rtllib_ips_leave_wq(ieee->dev);
-#ifdef ENABLE_DOT11D
if (IS_DOT11D_ENABLE(ieee) )
{
if (IS_COUNTRY_IE_VALID(ieee))
RESET_CIE_WATCHDOG(ieee);
}
}
-#endif
if (ieee->softmac_features & IEEE_SOFTMAC_SCAN) {
if (ieee->scanning_continue == 0) {
ieee->actscanning = true;
/* called with wx_sem held */
void rtllib_start_scan_syncro(struct rtllib_device *ieee, u8 is_mesh)
{
-#ifdef ENABLE_DOT11D
if (IS_DOT11D_ENABLE(ieee) )
{
if (IS_COUNTRY_IE_VALID(ieee))
RESET_CIE_WATCHDOG(ieee);
}
}
-#endif
ieee->sync_scan_hurryup = 0;
if (ieee->softmac_features & IEEE_SOFTMAC_SCAN){
rtllib_softmac_scan_syncro(ieee, is_mesh);
void rtllib_start_bss(struct rtllib_device *ieee)
{
unsigned long flags;
-#ifdef ENABLE_DOT11D
if (IS_DOT11D_ENABLE(ieee) && !IS_COUNTRY_IE_VALID(ieee))
{
if (! ieee->bGlobalDomain)
return;
}
}
-#endif
/* check if we have already found the net we
* are interested in (if any).
* if not (we are disassociated and we are not
if (ieee->data_hard_stop)
ieee->data_hard_stop(ieee->dev);
-#ifdef ENABLE_DOT11D
if (IS_DOT11D_ENABLE(ieee))
Dot11d_Reset(ieee);
-#endif
ieee->state = RTLLIB_NOLINK;
ieee->is_set_key = false;
ieee->wap_set = 0;
for (i = 0; i < 5; i++) {
ieee->seq_ctrl[i] = 0;
}
-#ifdef ENABLE_DOT11D
ieee->pDot11dInfo = kmalloc(sizeof(struct rt_dot11d_info), GFP_ATOMIC);
if (!ieee->pDot11dInfo)
RTLLIB_DEBUG(RTLLIB_DL_ERR, "can't alloc memory for DOT11D\n");
memset(ieee->pDot11dInfo, 0, sizeof(struct rt_dot11d_info));
-#endif
ieee->LinkDetectInfo.SlotIndex = 0;
ieee->LinkDetectInfo.SlotNum = 2;
ieee->LinkDetectInfo.NumRecvBcnInPeriod=0;
void rtllib_softmac_free(struct rtllib_device *ieee)
{
down(&ieee->wx_sem);
-#ifdef ENABLE_DOT11D
if (NULL != ieee->pDot11dInfo)
{
kfree(ieee->pDot11dInfo);
ieee->pDot11dInfo = NULL;
}
-#endif
del_timer_sync(&ieee->associate_timer);
cancel_delayed_work(&ieee->associate_retry_wq);
#include "rtllib.h"
#include "rtl_core.h"
-#ifdef ENABLE_DOT11D
#include "dot11d.h"
-#endif
/* FIXME: add A freqs */
const long rtllib_wlan_frequencies[] = {
}else { /* Set the channel */
-#ifdef ENABLE_DOT11D
if (ieee->active_channel_map[fwrq->m] != 1) {
ret = -EINVAL;
goto out;
}
-#endif
ieee->current_network.channel = fwrq->m;
ieee->set_chan(ieee->dev, ieee->current_network.channel);