Change hardcoded task id to TASK_VARIABLE
This commit is contained in:
@@ -370,7 +370,7 @@ int create_gNB_tasks(uint32_t gnb_nb) {
|
||||
}
|
||||
}
|
||||
|
||||
if (itti_create_task (TASK_GTPV1_U, &nr_gtpv1u_gNB_task, NULL) < 0) {
|
||||
if (itti_create_task (TASK_VARIABLE, &nr_gtpv1u_gNB_task, NULL) < 0) {
|
||||
LOG_E(GTPU, "Create task for GTPV1U failed\n");
|
||||
return -1;
|
||||
}
|
||||
@@ -395,7 +395,7 @@ int create_gNB_tasks(uint32_t gnb_nb) {
|
||||
}
|
||||
}
|
||||
|
||||
if (itti_create_task (TASK_GTPV1_U, &nr_gtpv1u_gNB_task, NULL) < 0) {
|
||||
if (itti_create_task (TASK_VARIABLE, &nr_gtpv1u_gNB_task, NULL) < 0) {
|
||||
LOG_E(GTPU, "Create task for GTPV1U failed\n");
|
||||
return -1;
|
||||
}
|
||||
|
||||
@@ -324,7 +324,7 @@ int CU_send_F1_SETUP_RESPONSE(instance_t instance,
|
||||
|
||||
for (i=0; i<num_cells_to_activate; i++) {
|
||||
|
||||
LOG_I(F1AP, "(%d) mcc = %d, mnc = %d, mnc_digit_length = %d\n",
|
||||
LOG_I(F1AP, "(cell %d) mcc = %d, mnc = %d, mnc_digit_length = %d\n",
|
||||
i, f1ap_setup_resp->cells_to_activate[i].mcc, f1ap_setup_resp->cells_to_activate[i].mnc, f1ap_setup_resp->cells_to_activate[i].mnc_digit_length);
|
||||
|
||||
F1AP_Cells_to_be_Activated_List_ItemIEs_t *cells_to_be_activated_list_item_ies;
|
||||
@@ -569,7 +569,7 @@ int CU_send_gNB_CU_CONFIGURATION_UPDATE(instance_t instance, f1ap_gnb_cu_configu
|
||||
|
||||
for (i=0; i<f1ap_gnb_cu_configuration_update->num_cells_to_activate; i++) {
|
||||
|
||||
LOG_I(F1AP, "(%d) mcc = %d, mnc = %d, mnc_digit_length = %d\n",
|
||||
LOG_I(F1AP, "(cell %d) mcc = %d, mnc = %d, mnc_digit_length = %d\n",
|
||||
i, f1ap_gnb_cu_configuration_update->cells_to_activate[i].mcc, f1ap_gnb_cu_configuration_update->cells_to_activate[i].mnc, f1ap_gnb_cu_configuration_update->cells_to_activate[i].mnc_digit_length);
|
||||
|
||||
F1AP_Cells_to_be_Activated_List_ItemIEs_t *cells_to_be_activated_list_item_ies;
|
||||
|
||||
@@ -1012,7 +1012,7 @@ pdcp_data_ind(
|
||||
rb_id + 4,
|
||||
sdu_buffer_sizeP - payload_offset);
|
||||
//LOG_T(PDCP,"Sending to GTPV1U %d bytes\n", sdu_buffer_sizeP - payload_offset);
|
||||
gtpu_buffer_p = itti_malloc(TASK_PDCP_ENB, TASK_GTPV1_U,
|
||||
gtpu_buffer_p = itti_malloc(TASK_PDCP_ENB, TASK_VARIABLE,
|
||||
sdu_buffer_sizeP - payload_offset + GTPU_HEADER_OVERHEAD_MAX);
|
||||
AssertFatal(gtpu_buffer_p != NULL, "OUT OF MEMORY");
|
||||
memcpy(>pu_buffer_p[GTPU_HEADER_OVERHEAD_MAX], &sdu_buffer_pP->data[payload_offset], sdu_buffer_sizeP - payload_offset);
|
||||
|
||||
@@ -481,7 +481,7 @@ static void deliver_sdu_drb(void *_ue, nr_pdcp_entity_t *entity,
|
||||
int offset=0;
|
||||
if (entity->has_sdap == 1 && entity->has_sdapULheader == 1) offset = 1; // this is the offset of the SDAP header in bytes
|
||||
|
||||
gtpu_buffer_p = itti_malloc(TASK_PDCP_ENB, TASK_GTPV1_U,
|
||||
gtpu_buffer_p = itti_malloc(TASK_PDCP_ENB, TASK_VARIABLE,
|
||||
size + GTPU_HEADER_OVERHEAD_MAX - offset);
|
||||
AssertFatal(gtpu_buffer_p != NULL, "OUT OF MEMORY");
|
||||
memcpy(>pu_buffer_p[GTPU_HEADER_OVERHEAD_MAX], buf+offset, size-offset);
|
||||
|
||||
@@ -8157,7 +8157,7 @@ rrc_eNB_decode_dcch(
|
||||
}
|
||||
}
|
||||
|
||||
itti_send_msg_to_task(TASK_GTPV1_U, ctxt_pP->instance, msg_delete_tunnels_p);
|
||||
itti_send_msg_to_task(TASK_VARIABLE, ctxt_pP->instance, msg_delete_tunnels_p);
|
||||
//S1AP_E_RAB_RELEASE_RESPONSE
|
||||
rrc_eNB_send_S1AP_E_RAB_RELEASE_RESPONSE(ctxt_pP,
|
||||
ue_context_p,
|
||||
|
||||
@@ -121,11 +121,11 @@ gtpv_data_req(
|
||||
|
||||
LOG_I(GTPU,"gtpv_data_req task_id = TASK_DATA_FORWARDING\n");
|
||||
|
||||
message_buffer = itti_malloc (TASK_GTPV1_U, TASK_DATA_FORWARDING, sdu_sizeP);
|
||||
message_buffer = itti_malloc (TASK_VARIABLE, TASK_DATA_FORWARDING, sdu_sizeP);
|
||||
|
||||
memcpy (message_buffer, buffer_pP, sdu_sizeP);
|
||||
|
||||
message_p = itti_alloc_new_message (TASK_GTPV1_U, 0, GTPV1U_ENB_DATA_FORWARDING_IND);
|
||||
message_p = itti_alloc_new_message (TASK_VARIABLE, 0, GTPV1U_ENB_DATA_FORWARDING_IND);
|
||||
GTPV1U_ENB_DATA_FORWARDING_IND (message_p).frame = ctxt_pP->frame;
|
||||
GTPV1U_ENB_DATA_FORWARDING_IND (message_p).enb_flag = ctxt_pP->enb_flag;
|
||||
GTPV1U_ENB_DATA_FORWARDING_IND (message_p).rb_id = rb_idP;
|
||||
@@ -144,11 +144,11 @@ gtpv_data_req(
|
||||
|
||||
LOG_I(GTPU,"gtpv_data_req task_id = TASK_END_MARKER\n");
|
||||
|
||||
message_buffer = itti_malloc (TASK_GTPV1_U, TASK_END_MARKER, sdu_sizeP);
|
||||
message_buffer = itti_malloc (TASK_VARIABLE, TASK_END_MARKER, sdu_sizeP);
|
||||
|
||||
memcpy (message_buffer, buffer_pP, sdu_sizeP);
|
||||
|
||||
message_p = itti_alloc_new_message (TASK_GTPV1_U, 0, GTPV1U_ENB_END_MARKER_IND);
|
||||
message_p = itti_alloc_new_message (TASK_VARIABLE, 0, GTPV1U_ENB_END_MARKER_IND);
|
||||
GTPV1U_ENB_END_MARKER_IND (message_p).frame = ctxt_pP->frame;
|
||||
GTPV1U_ENB_END_MARKER_IND (message_p).enb_flag = ctxt_pP->enb_flag;
|
||||
GTPV1U_ENB_END_MARKER_IND (message_p).rb_id = rb_idP;
|
||||
@@ -201,15 +201,15 @@ boolean_t gtpv_data_req_new (
|
||||
//ue_context_p->ue_context.handover_info->state = HO_END_MARKER;
|
||||
MessageDef *msg;
|
||||
// Configure end marker
|
||||
msg = itti_alloc_new_message(TASK_GTPV1_U, 0, GTPV1U_ENB_END_MARKER_REQ);
|
||||
GTPV1U_ENB_END_MARKER_REQ(msg).buffer = itti_malloc(TASK_GTPV1_U, TASK_GTPV1_U, GTPU_HEADER_OVERHEAD_MAX + sdu_buffer_sizeP);
|
||||
msg = itti_alloc_new_message(TASK_VARIABLE, 0, GTPV1U_ENB_END_MARKER_REQ);
|
||||
GTPV1U_ENB_END_MARKER_REQ(msg).buffer = itti_malloc(TASK_VARIABLE, TASK_VARIABLE, GTPU_HEADER_OVERHEAD_MAX + sdu_buffer_sizeP);
|
||||
memcpy(>PV1U_ENB_END_MARKER_REQ(msg).buffer[GTPU_HEADER_OVERHEAD_MAX], sdu_buffer_pP, sdu_buffer_sizeP);
|
||||
GTPV1U_ENB_END_MARKER_REQ(msg).length = sdu_buffer_sizeP;
|
||||
GTPV1U_ENB_END_MARKER_REQ(msg).rnti = ctxt->rnti;
|
||||
GTPV1U_ENB_END_MARKER_REQ(msg).rab_id = rb_idP;
|
||||
GTPV1U_ENB_END_MARKER_REQ(msg).offset = GTPU_HEADER_OVERHEAD_MAX;
|
||||
LOG_I(GTPU, "Send End Marker to GTPV1-U at frame %d and subframe %d \n", ctxt->frame,ctxt->subframe);
|
||||
itti_send_msg_to_task(TASK_GTPV1_U, ENB_MODULE_ID_TO_INSTANCE(ctxt->module_id), msg);
|
||||
itti_send_msg_to_task(TASK_VARIABLE, ENB_MODULE_ID_TO_INSTANCE(ctxt->module_id), msg);
|
||||
return NW_GTPV1U_OK;
|
||||
}
|
||||
|
||||
|
||||
@@ -88,6 +88,7 @@
|
||||
#include "executables/softmodem-common.h"
|
||||
#include <openair2/RRC/NR/rrc_gNB_UE_context.h>
|
||||
#include <openair2/X2AP/x2ap_eNB.h>
|
||||
#include <openair3/ocp-gtpu/gtp_itf.h>
|
||||
|
||||
#include "BIT_STRING.h"
|
||||
#include "assertions.h"
|
||||
@@ -2270,7 +2271,7 @@ rrc_gNB_decode_dcch(
|
||||
}
|
||||
}
|
||||
|
||||
itti_send_msg_to_task(TASK_GTPV1_U, ctxt_pP->instance, msg_delete_tunnels_p);
|
||||
itti_send_msg_to_task(TASK_VARIABLE, ctxt_pP->instance, msg_delete_tunnels_p);
|
||||
//NGAP_PDUSESSION_RELEASE_RESPONSE
|
||||
rrc_gNB_send_NGAP_PDUSESSION_RELEASE_RESPONSE(ctxt_pP, ue_context_p, xid);
|
||||
} else {
|
||||
|
||||
@@ -59,6 +59,12 @@
|
||||
#include "NR_UE-CapabilityRAT-ContainerList.h"
|
||||
#include "f1ap_messages_types.h"
|
||||
|
||||
#if defined(NEW_GTPU)
|
||||
#define TASK_VARIABLE OCP_GTPV1_U
|
||||
#else
|
||||
#define TASK_VARIABLE TASK_GTPV1_U
|
||||
#endif
|
||||
|
||||
extern RAN_CONTEXT_t RC;
|
||||
|
||||
/* Value to indicate an invalid UE initial id */
|
||||
@@ -1422,7 +1428,7 @@ rrc_gNB_process_NGAP_PDUSESSION_RELEASE_COMMAND(
|
||||
}
|
||||
}
|
||||
|
||||
itti_send_msg_to_task(TASK_GTPV1_U, instance, msg_delete_tunnels_p);
|
||||
itti_send_msg_to_task(TASK_VARIABLE, instance, msg_delete_tunnels_p);
|
||||
//NGAP_PDUSESSION_RELEASE_RESPONSE
|
||||
rrc_gNB_send_NGAP_PDUSESSION_RELEASE_RESPONSE(&ctxt, ue_context_p, xid);
|
||||
LOG_I(NR_RRC, "Send PDU Session Release Response \n");
|
||||
|
||||
@@ -310,7 +310,7 @@ int create_gNB_tasks(uint32_t gnb_nb) {
|
||||
}
|
||||
}
|
||||
|
||||
if (itti_create_task (TASK_GTPV1_U, &nr_gtpv1u_gNB_task, NULL) < 0) {
|
||||
if (itti_create_task (TASK_VARIABLE, &nr_gtpv1u_gNB_task, NULL) < 0) {
|
||||
LOG_E(GTPU, "Create task for GTPV1U failed\n");
|
||||
return -1;
|
||||
}
|
||||
|
||||
@@ -52,6 +52,7 @@
|
||||
#include "gtpv1u_eNB_task.h"
|
||||
#include "rrc_eNB_GTPV1U.h"
|
||||
#include <common/utils/msc/msc.h>
|
||||
#include <openair3/ocp-gtpu/gtp_itf.h>
|
||||
|
||||
#undef GTP_DUMP_SOCKET
|
||||
|
||||
@@ -136,7 +137,7 @@ static int gtpv1u_eNB_send_init_udp(const Gtpv1uS1Req *req) {
|
||||
// Create and alloc new message
|
||||
MessageDef *message_p;
|
||||
struct in_addr addr= {0};
|
||||
message_p = itti_alloc_new_message(TASK_GTPV1_U, 0, UDP_INIT);
|
||||
message_p = itti_alloc_new_message(TASK_VARIABLE, 0, UDP_INIT);
|
||||
|
||||
if (message_p == NULL) {
|
||||
return -1;
|
||||
@@ -185,7 +186,7 @@ NwGtpv1uRcT gtpv1u_eNB_send_udp_msg(
|
||||
// Create and alloc new message
|
||||
MessageDef *message_p = NULL;
|
||||
udp_data_req_t *udp_data_req_p = NULL;
|
||||
message_p = itti_alloc_new_message(TASK_GTPV1_U, 0, UDP_DATA_REQ);
|
||||
message_p = itti_alloc_new_message(TASK_VARIABLE, 0, UDP_DATA_REQ);
|
||||
|
||||
if (message_p) {
|
||||
#if defined(LOG_GTPU) && LOG_GTPU > 0
|
||||
@@ -286,15 +287,15 @@ NwGtpv1uRcT gtpv1u_eNB_process_stack_req(
|
||||
//ue_context_p->ue_context.handover_info->state = HO_END_MARKER;
|
||||
MessageDef *msg;
|
||||
// Configure end marker
|
||||
msg = itti_alloc_new_message(TASK_GTPV1_U, 0, GTPV1U_ENB_END_MARKER_REQ);
|
||||
GTPV1U_ENB_END_MARKER_REQ(msg).buffer = itti_malloc(TASK_GTPV1_U, TASK_GTPV1_U, GTPU_HEADER_OVERHEAD_MAX + buffer_len);
|
||||
msg = itti_alloc_new_message(TASK_VARIABLE, 0, GTPV1U_ENB_END_MARKER_REQ);
|
||||
GTPV1U_ENB_END_MARKER_REQ(msg).buffer = itti_malloc(TASK_VARIABLE, TASK_VARIABLE, GTPU_HEADER_OVERHEAD_MAX + buffer_len);
|
||||
memcpy(>PV1U_ENB_END_MARKER_REQ(msg).buffer[GTPU_HEADER_OVERHEAD_MAX], buffer, buffer_len);
|
||||
GTPV1U_ENB_END_MARKER_REQ(msg).length = buffer_len;
|
||||
GTPV1U_ENB_END_MARKER_REQ(msg).rnti = ctxt.rnti;
|
||||
GTPV1U_ENB_END_MARKER_REQ(msg).rab_id = gtpv1u_teid_data_p->eps_bearer_id;
|
||||
GTPV1U_ENB_END_MARKER_REQ(msg).offset = GTPU_HEADER_OVERHEAD_MAX;
|
||||
LOG_I(GTPU, "Send End Marker to GTPV1-U at frame %d and subframe %d \n", ctxt.frame,ctxt.subframe);
|
||||
itti_send_msg_to_task(TASK_GTPV1_U, ENB_MODULE_ID_TO_INSTANCE(ctxt.module_id), msg);
|
||||
itti_send_msg_to_task(TASK_VARIABLE, ENB_MODULE_ID_TO_INSTANCE(ctxt.module_id), msg);
|
||||
return NW_GTPV1U_OK;
|
||||
}
|
||||
}
|
||||
@@ -359,8 +360,8 @@ NwGtpv1uRcT gtpv1u_eNB_process_stack_req(
|
||||
if (ue_context_p->ue_context.handover_info->state == HO_COMPLETE) {
|
||||
MessageDef *msg;
|
||||
// Configure target
|
||||
msg = itti_alloc_new_message(TASK_GTPV1_U, 0, GTPV1U_ENB_DATA_FORWARDING_REQ);
|
||||
GTPV1U_ENB_DATA_FORWARDING_REQ(msg).buffer = itti_malloc(TASK_GTPV1_U, TASK_GTPV1_U, GTPU_HEADER_OVERHEAD_MAX + buffer_len);
|
||||
msg = itti_alloc_new_message(TASK_VARIABLE, 0, GTPV1U_ENB_DATA_FORWARDING_REQ);
|
||||
GTPV1U_ENB_DATA_FORWARDING_REQ(msg).buffer = itti_malloc(TASK_VARIABLE, TASK_VARIABLE, GTPU_HEADER_OVERHEAD_MAX + buffer_len);
|
||||
memcpy(>PV1U_ENB_DATA_FORWARDING_REQ(msg).buffer[GTPU_HEADER_OVERHEAD_MAX], buffer, buffer_len);
|
||||
GTPV1U_ENB_DATA_FORWARDING_REQ(msg).length = buffer_len;
|
||||
GTPV1U_ENB_DATA_FORWARDING_REQ(msg).rnti = ctxt.rnti;
|
||||
@@ -378,7 +379,7 @@ NwGtpv1uRcT gtpv1u_eNB_process_stack_req(
|
||||
LOG_T(GTPU, "\n");
|
||||
#endif
|
||||
LOG_I(GTPU, "Send data forwarding to GTPV1-U at frame %d and subframe %d \n", ctxt.frame,ctxt.subframe);
|
||||
itti_send_msg_to_task(TASK_GTPV1_U, ENB_MODULE_ID_TO_INSTANCE(ctxt.module_id), msg);
|
||||
itti_send_msg_to_task(TASK_VARIABLE, ENB_MODULE_ID_TO_INSTANCE(ctxt.module_id), msg);
|
||||
return NW_GTPV1U_OK;
|
||||
}
|
||||
|
||||
@@ -585,7 +586,7 @@ static NwGtpv1uRcT gtpv1u_start_timer_wrapper(
|
||||
if (tmrType == NW_GTPV1U_TMR_TYPE_ONE_SHOT) {
|
||||
timer_setup(timeoutSec,
|
||||
timeoutUsec,
|
||||
TASK_GTPV1_U,
|
||||
TASK_VARIABLE,
|
||||
INSTANCE_DEFAULT,
|
||||
TIMER_ONE_SHOT,
|
||||
timeoutArg,
|
||||
@@ -593,7 +594,7 @@ static NwGtpv1uRcT gtpv1u_start_timer_wrapper(
|
||||
} else {
|
||||
timer_setup(timeoutSec,
|
||||
timeoutUsec,
|
||||
TASK_GTPV1_U,
|
||||
TASK_VARIABLE,
|
||||
INSTANCE_DEFAULT,
|
||||
TIMER_PERIODIC,
|
||||
timeoutArg,
|
||||
@@ -1123,7 +1124,7 @@ int gtpv1u_delete_s1u_tunnel(
|
||||
hashtable_rc_t hash_rc = HASH_TABLE_KEY_NOT_EXISTS;
|
||||
teid_t teid_eNB = 0;
|
||||
int erab_index = 0;
|
||||
message_p = itti_alloc_new_message(TASK_GTPV1_U, 0, GTPV1U_ENB_DELETE_TUNNEL_RESP);
|
||||
message_p = itti_alloc_new_message(TASK_VARIABLE, 0, GTPV1U_ENB_DELETE_TUNNEL_RESP);
|
||||
GTPV1U_ENB_DELETE_TUNNEL_RESP(message_p).rnti = req_pP->rnti;
|
||||
GTPV1U_ENB_DELETE_TUNNEL_RESP(message_p).status = 0;
|
||||
hash_rc = hashtable_get(RC.gtpv1u_data_g->ue_mapping, req_pP->rnti, (void **)>pv1u_ue_data_p);
|
||||
@@ -1287,7 +1288,7 @@ void *gtpv1u_eNB_process_itti_msg(void *notUsed) {
|
||||
instance_t instance;
|
||||
MessageDef *received_message_p = NULL;
|
||||
int rc = 0;
|
||||
itti_receive_msg(TASK_GTPV1_U, &received_message_p);
|
||||
itti_receive_msg(TASK_VARIABLE, &received_message_p);
|
||||
VCD_SIGNAL_DUMPER_DUMP_FUNCTION_BY_NAME(VCD_SIGNAL_DUMPER_FUNCTIONS_GTPV1U_ENB_TASK, VCD_FUNCTION_IN);
|
||||
DevAssert(received_message_p != NULL);
|
||||
instance = ITTI_MSG_DESTINATION_INSTANCE(received_message_p);
|
||||
@@ -1591,7 +1592,7 @@ void *gtpv1u_eNB_task(void *args) {
|
||||
int rc = 0;
|
||||
rc = gtpv1u_eNB_init();
|
||||
AssertFatal(rc == 0, "gtpv1u_eNB_init Failed");
|
||||
itti_mark_task_ready(TASK_GTPV1_U);
|
||||
itti_mark_task_ready(TASK_VARIABLE);
|
||||
MSC_START_USE();
|
||||
|
||||
while(1) {
|
||||
|
||||
@@ -27,6 +27,7 @@
|
||||
*/
|
||||
#include <stdio.h>
|
||||
#include <errno.h>
|
||||
#include <openair3/ocp-gtpu/gtp_itf.h>
|
||||
|
||||
#include "mme_config.h"
|
||||
#include "intertask_interface.h"
|
||||
@@ -86,7 +87,7 @@ static NwGtpv1uRcT gtpv1u_start_timer_wrapper(
|
||||
if (tmrType == NW_GTPV1U_TMR_TYPE_ONE_SHOT) {
|
||||
timer_setup(timeoutSec,
|
||||
timeoutUsec,
|
||||
TASK_GTPV1_U,
|
||||
TASK_VARIABLE,
|
||||
INSTANCE_DEFAULT,
|
||||
TIMER_ONE_SHOT,
|
||||
timeoutArg,
|
||||
@@ -94,7 +95,7 @@ static NwGtpv1uRcT gtpv1u_start_timer_wrapper(
|
||||
} else {
|
||||
timer_setup(timeoutSec,
|
||||
timeoutUsec,
|
||||
TASK_GTPV1_U,
|
||||
TASK_VARIABLE,
|
||||
INSTANCE_DEFAULT,
|
||||
TIMER_PERIODIC,
|
||||
timeoutArg,
|
||||
@@ -302,7 +303,7 @@ void *gtpv1u_gNB_task(void *args) {
|
||||
int rc = 0;
|
||||
rc = gtpv1u_gNB_init();
|
||||
AssertFatal(rc == 0, "gtpv1u_eNB_init Failed");
|
||||
itti_mark_task_ready(TASK_GTPV1_U);
|
||||
itti_mark_task_ready(TASK_VARIABLE);
|
||||
MSC_START_USE();
|
||||
|
||||
while(1) {
|
||||
@@ -755,7 +756,7 @@ int gtpv1u_delete_ngu_tunnel(
|
||||
hashtable_rc_t hash_rc = HASH_TABLE_KEY_NOT_EXISTS;
|
||||
teid_t teid_gNB = 0;
|
||||
int pdusession_index = 0;
|
||||
message_p = itti_alloc_new_message(TASK_GTPV1_U, 0, GTPV1U_GNB_DELETE_TUNNEL_RESP);
|
||||
message_p = itti_alloc_new_message(TASK_VARIABLE, 0, GTPV1U_GNB_DELETE_TUNNEL_RESP);
|
||||
GTPV1U_GNB_DELETE_TUNNEL_RESP(message_p).rnti = req_pP->rnti;
|
||||
GTPV1U_GNB_DELETE_TUNNEL_RESP(message_p).status = 0;
|
||||
hash_rc = hashtable_get(RC.nr_gtpv1u_data_g->ue_mapping, req_pP->rnti, (void **)>pv1u_ue_data_p);
|
||||
@@ -826,7 +827,7 @@ static int gtpv1u_gNB_send_init_udp(const Gtpv1uNGReq *req) {
|
||||
// Create and alloc new message
|
||||
MessageDef *message_p;
|
||||
struct in_addr addr= {0};
|
||||
message_p = itti_alloc_new_message(TASK_GTPV1_U, 0, UDP_INIT);
|
||||
message_p = itti_alloc_new_message(TASK_VARIABLE, 0, UDP_INIT);
|
||||
|
||||
if (message_p == NULL) {
|
||||
return -1;
|
||||
@@ -938,7 +939,7 @@ void *gtpv1u_gNB_process_itti_msg(void *notUsed) {
|
||||
instance_t instance;
|
||||
MessageDef *received_message_p = NULL;
|
||||
int rc = 0;
|
||||
itti_receive_msg(TASK_GTPV1_U, &received_message_p);
|
||||
itti_receive_msg(TASK_VARIABLE, &received_message_p);
|
||||
VCD_SIGNAL_DUMPER_DUMP_FUNCTION_BY_NAME(VCD_SIGNAL_DUMPER_FUNCTIONS_GTPV1U_ENB_TASK, VCD_FUNCTION_IN);
|
||||
DevAssert(received_message_p != NULL);
|
||||
instance = received_message_p->ittiMsgHeader.originInstance;
|
||||
@@ -1007,7 +1008,7 @@ void *nr_gtpv1u_gNB_task(void *args) {
|
||||
int rc = 0;
|
||||
rc = nr_gtpv1u_gNB_init();
|
||||
AssertFatal(rc == 0, "gtpv1u_gNB_init Failed");
|
||||
itti_mark_task_ready(TASK_GTPV1_U);
|
||||
itti_mark_task_ready(TASK_VARIABLE);
|
||||
MSC_START_USE();
|
||||
|
||||
while(1) {
|
||||
|
||||
@@ -162,7 +162,7 @@ NwGtpv1uRcT gtpv1u_send_udp_msg(
|
||||
MessageDef *message_p;
|
||||
udp_data_req_t *udp_data_req_p;
|
||||
|
||||
message_p = itti_alloc_new_message(TASK_GTPV1_U, UDP_DATA_REQ);
|
||||
message_p = itti_alloc_new_message(TASK_VARIABLE, UDP_DATA_REQ);
|
||||
|
||||
udp_data_req_p = &message_p->ittiMsg.udp_data_req;
|
||||
|
||||
@@ -202,7 +202,7 @@ NwGtpv1uRcT gtpv1u_process_stack_req(
|
||||
pUlpApi->apiInfo.recvMsgInfo.teid,
|
||||
((NwGtpv1uMsgT*)pUlpApi->apiInfo.recvMsgInfo.hMsg)->msgBufLen);
|
||||
|
||||
message_p = itti_alloc_new_message(TASK_GTPV1_U, GTPV1U_TUNNEL_DATA_IND);
|
||||
message_p = itti_alloc_new_message(TASK_VARIABLE, GTPV1U_TUNNEL_DATA_IND);
|
||||
|
||||
if (message_p == NULL) {
|
||||
return -1;
|
||||
@@ -282,7 +282,7 @@ static int gtpv1u_create_s1u_tunnel(Gtpv1uCreateTunnelReq *create_tunnel_reqP)
|
||||
// gtpv1u_teid2enb_info->enb_ip_addr.address.ipv4_address[3] = 2;
|
||||
|
||||
|
||||
message_p = itti_alloc_new_message(TASK_GTPV1_U, GTPV1U_CREATE_TUNNEL_RESP);
|
||||
message_p = itti_alloc_new_message(TASK_VARIABLE, GTPV1U_CREATE_TUNNEL_RESP);
|
||||
message_p->ittiMsg.gtpv1uCreateTunnelResp.S1u_teid = s1u_teid;
|
||||
message_p->ittiMsg.gtpv1uCreateTunnelResp.context_teid = create_tunnel_reqP->context_teid;
|
||||
message_p->ittiMsg.gtpv1uCreateTunnelResp.eps_bearer_id = create_tunnel_reqP->eps_bearer_id;
|
||||
@@ -312,7 +312,7 @@ static int gtpv1u_delete_s1u_tunnel(Teid_t context_teidP, Teid_t S1U_teidP)
|
||||
MessageDef *message_p;
|
||||
|
||||
GTPU_DEBUG("Rx GTPV1U_DELETE_TUNNEL Context %u S1U teid %u\n", context_teidP, S1U_teidP);
|
||||
message_p = itti_alloc_new_message(TASK_GTPV1_U, GTPV1U_DELETE_TUNNEL_RESP);
|
||||
message_p = itti_alloc_new_message(TASK_VARIABLE, GTPV1U_DELETE_TUNNEL_RESP);
|
||||
|
||||
message_p->ittiMsg.gtpv1uDeleteTunnelResp.S1u_teid = S1U_teidP;
|
||||
message_p->ittiMsg.gtpv1uDeleteTunnelResp.context_teid = context_teidP;
|
||||
@@ -338,7 +338,7 @@ static int gtpv1u_update_s1u_tunnel(Gtpv1uUpdateTunnelReq *reqP)
|
||||
reqP->context_teid,
|
||||
reqP->sgw_S1u_teid,
|
||||
reqP->enb_S1u_teid);
|
||||
message_p = itti_alloc_new_message(TASK_GTPV1_U, GTPV1U_UPDATE_TUNNEL_RESP);
|
||||
message_p = itti_alloc_new_message(TASK_VARIABLE, GTPV1U_UPDATE_TUNNEL_RESP);
|
||||
|
||||
hash_rc = hashtable_get(gtpv1u_sgw_data.S1U_mapping, reqP->sgw_S1u_teid, (void**)>pv1u_teid2enb_info);
|
||||
|
||||
@@ -376,7 +376,7 @@ static NwGtpv1uRcT gtpv1u_start_timer_wrapper(
|
||||
if (tmrType == NW_GTPV1U_TMR_TYPE_ONE_SHOT) {
|
||||
timer_setup(timeoutSec,
|
||||
timeoutUsec,
|
||||
TASK_GTPV1_U,
|
||||
TASK_VARIABLE,
|
||||
INSTANCE_DEFAULT,
|
||||
TIMER_ONE_SHOT,
|
||||
timeoutArg,
|
||||
@@ -384,7 +384,7 @@ static NwGtpv1uRcT gtpv1u_start_timer_wrapper(
|
||||
} else {
|
||||
timer_setup(timeoutSec,
|
||||
timeoutUsec,
|
||||
TASK_GTPV1_U,
|
||||
TASK_VARIABLE,
|
||||
INSTANCE_DEFAULT,
|
||||
TIMER_PERIODIC,
|
||||
timeoutArg,
|
||||
@@ -406,7 +406,7 @@ static NwGtpv1uRcT gtpv1u_stop_timer_wrapper(
|
||||
|
||||
static void *gtpv1u_thread(void *args)
|
||||
{
|
||||
itti_mark_task_ready(TASK_GTPV1_U);
|
||||
itti_mark_task_ready(TASK_VARIABLE);
|
||||
MSC_START_USE();
|
||||
|
||||
while(1) {
|
||||
@@ -415,7 +415,7 @@ static void *gtpv1u_thread(void *args)
|
||||
* message is sent to the task.
|
||||
*/
|
||||
MessageDef *received_message_p = NULL;
|
||||
itti_receive_msg(TASK_GTPV1_U, &received_message_p);
|
||||
itti_receive_msg(TASK_VARIABLE, &received_message_p);
|
||||
DevAssert(received_message_p != NULL);
|
||||
|
||||
|
||||
@@ -474,7 +474,7 @@ int gtpv1u_init(const mme_config_t *mme_config_p)
|
||||
|
||||
gtpv1u_sgw_data.sgw_ip_address_for_S1u_S12_S4_up = mme_config_p->ipv4.sgw_ip_address_for_S1u_S12_S4_up;
|
||||
|
||||
if (itti_create_task(TASK_GTPV1_U, >pv1u_thread, NULL) < 0) {
|
||||
if (itti_create_task(TASK_VARIABLE, >pv1u_thread, NULL) < 0) {
|
||||
GTPU_ERROR("gtpv1u phtread_create: %s", strerror(errno));
|
||||
return -1;
|
||||
}
|
||||
|
||||
@@ -34,6 +34,7 @@
|
||||
#include <stdio.h>
|
||||
#include <stdlib.h>
|
||||
#include <string.h>
|
||||
#include <openair3/ocp-gtpu/gtp_itf.h>
|
||||
|
||||
#include "NwTypes.h"
|
||||
#include "NwUtils.h"
|
||||
@@ -641,10 +642,7 @@ nwGtpv1uHandleEchoReq(NW_IN NwGtpv1uStackT *thiz,
|
||||
* tool, I saw that there were 6 bytes accessed after bufLen in nwGtpv1uCreateAndSendMsg
|
||||
* the value "16" has been chosen arbitrarily, just bigger than 6
|
||||
*/
|
||||
((NwGtpv1uMsgT*)hMsg)->msgBuf = itti_malloc(
|
||||
TASK_GTPV1_U,
|
||||
TASK_UDP,
|
||||
bufLen + 16 /* CROUX - dirty +16, to be fixed! */);
|
||||
((NwGtpv1uMsgT*)hMsg)->msgBuf = itti_malloc(TASK_VARIABLE, TASK_UDP, bufLen + 16 /* CROUX - dirty +16, to be fixed! */);
|
||||
((NwGtpv1uMsgT*)hMsg)->msgBufLen = bufLen;
|
||||
NW_ASSERT(NW_GTPV1U_OK == rc);
|
||||
|
||||
|
||||
@@ -73,7 +73,7 @@ int create_tasks(uint32_t enb_nb) {
|
||||
rc = itti_create_task(TASK_UDP, udp_eNB_task, NULL);
|
||||
AssertFatal(rc >= 0, "Create task for UDP failed\n");
|
||||
}
|
||||
rc = itti_create_task(TASK_GTPV1_U, gtpv1u_eNB_task, NULL);
|
||||
rc = itti_create_task(TASK_VARIABLE, gtpv1u_eNB_task, NULL);
|
||||
AssertFatal(rc >= 0, "Create task for GTPV1U failed\n");
|
||||
if (is_x2ap_enabled()) {
|
||||
rc = itti_create_task(TASK_X2AP, x2ap_task, NULL);
|
||||
|
||||
@@ -115,7 +115,7 @@ int create_tasks_mbms(uint32_t enb_nb) {
|
||||
// AssertFatal(rc >= 0, "Create task for SCTP failed\n");
|
||||
rc = itti_create_task(TASK_UDP, udp_eNB_task, NULL);
|
||||
AssertFatal(rc >= 0, "Create task for UDP failed\n");
|
||||
rc = itti_create_task(TASK_GTPV1_U, gtpv1u_eNB_task, NULL);
|
||||
rc = itti_create_task(TASK_VARIABLE, gtpv1u_eNB_task, NULL);
|
||||
AssertFatal(rc >= 0, "Create task for GTPV1U failed\n");
|
||||
}
|
||||
///
|
||||
|
||||
Reference in New Issue
Block a user