Commit c45140bc authored by Michael Straube's avatar Michael Straube Committed by Greg Kroah-Hartman

staging: rtl8723bs: remove dead code, rtw_port_switch_chk()

The function rtw_port_switch_chk() returns always false.
Remove the function and related dead code.
Signed-off-by: default avatarMichael Straube <straube.linux@gmail.com>
Acked-by: default avatarHans de Goede <hdegoede@redhat.com>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent 15f11e0f
...@@ -5334,13 +5334,6 @@ void report_add_sta_event(struct adapter *padapter, unsigned char *MacAddr, int ...@@ -5334,13 +5334,6 @@ void report_add_sta_event(struct adapter *padapter, unsigned char *MacAddr, int
return; return;
} }
bool rtw_port_switch_chk(struct adapter *adapter)
{
bool switch_needed = false;
return switch_needed;
}
/**************************************************************************** /****************************************************************************
Following are the event callback functions Following are the event callback functions
...@@ -5414,7 +5407,6 @@ static void rtw_mlmeext_disconnect(struct adapter *padapter) ...@@ -5414,7 +5407,6 @@ static void rtw_mlmeext_disconnect(struct adapter *padapter)
struct mlme_ext_priv *pmlmeext = &padapter->mlmeextpriv; struct mlme_ext_priv *pmlmeext = &padapter->mlmeextpriv;
struct mlme_ext_info *pmlmeinfo = &(pmlmeext->mlmext_info); struct mlme_ext_info *pmlmeinfo = &(pmlmeext->mlmext_info);
struct wlan_bssid_ex *pnetwork = (struct wlan_bssid_ex *)(&(pmlmeinfo->network)); struct wlan_bssid_ex *pnetwork = (struct wlan_bssid_ex *)(&(pmlmeinfo->network));
u8 state_backup = (pmlmeinfo->state&0x03);
/* set_opmode_cmd(padapter, infra_client_with_mlme); */ /* set_opmode_cmd(padapter, infra_client_with_mlme); */
...@@ -5440,17 +5432,6 @@ static void rtw_mlmeext_disconnect(struct adapter *padapter) ...@@ -5440,17 +5432,6 @@ static void rtw_mlmeext_disconnect(struct adapter *padapter)
pmlmeinfo->state = WIFI_FW_NULL_STATE; pmlmeinfo->state = WIFI_FW_NULL_STATE;
if (state_backup == WIFI_FW_STATION_STATE) {
if (rtw_port_switch_chk(padapter)) {
rtw_hal_set_hwreg(padapter, HW_VAR_PORT_SWITCH, NULL);
{
struct adapter *port0_iface = dvobj_get_port0_adapter(adapter_to_dvobj(padapter));
if (port0_iface)
rtw_lps_ctrl_wk_cmd(port0_iface, LPS_CTRL_CONNECT, 0);
}
}
}
/* switch to the 20M Hz mode after disconnect */ /* switch to the 20M Hz mode after disconnect */
pmlmeext->cur_bwmode = CHANNEL_WIDTH_20; pmlmeext->cur_bwmode = CHANNEL_WIDTH_20;
pmlmeext->cur_ch_offset = HAL_PRIME_CHNL_OFFSET_DONT_CARE; pmlmeext->cur_ch_offset = HAL_PRIME_CHNL_OFFSET_DONT_CARE;
...@@ -5530,9 +5511,6 @@ void mlmeext_joinbss_event_callback(struct adapter *padapter, int join_res) ...@@ -5530,9 +5511,6 @@ void mlmeext_joinbss_event_callback(struct adapter *padapter, int join_res)
rtw_hal_macid_wakeup(padapter, psta->mac_id); rtw_hal_macid_wakeup(padapter, psta->mac_id);
} }
if (rtw_port_switch_chk(padapter))
rtw_hal_set_hwreg(padapter, HW_VAR_PORT_SWITCH, NULL);
join_type = 2; join_type = 2;
rtw_hal_set_hwreg(padapter, HW_VAR_MLME_JOIN, (u8 *)(&join_type)); rtw_hal_set_hwreg(padapter, HW_VAR_MLME_JOIN, (u8 *)(&join_type));
...@@ -6087,18 +6065,6 @@ u8 setopmode_hdl(struct adapter *padapter, u8 *pbuf) ...@@ -6087,18 +6065,6 @@ u8 setopmode_hdl(struct adapter *padapter, u8 *pbuf)
rtw_auto_ap_start_beacon(padapter); rtw_auto_ap_start_beacon(padapter);
#endif #endif
if (rtw_port_switch_chk(padapter)) {
rtw_hal_set_hwreg(padapter, HW_VAR_PORT_SWITCH, NULL);
if (psetop->mode == Ndis802_11APMode)
adapter_to_pwrctl(padapter)->fw_psmode_iface_id = 0xff; /* ap mode won't dowload rsvd pages */
else if (psetop->mode == Ndis802_11Infrastructure) {
struct adapter *port0_iface = dvobj_get_port0_adapter(adapter_to_dvobj(padapter));
if (port0_iface)
rtw_lps_ctrl_wk_cmd(port0_iface, LPS_CTRL_CONNECT, 0);
}
}
if (psetop->mode == Ndis802_11APMode) { if (psetop->mode == Ndis802_11APMode) {
/* Do this after port switch to */ /* Do this after port switch to */
/* prevent from downloading rsvd page to wrong port */ /* prevent from downloading rsvd page to wrong port */
......
...@@ -648,7 +648,6 @@ void report_survey_event(struct adapter *padapter, union recv_frame *precv_frame ...@@ -648,7 +648,6 @@ void report_survey_event(struct adapter *padapter, union recv_frame *precv_frame
void report_surveydone_event(struct adapter *padapter); void report_surveydone_event(struct adapter *padapter);
void report_del_sta_event(struct adapter *padapter, unsigned char* MacAddr, unsigned short reason); void report_del_sta_event(struct adapter *padapter, unsigned char* MacAddr, unsigned short reason);
void report_add_sta_event(struct adapter *padapter, unsigned char* MacAddr, int cam_idx); void report_add_sta_event(struct adapter *padapter, unsigned char* MacAddr, int cam_idx);
bool rtw_port_switch_chk(struct adapter *adapter);
void report_wmm_edca_update(struct adapter *padapter); void report_wmm_edca_update(struct adapter *padapter);
void beacon_timing_control(struct adapter *padapter); void beacon_timing_control(struct adapter *padapter);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment