static u8 gu8Chnl;
static u8 gs8SetIP[2][4];
static u8 gs8GetIP[2][4];
-#ifdef WILC_AP_EXTERNAL_MLME
static u32 gu32InactiveTime;
static u8 gu8DelBcn;
-#endif
static u32 gu32WidConnRstHack;
/*BugID_5137*/
{
s32 s32Error = 0;
tstrWID strWID;
- #ifdef WILC_AP_EXTERNAL_MLME
tstrWID strWIDList[5];
- #endif
u8 i;
u8 *pu8keybuf;
s8 s8idxarray[1];
case WEP:
-#ifdef WILC_AP_EXTERNAL_MLME
if (pstrHostIFkeyAttr->u8KeyAction & ADDKEY_AP) {
PRINT_D(HOSTINF_DBG, "Handling WEP key\n");
}
-#endif
if (pstrHostIFkeyAttr->u8KeyAction & ADDKEY) {
PRINT_D(HOSTINF_DBG, "Handling WEP key\n");
break;
case WPARxGtk:
- #ifdef WILC_AP_EXTERNAL_MLME
if (pstrHostIFkeyAttr->u8KeyAction & ADDKEY_AP) {
pu8keybuf = kmalloc(RX_MIC_KEY_MSG_LEN, GFP_KERNEL);
if (pu8keybuf == NULL) {
/* ///////////////////////// */
}
- #endif
if (pstrHostIFkeyAttr->u8KeyAction & ADDKEY) {
PRINT_D(HOSTINF_DBG, "Handling group key(Rx) function\n");
break;
case WPAPtk:
- #ifdef WILC_AP_EXTERNAL_MLME
if (pstrHostIFkeyAttr->u8KeyAction & ADDKEY_AP) {
up(&(pstrWFIDrv->hSemTestKeyBlock));
/* ///////////////////////// */
}
- #endif
if (pstrHostIFkeyAttr->u8KeyAction & ADDKEY) {
}
-
-#ifdef WILC_AP_EXTERNAL_MLME
-
-
/**
* @brief Handle_Get_InActiveTime
* @details Sending config packet to set mac adddress for station and
kfree(pstrStationParam->pu8Rates);
kfree(strWID.ps8WidVal);
}
-#endif /*WILC_AP_EXTERNAL_MLME*/
#ifdef WILC_P2P
/**
Handle_GetChnl(strHostIFmsg.drvHandler);
break;
-#ifdef WILC_AP_EXTERNAL_MLME
case HOST_IF_MSG_ADD_BEACON:
Handle_AddBeacon(strHostIFmsg.drvHandler, &strHostIFmsg.uniHostIFmsgBody.strHostIFSetBeacon);
break;
Handle_Get_InActiveTime(strHostIFmsg.drvHandler, &strHostIFmsg.uniHostIFmsgBody.strHostIfStaInactiveT);
break;
-#endif /*WILC_AP_EXTERNAL_MLME*/
case HOST_IF_MSG_SCAN_TIMER_FIRED:
PRINT_D(HOSTINF_DBG, "Scan Timeout\n");
}
-#ifdef WILC_AP_EXTERNAL_MLME
/**
*
* @brief host_int_add_wep_key_bss_ap
return s32Error;
}
-#endif
+
/**
* @brief adds ptk Key
* @details
strHostIFmsg.u16MsgId = HOST_IF_MSG_KEY;
strHostIFmsg.uniHostIFmsgBody.strHostIFkeyAttr.enuKeyType = WPAPtk;
- #ifdef WILC_AP_EXTERNAL_MLME
if (mode == AP_MODE) {
strHostIFmsg.uniHostIFmsgBody.strHostIFkeyAttr.u8KeyAction = ADDKEY_AP;
strHostIFmsg.uniHostIFmsgBody.strHostIFkeyAttr.
uniHostIFkeyAttr.strHostIFwpaAttr.u8keyidx = u8Idx;
}
- #endif
if (mode == STATION_MODE)
strHostIFmsg.uniHostIFmsgBody.strHostIFkeyAttr.u8KeyAction = ADDKEY;
strHostIFmsg.uniHostIFmsgBody.strHostIFkeyAttr.enuKeyType = WPARxGtk;
strHostIFmsg.drvHandler = hWFIDrv;
- #ifdef WILC_AP_EXTERNAL_MLME
if (mode == AP_MODE) {
strHostIFmsg.uniHostIFmsgBody.strHostIFkeyAttr.u8KeyAction = ADDKEY_AP;
strHostIFmsg.uniHostIFmsgBody.strHostIFkeyAttr.uniHostIFkeyAttr.strHostIFwpaAttr.u8Ciphermode = u8Ciphermode;
}
- #endif
if (mode == STATION_MODE)
strHostIFmsg.uniHostIFmsgBody.strHostIFkeyAttr.u8KeyAction = ADDKEY;
return s32Error;
}
-#ifdef WILC_AP_EXTERNAL_MLME
/**
* @brief host_int_get_inactive_time
* @details
return s32Error;
}
-#endif
+
/**
* @brief host_int_test_get_int_wid
* @details Test function for getting wids
}
#endif
-#ifdef WILC_AP_EXTERNAL_MLME
/**
* @brief host_int_add_beacon
* @details Setting add beacon params in message queue
return s32Error;
}
-#endif /*WILC_AP_EXTERNAL_MLME*/
+
u32 wilc_get_chipid(u8);
s32 host_int_set_power_mgmt(tstrWILC_WFIDrv *hWFIDrv, bool bIsEnabled, u32 u32Timeout)
#include "wilc_wlan_if.h"
#include "wilc_wlan.h"
-#ifdef WILC_AP_EXTERNAL_MLME
struct wilc_wfi_radiotap_hdr {
struct ieee80211_radiotap_header hdr;
return 0;
}
-#endif /* WILC_AP_EXTERNAL_MLME */
PRINT_D(GENERIC_DBG, "Deinitializing wilc1000\n");
g_linux_wlan->close = 1;
wilc1000_wlan_deinit(g_linux_wlan);
- #ifdef WILC_AP_EXTERNAL_MLME
WILC_WFI_deinit_mon_interface();
- #endif
}
up(&close_exit_sync);
}
}
-#ifdef WILC_AP_EXTERNAL_MLME
/* Bug 4600 : WILC_WFI_deinit_mon_interface was already called at mac_close */
/* WILC_WFI_deinit_mon_interface(); */
-#endif
/* if(g_linux_wlan->open_ifcs==0) */
{
const u8 *pu8RxMic = NULL;
const u8 *pu8TxMic = NULL;
u8 u8mode = NO_ENCRYPT;
- #ifdef WILC_AP_EXTERNAL_MLME
u8 u8gmode = NO_ENCRYPT;
u8 u8pmode = NO_ENCRYPT;
AUTHTYPE_T tenuAuth_type = ANY;
- #endif
priv = wiphy_priv(wiphy);
switch (params->cipher) {
case WLAN_CIPHER_SUITE_WEP40:
case WLAN_CIPHER_SUITE_WEP104:
- #ifdef WILC_AP_EXTERNAL_MLME
if (priv->wdev->iftype == NL80211_IFTYPE_AP) {
priv->WILC_WFI_wep_default = key_index;
host_int_add_wep_key_bss_ap(priv->hWILCWFIDrv, params->key, params->key_len, key_index, u8mode, tenuAuth_type);
break;
}
- #endif
if (memcmp(params->key, priv->WILC_WFI_wep_key[key_index], params->key_len)) {
priv->WILC_WFI_wep_default = key_index;
priv->WILC_WFI_wep_key_len[key_index] = params->key_len;
case WLAN_CIPHER_SUITE_TKIP:
case WLAN_CIPHER_SUITE_CCMP:
- #ifdef WILC_AP_EXTERNAL_MLME
if (priv->wdev->iftype == NL80211_IFTYPE_AP || priv->wdev->iftype == NL80211_IFTYPE_P2P_GO) {
if (priv->wilc_gtk[key_index] == NULL) {
}
break;
}
- #endif
{
u8mode = 0;
/*freeing memory allocated by "wilc_gtk" and "wilc_ptk" in "WILC_WIFI_ADD_KEY"*/
- #ifdef WILC_AP_EXTERNAL_MLME
if ((priv->wilc_gtk[key_index]) != NULL) {
if (priv->wilc_gtk[key_index]->key != NULL) {
kfree(priv->wilc_ptk[key_index]);
priv->wilc_ptk[key_index] = NULL;
}
- #endif
/*Delete saved PTK and GTK keys params, if any*/
if (g_key_ptk_params.key != NULL) {
s32 s32Error = 0;
struct wilc_priv *priv;
perInterface_wlan_t *nic;
- #ifdef WILC_AP_EXTERNAL_MLME
u32 i = 0;
u32 associatedsta = 0;
u32 inactive_time = 0;
- #endif
priv = wiphy_priv(wiphy);
nic = netdev_priv(dev);
- #ifdef WILC_AP_EXTERNAL_MLME
if (nic->iftype == AP_MODE || nic->iftype == GO_MODE) {
PRINT_D(HOSTAPD_DBG, "Getting station parameters\n");
PRINT_D(CFG80211_DBG, "Inactive time %d\n", sinfo->inactive_time);
}
- #endif
if (nic->iftype == STATION_MODE) {
tstrStatistics strStatistics;
return 0;
}
-#ifdef WILC_AP_EXTERNAL_MLME
+
/**
* @brief change_virtual_intf
* @details Change type/configuration of virtual interface,
return 0;
}
-
-
-#endif /*WILC_AP_EXTERNAL_MLME*/
static struct cfg80211_ops wilc_cfg80211_ops = {
.set_monitor_channel = set_channel,
.del_key = del_key,
.get_key = get_key,
.set_default_key = set_default_key,
- #ifdef WILC_AP_EXTERNAL_MLME
.add_virtual_intf = add_virtual_intf,
.del_virtual_intf = del_virtual_intf,
.change_virtual_intf = change_virtual_intf,
.add_station = add_station,
.del_station = del_station,
.change_station = change_station,
- #endif /* WILC_AP_EXTERNAL_MLME*/
.get_station = get_station,
.dump_station = dump_station,
.change_bss = change_bss,
}
- #ifdef WILC_AP_EXTERNAL_MLME
/* enable 802.11n HT */
WILC_WFI_band_2ghz.ht_cap.ht_supported = 1;
WILC_WFI_band_2ghz.ht_cap.cap |= (1 << IEEE80211_HT_CAP_RX_STBC_SHIFT);
WILC_WFI_band_2ghz.ht_cap.mcs.rx_mask[0] = 0xff;
WILC_WFI_band_2ghz.ht_cap.ampdu_factor = IEEE80211_HT_MAX_AMPDU_8K;
WILC_WFI_band_2ghz.ht_cap.ampdu_density = IEEE80211_HT_MPDU_DENSITY_NONE;
- #endif
/*wiphy bands*/
wdev->wiphy->bands[IEEE80211_BAND_2GHZ] = &WILC_WFI_band_2ghz;
return p->txq_entries;
}
/*Bug3959: transmitting mgmt frames received from host*/
-#if defined(WILC_AP_EXTERNAL_MLME) || defined(WILC_P2P)
+#if defined(WILC_P2P)
int wilc_wlan_txq_add_mgmt_pkt(void *priv, u8 *buffer, u32 buffer_size, wilc_tx_complete_func_t func)
{
wilc_wlan_txq_add_to_tail(tqe);
return 1;
}
-#endif /*WILC_AP_EXTERNAL_MLME*/
+#endif /* WILC_P2P */
static struct txq_entry_t *wilc_wlan_txq_get_first(void)
{
wilc_wlan_dev_t *p = (wilc_wlan_dev_t *)&g_wlan;
else if (tqe->type == WILC_NET_PKT) {
vmm_sz = ETH_ETHERNET_HDR_OFFSET;
}
-#ifdef WILC_AP_EXTERNAL_MLME
else {
vmm_sz = HOST_HDR_OFFSET;
}
-#endif
vmm_sz += tqe->buffer_size;
PRINT_D(TX_DBG, "VMM Size before alignment = %d\n", vmm_sz);
if (vmm_sz & 0x3) { /* has to be word aligned */
header = (tqe->type << 31) | (tqe->buffer_size << 15) | vmm_sz;
/*Bug3959: transmitting mgmt frames received from host*/
/*setting bit 30 in the host header to indicate mgmt frame*/
-#ifdef WILC_AP_EXTERNAL_MLME
if (tqe->type == WILC_MGMT_PKT)
header |= (1 << 30);
else
header &= ~(1 << 30);
-#endif
#ifdef BIG_ENDIAN
header = BYTE_SWAP(header);
}
/*bug 3887: [AP] Allow Management frames to be passed to the host*/
- #if defined(WILC_AP_EXTERNAL_MLME) || defined(WILC_P2P)
+ #if defined(WILC_P2P)
#define IS_MANAGMEMENT 0x100
#define IS_MANAGMEMENT_CALLBACK 0x080
#define IS_MGMT_STATUS_SUCCES 0x040
oup->wlan_cfg_get_value = wilc_wlan_cfg_get_val;
/*Bug3959: transmitting mgmt frames received from host*/
- #if defined(WILC_AP_EXTERNAL_MLME) || defined(WILC_P2P)
+ #if defined(WILC_P2P)
oup->wlan_add_mgmt_to_tx_que = wilc_wlan_txq_add_mgmt_pkt;
#endif
#define WILC_CFG_PKT 1
#define WILC_NET_PKT 0
/*Bug3959: transmitting mgmt frames received from host*/
-#ifdef WILC_AP_EXTERNAL_MLME
#define WILC_MGMT_PKT 2
-#endif /*WILC_AP_EXTERNAL_MLME*/
#define WILC_CFG_SET 1
#define WILC_CFG_QUERY 0
#define WILC_WLAN_IF_H
/*bug 3887: [AP] Allow Management frames to be passed to the host*/
-#define WILC_AP_EXTERNAL_MLME
#define WILC_P2P
#define TCP_ENHANCEMENTS
/* #define MEMORY_STATIC */
int (*wlan_cfg_get)(int, u32, int, u32);
int (*wlan_cfg_get_value)(u32, u8 *, u32);
/*Bug3959: transmitting mgmt frames received from host*/
- #if defined(WILC_AP_EXTERNAL_MLME) || defined(WILC_P2P)
+ #if defined(WILC_P2P)
int (*wlan_add_mgmt_to_tx_que)(void *, u8 *, u32, wilc_tx_complete_func_t);
#endif
} wilc_wlan_oup_t;
/* SCAN Complete notification WID*/
WID_SCAN_COMPLETE = 0x00C9,
-#ifdef WILC_AP_EXTERNAL_MLME
WID_DEL_BEACON = 0x00CA,
-#endif
WID_LOGTerminal_Switch = 0x00CD,
/* EMAC Short WID list */