remove one global
This commit is contained in:
committed by
Robert Schmidt
parent
ed1c87b598
commit
42c1679545
@@ -404,7 +404,6 @@ int init_nr_ue_signal(PHY_VARS_NR_UE *ue, int nb_connected_gNB)
|
||||
ue->pdcch_vars[th_id][gNB_id]->llr = (int16_t *)malloc16_clear( 2*4*100*12*sizeof(uint16_t) );
|
||||
ue->pdcch_vars[th_id][gNB_id]->llr16 = (int16_t *)malloc16_clear( 2*4*100*12*sizeof(uint16_t) );
|
||||
ue->pdcch_vars[th_id][gNB_id]->wbar = (int16_t *)malloc16_clear( 2*4*100*12*sizeof(uint16_t) );
|
||||
ue->pdcch_vars[th_id][gNB_id]->e_rx = (int16_t *)malloc16_clear( 4*2*100*12 );
|
||||
ue->pdcch_vars[th_id][gNB_id]->rxdataF_comp = (int32_t **)malloc16_clear( 4*fp->nb_antennas_rx*sizeof(int32_t *) );
|
||||
ue->pdcch_vars[th_id][gNB_id]->dl_ch_rho_ext = (int32_t **)malloc16_clear( 4*fp->nb_antennas_rx*sizeof(int32_t *) );
|
||||
ue->pdcch_vars[th_id][gNB_id]->rho = (int32_t **)malloc16( fp->nb_antennas_rx*sizeof(int32_t *) );
|
||||
@@ -574,7 +573,6 @@ void term_nr_ue_signal(PHY_VARS_NR_UE *ue, int nb_connected_gNB)
|
||||
free_and_zero(ue->pdcch_vars[th_id][gNB_id]->llr);
|
||||
free_and_zero(ue->pdcch_vars[th_id][gNB_id]->llr16);
|
||||
free_and_zero(ue->pdcch_vars[th_id][gNB_id]->wbar);
|
||||
free_and_zero(ue->pdcch_vars[th_id][gNB_id]->e_rx);
|
||||
free_and_zero(ue->pdcch_vars[th_id][gNB_id]->rxdataF_comp);
|
||||
free_and_zero(ue->pdcch_vars[th_id][gNB_id]->dl_ch_rho_ext);
|
||||
free_and_zero(ue->pdcch_vars[th_id][gNB_id]->rho);
|
||||
|
||||
@@ -132,7 +132,8 @@ void nr_generate_dci(nfapi_nr_dl_tti_pdcch_pdu_rel15_t *pdcch_pdu_rel15,
|
||||
|
||||
polar_encoder_fast((uint64_t*)dci_pdu->Payload, (void*)encoder_output, n_RNTI, 1,
|
||||
NR_POLAR_DCI_MESSAGE_TYPE, dci_pdu->PayloadSizeBits, dci_pdu->AggregationLevel);
|
||||
#if 1
|
||||
#ifdef DEBUG_CHANNEL_CODING
|
||||
//debug dump dci
|
||||
printf("polar rnti %x,length %d, L %d\n",n_RNTI, dci_pdu->PayloadSizeBits,pdcch_pdu_rel15->dci_pdu->AggregationLevel);
|
||||
printf("DCI PDU: [0]->0x%lx \t [1]->0x%lx\n",
|
||||
((uint64_t*)dci_pdu->Payload)[0], ((uint64_t*)dci_pdu->Payload)[1]);
|
||||
|
||||
@@ -83,7 +83,7 @@ char nr_dci_format_string[8][30] = {
|
||||
//static const int16_t conjugate[8]__attribute__((aligned(32))) = {-1,1,-1,1,-1,1,-1,1};
|
||||
|
||||
|
||||
void nr_pdcch_demapping_deinterleaving(uint32_t *llr,
|
||||
static void nr_pdcch_demapping_deinterleaving(uint32_t *llr,
|
||||
uint32_t *z,
|
||||
uint8_t coreset_time_dur,
|
||||
uint8_t start_symbol,
|
||||
@@ -685,7 +685,8 @@ void nr_pdcch_detection_mrc(NR_DL_FRAME_PARMS *frame_parms,
|
||||
|
||||
int32_t nr_rx_pdcch(PHY_VARS_NR_UE *ue,
|
||||
UE_nr_rxtx_proc_t *proc,
|
||||
fapi_nr_dl_config_dci_dl_pdu_rel15_t *rel15) {
|
||||
fapi_nr_dl_config_dci_dl_pdu_rel15_t *rel15,
|
||||
int16_t e_rx[4*2*100*12] ) {
|
||||
|
||||
uint32_t frame = proc->frame_rx;
|
||||
uint32_t slot = proc->nr_slot_rx;
|
||||
@@ -772,7 +773,7 @@ int32_t nr_rx_pdcch(PHY_VARS_NR_UE *ue,
|
||||
|
||||
LOG_D(PHY,"we enter nr_pdcch_demapping_deinterleaving(), number of candidates %d\n",rel15->number_of_candidates);
|
||||
nr_pdcch_demapping_deinterleaving((uint32_t *) pdcch_vars->llr,
|
||||
(uint32_t *) pdcch_vars->e_rx,
|
||||
(uint32_t *) e_rx,
|
||||
rel15->coreset.duration,
|
||||
rel15->coreset.StartSymbolIndex,
|
||||
n_rb,
|
||||
@@ -791,7 +792,7 @@ int32_t nr_rx_pdcch(PHY_VARS_NR_UE *ue,
|
||||
|
||||
|
||||
|
||||
void nr_pdcch_unscrambling(int16_t *z,
|
||||
void nr_pdcch_unscrambling(int16_t e_rx[4*2*100*12],
|
||||
uint16_t scrambling_RNTI,
|
||||
uint32_t length,
|
||||
uint16_t pdcch_DMRS_scrambling_id,
|
||||
@@ -814,13 +815,15 @@ void nr_pdcch_unscrambling(int16_t *z,
|
||||
reset = 0;
|
||||
}
|
||||
|
||||
if (((s >> (i % 32)) & 1) == 1) z2[i] = -z[i];
|
||||
else z2[i]=z[i];
|
||||
if (((s >> (i % 32)) & 1) == 1)
|
||||
z2[i] = -e_rx[i];
|
||||
else
|
||||
z2[i]=e_rx[i];
|
||||
}
|
||||
printf("Encoded Payload (length:%d dwords):\n", length>>5);
|
||||
printf("Encoded Payload (length:%d dwords):\n", length);
|
||||
|
||||
for (int i=0; i<length>>5; i++)
|
||||
printf("[%d]->0x%08x \t", i, z2[i]);
|
||||
for (int i=0; i<length; i++)
|
||||
printf("[%d]->0x%x \t", i, z2[i]);
|
||||
}
|
||||
|
||||
|
||||
@@ -855,7 +858,8 @@ static uint16_t nr_dci_false_detection(uint64_t *dci,
|
||||
return x;
|
||||
}
|
||||
|
||||
uint8_t nr_dci_decoding_procedure(PHY_VARS_NR_UE *ue,
|
||||
uint8_t nr_dci_decoding_procedure(int16_t e_rx[4*2*100*12],
|
||||
PHY_VARS_NR_UE *ue,
|
||||
UE_nr_rxtx_proc_t *proc,
|
||||
fapi_nr_dci_indication_t *dci_ind,
|
||||
fapi_nr_dl_config_dci_dl_pdu_rel15_t *rel15) {
|
||||
@@ -891,10 +895,10 @@ uint8_t nr_dci_decoding_procedure(PHY_VARS_NR_UE *ue,
|
||||
LOG_D(PHY, "Trying DCI candidate %d of %d number of candidates, CCE %d (%d), L %d, length %d, format %s\n",
|
||||
j, rel15->number_of_candidates, CCEind, e_rx_cand_idx, L, dci_length,nr_dci_format_string[rel15->dci_format_options[k]]);
|
||||
|
||||
nr_pdcch_unscrambling(&pdcch_vars->e_rx[e_rx_cand_idx], rel15->coreset.scrambling_rnti, L*108, rel15->coreset.pdcch_dmrs_scrambling_id, tmp_e);
|
||||
nr_pdcch_unscrambling(&e_rx[e_rx_cand_idx], rel15->coreset.scrambling_rnti, L*108, rel15->coreset.pdcch_dmrs_scrambling_id, tmp_e);
|
||||
|
||||
#ifdef DEBUG_DCI_DECODING
|
||||
uint32_t *z = (uint32_t *) &pdcch_vars->e_rx[e_rx_cand_idx];
|
||||
uint32_t *z = (uint32_t *) &e_rx[e_rx_cand_idx];
|
||||
for (int index_z = 0; index_z < L*6; index_z++){
|
||||
for (int i=0; i<9; i++) {
|
||||
LOG_D(PHY,"z[%d]=(%d,%d) \n", (9*index_z + i), *(int16_t *) &z[index_z + i],*(1 + (int16_t *) &z[index_z + i]));
|
||||
|
||||
@@ -1105,8 +1105,8 @@ uint32_t dlsch_decoding_emul(PHY_VARS_NR_UE *phy_vars_ue,
|
||||
|
||||
int32_t nr_rx_pdcch(PHY_VARS_NR_UE *ue,
|
||||
UE_nr_rxtx_proc_t *proc,
|
||||
fapi_nr_dl_config_dci_dl_pdu_rel15_t *rel15);
|
||||
|
||||
fapi_nr_dl_config_dci_dl_pdu_rel15_t *rel15,
|
||||
int16_t e_rx[4*2*100*12]);
|
||||
|
||||
/*! \brief Extract PSS and SSS resource elements
|
||||
@param phy_vars_ue Pointer to UE variables
|
||||
@@ -1667,7 +1667,8 @@ uint8_t get_prach_prb_offset(NR_DL_FRAME_PARMS *frame_parms,
|
||||
|
||||
#include <openair1/PHY/LTE_TRANSPORT/transport_proto.h>
|
||||
|
||||
uint8_t nr_dci_decoding_procedure(PHY_VARS_NR_UE *ue,
|
||||
uint8_t nr_dci_decoding_procedure(int16_t e_rx[4*2*100*12],
|
||||
PHY_VARS_NR_UE *ue,
|
||||
UE_nr_rxtx_proc_t *proc,
|
||||
fapi_nr_dci_indication_t *dci_ind,
|
||||
fapi_nr_dl_config_dci_dl_pdu_rel15_t *rel15);
|
||||
|
||||
@@ -611,9 +611,6 @@ typedef struct {
|
||||
/// \brief \f$\overline{w}\f$ from 36-211.
|
||||
/// - first index: ? [0..48*N_RB_DL[
|
||||
int16_t *wbar;
|
||||
/// \brief PDCCH/DCI e-sequence (input to rate matching).
|
||||
/// - first index: ? [0..96*N_RB_DL[
|
||||
int16_t *e_rx;
|
||||
/// Total number of PDU errors (diagnostic mode)
|
||||
uint32_t dci_errors;
|
||||
/// Total number of PDU received
|
||||
|
||||
@@ -500,7 +500,8 @@ int nr_ue_pdcch_procedures(uint8_t gNB_id,
|
||||
start_meas(&ue->dlsch_rx_pdcch_stats);
|
||||
|
||||
VCD_SIGNAL_DUMPER_DUMP_FUNCTION_BY_NAME(VCD_SIGNAL_DUMPER_FUNCTIONS_RX_PDCCH, VCD_FUNCTION_IN);
|
||||
nr_rx_pdcch(ue, proc, rel15);
|
||||
int16_t e_rx[4*2*100*12]={0};
|
||||
nr_rx_pdcch(ue, proc, rel15, e_rx);
|
||||
VCD_SIGNAL_DUMPER_DUMP_FUNCTION_BY_NAME(VCD_SIGNAL_DUMPER_FUNCTIONS_RX_PDCCH, VCD_FUNCTION_OUT);
|
||||
|
||||
|
||||
@@ -511,7 +512,7 @@ int nr_ue_pdcch_procedures(uint8_t gNB_id,
|
||||
n_ss);
|
||||
#endif
|
||||
|
||||
dci_cnt = nr_dci_decoding_procedure(ue, proc, dci_ind, rel15);
|
||||
dci_cnt = nr_dci_decoding_procedure(e_rx, ue, proc, dci_ind, rel15);
|
||||
|
||||
#ifdef NR_PDCCH_SCHED_DEBUG
|
||||
LOG_I(PHY,"<-NR_PDCCH_PHY_PROCEDURES_LTE_UE (nr_ue_pdcch_procedures)-> Ending function nr_dci_decoding_procedure() -> dci_cnt=%u\n",dci_cnt);
|
||||
|
||||
Reference in New Issue
Block a user