{
uint8_t elementCnt = 0;
uint8_t ret = ROK;
- uint8_t idx, idx2, rrcBufLen;
+ uint8_t idx;
/* UE Capabulity RAT Container List */
CU_ALLOC(rrcMsg->uE_CapabilityRAT_ContainerList, sizeof(UE_CapabilityRAT_ContainerList_t));
* RFAILED - failure
*
* ****************************************************************/
-uint8_t procDrbSetupList(uint32_t duId, DRBs_Setup_List_t *drbSetupList)
+uint8_t procDrbSetupList(uint32_t duId, CuUeCb *ueCb, DRBs_Setup_List_t *drbSetupList)
{
- uint8_t arrIdx = 0;
+ uint8_t arrIdx = 0, drbIdx = 0;
uint32_t teId = 0;
DRBs_Setup_ItemIEs_t *drbItemIe = NULLP;
teId = extractTeId(&drbItemIe->value.choice.DRBs_Setup_Item.dLUPTNLInformation_ToBeSetup_List);
if(teId > 0)
{
- if(addDrbTunnels(duId, teId)== ROK)
- {
- DU_LOG("\nDEBUG --> EGTP: Tunnel Added for TeId %d", teId);
- }
+ if(addDrbTunnels(duId, teId)== ROK)
+ {
+ DU_LOG("\nDEBUG --> EGTP: Tunnel Added for TeId %d", teId);
+ }
+ /* As per Spec 38.473, in UE COntext Response, Tunnel information
+ * are sent to CU for setting up of Tunnels in DL direction.
+ * Search for DRB ID in CU databse */
+ for(drbIdx = 0; drbIdx < ueCb->numDrb; drbIdx++)
+ {
+ if(ueCb->drbList[drbIdx].drbId == drbItemIe->value.choice.DRBs_Setup_Item.dRBID)
+ {
+ fillTeIdString(3, teId, ueCb->drbList[drbIdx].dlUpTnlInfo.teId);
+ break;
+ }
+ }
}
else
return RFAILED;
case ProtocolIE_ID_id_DRBs_Setup_List:
{
/* Adding Tunnels for successful DRB */
- procDrbSetupList(duId, &ueCtxtSetupRsp->protocolIEs.list.array[idx]->value.choice.DRBs_Setup_List);
+ procDrbSetupList(duId, ueCb, &ueCtxtSetupRsp->protocolIEs.list.array[idx]->value.choice.DRBs_Setup_List);
break;
}
case ProtocolIE_ID_id_DUtoCURRCInformation:
* ****************************************************************/
void procUeContextReleaseComplete(uint32_t duId, F1AP_PDU_t *f1apMsg)
{
- uint8_t duIdx = 0, ieIdx = 0, ueIdx = 0;
+ uint8_t duIdx = 0, ieIdx = 0, ueIdx = 0, drbIdx = 0;
uint8_t gnbDuUeF1apId = 0, gnbCuUeF1apId = 0;
DuDb *duDb = NULLP;
CuUeCb *ueCb = NULLP;
if((ueCb->cellCb->ueCb[ueIdx]->gnbCuUeF1apId == gnbCuUeF1apId) &&
(ueCb->cellCb->ueCb[ueIdx]->gnbDuUeF1apId == gnbDuUeF1apId))
{
+ for(drbIdx = 0; drbIdx < ueCb->numDrb; drbIdx++)
+ {
+ deleteEgtpTunnel(duId, ueCb->drbList[drbIdx].dlUpTnlInfo.teId);
+ }
ueCb->cellCb->ueCb[ueIdx] = NULLP;
ueCb->cellCb->numUe--;
if((ueCb->cellCb->numUe == 0) && (ueCb->cellCb->cellStatus == CELL_DELETION_IN_PROGRESS))
uint8_t cnt = 0;
EgtpTeIdCb *teidCb = NULLP;
- /* This variable is taken for sending specific number of downlink data packet.
- * Presently the code is supporting total 4500 data packets trasfer for 3 UEs only with sleep(1).
- * If you wants to pump data for 3 UE change the following macro values
- * NUM_TUNNEL_TO_PUMP_DATA = 9, NUM_DL_PACKETS = 1.
- * totalDataPacket = totalNumOfTestFlow * NUM_TUNNEL_TO_PUMP_DATA * NUM_DL_PACKETS
- * totalDataPacket = [500*9*1] */
- int32_t totalNumOfTestFlow = 2;
-
while(true)
{
ch = getchar();
}
#else
+ /* This variable is taken for sending specific number of downlink data packet.
+ * Presently the code is supporting total 4500 data packets trasfer for 3 UEs only with sleep(1).
+ * If you wants to pump data for 3 UE change the following macro values
+ * NUM_TUNNEL_TO_PUMP_DATA = 9, NUM_DL_PACKETS = 1.
+ * totalDataPacket = totalNumOfTestFlow * NUM_TUNNEL_TO_PUMP_DATA * NUM_DL_PACKETS
+ * totalDataPacket = [500*9*1] */
+ int32_t totalNumOfTestFlow = 2;
+
while(totalNumOfTestFlow)
{
for(duId = 1; duId<=MAX_DU_SUPPORTED; duId++)
{
for(teId = 1; teId <= NUM_TUNNEL_TO_PUMP_DATA; teId++)
{
- DU_LOG("\nDEBUG --> EGTP: Sending DL User Data(duId %d, teId:%d)\n", duId, teId);
+ teidCb = NULLP;
cmHashListFind(&(egtpCb.dstCb[duId-1].teIdLst), (uint8_t *)&(teId), sizeof(uint32_t), 0, (PTR *)&teidCb);
if(teidCb)
{
cnt =0;
+ DU_LOG("\nDEBUG --> EGTP: Sending DL User Data(duId %d, teId:%d)\n", duId, teId);
while(cnt < NUM_DL_PACKETS)
{
ret = cuEgtpDatReq(duId, teId);
cnt++;
}
}
+ else
+ {
+ DU_LOG("\nDEBUG --> EGTP: TunnelId Not Found for (duId %d, teId:%d)\n", duId, teId);
+ }
}
}
totalNumOfTestFlow--;