mirror of
https://github.com/lwfinger/rtl8188eu.git
synced 2025-06-23 08:34:20 +00:00
rtl8188eu: Remove dead code inside #if 0
Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net>
This commit is contained in:
parent
2d60bad9ad
commit
b6b121512b
56 changed files with 121 additions and 6115 deletions
|
@ -407,45 +407,10 @@ struct cfg80211_bss *rtw_cfg80211_inform_bss(struct adapter *padapter, struct wl
|
|||
if(psr !=NULL)
|
||||
*psr = 0; //clear sr
|
||||
|
||||
#if 0
|
||||
WLAN_BSSID_EX *pselect_network = &pnetwork->network;
|
||||
struct cfg80211_bss *pselect_bss = NULL;
|
||||
struct ieee80211_channel *notify_channel = NULL;
|
||||
u32 freq;
|
||||
|
||||
DBG_871X("%s, got sr, but ssid mismatch, to remove this bss\n", __func__);
|
||||
|
||||
if (pselect_network->Configuration.DSConfig <= RTW_CH_MAX_2G_CHANNEL)
|
||||
freq = rtw_ieee80211_channel_to_frequency(pselect_network->Configuration.DSConfig, IEEE80211_BAND_2GHZ);
|
||||
else
|
||||
freq = rtw_ieee80211_channel_to_frequency(pselect_network->Configuration.DSConfig, IEEE80211_BAND_5GHZ);
|
||||
|
||||
notify_channel = ieee80211_get_channel(wiphy, freq);
|
||||
pselect_bss = cfg80211_get_bss(wiphy, NULL/*notify_channel*/,
|
||||
pselect_network->MacAddress, pselect_network->Ssid.Ssid,
|
||||
pselect_network->Ssid.SsidLength, 0/*WLAN_CAPABILITY_ESS*/,
|
||||
0/*WLAN_CAPABILITY_ESS*/);
|
||||
|
||||
if(pselect_bss)
|
||||
{
|
||||
DBG_871X("%s, got bss for cfg80211 for unlinking bss\n", __func__);
|
||||
|
||||
cfg80211_unlink_bss(wiphy, pselect_bss);
|
||||
#if LINUX_VERSION_CODE >= KERNEL_VERSION(3, 9, 0)
|
||||
cfg80211_put_bss(wiphy, pselect_bss);
|
||||
#else
|
||||
cfg80211_put_bss(pselect_bss);
|
||||
#endif
|
||||
|
||||
}
|
||||
|
||||
goto exit;
|
||||
#endif
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
//_exit_critical_bh(&pwdev_priv->scan_req_lock, &irqL);
|
||||
|
||||
channel = pnetwork->network.Configuration.DSConfig;
|
||||
if (channel <= RTW_CH_MAX_2G_CHANNEL)
|
||||
|
@ -455,7 +420,6 @@ struct cfg80211_bss *rtw_cfg80211_inform_bss(struct adapter *padapter, struct wl
|
|||
|
||||
notify_channel = ieee80211_get_channel(wiphy, freq);
|
||||
|
||||
//rtw_get_timestampe_from_ie()
|
||||
notify_timestamp = jiffies_to_msecs(jiffies)*1000; /* uSec */
|
||||
|
||||
notify_interval = le16_to_cpu(*(u16*)rtw_get_beacon_interval_from_ie(pnetwork->network.IEs));
|
||||
|
@ -472,16 +436,6 @@ struct cfg80211_bss *rtw_cfg80211_inform_bss(struct adapter *padapter, struct wl
|
|||
} else {
|
||||
notify_signal = 100*translate_percentage_to_dbm(pnetwork->network.PhyInfo.SignalStrength);//dbm
|
||||
}
|
||||
|
||||
#if 0
|
||||
DBG_8192C("bssid: "MAC_FMT"\n", MAC_ARG(pnetwork->network.MacAddress));
|
||||
DBG_8192C("Channel: %d(%d)\n", channel, freq);
|
||||
DBG_8192C("Capability: %X\n", notify_capability);
|
||||
DBG_8192C("Beacon interval: %d\n", notify_interval);
|
||||
DBG_8192C("Signal: %d\n", notify_signal);
|
||||
DBG_8192C("notify_timestamp: %#018llx\n", notify_timestamp);
|
||||
#endif
|
||||
|
||||
pbuf = buf;
|
||||
|
||||
pwlanhdr = (struct rtw_ieee80211_hdr *)pbuf;
|
||||
|
@ -1678,25 +1632,6 @@ static int cfg80211_rtw_get_key(struct wiphy *wiphy, struct net_device *ndev,
|
|||
void (*callback)(void *cookie,
|
||||
struct key_params*))
|
||||
{
|
||||
#if 0
|
||||
struct iwm_priv *iwm = ndev_to_iwm(ndev);
|
||||
struct iwm_key *key = &iwm->keys[key_index];
|
||||
struct key_params params;
|
||||
|
||||
IWM_DBG_WEXT(iwm, DBG, "Getting key %d\n", key_index);
|
||||
|
||||
memset(¶ms, 0, sizeof(params));
|
||||
|
||||
params.cipher = key->cipher;
|
||||
params.key_len = key->key_len;
|
||||
params.seq_len = key->seq_len;
|
||||
params.seq = key->seq;
|
||||
params.key = key->key;
|
||||
|
||||
callback(cookie, ¶ms);
|
||||
|
||||
return key->key_len ? 0 : -ENOENT;
|
||||
#endif
|
||||
DBG_871X(FUNC_NDEV_FMT"\n", FUNC_NDEV_ARG(ndev));
|
||||
return 0;
|
||||
}
|
||||
|
@ -2413,35 +2348,6 @@ exit:
|
|||
|
||||
static int cfg80211_rtw_set_wiphy_params(struct wiphy *wiphy, u32 changed)
|
||||
{
|
||||
#if 0
|
||||
struct iwm_priv *iwm = wiphy_to_iwm(wiphy);
|
||||
|
||||
if (changed & WIPHY_PARAM_RTS_THRESHOLD &&
|
||||
(iwm->conf.rts_threshold != wiphy->rts_threshold)) {
|
||||
int ret;
|
||||
|
||||
iwm->conf.rts_threshold = wiphy->rts_threshold;
|
||||
|
||||
ret = iwm_umac_set_config_fix(iwm, UMAC_PARAM_TBL_CFG_FIX,
|
||||
CFG_RTS_THRESHOLD,
|
||||
iwm->conf.rts_threshold);
|
||||
if (ret < 0)
|
||||
return ret;
|
||||
}
|
||||
|
||||
if (changed & WIPHY_PARAM_FRAG_THRESHOLD &&
|
||||
(iwm->conf.frag_threshold != wiphy->frag_threshold)) {
|
||||
int ret;
|
||||
|
||||
iwm->conf.frag_threshold = wiphy->frag_threshold;
|
||||
|
||||
ret = iwm_umac_set_config_fix(iwm, UMAC_PARAM_TBL_FA_CFG_FIX,
|
||||
CFG_FRAG_THRESHOLD,
|
||||
iwm->conf.frag_threshold);
|
||||
if (ret < 0)
|
||||
return ret;
|
||||
}
|
||||
#endif
|
||||
DBG_8192C("%s\n", __func__);
|
||||
return 0;
|
||||
}
|
||||
|
@ -2902,12 +2808,6 @@ exit:
|
|||
|
||||
static int cfg80211_rtw_leave_ibss(struct wiphy *wiphy, struct net_device *ndev)
|
||||
{
|
||||
#if 0
|
||||
struct iwm_priv *iwm = wiphy_to_iwm(wiphy);
|
||||
|
||||
if (iwm->umac_profile_active)
|
||||
return iwm_invalidate_mlme_profile(iwm);
|
||||
#endif
|
||||
DBG_871X(FUNC_NDEV_FMT"\n", FUNC_NDEV_ARG(ndev));
|
||||
return 0;
|
||||
}
|
||||
|
@ -3201,32 +3101,6 @@ static int cfg80211_rtw_set_txpower(struct wiphy *wiphy,
|
|||
enum tx_power_setting type, int dbm)
|
||||
#endif
|
||||
{
|
||||
#if 0
|
||||
struct iwm_priv *iwm = wiphy_to_iwm(wiphy);
|
||||
int ret;
|
||||
|
||||
switch (type) {
|
||||
case NL80211_TX_POWER_AUTOMATIC:
|
||||
return 0;
|
||||
case NL80211_TX_POWER_FIXED:
|
||||
if (mbm < 0 || (mbm % 100))
|
||||
return -EOPNOTSUPP;
|
||||
|
||||
if (!test_bit(IWM_STATUS_READY, &iwm->status))
|
||||
return 0;
|
||||
|
||||
ret = iwm_umac_set_config_fix(iwm, UMAC_PARAM_TBL_CFG_FIX,
|
||||
CFG_TX_PWR_LIMIT_USR,
|
||||
MBM_TO_DBM(mbm) * 2);
|
||||
if (ret < 0)
|
||||
return ret;
|
||||
|
||||
return iwm_tx_power_trigger(iwm);
|
||||
default:
|
||||
IWM_ERR(iwm, "Unsupported power type: %d\n", type);
|
||||
return -EOPNOTSUPP;
|
||||
}
|
||||
#endif
|
||||
DBG_8192C("%s\n", __func__);
|
||||
return 0;
|
||||
}
|
||||
|
@ -3237,8 +3111,6 @@ static int cfg80211_rtw_get_txpower(struct wiphy *wiphy,
|
|||
#endif
|
||||
int *dbm)
|
||||
{
|
||||
//struct adapter *padapter = wiphy_to_adapter(wiphy);
|
||||
|
||||
DBG_8192C("%s\n", __func__);
|
||||
|
||||
*dbm = (12);
|
||||
|
@ -4749,18 +4621,6 @@ static s32 cfg80211_rtw_cancel_remain_on_channel(struct wiphy *wiphy,
|
|||
p2p_protocol_wk_hdl(padapter, P2P_RO_CH_WK);
|
||||
}
|
||||
|
||||
#if 0
|
||||
// Disable P2P Listen State
|
||||
if(!rtw_p2p_chk_role(pwdinfo, P2P_ROLE_CLIENT) && !rtw_p2p_chk_role(pwdinfo, P2P_ROLE_GO))
|
||||
{
|
||||
if(!rtw_p2p_chk_state(pwdinfo, P2P_STATE_NONE))
|
||||
{
|
||||
rtw_p2p_set_state(pwdinfo, P2P_STATE_NONE);
|
||||
_rtw_memset(pwdinfo, 0x00, sizeof(struct wifidirect_info));
|
||||
}
|
||||
}
|
||||
else
|
||||
#endif
|
||||
{
|
||||
rtw_p2p_set_state(pwdinfo, rtw_p2p_pre_state(pwdinfo));
|
||||
#ifdef CONFIG_DEBUG_CFG80211
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue