Merge remote-tracking branch 'origin/more_static_cleanup' into integration_2026_w02 (!3828)
L2 UE files code cleanup for static functions No functional change, just re-arranging code
This commit is contained in:
@@ -38,7 +38,7 @@
|
|||||||
#include "executables/softmodem-common.h"
|
#include "executables/softmodem-common.h"
|
||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
|
|
||||||
void fill_dci_search_candidates(const NR_SearchSpace_t *ss, fapi_nr_dl_config_dci_dl_pdu_rel15_t *rel15, const uint32_t Y)
|
static void fill_dci_search_candidates(const NR_SearchSpace_t *ss, fapi_nr_dl_config_dci_dl_pdu_rel15_t *rel15, const uint32_t Y)
|
||||||
{
|
{
|
||||||
LOG_T(NR_MAC_DCI, "Filling search candidates for DCI\n");
|
LOG_T(NR_MAC_DCI, "Filling search candidates for DCI\n");
|
||||||
|
|
||||||
@@ -89,7 +89,7 @@ void fill_dci_search_candidates(const NR_SearchSpace_t *ss, fapi_nr_dl_config_dc
|
|||||||
rel15->number_of_candidates = i;
|
rel15->number_of_candidates = i;
|
||||||
}
|
}
|
||||||
|
|
||||||
NR_ControlResourceSet_t *ue_get_coreset(const NR_BWP_PDCCH_t *config, const int coreset_id)
|
static NR_ControlResourceSet_t *ue_get_coreset(const NR_BWP_PDCCH_t *config, const int coreset_id)
|
||||||
{
|
{
|
||||||
if (config->commonControlResourceSet && coreset_id == config->commonControlResourceSet->controlResourceSetId)
|
if (config->commonControlResourceSet && coreset_id == config->commonControlResourceSet->controlResourceSetId)
|
||||||
return config->commonControlResourceSet;
|
return config->commonControlResourceSet;
|
||||||
@@ -362,12 +362,12 @@ bool is_ss_monitor_occasion(const int frame, const int slot, const int slots_per
|
|||||||
return monitor;
|
return monitor;
|
||||||
}
|
}
|
||||||
|
|
||||||
bool search_space_monitoring_ocasion_other_si(NR_UE_MAC_INST_t *mac,
|
static bool search_space_monitoring_ocasion_other_si(NR_UE_MAC_INST_t *mac,
|
||||||
const NR_SearchSpace_t *ss,
|
const NR_SearchSpace_t *ss,
|
||||||
const int abs_slot,
|
const int abs_slot,
|
||||||
const int frame,
|
const int frame,
|
||||||
const int slot,
|
const int slot,
|
||||||
const int slots_per_frame)
|
const int slots_per_frame)
|
||||||
{
|
{
|
||||||
const int duration = ss->duration ? *ss->duration : 1;
|
const int duration = ss->duration ? *ss->duration : 1;
|
||||||
int period, offset;
|
int period, offset;
|
||||||
|
|||||||
@@ -58,13 +58,6 @@ static const int nb_symbols_excluding_dmrs[11][2][2]
|
|||||||
/* 14 */ {{ 12 , 12 } , { 10 , 10 }},
|
/* 14 */ {{ 12 , 12 } , { 10 , 10 }},
|
||||||
};
|
};
|
||||||
|
|
||||||
static int get_deltatf(uint16_t nb_of_prbs,
|
|
||||||
uint8_t N_symb_PUCCH,
|
|
||||||
uint8_t freq_hop_flag,
|
|
||||||
uint8_t add_dmrs_flag,
|
|
||||||
int N_sc_ctrl_RB,
|
|
||||||
int O_UCI);
|
|
||||||
|
|
||||||
// ∆MPR according to Table 6.2.2-3 38.101-1
|
// ∆MPR according to Table 6.2.2-3 38.101-1
|
||||||
static float get_delta_mpr(uint16_t nr_band, frame_type_t frame_type, int scs, int channel_bandwidth, int n_prbs, int start_prb, int power_class)
|
static float get_delta_mpr(uint16_t nr_band, frame_type_t frame_type, int scs, int channel_bandwidth, int n_prbs, int start_prb, int power_class)
|
||||||
{
|
{
|
||||||
@@ -256,6 +249,28 @@ int get_sum_delta_pucch(NR_UE_MAC_INST_t *mac, int slot, frame_t frame)
|
|||||||
return delta_tpc_sum;
|
return delta_tpc_sum;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
static int get_deltatf(uint16_t nb_of_prbs,
|
||||||
|
uint8_t N_symb_PUCCH,
|
||||||
|
uint8_t freq_hop_flag,
|
||||||
|
uint8_t add_dmrs_flag,
|
||||||
|
int N_sc_ctrl_RB,
|
||||||
|
int O_UCI)
|
||||||
|
{
|
||||||
|
int DELTA_TF;
|
||||||
|
int O_CRC = compute_pucch_crc_size(O_UCI);
|
||||||
|
int N_symb = N_symb_PUCCH < 4 ? N_symb_PUCCH : nb_symbols_excluding_dmrs[N_symb_PUCCH - 4][add_dmrs_flag][freq_hop_flag];
|
||||||
|
float N_RE = nb_of_prbs * N_sc_ctrl_RB * N_symb;
|
||||||
|
float K1 = 6;
|
||||||
|
if (O_UCI + O_CRC < 12)
|
||||||
|
DELTA_TF = 10 * log10((double)(((K1 * (O_UCI)) / N_RE)));
|
||||||
|
else {
|
||||||
|
float K2 = 2.4;
|
||||||
|
float BPRE = (O_UCI + O_CRC) / N_RE;
|
||||||
|
DELTA_TF = 10 * log10((double)(pow(2, (K2 * BPRE)) - 1));
|
||||||
|
}
|
||||||
|
return DELTA_TF;
|
||||||
|
}
|
||||||
|
|
||||||
// PUCCH Power control according to 38.213 section 7.2.1
|
// PUCCH Power control according to 38.213 section 7.2.1
|
||||||
int16_t get_pucch_tx_power_ue(NR_UE_MAC_INST_t *mac,
|
int16_t get_pucch_tx_power_ue(NR_UE_MAC_INST_t *mac,
|
||||||
int scs,
|
int scs,
|
||||||
@@ -399,28 +414,6 @@ int16_t get_pucch_tx_power_ue(NR_UE_MAC_INST_t *mac,
|
|||||||
return pucch_power;
|
return pucch_power;
|
||||||
}
|
}
|
||||||
|
|
||||||
static int get_deltatf(uint16_t nb_of_prbs,
|
|
||||||
uint8_t N_symb_PUCCH,
|
|
||||||
uint8_t freq_hop_flag,
|
|
||||||
uint8_t add_dmrs_flag,
|
|
||||||
int N_sc_ctrl_RB,
|
|
||||||
int O_UCI)
|
|
||||||
{
|
|
||||||
int DELTA_TF;
|
|
||||||
int O_CRC = compute_pucch_crc_size(O_UCI);
|
|
||||||
int N_symb = N_symb_PUCCH < 4 ? N_symb_PUCCH : nb_symbols_excluding_dmrs[N_symb_PUCCH - 4][add_dmrs_flag][freq_hop_flag];
|
|
||||||
float N_RE = nb_of_prbs * N_sc_ctrl_RB * N_symb;
|
|
||||||
float K1 = 6;
|
|
||||||
if (O_UCI + O_CRC < 12)
|
|
||||||
DELTA_TF = 10 * log10((double)(((K1 * (O_UCI)) / N_RE)));
|
|
||||||
else {
|
|
||||||
float K2 = 2.4;
|
|
||||||
float BPRE = (O_UCI + O_CRC) / N_RE;
|
|
||||||
DELTA_TF = 10 * log10((double)(pow(2, (K2 * BPRE)) - 1));
|
|
||||||
}
|
|
||||||
return DELTA_TF;
|
|
||||||
}
|
|
||||||
|
|
||||||
// Returns the pathloss in dB for the active UL BWP on the selected carrier based on the DL RS associated with the PRACH transmission
|
// Returns the pathloss in dB for the active UL BWP on the selected carrier based on the DL RS associated with the PRACH transmission
|
||||||
// computation according to clause 7.4 (Physical random access channel) of 3GPP TS 38.213 version 16.3.0 Release 16
|
// computation according to clause 7.4 (Physical random access channel) of 3GPP TS 38.213 version 16.3.0 Release 16
|
||||||
// Assumptions:
|
// Assumptions:
|
||||||
|
|||||||
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
Reference in New Issue
Block a user