fixes for broken automatic indentation in MAC #1

This commit is contained in:
Raymond Knopp
2018-01-21 16:58:21 -08:00
parent 5dc0d7ccea
commit b350f8557e
4 changed files with 3995 additions and 4883 deletions
+131 -134
View File
@@ -251,7 +251,7 @@ void config_mib(int Mod_idP,
cfg->rf_config.dl_channel_bandwidth.value = to_prb(dl_BandwidthP); cfg->rf_config.dl_channel_bandwidth.value = to_prb(dl_BandwidthP);
cfg->rf_config.dl_channel_bandwidth.tl.tag = NFAPI_RF_CONFIG_DL_CHANNEL_BANDWIDTH_TAG; cfg->rf_config.dl_channel_bandwidth.tl.tag = NFAPI_RF_CONFIG_DL_CHANNEL_BANDWIDTH_TAG;
cfg->num_tlv++; cfg->num_tlv++;
LOG_E(PHY,"%s() dl_BandwidthP:%d\n", __FUNCTION__, dl_BandwidthP); LOG_E(PHY,"%s() dl_BandwidthP:%d\n", __FUNCTION__, dl_BandwidthP);
cfg->rf_config.ul_channel_bandwidth.value = to_prb(dl_BandwidthP); cfg->rf_config.ul_channel_bandwidth.value = to_prb(dl_BandwidthP);
cfg->rf_config.ul_channel_bandwidth.tl.tag = NFAPI_RF_CONFIG_UL_CHANNEL_BANDWIDTH_TAG; cfg->rf_config.ul_channel_bandwidth.tl.tag = NFAPI_RF_CONFIG_UL_CHANNEL_BANDWIDTH_TAG;
@@ -306,35 +306,35 @@ LOG_E(PHY,"%s() dl_BandwidthP:%d\n", __FUNCTION__, dl_BandwidthP);
LOG_I(MAC, LOG_I(MAC,
"%s() NFAPI_CONFIG_REQUEST(num_tlv:%u) DL_BW:%u UL_BW:%u Ncp %d,p_eNB %d,earfcn %d,band %d,phich_resource %u phich_duration %u phich_power_offset %u PSS %d SSS %d PCI %d" "%s() NFAPI_CONFIG_REQUEST(num_tlv:%u) DL_BW:%u UL_BW:%u Ncp %d,p_eNB %d,earfcn %d,band %d,phich_resource %u phich_duration %u phich_power_offset %u PSS %d SSS %d PCI %d"
#ifdef Rel14 #ifdef Rel14
" PBCH repetition %d" " PBCH repetition %d"
#endif #endif
"\n" "\n"
,__FUNCTION__ ,__FUNCTION__
,cfg->num_tlv ` ,cfg->num_tlv
,cfg->rf_config.dl_channel_bandwidth.value ,cfg->rf_config.dl_channel_bandwidth.value
,cfg->rf_config.ul_channel_bandwidth.value ,cfg->rf_config.ul_channel_bandwidth.value
,NcpP,p_eNBP ,NcpP,p_eNBP
,cfg->nfapi_config.earfcn.value ,cfg->nfapi_config.earfcn.value
,cfg->nfapi_config.rf_bands.rf_band[0] ,cfg->nfapi_config.rf_bands.rf_band[0]
,cfg->phich_config.phich_resource.value ,cfg->phich_config.phich_resource.value
,cfg->phich_config.phich_duration.value ,cfg->phich_config.phich_duration.value
,cfg->phich_config.phich_power_offset.value ,cfg->phich_config.phich_power_offset.value
,cfg->sch_config.primary_synchronization_signal_epre_eprers.value ,cfg->sch_config.primary_synchronization_signal_epre_eprers.value
,cfg->sch_config.secondary_synchronization_signal_epre_eprers.value ,cfg->sch_config.secondary_synchronization_signal_epre_eprers.value
,cfg->sch_config.physical_cell_id.value ,cfg->sch_config.physical_cell_id.value
#ifdef Rel14 #ifdef Rel14
,cfg->emtc_config.pbch_repetitions_enable_r13.value ,cfg->emtc_config.pbch_repetitions_enable_r13.value
#endif #endif
); );
} }
void config_sib1(int Mod_idP, int CC_idP, TDD_Config_t * tdd_ConfigP) void config_sib1(int Mod_idP, int CC_idP, TDD_Config_t * tdd_ConfigP)
{ {
nfapi_config_request_t *cfg = &RC.mac[Mod_idP]->config[CC_idP]; nfapi_config_request_t *cfg = &RC.mac[Mod_idP]->config[CC_idP];
if (tdd_ConfigP) { //TDD if (tdd_ConfigP) { //TDD
cfg->subframe_config.duplex_mode.value = 0; cfg->subframe_config.duplex_mode.value = 0;
@@ -434,16 +434,13 @@ config_sib2(int Mod_idP,
cfg->pucch_config.n1_pucch_an.tl.tag = NFAPI_PUCCH_CONFIG_N1_PUCCH_AN_TAG; cfg->pucch_config.n1_pucch_an.tl.tag = NFAPI_PUCCH_CONFIG_N1_PUCCH_AN_TAG;
cfg->num_tlv++; cfg->num_tlv++;
if (radioResourceConfigCommonP->pusch_ConfigCommon.ul_ReferenceSignalsPUSCH.groupHoppingEnabled == true) if (radioResourceConfigCommonP->pusch_ConfigCommon.ul_ReferenceSignalsPUSCH.groupHoppingEnabled == true) {
{
cfg->uplink_reference_signal_config.uplink_rs_hopping.value = 1; cfg->uplink_reference_signal_config.uplink_rs_hopping.value = 1;
} }
else if (radioResourceConfigCommonP->pusch_ConfigCommon.ul_ReferenceSignalsPUSCH.sequenceHoppingEnabled == true) else if (radioResourceConfigCommonP->pusch_ConfigCommon.ul_ReferenceSignalsPUSCH.sequenceHoppingEnabled == true) {
{
cfg->uplink_reference_signal_config.uplink_rs_hopping.value = 2; cfg->uplink_reference_signal_config.uplink_rs_hopping.value = 2;
} }
else // No hopping else {
{
cfg->uplink_reference_signal_config.uplink_rs_hopping.value = 0; cfg->uplink_reference_signal_config.uplink_rs_hopping.value = 0;
} }
cfg->uplink_reference_signal_config.uplink_rs_hopping.tl.tag = NFAPI_UPLINK_REFERENCE_SIGNAL_CONFIG_UPLINK_RS_HOPPING_TAG; cfg->uplink_reference_signal_config.uplink_rs_hopping.tl.tag = NFAPI_UPLINK_REFERENCE_SIGNAL_CONFIG_UPLINK_RS_HOPPING_TAG;
@@ -474,10 +471,10 @@ config_sib2(int Mod_idP,
if (radioResourceConfigCommonP->soundingRS_UL_ConfigCommon.choice.setup.srs_MaxUpPts) { if (radioResourceConfigCommonP->soundingRS_UL_ConfigCommon.choice.setup.srs_MaxUpPts) {
cfg->srs_config.max_up_pts.value = 1; cfg->srs_config.max_up_pts.value = 1;
} }
else { else {
cfg->srs_config.max_up_pts.value = 0; cfg->srs_config.max_up_pts.value = 0;
} }
cfg->srs_config.max_up_pts.tl.tag = NFAPI_SRS_CONFIG_MAX_UP_PTS_TAG; cfg->srs_config.max_up_pts.tl.tag = NFAPI_SRS_CONFIG_MAX_UP_PTS_TAG;
cfg->num_tlv++; cfg->num_tlv++;
@@ -819,65 +816,65 @@ rrc_mac_config_req_eNB(module_id_t Mod_idP,
RC.mac[Mod_idP]->common_channels[CC_idP].sib1_v13ext = sib1_v13ext; RC.mac[Mod_idP]->common_channels[CC_idP].sib1_v13ext = sib1_v13ext;
} }
#endif #endif
if (radioResourceConfigCommon != NULL) { if (radioResourceConfigCommon != NULL) {
LOG_I(MAC, "[CONFIG]SIB2/3 Contents (partial)\n"); LOG_I(MAC, "[CONFIG]SIB2/3 Contents (partial)\n");
LOG_I(MAC, "[CONFIG]pusch_config_common.n_SB = %ld\n", LOG_I(MAC, "[CONFIG]pusch_config_common.n_SB = %ld\n",
radioResourceConfigCommon-> radioResourceConfigCommon->
pusch_ConfigCommon.pusch_ConfigBasic.n_SB); pusch_ConfigCommon.pusch_ConfigBasic.n_SB);
LOG_I(MAC, "[CONFIG]pusch_config_common.hoppingMode = %ld\n", LOG_I(MAC, "[CONFIG]pusch_config_common.hoppingMode = %ld\n",
radioResourceConfigCommon-> radioResourceConfigCommon->
pusch_ConfigCommon.pusch_ConfigBasic.hoppingMode); pusch_ConfigCommon.pusch_ConfigBasic.hoppingMode);
LOG_I(MAC, LOG_I(MAC,
"[CONFIG]pusch_config_common.pusch_HoppingOffset = %ld\n", "[CONFIG]pusch_config_common.pusch_HoppingOffset = %ld\n",
radioResourceConfigCommon-> radioResourceConfigCommon->
pusch_ConfigCommon.pusch_ConfigBasic.pusch_HoppingOffset); pusch_ConfigCommon.pusch_ConfigBasic.pusch_HoppingOffset);
LOG_I(MAC, "[CONFIG]pusch_config_common.enable64QAM = %d\n", LOG_I(MAC, "[CONFIG]pusch_config_common.enable64QAM = %d\n",
radioResourceConfigCommon-> radioResourceConfigCommon->
pusch_ConfigCommon.pusch_ConfigBasic.enable64QAM); pusch_ConfigCommon.pusch_ConfigBasic.enable64QAM);
LOG_I(MAC, LOG_I(MAC,
"[CONFIG]pusch_config_common.groupHoppingEnabled = %d\n", "[CONFIG]pusch_config_common.groupHoppingEnabled = %d\n",
radioResourceConfigCommon-> radioResourceConfigCommon->
pusch_ConfigCommon.ul_ReferenceSignalsPUSCH. pusch_ConfigCommon.ul_ReferenceSignalsPUSCH.
groupHoppingEnabled); groupHoppingEnabled);
LOG_I(MAC, LOG_I(MAC,
"[CONFIG]pusch_config_common.groupAssignmentPUSCH = %ld\n", "[CONFIG]pusch_config_common.groupAssignmentPUSCH = %ld\n",
radioResourceConfigCommon-> radioResourceConfigCommon->
pusch_ConfigCommon.ul_ReferenceSignalsPUSCH. pusch_ConfigCommon.ul_ReferenceSignalsPUSCH.
groupAssignmentPUSCH); groupAssignmentPUSCH);
LOG_I(MAC, LOG_I(MAC,
"[CONFIG]pusch_config_common.sequenceHoppingEnabled = %d\n", "[CONFIG]pusch_config_common.sequenceHoppingEnabled = %d\n",
radioResourceConfigCommon-> radioResourceConfigCommon->
pusch_ConfigCommon.ul_ReferenceSignalsPUSCH. pusch_ConfigCommon.ul_ReferenceSignalsPUSCH.
sequenceHoppingEnabled); sequenceHoppingEnabled);
LOG_I(MAC, "[CONFIG]pusch_config_common.cyclicShift = %ld\n", LOG_I(MAC, "[CONFIG]pusch_config_common.cyclicShift = %ld\n",
radioResourceConfigCommon-> radioResourceConfigCommon->
pusch_ConfigCommon.ul_ReferenceSignalsPUSCH.cyclicShift); pusch_ConfigCommon.ul_ReferenceSignalsPUSCH.cyclicShift);
AssertFatal(radioResourceConfigCommon-> AssertFatal(radioResourceConfigCommon->
rach_ConfigCommon.maxHARQ_Msg3Tx > 0, rach_ConfigCommon.maxHARQ_Msg3Tx > 0,
"radioResourceconfigCommon %d == 0\n", "radioResourceconfigCommon %d == 0\n",
(int) radioResourceConfigCommon-> (int) radioResourceConfigCommon->
rach_ConfigCommon.maxHARQ_Msg3Tx); rach_ConfigCommon.maxHARQ_Msg3Tx);
RC.mac[Mod_idP]->common_channels[CC_idP]. RC.mac[Mod_idP]->common_channels[CC_idP].
radioResourceConfigCommon = radioResourceConfigCommon; radioResourceConfigCommon = radioResourceConfigCommon;
if (ul_CarrierFreq > 0) if (ul_CarrierFreq > 0)
RC.mac[Mod_idP]->common_channels[CC_idP].ul_CarrierFreq = RC.mac[Mod_idP]->common_channels[CC_idP].ul_CarrierFreq =
ul_CarrierFreq; ul_CarrierFreq;
if (ul_Bandwidth) if (ul_Bandwidth)
RC.mac[Mod_idP]->common_channels[CC_idP].ul_Bandwidth = RC.mac[Mod_idP]->common_channels[CC_idP].ul_Bandwidth =
*ul_Bandwidth; *ul_Bandwidth;
else else
RC.mac[Mod_idP]->common_channels[CC_idP].ul_Bandwidth = RC.mac[Mod_idP]->common_channels[CC_idP].ul_Bandwidth =
RC.mac[Mod_idP]->common_channels[CC_idP].mib->message. RC.mac[Mod_idP]->common_channels[CC_idP].mib->message.
dl_Bandwidth; dl_Bandwidth;
config_sib2(Mod_idP, CC_idP, radioResourceConfigCommon, config_sib2(Mod_idP, CC_idP, radioResourceConfigCommon,
#ifdef Rel14 #ifdef Rel14
radioResourceConfigCommon_BR, radioResourceConfigCommon_BR,
#endif #endif
NULL, ul_Bandwidth, additionalSpectrumEmission, NULL, ul_Bandwidth, additionalSpectrumEmission,
mbsfn_SubframeConfigList); mbsfn_SubframeConfigList);
} }
} // mib != NULL } // mib != NULL
@@ -888,14 +885,14 @@ rrc_mac_config_req_eNB(module_id_t Mod_idP,
if (UE_id == -1) { if (UE_id == -1) {
LOG_E(MAC, "%s:%d:%s: ERROR, UE_id == -1\n", __FILE__, LOG_E(MAC, "%s:%d:%s: ERROR, UE_id == -1\n", __FILE__,
__LINE__, __FUNCTION__); __LINE__, __FUNCTION__);
} else { } else {
if (logicalChannelConfig) if (logicalChannelConfig)
UE_list-> UE_list->
UE_template[CC_idP][UE_id].lcgidmap UE_template[CC_idP][UE_id].lcgidmap
[logicalChannelIdentity] = [logicalChannelIdentity] =
*logicalChannelConfig-> *logicalChannelConfig->
ul_SpecificParameters->logicalChannelGroup; ul_SpecificParameters->logicalChannelGroup;
else else
UE_list-> UE_list->
UE_template[CC_idP][UE_id].lcgidmap UE_template[CC_idP][UE_id].lcgidmap
@@ -920,9 +917,9 @@ rrc_mac_config_req_eNB(module_id_t Mod_idP,
UE_id = find_UE_id(Mod_idP, rntiP); UE_id = find_UE_id(Mod_idP, rntiP);
if (UE_id == -1) if (UE_id == -1)
LOG_E(MAC, "%s:%d:%s: ERROR, UE_id == -1\n", __FILE__, LOG_E(MAC, "%s:%d:%s: ERROR, UE_id == -1\n", __FILE__,
__LINE__, __FUNCTION__); __LINE__, __FUNCTION__);
else else
config_dedicated_scell(Mod_idP, rntiP, sCellToAddMod_r10); config_dedicated_scell(Mod_idP, rntiP, sCellToAddMod_r10);
} }
#endif #endif
@@ -954,7 +951,7 @@ rrc_mac_config_req_eNB(module_id_t Mod_idP,
#if defined(Rel10) || defined(Rel14) #if defined(Rel10) || defined(Rel14)
if (mbsfn_AreaInfoList != NULL) { if (mbsfn_AreaInfoList != NULL) {
// One eNB could be part of multiple mbsfn syc area, this could change over time so reset each time // One eNB could be part of multiple mbsfn syc area, this could change over time so reset each time
LOG_I(MAC,"[eNB %d][CONFIG] Received %d MBSFN Area Info\n", Mod_idP, mbsfn_AreaInfoList->list.count); LOG_I(MAC,"[eNB %d][CONFIG] Received %d MBSFN Area Info\n", Mod_idP, mbsfn_AreaInfoList->list.count);
RC.mac[Mod_idP]->common_channels[0].num_active_mbsfn_area = mbsfn_AreaInfoList->list.count; RC.mac[Mod_idP]->common_channels[0].num_active_mbsfn_area = mbsfn_AreaInfoList->list.count;
@@ -966,67 +963,67 @@ rrc_mac_config_req_eNB(module_id_t Mod_idP,
} }
} }
if (pmch_InfoList != NULL) { if (pmch_InfoList != NULL) {
// LOG_I(MAC,"DUY: lcid when entering rrc_mac config_req is %02d\n",(pmch_InfoList->list.array[0]->mbms_SessionInfoList_r9.list.array[0]->logicalChannelIdentity_r9)); // LOG_I(MAC,"DUY: lcid when entering rrc_mac config_req is %02d\n",(pmch_InfoList->list.array[0]->mbms_SessionInfoList_r9.list.array[0]->logicalChannelIdentity_r9));
LOG_I(MAC, "[CONFIG] Number of PMCH in this MBSFN Area %d\n", LOG_I(MAC, "[CONFIG] Number of PMCH in this MBSFN Area %d\n",
pmch_InfoList->list.count); pmch_InfoList->list.count);
for (i = 0; i < pmch_InfoList->list.count; i++) { for (i = 0; i < pmch_InfoList->list.count; i++) {
RC.mac[Mod_idP]->common_channels[0].pmch_Config[i] = RC.mac[Mod_idP]->common_channels[0].pmch_Config[i] =
&pmch_InfoList->list.array[i]->pmch_Config_r9; &pmch_InfoList->list.array[i]->pmch_Config_r9;
LOG_I(MAC, LOG_I(MAC,
"[CONFIG] PMCH[%d]: This PMCH stop (sf_AllocEnd_r9) at subframe %ldth\n", "[CONFIG] PMCH[%d]: This PMCH stop (sf_AllocEnd_r9) at subframe %ldth\n",
i, i,
RC.mac[Mod_idP]->common_channels[0]. RC.mac[Mod_idP]->common_channels[0].
pmch_Config[i]->sf_AllocEnd_r9); pmch_Config[i]->sf_AllocEnd_r9);
LOG_I(MAC, "[CONFIG] PMCH[%d]: mch_Scheduling_Period = %ld\n", LOG_I(MAC, "[CONFIG] PMCH[%d]: mch_Scheduling_Period = %ld\n",
i, i,
RC.mac[Mod_idP]->common_channels[0]. RC.mac[Mod_idP]->common_channels[0].
pmch_Config[i]->mch_SchedulingPeriod_r9); pmch_Config[i]->mch_SchedulingPeriod_r9);
LOG_I(MAC, "[CONFIG] PMCH[%d]: dataMCS = %ld\n", i, LOG_I(MAC, "[CONFIG] PMCH[%d]: dataMCS = %ld\n", i,
RC.mac[Mod_idP]->common_channels[0]. RC.mac[Mod_idP]->common_channels[0].
pmch_Config[i]->dataMCS_r9); pmch_Config[i]->dataMCS_r9);
// MBMS session info list in each MCH // MBMS session info list in each MCH
RC.mac[Mod_idP]->common_channels[0].mbms_SessionList[i] = RC.mac[Mod_idP]->common_channels[0].mbms_SessionList[i] =
&pmch_InfoList->list.array[i]->mbms_SessionInfoList_r9; &pmch_InfoList->list.array[i]->mbms_SessionInfoList_r9;
LOG_I(MAC, "PMCH[%d] Number of session (MTCH) is: %d\n", i, LOG_I(MAC, "PMCH[%d] Number of session (MTCH) is: %d\n", i,
RC.mac[Mod_idP]->common_channels[0]. RC.mac[Mod_idP]->common_channels[0].
mbms_SessionList[i]->list.count); mbms_SessionList[i]->list.count);
}
} }
} }
}
#endif #endif
LOG_E(MAC, "%s() %s:%d RC.mac[Mod_idP]->if_inst->PHY_config_req:%p\n", __FUNCTION__, __FILE__, __LINE__, RC.mac[Mod_idP]->if_inst->PHY_config_req); LOG_E(MAC, "%s() %s:%d RC.mac[Mod_idP]->if_inst->PHY_config_req:%p\n", __FUNCTION__, __FILE__, __LINE__, RC.mac[Mod_idP]->if_inst->PHY_config_req);
// if in nFAPI mode // if in nFAPI mode
if ( if (
(nfapi_mode == 1 || nfapi_mode == 2) && (nfapi_mode == 1 || nfapi_mode == 2) &&
(RC.mac[Mod_idP]->if_inst->PHY_config_req == NULL) (RC.mac[Mod_idP]->if_inst->PHY_config_req == NULL)
) { ) {
while(RC.mac[Mod_idP]->if_inst->PHY_config_req == NULL) { while(RC.mac[Mod_idP]->if_inst->PHY_config_req == NULL) {
// DJP AssertFatal(RC.mac[Mod_idP]->if_inst->PHY_config_req != NULL,"if_inst->phy_config_request is null\n"); // DJP AssertFatal(RC.mac[Mod_idP]->if_inst->PHY_config_req != NULL,"if_inst->phy_config_request is null\n");
usleep(100 * 1000); usleep(100 * 1000);
printf("Waiting for PHY_config_req\n"); printf("Waiting for PHY_config_req\n");
} }
} }
if (radioResourceConfigCommon != NULL) { if (radioResourceConfigCommon != NULL) {
PHY_Config_t phycfg; PHY_Config_t phycfg;
phycfg.Mod_id = Mod_idP; phycfg.Mod_id = Mod_idP;
phycfg.CC_id = CC_idP; phycfg.CC_id = CC_idP;
phycfg.cfg = &RC.mac[Mod_idP]->config[CC_idP]; phycfg.cfg = &RC.mac[Mod_idP]->config[CC_idP];
if (RC.mac[Mod_idP]->if_inst->PHY_config_req) RC.mac[Mod_idP]->if_inst->PHY_config_req(&phycfg); if (RC.mac[Mod_idP]->if_inst->PHY_config_req) RC.mac[Mod_idP]->if_inst->PHY_config_req(&phycfg);
VCD_SIGNAL_DUMPER_DUMP_FUNCTION_BY_NAME(VCD_SIGNAL_DUMPER_FUNCTIONS_RRC_MAC_CONFIG, VCD_FUNCTION_OUT); VCD_SIGNAL_DUMPER_DUMP_FUNCTION_BY_NAME(VCD_SIGNAL_DUMPER_FUNCTIONS_RRC_MAC_CONFIG, VCD_FUNCTION_OUT);
} }
return(0); return(0);
} }
int int
File diff suppressed because it is too large Load Diff
File diff suppressed because it is too large Load Diff
File diff suppressed because it is too large Load Diff