Commit 22059801 authored by Raymond Knopp's avatar Raymond Knopp

reduced logging, UE MIB processing

parent 42d4c6c1
......@@ -1698,16 +1698,17 @@ int get_nrofHARQ_ProcessesForPDSCH(e_NR_PDSCH_ServingCellConfig__nrofHARQ_Proces
int add_new_nr_ue(module_id_t mod_idP, rnti_t rntiP, NR_CellGroupConfig_t *CellGroup)
{
NR_UE_info_t *UE_info = &RC.nrmac[mod_idP]->UE_info;
LOG_I(MAC, "[gNB %d] Adding UE with rnti %x (num_UEs %d)\n",
LOG_I(NR_MAC, "[gNB %d] Adding UE with rnti %x (num_UEs %d)\n",
mod_idP,
rntiP,
UE_info->num_UEs);
dump_nr_list(&UE_info->list);
for (int i = 0; i < MAX_MOBILES_PER_GNB; i++) {
if (UE_info->active[i])
if (UE_info->active[i]) {
LOG_I(NR_MAC,"UE %x is active, skipping\n",rntiP);
continue;
}
int UE_id = i;
UE_info->num_UEs++;
UE_info->active[UE_id] = true;
......
......@@ -1251,7 +1251,7 @@ bool nr_acknack_scheduling(int mod_id,
// Find the right timing_indicator value.
int i = 0;
while (i < 8) {
LOG_I(MAC,"pdsch_to_harq_feedback[%d] = %d (pucch->ul_slot %d - slot %d)\n",
LOG_D(MAC,"pdsch_to_harq_feedback[%d] = %d (pucch->ul_slot %d - slot %d)\n",
i,pdsch_to_harq_feedback[i],pucch->ul_slot,slot);
if (pdsch_to_harq_feedback[i] == pucch->ul_slot - slot)
break;
......
......@@ -488,20 +488,12 @@ rrc_gNB_generate_RRCSetup(
/* init timers */
// ue_context_pP->ue_context.ue_rrc_inactivity_timer = 0;
nr_rrc_data_req(ctxt_pP,
DCCH,
rrc_gNB_mui++,
SDU_CONFIRM_NO,
ue_p->Srb0.Tx_buffer.payload_size,
(uint8_t *)ue_p->Srb0.Tx_buffer.Payload,
PDCP_TRANSMISSION_MODE_CONTROL);
// configure MAC
rrc_mac_config_req_gNB(rrc->module_id,
rrc->carrier.ssb_SubcarrierOffset,
rrc->carrier.pdsch_AntennaPorts,
rrc->carrier.pusch_AntennaPorts,
(NR_ServingCellConfigCommon_t *)rrc->carrier.servingcellconfigcommon,
NULL,
0,
ue_context_pP->ue_context.rnti,
ue_context_pP->ue_context.masterCellGroup
......@@ -527,11 +519,11 @@ rrc_gNB_generate_RRCSetup(
NULL);
#endif
}
break;
default :
LOG_W(NR_RRC, "Unknown node type %d\n", rrc->node_type);
break;
default:
LOG_W(NR_RRC, "Unknown node type %d\n", rrc->node_type);
break;
}
}
......
......@@ -555,42 +555,39 @@ int8_t nr_rrc_ue_decode_NR_BCCH_BCH_Message(
const uint8_t buffer_len ){
int i;
NR_BCCH_BCH_Message_t *bcch_message = NULL;
NR_MIB_t *mib = NR_UE_rrc_inst[module_id].mib;
if (NR_UE_rrc_inst[module_id].mib != NULL)
SEQUENCE_free( &asn_DEF_NR_BCCH_BCH_Message, (void *)bcch_message, 1 );
else LOG_I(NR_RRC,"Configuring MAC for first MIB reception\n");
if(mib != NULL){
SEQUENCE_free( &asn_DEF_NR_BCCH_BCH_Message, (void *)mib, 1 );
asn_dec_rval_t dec_rval = uper_decode_complete(NULL,
&asn_DEF_NR_BCCH_BCH_Message,
(void **)&bcch_message,
(const void *)bufferP,
buffer_len );
if ((dec_rval.code != RC_OK) || (dec_rval.consumed == 0)) {
LOG_I(NR_RRC,"NR_BCCH_BCH decode error\n");
// free the memory
SEQUENCE_free( &asn_DEF_NR_BCCH_BCH_Message, (void *)bcch_message, 1 );
return -1;
}
else {
//for(i=0; i<buffer_len; ++i){
// printf("[RRC] MIB PDU : %d\n", bufferP[i]);
//}
asn_dec_rval_t dec_rval = uper_decode_complete( NULL,
&asn_DEF_NR_BCCH_BCH_Message,
(void **)&bcch_message,
(const void *)bufferP,
buffer_len );
if ((dec_rval.code != RC_OK) || (dec_rval.consumed == 0)) {
LOG_I(NR_RRC,"NR_BCCH_BCH decode error\n");
// free the memory
SEQUENCE_free( &asn_DEF_NR_BCCH_BCH_Message, (void *)bcch_message, 1 );
return -1;
}
else {
// link to rrc instance
mib = bcch_message->message.choice.mib;
SEQUENCE_free( &asn_DEF_NR_MIB, (void *)NR_UE_rrc_inst[module_id].mib, 1 );
NR_UE_rrc_inst[module_id].mib = bcch_message->message.choice.mib;
//memcpy( (void *)mib,
// (void *)&bcch_message->message.choice.mib,
// sizeof(NR_MIB_t) );
LOG_I(NR_RRC,"Configuring MAC for first MIB reception\n");
nr_rrc_mac_config_req_ue( 0, 0, 0, mib, NULL, NULL, NULL);
nr_rrc_mac_config_req_ue( 0, 0, 0, NR_UE_rrc_inst[module_id].mib, NULL, NULL, NULL);
}
}
return 0;
}
const char siWindowLength[10][5] = {"5s", "10s", "20s", "40s", "80s", "160s", "320s", "640s", "1280s","ERR"};// {"1ms","2ms","5ms","10ms","15ms","20ms","40ms","80ms","ERR"};
const short siWindowLength_int[9] = {5,10,20,40,80,160,320,640,1280};//{1,2,5,10,15,20,40,80};
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment