rtl8188eu: Remove conditional #if 1

Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net>
This commit is contained in:
Larry Finger 2018-11-12 19:30:27 -06:00
parent f0050d3365
commit c25b5250a8
27 changed files with 2 additions and 373 deletions

View file

@ -1054,7 +1054,6 @@ bool rtw_hal_rfkill_poll(_adapter *adapter, u8 *valid)
u8 rtw_hal_ops_check(_adapter *padapter)
{
u8 ret = _SUCCESS;
#if 1
/*** initialize section ***/
if (NULL == padapter->hal_func.read_chip_version) {
rtw_hal_error_msg("read_chip_version");
@ -1235,9 +1234,6 @@ u8 rtw_hal_ops_check(_adapter *padapter)
ret = _FAIL;
}
#if defined(CONFIG_WOWLAN) || defined(CONFIG_AP_WOWLAN)
#endif /* CONFIG_WOWLAN */
if (NULL == padapter->hal_func.fw_dl) {
rtw_hal_error_msg("fw_dl");
ret = _FAIL;
@ -1296,7 +1292,6 @@ u8 rtw_hal_ops_check(_adapter *padapter)
rtw_hal_error_msg("hal_radio_onoff_check");
ret = _FAIL;
}
#endif
#endif
return ret;
}

View file

