pstrConnectInfo->au8bssid[1], pstrConnectInfo->au8bssid[2], pstrConnectInfo->au8bssid[3], pstrConnectInfo->au8bssid[4], pstrConnectInfo->au8bssid[5]);
WILC_memcpy(priv->au8AssociatedBss, pstrConnectInfo->au8bssid, ETH_ALEN);
- /* set bssid in frame filter */
- /* linux_wlan_set_bssid(dev,pstrConnectInfo->au8bssid); */
-
/* BugID_4209: if this network has expired in the scan results in the above nl80211 layer, refresh them here by calling
* cfg80211_inform_bss() with the last Scan results before calling cfg80211_connect_result() to avoid
* Linux kernel warning generated at the nl80211 layer */
}
if (bNeedScanRefresh == WILC_TRUE) {
- /* RefreshScanResult(priv); */
/*BugID_5418*/
/*Also, refrsh DIRECT- results if */
refresh_scan(priv, 1, WILC_TRUE);
priv = wiphy_priv(wiphy);
- /*if(connecting)
- * return -EBUSY; */
-
- /*BugID_4800: if in AP mode, return.*/
- /*This check is to handle the situation when user*/
- /*requests "create group" during a running scan*/
- /* host_int_set_wfi_drv_handler(priv->hWILCWFIDrv); */
-#if 0
- if (priv->dev->ieee80211_ptr->iftype == NL80211_IFTYPE_AP) {
- PRINT_D(GENERIC_DBG, "Required scan while in AP mode");
- return s32Error;
- }
-#endif /* end of if 0 */
priv->pstrScanReq = request;
priv->u32RcvdChCount = 0;
{
WILC_Sint32 s32Error = WILC_SUCCESS;
WILC_Uint32 i;
- /* SECURITY_T tenuSecurity_t = NO_SECURITY; */
u8 u8security = NO_ENCRYPT;
AUTHTYPE_T tenuAuth_type = ANY;
WILC_Char *pcgroup_encrypt_val;
host_int_set_wfi_drv_handler((WILC_Uint32)priv->hWILCWFIDrv);
- /* host_int_set_wfi_drv_handler((WILC_Uint32)priv->hWILCWFIDrv); */
PRINT_D(CFG80211_DBG, "Connecting to SSID [%s] on netdev [%p] host if [%x]\n", sme->ssid, dev, (WILC_Uint32)priv->hWILCWFIDrv);
#ifdef WILC_P2P
if (!(WILC_strncmp(sme->ssid, "DIRECT-", 7))) {
* we will add to it the pairwise cipher suite(s) */
pcwpa_version = "Default";
PRINT_D(CORECONFIG_DBG, ">> sme->crypto.wpa_versions: %x\n", sme->crypto.wpa_versions);
- /* case NL80211_WPA_VERSION_1: */
if (sme->crypto.cipher_group == WLAN_CIPHER_SUITE_WEP40) {
- /* tenuSecurity_t = WEP_40; */
u8security = ENCRYPT_ENABLED | WEP;
pcgroup_encrypt_val = "WEP40";
pccipher_group = "WLAN_CIPHER_SUITE_WEP40";
host_int_set_WEPDefaultKeyID(priv->hWILCWFIDrv, sme->key_idx);
host_int_add_wep_key_bss_sta(priv->hWILCWFIDrv, sme->key, sme->key_len, sme->key_idx);
} else if (sme->crypto.cipher_group == WLAN_CIPHER_SUITE_WEP104) {
- /* tenuSecurity_t = WEP_104; */
u8security = ENCRYPT_ENABLED | WEP | WEP_EXTENDED;
pcgroup_encrypt_val = "WEP104";
pccipher_group = "WLAN_CIPHER_SUITE_WEP104";
host_int_set_WEPDefaultKeyID(priv->hWILCWFIDrv, sme->key_idx);
host_int_add_wep_key_bss_sta(priv->hWILCWFIDrv, sme->key, sme->key_len, sme->key_idx);
} else if (sme->crypto.wpa_versions & NL80211_WPA_VERSION_2) {
- /* case NL80211_WPA_VERSION_2: */
if (sme->crypto.cipher_group == WLAN_CIPHER_SUITE_TKIP) {
- /* tenuSecurity_t = WPA2_TKIP; */
u8security = ENCRYPT_ENABLED | WPA2 | TKIP;
pcgroup_encrypt_val = "WPA2_TKIP";
pccipher_group = "TKIP";
pcwpa_version = "WPA_VERSION_2";
} else if (sme->crypto.wpa_versions & NL80211_WPA_VERSION_1) {
if (sme->crypto.cipher_group == WLAN_CIPHER_SUITE_TKIP) {
- /* tenuSecurity_t = WPA_TKIP; */
u8security = ENCRYPT_ENABLED | WPA | TKIP;
pcgroup_encrypt_val = "WPA_TKIP";
pccipher_group = "TKIP";
}
pcwpa_version = "WPA_VERSION_1";
- /* break; */
} else {
s32Error = -ENOTSUPP;
PRINT_ER("Not supported cipher: Error(%d)\n", s32Error);
host_int_add_rx_gtk(priv->hWILCWFIDrv, params->key, KeyLen,
key_index, params->seq_len, params->seq, pu8RxMic, pu8TxMic, STATION_MODE, u8mode);
- /* host_int_add_tx_gtk(priv->hWILCWFIDrv,params->key_len,params->key,key_index); */
} else {
if (params->key_len > 16 && params->cipher == WLAN_CIPHER_SUITE_TKIP) {
/* swap the tx mic by rx mic */
struct WILC_WFI_priv *priv;
priv = wiphy_priv(wiphy);
-/* priv = netdev_priv(priv->wdev->netdev); */
pstrCfgParamVal.u32SetCfgFlag = 0;
PRINT_D(CFG80211_DBG, "Setting Wiphy params \n");
const struct cfg80211_bitrate_mask *mask)
{
WILC_Sint32 s32Error = WILC_SUCCESS;
- /* strCfgParamVal pstrCfgParamVal; */
- /* struct WILC_WFI_priv* priv; */
PRINT_D(CFG80211_DBG, "Setting Bitrate mask function\n");
-#if 0
- priv = wiphy_priv(wiphy);
- /* priv = netdev_priv(priv->wdev->netdev); */
-
- pstrCfgParamVal.curr_tx_rate = mask->control[IEEE80211_BAND_2GHZ].legacy;
-
- PRINT_D(CFG80211_DBG, "Tx rate = %d\n", pstrCfgParamVal.curr_tx_rate);
- s32Error = hif_set_cfg(priv->hWILCWFIDrv, &pstrCfgParamVal);
-
- if (s32Error)
- PRINT_ER("Error in setting bitrate\n");
-#endif
return s32Error;
}
WILC_Sint32 s32Error = WILC_SUCCESS;
struct WILC_WFI_priv *priv = wiphy_priv(wiphy);
- /* priv = netdev_priv(priv->wdev->netdev); */
PRINT_D(CFG80211_DBG, "Deleting PMKSA keys\n");
static int WILC_WFI_flush_pmksa(struct wiphy *wiphy, struct net_device *netdev)
{
struct WILC_WFI_priv *priv = wiphy_priv(wiphy);
- /* priv = netdev_priv(priv->wdev->netdev); */
PRINT_D(CFG80211_DBG, "Flushing PMKID key values\n");
return -ENOENT;
priv = wiphy_priv(wiphy);
- /* priv = netdev_priv(priv->wdev->netdev); */
sinfo->filled |= BIT(NL80211_STA_INFO_SIGNAL);
host_int_get_rssi(priv->hWILCWFIDrv, &(sinfo->signal));
-#if 0
- sinfo->filled |= STATION_INFO_TX_BYTES |
- STATION_INFO_TX_PACKETS |
- STATION_INFO_RX_BYTES |
- STATION_INFO_RX_PACKETS | STATION_INFO_SIGNAL | STATION_INFO_INACTIVE_TIME;
-
- down(&SemHandleUpdateStats);
- sinfo->inactive_time = priv->netstats.rx_time > priv->netstats.tx_time ? jiffies_to_msecs(jiffies - priv->netstats.tx_time) : jiffies_to_msecs(jiffies - priv->netstats.rx_time);
- sinfo->rx_bytes = priv->netstats.rx_bytes;
- sinfo->tx_bytes = priv->netstats.tx_bytes;
- sinfo->rx_packets = priv->netstats.rx_packets;
- sinfo->tx_packets = priv->netstats.tx_packets;
- up(&SemHandleUpdateStats);
-#endif
return 0;
}
{
WILC_Sint32 s32Error = WILC_SUCCESS;
struct WILC_WFI_priv *priv;
- /* struct WILC_WFI_mon_priv* mon_priv; */
perInterface_wlan_t *nic;
u8 interface_type;
WILC_Uint16 TID = 0;
case NL80211_IFTYPE_STATION:
connecting = 0;
PRINT_D(HOSTAPD_DBG, "Interface type = NL80211_IFTYPE_STATION\n");
- /* linux_wlan_set_bssid(dev,g_linux_wlan->strInterfaceInfo[0].aSrcAddress); */
/* send delba over wlan interface */
host_int_set_power_mgmt(priv->hWILCWFIDrv, 0, 0);
connecting = 0;
PRINT_D(HOSTAPD_DBG, "Interface type = NL80211_IFTYPE_P2P_CLIENT\n");
- /* linux_wlan_set_bssid(dev,g_linux_wlan->strInterfaceInfo[0].aSrcAddress); */
host_int_del_All_Rx_BASession(priv->hWILCWFIDrv, g_linux_wlan->strInterfaceInfo[0].aBSSID, TID);
break;
case NL80211_IFTYPE_AP:
- /* connecting = 1; */
bEnablePS = WILC_FALSE;
PRINT_D(HOSTAPD_DBG, "Interface type = NL80211_IFTYPE_AP %d\n", type);
- /* linux_wlan_set_bssid(dev,g_linux_wlan->strInterfaceInfo[0].aSrcAddress); */
- /* mon_priv = netdev_priv(dev); */
- /* mon_priv->real_ndev = dev; */
dev->ieee80211_ptr->iftype = type;
priv->wdev->iftype = type;
nic->iftype = AP_MODE;
mac_close(dev);
mac_open(dev);
- /* wilc1000_wlan_deinit(g_linux_wlan); */
- /* wilc1000_wlan_init(dev,nic); */
- /* repeat_power_cycle(nic); */
- /* nic->iftype = STATION_MODE; */
-
/*BugID_4847: registered frames in firmware are now lost
* due to mac close. So re-register those frames */
for (i = 0; i < num_reg_frame; i++) {
host_int_del_All_Rx_BASession(priv->hWILCWFIDrv, g_linux_wlan->strInterfaceInfo[0].aBSSID, TID);
bEnablePS = WILC_FALSE;
PRINT_D(HOSTAPD_DBG, "Interface type = NL80211_IFTYPE_GO\n");
- /* linux_wlan_set_bssid(dev,g_linux_wlan->strInterfaceInfo[0].aSrcAddress); */
- /* mon_priv = netdev_priv(dev); */
- /* mon_priv->real_ndev = dev; */
dev->ieee80211_ptr->iftype = type;
priv->wdev->iftype = type;
PRINT_D(CORECONFIG_DBG, "(WILC_Uint32)priv->hWILCWFIDrv[%x]\n", (WILC_Uint32)priv->hWILCWFIDrv);
- /* host_int_set_operation_mode((WILC_Uint32)priv->hWILCWFIDrv,AP_MODE); */
#ifndef SIMULATION
#ifdef WILC_P2P
/* ensure that the message Q is empty */
host_int_wait_msg_queue_idle();
-
- /*while(!g_hif_thread_idle)
- * {
- * PRINT_D(GENERIC_DBG, "Wait for host IF idle\n");
- * WILC_Sleep(10);
- * }*/
wilc1000_wlan_deinit(g_linux_wlan);
- /* repeat_power_cycle_partially(g_linux_wlan); */
wilc1000_wlan_init(dev, nic);
g_wilc_initialized = 1;
struct WILC_WFI_priv *priv;
perInterface_wlan_t *nic;
WILC_NULLCHECK(s32Error, wiphy);
- /*BugID_4795: mac may be null pointer to indicate deleting all stations, so avoid null check*/
- /* WILC_NULLCHECK(s32Error, mac); */
priv = wiphy_priv(wiphy);
nic = netdev_priv(dev);
{
perInterface_wlan_t *nic;
struct WILC_WFI_priv *priv;
- /* struct WILC_WFI_mon_priv* mon_priv; */
struct net_device *new_ifc = NULL;
priv = wiphy_priv(wiphy);
.del_key = WILC_WFI_del_key,
.get_key = WILC_WFI_get_key,
.set_default_key = WILC_WFI_set_default_key,
- /* .dump_survey = WILC_WFI_dump_survey, */
#ifdef WILC_AP_EXTERNAL_MLME
.add_virtual_intf = WILC_WFI_add_virt_intf,
.del_virtual_intf = WILC_WFI_del_virt_intf,
#endif
.dump_station = WILC_WFI_dump_station,
.change_bss = WILC_WFI_change_bss,
- /* .auth = WILC_WFI_auth, */
- /* .assoc = WILC_WFI_assoc, */
- /* .deauth = WILC_WFI_deauth, */
- /* .disassoc = WILC_WFI_disassoc, */
.set_wiphy_params = WILC_WFI_set_wiphy_params,
- /* .set_bitrate_mask = WILC_WFI_set_bitrate_mask, */
.set_pmksa = WILC_WFI_set_pmksa,
.del_pmksa = WILC_WFI_del_pmksa,
.flush_pmksa = WILC_WFI_flush_pmksa,
.mgmt_tx_cancel_wait = WILC_WFI_mgmt_tx_cancel_wait,
.mgmt_tx = WILC_WFI_mgmt_tx,
.mgmt_frame_register = WILC_WFI_frame_register,
- /* .mgmt_tx_cancel_wait = WILC_WFI_mgmt_tx_cancel_wait, */
.set_power_mgmt = WILC_WFI_set_power_mgmt,
.set_cqm_rssi_config = WILC_WFI_set_cqm_rssi_config,
#endif
struct WILC_WFI_priv *priv;
priv = wiphy_priv(wiphy);
- /* down(&SemHandleUpdateStats); */
#if 1
switch (changed) {
case WILC_WFI_RX_PKT:
{
- /* MI_PRINTF("In Rx Receive Packet\n"); */
priv->netstats.rx_packets++;
priv->netstats.rx_bytes += pktlen;
priv->netstats.rx_time = get_jiffies_64();
default:
break;
}
- /* down(&SemHandleUpdateStats); */
#endif
return 0;
}
PRINT_D(CFG80211_DBG, "Successful Registering\n");
}
-#if 0
- /*wdev[i]->wiphy->interface_modes =
- * BIT(NL80211_IFTYPE_AP);
- * wdev[i]->iftype = NL80211_IFTYPE_AP;
- */
-
- /*Pointing the priv structure the netdev*/
- priv = netdev_priv(net);
-
- /*linking the wireless_dev structure with the netdevice*/
- priv->dev->ieee80211_ptr = wdev;
- priv->dev->ml_priv = priv;
- wdev->netdev = priv->dev;
-#endif
priv->dev = net;
-#if 0
- ret = host_int_init(&priv->hWILCWFIDrv);
- if (ret) {
- PRINT_ER("Error Init Driver\n");
- }
-#endif
return wdev;
sema_init(&(priv->hSemScanReq), 1);
s32Error = host_int_init(&priv->hWILCWFIDrv);
- /* s32Error = host_int_init(&priv->hWILCWFIDrv_2); */
if (s32Error) {
PRINT_ER("Error while initializing hostinterface\n");
}
op_ifcs--;
s32Error = host_int_deinit(priv->hWILCWFIDrv);
- /* s32Error = host_int_deinit(priv->hWILCWFIDrv_2); */
/* Clear the Shadow scan */
clear_shadow_scan(priv);