X-Git-Url: https://gerrit.o-ran-sc.org/r/gitweb?a=blobdiff_plain;f=src%2F5gnrmac%2Flwr_mac_fsm.c;h=bb338c51e7dbd4a0b8aa8f1669999f927f013c9b;hb=def50dc175cebc67238db5f1acd5ff322a2279bd;hp=03af08503a61ead7cb340b27b54080de7c2ff1aa;hpb=2193e4cf01012809495be026097e8d7eacb9f0ac;p=o-du%2Fl2.git diff --git a/src/5gnrmac/lwr_mac_fsm.c b/src/5gnrmac/lwr_mac_fsm.c index 03af08503..bb338c51e 100644 --- a/src/5gnrmac/lwr_mac_fsm.c +++ b/src/5gnrmac/lwr_mac_fsm.c @@ -1242,17 +1242,13 @@ void fillRssiMeas(uint8_t value, ClCellParam **cellPtr) uint32_t getParamValue(fapi_uint16_tlv_t *tlv, uint16_t type) { - //uint16_t valueLen; void *posPtr; - //valueLen = tlv->tl.length; posPtr = &tlv->tl.tag; posPtr += sizeof(tlv->tl.tag); posPtr += sizeof(tlv->tl.length); /*TO DO: malloc to SSI memory */ if(type == FAPI_UINT_8) { - //temp = (uint8_t *)malloc(valueLen * sizeof(U8)); - //memcpy(temp, posPtr, valueLen); return(*(uint8_t *)posPtr); } else if(type == FAPI_UINT_16) @@ -1869,12 +1865,12 @@ uint8_t lwr_mac_procParamRspEvt(void *msg) uint8_t lwr_mac_procConfigReqEvt(void *msg) { #ifdef INTEL_FAPI - uint8_t idx = 0; - uint8_t index = 0; - uint16_t *cellId; - uint16_t cellIdx; - uint32_t msgLen = 0; - MacCellCfg macCfgParams; + uint8_t idx = 0; + uint8_t index = 0; + uint16_t *cellId; + uint16_t cellIdx; + uint32_t msgLen = 0; + MacCellCfg macCfgParams; fapi_config_req_t *configReq; DU_LOG("\nLWR_MAC: Received EVENT[%d] at STATE[%d]", lwrMacCb.event, \ @@ -2596,7 +2592,7 @@ void fillDlMsgDlDciPdu(fapi_dl_dci_t *dlDciPtr, PdcchCfg *pdcchInfo,\ } /* Fetching DCI field values */ - dciFormatId = dlMsgInfo->dciFormatId;; /* Always set to 1 for DL */ + dciFormatId = dlMsgInfo->dciFormatId; /* Always set to 1 for DL */ timeDomResAssign = pdcchInfo->dci.pdschCfg->pdschTimeAlloc.rowIndex -1; VRB2PRBMap = pdcchInfo->dci.pdschCfg->pdschFreqAlloc.vrbPrbMapping; modNCodScheme = pdcchInfo->dci.pdschCfg->codeword[0].mcsIndex; @@ -2724,7 +2720,7 @@ uint8_t fillPdcchPdu(fapi_dl_tti_req_pdu_t *dlTtiReqPdu, DlSchedInfo *dlInfo, \ else { DU_LOG("\nLWR_MAC: Failed filling PDCCH Pdu"); - return RFAILED;; + return RFAILED; } dlTtiReqPdu->pduType = PDCCH_PDU_TYPE; dlTtiReqPdu->pdu.pdcch_pdu.bwpSize = bwp->freqAlloc.numPrb; @@ -3163,7 +3159,7 @@ uint16_t fillDlTtiReq(SlotIndInfo currTimingInfo) numPduEncoded++; } printf("\033[1;34m"); - DU_LOG("\nLWR_MAC: SIB1 sent..."); + DU_LOG("\nLWR_MAC: SIB1 sent..."); printf("\033[0m"); } } @@ -3205,7 +3201,7 @@ uint16_t fillDlTtiReq(SlotIndInfo currTimingInfo) fillPdcchPdu(&dlTtiReq->pdus[numPduEncoded], \ &currDlSlot->dlInfo, rntiType, CORESET_TYPE1); DU_LOG("\nLWR_MAC: DL MSG sent..."); - } + } printf("\033[0m"); numPduEncoded++; @@ -3225,6 +3221,9 @@ uint16_t fillDlTtiReq(SlotIndInfo currTimingInfo) msgLen = sizeof(fapi_dl_tti_req_t) - sizeof(fapi_msg_t); fillMsgHeader(&dlTtiReq->header, FAPI_DL_TTI_REQUEST, msgLen); +#ifdef ODU_SLOT_IND_DEBUG_LOG + DU_LOG("\nLWR_MAC: Sending DL TTI Request"); +#endif LwrMacSendToPhy(dlTtiReq->header.msg_id, sizeof(fapi_dl_tti_req_t), \ (void *)dlTtiReq); @@ -3235,6 +3234,9 @@ uint16_t fillDlTtiReq(SlotIndInfo currTimingInfo) { msgLen = sizeof(fapi_dl_tti_req_t) - sizeof(fapi_msg_t); fillMsgHeader(&dlTtiReq->header, FAPI_DL_TTI_REQUEST, msgLen); +#ifdef ODU_SLOT_IND_DEBUG_LOG + DU_LOG("\nLWR_MAC: Sending DL TTI Request"); +#endif LwrMacSendToPhy(dlTtiReq->header.msg_id, sizeof(fapi_dl_tti_req_t), (void *)dlTtiReq); } memset(currDlSlot, 0, sizeof(MacDlSlot)); @@ -3344,6 +3346,7 @@ uint16_t sendTxDataReq(SlotIndInfo currTimingInfo, DlSchedInfo *dlInfo) msgLen = txDataReqMsgSize - sizeof(fapi_msg_t); fillMsgHeader(&txDataReq->header, FAPI_TX_DATA_REQUEST, msgLen); + DU_LOG("\nLWR_MAC: Sending TX DATA Request"); LwrMacSendToPhy(txDataReq->header.msg_id, txDataReqMsgSize, \ (void *)txDataReq); } @@ -3656,8 +3659,9 @@ uint16_t fillUlTtiReq(SlotIndInfo currTimingInfo) } msgLen = sizeof(fapi_ul_tti_req_t) - sizeof(fapi_msg_t); fillMsgHeader(&ulTtiReq->header, FAPI_UL_TTI_REQUEST, msgLen); - - DU_LOG("\nLWR_MAC: Sending UL TTI Request"); +#ifdef ODU_SLOT_IND_DEBUG_LOG + DU_LOG("\nLWR_MAC: Sending UL TTI Request"); +#endif LwrMacSendToPhy(ulTtiReq->header.msg_id, msgSize, (void *)ulTtiReq); memset(currUlSlot, 0, sizeof(MacUlSlot)); @@ -3703,7 +3707,7 @@ void fillUlDciPdu(fapi_dl_dci_t *ulDciPtr, DciInfo *schDciInfo) uint8_t bytePos; uint8_t bitPos; - uint8_t coreset1Size = 0; + uint8_t coreset1Size = 0; uint16_t rbStart = 0; uint16_t rbLen = 0; uint8_t dciFormatId = 0; @@ -3895,7 +3899,7 @@ uint8_t fillUlDciPdcchPdu(fapi_dci_pdu_t *ulDciReqPdu, DlSchedInfo *dlInfo, uint uint16_t fillUlDciReq(SlotIndInfo currTimingInfo) { #ifdef INTEL_FAPI - uint8_t cellIdx; + uint8_t cellIdx; uint8_t numPduEncoded = 0; uint32_t msgLen = 0; uint32_t msgSize = 0;