@ -1577,7 +1577,6 @@ static void _phy_ap_calibrate_8188e(
continue;
tmp_reg = APK_RF_init_value[path][index];
#if 1
if (!p_dm_odm->rf_calibrate_info.is_apk_thermal_meter_ignore) {
BB_offset = (tmp_reg & 0xF0000) >> 16;
@ -1597,8 +1596,6 @@ static void _phy_ap_calibrate_8188e(
tmp_reg = tmp_reg | BIT(15);
tmp_reg = (tmp_reg & 0xFFF0FFFF) | (BB_offset << 16);
}
#endif
odm_set_rf_reg(p_dm_odm, (enum odm_rf_radio_path_e)path, RF_IPA_A, MASKDWORD, 0x8992e);
ODM_RT_TRACE(p_dm_odm, ODM_COMP_CALIBRATION, ODM_DBG_LOUD, ("_phy_ap_calibrate_8188e() offset 0xc %x\n", phy_query_rf_reg(p_adapter, path, RF_IPA_A, MASKDWORD)));
odm_set_rf_reg(p_dm_odm, (enum odm_rf_radio_path_e)path, RF_AC, MASKDWORD, APK_RF_value_0[path][index]);

View file

@ -192,7 +192,6 @@ struct _odm_phy_dbg_info_ {
/*2011/20/20 MH For MP driver RT_WLAN_STA = struct sta_info*/
/*Please declare below ODM relative info in your STA info structure.*/
#if 1
struct _ODM_STA_INFO {
/*Driver Write*/
bool is_used; /*record the sta status link or not?*/
@ -206,7 +205,6 @@ struct _ODM_STA_INFO {
u8 RXSNR[4];
};
#endif
enum odm_cmninfo_e {
/*Fixed value*/

View file

@ -2873,11 +2873,7 @@ odm_process_rssi_for_ant_div(
pdm_sat_table->pkt_rssi_cnt[p_dm_fat_table->antsel_rx_keep_0][pdm_sat_table->fast_training_beam_num]++;
pdm_sat_table->pkt_counter++;
#if 1
train_pkt_number = pdm_sat_table->beam_train_cnt[p_dm_fat_table->rx_idle_ant - 1][pdm_sat_table->fast_training_beam_num];
#else
train_pkt_number = pdm_sat_table->per_beam_training_pkt_num;
#endif
/*Swich Antenna erery N pkts*/
if (pdm_sat_table->pkt_counter == train_pkt_number) {

View file

@ -110,33 +110,10 @@ phydm_dynamic_rx_path(
training_set_timmer_en = true;
} else if (p_dm_drp_table->drp_state == DRP_TRAINING_STATE_1) {
phydm_drp_get_statistic(p_dm_odm);
p_dm_drp_table->curr_cca_all_cnt_1 = false_alm_cnt->cnt_cca_all;
p_dm_drp_table->curr_fa_all_cnt_1 = false_alm_cnt->cnt_all;
#if 1
p_dm_drp_table->drp_state = DRP_DECISION_STATE;
#else
if (p_dm_odm->mp_mode) {
rx_ok_cal = p_dm_odm->phy_dbg_info.num_qry_phy_status_cck + p_dm_odm->phy_dbg_info.num_qry_phy_status_ofdm;
RSSI = (rx_ok_cal != 0) ? p_dm_odm->rx_pwdb_ave / rx_ok_cal : 0;
ODM_RT_TRACE(p_dm_odm, ODM_COMP_DYNAMIC_RX_PATH, ODM_DBG_LOUD, ("MP RSSI = ((%d))\n", RSSI));
}
if (RSSI > p_dm_drp_table->rssi_threshold)
p_dm_drp_table->drp_state = DRP_DECISION_STATE;
else {
p_dm_drp_table->drp_state = DRP_TRAINING_STATE_2;
p_dm_drp_table->curr_rx_path = PHYDM_A;
training_set_timmer_en = true;
}
#endif
} else if (p_dm_drp_table->drp_state == DRP_TRAINING_STATE_2) {
phydm_drp_get_statistic(p_dm_odm);

View file

@ -882,7 +882,6 @@ static s8 phydm_rssi_report(struct PHY_DM_STRUCT *p_dm_odm, u8 mac_id)
h2c_parameter[4] = (p_ra_table->RA_threshold_offset & 0x7f) | (p_ra_table->RA_offset_direction << 7);
ODM_RT_TRACE(p_dm_odm, ODM_COMP_RA_MASK, ODM_DBG_LOUD, ("RA_threshold_offset = (( %s%d ))\n", ((p_ra_table->RA_threshold_offset == 0) ? " " : ((p_ra_table->RA_offset_direction) ? "+" : "-")), p_ra_table->RA_threshold_offset));
#if 1
if (first_connect) {
ODM_RT_TRACE(p_dm_odm, ODM_COMP_RATE_ADAPTIVE, ODM_DBG_LOUD, ("%s mac_id:%u, mac:"MAC_FMT", rssi:%d\n", __func__,
p_entry->mac_id, MAC_ARG(p_entry->hwaddr), p_entry->rssi_stat.undecorated_smoothed_pwdb));
@ -891,16 +890,13 @@ static s8 phydm_rssi_report(struct PHY_DM_STRUCT *p_dm_odm, u8 mac_id)
(UL_DL_STATE) ? "DL" : "UL", (tx_bf_en) ? "EN" : "DIS", (STBC_TX) ? "EN" : "DIS",
(p_dm_odm->noisy_decision) ? "True" : "False", (first_connect) ? "True" : "False"));
}
#endif
if (p_hal_data->fw_ractrl == _TRUE) {
#if (RTL8188E_SUPPORT == 1)
if (p_dm_odm->support_ic_type == ODM_RTL8188E)
cmdlen = 3;
#endif
odm_fill_h2c_cmd(p_dm_odm, ODM_H2C_RSSI_REPORT, cmdlen, h2c_parameter);
} else {
#if ((RTL8188E_SUPPORT == 1) && (RATE_ADAPTIVE_SUPPORT == 1))
#if ((RATE_ADAPTIVE_SUPPORT == 1))
if (p_dm_odm->support_ic_type == ODM_RTL8188E)
odm_ra_set_rssi_8188e(p_dm_odm, (u8)(p_entry->mac_id & 0xFF), p_entry->rssi_stat.undecorated_smoothed_pwdb & 0x7F);
#endif

View file

@ -186,7 +186,6 @@ struct _odm_ra_info_ {
u8 ra_waiting_counter;
u8 ra_pending_counter;
u8 ra_drop_after_down;
#if 1 /* POWER_TRAINING_ACTIVE == 1 */ /* For compile pass only~! */
u8 pt_active; /* on or off */
u8 pt_try_state; /* 0 trying state, 1 for decision state */
u8 pt_stage; /* 0~6 */
@ -196,7 +195,6 @@ struct _odm_ra_info_ {
u8 pt_mode_ss; /* decide whitch rate should do PT */
u8 ra_stage; /* StageRA, decide how many times RA will be done between PT */
u8 pt_smooth_factor;
#endif
};
#endif

View file

@ -689,8 +689,6 @@ void rtl8188e_set_p2p_ps_offload_cmd(_adapter *padapter, u8 p2p_ps_state)
struct P2P_PS_Offload_t *p2p_ps_offload = (struct P2P_PS_Offload_t *)(&pHalData->p2p_ps_offload);
u8 i;
#if 1
switch (p2p_ps_state) {
case P2P_PS_DISABLE:
RTW_INFO("P2P_PS_DISABLE\n");
@ -756,9 +754,6 @@ void rtl8188e_set_p2p_ps_offload_cmd(_adapter *padapter, u8 p2p_ps_state)
}
FillH2CCmd_88E(padapter, H2C_PS_P2P_OFFLOAD, 1, (u8 *)p2p_ps_offload);
#endif
}
#endif /* CONFIG_P2P_PS */

View file

@ -2379,11 +2379,7 @@ static void read_chip_version_8188e(PADAPTER padapter)
pHalData->MultiFunc = RT_MULTI_FUNC_NONE;
rtw_hal_config_rftype(padapter);
#if 1
dump_chip_info(pHalData->version_id);
#endif
}
void rtl8188e_start_thread(_adapter *padapter)