[Epic-ID: ODUHIGH-475][Task-ID: ODUHIGH-476]Fix for segmentation fault in RACH Indica... 99/9399/1
authorlal.harshita <Harshita.Lal@radisys.com>
Wed, 26 Oct 2022 06:26:54 +0000 (11:56 +0530)
committerlal.harshita <Harshita.Lal@radisys.com>
Wed, 26 Oct 2022 06:27:48 +0000 (11:57 +0530)
Signed-off-by: lal.harshita <Harshita.Lal@radisys.com>
Change-Id: Ia1b9f13f0d1b15ee17bbc59f4854dd01f8f542b4

src/5gnrsch/sch_rach.c
src/du_app/du_sys_info_hdl.c
src/du_app/du_ue_mgr.c

index 162ed15..8a81745 100644 (file)
@@ -375,10 +375,8 @@ uint16_t calculateRaRnti(uint8_t symbolIdx, uint8_t slotIdx, uint8_t freqIdx)
  *  @param[in]  shed instance
  *  @return  void
  **/
-void createSchRaCb(SchRaReq *raReq, Inst schInst)
+void createSchRaCb(uint8_t ueId, SchRaReq *raReq, Inst schInst)
 {
-   uint8_t ueId = 0;
-
    if(raReq->isCFRA)
    {
       /* If a UE in handover has triggered CFRA, its UE CB context is already present in SCH, 
@@ -760,7 +758,7 @@ bool schProcessRaReq(Inst schInst, SchCellCb *cell, SlotTimingInfo currTime, uin
          cell->schUlSlotInfo[msg3Time.slot]->puschUe = ueId;
 
       /* Create raCb at SCH */
-      createSchRaCb(cell->raReq[ueId-1], schInst);
+      createSchRaCb(ueId, cell->raReq[ueId-1], schInst);
 
       /* Remove RachInd from pending RA request list */
       SCH_FREE(cell->raReq[ueId-1]->rachInd, sizeof(RachIndInfo));
index a53e162..debaf53 100644 (file)
@@ -2863,7 +2863,7 @@ void FreePuschCfgCommon(struct BWP_UplinkCommon__pusch_ConfigCommon *puschCfg)
       /* P0 Nominal with grant */
       DU_FREE(setup->p0_NominalWithGrant, sizeof(long));
 
-      DU_ALLOC(puschCfg->choice.setup, sizeof(PUSCH_ConfigCommon_t));
+      DU_FREE(puschCfg->choice.setup, sizeof(PUSCH_ConfigCommon_t));
    }
 }/* BuildPuschCfgCommon */
 
index 7900c62..b77b231 100644 (file)
@@ -1279,6 +1279,7 @@ uint8_t fillMacUeCfg(uint16_t cellId, uint8_t gnbDuUef1apId, uint16_t crnti, DuU
          fillDefaultPhyCellGrpInfo(macUeCfg);
          fillDefaultSpCellGrpInfo(macUeCfg);
          fillDefaultModulation(macUeCfg);
+         macUeCfg->ambrCfg = NULLP;
       }
 
 #ifdef NR_DRX