+ if (eaxc.ruPortId < p_xran_dev_ctx->srs_cfg.eAxC_offset)
+ {
+ struct xran_flat_buffer *pBuffer = NULL;
+ if(result->dir == 1)
+ pBuffer = p_xran_dev_ctx->sFHCpRxPrbMapBbuIoBufCtrl[tti % XRAN_N_FE_BUF_LEN][eaxc.ccId][eaxc.ruPortId].sBufferList.pBuffers;
+ else if(result->dir == 0)
+ pBuffer = p_xran_dev_ctx->sFHCpTxPrbMapBbuIoBufCtrl[tti % XRAN_N_FE_BUF_LEN][eaxc.ccId][eaxc.ruPortId].sBufferList.pBuffers;
+ if(pBuffer)
+ pRbMap = (struct xran_prb_map *)pBuffer->pData;
+ if(p_xran_dev_ctx->sFrontHaulTxPrbMapBbuIoBufCtrl[tti % XRAN_N_FE_BUF_LEN][eaxc.ccId][eaxc.ruPortId].sBufferList.pBuffers)
+ pRbMap_desc = (struct xran_prb_map *) p_xran_dev_ctx->sFrontHaulTxPrbMapBbuIoBufCtrl[tti % XRAN_N_FE_BUF_LEN][eaxc.ccId][eaxc.ruPortId].sBufferList.pBuffers->pData;
+
+ if(i == 0){
+ if((pRbMap_desc != NULL) && (pRbMap_desc->nPrbElm <= p_xran_dev_ctx->sectiondb_elm[ctx_id][result->dir][eaxc.ccId][eaxc.ruPortId])){
+ p_xran_dev_ctx->sectiondb_elm[ctx_id][result->dir][eaxc.ccId][eaxc.ruPortId]=0;
+ xran_cp_reset_section_info(handle, result->dir, eaxc.ccId, eaxc.ruPortId, ctx_id);
+ }
+ idx = p_xran_dev_ctx->sectiondb_elm[ctx_id][result->dir][eaxc.ccId][eaxc.ruPortId]++;
+
+ if(p_dev_ctx){
+ result->numSetBFW = p_dev_ctx->numSetBFWs_arr[idx];
+ if(likely(pRbMap!=NULL)){
+ prbMapElm = &pRbMap->prbMap[idx];
+ mb = prbMapElm->bf_weight.p_ext_start;
+ if(mb){
+ rte_pktmbuf_free(mb);
+ }
+ prbMapElm->bf_weight.p_ext_start = mbuf;
+ prbMapElm->bf_weight.p_ext_section = (void *)section;
+ *mb_free = MBUF_KEEP;
+ }
+ }
+ }
+ info = xran_cp_get_section_info_ptr(handle, result->dir, eaxc.ccId, eaxc.ruPortId, ctx_id);
+ if(likely(info != NULL))
+ {
+ info->prbElemBegin = (i == 0 ) ? 1 : 0;
+ info->prbElemEnd = (i == (result->numSections -1)) ? 1 : 0;
+ info->ef = result->sections[i].info.ef;
+ info->startPrbc = result->sections[i].info.startPrbc;
+ info->numPrbc = result->sections[i].info.numPrbc;
+ info->type = result->sections[i].info.type;
+ info->startSymId = result->hdr.startSymId;
+ info->iqWidth = result->hdr.iqWidth;
+ info->compMeth = result->hdr.compMeth;
+ info->id = result->sections[i].info.id;
+ info->rb = XRAN_RBIND_EVERY;
+ info->numSymbol = result->sections[i].info.numSymbol;
+ info->reMask = 0xfff;
+ info->beamId = result->sections[i].info.beamId;
+ info->symInc = XRAN_SYMBOLNUMBER_NOTINC;
+
+ int loc_sym=0;
+ if(likely(pRbMap_desc != NULL)){
+ prbMapElm = &pRbMap_desc->prbMap[idx];
+ for(loc_sym = 0; loc_sym < XRAN_NUM_OF_SYMBOL_PER_SLOT; loc_sym++)
+ {
+ struct xran_section_desc *p_sec_desc = &prbMapElm->sec_desc[loc_sym][0];
+
+ if(likely(p_sec_desc!=NULL))
+ {
+ info->sec_desc[loc_sym].iq_buffer_offset = p_sec_desc->iq_buffer_offset;
+ info->sec_desc[loc_sym].iq_buffer_len = p_sec_desc->iq_buffer_len;
+
+ p_sec_desc->section_id = info->id;
+ }
+ else
+ {
+ print_err("section desc is NULL\n");
+ }
+ } /* for(loc_sym = 0; loc_sym < XRAN_NUM_OF_SYMBOL_PER_SLOT; loc_sym++) */
+ }
+ }