fixing most warning when compiling nr-softmodem
This commit is contained in:
@@ -59,7 +59,6 @@ int lte_segmentation(unsigned char *input_buffer,
|
||||
}
|
||||
|
||||
if ((*C)>MAX_NUM_DLSCH_SEGMENTS) {
|
||||
printf("%d\n",*(int *)0);
|
||||
LOG_E(PHY,"lte_segmentation.c: too many segments %d, B %d, L %d, Bprime %d\n",*C,B,L,Bprime);
|
||||
return(-1);
|
||||
}
|
||||
|
||||
@@ -1963,7 +1963,7 @@ void fill_dci0(PHY_VARS_eNB *eNB,int frame,int subframe,L1_rxtx_proc_t *proc,
|
||||
if(frame_parms->frame_type == TDD) {
|
||||
UE_id = find_ulsch(pdu->dci_pdu_rel8.rnti, eNB,SEARCH_EXIST_OR_FREE);
|
||||
|
||||
if(UE_id >=0 -1 || UE_id < NUMBER_OF_ULSCH_MAX) {
|
||||
if(UE_id >=0 || UE_id < NUMBER_OF_ULSCH_MAX) {
|
||||
eNB->ulsch[UE_id]->harq_processes[pdu->dci_pdu_rel8.harq_pid]->V_UL_DAI = dai +1;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -13,7 +13,6 @@ extern "C" {
|
||||
double samplerate = 30.72e6*ratio;
|
||||
double ofdm_size = 2048*ratio;
|
||||
double PI = std::acos(-1);
|
||||
std::complex<int> tt;
|
||||
complex<double> t[len];
|
||||
int index=0;
|
||||
double cp0 = 160*ratio;
|
||||
|
||||
@@ -322,8 +322,6 @@ void rx_nr_prach_ru(RU_t *ru,
|
||||
|
||||
case 30720:
|
||||
// 20, 25, 30 MHz @ 30.72 Ms/s
|
||||
Ncp = Ncp;
|
||||
dftlen = dftlen;
|
||||
break;
|
||||
|
||||
case 46080:
|
||||
@@ -354,7 +352,7 @@ void rx_nr_prach_ru(RU_t *ru,
|
||||
AssertFatal(1==0,"sample rate %f MHz not supported for numerology %d\n", fp->samples_per_subframe / 1000.0, mu);
|
||||
}
|
||||
|
||||
const idft_size_idx_t dftsize = get_dft(dftlen);
|
||||
const dft_size_idx_t dftsize = get_dft(dftlen);
|
||||
|
||||
// Do forward transform
|
||||
if (LOG_DEBUGFLAG(PRACH)) {
|
||||
|
||||
@@ -592,9 +592,9 @@ uint32_t nr_ulsch_decoding(PHY_VARS_gNB *phy_vars_gNB,
|
||||
|
||||
VCD_SIGNAL_DUMPER_DUMP_FUNCTION_BY_NAME(VCD_SIGNAL_DUMPER_FUNCTIONS_PHY_gNB_ULSCH_DECODING, 0);
|
||||
|
||||
if ((harq_process->processedSegments == (harq_process->C))) {
|
||||
if (harq_process->processedSegments == (harq_process->C)) {
|
||||
LOG_D(PHY, "[gNB %d] ULSCH: Setting ACK for slot %d TBS %d\n", phy_vars_gNB->Mod_id, harq_process->slot, harq_process->TBS);
|
||||
harq_process->status = SCH_IDLE;
|
||||
harq_process->status = NR_SCH_IDLE;
|
||||
harq_process->round = 0;
|
||||
ulsch->harq_mask &= ~(1 << harq_pid);
|
||||
|
||||
|
||||
@@ -1371,7 +1371,7 @@ __m128i nr_ulsch_comp_muli_sum(__m128i input_x,
|
||||
//divide by matrix det and convert back to Q15 before packing
|
||||
int sum_det =0;
|
||||
for (int k=0; k<4;k++) {
|
||||
sum_det += ((((int *)&det[0])[k])>>2);
|
||||
sum_det += ((((int *)&det)[k])>>2);
|
||||
//printf("det_%d = %d log2 =%d \n",k,(((int *)&det[0])[k]),log2_approx(((int *)&det[0])[k]));
|
||||
}
|
||||
|
||||
|
||||
@@ -860,7 +860,7 @@ void schedule_response(Sched_Rsp_t *Sched_INFO, void *arg) {
|
||||
// handle_nfapi_mch_dl_pdu(eNB,dl_config_pdu);
|
||||
//AssertFatal(1==0,"OK\n");
|
||||
nfapi_dl_config_mch_pdu_rel8_t *mch_pdu_rel8 = &dl_config_pdu->mch_pdu.mch_pdu_rel8;
|
||||
uint16_t pdu_index = mch_pdu_rel8->pdu_index;
|
||||
int16_t pdu_index = mch_pdu_rel8->pdu_index;
|
||||
uint16_t tx_pdus = TX_req->tx_request_body.number_of_pdus;
|
||||
uint16_t invalid_pdu = pdu_index == -1;
|
||||
uint8_t *sdu = invalid_pdu ? NULL : pdu_index >= tx_pdus ? NULL : TX_req->tx_request_body.tx_pdu_list[pdu_index].segments[0].segment_data;
|
||||
@@ -884,7 +884,7 @@ void schedule_response(Sched_Rsp_t *Sched_INFO, void *arg) {
|
||||
|
||||
case NFAPI_DL_CONFIG_DLSCH_PDU_TYPE: {
|
||||
nfapi_dl_config_dlsch_pdu_rel8_t *dlsch_pdu_rel8 = &dl_config_pdu->dlsch_pdu.dlsch_pdu_rel8;
|
||||
uint16_t pdu_index = dlsch_pdu_rel8->pdu_index;
|
||||
int16_t pdu_index = dlsch_pdu_rel8->pdu_index;
|
||||
uint16_t tx_pdus = TX_req->tx_request_body.number_of_pdus;
|
||||
uint16_t invalid_pdu = pdu_index == -1;
|
||||
uint8_t *sdu = invalid_pdu ? NULL : pdu_index >= tx_pdus ? NULL : TX_req->tx_request_body.tx_pdu_list[pdu_index].segments[0].segment_data;
|
||||
|
||||
@@ -618,7 +618,7 @@ void init_fep_thread(RU_t *ru,
|
||||
void kill_fep_thread(RU_t *ru)
|
||||
{
|
||||
RU_proc_t *proc = &ru->proc;
|
||||
if (proc->pthread_fep == 0)
|
||||
if (proc->pthread_fep[0] == 0)
|
||||
return;
|
||||
pthread_mutex_lock( &proc->mutex_fep[0] );
|
||||
proc->instance_cnt_fep[0] = 0;
|
||||
|
||||
@@ -243,7 +243,7 @@ void nr_postDecode(PHY_VARS_gNB *gNB, notifiedFIFO_elt_t *req) {
|
||||
if (decodeSuccess && !gNB->pusch_vars[rdata->ulsch_id]->DTX) {
|
||||
LOG_D(PHY,"[gNB %d] ULSCH: Setting ACK for SFN/SF %d.%d (pid %d, ndi %d, status %d, round %d, TBS %d, Max interation (all seg) %d)\n",
|
||||
gNB->Mod_id,ulsch_harq->frame,ulsch_harq->slot,rdata->harq_pid,pusch_pdu->pusch_data.new_data_indicator,ulsch_harq->status,ulsch_harq->round,ulsch_harq->TBS,rdata->decodeIterations);
|
||||
ulsch_harq->status = SCH_IDLE;
|
||||
ulsch_harq->status = NR_SCH_IDLE;
|
||||
ulsch_harq->round = 0;
|
||||
ulsch->harq_mask &= ~(1 << rdata->harq_pid);
|
||||
|
||||
@@ -885,7 +885,7 @@ int phy_procedures_gNB_uespec_RX(PHY_VARS_gNB *gNB, int frame_rx, int slot_rx) {
|
||||
int32_t srs_estimated_channel_time[frame_parms->nb_antennas_rx][1 << srs_pdu->num_ant_ports][frame_parms->ofdm_symbol_size] __attribute__((aligned(32)));
|
||||
int32_t srs_estimated_channel_time_shifted[frame_parms->nb_antennas_rx][1 << srs_pdu->num_ant_ports][frame_parms->ofdm_symbol_size];
|
||||
int8_t snr_per_rb[srs_pdu->bwp_size];
|
||||
int8_t snr;
|
||||
int8_t snr = 0;
|
||||
|
||||
start_meas(&gNB->generate_srs_stats);
|
||||
if (check_srs_pdu(srs_pdu, &gNB->nr_srs_info[i]->srs_pdu) == 0) {
|
||||
|
||||
@@ -61,11 +61,11 @@ static telnetshell_cmddef_t channelmod_cmdarray[] = {
|
||||
{"show predef", "", channelmod_show_cmd, {NULL}, TELNETSRV_CMDFLAG_WEBSRVONLY, NULL},
|
||||
{"show current", "", channelmod_show_cmd, {NULL}, TELNETSRV_CMDFLAG_WEBSRVONLY, NULL},
|
||||
{"modify", "<channelid> <param> <value>", channelmod_modify_cmd, {NULL}, TELNETSRV_CMDFLAG_TELNETONLY, NULL},
|
||||
{"show params", "<channelid> <param> <value>", channelmod_modify_cmd, {webfunc_getdata : get_currentchannels_type}, TELNETSRV_CMDFLAG_GETWEBTBLDATA | TELNETSRV_CMDFLAG_WEBSRV_SETRETURNTBL, NULL},
|
||||
{"show params", "<channelid> <param> <value>", channelmod_modify_cmd, {.webfunc_getdata = get_currentchannels_type}, TELNETSRV_CMDFLAG_GETWEBTBLDATA | TELNETSRV_CMDFLAG_WEBSRV_SETRETURNTBL, NULL},
|
||||
{"show channelid",
|
||||
HELP_WEBIF_MODIFCHAN_STRING,
|
||||
channelmod_modify_cmd,
|
||||
{webfunc_getdata : get_channel_params},
|
||||
{.webfunc_getdata = get_channel_params},
|
||||
TELNETSRV_CMDFLAG_NEEDPARAM | TELNETSRV_CMDFLAG_WEBSRVONLY | TELNETSRV_CMDFLAG_GETWEBTBLDATA,
|
||||
NULL},
|
||||
{"", "", NULL, {NULL}, 0, NULL},
|
||||
|
||||
@@ -263,10 +263,10 @@ typedef enum {
|
||||
|
||||
#define CHANNELMOD_HELP_MODELLIST "<list name> channel list name in config file describing the model type and its parameters\n"
|
||||
#define CHANNELMOD_PARAMS_DESC { \
|
||||
{"s" , CONFIG_HLP_SNR, PARAMFLAG_CMDLINE_NOPREFIXENABLED, dblptr:&snr_dB, defdblval:25, TYPE_DOUBLE, 0},\
|
||||
{"sinr_dB", NULL, 0, dblptr:&sinr_dB, defdblval:0 , TYPE_DOUBLE, 0},\
|
||||
{"max_chan", "Max number of runtime models", 0, uptr:&max_chan, defintval:10, TYPE_UINT, 0},\
|
||||
{CHANNELMOD_MODELLIST_PARANAME, CHANNELMOD_HELP_MODELLIST, 0, strptr:&modellist_name, defstrval:"DefaultChannelList", TYPE_STRING, 0},\
|
||||
{"s" , CONFIG_HLP_SNR, PARAMFLAG_CMDLINE_NOPREFIXENABLED, .dblptr=&snr_dB, .defdblval=25, TYPE_DOUBLE, 0},\
|
||||
{"sinr_dB", NULL, 0, .dblptr=&sinr_dB, .defdblval=0 , TYPE_DOUBLE, 0},\
|
||||
{"max_chan", "Max number of runtime models", 0, .uptr=&max_chan, .defintval=10, TYPE_UINT, 0},\
|
||||
{CHANNELMOD_MODELLIST_PARANAME, CHANNELMOD_HELP_MODELLIST, 0, .strptr=&modellist_name, .defstrval="DefaultChannelList", TYPE_STRING, 0},\
|
||||
}
|
||||
|
||||
/* parameters for one model */
|
||||
@@ -279,13 +279,13 @@ typedef enum {
|
||||
#define CHANNELMOD_MODEL_DT_PNAME "ds_tdl"
|
||||
|
||||
#define CHANNELMOD_MODEL_PARAMS_DESC { \
|
||||
{CHANNELMOD_MODEL_NAME_PNAME, "name of the model\n", 0, strptr:NULL , defstrval:"", TYPE_STRING, 0 },\
|
||||
{CHANNELMOD_MODEL_TYPE_PNAME, "name of the model type\n", 0, strptr:NULL , defstrval:"AWGN", TYPE_STRING, 0 },\
|
||||
{CHANNELMOD_MODEL_PL_PNAME, "channel path loss in dB\n", 0, dblptr:NULL, defdblval:0, TYPE_DOUBLE, 0 },\
|
||||
{CHANNELMOD_MODEL_NP_PNAME, "channel noise in dB\n", 0, dblptr:NULL, defdblval:-50, TYPE_DOUBLE, 0 },\
|
||||
{CHANNELMOD_MODEL_FF_PNAME, "channel forget factor ((0 to 1)\n", 0, dblptr:NULL, defdblval:0, TYPE_DOUBLE, 0 },\
|
||||
{CHANNELMOD_MODEL_CO_PNAME, "channel offset in samps\n", 0, iptr:NULL, defintval:0, TYPE_INT, 0 },\
|
||||
{CHANNELMOD_MODEL_DT_PNAME, "delay spread for TDL models\n", 0, dblptr:NULL, defdblval:0, TYPE_DOUBLE, 0 }\
|
||||
{CHANNELMOD_MODEL_NAME_PNAME, "name of the model\n", 0, .strptr=NULL , .defstrval="", TYPE_STRING, 0 },\
|
||||
{CHANNELMOD_MODEL_TYPE_PNAME, "name of the model type\n", 0, .strptr=NULL , .defstrval="AWGN", TYPE_STRING, 0 },\
|
||||
{CHANNELMOD_MODEL_PL_PNAME, "channel path loss in dB\n", 0, .dblptr=NULL, .defdblval=0, TYPE_DOUBLE, 0 },\
|
||||
{CHANNELMOD_MODEL_NP_PNAME, "channel noise in dB\n", 0, .dblptr=NULL, .defdblval=-50, TYPE_DOUBLE, 0 },\
|
||||
{CHANNELMOD_MODEL_FF_PNAME, "channel forget factor ((0 to 1)\n", 0, .dblptr=NULL, .defdblval=0, TYPE_DOUBLE, 0 },\
|
||||
{CHANNELMOD_MODEL_CO_PNAME, "channel offset in samps\n", 0, .iptr=NULL, .defintval=0, TYPE_INT, 0 },\
|
||||
{CHANNELMOD_MODEL_DT_PNAME, "delay spread for TDL models\n", 0, .dblptr=NULL, .defdblval=0, TYPE_DOUBLE, 0 }\
|
||||
}
|
||||
|
||||
#include "common/platform_constants.h"
|
||||
|
||||
Reference in New Issue
Block a user