From 454258d2e1177dcbae9c5b03086481415b6a736b Mon Sep 17 00:00:00 2001 From: Robert Schmidt Date: Wed, 12 Jul 2023 16:43:04 +0200 Subject: [PATCH] Remove unused preprocessor defines commit ddf549b1f38093dc127aef1ba46233bc7b9a668c moved the CMakeLists.txt for building radio libraries down to radio/. Previously, each option would also declare a constant (e.g., OAI_USRP for USRP). With the definition being below radio/, the executables don't have that define. This commits removes the couple of defines that were in place: - one that only shows a log, but it also applies for e.g., rfsimulator. It is also missing in the CI. Simply put it back - two other places guard a commented(!) function call, which can go out entirely --- .../PHY/NR_UE_TRANSPORT/nr_initial_sync.c | 35 +++---------------- openair1/SCHED_NR_UE/phy_procedures_nr_ue.c | 4 --- 2 files changed, 5 insertions(+), 34 deletions(-) diff --git a/openair1/PHY/NR_UE_TRANSPORT/nr_initial_sync.c b/openair1/PHY/NR_UE_TRANSPORT/nr_initial_sync.c index 5a475b84ae..c9549b523b 100644 --- a/openair1/PHY/NR_UE_TRANSPORT/nr_initial_sync.c +++ b/openair1/PHY/NR_UE_TRANSPORT/nr_initial_sync.c @@ -444,13 +444,11 @@ int nr_initial_sync(UE_nr_rxtx_proc_t *proc, } - -#if defined(OAI_USRP) || defined(OAI_BLADERF) || defined(OAI_LMSSDR) || defined(OAI_ADRV9371_ZC706) - LOG_I(PHY, "[UE %d] Measured Carrier Frequency %.0f Hz (offset %d Hz)\n", - ue->Mod_id, - openair0_cfg[0].rx_freq[0]+ue->common_vars.freq_offset, - ue->common_vars.freq_offset); -#endif + LOG_I(PHY, + "[UE %d] Measured Carrier Frequency %.0f Hz (offset %d Hz)\n", + ue->Mod_id, + openair0_cfg[0].rx_freq[0] + ue->common_vars.freq_offset, + ue->common_vars.freq_offset); } else { #ifdef DEBUG_INITIAL_SYNC LOG_I(PHY,"[UE%d] Initial sync : PBCH not ok\n",ue->Mod_id); @@ -486,29 +484,6 @@ int nr_initial_sync(UE_nr_rxtx_proc_t *proc, LOG_I(PHY,"[UE%d] Initial sync : Estimated power: %d dB\n",ue->Mod_id,ue->measurements.rx_power_avg_dB[0] ); #endif -#ifndef OAI_USRP -#ifndef OAI_BLADERF -#ifndef OAI_LMSSDR -#ifndef OAI_ADRV9371_ZC706 - //phy_adjust_gain(ue,ue->measurements.rx_power_avg_dB[0],0); -#endif -#endif -#endif -#endif - - } - else { - -#ifndef OAI_USRP -#ifndef OAI_BLADERF -#ifndef OAI_LMSSDR -#ifndef OAI_ADRV9371_ZC706 - //phy_adjust_gain(ue,dB_fixed(ue->measurements.rssi),0); -#endif -#endif -#endif -#endif - } if (ue->target_Nid_cell != -1) { diff --git a/openair1/SCHED_NR_UE/phy_procedures_nr_ue.c b/openair1/SCHED_NR_UE/phy_procedures_nr_ue.c index c903df6f6d..39ed35b3e7 100644 --- a/openair1/SCHED_NR_UE/phy_procedures_nr_ue.c +++ b/openair1/SCHED_NR_UE/phy_procedures_nr_ue.c @@ -75,10 +75,6 @@ fifo_dump_emos_UE emos_dump_UE; #include "intertask_interface.h" #include "T.h" -#if defined(OAI_USRP) || defined(OAI_BLADERF) || defined(OAI_LMSSDR) || defined(OAI_ADRV9371_ZC706) -extern uint64_t downlink_frequency[MAX_NUM_CCs][4]; -#endif - unsigned int gain_table[31] = {100,112,126,141,158,178,200,224,251,282,316,359,398,447,501,562,631,708,794,891,1000,1122,1258,1412,1585,1778,1995,2239,2512,2818,3162}; void nr_fill_dl_indication(nr_downlink_indication_t *dl_ind,