diff options
Diffstat (limited to 'drivers/staging/rtl8723bs/os_dep/ioctl_cfg80211.c')
-rw-r--r-- | drivers/staging/rtl8723bs/os_dep/ioctl_cfg80211.c | 143 |
1 files changed, 8 insertions, 135 deletions
diff --git a/drivers/staging/rtl8723bs/os_dep/ioctl_cfg80211.c b/drivers/staging/rtl8723bs/os_dep/ioctl_cfg80211.c index 42c0685e976e..aa2cd69d7056 100644 --- a/drivers/staging/rtl8723bs/os_dep/ioctl_cfg80211.c +++ b/drivers/staging/rtl8723bs/os_dep/ioctl_cfg80211.c @@ -237,7 +237,6 @@ struct cfg80211_bss *rtw_cfg80211_inform_bss(struct adapter *padapter, struct wl bssinf_len = pnetwork->network.IELength + sizeof(struct ieee80211_hdr_3addr); if (bssinf_len > MAX_BSSINFO_LEN) { - DBG_871X("%s IE Length too long > %d byte\n", __func__, MAX_BSSINFO_LEN); goto exit; } @@ -248,7 +247,6 @@ struct cfg80211_bss *rtw_cfg80211_inform_bss(struct adapter *padapter, struct wl { if (wapi_len > 0) { - DBG_871X("%s, no support wapi!\n", __func__); goto exit; } } @@ -281,7 +279,6 @@ struct cfg80211_bss *rtw_cfg80211_inform_bss(struct adapter *padapter, struct wl else if (pssid->SsidLength == ssids[0].ssid_len && !memcmp(pssid->Ssid, ssids[0].ssid, ssids[0].ssid_len)) { - DBG_871X("%s, got sr and ssid match!\n", __func__); } else { @@ -395,7 +392,6 @@ void rtw_cfg80211_ibss_indicate_connect(struct adapter *padapter) int freq = (int)cur_network->network.Configuration.DSConfig; struct ieee80211_channel *chan; - DBG_871X(FUNC_ADPT_FMT"\n", FUNC_ADPT_ARG(padapter)); if (pwdev->iftype != NL80211_IFTYPE_ADHOC) { return; @@ -410,9 +406,9 @@ void rtw_cfg80211_ibss_indicate_connect(struct adapter *padapter) memcpy(&cur_network->network, pnetwork, sizeof(struct wlan_bssid_ex)); if (!rtw_cfg80211_inform_bss(padapter, cur_network)) - DBG_871X(FUNC_ADPT_FMT" inform fail !!\n", FUNC_ADPT_ARG(padapter)); + {} else - DBG_871X(FUNC_ADPT_FMT" inform success !!\n", FUNC_ADPT_ARG(padapter)); + {} } else { @@ -424,12 +420,10 @@ void rtw_cfg80211_ibss_indicate_connect(struct adapter *padapter) && !memcmp(scanned->network.MacAddress, pnetwork->MacAddress, sizeof(NDIS_802_11_MAC_ADDRESS)) ) { if (!rtw_cfg80211_inform_bss(padapter, scanned)) { - DBG_871X(FUNC_ADPT_FMT" inform fail !!\n", FUNC_ADPT_ARG(padapter)); } else { /* DBG_871X(FUNC_ADPT_FMT" inform success !!\n", FUNC_ADPT_ARG(padapter)); */ } } else { - DBG_871X("scanned & pnetwork compare fail\n"); rtw_warn_on(1); } } @@ -448,7 +442,6 @@ void rtw_cfg80211_indicate_connect(struct adapter *padapter) struct wlan_network *cur_network = &(pmlmepriv->cur_network); struct wireless_dev *pwdev = padapter->rtw_wdev; - DBG_871X(FUNC_ADPT_FMT"\n", FUNC_ADPT_ARG(padapter)); if (pwdev->iftype != NL80211_IFTYPE_STATION && pwdev->iftype != NL80211_IFTYPE_P2P_CLIENT ) { @@ -473,15 +466,10 @@ void rtw_cfg80211_indicate_connect(struct adapter *padapter) && !memcmp(&(scanned->network.Ssid), &(pnetwork->Ssid), sizeof(struct ndis_802_11_ssid)) ) { if (!rtw_cfg80211_inform_bss(padapter, scanned)) { - DBG_871X(FUNC_ADPT_FMT" inform fail !!\n", FUNC_ADPT_ARG(padapter)); } else { /* DBG_871X(FUNC_ADPT_FMT" inform success !!\n", FUNC_ADPT_ARG(padapter)); */ } } else { - DBG_871X("scanned: %s(%pM), cur: %s(%pM)\n", - scanned->network.Ssid.Ssid, MAC_ARG(scanned->network.MacAddress), - pnetwork->Ssid.Ssid, MAC_ARG(pnetwork->MacAddress) - ); rtw_warn_on(1); } } @@ -501,7 +489,6 @@ check_bss: notify_channel = ieee80211_get_channel(wiphy, freq); - DBG_871X(FUNC_ADPT_FMT" call cfg80211_roamed\n", FUNC_ADPT_ARG(padapter)); roam_info.channel = notify_channel; roam_info.bssid = cur_network->network.MacAddress; roam_info.req_ie = @@ -530,8 +517,6 @@ void rtw_cfg80211_indicate_disconnect(struct adapter *padapter) struct mlme_priv *pmlmepriv = &padapter->mlmepriv; struct wireless_dev *pwdev = padapter->rtw_wdev; - DBG_871X(FUNC_ADPT_FMT"\n", FUNC_ADPT_ARG(padapter)); - if (pwdev->iftype != NL80211_IFTYPE_STATION && pwdev->iftype != NL80211_IFTYPE_P2P_CLIENT ) { @@ -958,9 +943,6 @@ static int rtw_cfg80211_set_encryption(struct net_device *dev, struct ieee_param /* _set_timer(&padapter->securitypriv.tkip_timer, 50); */ } - /* DEBUG_ERR((" param->u.crypt.key_len =%d\n", param->u.crypt.key_len)); */ - DBG_871X(" ~~~~set sta key:unicastkey\n"); - rtw_setstakey_cmd(padapter, psta, true, true); } else/* group key */ @@ -971,8 +953,6 @@ static int rtw_cfg80211_set_encryption(struct net_device *dev, struct ieee_param memcpy(padapter->securitypriv.dot118021XGrptxmickey[param->u.crypt.idx].skey, &(param->u.crypt.key[16]), 8); memcpy(padapter->securitypriv.dot118021XGrprxmickey[param->u.crypt.idx].skey, &(param->u.crypt.key[24]), 8); padapter->securitypriv.binstallGrpkey = true; - /* DEBUG_ERR((" param->u.crypt.key_len =%d\n", param->u.crypt.key_len)); */ - DBG_871X(" ~~~~set sta key:groupkey\n"); padapter->securitypriv.dot118021XGrpKeyid = param->u.crypt.idx; rtw_set_key(padapter, &padapter->securitypriv, param->u.crypt.idx, 1, true); @@ -988,7 +968,6 @@ static int rtw_cfg80211_set_encryption(struct net_device *dev, struct ieee_param DBG_871X("\n");*/ padapter->securitypriv.dot11wBIPKeyid = param->u.crypt.idx; padapter->securitypriv.binstallBIPkey = true; - DBG_871X(" ~~~~set sta key:IGKT\n"); } } } @@ -1034,13 +1013,6 @@ static int cfg80211_rtw_add_key(struct wiphy *wiphy, struct net_device *ndev, struct adapter *padapter = rtw_netdev_priv(ndev); struct mlme_priv *pmlmepriv = &padapter->mlmepriv; - DBG_871X(FUNC_NDEV_FMT" adding key for %pM\n", FUNC_NDEV_ARG(ndev), mac_addr); - DBG_871X("cipher = 0x%x\n", params->cipher); - DBG_871X("key_len = 0x%x\n", params->key_len); - DBG_871X("seq_len = 0x%x\n", params->seq_len); - DBG_871X("key_index =%d\n", key_index); - DBG_871X("pairwise =%d\n", pairwise); - param_len = sizeof(struct ieee_param) + params->key_len; param = rtw_malloc(param_len); if (param == NULL) @@ -1134,7 +1106,6 @@ static int cfg80211_rtw_get_key(struct wiphy *wiphy, struct net_device *ndev, void (*callback)(void *cookie, struct key_params*)) { - DBG_871X(FUNC_NDEV_FMT"\n", FUNC_NDEV_ARG(ndev)); return 0; } @@ -1144,8 +1115,6 @@ static int cfg80211_rtw_del_key(struct wiphy *wiphy, struct net_device *ndev, struct adapter *padapter = rtw_netdev_priv(ndev); struct security_priv *psecuritypriv = &padapter->securitypriv; - DBG_871X(FUNC_NDEV_FMT" key_index =%d\n", FUNC_NDEV_ARG(ndev), key_index); - if (key_index == psecuritypriv->dot11PrivacyKeyIndex) { /* clear the flag of wep default key set. */ @@ -1163,9 +1132,6 @@ static int cfg80211_rtw_set_default_key(struct wiphy *wiphy, struct adapter *padapter = rtw_netdev_priv(ndev); struct security_priv *psecuritypriv = &padapter->securitypriv; - DBG_871X(FUNC_NDEV_FMT" key_index =%d, unicast =%d, multicast =%d\n", - FUNC_NDEV_ARG(ndev), key_index, unicast, multicast); - if ((key_index < WEP_KEYS) && ((psecuritypriv->dot11PrivacyAlgrthm == _WEP40_) || (psecuritypriv->dot11PrivacyAlgrthm == _WEP104_))) /* set wep default key */ { psecuritypriv->ndisencryptstatus = Ndis802_11Encryption1Enabled; @@ -1201,7 +1167,6 @@ static int cfg80211_rtw_get_station(struct wiphy *wiphy, sinfo->filled = 0; if (!mac) { - DBG_871X(FUNC_NDEV_FMT" mac ==%p\n", FUNC_NDEV_ARG(ndev), mac); ret = -ENOENT; goto exit; } @@ -1214,7 +1179,6 @@ static int cfg80211_rtw_get_station(struct wiphy *wiphy, } #ifdef DEBUG_CFG80211 - DBG_871X(FUNC_NDEV_FMT" mac =%pM\n", FUNC_NDEV_ARG(ndev), MAC_ARG(mac)); #endif /* for infra./P2PClient mode */ @@ -1225,7 +1189,6 @@ static int cfg80211_rtw_get_station(struct wiphy *wiphy, struct wlan_network *cur_network = &(pmlmepriv->cur_network); if (memcmp((u8 *)mac, cur_network->network.MacAddress, ETH_ALEN)) { - DBG_871X("%s, mismatch bssid =%pM\n", __func__, MAC_ARG(cur_network->network.MacAddress)); ret = -ENOENT; goto exit; } @@ -1270,8 +1233,6 @@ static int cfg80211_rtw_change_iface(struct wiphy *wiphy, struct mlme_ext_priv *pmlmeext = &(padapter->mlmeextpriv); int ret = 0; - DBG_871X(FUNC_NDEV_FMT" type =%d\n", FUNC_NDEV_ARG(ndev), type); - if (adapter_to_dvobj(padapter)->processing_dev_remove == true) { ret = -EPERM; @@ -1279,23 +1240,18 @@ static int cfg80211_rtw_change_iface(struct wiphy *wiphy, } { - DBG_871X(FUNC_NDEV_FMT" call netdev_open\n", FUNC_NDEV_ARG(ndev)); if (netdev_open(ndev) != 0) { - DBG_871X(FUNC_NDEV_FMT" call netdev_open fail\n", FUNC_NDEV_ARG(ndev)); ret = -EPERM; goto exit; } } if (_FAIL == rtw_pwr_wakeup(padapter)) { - DBG_871X(FUNC_NDEV_FMT" call rtw_pwr_wakeup fail\n", FUNC_NDEV_ARG(ndev)); ret = -EPERM; goto exit; } old_type = rtw_wdev->iftype; - DBG_871X(FUNC_NDEV_FMT" old_iftype =%d, new_iftype =%d\n", - FUNC_NDEV_ARG(ndev), old_type, type); if (old_type != type) { @@ -1331,7 +1287,6 @@ static int cfg80211_rtw_change_iface(struct wiphy *wiphy, exit: - DBG_871X(FUNC_NDEV_FMT" ret:%d\n", FUNC_NDEV_ARG(ndev), ret); return ret; } @@ -1345,7 +1300,6 @@ void rtw_cfg80211_indicate_scan_done(struct adapter *adapter, bool aborted) spin_lock_bh(&pwdev_priv->scan_req_lock); if (pwdev_priv->scan_request) { #ifdef DEBUG_CFG80211 - DBG_871X("%s with scan req\n", __func__); #endif /* avoid WARN_ON(request != wiphy_to_dev(request->wiphy)->scan_req); */ @@ -1361,7 +1315,6 @@ void rtw_cfg80211_indicate_scan_done(struct adapter *adapter, bool aborted) pwdev_priv->scan_request = NULL; } else { #ifdef DEBUG_CFG80211 - DBG_871X("%s without scan req\n", __func__); #endif } spin_unlock_bh(&pwdev_priv->scan_req_lock); @@ -1492,9 +1445,6 @@ static int cfg80211_rtw_scan(struct wiphy *wiphy padapter = rtw_netdev_priv(ndev); pwdev_priv = adapter_wdev_data(padapter); pmlmepriv = &padapter->mlmepriv; - -/* ifdef DEBUG_CFG80211 */ - DBG_871X(FUNC_ADPT_FMT"\n", FUNC_ADPT_ARG(padapter)); /* endif */ spin_lock_bh(&pwdev_priv->scan_req_lock); @@ -1504,7 +1454,6 @@ static int cfg80211_rtw_scan(struct wiphy *wiphy if (check_fwstate(pmlmepriv, WIFI_AP_STATE) == true) { #ifdef DEBUG_CFG80211 - DBG_871X("%s under WIFI_AP_STATE\n", __func__); #endif if (check_fwstate(pmlmepriv, WIFI_UNDER_WPS|_FW_UNDER_SURVEY|_FW_UNDER_LINKING) == true) @@ -1551,14 +1500,12 @@ static int cfg80211_rtw_scan(struct wiphy *wiphy lastscantime = jiffies; if (passtime > 12000) { - DBG_871X("%s: bBusyTraffic == true\n", __func__); need_indicate_scan_done = true; goto check_need_indicate_scan_done; } } if (rtw_is_scan_deny(padapter)) { - DBG_871X(FUNC_ADPT_FMT ": scan deny\n", FUNC_ADPT_ARG(padapter)); need_indicate_scan_done = true; goto check_need_indicate_scan_done; } @@ -1583,7 +1530,6 @@ static int cfg80211_rtw_scan(struct wiphy *wiphy memset(ch, 0, sizeof(struct rtw_ieee80211_channel)*RTW_CHANNEL_SCAN_AMOUNT); for (i = 0; i < request->n_channels && i < RTW_CHANNEL_SCAN_AMOUNT; i++) { #ifdef DEBUG_CFG80211 - DBG_871X(FUNC_ADPT_FMT CHAN_FMT"\n", FUNC_ADPT_ARG(padapter), CHAN_ARG(request->channels[i])); #endif ch[i].hw_value = request->channels[i]->hw_value; ch[i].flags = request->channels[i]->flags; @@ -1967,8 +1913,6 @@ static int cfg80211_rtw_leave_ibss(struct wiphy *wiphy, struct net_device *ndev) enum nl80211_iftype old_type; int ret = 0; - DBG_871X(FUNC_NDEV_FMT"\n", FUNC_NDEV_ARG(ndev)); - old_type = rtw_wdev->iftype; rtw_set_to_roam(padapter, 0); @@ -2004,14 +1948,9 @@ static int cfg80211_rtw_connect(struct wiphy *wiphy, struct net_device *ndev, padapter->mlmepriv.not_indic_disco = true; - DBG_871X("=>"FUNC_NDEV_FMT"\n", FUNC_NDEV_ARG(ndev)); - DBG_871X("privacy =%d, key =%p, key_len =%d, key_idx =%d\n", - sme->privacy, sme->key, sme->key_len, sme->key_idx); - if (adapter_wdev_data(padapter)->block == true) { ret = -EBUSY; - DBG_871X("%s wdev_priv.block is set\n", __func__); goto exit; } @@ -2089,7 +2028,6 @@ static int cfg80211_rtw_connect(struct wiphy *wiphy, struct net_device *ndev, psecuritypriv->dot11AuthAlgrthm == dot11AuthAlgrthm_Auto) && sme->key) { u32 wep_key_idx, wep_key_len, wep_total_len; struct ndis_802_11_wep *pwep = NULL; - DBG_871X("%s(): Shared/Auto WEP\n", __func__); wep_key_idx = sme->key_idx; wep_key_len = sme->key_len; @@ -2104,7 +2042,6 @@ static int cfg80211_rtw_connect(struct wiphy *wiphy, struct net_device *ndev, wep_total_len = wep_key_len + FIELD_OFFSET(struct ndis_802_11_wep, KeyMaterial); pwep = rtw_malloc(wep_total_len); if (pwep == NULL) { - DBG_871X(" wpa_set_encryption: pwep allocate fail !!!\n"); ret = -ENOMEM; goto exit; } @@ -2175,22 +2112,17 @@ static int cfg80211_rtw_disconnect(struct wiphy *wiphy, struct net_device *ndev, { struct adapter *padapter = rtw_netdev_priv(ndev); - DBG_871X(FUNC_NDEV_FMT"\n", FUNC_NDEV_ARG(ndev)); - rtw_set_to_roam(padapter, 0); rtw_scan_abort(padapter); LeaveAllPowerSaveMode(padapter); rtw_disassoc_cmd(padapter, 500, false); - DBG_871X("%s...call rtw_indicate_disconnect\n", __func__); - rtw_indicate_disconnect(padapter); rtw_free_assoc_resources(padapter, 1); rtw_pwr_wakeup(padapter); - DBG_871X(FUNC_NDEV_FMT" return 0\n", FUNC_NDEV_ARG(ndev)); return 0; } @@ -2223,9 +2155,6 @@ static int cfg80211_rtw_set_power_mgmt(struct wiphy *wiphy, struct adapter *padapter = rtw_netdev_priv(ndev); struct rtw_wdev_priv *rtw_wdev_priv = adapter_wdev_data(padapter); - DBG_871X(FUNC_NDEV_FMT" enabled:%u, timeout:%d\n", FUNC_NDEV_ARG(ndev), - enabled, timeout); - rtw_wdev_priv->power_mgmt = enabled; if (!enabled) @@ -2243,8 +2172,6 @@ static int cfg80211_rtw_set_pmksa(struct wiphy *wiphy, struct security_priv *psecuritypriv = &padapter->securitypriv; u8 strZeroMacAddress[ETH_ALEN] = { 0x00 }; - DBG_871X(FUNC_NDEV_FMT"\n", FUNC_NDEV_ARG(ndev)); - if (!memcmp((u8 *)pmksa->bssid, strZeroMacAddress, ETH_ALEN)) return -EINVAL; @@ -2253,8 +2180,6 @@ static int cfg80211_rtw_set_pmksa(struct wiphy *wiphy, /* overwrite PMKID */ for (index = 0 ; index < NUM_PMKID_CACHE; index++) { if (!memcmp(psecuritypriv->PMKIDList[index].Bssid, (u8 *)pmksa->bssid, ETH_ALEN)) { - /* BSSID is matched, the same AP => rewrite with new PMKID. */ - DBG_871X(FUNC_NDEV_FMT" BSSID exists in the PMKList.\n", FUNC_NDEV_ARG(ndev)); memcpy(psecuritypriv->PMKIDList[index].PMKID, (u8 *)pmksa->pmkid, WLAN_PMKID_LEN); psecuritypriv->PMKIDList[index].bUsed = true; @@ -2265,9 +2190,6 @@ static int cfg80211_rtw_set_pmksa(struct wiphy *wiphy, } if (!blInserted) { - /* Find a new entry */ - DBG_871X(FUNC_NDEV_FMT" Use the new entry index = %d for this PMKID.\n", - FUNC_NDEV_ARG(ndev), psecuritypriv->PMKIDIndex); memcpy(psecuritypriv->PMKIDList[psecuritypriv->PMKIDIndex].Bssid, (u8 *)pmksa->bssid, ETH_ALEN); memcpy(psecuritypriv->PMKIDList[psecuritypriv->PMKIDIndex].PMKID, (u8 *)pmksa->pmkid, WLAN_PMKID_LEN); @@ -2289,8 +2211,6 @@ static int cfg80211_rtw_del_pmksa(struct wiphy *wiphy, struct adapter *padapter = rtw_netdev_priv(ndev); struct security_priv *psecuritypriv = &padapter->securitypriv; - DBG_871X(FUNC_NDEV_FMT"\n", FUNC_NDEV_ARG(ndev)); - for (index = 0 ; index < NUM_PMKID_CACHE; index++) { if (!memcmp(psecuritypriv->PMKIDList[index].Bssid, (u8 *)pmksa->bssid, ETH_ALEN)) { /* @@ -2306,8 +2226,6 @@ static int cfg80211_rtw_del_pmksa(struct wiphy *wiphy, } if (false == bMatched) { - DBG_871X(FUNC_NDEV_FMT" do not have matched BSSID\n" - , FUNC_NDEV_ARG(ndev)); return -EINVAL; } @@ -2320,8 +2238,6 @@ static int cfg80211_rtw_flush_pmksa(struct wiphy *wiphy, struct adapter *padapter = rtw_netdev_priv(ndev); struct security_priv *psecuritypriv = &padapter->securitypriv; - DBG_871X(FUNC_NDEV_FMT"\n", FUNC_NDEV_ARG(ndev)); - memset(&psecuritypriv->PMKIDList[0], 0x00, sizeof(struct rt_pmkid_list) * NUM_PMKID_CACHE); psecuritypriv->PMKIDIndex = 0; @@ -2332,8 +2248,6 @@ void rtw_cfg80211_indicate_sta_assoc(struct adapter *padapter, u8 *pmgmt_frame, { struct net_device *ndev = padapter->pnetdev; - DBG_871X(FUNC_ADPT_FMT"\n", FUNC_ADPT_ARG(padapter)); - { struct station_info sinfo; u8 ie_offset; @@ -2353,8 +2267,6 @@ void rtw_cfg80211_indicate_sta_disassoc(struct adapter *padapter, unsigned char { struct net_device *ndev = padapter->pnetdev; - DBG_871X(FUNC_ADPT_FMT"\n", FUNC_ADPT_ARG(padapter)); - cfg80211_del_sta(ndev, da, GFP_ATOMIC); } @@ -2374,8 +2286,6 @@ static netdev_tx_t rtw_cfg80211_monitor_if_xmit_entry(struct sk_buff *skb, struc struct ieee80211_radiotap_header *rtap_hdr; struct adapter *padapter = rtw_netdev_priv(ndev); - DBG_871X(FUNC_NDEV_FMT"\n", FUNC_NDEV_ARG(ndev)); - if (!skb) goto fail; @@ -2450,9 +2360,9 @@ static netdev_tx_t rtw_cfg80211_monitor_if_xmit_entry(struct sk_buff *skb, struc DBG_8192C("RTW_Tx:da =%pM via "FUNC_NDEV_FMT"\n", MAC_ARG(GetAddr1Ptr(buf)), FUNC_NDEV_ARG(ndev)); if (category == RTW_WLAN_CATEGORY_PUBLIC) - DBG_871X("RTW_Tx:%s\n", action_public_str(action)); + {} else - DBG_871X("RTW_Tx:category(%u), action(%u)\n", category, action); + {} /* starting alloc mgmt frame to dump it */ pmgntframe = alloc_mgtxmitframe(pxmitpriv); @@ -2510,21 +2420,17 @@ static int rtw_cfg80211_add_monitor_if(struct adapter *padapter, char *name, str struct rtw_wdev_priv *pwdev_priv = adapter_wdev_data(padapter); if (!name) { - DBG_871X(FUNC_ADPT_FMT" without specific name\n", FUNC_ADPT_ARG(padapter)); ret = -EINVAL; goto out; } if (pwdev_priv->pmon_ndev) { - DBG_871X(FUNC_ADPT_FMT" monitor interface exist: %s\n", - FUNC_ADPT_ARG(padapter), NDEV_ARG(pwdev_priv->pmon_ndev)); ret = -EBUSY; goto out; } mon_ndev = alloc_etherdev(sizeof(struct rtw_netdev_priv_indicator)); if (!mon_ndev) { - DBG_871X(FUNC_ADPT_FMT" allocate ndev fail\n", FUNC_ADPT_ARG(padapter)); ret = -ENOMEM; goto out; } @@ -2544,7 +2450,6 @@ static int rtw_cfg80211_add_monitor_if(struct adapter *padapter, char *name, str /* wdev */ mon_wdev = rtw_zmalloc(sizeof(struct wireless_dev)); if (!mon_wdev) { - DBG_871X(FUNC_ADPT_FMT" allocate mon_wdev fail\n", FUNC_ADPT_ARG(padapter)); ret = -ENOMEM; goto out; } @@ -2587,9 +2492,6 @@ static struct wireless_dev * struct net_device *ndev = NULL; struct adapter *padapter = wiphy_to_adapter(wiphy); - DBG_871X(FUNC_ADPT_FMT " wiphy:%s, name:%s, type:%d\n", - FUNC_ADPT_ARG(padapter), wiphy_name(wiphy), name, type); - switch (type) { case NL80211_IFTYPE_ADHOC: case NL80211_IFTYPE_AP_VLAN: @@ -2610,12 +2512,9 @@ static struct wireless_dev * break; default: ret = -ENODEV; - DBG_871X("Unsupported interface type\n"); break; } - DBG_871X(FUNC_ADPT_FMT" ndev:%p, ret:%d\n", FUNC_ADPT_ARG(padapter), ndev, ret); - return ndev ? ndev->ieee80211_ptr : ERR_PTR(ret); } @@ -2641,7 +2540,6 @@ static int cfg80211_rtw_del_virtual_intf(struct wiphy *wiphy, if (ndev == pwdev_priv->pmon_ndev) { pwdev_priv->pmon_ndev = NULL; pwdev_priv->ifname_mon[0] = '\0'; - DBG_871X(FUNC_NDEV_FMT" remove monitor interface\n", FUNC_NDEV_ARG(ndev)); } exit: @@ -2698,9 +2596,6 @@ static int cfg80211_rtw_start_ap(struct wiphy *wiphy, struct net_device *ndev, int ret = 0; struct adapter *adapter = rtw_netdev_priv(ndev); - DBG_871X(FUNC_NDEV_FMT" hidden_ssid:%d, auth_type:%d\n", FUNC_NDEV_ARG(ndev), - settings->hidden_ssid, settings->auth_type); - ret = rtw_add_beacon(adapter, settings->beacon.head, settings->beacon.head_len, settings->beacon.tail, settings->beacon.tail_len); @@ -2724,14 +2619,11 @@ static int cfg80211_rtw_change_beacon(struct wiphy *wiphy, struct net_device *nd { struct adapter *adapter = rtw_netdev_priv(ndev); - DBG_871X(FUNC_NDEV_FMT"\n", FUNC_NDEV_ARG(ndev)); - return rtw_add_beacon(adapter, info->head, info->head_len, info->tail, info->tail_len); } static int cfg80211_rtw_stop_ap(struct wiphy *wiphy, struct net_device *ndev) { - DBG_871X(FUNC_NDEV_FMT"\n", FUNC_NDEV_ARG(ndev)); return 0; } @@ -2739,8 +2631,6 @@ static int cfg80211_rtw_add_station(struct wiphy *wiphy, struct net_device *ndev const u8 *mac, struct station_parameters *params) { - DBG_871X(FUNC_NDEV_FMT"\n", FUNC_NDEV_ARG(ndev)); - return 0; } @@ -2756,8 +2646,6 @@ static int cfg80211_rtw_del_station(struct wiphy *wiphy, struct net_device *ndev struct sta_priv *pstapriv = &padapter->stapriv; const u8 *mac = params->mac; - DBG_871X("+"FUNC_NDEV_FMT"\n", FUNC_NDEV_ARG(ndev)); - if (check_fwstate(pmlmepriv, (_FW_LINKED|WIFI_AP_STATE)) != true) { DBG_8192C("%s, fw_state != FW_LINKED|WIFI_AP_STATE\n", __func__); return -EINVAL; @@ -2819,8 +2707,6 @@ static int cfg80211_rtw_del_station(struct wiphy *wiphy, struct net_device *ndev associated_clients_update(padapter, updated); - DBG_871X("-"FUNC_NDEV_FMT"\n", FUNC_NDEV_ARG(ndev)); - return ret; } @@ -2828,8 +2714,6 @@ static int cfg80211_rtw_del_station(struct wiphy *wiphy, struct net_device *ndev static int cfg80211_rtw_change_station(struct wiphy *wiphy, struct net_device *ndev, const u8 *mac, struct station_parameters *params) { - DBG_871X(FUNC_NDEV_FMT"\n", FUNC_NDEV_ARG(ndev)); - return 0; } @@ -2861,13 +2745,11 @@ static int cfg80211_rtw_dump_station(struct wiphy *wiphy, struct net_device *nde struct adapter *padapter = rtw_netdev_priv(ndev); struct sta_info *psta = NULL; struct sta_priv *pstapriv = &padapter->stapriv; - DBG_871X(FUNC_NDEV_FMT"\n", FUNC_NDEV_ARG(ndev)); spin_lock_bh(&pstapriv->asoc_list_lock); psta = rtw_sta_info_get_by_idx(idx, pstapriv); spin_unlock_bh(&pstapriv->asoc_list_lock); if (NULL == psta) { - DBG_871X("Station is not found\n"); ret = -ENOENT; goto exit; } @@ -2882,7 +2764,6 @@ exit: static int cfg80211_rtw_change_bss(struct wiphy *wiphy, struct net_device *ndev, struct bss_parameters *params) { - DBG_871X(FUNC_NDEV_FMT"\n", FUNC_NDEV_ARG(ndev)); return 0; } @@ -2898,9 +2779,9 @@ void rtw_cfg80211_rx_action(struct adapter *adapter, u8 *frame, uint frame_len, DBG_8192C("RTW_Rx:cur_ch =%d\n", channel); if (msg) - DBG_871X("RTW_Rx:%s\n", msg); + {} else - DBG_871X("RTW_Rx:category(%u), action(%u)\n", category, action); + {} freq = rtw_ieee80211_channel_to_frequency(channel, NL80211_BAND_2GHZ); @@ -3013,10 +2894,6 @@ static int cfg80211_rtw_mgmt_tx(struct wiphy *wiphy, *cookie = (unsigned long) buf; #ifdef DEBUG_CFG80211 - DBG_871X(FUNC_ADPT_FMT" len =%zu, ch =%d" - "\n", FUNC_ADPT_ARG(padapter), - len, tx_ch - ); #endif /* DEBUG_CFG80211 */ /* indicate ack before issue frame to avoid racing with rsp frame */ @@ -3030,9 +2907,9 @@ static int cfg80211_rtw_mgmt_tx(struct wiphy *wiphy, DBG_8192C("RTW_Tx:tx_ch =%d, da =%pM\n", tx_ch, MAC_ARG(GetAddr1Ptr(buf))); if (category == RTW_WLAN_CATEGORY_PUBLIC) - DBG_871X("RTW_Tx:%s\n", action_public_str(action)); + {} else - DBG_871X("RTW_Tx:category(%u), action(%u)\n", category, action); + {} rtw_ps_deny(padapter, PS_DENY_MGNT_TX); if (_FAIL == rtw_pwr_wakeup(padapter)) { @@ -3046,8 +2923,6 @@ static int cfg80211_rtw_mgmt_tx(struct wiphy *wiphy, } while (dump_cnt < dump_limit && tx_ret != _SUCCESS); if (tx_ret != _SUCCESS || dump_cnt > 1) { - DBG_871X(FUNC_ADPT_FMT" %s (%d/%d)\n", FUNC_ADPT_ARG(padapter), - tx_ret == _SUCCESS?"OK":"FAIL", dump_cnt, dump_limit); } switch (type) { @@ -3056,8 +2931,6 @@ static int cfg80211_rtw_mgmt_tx(struct wiphy *wiphy, break; case P2P_INVIT_RESP: if (pwdev_priv->invit_info.flags & BIT(0) && pwdev_priv->invit_info.status == 0) { - DBG_871X(FUNC_ADPT_FMT" agree with invitation of persistent group\n", - FUNC_ADPT_ARG(padapter)); rtw_set_scan_deny(padapter, 5000); rtw_pwr_wakeup_ex(padapter, 5000); rtw_clear_scan_deny(padapter); |