From 3e7c22e7c6f7027b15a961e6e77b9e5e5ca5b359 Mon Sep 17 00:00:00 2001
From: Laurent THOMAS <laurent.thomas@open-cells.com>
Date: Wed, 26 Jan 2022 11:27:02 +0100
Subject: [PATCH] gtp-u old code delete

---
 cmake_targets/CMakeLists.txt                  |   55 +-
 common/ran_context.h                          |   10 +-
 common/utils/assertions.h                     |   18 +-
 common/utils/lte/ue_power.h                   |   34 -
 common/utils/ocp_itti/intertask_interface.h   |    6 +-
 doc/SW_archi.md                               |    2 +-
 executables/nr-softmodem.c                    |    2 +-
 executables/nr-ue.c                           |    3 +-
 openair1/PHY/TOOLS/lte_enb_scope.c            |    6 -
 openair1/SCHED_NR/vars.h                      |    0
 openair1/SIMULATION/NR_PHY/dlsim.c            |    7 +-
 openair1/SIMULATION/NR_PHY/prachsim.c         |    7 +-
 openair1/SIMULATION/NR_PHY/ulsim.c            |    7 +-
 openair2/COMMON/gtpv1_u_messages_def.h        |   10 +-
 openair2/COMMON/gtpv1_u_messages_types.h      |    8 -
 openair2/ENB_APP/enb_config.c                 |    2 +-
 openair2/F1AP/f1ap_cu_task.c                  |    2 +-
 openair2/F1AP/f1ap_du_task.c                  |    2 +-
 openair2/GNB_APP/gnb_config.c                 |    2 +-
 openair2/LAYER2/PDCP_v10.1.0/pdcp.c           |    5 +-
 openair2/LAYER2/PDCP_v10.1.0/pdcp_fifo.c      |    2 -
 openair2/LAYER2/nr_pdcp/nr_pdcp_oai_api.c     |    4 +-
 openair2/LAYER2/nr_rlc/nr_rlc_oai_api.c       |    2 +-
 openair2/LAYER2/rlc_v2/rlc_oai_api.c          |    2 +-
 openair2/NR_UE_PHY_INTERFACE/NR_IF_Module.c   |    4 +
 openair2/RRC/LTE/rrc_eNB.c                    |   14 -
 openair2/RRC/LTE/rrc_eNB_GTPV1U.c             |    4 +-
 openair2/RRC/LTE/rrc_eNB_S1AP.c               |    1 -
 openair2/RRC/NR/rrc_gNB.c                     |   23 +-
 openair2/RRC/NR/rrc_gNB_NGAP.c                |   13 +-
 openair2/UTIL/MATH/crc_byte.c                 |  185 --
 openair2/UTIL/MATH/random_proto_extern.h      |   30 -
 openair2/UTIL/MATH/taus.c                     |  116 --
 openair3/GTPV1-U/Makefile.am                  |   58 -
 openair3/GTPV1-U/Makefile.eNB                 |   67 -
 openair3/GTPV1-U/gtpv1u.h                     |   55 -
 openair3/GTPV1-U/gtpv1u_eNB.c                 | 1600 -----------------
 openair3/GTPV1-U/gtpv1u_eNB_task.h            |   69 -
 openair3/GTPV1-U/gtpv1u_gNB.c                 | 1012 -----------
 openair3/GTPV1-U/gtpv1u_gNB_defs.h            |  108 --
 openair3/GTPV1-U/gtpv1u_sgw_defs.h            |   97 -
 openair3/GTPV1-U/gtpv1u_teid_pool.c           |   47 -
 openair3/GTPV1-U/nw-gtpv1u/AUTHORS            |    1 -
 openair3/GTPV1-U/nw-gtpv1u/COPYING            |   26 -
 openair3/GTPV1-U/nw-gtpv1u/ChangeLog          |    0
 openair3/GTPV1-U/nw-gtpv1u/NEWS               |    0
 openair3/GTPV1-U/nw-gtpv1u/README             |    0
 .../GTPV1-U/nw-gtpv1u/include/NwGtpv1uLog.h   |   83 -
 .../nw-gtpv1u/include/NwGtpv1uPrivate.h       |  227 ---
 .../GTPV1-U/nw-gtpv1u/include/NwGtpv1uTrxn.h  |   88 -
 .../include/NwGtpv1uTunnelEndPoint.h          |   85 -
 openair3/GTPV1-U/nw-gtpv1u/shared/NwGtpv1u.h  |  562 ------
 .../GTPV1-U/nw-gtpv1u/shared/NwGtpv1uError.h  |   63 -
 .../GTPV1-U/nw-gtpv1u/shared/NwGtpv1uIe.h     |   66 -
 .../GTPV1-U/nw-gtpv1u/shared/NwGtpv1uMsg.h    |  317 ----
 openair3/GTPV1-U/nw-gtpv1u/shared/NwLog.h     |   88 -
 openair3/GTPV1-U/nw-gtpv1u/shared/NwTypes.h   |   78 -
 openair3/GTPV1-U/nw-gtpv1u/shared/NwUtils.h   |   68 -
 openair3/GTPV1-U/nw-gtpv1u/src/NwGtpv1u.c     | 1025 -----------
 openair3/GTPV1-U/nw-gtpv1u/src/NwGtpv1uMsg.c  |  558 ------
 openair3/GTPV1-U/nw-gtpv1u/src/NwGtpv1uTrxn.c |  399 ----
 .../nw-gtpv1u/src/NwGtpv1uTunnelEndPoint.c    |  135 --
 .../GTPV1-U/nw-gtpv1u/test-app/Makefile.am    |    5 -
 .../GTPV1-U/nw-gtpv1u/test-app/Makefile.in    |  461 -----
 .../test-app/nw-helloworld/Makefile.am        |   17 -
 .../test-app/nw-helloworld/Makefile.in        |  433 -----
 .../nw-gtpv1u/test-app/nw-helloworld/NwEvt.h  |   80 -
 .../nw-helloworld/NwMiniLogMgrEntity.c        |   62 -
 .../nw-helloworld/NwMiniLogMgrEntity.h        |   57 -
 .../nw-helloworld/NwMiniTmrMgrEntity.c        |  101 --
 .../nw-helloworld/NwMiniTmrMgrEntity.h        |   53 -
 .../test-app/nw-helloworld/NwMiniUdpEntity.c  |  157 --
 .../test-app/nw-helloworld/NwMiniUdpEntity.h  |   51 -
 .../test-app/nw-helloworld/NwMiniUlpEntity.c  |  309 ----
 .../test-app/nw-helloworld/NwMiniUlpEntity.h  |   64 -
 .../test-app/nw-helloworld/helloworld.c       |  207 ---
 openair3/UDP/udp_eNB_task.c                   |  447 -----
 openair3/UDP/udp_eNB_task.h                   |   97 -
 openair3/ocp-gtpu/gtp_itf.cpp                 |  104 +-
 openair3/ocp-gtpu/gtp_itf.h                   |   31 +-
 .../gtpv1u_eNB_task.h}                        |  110 +-
 .../{GTPV1-U => ocp-gtpu}/gtpv1u_gNB_task.h   |    3 +
 targets/COMMON/create_tasks.c                 |    9 +-
 targets/COMMON/create_tasks_mbms.c            |   39 +-
 targets/COMMON/create_tasks_ue.c              |    1 -
 targets/RT/USER/TOOLS/thread_ipc.h            |   83 -
 86 files changed, 213 insertions(+), 10338 deletions(-)
 delete mode 100644 common/utils/lte/ue_power.h
 delete mode 100644 openair1/SCHED_NR/vars.h
 delete mode 100644 openair2/UTIL/MATH/crc_byte.c
 delete mode 100644 openair2/UTIL/MATH/random_proto_extern.h
 delete mode 100644 openair2/UTIL/MATH/taus.c
 delete mode 100644 openair3/GTPV1-U/Makefile.am
 delete mode 100644 openair3/GTPV1-U/Makefile.eNB
 delete mode 100644 openair3/GTPV1-U/gtpv1u.h
 delete mode 100644 openair3/GTPV1-U/gtpv1u_eNB.c
 delete mode 100644 openair3/GTPV1-U/gtpv1u_eNB_task.h
 delete mode 100644 openair3/GTPV1-U/gtpv1u_gNB.c
 delete mode 100644 openair3/GTPV1-U/gtpv1u_gNB_defs.h
 delete mode 100644 openair3/GTPV1-U/gtpv1u_sgw_defs.h
 delete mode 100644 openair3/GTPV1-U/gtpv1u_teid_pool.c
 delete mode 100644 openair3/GTPV1-U/nw-gtpv1u/AUTHORS
 delete mode 100644 openair3/GTPV1-U/nw-gtpv1u/COPYING
 delete mode 100644 openair3/GTPV1-U/nw-gtpv1u/ChangeLog
 delete mode 100644 openair3/GTPV1-U/nw-gtpv1u/NEWS
 delete mode 100644 openair3/GTPV1-U/nw-gtpv1u/README
 delete mode 100644 openair3/GTPV1-U/nw-gtpv1u/include/NwGtpv1uLog.h
 delete mode 100644 openair3/GTPV1-U/nw-gtpv1u/include/NwGtpv1uPrivate.h
 delete mode 100644 openair3/GTPV1-U/nw-gtpv1u/include/NwGtpv1uTrxn.h
 delete mode 100644 openair3/GTPV1-U/nw-gtpv1u/include/NwGtpv1uTunnelEndPoint.h
 delete mode 100644 openair3/GTPV1-U/nw-gtpv1u/shared/NwGtpv1u.h
 delete mode 100644 openair3/GTPV1-U/nw-gtpv1u/shared/NwGtpv1uError.h
 delete mode 100644 openair3/GTPV1-U/nw-gtpv1u/shared/NwGtpv1uIe.h
 delete mode 100644 openair3/GTPV1-U/nw-gtpv1u/shared/NwGtpv1uMsg.h
 delete mode 100644 openair3/GTPV1-U/nw-gtpv1u/shared/NwLog.h
 delete mode 100644 openair3/GTPV1-U/nw-gtpv1u/shared/NwTypes.h
 delete mode 100644 openair3/GTPV1-U/nw-gtpv1u/shared/NwUtils.h
 delete mode 100644 openair3/GTPV1-U/nw-gtpv1u/src/NwGtpv1u.c
 delete mode 100644 openair3/GTPV1-U/nw-gtpv1u/src/NwGtpv1uMsg.c
 delete mode 100644 openair3/GTPV1-U/nw-gtpv1u/src/NwGtpv1uTrxn.c
 delete mode 100644 openair3/GTPV1-U/nw-gtpv1u/src/NwGtpv1uTunnelEndPoint.c
 delete mode 100644 openair3/GTPV1-U/nw-gtpv1u/test-app/Makefile.am
 delete mode 100644 openair3/GTPV1-U/nw-gtpv1u/test-app/Makefile.in
 delete mode 100644 openair3/GTPV1-U/nw-gtpv1u/test-app/nw-helloworld/Makefile.am
 delete mode 100644 openair3/GTPV1-U/nw-gtpv1u/test-app/nw-helloworld/Makefile.in
 delete mode 100644 openair3/GTPV1-U/nw-gtpv1u/test-app/nw-helloworld/NwEvt.h
 delete mode 100644 openair3/GTPV1-U/nw-gtpv1u/test-app/nw-helloworld/NwMiniLogMgrEntity.c
 delete mode 100644 openair3/GTPV1-U/nw-gtpv1u/test-app/nw-helloworld/NwMiniLogMgrEntity.h
 delete mode 100644 openair3/GTPV1-U/nw-gtpv1u/test-app/nw-helloworld/NwMiniTmrMgrEntity.c
 delete mode 100644 openair3/GTPV1-U/nw-gtpv1u/test-app/nw-helloworld/NwMiniTmrMgrEntity.h
 delete mode 100644 openair3/GTPV1-U/nw-gtpv1u/test-app/nw-helloworld/NwMiniUdpEntity.c
 delete mode 100644 openair3/GTPV1-U/nw-gtpv1u/test-app/nw-helloworld/NwMiniUdpEntity.h
 delete mode 100644 openair3/GTPV1-U/nw-gtpv1u/test-app/nw-helloworld/NwMiniUlpEntity.c
 delete mode 100644 openair3/GTPV1-U/nw-gtpv1u/test-app/nw-helloworld/NwMiniUlpEntity.h
 delete mode 100644 openair3/GTPV1-U/nw-gtpv1u/test-app/nw-helloworld/helloworld.c
 delete mode 100644 openair3/UDP/udp_eNB_task.c
 delete mode 100644 openair3/UDP/udp_eNB_task.h
 rename openair3/{GTPV1-U/gtpv1u_eNB_defs.h => ocp-gtpu/gtpv1u_eNB_task.h} (61%)
 rename openair3/{GTPV1-U => ocp-gtpu}/gtpv1u_gNB_task.h (94%)
 delete mode 100644 targets/RT/USER/TOOLS/thread_ipc.h

diff --git a/cmake_targets/CMakeLists.txt b/cmake_targets/CMakeLists.txt
index f2eda66fc0e..ff6169b7043 100644
--- a/cmake_targets/CMakeLists.txt
+++ b/cmake_targets/CMakeLists.txt
@@ -1019,7 +1019,6 @@ add_boolean_option(TRACE_RLC_UM_TX_STATUS  False "TRACE for RLC UM, TO BE CHANGE
 ##########################
 #add_boolean_option(LINK_ENB_PDCP_TO_IP_DRIVER  False "For eNB, PDCP communicate with a IP driver")
 #add_boolean_option(LINK_ENB_PDCP_TO_GTPV1U     True  "For eNB, PDCP communicate with GTP-U protocol (eNB<->S-GW)")
-add_definitions(-DNEW_GTPU=1)
 
 ##########################
 # RRC LAYER OPTIONS
@@ -1097,8 +1096,7 @@ include_directories("${OPENAIR3_DIR}/S1AP")
 include_directories("${OPENAIR2_DIR}/X2AP")
 include_directories("${OPENAIR2_DIR}/M2AP")
 include_directories("${OPENAIR2_DIR}/F1AP")
-include_directories("${OPENAIR3_DIR}/UDP")
-include_directories("${OPENAIR3_DIR}/GTPV1-U")
+include_directories("${OPENAIR3_DIR}/ocp-gtpu")
 include_directories("${OPENAIR3_DIR}/M3AP")
 include_directories("${OPENAIR3_DIR}/MME_APP")
 include_directories("${OPENAIR_DIR}/targets/COMMON")
@@ -1124,8 +1122,6 @@ include_directories("${OPENAIR2_DIR}/UTIL/CLI")
 include_directories("${OPENAIR2_DIR}/UTIL/OPT")
 include_directories("${OPENAIR2_DIR}/UTIL/OMV")
 include_directories("${OPENAIR2_DIR}/RRC/LTE/MESSAGES")
-include_directories("${OPENAIR3_DIR}/GTPV1-U/nw-gtpv1u/shared")
-include_directories("${OPENAIR3_DIR}/GTPV1-U/nw-gtpv1u/include")
 include_directories("${OPENAIR_DIR}")
 
 # Utilities Library
@@ -2158,7 +2154,6 @@ add_library(L2_NR
   ${MAC_NR_SRC}
   ${GNB_APP_SRC}
   )
-target_compile_definitions(L2_NR PUBLIC NEW_GTPU)
 
 add_library(L2_LTE_NR
   ${L2_RRC_SRC}
@@ -2166,7 +2161,6 @@ add_library(L2_LTE_NR
   ${ENB_APP_SRC}
   ${MCE_APP_SRC}
 )
-target_compile_definitions(L2_LTE_NR PUBLIC NEW_GTPU)
 
 add_dependencies(L2_NR rrc_flag nr_rrc_flag s1ap_flag x2_flag)
 
@@ -2207,32 +2201,14 @@ add_library(CN_UTILS
   ${OPENAIR3_DIR}/UTILS/mcc_mnc_itu.c
   )
 
-set(GTPV1U_DIR ${OPENAIR3_DIR}/GTPV1-U)
-
-add_library (GTPV1U_OCP
+add_library (GTPV1U
   ${NR_RRC_DIR}/rrc_gNB_GTPV1U.c
   ${RRC_DIR}/rrc_eNB_GTPV1U.c
   ${OPENAIR3_DIR}/ocp-gtpu/gtp_itf.cpp
   )
-target_compile_definitions(GTPV1U_OCP PUBLIC NEW_GTPU)
-add_dependencies(GTPV1U_OCP rrc_flag)
+add_dependencies(GTPV1U rrc_flag)
 include_directories(${OPENAIR3_DIR}/ocp-gtp)
 
-#NR case
-set (NR_GTPV1U_SRC
-  ${NR_RRC_DIR}/rrc_gNB_GTPV1U.c
-  ${RRC_DIR}/rrc_eNB_GTPV1U.c
-  ${GTPV1U_DIR}/gtpv1u_eNB.c
-  ${GTPV1U_DIR}/gtpv1u_gNB.c
-  ${GTPV1U_DIR}/nw-gtpv1u/src/NwGtpv1uTunnelEndPoint.c
-  ${GTPV1U_DIR}/nw-gtpv1u/src/NwGtpv1uTrxn.c
-  ${GTPV1U_DIR}/nw-gtpv1u/src/NwGtpv1uMsg.c
-  ${GTPV1U_DIR}/nw-gtpv1u/src/NwGtpv1u.c
-  ${GTPV1U_DIR}/gtpv1u_teid_pool.c
-  )
-add_library(NR_GTPV1U ${NR_GTPV1U_SRC})
-add_dependencies(NR_GTPV1U rrc_flag)
-
 set (MME_APP_SRC
   ${OPENAIR3_DIR}/MME_APP/mme_app.c
   ${OPENAIR3_DIR}/MME_APP/mme_config.c
@@ -2248,9 +2224,6 @@ set(SCTP_SRC
 add_library(SCTP_CLIENT ${SCTP_SRC})
 add_dependencies(SCTP_CLIENT rrc_flag)
 
-add_library(UDP ${OPENAIR3_DIR}/UDP/udp_eNB_task.c)
-add_dependencies(UDP rrc_flag)
-
 set(NAS_SRC ${OPENAIR3_DIR}/NAS/)
 set(libnas_api_OBJS
   ${NAS_SRC}COMMON/API/NETWORK/as_message.c
@@ -2805,7 +2778,7 @@ add_dependencies(lte-softmodem rrc_flag s1ap_flag x2_flag oai_iqplayer)
 
 target_link_libraries (lte-softmodem
   -Wl,--start-group
-  RRC_LIB NR_RRC_LIB S1AP_LIB S1AP_ENB M2AP_LIB M2AP_ENB X2AP_LIB X2AP_ENB M3AP_LIB M3AP_ENB GTPV1U_OCP F1AP_LIB F1AP SECU_CN SECU_OSA UTIL HASHTABLE SCTP_CLIENT MME_APP UDP SCHED_LIB SCHED_RU_LIB
+  RRC_LIB NR_RRC_LIB S1AP_LIB S1AP_ENB M2AP_LIB M2AP_ENB X2AP_LIB X2AP_ENB M3AP_LIB M3AP_ENB GTPV1U F1AP_LIB F1AP SECU_CN SECU_OSA UTIL HASHTABLE SCTP_CLIENT MME_APP SCHED_LIB SCHED_RU_LIB
   PHY_COMMON PHY PHY_RU LFDS L2 L2_LTE NFAPI_COMMON_LIB NFAPI_LIB NFAPI_VNF_LIB NFAPI_PNF_LIB NFAPI_USER_LIB MISC_NFAPI_LTE_LIB LFDS7
   ${MSC_LIB} ${RAL_LIB} ${NAS_UE_LIB} ITTI ${FLPT_MSG_LIB} ${ASYNC_IF_LIB} ${FLEXRAN_AGENT_LIB} ${FSPT_MSG_LIB} ${PROTO_AGENT_LIB}
   -Wl,--end-group z dl)
@@ -2849,7 +2822,7 @@ add_dependencies(ocp-enb rrc_flag s1ap_flag x2_flag oai_iqplayer coding params_l
 target_link_libraries (ocp-enb
   -Wl,--start-group
 
-  RRC_LIB NR_RRC_LIB S1AP_LIB S1AP_ENB F1AP_LIB F1AP M2AP_LIB M2AP_ENB X2AP_LIB X2AP_ENB M3AP_LIB M3AP_ENB GTPV1U_OCP SECU_CN SECU_OSA UTIL HASHTABLE SCTP_CLIENT MME_APP UDP SCHED_LIB SCHED_RU_LIB
+  RRC_LIB NR_RRC_LIB S1AP_LIB S1AP_ENB F1AP_LIB F1AP M2AP_LIB M2AP_ENB X2AP_LIB X2AP_ENB M3AP_LIB M3AP_ENB GTPV1U SECU_CN SECU_OSA UTIL HASHTABLE SCTP_CLIENT MME_APP SCHED_LIB SCHED_RU_LIB
   PHY_COMMON PHY PHY_RU LFDS L2 L2_LTE NFAPI_COMMON_LIB NFAPI_LIB MISC_NFAPI_LTE_LIB NFAPI_VNF_LIB NFAPI_PNF_LIB NFAPI_USER_LIB LFDS7 SIMU_COMMON
   ${MSC_LIB} ${RAL_LIB} ${NAS_UE_LIB} ITTI ${FLPT_MSG_LIB} ${ASYNC_IF_LIB} ${FLEXRAN_AGENT_LIB} ${FSPT_MSG_LIB} ${PROTO_AGENT_LIB}
   -Wl,--end-group z dl)
@@ -2943,7 +2916,7 @@ endif()
 target_link_libraries (lte-uesoftmodem
   -Wl,--start-group
   RRC_LIB NR_RRC_LIB S1AP_LIB S1AP_ENB X2AP_LIB X2AP_ENB M2AP_LIB M2AP_ENB M3AP_LIB M3AP_ENB
-  SECU_CN SECU_OSA UTIL HASHTABLE SCTP_CLIENT MME_APP UDP SCHED_RU_LIB SCHED_UE_LIB PHY_COMMON
+  SECU_CN SECU_OSA UTIL HASHTABLE SCTP_CLIENT MME_APP SCHED_RU_LIB SCHED_UE_LIB PHY_COMMON
   PHY_UE PHY_RU LFDS L2_UE L2_LTE LFDS7 SIMU_COMMON SIMU NFAPI_COMMON_LIB NFAPI_LIB NFAPI_PNF_LIB NFAPI_USER_LIB MISC_NFAPI_LTE_LIB
   ${MSC_LIB} ${RAL_LIB} ${NAS_UE_LIB} ITTI ${FLPT_MSG_LIB} ${ASYNC_IF_LIB} ${ATLAS_LIBRARIES}
   -Wl,--end-group z dl)
@@ -2985,10 +2958,9 @@ add_executable(nr-softmodem
   ${OPENAIR2_DIR}/ENB_APP/flexran_agent_ran_api_to_fix.c
   )
 
-target_compile_definitions(nr-softmodem PUBLIC NEW_GTPU)
 target_link_libraries (nr-softmodem
   -Wl,--start-group
-  UTIL HASHTABLE SCTP_CLIENT UDP SCHED_LIB SCHED_RU_LIB SCHED_NR_LIB PHY_NR PHY PHY_COMMON PHY_NR_COMMON PHY_RU LFDS GTPV1U_OCP SECU_CN SECU_OSA
+  UTIL HASHTABLE SCTP_CLIENT SCHED_LIB SCHED_RU_LIB SCHED_NR_LIB PHY_NR PHY PHY_COMMON PHY_NR_COMMON PHY_RU LFDS GTPV1U SECU_CN SECU_OSA
   ITTI ${FLPT_MSG_LIB} ${ASYNC_IF_LIB} ${FLEXRAN_AGENT_LIB} LFDS7 ${MSC_LIB} ${RAL_LIB} ${NAS_UE_LIB} RRC_LIB NR_RRC_LIB
   NGAP_LIB NGAP_GNB S1AP_LIB S1AP_ENB L2_LTE_NR L2_NR MAC_NR_COMMON NFAPI_COMMON_LIB NFAPI_LIB NFAPI_VNF_LIB NFAPI_PNF_LIB NFAPI_USER_LIB
   X2AP_LIB X2AP_ENB F1AP_LIB F1AP M2AP_LIB M2AP_ENB M3AP_LIB M3AP_ENB ${PROTO_AGENT_LIB} ${FSPT_MSG_LIB}
@@ -3028,7 +3000,7 @@ add_executable(ocp-gnb
 
 target_link_libraries (ocp-gnb
   -Wl,--start-group
-  UTIL HASHTABLE SCTP_CLIENT UDP SCHED_LIB SCHED_RU_LIB SCHED_NR_LIB PHY_NR PHY PHY_COMMON PHY_NR_COMMON PHY_RU LFDS GTPV1U_OCP SECU_CN SECU_OSA
+  UTIL HASHTABLE SCTP_CLIENT SCHED_LIB SCHED_RU_LIB SCHED_NR_LIB PHY_NR PHY PHY_COMMON PHY_NR_COMMON PHY_RU LFDS GTPV1U SECU_CN SECU_OSA
   ITTI ${FLPT_MSG_LIB} ${ASYNC_IF_LIB} LFDS7 ${MSC_LIB} ${RAL_LIB} ${NAS_UE_LIB} RRC_LIB NR_RRC_LIB
   NGAP_LIB NGAP_GNB S1AP_LIB S1AP_ENB L2_LTE_NR L2_NR MAC_NR_COMMON NFAPI_COMMON_LIB NFAPI_LIB NFAPI_VNF_LIB NFAPI_PNF_LIB NFAPI_USER_LIB
   X2AP_LIB X2AP_ENB F1AP_LIB F1AP M2AP_LIB M2AP_ENB M3AP_LIB M3AP_ENB SIMU_COMMON
@@ -3072,7 +3044,7 @@ add_executable(nr-uesoftmodem
 
 target_link_libraries (nr-uesoftmodem
   -Wl,--start-group
-  RRC_LIB NR_RRC_LIB NGAP_LIB NGAP_GNB SECU_CN SECU_OSA UTIL HASHTABLE SCTP_CLIENT UDP SCHED_RU_LIB SCHED_UE_LIB SCHED_NR_UE_LIB
+  RRC_LIB NR_RRC_LIB NGAP_LIB NGAP_GNB SECU_CN SECU_OSA UTIL HASHTABLE SCTP_CLIENT SCHED_RU_LIB SCHED_UE_LIB SCHED_NR_UE_LIB
   PHY_COMMON PHY_NR_COMMON PHY_UE PHY_NR_UE PHY_RU LFDS NR_L2_UE L2_UE_LTE_NR MAC_NR_COMMON NFAPI_COMMON_LIB NFAPI_LIB NFAPI_PNF_LIB
   NFAPI_USER_LIB MISC_NFAPI_NR_LIB S1AP_LIB S1AP_ENB
   ${MSC_LIB} ${RAL_LIB} ${NAS_UE_LIB} ITTI ${FLPT_MSG_LIB} ${ASYNC_IF_LIB} LFDS7 ${ATLAS_LIBRARIES}
@@ -3326,7 +3298,7 @@ add_executable(test_epc_generate_scenario
   ${OPENAIR3_DIR}/S1AP/s1ap_eNB_defs.h
   )
 target_link_libraries (test_epc_generate_scenario
-  -Wl,--start-group RRC_LIB S1AP_LIB S1AP_ENB X2AP_LIB X2AP_ENB M2AP_LIB M2AP_ENB M3AP_LIB M3AP_ENB F1AP_LIB F1AP GTPV1U_OCP LIB_NAS_UE SECU_CN UTIL HASHTABLE SCTP_CLIENT MME_APP UDP SCHED_LIB PHY LFDS ITTI ${MSC_LIB} L2 -Wl,--end-group pthread m rt crypt sctp ${LIBXML2_LIBRARIES} ${LIBXSLT_LIBRARIES} ${CRYPTO_LIBRARIES} ${OPENSSL_LIBRARIES} ${CONFIG_LIB}
+  -Wl,--start-group RRC_LIB S1AP_LIB S1AP_ENB X2AP_LIB X2AP_ENB M2AP_LIB M2AP_ENB M3AP_LIB M3AP_ENB F1AP_LIB F1AP GTPV1U LIB_NAS_UE SECU_CN UTIL HASHTABLE SCTP_CLIENT MME_APP SCHED_LIB PHY LFDS ITTI ${MSC_LIB} L2 -Wl,--end-group pthread m rt crypt sctp ${LIBXML2_LIBRARIES} ${LIBXSLT_LIBRARIES} ${CRYPTO_LIBRARIES} ${OPENSSL_LIBRARIES} ${CONFIG_LIB}
   )
 
 add_executable(test_epc_play_scenario
@@ -3345,7 +3317,7 @@ add_executable(test_epc_play_scenario
   )
 target_include_directories(test_epc_play_scenario PUBLIC /usr/local/share/asn1c)
 target_link_libraries (test_epc_play_scenario
-  -Wl,--start-group RRC_LIB S1AP_LIB X2AP_LIB X2AP_ENB M3AP_LIB M3AP_ENB F1AP_LIB F1AP GTPV1U_OCP LIB_NAS_UE SECU_CN UTIL HASHTABLE SCTP_CLIENT MME_APP UDP SCHED_LIB PHY_NR_COMMON PHY_COMMON PHY PHY_UE LFDS ITTI ${MSC_LIB} -Wl,--end-group pthread m rt crypt sctp ${LIBXML2_LIBRARIES} ${LIBXSLT_LIBRARIES} ${CRYPTO_LIBRARIES} ${OPENSSL_LIBRARIES} ${CONFIG_LIB}
+  -Wl,--start-group RRC_LIB S1AP_LIB X2AP_LIB X2AP_ENB M3AP_LIB M3AP_ENB F1AP_LIB F1AP GTPV1U LIB_NAS_UE SECU_CN UTIL HASHTABLE SCTP_CLIENT MME_APP SCHED_LIB PHY_NR_COMMON PHY_COMMON PHY PHY_UE LFDS ITTI ${MSC_LIB} -Wl,--end-group pthread m rt crypt sctp ${LIBXML2_LIBRARIES} ${LIBXSLT_LIBRARIES} ${CRYPTO_LIBRARIES} ${OPENSSL_LIBRARIES} ${CONFIG_LIB}
   )
 
 
@@ -3391,7 +3363,7 @@ if (${T_TRACER})
         NFAPI_COMMON_LIB NFAPI_LIB NFAPI_PNF_LIB NFAPI_VNF_LIB NFAPI_USER_LIB
         PHY_COMMON PHY PHY_UE PHY_NR PHY_NR_COMMON PHY_NR_UE PHY_RU PHY_MEX
         L2 L2_LTE L2_NR L2_LTE_NR L2_UE NR_L2_UE L2_UE_LTE_NR MAC_NR_COMMON MAC_NR MAC_UE_NR NGAP_GNB
-        CN_UTILS GTPV1U_OCP GTPV1U_OCP SCTP_CLIENT MME_APP UDP LIB_NAS_UE NB_IoT LFDS LFDS7 SIMU_COMMON SIMU SIMU_ETH OPENAIR0_LIB
+        CN_UTILS GTPV1U SCTP_CLIENT MME_APP LIB_NAS_UE NB_IoT LFDS LFDS7 SIMU_COMMON SIMU SIMU_ETH OPENAIR0_LIB
         ldpc_orig ldpc_optim ldpc_optim8seg ldpc PROTO_AGENT dfts)
     if (TARGET ${i})
       add_dependencies(${i} generate_T)
@@ -3496,11 +3468,10 @@ add_executable(nr-ittisim
   ${CONFIG_SOURCES}
   ${SHLIB_LOADER_SOURCES}
   )
-target_compile_definitions(nr-ittisim PUBLIC NEW_GTPU)
 
 target_link_libraries (nr-ittisim
   -Wl,--start-group
-  UTIL HASHTABLE SCTP_CLIENT UDP SCHED_LIB SCHED_RU_LIB SCHED_NR_LIB PHY_NR PHY PHY_COMMON PHY_NR_COMMON PHY_RU LFDS GTPV1U_OCP SECU_CN SECU_OSA
+  UTIL HASHTABLE SCTP_CLIENT SCHED_LIB SCHED_RU_LIB SCHED_NR_LIB PHY_NR PHY PHY_COMMON PHY_NR_COMMON PHY_RU LFDS GTPV1U SECU_CN SECU_OSA
   ITTI ${FLPT_MSG_LIB} ${ASYNC_IF_LIB} ${FLEXRAN_AGENT_LIB} LFDS7 ${MSC_LIB} ${RAL_LIB} ${NAS_SIM_LIB} RRC_LIB NR_RRC_LIB
   NGAP_LIB NGAP_GNB S1AP_LIB S1AP_ENB L2_LTE_NR L2_NR MAC_NR_COMMON NFAPI_COMMON_LIB NFAPI_LIB NFAPI_VNF_LIB NFAPI_PNF_LIB NFAPI_USER_LIB
   X2AP_LIB X2AP_ENB F1AP_LIB F1AP M2AP_LIB M2AP_ENB M3AP_LIB M3AP_ENB ${PROTO_AGENT_LIB} ${FSPT_MSG_LIB}
diff --git a/common/ran_context.h b/common/ran_context.h
index db981e9182f..055c6f783e5 100644
--- a/common/ran_context.h
+++ b/common/ran_context.h
@@ -42,17 +42,11 @@
 //#include "ENB_APP/enb_config.h"
 #include "flexran_agent_defs.h"
 
-#include "gtpv1u.h"
-#include "NwGtpv1u.h"
-#include "NwGtpv1uMsg.h"
-#include "NwGtpv1uPrivate.h"
-#include "gtpv1u_eNB_defs.h"
-#include "gtpv1u_gNB_defs.h"
-
 #include "PHY/defs_L1_NB_IoT.h"
 #include "RRC/LTE/defs_NB_IoT.h"
 #include "RRC/LTE/rrc_defs.h"
 #include "RRC/NR/nr_rrc_defs.h"
+#include <openair3/ocp-gtpu/gtpv1u_eNB_task.h>
 
 
 typedef struct {
@@ -110,8 +104,6 @@ typedef struct {
   struct gNB_MAC_INST_s **nrmac;
   /// GTPu descriptor 
   gtpv1u_data_t *gtpv1u_data_g;
-  /// NR GTPu descriptor 
-  nr_gtpv1u_data_t *nr_gtpv1u_data_g;
   /// RU descriptors. These describe what each radio unit is supposed to do and contain the necessary functions for fronthaul interfaces
   struct RU_t_s **ru;
   /// Mask to indicate fronthaul setup status of RU (hard-limit to 64 RUs)
diff --git a/common/utils/assertions.h b/common/utils/assertions.h
index d85dab79a0c..57c50a65e06 100644
--- a/common/utils/assertions.h
+++ b/common/utils/assertions.h
@@ -25,14 +25,22 @@
 #include <stdio.h>
 #include <stdlib.h>
 #include <inttypes.h>
+#include <sys/types.h>
+#include <unistd.h>
 #include <platform_types.h>
 #include "backtrace.h"
 
-#define _Assert_Exit_                           \
-    fprintf(stderr, "\nExiting execution\n");   \
-    fflush(stdout);                             \
-    fflush(stderr);                             \
-    abort();
+#define _Assert_Exit_							\
+  if (getenv("gdbStacks")) {						\
+    char tmp [1000];							\
+    sprintf(tmp,"gdb -ex='set confirm off' -ex 'thread apply all bt' -ex q -p %d > /tmp/full_stacks.%d < /dev/null", \
+	    getpid(), getpid());					\
+    system(tmp);							\
+  }									\
+  fprintf(stderr, "\nExiting execution\n");				\
+  fflush(stdout);							\
+  fflush(stderr);							\
+  abort();
 
 #define _Assert_(cOND, aCTION, fORMAT, aRGS...)             \
 do {                                                        \
diff --git a/common/utils/lte/ue_power.h b/common/utils/lte/ue_power.h
deleted file mode 100644
index caeebec2c8f..00000000000
--- a/common/utils/lte/ue_power.h
+++ /dev/null
@@ -1,34 +0,0 @@
-/*
- * Licensed to the OpenAirInterface (OAI) Software Alliance under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The OpenAirInterface Software Alliance licenses this file to You under
- * the OAI Public License, Version 1.1  (the "License"); you may not use this file
- * except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.openairinterface.org/?page_id=698
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- *-------------------------------------------------------------------------------
- * For more information about the OpenAirInterface (OAI) Software Alliance:
- *      contact@openairinterface.org
- */
-
-/*! \file ue_power.h
-* \brief support routines used in MAC and PHY 
-* \author R. Knopp, F. Kaltenberger
-* \date 2020
-* \version 0.1
-* \company Eurecom
-* \email: knopp@eurecom.fr,florian.kaltenberger@eurecom.fr
-* \note
-* \warning
-*/
-
-int16_t estimate_ue_tx_power(int norm,uint32_t tbs, uint32_t nb_rb, uint8_t control_only, lte_prefix_type_t ncp, uint8_t use_srs);
-
diff --git a/common/utils/ocp_itti/intertask_interface.h b/common/utils/ocp_itti/intertask_interface.h
index 3188e5889f0..5ea2e0f87a9 100644
--- a/common/utils/ocp_itti/intertask_interface.h
+++ b/common/utils/ocp_itti/intertask_interface.h
@@ -256,8 +256,8 @@ typedef struct IttiMsgText_s {
 #include <openair3/MME_APP/mme_app.h>
 //#include <proto.h>
 
-#include <openair3/GTPV1-U/gtpv1u_eNB_task.h>
-#include <openair3/GTPV1-U/gtpv1u_gNB_task.h>
+#include <openair3/ocp-gtpu/gtpv1u_eNB_task.h>
+#include <openair3/ocp-gtpu/gtpv1u_gNB_task.h>
 void *rrc_enb_process_itti_msg(void *);
 #include <openair3/SCTP/sctp_eNB_task.h>
 #include <openair3/NGAP/ngap_gNB.h>
@@ -340,8 +340,6 @@ void *rrc_enb_process_msg(void *);
   TASK_DEF(TASK_RAL_UE,   TASK_PRIORITY_MED,  200, NULL, NULL)  \
   TASK_DEF(TASK_MSC,      TASK_PRIORITY_MED,  200, NULL, NULL)\
   TASK_DEF(TASK_GTPV1_U,  TASK_PRIORITY_MED,  1000,NULL, NULL)\
-  TASK_DEF(OCP_GTPV1_U,  TASK_PRIORITY_MED,  1000,NULL, NULL)\
-  TASK_DEF(TASK_UDP,      TASK_PRIORITY_MED,  1000, NULL, NULL)\
   TASK_DEF(TASK_CU_F1,    TASK_PRIORITY_MED,  200, NULL, NULL) \
   TASK_DEF(TASK_DU_F1,    TASK_PRIORITY_MED,  200, NULL, NULL) \
   TASK_DEF(TASK_RRC_UE_SIM,   TASK_PRIORITY_MED,  200, NULL, NULL)  \
diff --git a/doc/SW_archi.md b/doc/SW_archi.md
index 0e77cfa580a..7648fb2e167 100644
--- a/doc/SW_archi.md
+++ b/doc/SW_archi.md
@@ -369,7 +369,7 @@ gtpv1u_create_s1u_tunnel(), delete tunnel, ... functions are called inside the o
 # New GTP
 ## initialization
 
-ocp_gtpv1uTask(): this creates only the thread, doesn't configure anything
+gtpv1uTask(): this creates only the thread, doesn't configure anything
 gtpv1Init(): creates a listening socket to Linux for a given reception and select a local IP address
 
 ## newGtpuCreateTunnel()   
diff --git a/executables/nr-softmodem.c b/executables/nr-softmodem.c
index 5f579196455..184b9caa8fb 100644
--- a/executables/nr-softmodem.c
+++ b/executables/nr-softmodem.c
@@ -365,7 +365,7 @@ int create_gNB_tasks(uint32_t gnb_nb) {
 
     //Use check on x2ap to consider the NSA scenario and check on AMF_MODE_ENABLED for the SA scenario
     if(is_x2ap_enabled() || AMF_MODE_ENABLED) {
-      if (itti_create_task (TASK_GTPV1_U, &nr_gtpv1u_gNB_task, NULL) < 0) {
+      if (itti_create_task (TASK_GTPV1_U, &gtpv1uTask, NULL) < 0) {
         LOG_E(GTPU, "Create task for GTPV1U failed\n");
         return -1;
       }
diff --git a/executables/nr-ue.c b/executables/nr-ue.c
index 2e7b2ea0e15..71f99f543db 100644
--- a/executables/nr-ue.c
+++ b/executables/nr-ue.c
@@ -18,7 +18,8 @@
  * For more information about the OpenAirInterface (OAI) Software Alliance:
  *      contact@openairinterface.org
  */
-
+#define _GNU_SOURCE 
+#include <pthread.h>
 #include <openair1/PHY/impl_defs_top.h>
 #include "executables/nr-uesoftmodem.h"
 #include "PHY/phy_extern_nr_ue.h"
diff --git a/openair1/PHY/TOOLS/lte_enb_scope.c b/openair1/PHY/TOOLS/lte_enb_scope.c
index 7fde9f244c0..0e873addbcf 100644
--- a/openair1/PHY/TOOLS/lte_enb_scope.c
+++ b/openair1/PHY/TOOLS/lte_enb_scope.c
@@ -49,12 +49,6 @@ void reset_stats(FL_OBJECT *button, long arg) {
   int i,j,k;
   PHY_VARS_eNB *phy_vars_eNB = RC.eNB[0][0];
 
-  printf("XXX %d %d %d\n",
-	 sizeofArray(phy_vars_eNB->UE_stats),
-	 sizeofArray( phy_vars_eNB->UE_stats[i].dlsch_NAK),
-	 sizeofArray( *phy_vars_eNB->UE_stats[i].dlsch_NAK)
-	 );
- 
   for (i=0; i<sizeofArray(phy_vars_eNB->UE_stats); i++) {
     for (k=0; k<sizeofArray(phy_vars_eNB->UE_stats[i].dlsch_NAK); k++) { //harq_processes
       for (j=0; j<sizeofArray(*phy_vars_eNB->UE_stats[i].dlsch_NAK); j++) {
diff --git a/openair1/SCHED_NR/vars.h b/openair1/SCHED_NR/vars.h
deleted file mode 100644
index e69de29bb2d..00000000000
diff --git a/openair1/SIMULATION/NR_PHY/dlsim.c b/openair1/SIMULATION/NR_PHY/dlsim.c
index 6a2aba59443..2a4fdf64d24 100644
--- a/openair1/SIMULATION/NR_PHY/dlsim.c
+++ b/openair1/SIMULATION/NR_PHY/dlsim.c
@@ -175,7 +175,12 @@ gtpv1u_update_ngu_tunnel(
   return 0;
 }
 
-int ocp_gtpv1u_delete_s1u_tunnel(const instance_t instance, const gtpv1u_enb_delete_tunnel_req_t *const req_pP) {
+int gtpv1u_delete_s1u_tunnel(const instance_t instance, const gtpv1u_enb_delete_tunnel_req_t *const req_pP) {
+  return 0;
+}
+
+int gtpv1u_delete_ngu_tunnel( const instance_t instance,
+			      gtpv1u_gnb_delete_tunnel_req_t *req) {
   return 0;
 }
 
diff --git a/openair1/SIMULATION/NR_PHY/prachsim.c b/openair1/SIMULATION/NR_PHY/prachsim.c
index fb0f37d7ac6..d7c29e8ff39 100644
--- a/openair1/SIMULATION/NR_PHY/prachsim.c
+++ b/openair1/SIMULATION/NR_PHY/prachsim.c
@@ -143,7 +143,12 @@ gtpv1u_update_ngu_tunnel(
   return 0;
 }
 
-int ocp_gtpv1u_delete_s1u_tunnel(const instance_t instance, const gtpv1u_enb_delete_tunnel_req_t *const req_pP) {
+int gtpv1u_delete_s1u_tunnel(const instance_t instance, const gtpv1u_enb_delete_tunnel_req_t *const req_pP) {
+  return 0;
+}
+
+int gtpv1u_delete_ngu_tunnel( const instance_t instance,
+			      gtpv1u_gnb_delete_tunnel_req_t *req) {
   return 0;
 }
 
diff --git a/openair1/SIMULATION/NR_PHY/ulsim.c b/openair1/SIMULATION/NR_PHY/ulsim.c
index ac991ae940c..b296b6ef368 100644
--- a/openair1/SIMULATION/NR_PHY/ulsim.c
+++ b/openair1/SIMULATION/NR_PHY/ulsim.c
@@ -139,7 +139,12 @@ gtpv1u_create_s1u_tunnel(
   return 0;
 }
 
-int ocp_gtpv1u_delete_s1u_tunnel(const instance_t instance, const gtpv1u_enb_delete_tunnel_req_t *const req_pP) {
+int gtpv1u_delete_s1u_tunnel(const instance_t instance, const gtpv1u_enb_delete_tunnel_req_t *const req_pP) {
+  return 0;
+}
+
+int gtpv1u_delete_ngu_tunnel( const instance_t instance,
+			      gtpv1u_gnb_delete_tunnel_req_t *req) {
   return 0;
 }
 
diff --git a/openair2/COMMON/gtpv1_u_messages_def.h b/openair2/COMMON/gtpv1_u_messages_def.h
index 2835d07e4ae..44e9d4fbdf2 100644
--- a/openair2/COMMON/gtpv1_u_messages_def.h
+++ b/openair2/COMMON/gtpv1_u_messages_def.h
@@ -19,18 +19,12 @@
  *      contact@openairinterface.org
  */
 
-MESSAGE_DEF(GTPV1U_ENB_UPDATE_TUNNEL_REQ,   MESSAGE_PRIORITY_MED, gtpv1u_enb_update_tunnel_req_t,  Gtpv1uUpdateTunnelReq)
-MESSAGE_DEF(GTPV1U_ENB_UPDATE_TUNNEL_RESP,  MESSAGE_PRIORITY_MED, gtpv1u_enb_update_tunnel_resp_t, Gtpv1uUpdateTunnelResp)
-MESSAGE_DEF(GTPV1U_ENB_DELETE_TUNNEL_REQ,   MESSAGE_PRIORITY_MED, gtpv1u_enb_delete_tunnel_req_t,  Gtpv1uDeleteTunnelReq)
-MESSAGE_DEF(GTPV1U_ENB_DELETE_TUNNEL_RESP,  MESSAGE_PRIORITY_MED, gtpv1u_enb_delete_tunnel_resp_t, Gtpv1uDeleteTunnelResp)
-MESSAGE_DEF(GTPV1U_ENB_TUNNEL_DATA_IND,     MESSAGE_PRIORITY_MED, gtpv1u_enb_tunnel_data_ind_t,    Gtpv1uTunnelDataInd)
+
 MESSAGE_DEF(GTPV1U_ENB_TUNNEL_DATA_REQ,     MESSAGE_PRIORITY_MED, gtpv1u_enb_tunnel_data_req_t,    Gtpv1uTunnelDataReq)
 MESSAGE_DEF(GTPV1U_ENB_DATA_FORWARDING_REQ, MESSAGE_PRIORITY_MED, gtpv1u_enb_data_forwarding_req_t,Gtpv1uDataForwardingReq)
 MESSAGE_DEF(GTPV1U_ENB_DATA_FORWARDING_IND, MESSAGE_PRIORITY_MED, gtpv1u_enb_data_forwarding_ind_t,Gtpv1uDataForwardingInd)
 MESSAGE_DEF(GTPV1U_ENB_END_MARKER_REQ,      MESSAGE_PRIORITY_MED, gtpv1u_enb_end_marker_req_t,    Gtpv1uEndMarkerReq)
 MESSAGE_DEF(GTPV1U_ENB_END_MARKER_IND,      MESSAGE_PRIORITY_MED, gtpv1u_enb_end_marker_ind_t,    Gtpv1uEndMarkerInd)
-MESSAGE_DEF(GTPV1U_REQ,        MESSAGE_PRIORITY_MED, Gtpv1uReq,    gtpv1uReq)
+MESSAGE_DEF(GTPV1U_REQ,                     MESSAGE_PRIORITY_MED, Gtpv1uReq,    gtpv1uReq)
 
-MESSAGE_DEF(GTPV1U_GNB_DELETE_TUNNEL_REQ,   MESSAGE_PRIORITY_MED, gtpv1u_gnb_delete_tunnel_req_t,  NRGtpv1uDeleteTunnelReq)
-MESSAGE_DEF(GTPV1U_GNB_DELETE_TUNNEL_RESP,  MESSAGE_PRIORITY_MED, gtpv1u_gnb_delete_tunnel_resp_t, NRGtpv1uDeleteTunnelResp)
 MESSAGE_DEF(GTPV1U_GNB_TUNNEL_DATA_REQ,     MESSAGE_PRIORITY_MED, gtpv1u_gnb_tunnel_data_req_t,    NRGtpv1uTunnelDataReq)
diff --git a/openair2/COMMON/gtpv1_u_messages_types.h b/openair2/COMMON/gtpv1_u_messages_types.h
index 2dd476ab686..096f0f46972 100644
--- a/openair2/COMMON/gtpv1_u_messages_types.h
+++ b/openair2/COMMON/gtpv1_u_messages_types.h
@@ -28,10 +28,6 @@
 #define GTPV1U_MAX_BEARERS_PER_UE max_val_LTE_DRB_Identity
 #define NR_GTPV1U_MAX_BEARERS_PER_UE max_val_NR_DRB_Identity
 
-#define GTPV1U_ENB_UPDATE_TUNNEL_REQ(mSGpTR)  (mSGpTR)->ittiMsg.Gtpv1uUpdateTunnelReq
-#define GTPV1U_ENB_UPDATE_TUNNEL_RESP(mSGpTR) (mSGpTR)->ittiMsg.Gtpv1uUpdateTunnelResp
-#define GTPV1U_ENB_DELETE_TUNNEL_REQ(mSGpTR)  (mSGpTR)->ittiMsg.Gtpv1uDeleteTunnelReq
-#define GTPV1U_ENB_DELETE_TUNNEL_RESP(mSGpTR) (mSGpTR)->ittiMsg.Gtpv1uDeleteTunnelResp
 #define GTPV1U_ENB_TUNNEL_DATA_IND(mSGpTR)    (mSGpTR)->ittiMsg.Gtpv1uTunnelDataInd
 #define GTPV1U_ENB_TUNNEL_DATA_REQ(mSGpTR)    (mSGpTR)->ittiMsg.Gtpv1uTunnelDataReq
 #define GTPV1U_ENB_DATA_FORWARDING_REQ(mSGpTR)    (mSGpTR)->ittiMsg.Gtpv1uDataForwardingReq
@@ -41,8 +37,6 @@
 
 #define GTPV1U_REQ(mSGpTR)    (mSGpTR)->ittiMsg.gtpv1uReq
 
-#define GTPV1U_GNB_DELETE_TUNNEL_REQ(mSGpTR)  (mSGpTR)->ittiMsg.NRGtpv1uDeleteTunnelReq
-#define GTPV1U_GNB_DELETE_TUNNEL_RESP(mSGpTR) (mSGpTR)->ittiMsg.NRGtpv1uDeleteTunnelResp
 #define GTPV1U_GNB_TUNNEL_DATA_REQ(mSGpTR)    (mSGpTR)->ittiMsg.NRGtpv1uTunnelDataReq
 
 #define GTPV1U_ALL_TUNNELS_TEID (teid_t)0xFFFFFFFF
@@ -200,7 +194,6 @@ typedef struct gtpv1u_gnb_create_tunnel_resp_s {
   pdusessionid_t         pdusession_id[NR_GTPV1U_MAX_BEARERS_PER_UE];
   transport_layer_addr_t gnb_addr;
 } gtpv1u_gnb_create_tunnel_resp_t;
-
 typedef struct gtpv1u_gnb_delete_tunnel_req_s {
   rnti_t                 rnti;
   uint8_t                num_pdusession;
@@ -212,7 +205,6 @@ typedef struct gtpv1u_gnb_delete_tunnel_resp_s {
   uint8_t                status;               ///< Status of NGU endpoint deleteion (Failed = 0xFF or Success = 0x0)
   teid_t                 gnb_NGu_teid;         ///< local NGU Tunnel Endpoint Identifier to be deleted
 } gtpv1u_gnb_delete_tunnel_resp_t;
-
 typedef struct gtpv1u_gnb_tunnel_data_req_s {
   uint8_t               *buffer;
   uint32_t               length;
diff --git a/openair2/ENB_APP/enb_config.c b/openair2/ENB_APP/enb_config.c
index a08bcf4baf9..f5493a839a0 100644
--- a/openair2/ENB_APP/enb_config.c
+++ b/openair2/ENB_APP/enb_config.c
@@ -2080,7 +2080,7 @@ int RCconfig_gtpu(void ) {
     GTPV1U_REQ(message).localPort = enb_port_for_S1U;
     strcpy(GTPV1U_REQ(message).localAddrStr,address);
     sprintf(GTPV1U_REQ(message).localPortStr,"%d", enb_port_for_S1U);
-    itti_send_msg_to_task (TASK_VARIABLE, 0, message); // data model is wrong: gtpu doesn't have enb_id (or module_id)
+    itti_send_msg_to_task (TASK_GTPV1_U, 0, message); // data model is wrong: gtpu doesn't have enb_id (or module_id)
   } else
     LOG_E(GTPU,"invalid address for S1U\n");
 
diff --git a/openair2/F1AP/f1ap_cu_task.c b/openair2/F1AP/f1ap_cu_task.c
index 13f08b94588..8d4f8962500 100644
--- a/openair2/F1AP/f1ap_cu_task.c
+++ b/openair2/F1AP/f1ap_cu_task.c
@@ -47,7 +47,7 @@ static instance_t cu_task_create_gtpu_instance_to_du(eth_params_t *IPaddrs) {
   strncpy(tmp.destinationHost, IPaddrs->remote_addr, sizeof(tmp.destinationHost)-1);
   sprintf(tmp.originService, "%d",  IPaddrs->my_portd);
   sprintf(tmp.destinationService, "%d",  IPaddrs->remote_portd);
-  return ocp_gtpv1Init(tmp);
+  return gtpv1Init(tmp);
 }
 
 static void cu_task_handle_sctp_association_ind(instance_t instance, sctp_new_association_ind_t *sctp_new_association_ind,
diff --git a/openair2/F1AP/f1ap_du_task.c b/openair2/F1AP/f1ap_du_task.c
index 537f0060aec..1d5d24f5ca3 100644
--- a/openair2/F1AP/f1ap_du_task.c
+++ b/openair2/F1AP/f1ap_du_task.c
@@ -103,7 +103,7 @@ static instance_t du_create_gtpu_instance_to_cu(char *CUaddr, uint16_t CUport, c
   strncpy(tmp.destinationHost, CUaddr, sizeof(tmp.destinationHost)-1);
   sprintf(tmp.originService, "%d", DUport);
   sprintf(tmp.destinationService, "%d", CUport);
-  return ocp_gtpv1Init(tmp);
+  return gtpv1Init(tmp);
 }
 
 void *F1AP_DU_task(void *arg) {
diff --git a/openair2/GNB_APP/gnb_config.c b/openair2/GNB_APP/gnb_config.c
index 9710dd18146..65f2b58d8d8 100644
--- a/openair2/GNB_APP/gnb_config.c
+++ b/openair2/GNB_APP/gnb_config.c
@@ -1220,7 +1220,7 @@ int RCconfig_nr_gtpu(void ) {
     GTPV1U_REQ(message).localPort = port;
     strcpy(GTPV1U_REQ(message).localAddrStr,address);
     sprintf(GTPV1U_REQ(message).localPortStr,"%d", port);
-    itti_send_msg_to_task (TASK_VARIABLE, 0, message); // data model is wrong: gtpu doesn't have enb_id (or module_id)
+    itti_send_msg_to_task (TASK_GTPV1_U, 0, message); // data model is wrong: gtpu doesn't have enb_id (or module_id)
   } else
     LOG_E(GTPU,"invalid address for NGU or S1U\n");
   
diff --git a/openair2/LAYER2/PDCP_v10.1.0/pdcp.c b/openair2/LAYER2/PDCP_v10.1.0/pdcp.c
index 4d2e157728b..68bc9aedb23 100644
--- a/openair2/LAYER2/PDCP_v10.1.0/pdcp.c
+++ b/openair2/LAYER2/PDCP_v10.1.0/pdcp.c
@@ -60,7 +60,6 @@
 #include <pthread.h>
 
 #  include "gtpv1u_eNB_task.h"
-#  include "gtpv1u.h"
 #include <openair3/ocp-gtpu/gtp_itf.h>
 
 #include "ENB_APP/enb_config.h"
@@ -229,7 +228,7 @@ rlc_op_status_t cu_send_to_du(const protocol_ctxt_t *const ctxt,
   LOG_D(PDCP, "%s() (drb %ld) sending message to gtp size %d\n",
 	__func__, rb_id, size);
   extern instance_t CUuniqInstance;
-  itti_send_msg_to_task(TASK_VARIABLE, CUuniqInstance, message_p);
+  itti_send_msg_to_task(TASK_GTPV1_U, CUuniqInstance, message_p);
   return TRUE;
 }
 
@@ -1078,7 +1077,7 @@ pdcp_data_ind(
       GTPV1U_ENB_TUNNEL_DATA_REQ(message_p).offset       = GTPU_HEADER_OVERHEAD_MAX;
       GTPV1U_ENB_TUNNEL_DATA_REQ(message_p).rnti         = ctxt_pP->rnti;
       GTPV1U_ENB_TUNNEL_DATA_REQ(message_p).rab_id       = rb_id + 4;
-      itti_send_msg_to_task(TASK_VARIABLE, INSTANCE_DEFAULT, message_p);
+      itti_send_msg_to_task(TASK_GTPV1_U, INSTANCE_DEFAULT, message_p);
       packet_forwarded = TRUE;
     }
   } else {
diff --git a/openair2/LAYER2/PDCP_v10.1.0/pdcp_fifo.c b/openair2/LAYER2/PDCP_v10.1.0/pdcp_fifo.c
index b49b0204282..c3bffc0d2ac 100644
--- a/openair2/LAYER2/PDCP_v10.1.0/pdcp_fifo.c
+++ b/openair2/LAYER2/PDCP_v10.1.0/pdcp_fifo.c
@@ -85,8 +85,6 @@ extern struct msghdr nas_msg_rx;
 
 
 #  include "gtpv1u_eNB_task.h"
-#  include "gtpv1u_eNB_defs.h"
-
 
 extern int gtpv1u_new_data_req( uint8_t  enb_module_idP, rnti_t   ue_rntiP, uint8_t  rab_idP, uint8_t *buffer_pP, uint32_t buf_lenP, uint32_t buf_offsetP);
 uint16_t ue_id_g; // Global variable to identify the ID for each UE. It is updated in main() of lte-uesoftmodem.c
diff --git a/openair2/LAYER2/nr_pdcp/nr_pdcp_oai_api.c b/openair2/LAYER2/nr_pdcp/nr_pdcp_oai_api.c
index ab8578a0e7e..c75132564cc 100644
--- a/openair2/LAYER2/nr_pdcp/nr_pdcp_oai_api.c
+++ b/openair2/LAYER2/nr_pdcp/nr_pdcp_oai_api.c
@@ -674,7 +674,7 @@ static void deliver_sdu_drb(void *_ue, nr_pdcp_entity_t *entity,
         sdap_gnb_ul_header_handler(buf[0]); // Handler for the UL gNB SDAP Header
       }
       LOG_D(PDCP, "%s() (drb %d) sending message to gtp size %d\n", __func__, rb_id, size-offset);
-      itti_send_msg_to_task(TASK_VARIABLE, INSTANCE_DEFAULT, message_p);
+      itti_send_msg_to_task(TASK_GTPV1_U, INSTANCE_DEFAULT, message_p);
    }
   }
 }
@@ -728,7 +728,7 @@ rb_found:
     LOG_D(PDCP, "%s() (drb %d) sending message to gtp size %d\n",
 	  __func__, rb_id, size);
     extern instance_t CUuniqInstance;
-    itti_send_msg_to_task(TASK_VARIABLE, CUuniqInstance, message_p);
+    itti_send_msg_to_task(TASK_GTPV1_U, CUuniqInstance, message_p);
   } else {
     
     memblock = get_free_mem_block(size, __FUNCTION__);
diff --git a/openair2/LAYER2/nr_rlc/nr_rlc_oai_api.c b/openair2/LAYER2/nr_rlc/nr_rlc_oai_api.c
index 78e06d37e29..dcf2694d1a8 100644
--- a/openair2/LAYER2/nr_rlc/nr_rlc_oai_api.c
+++ b/openair2/LAYER2/nr_rlc/nr_rlc_oai_api.c
@@ -518,7 +518,7 @@ rb_found:
 	req->pdusession_id=rb_id;
 	LOG_D(RLC, "Received uplink user-plane traffic at RLC-DU to be sent to the CU, size %d \n", size);
 	extern instance_t DUuniqInstance;
-	itti_send_msg_to_task(OCP_GTPV1_U, DUuniqInstance, msg);
+	itti_send_msg_to_task(TASK_GTPV1_U, DUuniqInstance, msg);
 	return;
       }
     }
diff --git a/openair2/LAYER2/rlc_v2/rlc_oai_api.c b/openair2/LAYER2/rlc_v2/rlc_oai_api.c
index 16c3db0cae3..2a6f00c13c4 100644
--- a/openair2/LAYER2/rlc_v2/rlc_oai_api.c
+++ b/openair2/LAYER2/rlc_v2/rlc_oai_api.c
@@ -440,7 +440,7 @@ rb_found:
 	req->rnti=ue->rnti;
 	req->rab_id=rb_id+4;
 	LOG_D(RLC, "Received uplink user-plane traffic at RLC-DU to be sent to the CU, size %d \n", size);
-	itti_send_msg_to_task(OCP_GTPV1_U, DUuniqInstance, msg);      
+	itti_send_msg_to_task(TASK_GTPV1_U, DUuniqInstance, msg);      
 	return;
       }
     }
diff --git a/openair2/NR_UE_PHY_INTERFACE/NR_IF_Module.c b/openair2/NR_UE_PHY_INTERFACE/NR_IF_Module.c
index c7b54950d7c..08807e02024 100644
--- a/openair2/NR_UE_PHY_INTERFACE/NR_IF_Module.c
+++ b/openair2/NR_UE_PHY_INTERFACE/NR_IF_Module.c
@@ -30,6 +30,10 @@
  * \warning
  */
 
+#include <sys/socket.h>
+#include <netinet/in.h>
+#include <arpa/inet.h>
+
 #include "PHY/defs_nr_UE.h"
 #include "NR_IF_Module.h"
 #include "NR_MAC_UE/mac_proto.h"
diff --git a/openair2/RRC/LTE/rrc_eNB.c b/openair2/RRC/LTE/rrc_eNB.c
index 260b6fceaa6..8d21663d513 100644
--- a/openair2/RRC/LTE/rrc_eNB.c
+++ b/openair2/RRC/LTE/rrc_eNB.c
@@ -9572,20 +9572,6 @@ void *rrc_enb_process_itti_msg(void *notUsed) {
       rrc_eNB_process_S1AP_UE_CONTEXT_RELEASE_COMMAND(msg_p, msg_name_p, instance);
       break;
 
-    case GTPV1U_ENB_DELETE_TUNNEL_RESP: {
-      rrc_eNB_ue_context_t *ue = rrc_eNB_get_ue_context(RC.rrc[instance], GTPV1U_ENB_DELETE_TUNNEL_RESP(msg_p).rnti);
-
-      if (ue != NULL
-          && ue->ue_context.ue_release_timer_rrc > 0
-          && (ue->ue_context.handover_info == NULL ||
-              (ue->ue_context.handover_info->state != HO_RELEASE &&
-               ue->ue_context.handover_info->state != HO_CANCEL))) {
-        ue->ue_context.ue_release_timer_rrc = ue->ue_context.ue_release_timer_thres_rrc;
-      }
-
-      break;
-    }
-
     case S1AP_PATH_SWITCH_REQ_ACK:
       LOG_I(RRC, "[eNB %ld] received path switch ack %s\n", instance, msg_name_p);
       rrc_eNB_process_S1AP_PATH_SWITCH_REQ_ACK(msg_p, msg_name_p, instance);
diff --git a/openair2/RRC/LTE/rrc_eNB_GTPV1U.c b/openair2/RRC/LTE/rrc_eNB_GTPV1U.c
index 3fa17bcd6bd..7afec416c65 100644
--- a/openair2/RRC/LTE/rrc_eNB_GTPV1U.c
+++ b/openair2/RRC/LTE/rrc_eNB_GTPV1U.c
@@ -210,7 +210,7 @@ boolean_t gtpv_data_req_new (
       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);
-      return NW_GTPV1U_OK;
+      return 0;
   }
   
   /* target enb */
@@ -225,7 +225,7 @@ boolean_t gtpv_data_req_new (
       gtpv1u_enb_delete_tunnel_req_t delete_tunnel_req;
       memset(&delete_tunnel_req, 0, sizeof(delete_tunnel_req));
       delete_tunnel_req.rnti = ctxt->rnti;
-      gtpv1u_delete_x2u_tunnel(ctxt->module_id, &delete_tunnel_req, GTPV1U_TARGET_ENB);
+      gtpv1u_delete_x2u_tunnel(ctxt->module_id, &delete_tunnel_req);
       return true;
     } else {
       /* data packet */
diff --git a/openair2/RRC/LTE/rrc_eNB_S1AP.c b/openair2/RRC/LTE/rrc_eNB_S1AP.c
index 1a5fe55c26f..96b8cd0a99d 100644
--- a/openair2/RRC/LTE/rrc_eNB_S1AP.c
+++ b/openair2/RRC/LTE/rrc_eNB_S1AP.c
@@ -36,7 +36,6 @@
 #include "rrc_eNB_S1AP.h"
 #include "enb_config.h"
 #include "common/ran_context.h"
-#include "gtpv1u.h"
 
 #include "s1ap_eNB.h"
 #include "s1ap_eNB_defs.h"
diff --git a/openair2/RRC/NR/rrc_gNB.c b/openair2/RRC/NR/rrc_gNB.c
index 2c2020412d4..5b370d3614d 100755
--- a/openair2/RRC/NR/rrc_gNB.c
+++ b/openair2/RRC/NR/rrc_gNB.c
@@ -30,6 +30,10 @@
 #define RRC_GNB_C
 #define RRC_GNB_C
 
+#include <sys/socket.h>
+#include <netinet/in.h>
+#include <arpa/inet.h>
+
 #include "nr_rrc_config.h"
 #include "nr_rrc_defs.h"
 #include "nr_rrc_extern.h"
@@ -2190,7 +2194,6 @@ rrc_gNB_decode_dcch(
   asn_dec_rval_t                      dec_rval;
   NR_UL_DCCH_Message_t                *ul_dcch_msg  = NULL;
   struct rrc_gNB_ue_context_s         *ue_context_p = NULL;
-  MessageDef                         *msg_delete_tunnels_p = NULL;
   uint8_t                             xid;
 
   int i;
@@ -2289,21 +2292,17 @@ rrc_gNB_decode_dcch(
             xid = ul_dcch_msg->message.choice.c1->choice.rrcReconfigurationComplete->rrc_TransactionIdentifier;
             ue_context_p->ue_context.pdu_session_release_command_flag = 0;
             //gtp tunnel delete
-            msg_delete_tunnels_p = itti_alloc_new_message(TASK_RRC_GNB, 0, GTPV1U_GNB_DELETE_TUNNEL_REQ);
-            memset(&GTPV1U_GNB_DELETE_TUNNEL_REQ(msg_delete_tunnels_p), 0, sizeof(GTPV1U_GNB_DELETE_TUNNEL_REQ(msg_delete_tunnels_p)));
-            GTPV1U_GNB_DELETE_TUNNEL_REQ(msg_delete_tunnels_p).rnti = ue_context_p->ue_context.rnti;
-
+	    gtpv1u_gnb_delete_tunnel_req_t req={0};
             for(i = 0; i < NB_RB_MAX; i++) {
               if(xid == ue_context_p->ue_context.pduSession[i].xid) {
-                GTPV1U_GNB_DELETE_TUNNEL_REQ(msg_delete_tunnels_p).pdusession_id[GTPV1U_GNB_DELETE_TUNNEL_REQ(msg_delete_tunnels_p).num_pdusession++] =
+                req.pdusession_id[req.num_pdusession++] =
                   ue_context_p->ue_context.gnb_gtp_psi[i];
                 ue_context_p->ue_context.gnb_gtp_teid[i] = 0;
                 memset(&ue_context_p->ue_context.gnb_gtp_addrs[i], 0, sizeof(ue_context_p->ue_context.gnb_gtp_addrs[i]));
                 ue_context_p->ue_context.gnb_gtp_psi[i]  = 0;
               }
             }
-
-            itti_send_msg_to_task(TASK_GTPV1_U, ctxt_pP->instance, msg_delete_tunnels_p);
+	    gtpv1u_delete_ngu_tunnel(ctxt_pP->instance, &req);
             //NGAP_PDUSESSION_RELEASE_RESPONSE
             rrc_gNB_send_NGAP_PDUSESSION_RELEASE_RESPONSE(ctxt_pP, ue_context_p, xid);
           } else if (ue_context_p->ue_context.established_pdu_sessions_flag != 1) {
@@ -3636,9 +3635,6 @@ void *rrc_gnb_task(void *args_p) {
         rrc_gNB_process_NGAP_PDUSESSION_RELEASE_COMMAND(msg_p, msg_name_p, instance);
         break;
 
-      case GTPV1U_GNB_DELETE_TUNNEL_RESP:
-        break;
-
       /* Messages from gNB app */
       case NRRRC_CONFIGURATION_REQ:
         LOG_I(NR_RRC, "[gNB %ld] Received %s : %p\n", instance, msg_name_p,&NRRRC_CONFIGURATION_REQ(msg_p));
@@ -3688,11 +3684,6 @@ void *rrc_gnb_task(void *args_p) {
         rrc_gNB_process_dc_overall_timeout(GNB_INSTANCE_TO_MODULE_ID(instance), &X2AP_ENDC_DC_OVERALL_TIMEOUT(msg_p));
         break;
 
-      /* Messages from GTP */
-      case GTPV1U_ENB_DELETE_TUNNEL_RESP:
-        /* nothing to do? */
-        break;
-
       case NGAP_UE_CONTEXT_RELEASE_REQ:
         rrc_gNB_process_NGAP_UE_CONTEXT_RELEASE_REQ(msg_p, msg_name_p, instance);
         break;
diff --git a/openair2/RRC/NR/rrc_gNB_NGAP.c b/openair2/RRC/NR/rrc_gNB_NGAP.c
index 043d1366045..a05698bd5ab 100644
--- a/openair2/RRC/NR/rrc_gNB_NGAP.c
+++ b/openair2/RRC/NR/rrc_gNB_NGAP.c
@@ -33,7 +33,6 @@
 #include "rrc_eNB_S1AP.h"
 #include "gnb_config.h"
 #include "common/ran_context.h"
-#include "gtpv1u.h"
 
 #include "asn1_conversions.h"
 #include "intertask_interface.h"
@@ -44,6 +43,7 @@
 
 #include "gtpv1u_eNB_task.h"
 #include "gtpv1u_gNB_task.h"
+#include <openair3/ocp-gtpu/gtp_itf.h>
 #include "RRC/LTE/rrc_eNB_GTPV1U.h"
 #include "RRC/NR/rrc_gNB_GTPV1U.h"
 
@@ -1395,7 +1395,6 @@ rrc_gNB_process_NGAP_PDUSESSION_RELEASE_COMMAND(
   protocol_ctxt_t                 ctxt;
   pdusession_release_t            pdusession_release_params[NGAP_MAX_PDUSESSION];
   uint8_t                         nb_pdusessions_torelease;
-  MessageDef                     *msg_delete_tunnels_p = NULL;
   uint8_t xid;
   int i, pdusession;
   uint8_t b_existed,is_existed;
@@ -1473,20 +1472,18 @@ rrc_gNB_process_NGAP_PDUSESSION_RELEASE_COMMAND(
     } else {
       //gtp tunnel delete
       LOG_I(NR_RRC, "gtp tunnel delete \n");
-      msg_delete_tunnels_p = itti_alloc_new_message(TASK_RRC_GNB, 0, GTPV1U_GNB_DELETE_TUNNEL_REQ);
-      memset(&GTPV1U_GNB_DELETE_TUNNEL_REQ(msg_delete_tunnels_p), 0, sizeof(GTPV1U_GNB_DELETE_TUNNEL_REQ(msg_delete_tunnels_p)));
-      GTPV1U_GNB_DELETE_TUNNEL_REQ(msg_delete_tunnels_p).rnti = ue_context_p->ue_context.rnti;
+      gtpv1u_gnb_delete_tunnel_req_t req={0};
+      req.rnti = ue_context_p->ue_context.rnti;
 
       for(i = 0; i < NB_RB_MAX; i++) {
         if(xid == ue_context_p->ue_context.pduSession[i].xid) {
-          GTPV1U_GNB_DELETE_TUNNEL_REQ(msg_delete_tunnels_p).pdusession_id[GTPV1U_GNB_DELETE_TUNNEL_REQ(msg_delete_tunnels_p).num_pdusession++] = ue_context_p->ue_context.gnb_gtp_psi[i];
+          req.pdusession_id[req.num_pdusession++] = ue_context_p->ue_context.gnb_gtp_psi[i];
           ue_context_p->ue_context.gnb_gtp_teid[i] = 0;
           memset(&ue_context_p->ue_context.gnb_gtp_addrs[i], 0, sizeof(ue_context_p->ue_context.gnb_gtp_addrs[i]));
           ue_context_p->ue_context.gnb_gtp_psi[i]  = 0;
         }
       }
-
-      itti_send_msg_to_task(TASK_GTPV1_U, instance, msg_delete_tunnels_p);
+      gtpv1u_delete_ngu_tunnel(instance, &req);
       //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");
diff --git a/openair2/UTIL/MATH/crc_byte.c b/openair2/UTIL/MATH/crc_byte.c
deleted file mode 100644
index a3ff00fec19..00000000000
--- a/openair2/UTIL/MATH/crc_byte.c
+++ /dev/null
@@ -1,185 +0,0 @@
-/*
- * Licensed to the OpenAirInterface (OAI) Software Alliance under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The OpenAirInterface Software Alliance licenses this file to You under
- * the OAI Public License, Version 1.1  (the "License"); you may not use this file
- * except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.openairinterface.org/?page_id=698
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- *-------------------------------------------------------------------------------
- * For more information about the OpenAirInterface (OAI) Software Alliance:
- *      contact@openairinterface.org
- */
-
-/*
-  May 10, 2001
-  Modified in June, 2001, to include  the length non multiple of 8
-  crc_byte.c
-  Byte oriented implementation of CRC's
-
-  */
-#include "rtos_header.h"
-#include "platform_types.h"
-
-
-/*ref 25.222 v4.0.0 , p12 */
-/* the highest degree is set by default */
-unsigned int             poly24 = 0x80006100;    // 1000 0000 0000 0000 0110 0001  D^24 + D^23 + D^6 + D^5 + D + 1
-unsigned int             poly16 = 0x10210000;    // 0001 0000 0010 0001            D^16 + D^12 + D^5 + 1
-unsigned int             poly12 = 0x80F00000;    // 1000 0000 1111                 D^12 + D^11 + D^3 + D^2 + D + 1
-unsigned int             poly8 = 0x9B000000;     // 1001 1011                      D^8  + D^7  + D^4 + D^3 + D + 1
-/*********************************************************
-
-For initialization && verification purposes,
-   bit by bit implementation with any polynomial
-
-The first bit is in the MSB of each byte
-
-*********************************************************/
-static          unsigned int
-crcbit (unsigned char * inputptr, int octetlen, unsigned int poly)
-{
-  unsigned int             i, crc = 0, c;
-
-  while (octetlen-- > 0) {
-    c = (*inputptr++) << 24;
-
-    for (i = 8; i != 0; i--) {
-      if ((1 << 31) & (c ^ crc))
-        crc = (crc << 1) ^ poly;
-      else
-        crc <<= 1;
-
-      c <<= 1;
-    }
-  }
-
-  return crc;
-}
-
-/*********************************************************
-
-crc table initialization
-
-*********************************************************/
-static unsigned int      crc24Table[256];
-static unsigned short      crc16Table[256];
-static unsigned short      crc12Table[256];
-static unsigned char       crc8Table[256];
-void
-crcTableInit ()
-{
-  unsigned char              c = 0;
-
-  do {
-    crc24Table[c] = crcbit (&c, 1, poly24);
-    crc16Table[c] = (unsigned short) (crcbit (&c, 1, poly16) >> 16);
-    crc12Table[c] = (unsigned short) (crcbit (&c, 1, poly12) >> 16);
-    crc8Table[c] = (unsigned char) (crcbit (&c, 1, poly8) >> 24);
-  } while (++c);
-}
-
-/*********************************************************
-
-Byte by byte implementations,
-assuming initial byte is 0 padded (in MSB) if necessary
-
-*********************************************************/
-unsigned int
-crc24 (unsigned char * inptr, int bitlen)
-{
-
-  int             octetlen, resbit;
-  unsigned int             crc = 0;
-  octetlen = bitlen / 8;        /* Change in octets */
-  resbit = (bitlen % 8);
-
-  while (octetlen-- > 0) {
-    crc = (crc << 8) ^ crc24Table[(*inptr++) ^ (crc >> 24)];
-  }
-
-  if (resbit > 0)
-    crc = (crc << resbit) ^ crc24Table[((*inptr) >> (8 - resbit)) ^ (crc >> (32 - resbit))];
-
-  return crc;
-}
-
-unsigned int
-crc16 (unsigned char * inptr, int bitlen)
-{
-  int             octetlen, resbit;
-  unsigned int             crc = 0;
-  octetlen = bitlen / 8;        /* Change in octets */
-  resbit = (bitlen % 8);
-
-  while (octetlen-- > 0) {
-    crc = (crc << 8) ^ (crc16Table[(*inptr++) ^ (crc >> 24)] << 16);
-  }
-
-  if (resbit > 0)
-    crc = (crc << resbit) ^ (crc16Table[((*inptr) >> (8 - resbit)) ^ (crc >> (32 - resbit))] << 16);
-
-  return crc;
-}
-
-unsigned int
-crc12 (unsigned char * inptr, int bitlen)
-{
-  int             octetlen, resbit;
-  unsigned int             crc = 0;
-  octetlen = bitlen / 8;        /* Change in octets */
-  resbit = (bitlen % 8);
-
-  while (octetlen-- > 0) {
-    crc = (crc << 8) ^ (crc12Table[(*inptr++) ^ (crc >> 24)] << 16);
-  }
-
-  if (resbit > 0)
-    crc = (crc << resbit) ^ (crc12Table[((*inptr) >> (8 - resbit)) ^ (crc >> (32 - resbit))] << 16);
-
-  return crc;
-}
-
-unsigned int
-crc8 (unsigned char * inptr, int bitlen)
-{
-  int             octetlen, resbit;
-  unsigned int             crc = 0;
-  octetlen = bitlen / 8;        /* Change in octets */
-  resbit = (bitlen % 8);
-
-  while (octetlen-- > 0) {
-    crc = crc8Table[(*inptr++) ^ (crc >> 24)] << 24;
-  }
-
-  if (resbit > 0)
-    crc = (crc << resbit) ^ (crc8Table[((*inptr) >> (8 - resbit)) ^ (crc >> (32 - resbit))] << 24);
-
-  return crc;
-}
-
-/*******************************************************************/
-/**
-   Test code
-********************************************************************/
-
-/* #ifdef MAIN
-   #include <stdio.h>
-   main()
-   {
-   unsigned char test[] = "Thebigredfox";
-   crcTableInit();
-   printf("%x\n", crcbit(test, sizeof(test) - 1, poly24));
-   printf("%x\n", crc24(test, (sizeof(test) - 1)*8));
-   printf("%x\n", crcbit(test, sizeof(test) - 1, poly8));
-   printf("%x\n", crc8(test, (sizeof(test) - 1)*8));
-   }
-   #endif */
diff --git a/openair2/UTIL/MATH/random_proto_extern.h b/openair2/UTIL/MATH/random_proto_extern.h
deleted file mode 100644
index 45db5652172..00000000000
--- a/openair2/UTIL/MATH/random_proto_extern.h
+++ /dev/null
@@ -1,30 +0,0 @@
-/*
- * Licensed to the OpenAirInterface (OAI) Software Alliance under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The OpenAirInterface Software Alliance licenses this file to You under
- * the OAI Public License, Version 1.1  (the "License"); you may not use this file
- * except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.openairinterface.org/?page_id=698
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- *-------------------------------------------------------------------------------
- * For more information about the OpenAirInterface (OAI) Software Alliance:
- *      contact@openairinterface.org
- */
-
-/*
-
-                             random_proto_extern.h
-                             -------------------
-  AUTHOR  : Lionel GAUTHIER
-  COMPANY : EURECOM
-  EMAIL   : Lionel.Gauthier@eurecom.fr
- ***************************************************************************/
-extern int      uniform (void);
diff --git a/openair2/UTIL/MATH/taus.c b/openair2/UTIL/MATH/taus.c
deleted file mode 100644
index 6b5e03588dd..00000000000
--- a/openair2/UTIL/MATH/taus.c
+++ /dev/null
@@ -1,116 +0,0 @@
-/*
- * Licensed to the OpenAirInterface (OAI) Software Alliance under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The OpenAirInterface Software Alliance licenses this file to You under
- * the OAI Public License, Version 1.1  (the "License"); you may not use this file
- * except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.openairinterface.org/?page_id=698
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- *-------------------------------------------------------------------------------
- * For more information about the OpenAirInterface (OAI) Software Alliance:
- *      contact@openairinterface.org
- */
-
-/*! \file taus.c
-* \brief random number generator per OAI component
-* \author Navid Nikaein
-* \date 2011 - 2014
-* \version 0.1
-* \email navid.nikaein@eurecom.fr
-* \warning
-* @ingroup util
-*/
-
-#include <stdio.h>
-#include <stdlib.h>
-#include <string.h>
-#include <time.h>
-#include <math.h>
-#include "oml.h"
-
-unsigned int s0[MAX_NUM_COMPS], s1[MAX_NUM_COMPS], s2[MAX_NUM_COMPS], b[MAX_NUM_COMPS], r[MAX_NUM_COMPS];
-
-
-
-
-inline unsigned int taus(unsigned int comp) {
-  b[comp] = (((s0[comp] << 13) ^ s0[comp]) >> 19);
-  s0[comp] = (((s0[comp] & 0xFFFFFFFE) << 12)^  b[comp]);
-  b[comp] = (((s1[comp] << 2) ^ s1[comp]) >> 25);
-  s1[comp] = (((s1[comp] & 0xFFFFFFF8) << 4)^  b[comp]);
-  b[comp] = (((s2[comp] << 3) ^ s2[comp]) >> 11);
-  s2[comp] = (((s2[comp] & 0xFFFFFFF0) << 17)^  b[comp]);
-  r[comp] = s0[comp] ^ s1[comp] ^ s2[comp];
-  return r[comp];
-}
-
-/*void set_taus_seed(unsigned int seed_type) {
-  unsigned int i; // i index of component
-
-  for (i=MIN_NUM_COMPS; i < MAX_NUM_COMPS  ; i ++)  {
-    switch (seed_type) {
-      case 0: // use rand func
-        if (i == 0) srand(time(NULL));
-
-        s0[i] = ((unsigned int)rand());
-        s1[i] = ((unsigned int)rand());
-        s2[i] = ((unsigned int)rand());
-        printf("Initial seeds use rand: s0[%u] = 0x%x, s1[%u] = 0x%x, s2[%u] = 0x%x\n", i, s0[i], i, s1[i], i, s2[i]);
-        break;
-
-      case 1: // use rand with seed
-        if (i == 0) srand(0x1e23d851);
-
-        s0[i] = ((unsigned int)rand());
-        s1[i] = ((unsigned int)rand());
-        s2[i] = ((unsigned int)rand());
-        printf("Initial seeds use rand with seed : s0[%u] = 0x%x, s1[%u] = 0x%x, s2[%u] = 0x%x\n", i, s0[i], i, s1[i], i, s2[i]);
-        break;
-
-      default:
-        break;
-    }
-  }
-}*/
-
-int get_rand (unsigned int comp) {
-  if ((comp > MIN_NUM_COMPS) && (comp < MAX_NUM_COMPS))
-    return r[comp];
-  else {
-    //LOG_E(RNG,"unknown component %d\n",comp);
-    return -1;
-  }
-}
-
-unsigned int dtaus(unsigned int comp, unsigned int a, unsigned b) {
-  return (int) (((double)taus(comp)/(double)0xffffffff)* (double)(b-a) + (double)a);
-}
-/*
-#ifdef STANDALONE
-main() {
-
-  unsigned int i,randomg, randphy;
-
-  set_taus_seed(0);
-  printf("dtaus %d \n",dtaus(PHY, 1000, 1000000));
-
-  do {//for (i=0;i<10;i++){
-    randphy = taus(PHY);
-    randomg = taus(OTG);
-    i++;
-    // printf("rand for OMG (%d,0x%x) PHY (%d,0x%x)\n",OMG, randomg, PHY, randphy);
-  } while (randphy != randomg);
-  printf("after %d run: get rand for (OMG 0x%x, PHY 0x%x)\n",i, get_rand(OTG), get_rand(PHY));
-
-}
-#endif
-
-*/
diff --git a/openair3/GTPV1-U/Makefile.am b/openair3/GTPV1-U/Makefile.am
deleted file mode 100644
index 30ea61d6c17..00000000000
--- a/openair3/GTPV1-U/Makefile.am
+++ /dev/null
@@ -1,58 +0,0 @@
-#/*
-# * Licensed to the OpenAirInterface (OAI) Software Alliance under one or more
-# * contributor license agreements.  See the NOTICE file distributed with
-# * this work for additional information regarding copyright ownership.
-# * The OpenAirInterface Software Alliance licenses this file to You under
-# * the OAI Public License, Version 1.1  (the "License"); you may not use this file
-# * except in compliance with the License.
-# * You may obtain a copy of the License at
-# *
-# *      http://www.openairinterface.org/?page_id=698
-# *
-# * Unless required by applicable law or agreed to in writing, software
-# * distributed under the License is distributed on an "AS IS" BASIS,
-# * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# * See the License for the specific language governing permissions and
-# * limitations under the License.
-# *-------------------------------------------------------------------------------
-# * For more information about the OpenAirInterface (OAI) Software Alliance:
-# *      contact@openairinterface.org
-# */
-
-AM_CFLAGS = @ADD_CFLAGS@ 	\
-	-I$(top_srcdir)/COMMON	\
-	-I$(top_srcdir)/NAS/EURECOM-NAS/src/api/network		\
-	-I$(top_srcdir)/NAS/EURECOM-NAS/src/include			\
-	-I$(top_srcdir)/NAS/EURECOM-NAS/src/ies				\
-	-I$(top_srcdir)/NAS/EURECOM-NAS/src/emm/msg			\
-	-I$(top_srcdir)/NAS/EURECOM-NAS/src/esm/msg			\
-	-I$(top_srcdir)/NAS/EURECOM-NAS/src/util			\
-	-I$(top_srcdir)/INTERTASK_INTERFACE	\
-	-I$(top_srcdir)/GTPV1-U/nw-gtpv1u/include	\
-	-I$(top_srcdir)/GTPV1-U/nw-gtpv1u/shared	\
-    -I$(top_srcdir)/UTILS   \
-    -I$(top_srcdir)/UTILS/HASHTABLE   \
-	-I$(top_srcdir)/UTILS/TIMER
-
-noinst_LTLIBRARIES = libgtpv1u.la
-
-libgtpv1u_la_LDFLAGS = -all-static
-
-libgtpv1u_la_SOURCES = \
-	gtpv1u_task.c	gtpv1u.h	\
-	gtpv1u_teid_pool.c	\
-	nw-gtpv1u/shared/NwTypes.h	\
-	nw-gtpv1u/shared/NwUtils.h	\
-	nw-gtpv1u/shared/NwGtpv1uError.h	\
-	nw-gtpv1u/shared/NwLog.h		\
-	nw-gtpv1u/shared/NwGtpv1uIe.h	\
-	nw-gtpv1u/shared/NwGtpv1uMsg.h	\
-	nw-gtpv1u/shared/NwGtpv1u.h	\
-	nw-gtpv1u/include/NwGtpv1uPrivate.h	\
-	nw-gtpv1u/include/NwGtpv1uLog.h	\
-	nw-gtpv1u/include/NwGtpv1uTrxn.h	\
-	nw-gtpv1u/include/NwGtpv1uTunnelEndPoint.h	\
-	nw-gtpv1u/src/NwGtpv1uTunnelEndPoint.c	\
-	nw-gtpv1u/src/NwGtpv1uTrxn.c	\
-	nw-gtpv1u/src/NwGtpv1uMsg.c	\
-	nw-gtpv1u/src/NwGtpv1u.c
diff --git a/openair3/GTPV1-U/Makefile.eNB b/openair3/GTPV1-U/Makefile.eNB
deleted file mode 100644
index b469dc756d0..00000000000
--- a/openair3/GTPV1-U/Makefile.eNB
+++ /dev/null
@@ -1,67 +0,0 @@
-#/*
-# * Licensed to the OpenAirInterface (OAI) Software Alliance under one or more
-# * contributor license agreements.  See the NOTICE file distributed with
-# * this work for additional information regarding copyright ownership.
-# * The OpenAirInterface Software Alliance licenses this file to You under
-# * the OAI Public License, Version 1.1  (the "License"); you may not use this file
-# * except in compliance with the License.
-# * You may obtain a copy of the License at
-# *
-# *      http://www.openairinterface.org/?page_id=698
-# *
-# * Unless required by applicable law or agreed to in writing, software
-# * distributed under the License is distributed on an "AS IS" BASIS,
-# * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# * See the License for the specific language governing permissions and
-# * limitations under the License.
-# *-------------------------------------------------------------------------------
-# * For more information about the OpenAirInterface (OAI) Software Alliance:
-# *      contact@openairinterface.org
-# */
-
-OUTDIR = .
-
-libgtpv1u_OBJECTS = \
-	nw-gtpv1u/src/NwGtpv1uTunnelEndPoint.o	\
-	nw-gtpv1u/src/NwGtpv1uTrxn.o 	\
-	nw-gtpv1u/src/NwGtpv1uMsg.o 	\
-	nw-gtpv1u/src/NwGtpv1u.o 	\
-	gtpv1u_eNB.o	\
-	gtpv1u_teid_pool.o
-
-# pull in dependency info for *existing* .o files
--include $(OUTDIR)/*.d
-
-CFLAGS = \
-	-Wall			\
-	$(GTPV1U_CFLAGS)		\
-	-DENB_MODE		\
-	-Werror=uninitialized	\
-	-Werror=implicit-function-declaration
-
-$(OUTDIR)/%.o : %.c
-	@echo "Compiling $<"
-	@if [ ! -d $(dir $@) ]; then mkdir -p $(dir $@); fi;
-	@$(CC) -c $(CFLAGS) -o $@ $<
-	@$(CC) -MM $(CFLAGS) $< > $(basename $@).d
-	@mv -f $(basename $@).d $(basename $@).d.tmp
-	@sed -e 's|.*:|$@:|' < $(basename $@).d.tmp > $(basename $@).d
-	@sed -e 's/.*://' -e 's/\\$$//' < $(basename $@).d.tmp | fmt -1 | \
-	sed -e 's/^ *//' -e 's/$$/:/' >> $(basename $@).d
-	@rm -f $(basename $@).d.tmp
-
-objsdir:
-	@if [ ! -d $(OUTDIR) ]; then mkdir -p $(OUTDIR); fi;
-
-$(OUTDIR)/libgtpv1u.a: $(addprefix $(OUTDIR)/,$(libgtpv1u_OBJECTS))
-	@echo Creating GTPV1U archive
-	@$(AR) rcs $@ $(addprefix $(OUTDIR)/,$(libgtpv1u_OBJECTS))
-
-clean:
-	@$(RM_F_V) $(OUTDIR)/nw-gtpv1u/src/*.o
-	@$(RM_F_V) $(OUTDIR)/nw-gtpv1u/src/*.d
-	@$(RM_F_V) $(OUTDIR)/*.o
-	@$(RM_F_V) $(OUTDIR)/*.d
-	@$(RM_F_V) $(OUTDIR)/libgtpv1u.a
-
-cleanall: clean
diff --git a/openair3/GTPV1-U/gtpv1u.h b/openair3/GTPV1-U/gtpv1u.h
deleted file mode 100644
index 9466f024bc0..00000000000
--- a/openair3/GTPV1-U/gtpv1u.h
+++ /dev/null
@@ -1,55 +0,0 @@
-/*
- * Licensed to the OpenAirInterface (OAI) Software Alliance under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The OpenAirInterface Software Alliance licenses this file to You under
- * the OAI Public License, Version 1.1  (the "License"); you may not use this file
- * except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.openairinterface.org/?page_id=698
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- *-------------------------------------------------------------------------------
- * For more information about the OpenAirInterface (OAI) Software Alliance:
- *      contact@openairinterface.org
- */
-
-/*! \file gtpv1u.h
-* \brief
-* \author Sebastien ROUX, Lionel Gauthier
-* \company Eurecom
-* \email: lionel.gauthier@eurecom.fr
-*/
-
-#ifndef GTPV1_U_H_
-#define GTPV1_U_H_
-
-#define GTPU_STACK_ENB 0
-#define GTPU_STACK_SGW 1
-
-/* When gtpv1u is compiled for eNB use MACRO from UTILS/log.h,
- * otherwise use standard fprintf as logger.
- */
-#if defined(ENB_MODE)
-# define GTPU_DEBUG(x, args...)   LOG_D(GTPU, x, ##args)
-# define GTPU_INFO(x, args...)    LOG_I(GTPU, x, ##args)
-# define GTPU_WARNING(x, args...) LOG_W(GTPU, x, ##args)
-# define GTPU_ERROR(x, args...)   LOG_E(GTPU, x, ##args)
-#else
-# define GTPU_DEBUG(x, args...)   fprintf(stdout, "[GTPU][D]"x, ##args)
-# define GTPU_INFO(x, args...)    fprintf(stdout, "[GTPU][I]"x, ##args)
-# define GTPU_WARNING(x, args...) fprintf(stdout, "[GTPU][W]"x, ##args)
-# define GTPU_ERROR(x, args...)   fprintf(stderr, "[GTPU][E]"x, ##args)
-#endif
-
-//#warning "TO BE REFINED"
-# define GTPU_HEADER_OVERHEAD_MAX 64
-
-uint32_t gtpv1u_new_teid(void);
-
-#endif /* GTPV1_U_H_ */
diff --git a/openair3/GTPV1-U/gtpv1u_eNB.c b/openair3/GTPV1-U/gtpv1u_eNB.c
deleted file mode 100644
index 6f5ef004b59..00000000000
--- a/openair3/GTPV1-U/gtpv1u_eNB.c
+++ /dev/null
@@ -1,1600 +0,0 @@
-/*
- * Licensed to the OpenAirInterface (OAI) Software Alliance under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The OpenAirInterface Software Alliance licenses this file to You under
- * the OAI Public License, Version 1.1  (the "License"); you may not use this file
- * except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.openairinterface.org/?page_id=698
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- *-------------------------------------------------------------------------------
- * For more information about the OpenAirInterface (OAI) Software Alliance:
- *      contact@openairinterface.org
- */
-
-/*! \file gtpv1u_eNB.c
- * \brief
- * \author Sebastien ROUX, Lionel GAUTHIER, Navid Nikaein
- * \version 1.0
- * \company Eurecom
- * \email: lionel.gauthier@eurecom.fr
- */
-#include <stdio.h>
-#include <errno.h>
-
-#include "mme_config.h"
-
-#include "assertions.h"
-#include "intertask_interface.h"
-#include "msc.h"
-
-#include "gtpv1u.h"
-#include "NwGtpv1u.h"
-#include "NwGtpv1uMsg.h"
-#include "NwGtpv1uPrivate.h"
-#include "NwLog.h"
-#include "gtpv1u_eNB_defs.h"
-#include "gtpv1_u_messages_types.h"
-#include "udp_eNB_task.h"
-#include "common/utils/LOG/log.h"
-#include "COMMON/platform_types.h"
-#include "COMMON/platform_constants.h"
-#include "common/utils/LOG/vcd_signal_dumper.h"
-#include "common/ran_context.h"
-#include "gtpv1u_eNB_defs.h"
-#include "gtpv1u_eNB_task.h"
-#include "rrc_eNB_GTPV1U.h"
-#include <common/utils/msc/msc.h>
-
-#undef GTP_DUMP_SOCKET
-
-extern unsigned char NB_eNB_INST;
-extern RAN_CONTEXT_t RC;
-
-extern struct rrc_eNB_ue_context_s *
-rrc_eNB_get_ue_context(
-  eNB_RRC_INST *rrc_instance_pP,
-  rnti_t rntiP);
-
-#if defined(GTP_DUMP_SOCKET) && GTP_DUMP_SOCKET > 0
-#include <linux/if.h>
-static int           gtpv1u_dump_socket_g;
-
-//-----------------------------------------------------------------------------
-int gtpv1u_eNB_create_dump_socket(void) {
-  struct ifreq ifr;
-  int          hdrincl=1;
-
-  if ((gtpv1u_dump_socket_g = socket(AF_INET, SOCK_RAW, IPPROTO_RAW)) < 0 ) {
-    LOG_E(GTPU, "Could not create dump socket %d:%s\n", errno, strerror(errno));
-    return -1;
-  }
-
-  if (setsockopt(gtpv1u_dump_socket_g,
-                 IPPROTO_IP,
-                 IP_HDRINCL,
-                 &hdrincl,
-                 sizeof(hdrincl))==-1) {
-    LOG_E(GTPU, "%s:%d set IP_HDRINCL %d:%s\n",
-          __FILE__, __LINE__, errno, strerror(errno));
-  }
-
-  memset(&ifr, 0, sizeof(ifr));
-  snprintf(ifr.ifr_name, sizeof(ifr.ifr_name), "lo");
-
-  if (setsockopt(gtpv1u_dump_socket_g, SOL_SOCKET, SO_BINDTODEVICE, (void *)&ifr, sizeof(ifr)) < 0) {
-    LOG_E(GTPU, "%s:%d  setsockopt SO_BINDTODEVICE %d:%s\n",
-          __FILE__, __LINE__, errno, strerror(errno));
-    close(gtpv1u_dump_socket_g);
-    return -1;
-  }
-}
-
-//-----------------------------------------------------------------------------
-static void gtpv1u_eNB_write_dump_socket(uint8_t *buffer_pP, uint32_t buffer_lengthP) {
-  struct sockaddr_in sin;
-  memset(&sin, 0, sizeof(sin));
-  sin.sin_family = AF_INET;
-  sin.sin_addr.s_addr = INADDR_LOOPBACK;
-
-  if (sendto(gtpv1u_dump_socket_g, buffer_pP, (size_t)buffer_lengthP, 0, (struct sockaddr *)&sin, sizeof(struct sockaddr)) < 0)  {
-    LOG_E(GTPU, "%s:%s:%d  sendto %d:%s\n",
-          __FILE__, __FUNCTION__, __LINE__, errno, strerror(errno));
-  }
-}
-
-#endif
-
-//-----------------------------------------------------------------------------
-static int gtpv1u_eNB_get_msgsource(struct rrc_eNB_ue_context_s *ue_context_p, teid_t teid) {
-  int erab_index = 0;
-
-  /* source enb */
-  if(ue_context_p->ue_context.handover_info != NULL && ue_context_p->ue_context.handover_info->state == HO_COMPLETE) {
-    return GTPV1U_MSG_FROM_SPGW;
-  }
-
-  /* target enb */
-  for (erab_index = 0; erab_index < ue_context_p->ue_context.nb_x2u_e_rabs; erab_index++) {
-    if(ue_context_p->ue_context.enb_gtp_x2u_teid[erab_index] == teid) {
-      return GTPV1U_MSG_FROM_SOURCE_ENB;
-    }
-  }
-
-  return GTPV1U_MSG_FROM_SPGW;
-}
-
-//-----------------------------------------------------------------------------
-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);
-
-  if (message_p == NULL) {
-    return -1;
-  }
-
-  UDP_INIT(message_p).port = req->enb_port_for_S1u_S12_S4_up;
-  addr.s_addr = req->enb_ip_address_for_S1u_S12_S4_up;
-  UDP_INIT(message_p).address = inet_ntoa(addr);
-  LOG_I(GTPU, "Tx UDP_INIT IP addr %s (%x)\n", UDP_INIT(message_p).address,UDP_INIT(message_p).port);
-  MSC_LOG_EVENT(
-    MSC_GTPU_ENB,
-    "0 UDP bind  %s:%u",
-    UDP_INIT(message_p).address,
-    UDP_INIT(message_p).port);
-  return itti_send_msg_to_task(TASK_UDP, INSTANCE_DEFAULT, message_p);
-}
-
-static int gtpv1u_s1_req(
-  const instance_t                             instanceP,
-  const Gtpv1uS1Req *const req) {
-  memcpy(&RC.gtpv1u_data_g->enb_ip_address_for_S1u_S12_S4_up,
-         &req->enb_ip_address_for_S1u_S12_S4_up,
-         sizeof (req->enb_ip_address_for_S1u_S12_S4_up));
-  gtpv1u_eNB_send_init_udp(req);
-  return 0;
-}
-
-//-----------------------------------------------------------------------------
-NwGtpv1uRcT gtpv1u_eNB_log_request(NwGtpv1uLogMgrHandleT hLogMgr,
-                                   uint32_t logLevel,
-                                   NwCharT *file,
-                                   uint32_t line,
-                                   NwCharT *logStr) {
-  LOG_D(GTPU, "%s\n", logStr);
-  return NW_GTPV1U_OK;
-}
-
-//-----------------------------------------------------------------------------
-NwGtpv1uRcT gtpv1u_eNB_send_udp_msg(
-  NwGtpv1uUdpHandleT udpHandle,
-  uint8_t *buffer,
-  uint32_t buffer_len,
-  uint32_t buffer_offset,
-  uint32_t peerIpAddr,
-  uint16_t peerPort) {
-  // 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);
-
-  if (message_p) {
-#if defined(LOG_GTPU) && LOG_GTPU > 0
-    LOG_D(GTPU, "Sending UDP_DATA_REQ length %u offset %u", buffer_len, buffer_offset);
-#endif
-    udp_data_req_p = &message_p->ittiMsg.udp_data_req;
-    udp_data_req_p->peer_address  = peerIpAddr;
-    udp_data_req_p->peer_port     = peerPort;
-    udp_data_req_p->buffer        = buffer;
-    udp_data_req_p->buffer_length = buffer_len;
-    udp_data_req_p->buffer_offset = buffer_offset;
-    return itti_send_msg_to_task(TASK_UDP, INSTANCE_DEFAULT, message_p);
-  } else {
-    return NW_GTPV1U_FAILURE;
-  }
-}
-
-
-//-----------------------------------------------------------------------------
-/* Callback called when a gtpv1u message arrived on UDP interface */
-NwGtpv1uRcT gtpv1u_eNB_process_stack_req(
-  NwGtpv1uUlpHandleT hUlp,
-  NwGtpv1uUlpApiT   *pUlpApi) {
-  boolean_t           result             = FALSE;
-  teid_t              teid               = 0;
-  hashtable_rc_t      hash_rc            = HASH_TABLE_KEY_NOT_EXISTS;
-  gtpv1u_teid_data_t *gtpv1u_teid_data_p = NULL;
-  protocol_ctxt_t     ctxt;
-  NwGtpv1uRcT         rc;
-
-  switch(pUlpApi->apiType) {
-    /* Here there are two type of messages handled:
-     * - T-PDU
-     * - END-MARKER
-     */
-    case NW_GTPV1U_ULP_API_RECV_TPDU: {
-      uint8_t              buffer[NFAPI_MAX_PACKED_MESSAGE_SIZE];
-      uint32_t             buffer_len;
-      struct rrc_eNB_ue_context_s        *ue_context_p;
-      uint16_t             msgType = NW_GTP_GPDU;
-      NwGtpv1uMsgT     *pMsg = NULL;
-      /* Nw-gptv1u stack has processed a PDU. we can schedule it to PDCP
-       * for transmission.
-       */
-      teid = pUlpApi->apiInfo.recvMsgInfo.teid;
-      pMsg = (NwGtpv1uMsgT *) pUlpApi->apiInfo.recvMsgInfo.hMsg;
-      msgType = pMsg->msgType;
-
-      if (NW_GTPV1U_OK != nwGtpv1uMsgGetTpdu(pUlpApi->apiInfo.recvMsgInfo.hMsg,
-                                             buffer, &buffer_len)) {
-        LOG_E(GTPU, "Error while retrieving T-PDU");
-      }
-
-      itti_free(TASK_UDP, ((NwGtpv1uMsgT *)pUlpApi->apiInfo.recvMsgInfo.hMsg)->msgBuf);
-#if defined(GTP_DUMP_SOCKET) && GTP_DUMP_SOCKET > 0
-      gtpv1u_eNB_write_dump_socket(buffer,buffer_len);
-#endif
-      rc = nwGtpv1uMsgDelete(RC.gtpv1u_data_g->gtpv1u_stack,
-                             pUlpApi->apiInfo.recvMsgInfo.hMsg);
-
-      if (rc != NW_GTPV1U_OK) {
-        LOG_E(GTPU, "nwGtpv1uMsgDelete failed: 0x%x\n", rc);
-      }
-
-      //-----------------------
-      // GTPV1U->PDCP mapping
-      //-----------------------
-      hash_rc = hashtable_get(RC.gtpv1u_data_g->teid_mapping, teid, (void **)&gtpv1u_teid_data_p);
-
-      if (hash_rc == HASH_TABLE_OK) {
-#if defined(LOG_GTPU) && LOG_GTPU > 0
-        LOG_D(GTPU, "Received T-PDU from gtpv1u stack teid  %u size %d -> enb module id %u ue module id %u rab id %u\n",
-              teid,
-              buffer_len,
-              gtpv1u_teid_data_p->enb_id,
-              gtpv1u_teid_data_p->ue_id,
-              gtpv1u_teid_data_p->eps_bearer_id);
-#endif
-        //#warning "LG eps bearer mapping to DRB id to do (offset -4)"
-        PROTOCOL_CTXT_SET_BY_MODULE_ID(&ctxt, gtpv1u_teid_data_p->enb_id, ENB_FLAG_YES,  gtpv1u_teid_data_p->ue_id, 0, 0,gtpv1u_teid_data_p->enb_id);
-        MSC_LOG_TX_MESSAGE(
-          MSC_GTPU_ENB,
-          MSC_PDCP_ENB,
-          NULL,0,
-          MSC_AS_TIME_FMT" DATA-REQ rb %u size %u",
-          0,0,
-          (gtpv1u_teid_data_p->eps_bearer_id) ? gtpv1u_teid_data_p->eps_bearer_id - 4: 5-4,
-          buffer_len);
-        ue_context_p = rrc_eNB_get_ue_context(RC.rrc[ctxt.module_id], ctxt.rnti);
-
-        if((ue_context_p != NULL) &&
-            (ue_context_p->ue_context.handover_info != NULL) &&
-            (ue_context_p->ue_context.handover_info->state < HO_FORWARDING_COMPLETE)) {
-          if(msgType == NW_GTP_END_MARKER) {
-            /* in the source enb, UE in RRC_HO_EXECUTION mode */
-            if (ue_context_p->ue_context.StatusRrc == RRC_HO_EXECUTION && ue_context_p->ue_context.handover_info->state == HO_COMPLETE) {
-              /* set handover state */
-              //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);
-              memcpy(&GTPV1U_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);
-              return NW_GTPV1U_OK;
-            }
-          }
-
-          if (ue_context_p->ue_context.StatusRrc == RRC_HO_EXECUTION || ue_context_p->ue_context.StatusRrc == RRC_RECONFIGURED) {
-            int msgsrc = gtpv1u_eNB_get_msgsource(ue_context_p, teid);
-            LOG_D(GTPU,"UE INFO.ueStatus %d, handover state %d, forwarding state %d, from %s. message type %s\n",
-                  ue_context_p->ue_context.StatusRrc,
-                  ue_context_p->ue_context.handover_info->state,
-                  ue_context_p->ue_context.handover_info->forwarding_state,
-                  msgsrc == GTPV1U_MSG_FROM_SOURCE_ENB?"Source eNB":"EPC",
-                  msgsrc != GTPV1U_MSG_FROM_SOURCE_ENB? "UDP DATA" :
-                  msgType == NW_GTP_END_MARKER?"END MARKER":"DATA FORWARDING");
-
-	    /* target enb */
-            if(msgType == NW_GTP_END_MARKER) {
-              LOG_I(GTPU, "target end receive END MARKER\n");
-              ue_context_p->ue_context.handover_info->state = HO_END_MARKER;
-              gtpv1u_enb_delete_tunnel_req_t delete_tunnel_req;
-              memset(&delete_tunnel_req, 0, sizeof(delete_tunnel_req));
-              delete_tunnel_req.rnti = ctxt.rnti;
-              gtpv1u_delete_x2u_tunnel(ctxt.module_id, &delete_tunnel_req, GTPV1U_TARGET_ENB);
-              return NW_GTPV1U_OK;
-            }
-
-            /* form source eNB message */
-            if(msgsrc == GTPV1U_MSG_FROM_SOURCE_ENB) {
-              LOG_I(GTPU, "Received a message data forwarding length %d\n", buffer_len);
-#if defined(LOG_GTPU) && LOG_GTPU > 0
-              LOG_T(GTPU, "forwarding data info:\n", buffer_len);
-
-              for(int i=1; i<=buffer_len; i++) {
-                LOG_T(GTPU, "%02x ", buffer[i-1]);
-
-                if(i%20 == 0)LOG_T(GTPU, "\n");
-              }
-
-              LOG_T(GTPU, "\n");
-#endif
-              result = gtpv_data_req(
-                         &ctxt,
-                         (gtpv1u_teid_data_p->eps_bearer_id) ? gtpv1u_teid_data_p->eps_bearer_id - 4: 5-4,
-                         0, // mui
-                         SDU_CONFIRM_NO, // confirm
-                         buffer_len,
-                         buffer,
-                         PDCP_TRANSMISSION_MODE_DATA,
-                         TASK_DATA_FORWARDING
-                       );
-
-              if ( result == FALSE ) {
-                LOG_W(GTPU, "DATA FORWARDING message save failed\n");
-                return NW_GTPV1U_FAILURE;
-              }
-
-              ue_context_p->ue_context.handover_info->forwarding_state = FORWARDING_NO_EMPTY;
-              return NW_GTPV1U_OK;
-            }
-            /* from epc message */
-            else {
-              /* in the source enb, UE in RRC_HO_EXECUTION mode */
-              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);
-                memcpy(&GTPV1U_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;
-                GTPV1U_ENB_DATA_FORWARDING_REQ(msg).rab_id = gtpv1u_teid_data_p->eps_bearer_id;
-                GTPV1U_ENB_DATA_FORWARDING_REQ(msg).offset = GTPU_HEADER_OVERHEAD_MAX;
-#if defined(LOG_GTPU) && LOG_GTPU > 0
-                LOG_T(GTPU, "Send data forwarding sdu_buffer to target enb. len %d info\n", buffer);
-
-                for(int i=1; i<=buffer_len; i++) {
-                  LOG_T(GTPU, "%02x ", buffer[i-1]);
-
-                  if(i%20 == 0)LOG_T(GTPU, "\n");
-                }
-
-                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);
-                return NW_GTPV1U_OK;
-              }
-
-              /* target eNB. x2ho forwarding is processing. spgw message save to TASK_END_MARKER */
-              if(ue_context_p->ue_context.handover_info->state != HO_COMPLETE &&
-                  ue_context_p->ue_context.handover_info->state != HO_END_MARKER ) {
-                LOG_I(GTPU, "x2ho forwarding is processing. Received a spgw message. length %d\n", buffer_len);
-#if defined(LOG_GTPU) && LOG_GTPU > 0
-                LOG_T(GTPU, "spgw data info:\n", buffer_len);
-
-                for(int i=1; i<=buffer_len; i++) {
-                  LOG_T(GTPU, "%02x ", buffer[i-1]);
-
-                  if(i%20 == 0)LOG_T(GTPU, "\n");
-                }
-
-                LOG_T(GTPU, "\n");
-#endif
-                result = gtpv_data_req(
-                           &ctxt,
-                           (gtpv1u_teid_data_p->eps_bearer_id) ? gtpv1u_teid_data_p->eps_bearer_id - 4: 5-4,
-                           0, // mui
-                           SDU_CONFIRM_NO, // confirm
-                           buffer_len,
-                           buffer,
-                           PDCP_TRANSMISSION_MODE_DATA,
-                           TASK_END_MARKER
-                         );
-
-                if ( result == FALSE ) {
-                  LOG_W(GTPU, "DATA FORWARDING message save failed\n");
-                  return NW_GTPV1U_FAILURE;
-                }
-
-                ue_context_p->ue_context.handover_info->endmark_state = ENDMARK_NO_EMPTY;
-                return NW_GTPV1U_OK;
-              }
-            }
-          }
-        }
-
-        result = pdcp_data_req(
-                   &ctxt,
-                   SRB_FLAG_NO,
-                   (gtpv1u_teid_data_p->eps_bearer_id) ? gtpv1u_teid_data_p->eps_bearer_id - 4: 5-4,
-                   0, // mui
-                   SDU_CONFIRM_NO, // confirm
-                   buffer_len,
-                   buffer,
-                   PDCP_TRANSMISSION_MODE_DATA,NULL, NULL
-                 );
-
-        if ( result == FALSE ) {
-          LOG_W(GTPU, "PDCP data request failed\n");
-          return NW_GTPV1U_FAILURE;
-        }
-      } else {
-        LOG_W(GTPU, "Received T-PDU from gtpv1u stack teid %u unknown size %u", teid, buffer_len);
-      }
-    }
-    break;
-
-    default: {
-      LOG_E(GTPU, "Received undefined UlpApi (%02x) from gtpv1u stack!\n",
-            pUlpApi->apiType);
-    }
-  } // end of switch
-
-  return NW_GTPV1U_OK;
-}
-
-
-//-----------------------------------------------------------------------------
-int data_recv_callback(uint16_t  portP,
-                       uint32_t  address,
-                       uint8_t  *buffer,
-                       uint32_t  length,
-                       void     *arg_p) {
-  gtpv1u_data_t        *gtpv1u_data_p;
-
-  if (arg_p == NULL) {
-    return -1;
-  }
-
-  gtpv1u_data_p = (gtpv1u_data_t *)arg_p;
-  return nwGtpv1uProcessUdpReq(gtpv1u_data_p->gtpv1u_stack,
-                               buffer,
-                               length,
-                               portP,
-                               address);
-}
-
-//int
-//gtpv1u_create_tunnel_endpoint(
-//    gtpv1u_data_t *gtpv1u_data_pP,
-//    uint8_t        ue_idP,
-//    uint8_t        rab_idP,
-//    char          *sgw_ip_addr_pP,
-//    uint16_t       portP)
-//{
-//    uint32_t                     teid;
-//    uint8_t                      max_attempt = 100;
-//    NwGtpv1uRcT                  rc          = NW_GTPV1U_FAILURE;
-//    NwGtpv1uUlpApiT              ulp_req;
-//    struct gtpv1u_ue_data_s     *new_ue_p    = NULL;
-//    struct gtpv1u_bearer_s      *bearer_p    = NULL;
-//    hashtable_rc_t               hash_rc     = HASH_TABLE_KEY_NOT_EXISTS;;
-//
-//    if (rab_idP > GTPV1U_MAX_BEARERS_PER_UE) {
-//        LOG_E(GTPU, "Could not use rab_id %d > max %d\n",
-//              rab_idP, GTPV1U_MAX_BEARERS_PER_UE);
-//        return -1;
-//    }
-//
-//
-//    if ((hash_rc = hashtable_get(gtpv1u_data_pP->ue_mapping, (uint64_t)ue_idP, (void**)&new_ue_p)) == HASH_TABLE_OK) {
-//        /* A context for this UE already exist in the tree, use it */
-//        /* We check that the tunnel is not already configured */
-//        if (new_ue_p->bearers[rab_idP].state != BEARER_DOWN) {
-//            LOG_E(GTPU, "Cannot create new end-point over already existing tunnel\n");
-//            return -1;
-//        }
-//    } else {
-//        /* Context doesn't exist, create it */
-//        if (rab_idP != 0) {
-//            /* UE should first establish Default bearer before trying to setup
-//             * additional bearers.
-//             */
-//            LOG_E(GTPU, "UE context is not known and rab_id != 0\n");
-//            return -1;
-//        }
-//        new_ue_p = calloc(1, sizeof(struct gtpv1u_ue_data_s));
-//        new_ue_p->ue_id = ue_idP;
-//
-//        hash_rc = hashtable_insert(gtpv1u_data_pP->ue_mapping, (uint64_t)ue_idP, new_ue_p);
-//
-//        if ((hash_rc != HASH_TABLE_OK) && (hash_rc != HASH_TABLE_INSERT_OVERWRITTEN_DATA)) {
-//            LOG_E(GTPU, "Failed to insert new UE context\n");
-//            free(new_ue_p);
-//            return -1;
-//        }
-//    }
-//
-//    bearer_p = &new_ue_p->bearers[rab_idP];
-//
-//    /* Configure the bearer */
-//    bearer_p->state       = BEARER_IN_CONFIG;
-//    bearer_p->sgw_ip_addr = inet_addr(sgw_ip_addr_pP);
-//    bearer_p->port        = portP;
-//
-//    /* Create the new stack api request */
-//    memset(&ulp_req, 0, sizeof(NwGtpv1uUlpApiT));
-//    ulp_req.apiType = NW_GTPV1U_ULP_API_CREATE_TUNNEL_ENDPOINT;
-//
-//    /* Try to create new tunnel-endpoint.
-//     * If teid generated is already present in the stack, just peek another random
-//     * teid. This could be ok for small number of tunnel but more errors could be
-//     * thrown if we reached high number of tunnels.
-//     * TODO: find a solution for teid
-//     */
-//    do {
-//        /* Request for a new random TEID */
-//        teid = gtpv1u_new_teid();
-//        ulp_req.apiInfo.createTunnelEndPointInfo.teid = teid;
-//
-//        rc = nwGtpv1uProcessUlpReq(gtpv1u_data_pP->gtpv1u_stack, &ulp_req);
-//
-//        if (rc == NW_GTPV1U_OK) {
-////             LOG_D(GTPU, "Successfully created new tunnel endpoint for teid 0x%x\n",
-////                   teid);
-//            bearer_p->teid_eNB = teid;
-////             gtpv1u_initial_req(gtpv1u_data_pP, teid, GTPV1U_UDP_PORT,
-////                                inet_addr("192.168.56.101"));
-//            LOG_I(GTPU, "Created eNB tunnel endpoint %u for ue id %u, rab id %u\n", teid, ue_idP, rab_idP);
-//            return 0;
-//        } else {
-//            LOG_W(GTPU, "Teid %u already in use... %s\n",
-//                  teid, (max_attempt > 1) ? "Trying another one" : "Last chance");
-//        }
-//    } while(max_attempt-- && rc != NW_GTPV1U_OK);
-//
-//    bearer_p->state = BEARER_DOWN;
-//    LOG_I(GTPU, "Failed to created eNB tunnel endpoint %u for ue id %u, rab id %u, bearer down\n", teid, ue_idP, rab_idP);
-//
-//    return -1;
-//}
-
-
-//-----------------------------------------------------------------------------
-static NwGtpv1uRcT gtpv1u_start_timer_wrapper(
-  NwGtpv1uTimerMgrHandleT tmrMgrHandle,
-  uint32_t                  timeoutSec,
-  uint32_t                  timeoutUsec,
-  uint32_t                  tmrType,
-  void                   *timeoutArg,
-  NwGtpv1uTimerHandleT   *hTmr) {
-  NwGtpv1uRcT rc = NW_GTPV1U_OK;
-  long        timer_id;
-
-  if (tmrType == NW_GTPV1U_TMR_TYPE_ONE_SHOT) {
-    timer_setup(timeoutSec,
-                timeoutUsec,
-                TASK_GTPV1_U,
-                INSTANCE_DEFAULT,
-                TIMER_ONE_SHOT,
-                timeoutArg,
-                &timer_id);
-  } else {
-    timer_setup(timeoutSec,
-                timeoutUsec,
-                TASK_GTPV1_U,
-                INSTANCE_DEFAULT,
-                TIMER_PERIODIC,
-                timeoutArg,
-                &timer_id);
-  }
-
-  return rc;
-}
-
-
-//-----------------------------------------------------------------------------
-static NwGtpv1uRcT
-gtpv1u_stop_timer_wrapper(
-  NwGtpv1uTimerMgrHandleT tmrMgrHandle,
-  NwGtpv1uTimerHandleT hTmr) {
-  NwGtpv1uRcT rc = NW_GTPV1U_OK;
-  return rc;
-}
-
-
-//-----------------------------------------------------------------------------
-int
-gtpv1u_initial_req(
-  gtpv1u_data_t *gtpv1u_data_pP,
-  teid_t         teidP,
-  tcp_udp_port_t portP,
-  uint32_t       address) {
-  NwGtpv1uUlpApiT ulp_req;
-  NwGtpv1uRcT     rc = NW_GTPV1U_FAILURE;
-  memset(&ulp_req, 0, sizeof(NwGtpv1uUlpApiT));
-  ulp_req.apiType = NW_GTPV1U_ULP_API_INITIAL_REQ;
-  ulp_req.apiInfo.initialReqInfo.teid     = teidP;
-  ulp_req.apiInfo.initialReqInfo.peerPort = portP;
-  ulp_req.apiInfo.initialReqInfo.peerIp   = address;
-  rc = nwGtpv1uProcessUlpReq(gtpv1u_data_pP->gtpv1u_stack, &ulp_req);
-
-  if (rc == NW_GTPV1U_OK) {
-    LOG_D(GTPU, "Successfully sent initial req for teid %u\n", teidP);
-  } else {
-    LOG_W(GTPU, "Could not send initial req for teid %u\n", teidP);
-  }
-
-  return (rc == NW_GTPV1U_OK) ? 0 : -1;
-}
-
-//-----------------------------------------------------------------------------
-int
-gtpv1u_new_data_req(
-  uint8_t  enb_module_idP,
-  rnti_t   ue_rntiP,
-  uint8_t  rab_idP,
-  uint8_t *buffer_pP,
-  uint32_t buf_lenP,
-  uint32_t buf_offsetP
-) {
-  NwGtpv1uUlpApiT          stack_req;
-  NwGtpv1uRcT              rc            = NW_GTPV1U_FAILURE;
-  struct gtpv1u_ue_data_s  ue;
-  struct gtpv1u_ue_data_s *ue_inst_p     = NULL;
-  struct gtpv1u_bearer_s  *bearer_p      = NULL;
-  hashtable_rc_t           hash_rc       = HASH_TABLE_KEY_NOT_EXISTS;;
-  gtpv1u_data_t           *gtpv1u_data_p = NULL;
-  memset(&ue, 0, sizeof(struct gtpv1u_ue_data_s));
-  ue.ue_id = ue_rntiP;
-  AssertFatal(enb_module_idP >=0, "Bad parameter enb module id %u\n", enb_module_idP);
-  AssertFatal((rab_idP - GTPV1U_BEARER_OFFSET)< GTPV1U_MAX_BEARERS_ID, "Bad parameter rab id %u\n", rab_idP);
-  AssertFatal((rab_idP - GTPV1U_BEARER_OFFSET) >= 0, "Bad parameter rab id %u\n", rab_idP);
-  gtpv1u_data_p = RC.gtpv1u_data_g;
-  /* Check that UE context is present in ue map. */
-  hash_rc = hashtable_get(gtpv1u_data_p->ue_mapping, (uint64_t)ue_rntiP, (void **)&ue_inst_p);
-
-  if (hash_rc ==  HASH_TABLE_KEY_NOT_EXISTS ) {
-    LOG_E(GTPU, "[UE %d] Trying to send data on non-existing UE context\n", ue_rntiP);
-    return -1;
-  }
-
-  bearer_p = &ue_inst_p->bearers[rab_idP - GTPV1U_BEARER_OFFSET];
-
-  /* Ensure the bearer in ready.
-   * TODO: handle the cases where the bearer is in HANDOVER state.
-   * In such case packets should be placed in FIFO.
-   */
-  if (bearer_p->state != BEARER_UP) {
-    LOG_W(GTPU, "Trying to send data over bearer with state(%u) != BEARER_UP\n",
-          bearer_p->state);
-    //#warning  LG: HACK WHILE WAITING FOR NAS, normally return -1
-
-    if (bearer_p->state != BEARER_IN_CONFIG)
-      return -1;
-  }
-
-  memset(&stack_req, 0, sizeof(NwGtpv1uUlpApiT));
-  stack_req.apiType                   = NW_GTPV1U_ULP_API_SEND_TPDU;
-  stack_req.apiInfo.sendtoInfo.teid   = bearer_p->teid_sgw;
-  stack_req.apiInfo.sendtoInfo.ipAddr = bearer_p->sgw_ip_addr;
-  LOG_D(GTPU, "TX TO TEID %u addr 0x%x\n",bearer_p->teid_sgw, bearer_p->sgw_ip_addr);
-  rc = nwGtpv1uGpduMsgNew(gtpv1u_data_p->gtpv1u_stack,
-                          bearer_p->teid_sgw,
-                          NW_FALSE,
-                          gtpv1u_data_p->seq_num++,
-                          buffer_pP,
-                          buf_lenP,
-                          buf_offsetP,
-                          &(stack_req.apiInfo.sendtoInfo.hMsg));
-
-  if (rc != NW_GTPV1U_OK) {
-    LOG_E(GTPU, "nwGtpv1uGpduMsgNew failed: 0x%x\n", rc);
-    return -1;
-  }
-
-  rc = nwGtpv1uProcessUlpReq(gtpv1u_data_p->gtpv1u_stack,
-                             &stack_req);
-
-  if (rc != NW_GTPV1U_OK) {
-    LOG_E(GTPU, "nwGtpv1uProcessUlpReq failed: 0x%x\n", rc);
-    return -1;
-  }
-
-  rc = nwGtpv1uMsgDelete(gtpv1u_data_p->gtpv1u_stack,
-                         stack_req.apiInfo.sendtoInfo.hMsg);
-
-  if (rc != NW_GTPV1U_OK) {
-    LOG_E(GTPU, "nwGtpv1uMsgDelete failed: 0x%x\n", rc);
-    return -1;
-  }
-
-  LOG_D(GTPU, "%s() return code OK\n", __FUNCTION__);
-  return 0;
-}
-
-//-----------------------------------------------------------------------------
-int
-gtpv1u_create_x2u_tunnel(
-  const instance_t                              instanceP,
-  const gtpv1u_enb_create_x2u_tunnel_req_t *const  create_tunnel_req_pP,
-  gtpv1u_enb_create_x2u_tunnel_resp_t *const create_tunnel_resp_pP
-) {
-  /* Create a new nw-gtpv1-u stack req using API */
-  NwGtpv1uUlpApiT          stack_req;
-  NwGtpv1uRcT              rc                   = NW_GTPV1U_FAILURE;
-  /* Local tunnel end-point identifier */
-  teid_t                   x2u_teid             = 0;
-  gtpv1u_teid_data_t      *gtpv1u_teid_data_p   = NULL;
-  hashtable_rc_t           hash_rc              = HASH_TABLE_KEY_NOT_EXISTS;
-  int                      i;
-  ebi_t                    eps_bearer_id        = 0;
-  MSC_LOG_RX_MESSAGE(
-    MSC_GTPU_ENB,
-    MSC_RRC_ENB,
-    NULL,0,
-    MSC_AS_TIME_FMT" CREATE_X2U_TUNNEL_REQ RNTI %"PRIx16" inst %u ntuns %u ebid %u enb-x2u teid %u",
-    0,0,create_tunnel_req_pP->rnti, instanceP,
-    create_tunnel_req_pP->num_tunnels, create_tunnel_req_pP->eps_bearer_id[0],
-    create_tunnel_req_pP->tenb_X2u_teid[0]);
-  create_tunnel_resp_pP->rnti        = create_tunnel_req_pP->rnti;
-  create_tunnel_resp_pP->status      = 0;
-  create_tunnel_resp_pP->num_tunnels = 0;
-
-  for (i = 0; i < create_tunnel_req_pP->num_tunnels; i++) {
-    eps_bearer_id = create_tunnel_req_pP->eps_bearer_id[i];
-    LOG_D(GTPU, "Rx GTPV1U_ENB_CREATE_X2U_TUNNEL_REQ ue rnti %x eps bearer id %u\n",
-          create_tunnel_req_pP->rnti, eps_bearer_id);
-    memset(&stack_req, 0, sizeof(NwGtpv1uUlpApiT));
-    stack_req.apiType = NW_GTPV1U_ULP_API_CREATE_TUNNEL_ENDPOINT;
-
-    do {
-      x2u_teid = gtpv1u_new_teid();
-      LOG_D(GTPU, "gtpv1u_create_x2u_tunnel() 0x%x %u(dec)\n", x2u_teid, x2u_teid);
-      stack_req.apiInfo.createTunnelEndPointInfo.teid          = x2u_teid;
-      stack_req.apiInfo.createTunnelEndPointInfo.hUlpSession   = 0;
-      stack_req.apiInfo.createTunnelEndPointInfo.hStackSession = 0;
-      rc = nwGtpv1uProcessUlpReq(RC.gtpv1u_data_g->gtpv1u_stack, &stack_req);
-      LOG_D(GTPU, ".\n");
-    } while (rc != NW_GTPV1U_OK);
-
-    memcpy(&create_tunnel_resp_pP->enb_addr.buffer,
-           &RC.gtpv1u_data_g->enb_ip_address_for_S1u_S12_S4_up,
-           sizeof (in_addr_t));
-    LOG_D(GTPU, "gtpv1u_create_x2u_tunnel() end addr %d.%d.%d.%d\n",
-          create_tunnel_resp_pP->enb_addr.buffer[0],
-          create_tunnel_resp_pP->enb_addr.buffer[1],
-          create_tunnel_resp_pP->enb_addr.buffer[2],
-          create_tunnel_resp_pP->enb_addr.buffer[3]);
-    create_tunnel_resp_pP->enb_addr.length  = sizeof (in_addr_t);
-    create_tunnel_resp_pP->eps_bearer_id[i] = eps_bearer_id;
-    create_tunnel_resp_pP->num_tunnels      += 1;
-    //-----------------------
-    // GTPV1U->PDCP mapping
-    //-----------------------
-    create_tunnel_resp_pP->enb_X2u_teid[i] = x2u_teid;
-    hash_rc = hashtable_get(RC.gtpv1u_data_g->teid_mapping, x2u_teid, (void **)&gtpv1u_teid_data_p);
-
-    if (hash_rc == HASH_TABLE_KEY_NOT_EXISTS) {
-      gtpv1u_teid_data_p = calloc (1, sizeof(gtpv1u_teid_data_t));
-      gtpv1u_teid_data_p->enb_id        = 0; // TO DO
-      gtpv1u_teid_data_p->ue_id         = create_tunnel_req_pP->rnti;
-      gtpv1u_teid_data_p->eps_bearer_id = eps_bearer_id;
-      hash_rc = hashtable_insert(RC.gtpv1u_data_g->teid_mapping, x2u_teid, gtpv1u_teid_data_p);
-      AssertFatal(hash_rc == HASH_TABLE_OK, "Error inserting teid mapping in GTPV1U hashtable");
-    } else {
-      create_tunnel_resp_pP->enb_X2u_teid[i] = 0;
-      create_tunnel_resp_pP->status         = 0xFF;
-    }
-  }
-
-  MSC_LOG_TX_MESSAGE(
-    MSC_GTPU_ENB,
-    MSC_RRC_ENB,
-    NULL,0,
-    "0 GTPV1U_ENB_CREATE_TUNNEL_RESP rnti %x teid %x",
-    create_tunnel_resp_pP->rnti,
-    x2u_teid);
-  LOG_D(GTPU, "Tx GTPV1U_ENB_CREATE_TUNNEL_RESP ue rnti %x status %d\n",
-        create_tunnel_req_pP->rnti,
-        create_tunnel_resp_pP->status);
-  return 0;
-}
-
-//-----------------------------------------------------------------------------
-int gtpv1u_delete_x2u_tunnel(
-  const instance_t                             instanceP,
-  const gtpv1u_enb_delete_tunnel_req_t *const req_pP,
-  int                             enbflag) {
-  gtpv1u_ue_data_t        *gtpv1u_ue_data_p     = NULL;
-  hashtable_rc_t           hash_rc              = HASH_TABLE_KEY_NOT_EXISTS;
-  int                      erab_index           = 0;
-  ebi_t                    eps_bearer_id        = 0;
-  struct rrc_eNB_ue_context_s *ue_context_p     = NULL;
-  ue_context_p = rrc_eNB_get_ue_context(RC.rrc[instanceP], req_pP->rnti);
-
-  if(ue_context_p != NULL) {
-    /* in the source enb */
-    if(enbflag == GTPV1U_SOURCE_ENB) {
-      hash_rc = hashtable_get(RC.gtpv1u_data_g->ue_mapping, req_pP->rnti, (void **)&gtpv1u_ue_data_p);
-
-      if (hash_rc == HASH_TABLE_OK) {
-        for (erab_index = 0; erab_index < ue_context_p->ue_context.nb_x2u_e_rabs; erab_index++) {
-          eps_bearer_id = ue_context_p->ue_context.enb_gtp_x2u_ebi[erab_index];
-          LOG_I(GTPU, "gtpv1u_delete_x2u_tunnel user rnti %x teNB X2U teid %u eps bearer id %ld\n",
-                req_pP->rnti,
-                gtpv1u_ue_data_p->bearers[eps_bearer_id - GTPV1U_BEARER_OFFSET].teid_teNB,
-                ue_context_p->ue_context.enb_gtp_x2u_ebi[erab_index]);
-          gtpv1u_ue_data_p->bearers[eps_bearer_id - GTPV1U_BEARER_OFFSET].teid_teNB = 0;
-          gtpv1u_ue_data_p->bearers[eps_bearer_id - GTPV1U_BEARER_OFFSET].tenb_ip_addr = 0;
-          //gtpv1u_ue_data_p->bearers[eps_bearer_id - GTPV1U_BEARER_OFFSET].tenb_ip6_addr = 0;
-        }
-
-        ue_context_p->ue_context.nb_x2u_e_rabs = 0;
-      }
-    }
-    /* in the target enb */
-    else {
-      for (erab_index = 0; erab_index < ue_context_p->ue_context.nb_x2u_e_rabs; erab_index++) {
-        //-----------------------
-        // GTPV1U->PDCP mapping
-        //-----------------------
-        hash_rc = hashtable_remove(RC.gtpv1u_data_g->teid_mapping, ue_context_p->ue_context.enb_gtp_x2u_teid[erab_index]);
-        LOG_I(GTPU, "Removed user rnti %x , enb X2U teid %u\n", req_pP->rnti, ue_context_p->ue_context.enb_gtp_x2u_teid[erab_index]);
-
-        if (hash_rc != HASH_TABLE_OK) {
-          LOG_D(GTPU, "Removed user rnti %x , enb X2U teid %u not found\n", req_pP->rnti, ue_context_p->ue_context.enb_gtp_x2u_teid[erab_index]);
-        }
-      }
-
-      ue_context_p->ue_context.nb_x2u_e_rabs = 0;
-    }
-  }
-
-  return 0;
-}
-
-//-----------------------------------------------------------------------------
-int
-gtpv1u_create_s1u_tunnel(
-  const instance_t                              instanceP,
-  const gtpv1u_enb_create_tunnel_req_t *const  create_tunnel_req_pP,
-  gtpv1u_enb_create_tunnel_resp_t *const create_tunnel_resp_pP
-) {
-  /* Create a new nw-gtpv1-u stack req using API */
-  NwGtpv1uUlpApiT          stack_req;
-  NwGtpv1uRcT              rc                   = NW_GTPV1U_FAILURE;
-  /* Local tunnel end-point identifier */
-  teid_t                   s1u_teid             = 0;
-  gtpv1u_teid_data_t      *gtpv1u_teid_data_p   = NULL;
-  gtpv1u_ue_data_t        *gtpv1u_ue_data_p     = NULL;
-  //MessageDef              *message_p            = NULL;
-  hashtable_rc_t           hash_rc              = HASH_TABLE_KEY_NOT_EXISTS;
-  int                      i;
-  ebi_t                    eps_bearer_id        = 0;
-  //    int                      ipv4_addr            = 0;
-  int                      ip_offset            = 0;
-  in_addr_t                in_addr;
-  int                      addrs_length_in_bytes= 0;
-  int                      loop_counter         = 0;
-  int                      ret                  = 0;
-  MSC_LOG_RX_MESSAGE(
-    MSC_GTPU_ENB,
-    MSC_RRC_ENB,
-    NULL,0,
-    MSC_AS_TIME_FMT" CREATE_TUNNEL_REQ RNTI %"PRIx16" inst %u ntuns %u ebid %u sgw-s1u teid %u",
-    0,0,create_tunnel_req_pP->rnti, instanceP,
-    create_tunnel_req_pP->num_tunnels, create_tunnel_req_pP->eps_bearer_id[0],
-    create_tunnel_req_pP->sgw_S1u_teid[0]);
-  create_tunnel_resp_pP->rnti        = create_tunnel_req_pP->rnti;
-  create_tunnel_resp_pP->status      = 0;
-  create_tunnel_resp_pP->num_tunnels = 0;
-
-  for (i = 0; i < create_tunnel_req_pP->num_tunnels; i++) {
-    ip_offset               = 0;
-    loop_counter            = 0;
-    eps_bearer_id = create_tunnel_req_pP->eps_bearer_id[i];
-    LOG_D(GTPU, "Rx GTPV1U_ENB_CREATE_TUNNEL_REQ ue rnti %x eps bearer id %u\n",
-          create_tunnel_req_pP->rnti, eps_bearer_id);
-    memset(&stack_req, 0, sizeof(NwGtpv1uUlpApiT));
-    stack_req.apiType = NW_GTPV1U_ULP_API_CREATE_TUNNEL_ENDPOINT;
-
-    do {
-      s1u_teid = gtpv1u_new_teid();
-      LOG_I(GTPU, "gtpv1u_data_g %p\n", RC.gtpv1u_data_g);
-      LOG_I(GTPU, "gtpv1u_create_s1u_tunnel() 0x%x %u(dec)\n", s1u_teid, s1u_teid);
-      stack_req.apiInfo.createTunnelEndPointInfo.teid          = s1u_teid;
-      stack_req.apiInfo.createTunnelEndPointInfo.hUlpSession   = 0;
-      stack_req.apiInfo.createTunnelEndPointInfo.hStackSession = 0;
-      rc = nwGtpv1uProcessUlpReq(RC.gtpv1u_data_g->gtpv1u_stack, &stack_req);
-      LOG_D(GTPU, ".\n");
-      loop_counter++;
-    } while (rc != NW_GTPV1U_OK && loop_counter < 10);
-
-    if ( rc != NW_GTPV1U_OK && loop_counter == 10 ) {
-      LOG_E(GTPU,"NwGtpv1uCreateTunnelEndPoint failed 10 times,start next loop\n");
-      ret = -1;
-      continue;
-    }
-
-    //-----------------------
-    // PDCP->GTPV1U mapping
-    //-----------------------
-    hash_rc = hashtable_get(RC.gtpv1u_data_g->ue_mapping, create_tunnel_req_pP->rnti, (void **)&gtpv1u_ue_data_p);
-
-    if ((hash_rc == HASH_TABLE_KEY_NOT_EXISTS) || (hash_rc == HASH_TABLE_OK)) {
-      if (hash_rc == HASH_TABLE_KEY_NOT_EXISTS) {
-        gtpv1u_ue_data_p = calloc (1, sizeof(gtpv1u_ue_data_t));
-        hash_rc = hashtable_insert(RC.gtpv1u_data_g->ue_mapping, create_tunnel_req_pP->rnti, gtpv1u_ue_data_p);
-        AssertFatal(hash_rc == HASH_TABLE_OK, "Error inserting ue_mapping in GTPV1U hashtable");
-      }
-
-      gtpv1u_ue_data_p->ue_id       = create_tunnel_req_pP->rnti;
-      gtpv1u_ue_data_p->instance_id = 0; // TO DO
-      memcpy(&create_tunnel_resp_pP->enb_addr.buffer,
-             &RC.gtpv1u_data_g->enb_ip_address_for_S1u_S12_S4_up,
-             sizeof (in_addr_t));
-     
-      LOG_I(GTPU,"Configured GTPu address : %x\n",RC.gtpv1u_data_g->enb_ip_address_for_S1u_S12_S4_up);
-      create_tunnel_resp_pP->enb_addr.length = sizeof (in_addr_t);
-      addrs_length_in_bytes = create_tunnel_req_pP->sgw_addr[i].length / 8;
-      AssertFatal((addrs_length_in_bytes == 4) ||
-                  (addrs_length_in_bytes == 16) ||
-                  (addrs_length_in_bytes == 20),
-                  "Bad transport layer address length %d (bits) %d (bytes)",
-                  create_tunnel_req_pP->sgw_addr[i].length, addrs_length_in_bytes);
-
-      if ((addrs_length_in_bytes == 4) ||
-          (addrs_length_in_bytes == 20)) {
-        in_addr = *((in_addr_t *)create_tunnel_req_pP->sgw_addr[i].buffer);
-        ip_offset = 4;
-        gtpv1u_ue_data_p->bearers[eps_bearer_id - GTPV1U_BEARER_OFFSET].sgw_ip_addr = in_addr;
-      }
-
-      if ((addrs_length_in_bytes == 16) ||
-          (addrs_length_in_bytes == 20)) {
-        memcpy(gtpv1u_ue_data_p->bearers[eps_bearer_id - GTPV1U_BEARER_OFFSET].sgw_ip6_addr.s6_addr,
-               &create_tunnel_req_pP->sgw_addr[i].buffer[ip_offset],
-               16);
-      }
-
-      gtpv1u_ue_data_p->bearers[eps_bearer_id - GTPV1U_BEARER_OFFSET].state                  = BEARER_IN_CONFIG;
-      gtpv1u_ue_data_p->bearers[eps_bearer_id - GTPV1U_BEARER_OFFSET].teid_eNB               = s1u_teid;
-      gtpv1u_ue_data_p->bearers[eps_bearer_id - GTPV1U_BEARER_OFFSET].teid_eNB_stack_session = stack_req.apiInfo.createTunnelEndPointInfo.hStackSession;
-      gtpv1u_ue_data_p->bearers[eps_bearer_id - GTPV1U_BEARER_OFFSET].teid_sgw               = create_tunnel_req_pP->sgw_S1u_teid[i];
-      gtpv1u_ue_data_p->num_bearers++;
-      create_tunnel_resp_pP->enb_S1u_teid[i] = s1u_teid;
-
-      LOG_I(GTPU,"Copied to create_tunnel_resp tunnel: index %d target gNB ip %d.%d.%d.%d length %d gtp teid %u\n",
-    		  i,
-    		  create_tunnel_resp_pP->enb_addr.buffer[0],
-    		  create_tunnel_resp_pP->enb_addr.buffer[1],
-    		  create_tunnel_resp_pP->enb_addr.buffer[2],
-    		  create_tunnel_resp_pP->enb_addr.buffer[3],
-    		  create_tunnel_resp_pP->enb_addr.length,
-    		  create_tunnel_resp_pP->enb_S1u_teid[i]);
-    } else {
-      create_tunnel_resp_pP->enb_S1u_teid[i] = 0;
-      create_tunnel_resp_pP->status         = 0xFF;
-    }
-
-    create_tunnel_resp_pP->eps_bearer_id[i] = eps_bearer_id;
-    create_tunnel_resp_pP->num_tunnels      += 1;
-    //-----------------------
-    // GTPV1U->PDCP mapping
-    //-----------------------
-    hash_rc = hashtable_get(RC.gtpv1u_data_g->teid_mapping, s1u_teid, (void **)&gtpv1u_teid_data_p);
-
-    if (hash_rc == HASH_TABLE_KEY_NOT_EXISTS) {
-      gtpv1u_teid_data_p = calloc (1, sizeof(gtpv1u_teid_data_t));
-      gtpv1u_teid_data_p->enb_id        = 0; // TO DO
-      gtpv1u_teid_data_p->ue_id         = create_tunnel_req_pP->rnti;
-      gtpv1u_teid_data_p->eps_bearer_id = eps_bearer_id;
-      hash_rc = hashtable_insert(RC.gtpv1u_data_g->teid_mapping, s1u_teid, gtpv1u_teid_data_p);
-      AssertFatal(hash_rc == HASH_TABLE_OK, "Error inserting teid mapping in GTPV1U hashtable");
-    } else {
-      create_tunnel_resp_pP->enb_S1u_teid[i] = 0;
-      create_tunnel_resp_pP->status         = 0xFF;
-    }
-  }
-
-  MSC_LOG_TX_MESSAGE(
-    MSC_GTPU_ENB,
-    MSC_RRC_ENB,
-    NULL,0,
-    "0 GTPV1U_ENB_CREATE_TUNNEL_RESP rnti %x teid %x",
-    create_tunnel_resp_pP->rnti,
-    s1u_teid);
-  LOG_D(GTPU, "Tx GTPV1U_ENB_CREATE_TUNNEL_RESP ue rnti %x status %d\n",
-        create_tunnel_req_pP->rnti,
-        create_tunnel_resp_pP->status);
-  //return 0;
-  return ret;
-}
-
-int gtpv1u_update_s1u_tunnel(
-  const instance_t                              instanceP,
-  const gtpv1u_enb_create_tunnel_req_t *const  create_tunnel_req_pP,
-  const rnti_t                                  prior_rnti
-) {
-  /* Local tunnel end-point identifier */
-  teid_t                   s1u_teid             = 0;
-  gtpv1u_teid_data_t      *gtpv1u_teid_data_p   = NULL;
-  gtpv1u_ue_data_t        *gtpv1u_ue_data_p     = NULL;
-  gtpv1u_ue_data_t        *gtpv1u_ue_data_new_p     = NULL;
-  //MessageDef              *message_p            = NULL;
-  hashtable_rc_t           hash_rc              = HASH_TABLE_KEY_NOT_EXISTS;
-  int                      i,j;
-  uint8_t                  bearers_num = 0,bearers_total = 0;
-  //-----------------------
-  // PDCP->GTPV1U mapping
-  //-----------------------
-  hash_rc = hashtable_get(RC.gtpv1u_data_g->ue_mapping, prior_rnti, (void **)&gtpv1u_ue_data_p);
-
-  if(hash_rc != HASH_TABLE_OK) {
-    LOG_E(GTPU,"Error get ue_mapping(rnti=%x) from GTPV1U hashtable error\n", prior_rnti);
-    return -1;
-  }
-
-  gtpv1u_ue_data_new_p = calloc (1, sizeof(gtpv1u_ue_data_t));
-  memcpy(gtpv1u_ue_data_new_p,gtpv1u_ue_data_p,sizeof(gtpv1u_ue_data_t));
-  gtpv1u_ue_data_new_p->ue_id       = create_tunnel_req_pP->rnti;
-  hash_rc = hashtable_insert(RC.gtpv1u_data_g->ue_mapping, create_tunnel_req_pP->rnti, gtpv1u_ue_data_new_p);
-
-  //AssertFatal(hash_rc == HASH_TABLE_OK, "Error inserting ue_mapping in GTPV1U hashtable");
-  if ( hash_rc != HASH_TABLE_OK ) {
-    LOG_E(GTPU,"Failed to insert ue_mapping(rnti=%x) in GTPV1U hashtable\n",create_tunnel_req_pP->rnti);
-    return -1;
-  } else {
-    LOG_I(GTPU, "inserting ue_mapping(rnti=%x) in GTPV1U hashtable\n",
-          create_tunnel_req_pP->rnti);
-  }
-
-  hash_rc = hashtable_remove(RC.gtpv1u_data_g->ue_mapping, prior_rnti);
-  LOG_I(GTPU, "hashtable_remove ue_mapping(rnti=%x) in GTPV1U hashtable\n",
-        prior_rnti);
-  //-----------------------
-  // GTPV1U->PDCP mapping
-  //-----------------------
-  bearers_total =gtpv1u_ue_data_new_p->num_bearers;
-
-  for(j = 0; j<GTPV1U_MAX_BEARERS_ID; j++) {
-    if(gtpv1u_ue_data_new_p->bearers[j].state != BEARER_IN_CONFIG)
-      continue;
-
-    bearers_num++;
-
-    for (i = 0; i < create_tunnel_req_pP->num_tunnels; i++) {
-      if(j == (create_tunnel_req_pP->eps_bearer_id[i]-GTPV1U_BEARER_OFFSET))
-        break;
-    }
-
-    if(i < create_tunnel_req_pP->num_tunnels) {
-      s1u_teid = gtpv1u_ue_data_new_p->bearers[j].teid_eNB;
-      hash_rc = hashtable_get(RC.gtpv1u_data_g->teid_mapping, s1u_teid, (void **)&gtpv1u_teid_data_p);
-
-      if (hash_rc == HASH_TABLE_OK) {
-        gtpv1u_teid_data_p->ue_id         = create_tunnel_req_pP->rnti;
-        gtpv1u_teid_data_p->eps_bearer_id = create_tunnel_req_pP->eps_bearer_id[i];
-        LOG_I(GTPU, "updata teid_mapping te_id %u (prior_rnti %x rnti %x) in GTPV1U hashtable\n",
-              s1u_teid,prior_rnti,create_tunnel_req_pP->rnti);
-      } else {
-        LOG_W(GTPU, "Error get teid mapping(s1u_teid=%u) from GTPV1U hashtable", s1u_teid);
-      }
-    } else {
-      s1u_teid = gtpv1u_ue_data_new_p->bearers[j].teid_eNB;
-      hash_rc = hashtable_remove(RC.gtpv1u_data_g->teid_mapping, s1u_teid);
-
-      if (hash_rc != HASH_TABLE_OK) {
-        LOG_D(GTPU, "Removed user rnti %x , enb S1U teid %u not found\n", prior_rnti, s1u_teid);
-      }
-
-      gtpv1u_ue_data_new_p->bearers[j].state = BEARER_DOWN;
-      gtpv1u_ue_data_new_p->num_bearers--;
-      LOG_I(GTPU, "delete teid_mapping te_id %u (rnti%x) bearer_id %d in GTPV1U hashtable\n",
-            s1u_teid,prior_rnti,j+GTPV1U_BEARER_OFFSET);;
-    }
-
-    if(bearers_num > bearers_total)
-      break;
-  }
-
-  return 0;
-}
-
-//-----------------------------------------------------------------------------
-int gtpv1u_delete_s1u_tunnel(
-  const instance_t                             instanceP,
-  const gtpv1u_enb_delete_tunnel_req_t *const req_pP) {
-  NwGtpv1uUlpApiT          stack_req;
-  NwGtpv1uRcT              rc                   = NW_GTPV1U_FAILURE;
-  MessageDef              *message_p = NULL;
-  gtpv1u_ue_data_t        *gtpv1u_ue_data_p     = NULL;
-  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);
-  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 **)&gtpv1u_ue_data_p);
-
-  if (hash_rc == HASH_TABLE_OK) {
-    for (erab_index = 0; erab_index < req_pP->num_erab; erab_index++) {
-      teid_eNB = gtpv1u_ue_data_p->bearers[req_pP->eps_bearer_id[erab_index] - GTPV1U_BEARER_OFFSET].teid_eNB;
-      LOG_D(GTPU, "Rx GTPV1U_ENB_DELETE_TUNNEL user rnti %x eNB S1U teid %u eps bearer id %u\n",
-            req_pP->rnti, teid_eNB, req_pP->eps_bearer_id[erab_index]);
-      {
-        memset(&stack_req, 0, sizeof(NwGtpv1uUlpApiT));
-        stack_req.apiType = NW_GTPV1U_ULP_API_DESTROY_TUNNEL_ENDPOINT;
-        LOG_D(GTPU, "gtpv1u_delete_s1u_tunnel erab %u  %u\n",
-              req_pP->eps_bearer_id[erab_index],
-              teid_eNB);
-        stack_req.apiInfo.destroyTunnelEndPointInfo.hStackSessionHandle   = gtpv1u_ue_data_p->bearers[req_pP->eps_bearer_id[erab_index] - GTPV1U_BEARER_OFFSET].teid_eNB_stack_session;
-        rc = nwGtpv1uProcessUlpReq(RC.gtpv1u_data_g->gtpv1u_stack, &stack_req);
-        LOG_D(GTPU, ".\n");
-      }
-
-      if (rc != NW_GTPV1U_OK) {
-        GTPV1U_ENB_DELETE_TUNNEL_RESP(message_p).status       |= 0xFF;
-        LOG_E(GTPU, "NW_GTPV1U_ULP_API_DESTROY_TUNNEL_ENDPOINT failed");
-      }
-
-      //-----------------------
-      // PDCP->GTPV1U mapping
-      //-----------------------
-      gtpv1u_ue_data_p->bearers[req_pP->eps_bearer_id[erab_index] - GTPV1U_BEARER_OFFSET].state       = BEARER_DOWN;
-      gtpv1u_ue_data_p->bearers[req_pP->eps_bearer_id[erab_index] - GTPV1U_BEARER_OFFSET].teid_eNB    = 0;
-      gtpv1u_ue_data_p->bearers[req_pP->eps_bearer_id[erab_index] - GTPV1U_BEARER_OFFSET].teid_sgw    = 0;
-      gtpv1u_ue_data_p->bearers[req_pP->eps_bearer_id[erab_index] - GTPV1U_BEARER_OFFSET].sgw_ip_addr = 0;
-      gtpv1u_ue_data_p->num_bearers -= 1;
-
-      if (gtpv1u_ue_data_p->num_bearers == 0) {
-        hash_rc = hashtable_remove(RC.gtpv1u_data_g->ue_mapping, req_pP->rnti);
-        LOG_D(GTPU, "Removed user rnti %x,no more bearers configured\n", req_pP->rnti);
-      }
-
-      //-----------------------
-      // GTPV1U->PDCP mapping
-      //-----------------------
-      hash_rc = hashtable_remove(RC.gtpv1u_data_g->teid_mapping, teid_eNB);
-
-      if (hash_rc != HASH_TABLE_OK) {
-        LOG_D(GTPU, "Removed user rnti %x , enb S1U teid %u not found\n", req_pP->rnti, teid_eNB);
-      }
-    }
-  }// else silently do nothing
-
-  LOG_D(GTPU, "Tx GTPV1U_ENB_DELETE_TUNNEL_RESP user rnti %x eNB S1U teid %u status %u\n",
-        GTPV1U_ENB_DELETE_TUNNEL_RESP(message_p).rnti,
-        GTPV1U_ENB_DELETE_TUNNEL_RESP(message_p).enb_S1u_teid,
-        GTPV1U_ENB_DELETE_TUNNEL_RESP(message_p).status);
-  MSC_LOG_TX_MESSAGE(
-    MSC_GTPU_ENB,
-    MSC_RRC_ENB,
-    NULL,0,
-    "0 GTPV1U_ENB_DELETE_TUNNEL_RESP rnti %x teid %x",
-    GTPV1U_ENB_DELETE_TUNNEL_RESP(message_p).rnti,
-    teid_eNB);
-  if (req_pP->from_gnb)
-    return itti_send_msg_to_task(TASK_RRC_GNB, instanceP, message_p);
-  else
-    return itti_send_msg_to_task(TASK_RRC_ENB, instanceP, message_p);
-}
-
-
-//-----------------------------------------------------------------------------
-int gtpv1u_eNB_init(void) {
-  NwGtpv1uRcT             rc = NW_GTPV1U_FAILURE;
-  NwGtpv1uUlpEntityT      ulp;
-  NwGtpv1uUdpEntityT      udp;
-  NwGtpv1uLogMgrEntityT   log;
-  NwGtpv1uTimerMgrEntityT tmr;
-  //  enb_properties_p = enb_config_get()->properties[0];
-  RC.gtpv1u_data_g = (gtpv1u_data_t *)calloc(sizeof(gtpv1u_data_t),1);
-  LOG_I(GTPU, "Initializing GTPU stack %p\n",&RC.gtpv1u_data_g);
-  //gtpv1u_data_g.gtpv1u_stack;
-  /* Initialize UE hashtable */
-  RC.gtpv1u_data_g->ue_mapping      = hashtable_create (32, NULL, NULL);
-  AssertFatal(RC.gtpv1u_data_g->ue_mapping != NULL, " ERROR Initializing TASK_GTPV1_U task interface: in hashtable_create returned %p\n", RC.gtpv1u_data_g->ue_mapping);
-  RC.gtpv1u_data_g->teid_mapping    = hashtable_create (256, NULL, NULL);
-  AssertFatal(RC.gtpv1u_data_g->teid_mapping != NULL, " ERROR Initializing TASK_GTPV1_U task interface: in hashtable_create\n");
-  //  RC.gtpv1u_data_g.enb_ip_address_for_S1u_S12_S4_up         = enb_properties_p->enb_ipv4_address_for_S1U;
-  //gtpv1u_data_g.udp_data;
-  RC.gtpv1u_data_g->seq_num         = 0;
-  RC.gtpv1u_data_g->restart_counter = 0;
-  RC.gtpv1u_data_g->enb_ip_address_for_S1u_S12_S4_up = 0;
-  /* Initializing GTPv1-U stack */
-  if ((rc = nwGtpv1uInitialize(&RC.gtpv1u_data_g->gtpv1u_stack, GTPU_STACK_ENB)) != NW_GTPV1U_OK) {
-    LOG_E(GTPU, "Failed to setup nwGtpv1u stack %x\n", rc);
-    return -1;
-  }
-
-  if ((rc = nwGtpv1uSetLogLevel(RC.gtpv1u_data_g->gtpv1u_stack,
-                                NW_LOG_LEVEL_DEBG)) != NW_GTPV1U_OK) {
-    LOG_E(GTPU, "Failed to setup loglevel for stack %x\n", rc);
-    return -1;
-  }
-
-  /* Set the ULP API callback. Called once message have been processed by the
-   * nw-gtpv1u stack.
-   */
-  ulp.ulpReqCallback = gtpv1u_eNB_process_stack_req;
-  memset((void *)&(ulp.hUlp), 0, sizeof(NwGtpv1uUlpHandleT));
-
-  if ((rc = nwGtpv1uSetUlpEntity(RC.gtpv1u_data_g->gtpv1u_stack, &ulp)) != NW_GTPV1U_OK) {
-    LOG_E(GTPU, "nwGtpv1uSetUlpEntity: %x", rc);
-    return -1;
-  }
-
-  /* nw-gtpv1u stack requires an udp callback to send data over UDP.
-   * We provide a wrapper to UDP task.
-   */
-  udp.udpDataReqCallback = gtpv1u_eNB_send_udp_msg;
-  memset((void *)&(udp.hUdp), 0, sizeof(NwGtpv1uUdpHandleT));
-
-  if ((rc = nwGtpv1uSetUdpEntity(RC.gtpv1u_data_g->gtpv1u_stack, &udp)) != NW_GTPV1U_OK) {
-    LOG_E(GTPU, "nwGtpv1uSetUdpEntity: %x", rc);
-    return -1;
-  }
-
-  log.logReqCallback = gtpv1u_eNB_log_request;
-  memset((void *)&(log.logMgrHandle), 0, sizeof(NwGtpv1uLogMgrHandleT));
-
-  if ((rc = nwGtpv1uSetLogMgrEntity(RC.gtpv1u_data_g->gtpv1u_stack, &log)) != NW_GTPV1U_OK) {
-    LOG_E(GTPU, "nwGtpv1uSetLogMgrEntity: %x", rc);
-    return -1;
-  }
-
-  /* Timer interface is more complicated as both wrappers doesn't send a message
-   * to the timer task but call the timer API functions start/stop timer.
-   */
-  tmr.tmrMgrHandle     = 0;
-  tmr.tmrStartCallback = gtpv1u_start_timer_wrapper;
-  tmr.tmrStopCallback  = gtpv1u_stop_timer_wrapper;
-
-  if ((rc = nwGtpv1uSetTimerMgrEntity(RC.gtpv1u_data_g->gtpv1u_stack, &tmr)) != NW_GTPV1U_OK) {
-    LOG_E(GTPU, "nwGtpv1uSetTimerMgrEntity: %x", rc);
-    return -1;
-  }
-
-#if defined(GTP_DUMP_SOCKET) && GTP_DUMP_SOCKET > 0
-
-  if ((ret = gtpv1u_eNB_create_dump_socket()) < 0) {
-    return -1;
-  }
-
-#endif
-  LOG_D(GTPU, "Initializing GTPV1U interface for eNB: DONE\n");
-  return 0;
-}
-
-//-----------------------------------------------------------------------------
-void *gtpv1u_eNB_process_itti_msg(void *notUsed) {
-  /* Trying to fetch a message from the message queue.
-   * If the queue is empty, this function will block till a
-   * message is sent to the task.
-   */
-  instance_t  instance;
-  MessageDef *received_message_p = NULL;
-  int         rc = 0;
-  itti_receive_msg(TASK_GTPV1_U, &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);
-  //msg_name_p = ITTI_MSG_NAME(received_message_p);
-
-  switch (ITTI_MSG_ID(received_message_p)) {
-    case GTPV1U_ENB_S1_REQ:
-      gtpv1u_s1_req(instance, &received_message_p->ittiMsg.gtpv1uS1Req);
-
-    case GTPV1U_ENB_DELETE_TUNNEL_REQ: {
-      gtpv1u_delete_s1u_tunnel(instance, &received_message_p->ittiMsg.Gtpv1uDeleteTunnelReq);
-    }
-    break;
-
-    // DATA COMING FROM UDP
-    case UDP_DATA_IND: {
-      udp_data_ind_t *udp_data_ind_p;
-      udp_data_ind_p = &received_message_p->ittiMsg.udp_data_ind;
-      nwGtpv1uProcessUdpReq(RC.gtpv1u_data_g->gtpv1u_stack,
-                            udp_data_ind_p->buffer,
-                            udp_data_ind_p->buffer_length,
-                            udp_data_ind_p->peer_port,
-                            udp_data_ind_p->peer_address);
-      //itti_free(ITTI_MSG_ORIGIN_ID(received_message_p), udp_data_ind_p->buffer);
-    }
-    break;
-
-    // DATA TO BE SENT TO UDP
-    case GTPV1U_ENB_TUNNEL_DATA_REQ: {
-      gtpv1u_enb_tunnel_data_req_t *data_req_p           = NULL;
-      NwGtpv1uUlpApiT               stack_req;
-      NwGtpv1uRcT                   rc                   = NW_GTPV1U_FAILURE;
-      hashtable_rc_t                hash_rc              = HASH_TABLE_KEY_NOT_EXISTS;
-      gtpv1u_ue_data_t             *gtpv1u_ue_data_p     = NULL;
-      teid_t                        enb_s1u_teid         = 0;
-      teid_t                        sgw_s1u_teid         = 0;
-      VCD_SIGNAL_DUMPER_DUMP_FUNCTION_BY_NAME(VCD_SIGNAL_DUMPER_FUNCTIONS_GTPV1U_PROCESS_TUNNEL_DATA_REQ, VCD_FUNCTION_IN);
-      data_req_p = &GTPV1U_ENB_TUNNEL_DATA_REQ(received_message_p);
-      //ipv4_send_data(ipv4_data_p->sd, data_ind_p->buffer, data_ind_p->length);
-#if defined(GTP_DUMP_SOCKET) && GTP_DUMP_SOCKET > 0
-      gtpv1u_eNB_write_dump_socket(&data_req_p->buffer[data_req_p->offset],data_req_p->length);
-#endif
-      memset(&stack_req, 0, sizeof(NwGtpv1uUlpApiT));
-      hash_rc = hashtable_get(RC.gtpv1u_data_g->ue_mapping, (uint64_t)data_req_p->rnti, (void **)&gtpv1u_ue_data_p);
-
-      if (hash_rc == HASH_TABLE_KEY_NOT_EXISTS) {
-        LOG_E(GTPU, "nwGtpv1uProcessUlpReq failed: while getting ue rnti %x in hashtable ue_mapping\n", data_req_p->rnti);
-      } else {
-        if ((data_req_p->rab_id >= GTPV1U_BEARER_OFFSET) && (data_req_p->rab_id < max_val_LTE_DRB_Identity)) {
-          enb_s1u_teid                        = gtpv1u_ue_data_p->bearers[data_req_p->rab_id - GTPV1U_BEARER_OFFSET].teid_eNB;
-          sgw_s1u_teid                        = gtpv1u_ue_data_p->bearers[data_req_p->rab_id - GTPV1U_BEARER_OFFSET].teid_sgw;
-          stack_req.apiType                   = NW_GTPV1U_ULP_API_SEND_TPDU;
-          stack_req.apiInfo.sendtoInfo.teid   = sgw_s1u_teid;
-          stack_req.apiInfo.sendtoInfo.ipAddr = gtpv1u_ue_data_p->bearers[data_req_p->rab_id - GTPV1U_BEARER_OFFSET].sgw_ip_addr;
-          rc = nwGtpv1uGpduMsgNew(
-                 RC.gtpv1u_data_g->gtpv1u_stack,
-                 sgw_s1u_teid,
-                 NW_FALSE,
-                 RC.gtpv1u_data_g->seq_num++,
-                 data_req_p->buffer,
-                 data_req_p->length,
-                 data_req_p->offset,
-                 &(stack_req.apiInfo.sendtoInfo.hMsg));
-
-          if (rc != NW_GTPV1U_OK) {
-            LOG_E(GTPU, "nwGtpv1uGpduMsgNew failed: 0x%x\n", rc);
-            MSC_LOG_EVENT(MSC_GTPU_ENB,"0 Failed send G-PDU ltid %u rtid %u size %u",
-                          enb_s1u_teid,sgw_s1u_teid,data_req_p->length);
-            (void)enb_s1u_teid; /* avoid gcc warning "set but not used" */
-          } else {
-            rc = nwGtpv1uProcessUlpReq(RC.gtpv1u_data_g->gtpv1u_stack, &stack_req);
-
-            if (rc != NW_GTPV1U_OK) {
-              LOG_E(GTPU, "nwGtpv1uProcessUlpReq failed: 0x%x\n", rc);
-              MSC_LOG_EVENT(MSC_GTPU_ENB,"0 Failed send G-PDU ltid %u rtid %u size %u",
-                            enb_s1u_teid,sgw_s1u_teid,data_req_p->length);
-            } else {
-              MSC_LOG_TX_MESSAGE(
-                MSC_GTPU_ENB,
-                MSC_GTPU_SGW,
-                NULL,
-                0,
-                MSC_AS_TIME_FMT" G-PDU ltid %u rtid %u size %u",
-                0,0,
-                enb_s1u_teid,
-                sgw_s1u_teid,
-                data_req_p->length);
-            }
-
-            rc = nwGtpv1uMsgDelete(RC.gtpv1u_data_g->gtpv1u_stack,
-                                   stack_req.apiInfo.sendtoInfo.hMsg);
-
-            if (rc != NW_GTPV1U_OK) {
-              LOG_E(GTPU, "nwGtpv1uMsgDelete failed: 0x%x\n", rc);
-            }
-          }
-        }
-      }
-
-      VCD_SIGNAL_DUMPER_DUMP_FUNCTION_BY_NAME(VCD_SIGNAL_DUMPER_FUNCTIONS_GTPV1U_PROCESS_TUNNEL_DATA_REQ, VCD_FUNCTION_OUT);
-      /* Buffer still needed, do not free it */
-      //itti_free(ITTI_MSG_ORIGIN_ID(received_message_p), data_req_p->buffer);
-    }
-    break;
-
-    case GTPV1U_ENB_DATA_FORWARDING_REQ: {
-      gtpv1u_enb_data_forwarding_req_t *data_req_p           = NULL;
-      NwGtpv1uUlpApiT               stack_req;
-      NwGtpv1uRcT                   rc                   = NW_GTPV1U_FAILURE;
-      hashtable_rc_t                hash_rc              = HASH_TABLE_KEY_NOT_EXISTS;
-      gtpv1u_ue_data_t             *gtpv1u_ue_data_p     = NULL;
-      teid_t                        enb_s1u_teid         = 0;
-      teid_t                        tenb_x2u_teid         = 0;
-      VCD_SIGNAL_DUMPER_DUMP_FUNCTION_BY_NAME(VCD_SIGNAL_DUMPER_FUNCTIONS_GTPV1U_PROCESS_TUNNEL_DATA_REQ, VCD_FUNCTION_IN);
-      data_req_p = &GTPV1U_ENB_DATA_FORWARDING_REQ(received_message_p);
-      //ipv4_send_data(ipv4_data_p->sd, data_ind_p->buffer, data_ind_p->length);
-#if defined(GTP_DUMP_SOCKET) && GTP_DUMP_SOCKET > 0
-      gtpv1u_eNB_write_dump_socket(&data_req_p->buffer[data_req_p->offset],data_req_p->length);
-#endif
-      memset(&stack_req, 0, sizeof(NwGtpv1uUlpApiT));
-      hash_rc = hashtable_get(RC.gtpv1u_data_g->ue_mapping, (uint64_t)data_req_p->rnti, (void **)&gtpv1u_ue_data_p);
-
-      if (hash_rc == HASH_TABLE_KEY_NOT_EXISTS) {
-        LOG_E(GTPU, "nwGtpv1uProcessUlpReq failed: while getting ue rnti %x in hashtable ue_mapping\n", data_req_p->rnti);
-      } else {
-        if ((data_req_p->rab_id >= GTPV1U_BEARER_OFFSET) && (data_req_p->rab_id <= max_val_LTE_DRB_Identity)) {
-          enb_s1u_teid                        = gtpv1u_ue_data_p->bearers[data_req_p->rab_id - GTPV1U_BEARER_OFFSET].teid_eNB;
-          tenb_x2u_teid                       = gtpv1u_ue_data_p->bearers[data_req_p->rab_id - GTPV1U_BEARER_OFFSET].teid_teNB; // target enb teid
-          stack_req.apiType                   = NW_GTPV1U_ULP_API_SEND_TPDU;
-          stack_req.apiInfo.sendtoInfo.teid   = tenb_x2u_teid;
-          stack_req.apiInfo.sendtoInfo.ipAddr = gtpv1u_ue_data_p->bearers[data_req_p->rab_id - GTPV1U_BEARER_OFFSET].tenb_ip_addr;// target enb ip
-          rc = nwGtpv1uGpduMsgNew(
-                 RC.gtpv1u_data_g->gtpv1u_stack,
-                 tenb_x2u_teid,
-                 NW_FALSE,
-                 RC.gtpv1u_data_g->seq_num++,
-                 data_req_p->buffer,
-                 data_req_p->length,
-                 data_req_p->offset,
-                 &(stack_req.apiInfo.sendtoInfo.hMsg));
-
-          if (rc != NW_GTPV1U_OK) {
-            LOG_E(GTPU, "nwGtpv1uGpduMsgNew failed: 0x%x\n", rc);
-            MSC_LOG_EVENT(MSC_GTPU_ENB,"0 Failed send G-PDU ltid %u rtid %u size %u",
-                          enb_s1u_teid,tenb_x2u_teid,data_req_p->length);
-            (void)enb_s1u_teid; /* avoid gcc warning "set but not used" */
-          } else {
-            rc = nwGtpv1uProcessUlpReq(RC.gtpv1u_data_g->gtpv1u_stack, &stack_req);
-
-            if (rc != NW_GTPV1U_OK) {
-              LOG_E(GTPU, "nwGtpv1uProcessUlpReq failed: 0x%x\n", rc);
-              MSC_LOG_EVENT(MSC_GTPU_ENB,"0 Failed send G-PDU ltid %u rtid %u size %u",
-                            enb_s1u_teid,tenb_x2u_teid,data_req_p->length);
-            } else {
-              MSC_LOG_TX_MESSAGE(
-                MSC_GTPU_ENB,
-                MSC_GTPU_SGW,
-                NULL,
-                0,
-                MSC_AS_TIME_FMT" G-PDU ltid %u rtid %u size %u",
-                0,0,
-                enb_s1u_teid,
-                tenb_x2u_teid,
-                data_req_p->length);
-            }
-
-            rc = nwGtpv1uMsgDelete(RC.gtpv1u_data_g->gtpv1u_stack,
-                                   stack_req.apiInfo.sendtoInfo.hMsg);
-
-            if (rc != NW_GTPV1U_OK) {
-              LOG_E(GTPU, "nwGtpv1uMsgDelete failed: 0x%x\n", rc);
-            }
-          }
-        }
-      }
-
-      VCD_SIGNAL_DUMPER_DUMP_FUNCTION_BY_NAME(VCD_SIGNAL_DUMPER_FUNCTIONS_GTPV1U_PROCESS_TUNNEL_DATA_REQ, VCD_FUNCTION_OUT);
-      /* Buffer still needed, do not free it */
-      //itti_free(ITTI_MSG_ORIGIN_ID(received_message_p), data_req_p->buffer)
-    }
-    break;
-
-    case GTPV1U_ENB_END_MARKER_REQ: {
-      gtpv1u_enb_end_marker_req_t   *data_req_p           = NULL;
-      NwGtpv1uUlpApiT               stack_req;
-      NwGtpv1uRcT                   rc                    = NW_GTPV1U_FAILURE;
-      hashtable_rc_t                hash_rc               = HASH_TABLE_KEY_NOT_EXISTS;
-      gtpv1u_ue_data_t              *gtpv1u_ue_data_p     = NULL;
-      teid_t                        enb_s1u_teid          = 0;
-      teid_t                        tenb_x2u_teid         = 0;
-      NwGtpv1uMsgT      *pMsg                 = NULL;
-      VCD_SIGNAL_DUMPER_DUMP_FUNCTION_BY_NAME(VCD_SIGNAL_DUMPER_FUNCTIONS_GTPV1U_PROCESS_TUNNEL_DATA_REQ, VCD_FUNCTION_IN);
-      data_req_p = &GTPV1U_ENB_END_MARKER_REQ(received_message_p);
-      //ipv4_send_data(ipv4_data_p->sd, data_ind_p->buffer, data_ind_p->length);
-#if defined(GTP_DUMP_SOCKET) && GTP_DUMP_SOCKET > 0
-      gtpv1u_eNB_write_dump_socket(&data_req_p->buffer[data_req_p->offset],data_req_p->length);
-#endif
-      memset(&stack_req, 0, sizeof(NwGtpv1uUlpApiT));
-      hash_rc = hashtable_get(RC.gtpv1u_data_g->ue_mapping, (uint64_t)data_req_p->rnti, (void **)&gtpv1u_ue_data_p);
-
-      if (hash_rc == HASH_TABLE_KEY_NOT_EXISTS) {
-        LOG_E(GTPU, "nwGtpv1uProcessUlpReq failed: while getting ue rnti %x in hashtable ue_mapping\n", data_req_p->rnti);
-      } else {
-        if ((data_req_p->rab_id >= GTPV1U_BEARER_OFFSET) && (data_req_p->rab_id <= max_val_LTE_DRB_Identity)) {
-          enb_s1u_teid                        = gtpv1u_ue_data_p->bearers[data_req_p->rab_id - GTPV1U_BEARER_OFFSET].teid_eNB;
-          tenb_x2u_teid                       = gtpv1u_ue_data_p->bearers[data_req_p->rab_id - GTPV1U_BEARER_OFFSET].teid_teNB; // target enb teid
-          stack_req.apiType                   = NW_GTPV1U_ULP_API_SEND_TPDU;
-          stack_req.apiInfo.sendtoInfo.teid   = tenb_x2u_teid;
-          stack_req.apiInfo.sendtoInfo.ipAddr = gtpv1u_ue_data_p->bearers[data_req_p->rab_id - GTPV1U_BEARER_OFFSET].tenb_ip_addr;// target enb ip
-          rc = nwGtpv1uGpduMsgNew(
-				  RC.gtpv1u_data_g->gtpv1u_stack,
-				  tenb_x2u_teid,
-				  NW_FALSE,
-				  RC.gtpv1u_data_g->seq_num++,
-				  data_req_p->buffer,
-				  data_req_p->length,
-				  data_req_p->offset,
-				  &(stack_req.apiInfo.sendtoInfo.hMsg));
-	  
-          if (rc != NW_GTPV1U_OK) {
-            LOG_E(GTPU, "nwGtpv1uGpduMsgNew failed: 0x%x\n", rc);
-            MSC_LOG_EVENT(MSC_GTPU_ENB,"0 Failed send G-PDU ltid %u rtid %u size %u",
-                          enb_s1u_teid,tenb_x2u_teid,data_req_p->length);
-            (void)enb_s1u_teid; /* avoid gcc warning "set but not used" */
-          } else {
-            pMsg = (NwGtpv1uMsgT *) stack_req.apiInfo.sendtoInfo.hMsg;
-            pMsg->msgType = NW_GTP_END_MARKER;
-            rc = nwGtpv1uProcessUlpReq(RC.gtpv1u_data_g->gtpv1u_stack, &stack_req);
-	    
-            if (rc != NW_GTPV1U_OK) {
-              LOG_E(GTPU, "nwGtpv1uProcessUlpReq failed: 0x%x\n", rc);
-              MSC_LOG_EVENT(MSC_GTPU_ENB,"0 Failed send G-PDU ltid %u rtid %u size %u",
-                            enb_s1u_teid,tenb_x2u_teid,data_req_p->length);
-            } else {
-              MSC_LOG_TX_MESSAGE(
-                MSC_GTPU_ENB,
-                MSC_GTPU_SGW,
-                NULL,
-                0,
-                MSC_AS_TIME_FMT" G-PDU ltid %u rtid %u size %u",
-                0,0,
-                enb_s1u_teid,
-                tenb_x2u_teid,
-                data_req_p->length);
-            }
-
-            rc = nwGtpv1uMsgDelete(RC.gtpv1u_data_g->gtpv1u_stack,
-                                   stack_req.apiInfo.sendtoInfo.hMsg);
-	    
-            if (rc != NW_GTPV1U_OK) {
-              LOG_E(GTPU, "nwGtpv1uMsgDelete failed: 0x%x\n", rc);
-            }
-	    
-            gtpv1u_enb_delete_tunnel_req_t delete_tunnel_req;
-            memset(&delete_tunnel_req, 0, sizeof(delete_tunnel_req));
-            delete_tunnel_req.rnti = data_req_p->rnti;
-            gtpv1u_delete_x2u_tunnel(instance, &delete_tunnel_req, GTPV1U_SOURCE_ENB);
-          }
-        }
-      }
-      
-      VCD_SIGNAL_DUMPER_DUMP_FUNCTION_BY_NAME(VCD_SIGNAL_DUMPER_FUNCTIONS_GTPV1U_PROCESS_TUNNEL_DATA_REQ, VCD_FUNCTION_OUT);
-    }
-    break;
-
-    case TERMINATE_MESSAGE: {
-      if (RC.gtpv1u_data_g->ue_mapping != NULL) {
-        hashtable_destroy (&(RC.gtpv1u_data_g->ue_mapping));
-      }
-
-      if (RC.gtpv1u_data_g->teid_mapping != NULL) {
-        hashtable_destroy (&(RC.gtpv1u_data_g->teid_mapping));
-      }
-
-      LOG_W(GTPU, " *** Exiting GTPU thread\n");
-      itti_exit_task();
-    }
-    break;
-
-    case TIMER_HAS_EXPIRED:
-      nwGtpv1uProcessTimeout(&received_message_p->ittiMsg.timer_has_expired.arg);
-      break;
-
-    default: {
-      LOG_E(GTPU, "Unkwnon message ID %d:%s\n",
-            ITTI_MSG_ID(received_message_p),
-            ITTI_MSG_NAME(received_message_p));
-    }
-    break;
-  }
-
-  rc = itti_free(ITTI_MSG_ORIGIN_ID(received_message_p), received_message_p);
-  AssertFatal(rc == EXIT_SUCCESS, "Failed to free memory (%d)!\n", rc);
-  received_message_p = NULL;
-  VCD_SIGNAL_DUMPER_DUMP_FUNCTION_BY_NAME(VCD_SIGNAL_DUMPER_FUNCTIONS_GTPV1U_ENB_TASK, VCD_FUNCTION_OUT);
-  return NULL;
-}
-
-//-----------------------------------------------------------------------------
-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);
-  MSC_START_USE();
-
-  while(1) {
-    (void) gtpv1u_eNB_process_itti_msg (NULL);
-  }
-
-  return NULL;
-}
-
diff --git a/openair3/GTPV1-U/gtpv1u_eNB_task.h b/openair3/GTPV1-U/gtpv1u_eNB_task.h
deleted file mode 100644
index a6e26259415..00000000000
--- a/openair3/GTPV1-U/gtpv1u_eNB_task.h
+++ /dev/null
@@ -1,69 +0,0 @@
-/*
- * Licensed to the OpenAirInterface (OAI) Software Alliance under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The OpenAirInterface Software Alliance licenses this file to You under
- * the OAI Public License, Version 1.1  (the "License"); you may not use this file
- * except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.openairinterface.org/?page_id=698
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- *-------------------------------------------------------------------------------
- * For more information about the OpenAirInterface (OAI) Software Alliance:
- *      contact@openairinterface.org
- */
-
-/*! \file gtpv1u_eNB_task.h
-* \brief
-* \author Lionel Gauthier
-* \company Eurecom
-* \email: lionel.gauthier@eurecom.fr
-*/
-
-#ifndef GTPV1U_ENB_TASK_H_
-#define GTPV1U_ENB_TASK_H_
-
-
-/*
-int
-gtpv1u_new_data_req(
-  uint8_t enb_id,
-  uint8_t ue_id,
-  uint8_t rab_id,
-  uint8_t *buffer,
-  uint32_t buf_len,
-  uint32_t buf_offset);*/
-
-int   gtpv1u_eNB_init(void);
-void *gtpv1u_eNB_process_itti_msg(void*);
-void *gtpv1u_eNB_task(void *args);
-
-int
-gtpv1u_create_x2u_tunnel(
-  const instance_t instanceP,
-  const gtpv1u_enb_create_x2u_tunnel_req_t *  const create_tunnel_req_pP,
-        gtpv1u_enb_create_x2u_tunnel_resp_t * const create_tunnel_resp_pP);
-
-int
-gtpv1u_create_s1u_tunnel(
-  const instance_t instanceP,
-  const gtpv1u_enb_create_tunnel_req_t *  const create_tunnel_req_pP,
-        gtpv1u_enb_create_tunnel_resp_t * const create_tunnel_resp_pP);
-
-int
-gtpv1u_update_s1u_tunnel(
-    const instance_t                              instanceP,
-    const gtpv1u_enb_create_tunnel_req_t * const  create_tunnel_req_pP,
-    const rnti_t                                  prior_rnti);
-
-int gtpv1u_delete_x2u_tunnel(
-  const instance_t                             instanceP,
-  const gtpv1u_enb_delete_tunnel_req_t * const req_pP,
-  int                             enbflag);
-#endif /* GTPV1U_ENB_TASK_H_ */
diff --git a/openair3/GTPV1-U/gtpv1u_gNB.c b/openair3/GTPV1-U/gtpv1u_gNB.c
deleted file mode 100644
index ff7c8c06042..00000000000
--- a/openair3/GTPV1-U/gtpv1u_gNB.c
+++ /dev/null
@@ -1,1012 +0,0 @@
-/* Licensed to the OpenAirInterface (OAI) Software Alliance under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The OpenAirInterface Software Alliance licenses this file to You under
- * the OAI Public License, Version 1.1  (the "License"); you may not use this file
- * except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.openairinterface.org/?page_id=698
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- *-------------------------------------------------------------------------------
- * For more information about the OpenAirInterface (OAI) Software Alliance:
- *      contact@openairinterface.org
- */
-
-/*! \file gtpv1u_gNB.c
- * \brief
- * \author Sebastien ROUX, Lionel GAUTHIER, Navid Nikaein, Panos MATZAKOS
- * \version 1.0
- * \company Eurecom
- * \email: lionel.gauthier@eurecom.fr
- */
-#include <stdio.h>
-#include <errno.h>
-
-#include "mme_config.h"
-#include "intertask_interface.h"
-#include "msc.h"
-
-#include "gtpv1u.h"
-#include "NwGtpv1u.h"
-#include "NwGtpv1uMsg.h"
-#include "NwGtpv1uPrivate.h"
-#include "NwLog.h"
-#include "gtpv1u_eNB_defs.h"
-#include "gtpv1u_gNB_defs.h"
-#include "gtpv1_u_messages_types.h"
-#include "udp_eNB_task.h"
-#include "common/utils/LOG/log.h"
-#include "COMMON/platform_types.h"
-#include "COMMON/platform_constants.h"
-#include "common/utils/LOG/vcd_signal_dumper.h"
-#include "common/ran_context.h"
-#include "gtpv1u_eNB_task.h"
-#include "gtpv1u_gNB_task.h"
-#include "rrc_eNB_GTPV1U.h"
-
-#undef GTP_DUMP_SOCKET
-
-#undef GTPV1U_BEARER_OFFSET
-#define GTPV1U_BEARER_OFFSET 1
-
-extern unsigned char NB_eNB_INST;
-
-extern RAN_CONTEXT_t RC;
-
-extern NwGtpv1uRcT gtpv1u_eNB_send_udp_msg(
-		  NwGtpv1uUdpHandleT udpHandle,
-		  uint8_t *buffer,
-		  uint32_t buffer_len,
-		  uint32_t buffer_offset,
-		  uint32_t peerIpAddr,
-		  uint16_t peerPort);
-
-extern NwGtpv1uRcT gtpv1u_eNB_log_request(NwGtpv1uLogMgrHandleT hLogMgr,
-        uint32_t logLevel,
-        NwCharT *file,
-        uint32_t line,
-        NwCharT *logStr);
-
-static NwGtpv1uRcT gtpv1u_start_timer_wrapper(
-  NwGtpv1uTimerMgrHandleT tmrMgrHandle,
-  uint32_t                  timeoutSec,
-  uint32_t                  timeoutUsec,
-  uint32_t                  tmrType,
-  void                   *timeoutArg,
-  NwGtpv1uTimerHandleT   *hTmr) {
-  NwGtpv1uRcT rc = NW_GTPV1U_OK;
-  long        timer_id;
-
-  if (tmrType == NW_GTPV1U_TMR_TYPE_ONE_SHOT) {
-    timer_setup(timeoutSec,
-                timeoutUsec,
-                TASK_GTPV1_U,
-                INSTANCE_DEFAULT,
-                TIMER_ONE_SHOT,
-                timeoutArg,
-                &timer_id);
-  } else {
-    timer_setup(timeoutSec,
-                timeoutUsec,
-                TASK_GTPV1_U,
-                INSTANCE_DEFAULT,
-                TIMER_PERIODIC,
-                timeoutArg,
-                &timer_id);
-  }
-
-  return rc;
-}
-
-
-static NwGtpv1uRcT
-gtpv1u_stop_timer_wrapper(
-  NwGtpv1uTimerMgrHandleT tmrMgrHandle,
-  NwGtpv1uTimerHandleT hTmr) {
-  NwGtpv1uRcT rc = NW_GTPV1U_OK;
-  return rc;
-}
-
-/* Callback called when a gtpv1u message arrived on UDP interface */
-NwGtpv1uRcT gtpv1u_gNB_process_stack_req(
-  NwGtpv1uUlpHandleT hUlp,
-  NwGtpv1uUlpApiT   *pUlpApi) {
-  boolean_t           result             = FALSE;
-  teid_t              teid               = 0;
-  hashtable_rc_t      hash_rc            = HASH_TABLE_KEY_NOT_EXISTS;
-  gtpv1u_teid_data_t *gtpv1u_teid_data_p = NULL;
-  protocol_ctxt_t     ctxt;
-  NwGtpv1uRcT         rc;
-
-  switch(pUlpApi->apiType) {
-    /* Here there are two type of messages handled:
-     * - T-PDU
-     * - END-MARKER
-     */
-    case NW_GTPV1U_ULP_API_RECV_TPDU: {
-      uint8_t              buffer[4096];
-      uint32_t             buffer_len;
-      //uint16_t             msgType = NW_GTP_GPDU;
-      //NwGtpv1uMsgT     *pMsg = NULL;
-      /* Nw-gptv1u stack has processed a PDU. we can schedule it to PDCP
-       * for transmission.
-       */
-      teid = pUlpApi->apiInfo.recvMsgInfo.teid;
-      //pMsg = (NwGtpv1uMsgT *) pUlpApi->apiInfo.recvMsgInfo.hMsg;
-      //msgType = pMsg->msgType;
-
-      if (NW_GTPV1U_OK != nwGtpv1uMsgGetTpdu(pUlpApi->apiInfo.recvMsgInfo.hMsg,
-                                             buffer, &buffer_len)) {
-        LOG_E(GTPU, "Error while retrieving T-PDU");
-      }
-
-      itti_free(TASK_UDP, ((NwGtpv1uMsgT *)pUlpApi->apiInfo.recvMsgInfo.hMsg)->msgBuf);
-#if defined(GTP_DUMP_SOCKET) && GTP_DUMP_SOCKET > 0
-      gtpv1u_eNB_write_dump_socket(buffer,buffer_len);
-#endif
-      rc = nwGtpv1uMsgDelete(RC.gtpv1u_data_g->gtpv1u_stack,
-                             pUlpApi->apiInfo.recvMsgInfo.hMsg);
-
-      if (rc != NW_GTPV1U_OK) {
-        LOG_E(GTPU, "nwGtpv1uMsgDelete failed: 0x%x\n", rc);
-      }
-
-      hash_rc = hashtable_get(RC.gtpv1u_data_g->teid_mapping, teid, (void **)&gtpv1u_teid_data_p);
-
-      if (hash_rc == HASH_TABLE_OK) {
-#if defined(LOG_GTPU) && LOG_GTPU > 0
-        LOG_D(GTPU, "Received T-PDU from gtpv1u stack teid  %u size %d -> enb module id %u ue module id %u rab id %u\n",
-              teid,
-              buffer_len,
-              gtpv1u_teid_data_p->enb_id,
-              gtpv1u_teid_data_p->ue_id,
-              gtpv1u_teid_data_p->eps_bearer_id);
-#endif
-        //warning "LG eps bearer mapping to DRB id to do (offset -4)"
-        PROTOCOL_CTXT_SET_BY_MODULE_ID(&ctxt, gtpv1u_teid_data_p->enb_id, ENB_FLAG_YES,  gtpv1u_teid_data_p->ue_id, 0, 0,gtpv1u_teid_data_p->enb_id);
-        MSC_LOG_TX_MESSAGE(
-          MSC_GTPU_ENB,
-          MSC_PDCP_ENB,
-          NULL,0,
-          MSC_AS_TIME_FMT" DATA-REQ rb %u size %u",
-          0,0,
-          (gtpv1u_teid_data_p->eps_bearer_id) ? gtpv1u_teid_data_p->eps_bearer_id - 4: 5-4,
-          buffer_len);
-
-        result = pdcp_data_req(
-                   &ctxt,
-                   SRB_FLAG_NO,
-                   (gtpv1u_teid_data_p->eps_bearer_id) ? gtpv1u_teid_data_p->eps_bearer_id - 4: 5-4,
-                   0, // mui
-                   SDU_CONFIRM_NO, // confirm
-                   buffer_len,
-                   buffer,
-                   PDCP_TRANSMISSION_MODE_DATA,NULL, NULL
-                 );
-
-        if ( result == FALSE ) {
-            LOG_W(GTPU, "PDCP data request failed\n");
-
-          return NW_GTPV1U_FAILURE;
-        }
-      } else {
-        LOG_W(GTPU, "Received T-PDU from gtpv1u stack teid %u unknown size %u", teid, buffer_len);
-      }
-    }
-    break;
-
-    default: {
-      LOG_E(GTPU, "Received undefined UlpApi (%02x) from gtpv1u stack!\n",
-            pUlpApi->apiType);
-    }
-  } // end of switch
-
-  return NW_GTPV1U_OK;
-}
-
-int gtpv1u_gNB_init(void) {
-  NwGtpv1uRcT             rc = NW_GTPV1U_FAILURE;
-  NwGtpv1uUlpEntityT      ulp;
-  NwGtpv1uUdpEntityT      udp;
-  NwGtpv1uLogMgrEntityT   log;
-  NwGtpv1uTimerMgrEntityT tmr;
-  //  enb_properties_p = enb_config_get()->properties[0];
-  RC.gtpv1u_data_g = (gtpv1u_data_t *)calloc(sizeof(gtpv1u_data_t),1);
-  LOG_I(GTPU, "Initializing GTPU stack %p\n",&RC.gtpv1u_data_g);
-  //gtpv1u_data_g.gtpv1u_stack;
-  /* Initialize UE hashtable */
-  RC.gtpv1u_data_g->ue_mapping      = hashtable_create (32, NULL, NULL);
-  AssertFatal(RC.gtpv1u_data_g->ue_mapping != NULL, " ERROR Initializing TASK_GTPV1_U task interface: in hashtable_create returned %p\n", RC.gtpv1u_data_g->ue_mapping);
-  RC.gtpv1u_data_g->teid_mapping    = hashtable_create (256, NULL, NULL);
-  AssertFatal(RC.gtpv1u_data_g->teid_mapping != NULL, " ERROR Initializing TASK_GTPV1_U task interface: in hashtable_create\n");
-  //  RC.gtpv1u_data_g.enb_ip_address_for_S1u_S12_S4_up         = enb_properties_p->enb_ipv4_address_for_S1U;
-  //gtpv1u_data_g.udp_data;
-  RC.gtpv1u_data_g->seq_num         = 0;
-  RC.gtpv1u_data_g->restart_counter = 0;
-
-  /* Initializing GTPv1-U stack */
-  if ((rc = nwGtpv1uInitialize(&RC.gtpv1u_data_g->gtpv1u_stack, GTPU_STACK_ENB)) != NW_GTPV1U_OK) {
-    LOG_E(GTPU, "Failed to setup nwGtpv1u stack %x\n", rc);
-    return -1;
-  }
-
-  if ((rc = nwGtpv1uSetLogLevel(RC.gtpv1u_data_g->gtpv1u_stack,
-                                NW_LOG_LEVEL_DEBG)) != NW_GTPV1U_OK) {
-    LOG_E(GTPU, "Failed to setup loglevel for stack %x\n", rc);
-    return -1;
-  }
-
-  /* Set the ULP API callback. Called once message have been processed by the
-   * nw-gtpv1u stack.
-   */
-  ulp.ulpReqCallback = gtpv1u_gNB_process_stack_req;
-  memset((void *)&(ulp.hUlp), 0, sizeof(NwGtpv1uUlpHandleT));
-
-  if ((rc = nwGtpv1uSetUlpEntity(RC.gtpv1u_data_g->gtpv1u_stack, &ulp)) != NW_GTPV1U_OK) {
-    LOG_E(GTPU, "nwGtpv1uSetUlpEntity: %x", rc);
-    return -1;
-  }
-
-  /* nw-gtpv1u stack requires an udp callback to send data over UDP.
-   * We provide a wrapper to UDP task.
-   */
-  udp.udpDataReqCallback = gtpv1u_eNB_send_udp_msg;
-  memset((void *)&(udp.hUdp), 0, sizeof(NwGtpv1uUdpHandleT));
-
-  if ((rc = nwGtpv1uSetUdpEntity(RC.gtpv1u_data_g->gtpv1u_stack, &udp)) != NW_GTPV1U_OK) {
-    LOG_E(GTPU, "nwGtpv1uSetUdpEntity: %x", rc);
-    return -1;
-  }
-
-  log.logReqCallback = gtpv1u_eNB_log_request;
-  memset((void *)&(log.logMgrHandle), 0, sizeof(NwGtpv1uLogMgrHandleT));
-
-  if ((rc = nwGtpv1uSetLogMgrEntity(RC.gtpv1u_data_g->gtpv1u_stack, &log)) != NW_GTPV1U_OK) {
-    LOG_E(GTPU, "nwGtpv1uSetLogMgrEntity: %x", rc);
-    return -1;
-  }
-
-  /* Timer interface is more complicated as both wrappers doesn't send a message
-   * to the timer task but call the timer API functions start/stop timer.
-   */
-  tmr.tmrMgrHandle     = 0;
-  tmr.tmrStartCallback = gtpv1u_start_timer_wrapper;
-  tmr.tmrStopCallback  = gtpv1u_stop_timer_wrapper;
-
-  if ((rc = nwGtpv1uSetTimerMgrEntity(RC.gtpv1u_data_g->gtpv1u_stack, &tmr)) != NW_GTPV1U_OK) {
-    LOG_E(GTPU, "nwGtpv1uSetTimerMgrEntity: %x", rc);
-    return -1;
-  }
-
-#if defined(GTP_DUMP_SOCKET) && GTP_DUMP_SOCKET > 0
-
-  if ((ret = gtpv1u_eNB_create_dump_socket()) < 0) {
-    return -1;
-  }
-
-#endif
-  LOG_D(GTPU, "Initializing GTPV1U interface for eNB: DONE\n");
-  return 0;
-}
-
-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);
-  MSC_START_USE();
-
-  while(1) {
-    (void) gtpv1u_eNB_process_itti_msg (NULL);
-  }
-
-  return NULL;
-}
-
-/* Callback called when a gtpv1u message arrived on UDP interface */
-NwGtpv1uRcT nr_gtpv1u_gNB_process_stack_req(
-  NwGtpv1uUlpHandleT hUlp,
-  NwGtpv1uUlpApiT   *pUlpApi) {
-  boolean_t              result             = FALSE;
-  teid_t                 teid               = 0;
-  hashtable_rc_t         hash_rc            = HASH_TABLE_KEY_NOT_EXISTS;
-  nr_gtpv1u_teid_data_t *gtpv1u_teid_data_p = NULL;
-  protocol_ctxt_t        ctxt;
-  NwGtpv1uRcT            rc;
-
-  switch(pUlpApi->apiType) {
-    /* Here there are two type of messages handled:
-     * - T-PDU
-     * - END-MARKER
-     */
-    case NW_GTPV1U_ULP_API_RECV_TPDU: {
-      uint8_t              buffer[4096];
-      uint32_t             buffer_len;
-      //uint16_t             msgType = NW_GTP_GPDU;
-      //NwGtpv1uMsgT     *pMsg = NULL;
-      /* Nw-gptv1u stack has processed a PDU. we can schedule it to PDCP
-       * for transmission.
-       */
-      teid = pUlpApi->apiInfo.recvMsgInfo.teid;
-      //pMsg = (NwGtpv1uMsgT *) pUlpApi->apiInfo.recvMsgInfo.hMsg;
-      //msgType = pMsg->msgType;
-
-      if (NW_GTPV1U_OK != nwGtpv1uMsgGetTpdu(pUlpApi->apiInfo.recvMsgInfo.hMsg,
-                                             buffer, &buffer_len)) {
-        LOG_E(GTPU, "Error while retrieving T-PDU");
-      }
-
-      itti_free(TASK_UDP, ((NwGtpv1uMsgT *)pUlpApi->apiInfo.recvMsgInfo.hMsg)->msgBuf);
-#if defined(GTP_DUMP_SOCKET) && GTP_DUMP_SOCKET > 0
-      gtpv1u_eNB_write_dump_socket(buffer,buffer_len);
-#endif
-      rc = nwGtpv1uMsgDelete(RC.nr_gtpv1u_data_g->gtpv1u_stack,
-                             pUlpApi->apiInfo.recvMsgInfo.hMsg);
-
-      if (rc != NW_GTPV1U_OK) {
-        LOG_E(GTPU, "nwGtpv1uMsgDelete failed: 0x%x\n", rc);
-      }
-
-      hash_rc = hashtable_get(RC.nr_gtpv1u_data_g->teid_mapping, teid, (void **)&gtpv1u_teid_data_p);
-
-      if (hash_rc == HASH_TABLE_OK) {
-// #if defined(LOG_GTPU) && LOG_GTPU > 0
-        LOG_D(GTPU, "Received T-PDU from gtpv1u stack teid  %u size %d -> gnb module id %u ue module id %u pdu session id %u\n",
-              teid,
-              buffer_len,
-              gtpv1u_teid_data_p->gnb_id,
-              gtpv1u_teid_data_p->ue_id,
-              gtpv1u_teid_data_p->pdu_session_id);
-// #endif
-        //warning "LG eps bearer mapping to DRB id to do (offset -4)"
-        PROTOCOL_CTXT_SET_BY_MODULE_ID(&ctxt, gtpv1u_teid_data_p->gnb_id, GNB_FLAG_YES,  gtpv1u_teid_data_p->ue_id, 0, 0,gtpv1u_teid_data_p->gnb_id);
-        // MSC_LOG_TX_MESSAGE(
-        //   MSC_GTPU_ENB,
-        //   MSC_PDCP_ENB,
-        //   NULL,0,
-        //   MSC_AS_TIME_FMT" DATA-REQ rb %u size %u",
-        //   0,0,
-        //   (gtpv1u_teid_data_p->eps_bearer_id) ? gtpv1u_teid_data_p->eps_bearer_id - 4: 5-4,
-        //   buffer_len);
-
-        result = pdcp_data_req(
-                   &ctxt,
-                   SRB_FLAG_NO,
-                   1,
-                   0, // mui
-                   SDU_CONFIRM_NO, // confirm
-                   buffer_len,
-                   buffer,
-                   PDCP_TRANSMISSION_MODE_DATA,NULL, NULL
-                 );
-
-        if ( result == FALSE ) {
-            LOG_W(GTPU, "PDCP data request failed\n");
-
-          return NW_GTPV1U_FAILURE;
-        }
-      } else {
-        LOG_W(GTPU, "Received T-PDU from gtpv1u stack teid %u unknown size %u", teid, buffer_len);
-      }
-    }
-    break;
-
-    default: {
-      LOG_E(GTPU, "Received undefined UlpApi (%02x) from gtpv1u stack!\n",
-            pUlpApi->apiType);
-    }
-  } // end of switch
-
-  return NW_GTPV1U_OK;
-}
-
-int nr_gtpv1u_gNB_init(void) {
-  NwGtpv1uRcT             rc = NW_GTPV1U_FAILURE;
-  NwGtpv1uUlpEntityT      ulp;
-  NwGtpv1uUdpEntityT      udp;
-  NwGtpv1uLogMgrEntityT   log;
-  NwGtpv1uTimerMgrEntityT tmr;
-  //  enb_properties_p = enb_config_get()->properties[0];
-  RC.nr_gtpv1u_data_g = (nr_gtpv1u_data_t *)calloc(sizeof(nr_gtpv1u_data_t),1);
-  LOG_I(GTPU, "Initializing GTPU stack %p\n",&RC.nr_gtpv1u_data_g);
-
-  /* Initialize UE hashtable */
-  RC.nr_gtpv1u_data_g->ue_mapping      = hashtable_create (32, NULL, NULL);
-  AssertFatal(RC.nr_gtpv1u_data_g->ue_mapping != NULL, " ERROR Initializing TASK_GTPV1_U task interface: in hashtable_create returned %p\n", RC.gtpv1u_data_g->ue_mapping);
-  RC.nr_gtpv1u_data_g->teid_mapping    = hashtable_create (256, NULL, NULL);
-  AssertFatal(RC.nr_gtpv1u_data_g->teid_mapping != NULL, " ERROR Initializing TASK_GTPV1_U task interface: in hashtable_create\n");
-  //  RC.gtpv1u_data_g.enb_ip_address_for_S1u_S12_S4_up         = enb_properties_p->enb_ipv4_address_for_S1U;
-  //gtpv1u_data_g.udp_data;
-  RC.nr_gtpv1u_data_g->seq_num         = 0;
-  RC.nr_gtpv1u_data_g->restart_counter = 0;
-
-  /* Initializing GTPv1-U stack */
-  if ((rc = nwGtpv1uInitialize(&RC.nr_gtpv1u_data_g->gtpv1u_stack, GTPU_STACK_ENB)) != NW_GTPV1U_OK) {
-    LOG_E(GTPU, "Failed to setup nwGtpv1u stack %x\n", rc);
-    return -1;
-  }
-
-  if ((rc = nwGtpv1uSetLogLevel(RC.nr_gtpv1u_data_g->gtpv1u_stack,
-                                NW_LOG_LEVEL_DEBG)) != NW_GTPV1U_OK) {
-    LOG_E(GTPU, "Failed to setup loglevel for stack %x\n", rc);
-    return -1;
-  }
-
-  /* Set the ULP API callback. Called once message have been processed by the
-   * nw-gtpv1u stack.
-   */
-  ulp.ulpReqCallback = nr_gtpv1u_gNB_process_stack_req;
-  memset((void *)&(ulp.hUlp), 0, sizeof(NwGtpv1uUlpHandleT));
-
-  if ((rc = nwGtpv1uSetUlpEntity(RC.nr_gtpv1u_data_g->gtpv1u_stack, &ulp)) != NW_GTPV1U_OK) {
-    LOG_E(GTPU, "nwGtpv1uSetUlpEntity: %x", rc);
-    return -1;
-  }
-
-  /* nw-gtpv1u stack requires an udp callback to send data over UDP.
-   * We provide a wrapper to UDP task.
-   */
-  udp.udpDataReqCallback = gtpv1u_eNB_send_udp_msg;
-  memset((void *)&(udp.hUdp), 0, sizeof(NwGtpv1uUdpHandleT));
-
-  if ((rc = nwGtpv1uSetUdpEntity(RC.nr_gtpv1u_data_g->gtpv1u_stack, &udp)) != NW_GTPV1U_OK) {
-    LOG_E(GTPU, "nwGtpv1uSetUdpEntity: %x", rc);
-    return -1;
-  }
-
-  log.logReqCallback = gtpv1u_eNB_log_request;
-  memset((void *)&(log.logMgrHandle), 0, sizeof(NwGtpv1uLogMgrHandleT));
-
-  if ((rc = nwGtpv1uSetLogMgrEntity(RC.nr_gtpv1u_data_g->gtpv1u_stack, &log)) != NW_GTPV1U_OK) {
-    LOG_E(GTPU, "nwGtpv1uSetLogMgrEntity: %x", rc);
-    return -1;
-  }
-
-  /* Timer interface is more complicated as both wrappers doesn't send a message
-   * to the timer task but call the timer API functions start/stop timer.
-   */
-  tmr.tmrMgrHandle     = 0;
-  tmr.tmrStartCallback = gtpv1u_start_timer_wrapper;
-  tmr.tmrStopCallback  = gtpv1u_stop_timer_wrapper;
-
-  if ((rc = nwGtpv1uSetTimerMgrEntity(RC.nr_gtpv1u_data_g->gtpv1u_stack, &tmr)) != NW_GTPV1U_OK) {
-    LOG_E(GTPU, "nwGtpv1uSetTimerMgrEntity: %x", rc);
-    return -1;
-  }
-
-#if defined(GTP_DUMP_SOCKET) && GTP_DUMP_SOCKET > 0
-
-  if ((ret = gtpv1u_eNB_create_dump_socket()) < 0) {
-    return -1;
-  }
-
-#endif
-  LOG_D(GTPU, "Initializing GTPV1U interface for eNB: DONE\n");
-  return 0;
-}
-
-//-----------------------------------------------------------------------------
-int
-gtpv1u_create_ngu_tunnel(
-  const instance_t                              instanceP,
-  const gtpv1u_gnb_create_tunnel_req_t *const  create_tunnel_req_pP,
-  gtpv1u_gnb_create_tunnel_resp_t *const create_tunnel_resp_pP)
-{
-  /* Create a new nw-gtpv1-u stack req using API */
-  NwGtpv1uUlpApiT          stack_req;
-  NwGtpv1uRcT              rc                   = NW_GTPV1U_FAILURE;
-  /* Local tunnel end-point identifier */
-  teid_t                   ngu_teid             = 0;
-  nr_gtpv1u_teid_data_t   *gtpv1u_teid_data_p   = NULL;
-  nr_gtpv1u_ue_data_t     *gtpv1u_ue_data_p     = NULL;
-  //MessageDef              *message_p            = NULL;
-  hashtable_rc_t           hash_rc              = HASH_TABLE_KEY_NOT_EXISTS;
-  int                      i;
-  pdusessionid_t           pdusession_id        = 0;
-  //    int                      ipv4_addr            = 0;
-  int                      ip_offset            = 0;
-  in_addr_t                in_addr;
-  int                      addrs_length_in_bytes= 0;
-  int                      loop_counter         = 0;
-  int                      ret                  = 0;
-  MSC_LOG_RX_MESSAGE(
-    MSC_GTPU_GNB,
-    MSC_RRC_GNB,
-    NULL,0,
-    MSC_AS_TIME_FMT" CREATE_TUNNEL_REQ RNTI %"PRIx16" inst %u ntuns %u psid %u upf-ngu teid %u",
-    0,0,create_tunnel_req_pP->rnti, instanceP,
-    create_tunnel_req_pP->num_tunnels, create_tunnel_req_pP->pdusession_id[0],
-    create_tunnel_req_pP->outgoing_teid[0]);
-  create_tunnel_resp_pP->rnti        = create_tunnel_req_pP->rnti;
-  create_tunnel_resp_pP->status      = 0;
-  create_tunnel_resp_pP->num_tunnels = 0;
-
-  for (i = 0; i < create_tunnel_req_pP->num_tunnels; i++) {
-    ip_offset               = 0;
-    loop_counter            = 0;
-    pdusession_id = create_tunnel_req_pP->pdusession_id[i];
-    LOG_D(GTPU, "Rx GTPV1U_GNB_CREATE_TUNNEL_REQ ue rnti %x pdu session id %u\n",
-          create_tunnel_req_pP->rnti, pdusession_id);
-    memset(&stack_req, 0, sizeof(NwGtpv1uUlpApiT));
-    stack_req.apiType = NW_GTPV1U_ULP_API_CREATE_TUNNEL_ENDPOINT;
-
-    do {
-      ngu_teid = gtpv1u_new_teid();
-      LOG_D(GTPU, "gtpv1u_create_ngu_tunnel() 0x%x %u(dec)\n", ngu_teid, ngu_teid);
-      stack_req.apiInfo.createTunnelEndPointInfo.teid          = ngu_teid;
-      stack_req.apiInfo.createTunnelEndPointInfo.hUlpSession   = 0;
-      stack_req.apiInfo.createTunnelEndPointInfo.hStackSession = 0;
-      rc = nwGtpv1uProcessUlpReq(RC.nr_gtpv1u_data_g->gtpv1u_stack, &stack_req);
-      LOG_D(GTPU, ".\n");
-      loop_counter++;
-    } while (rc != NW_GTPV1U_OK && loop_counter < 10);
-
-    if ( rc != NW_GTPV1U_OK && loop_counter == 10 ) {
-      LOG_E(GTPU,"NwGtpv1uCreateTunnelEndPoint failed 10 times,start next loop\n");
-      ret = -1;
-      continue;
-    }
-
-    //-----------------------
-    // PDCP->GTPV1U mapping
-    //-----------------------
-    hash_rc = hashtable_get(RC.nr_gtpv1u_data_g->ue_mapping, create_tunnel_req_pP->rnti, (void **)&gtpv1u_ue_data_p);
-
-    if ((hash_rc == HASH_TABLE_KEY_NOT_EXISTS) || (hash_rc == HASH_TABLE_OK)) {
-      if (hash_rc == HASH_TABLE_KEY_NOT_EXISTS) {
-        gtpv1u_ue_data_p = calloc (1, sizeof(gtpv1u_ue_data_t));
-        hash_rc = hashtable_insert(RC.nr_gtpv1u_data_g->ue_mapping, create_tunnel_req_pP->rnti, gtpv1u_ue_data_p);
-        AssertFatal(hash_rc == HASH_TABLE_OK, "Error inserting ue_mapping in GTPV1U hashtable");
-      }
-
-      gtpv1u_ue_data_p->ue_id       = create_tunnel_req_pP->rnti;
-      gtpv1u_ue_data_p->instance_id = 0; // TO DO
-      memcpy(&create_tunnel_resp_pP->gnb_addr.buffer,
-             &RC.nr_gtpv1u_data_g->gnb_ip_address_for_NGu_up,
-             sizeof (in_addr_t));
-     
-      LOG_I(GTPU,"Configured GTPu address : %x\n",RC.nr_gtpv1u_data_g->gnb_ip_address_for_NGu_up);
-      create_tunnel_resp_pP->gnb_addr.length = sizeof (in_addr_t);
-      addrs_length_in_bytes = create_tunnel_req_pP->dst_addr[i].length / 8;
-      AssertFatal((addrs_length_in_bytes == 4) ||
-                  (addrs_length_in_bytes == 16) ||
-                  (addrs_length_in_bytes == 20),
-                  "Bad transport layer address length %d (bits) %d (bytes)",
-                  create_tunnel_req_pP->dst_addr[i].length, addrs_length_in_bytes);
-
-      if ((addrs_length_in_bytes == 4) ||
-          (addrs_length_in_bytes == 20)) {
-        in_addr = *((in_addr_t *)create_tunnel_req_pP->dst_addr[i].buffer);
-        ip_offset = 4;
-        gtpv1u_ue_data_p->bearers[pdusession_id - GTPV1U_BEARER_OFFSET].upf_ip_addr = in_addr;
-      }
-
-      if ((addrs_length_in_bytes == 16) ||
-          (addrs_length_in_bytes == 20)) {
-        memcpy(gtpv1u_ue_data_p->bearers[pdusession_id - GTPV1U_BEARER_OFFSET].upf_ip6_addr.s6_addr,
-               &create_tunnel_req_pP->dst_addr[i].buffer[ip_offset],
-               16);
-      }
-
-      gtpv1u_ue_data_p->bearers[pdusession_id - GTPV1U_BEARER_OFFSET].state                  = BEARER_IN_CONFIG;
-      gtpv1u_ue_data_p->bearers[pdusession_id - GTPV1U_BEARER_OFFSET].teid_gNB               = ngu_teid;
-      gtpv1u_ue_data_p->bearers[pdusession_id - GTPV1U_BEARER_OFFSET].teid_gNB_stack_session = stack_req.apiInfo.createTunnelEndPointInfo.hStackSession;
-      gtpv1u_ue_data_p->bearers[pdusession_id - GTPV1U_BEARER_OFFSET].teid_upf               = create_tunnel_req_pP->outgoing_teid[i];
-      gtpv1u_ue_data_p->num_bearers++;
-      create_tunnel_resp_pP->gnb_NGu_teid[i] = ngu_teid;
-
-      LOG_I(GTPU,"Copied to create_tunnel_resp tunnel: index %d target gNB ip %d.%d.%d.%d length %d gtp teid %u\n",
-        i,
-        create_tunnel_resp_pP->gnb_addr.buffer[0],
-        create_tunnel_resp_pP->gnb_addr.buffer[1],
-        create_tunnel_resp_pP->gnb_addr.buffer[2],
-        create_tunnel_resp_pP->gnb_addr.buffer[3],
-        create_tunnel_resp_pP->gnb_addr.length,
-        create_tunnel_resp_pP->gnb_NGu_teid[i]);
-    } else {
-      create_tunnel_resp_pP->gnb_NGu_teid[i] = 0;
-      create_tunnel_resp_pP->status         = 0xFF;
-    }
-
-    create_tunnel_resp_pP->pdusession_id[i] = pdusession_id;
-    create_tunnel_resp_pP->num_tunnels      += 1;
-    //-----------------------
-    // GTPV1U->PDCP mapping
-    //-----------------------
-    hash_rc = hashtable_get(RC.nr_gtpv1u_data_g->teid_mapping, ngu_teid, (void **)&gtpv1u_teid_data_p);
-
-    if (hash_rc == HASH_TABLE_KEY_NOT_EXISTS) {
-      gtpv1u_teid_data_p = calloc (1, sizeof(nr_gtpv1u_teid_data_t));
-      gtpv1u_teid_data_p->gnb_id        = 0; // TO DO
-      gtpv1u_teid_data_p->ue_id         = create_tunnel_req_pP->rnti;
-      gtpv1u_teid_data_p->pdu_session_id = pdusession_id;
-      hash_rc = hashtable_insert(RC.nr_gtpv1u_data_g->teid_mapping, ngu_teid, gtpv1u_teid_data_p);
-      AssertFatal(hash_rc == HASH_TABLE_OK, "Error inserting teid mapping in GTPV1U hashtable");
-    } else {
-      create_tunnel_resp_pP->gnb_NGu_teid[i] = 0;
-      create_tunnel_resp_pP->status         = 0xFF;
-    }
-  }
-
-  MSC_LOG_TX_MESSAGE(
-    MSC_GTPU_GNB,
-    MSC_RRC_GNB,
-    NULL,0,
-    "0 GTPV1U_GNB_CREATE_TUNNEL_RESP rnti %x teid %x",
-    create_tunnel_resp_pP->rnti,
-    ngu_teid);
-  LOG_D(GTPU, "Tx GTPV1U_GNB_CREATE_TUNNEL_RESP ue rnti %x status %d\n",
-        create_tunnel_req_pP->rnti,
-        create_tunnel_resp_pP->status);
-  //return 0;
-  return ret;
-}
-
-int gtpv1u_update_ngu_tunnel(
-  const instance_t                              instanceP,
-  const gtpv1u_gnb_create_tunnel_req_t *const  create_tunnel_req_pP,
-  const rnti_t                                  prior_rnti
-) {
-  /* Local tunnel end-point identifier */
-  teid_t                      ngu_teid             = 0;
-  nr_gtpv1u_teid_data_t      *gtpv1u_teid_data_p   = NULL;
-  nr_gtpv1u_ue_data_t        *gtpv1u_ue_data_p     = NULL;
-  nr_gtpv1u_ue_data_t        *gtpv1u_ue_data_new_p     = NULL;
-  //MessageDef              *message_p            = NULL;
-  hashtable_rc_t           hash_rc              = HASH_TABLE_KEY_NOT_EXISTS;
-  int                      i,j;
-  uint8_t                  bearers_num = 0,bearers_total = 0;
-  //-----------------------
-  // PDCP->GTPV1U mapping
-  //-----------------------
-  hash_rc = hashtable_get(RC.nr_gtpv1u_data_g->ue_mapping, prior_rnti, (void **)&gtpv1u_ue_data_p);
-
-  if(hash_rc != HASH_TABLE_OK) {
-    LOG_E(GTPU,"Error get ue_mapping(rnti=%x) from GTPV1U hashtable error\n", prior_rnti);
-    return -1;
-  }
-
-  gtpv1u_ue_data_new_p = calloc (1, sizeof(nr_gtpv1u_ue_data_t));
-  memcpy(gtpv1u_ue_data_new_p,gtpv1u_ue_data_p,sizeof(nr_gtpv1u_ue_data_t));
-  gtpv1u_ue_data_new_p->ue_id       = create_tunnel_req_pP->rnti;
-  hash_rc = hashtable_insert(RC.nr_gtpv1u_data_g->ue_mapping, create_tunnel_req_pP->rnti, gtpv1u_ue_data_new_p);
-
-  //AssertFatal(hash_rc == HASH_TABLE_OK, "Error inserting ue_mapping in GTPV1U hashtable");
-  if ( hash_rc != HASH_TABLE_OK ) {
-    LOG_E(GTPU,"Failed to insert ue_mapping(rnti=%x) in GTPV1U hashtable\n",create_tunnel_req_pP->rnti);
-    return -1;
-  } else {
-    LOG_I(GTPU, "inserting ue_mapping(rnti=%x) in GTPV1U hashtable\n",
-          create_tunnel_req_pP->rnti);
-  }
-
-  hash_rc = hashtable_remove(RC.nr_gtpv1u_data_g->ue_mapping, prior_rnti);
-  LOG_I(GTPU, "hashtable_remove ue_mapping(rnti=%x) in GTPV1U hashtable\n",
-        prior_rnti);
-  //-----------------------
-  // GTPV1U->PDCP mapping
-  //-----------------------
-  bearers_total =gtpv1u_ue_data_new_p->num_bearers;
-
-  for(j = 0; j<GTPV1U_MAX_BEARERS_ID; j++) {
-    if(gtpv1u_ue_data_new_p->bearers[j].state != BEARER_IN_CONFIG)
-      continue;
-
-    bearers_num++;
-
-    for (i = 0; i < create_tunnel_req_pP->num_tunnels; i++) {
-      if(j == (create_tunnel_req_pP->pdusession_id[i]-GTPV1U_BEARER_OFFSET))
-        break;
-    }
-
-    if(i < create_tunnel_req_pP->num_tunnels) {
-      ngu_teid = gtpv1u_ue_data_new_p->bearers[j].teid_gNB;
-      hash_rc = hashtable_get(RC.nr_gtpv1u_data_g->teid_mapping, ngu_teid, (void **)&gtpv1u_teid_data_p);
-
-      if (hash_rc == HASH_TABLE_OK) {
-        gtpv1u_teid_data_p->ue_id         = create_tunnel_req_pP->rnti;
-        gtpv1u_teid_data_p->pdu_session_id = create_tunnel_req_pP->pdusession_id[i];
-        LOG_I(GTPU, "updata teid_mapping te_id %u (prior_rnti %x rnti %x) in GTPV1U hashtable\n",
-                    ngu_teid,prior_rnti,create_tunnel_req_pP->rnti);
-      } else {
-        LOG_W(GTPU, "Error get teid mapping(s1u_teid=%u) from GTPV1U hashtable", ngu_teid);
-      }
-    } else {
-      ngu_teid = gtpv1u_ue_data_new_p->bearers[j].teid_gNB;
-      hash_rc = hashtable_remove(RC.nr_gtpv1u_data_g->teid_mapping, ngu_teid);
-
-      if (hash_rc != HASH_TABLE_OK) {
-        LOG_D(GTPU, "Removed user rnti %x , enb S1U teid %u not found\n", prior_rnti, ngu_teid);
-      }
-
-      gtpv1u_ue_data_new_p->bearers[j].state = BEARER_DOWN;
-      gtpv1u_ue_data_new_p->num_bearers--;
-      LOG_I(GTPU, "delete teid_mapping te_id %u (rnti%x) bearer_id %d in GTPV1U hashtable\n",
-            ngu_teid,prior_rnti,j+GTPV1U_BEARER_OFFSET);;
-    }
-
-    if(bearers_num > bearers_total)
-      break;
-  }
-
-  return 0;
-}
-
-//-----------------------------------------------------------------------------
-int gtpv1u_delete_ngu_tunnel(
-  const instance_t                             instanceP,
-  const gtpv1u_gnb_delete_tunnel_req_t *const req_pP) {
-  NwGtpv1uUlpApiT          stack_req;
-  NwGtpv1uRcT              rc                   = NW_GTPV1U_FAILURE;
-  MessageDef              *message_p = NULL;
-  nr_gtpv1u_ue_data_t     *gtpv1u_ue_data_p     = NULL;
-  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);
-  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 **)&gtpv1u_ue_data_p);
-
-  if (hash_rc == HASH_TABLE_OK) {
-    for (pdusession_index = 0; pdusession_index < req_pP->num_pdusession; pdusession_index++) {
-      teid_gNB = gtpv1u_ue_data_p->bearers[req_pP->pdusession_id[pdusession_index] - GTPV1U_BEARER_OFFSET].teid_gNB;
-      LOG_D(GTPU, "Rx GTPV1U_ENB_DELETE_TUNNEL user rnti %x eNB S1U teid %u eps bearer id %u\n",
-            req_pP->rnti, teid_gNB, req_pP->pdusession_id[pdusession_index]);
-      {
-        memset(&stack_req, 0, sizeof(NwGtpv1uUlpApiT));
-        stack_req.apiType = NW_GTPV1U_ULP_API_DESTROY_TUNNEL_ENDPOINT;
-        LOG_D(GTPU, "gtpv1u_delete_ngu_tunnel pdusession %u  %u\n",
-              req_pP->pdusession_id[pdusession_index],
-              teid_gNB);
-        stack_req.apiInfo.destroyTunnelEndPointInfo.hStackSessionHandle =
-            gtpv1u_ue_data_p->bearers[req_pP->pdusession_id[pdusession_index] - GTPV1U_BEARER_OFFSET].teid_gNB_stack_session;
-        rc = nwGtpv1uProcessUlpReq(RC.nr_gtpv1u_data_g->gtpv1u_stack, &stack_req);
-        LOG_D(GTPU, ".\n");
-      }
-
-      if (rc != NW_GTPV1U_OK) {
-        GTPV1U_GNB_DELETE_TUNNEL_RESP(message_p).status       |= 0xFF;
-        LOG_E(GTPU, "NW_GTPV1U_ULP_API_DESTROY_TUNNEL_ENDPOINT failed");
-      }
-
-      //-----------------------
-      // PDCP->GTPV1U mapping
-      //-----------------------
-      gtpv1u_ue_data_p->bearers[req_pP->pdusession_id[pdusession_index] - GTPV1U_BEARER_OFFSET].state       = BEARER_DOWN;
-      gtpv1u_ue_data_p->bearers[req_pP->pdusession_id[pdusession_index] - GTPV1U_BEARER_OFFSET].teid_gNB    = 0;
-      gtpv1u_ue_data_p->bearers[req_pP->pdusession_id[pdusession_index] - GTPV1U_BEARER_OFFSET].teid_upf    = 0;
-      gtpv1u_ue_data_p->bearers[req_pP->pdusession_id[pdusession_index] - GTPV1U_BEARER_OFFSET].upf_ip_addr = 0;
-      gtpv1u_ue_data_p->num_bearers -= 1;
-
-      if (gtpv1u_ue_data_p->num_bearers == 0) {
-        hash_rc = hashtable_remove(RC.nr_gtpv1u_data_g->ue_mapping, req_pP->rnti);
-        LOG_D(GTPU, "Removed user rnti %x,no more bearers configured\n", req_pP->rnti);
-      }
-
-      //-----------------------
-      // GTPV1U->PDCP mapping
-      //-----------------------
-      hash_rc = hashtable_remove(RC.nr_gtpv1u_data_g->teid_mapping, teid_gNB);
-
-      if (hash_rc != HASH_TABLE_OK) {
-        LOG_D(GTPU, "Removed user rnti %x , gNB NGU teid %u not found\n", req_pP->rnti, teid_gNB);
-      }
-    }
-  }// else silently do nothing
-
-  LOG_D(GTPU, "Tx GTPV1U_GNB_DELETE_TUNNEL_RESP user rnti %x gNB NGU teid %u status %u\n",
-        GTPV1U_GNB_DELETE_TUNNEL_RESP(message_p).rnti,
-        GTPV1U_GNB_DELETE_TUNNEL_RESP(message_p).gnb_NGu_teid,
-        GTPV1U_GNB_DELETE_TUNNEL_RESP(message_p).status);
-  MSC_LOG_TX_MESSAGE(
-    MSC_GTPU_GNB,
-    MSC_RRC_GNB,
-    NULL,0,
-    "0 GTPV1U_GNB_DELETE_TUNNEL_RESP rnti %x teid %x",
-    GTPV1U_GNB_DELETE_TUNNEL_RESP(message_p).rnti,
-    teid_gNB);
-  return itti_send_msg_to_task(TASK_RRC_GNB, instanceP, message_p);
-}
-
-//-----------------------------------------------------------------------------
-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);
-
-  if (message_p == NULL) {
-    return -1;
-  }
-
-  UDP_INIT(message_p).port = req->gnb_port_for_NGu_up;
-  addr.s_addr = req->gnb_ip_address_for_NGu_up;
-  UDP_INIT(message_p).address = inet_ntoa(addr);
-  LOG_I(GTPU, "Tx UDP_INIT IP addr %s (%x)\n", UDP_INIT(message_p).address,UDP_INIT(message_p).port);
-  MSC_LOG_EVENT(
-    MSC_GTPU_ENB,
-    "0 UDP bind  %s:%u",
-    UDP_INIT(message_p).address,
-    UDP_INIT(message_p).port);
-  return itti_send_msg_to_task(TASK_UDP, INSTANCE_DEFAULT, message_p);
-}
-
-static int gtpv1u_ng_req(
-  const instance_t                             instanceP,
-  const Gtpv1uNGReq *const req) {
-  memcpy(&RC.nr_gtpv1u_data_g->gnb_ip_address_for_NGu_up,
-         &req->gnb_ip_address_for_NGu_up,
-         sizeof (req->gnb_ip_address_for_NGu_up));
-  gtpv1u_gNB_send_init_udp(req);
-  return 0;
-}
-
-static int gtpv1u_gnb_tunnel_data_req(gtpv1u_gnb_tunnel_data_req_t *gnb_tunnel_data_req) {
-  gtpv1u_gnb_tunnel_data_req_t *data_req_p           = NULL;
-  NwGtpv1uUlpApiT               stack_req;
-  NwGtpv1uRcT                   rc                   = NW_GTPV1U_FAILURE;
-  hashtable_rc_t                hash_rc              = HASH_TABLE_KEY_NOT_EXISTS;
-  nr_gtpv1u_ue_data_t          *gtpv1u_ue_data_p     = NULL;
-  teid_t                        gnb_ngu_teid         = 0;
-  teid_t                        outgoing_teid         = 0;
-  VCD_SIGNAL_DUMPER_DUMP_FUNCTION_BY_NAME(VCD_SIGNAL_DUMPER_FUNCTIONS_GTPV1U_PROCESS_TUNNEL_DATA_REQ, VCD_FUNCTION_IN);
-  data_req_p = gnb_tunnel_data_req;
-
-  memset(&stack_req, 0, sizeof(NwGtpv1uUlpApiT));
-  hash_rc = hashtable_get(RC.nr_gtpv1u_data_g->ue_mapping, (uint64_t)data_req_p->rnti, (void **)&gtpv1u_ue_data_p);
-
-  if (hash_rc == HASH_TABLE_KEY_NOT_EXISTS) {
-    LOG_E(GTPU, "nwGtpv1uProcessUlpReq failed: while getting ue rnti %x in hashtable ue_mapping\n", data_req_p->rnti);
-  } else {
-    if ((data_req_p->pdusession_id >= GTPV1U_BEARER_OFFSET) && (data_req_p->pdusession_id < max_val_NR_DRB_Identity)) {
-      gnb_ngu_teid                        = gtpv1u_ue_data_p->bearers[data_req_p->pdusession_id - GTPV1U_BEARER_OFFSET].teid_gNB;
-      outgoing_teid                        = gtpv1u_ue_data_p->bearers[data_req_p->pdusession_id - GTPV1U_BEARER_OFFSET].teid_upf;
-      stack_req.apiType                   = NW_GTPV1U_ULP_API_SEND_TPDU;
-      stack_req.apiInfo.sendtoInfo.teid   = outgoing_teid;
-      stack_req.apiInfo.sendtoInfo.ipAddr = gtpv1u_ue_data_p->bearers[data_req_p->pdusession_id - GTPV1U_BEARER_OFFSET].upf_ip_addr;
-      rc = nwGtpv1uGpduMsgNew(
-              RC.nr_gtpv1u_data_g->gtpv1u_stack,
-              outgoing_teid,
-              NW_FALSE,
-              RC.nr_gtpv1u_data_g->seq_num++,
-              data_req_p->buffer,
-              data_req_p->length,
-              data_req_p->offset,
-              &(stack_req.apiInfo.sendtoInfo.hMsg));
-
-      if (rc != NW_GTPV1U_OK) {
-        LOG_E(GTPU, "nwGtpv1uGpduMsgNew failed: 0x%x\n", rc);
-        MSC_LOG_EVENT(MSC_GTPU_GNB,"0 Failed send G-PDU ltid %u rtid %u size %u",
-                      gnb_ngu_teid,outgoing_teid,data_req_p->length);
-        (void)gnb_ngu_teid; /* avoid gcc warning "set but not used" */
-      } else {
-        rc = nwGtpv1uProcessUlpReq(RC.nr_gtpv1u_data_g->gtpv1u_stack, &stack_req);
-
-        if (rc != NW_GTPV1U_OK) {
-          LOG_E(GTPU, "nwGtpv1uProcessUlpReq failed: 0x%x\n", rc);
-          MSC_LOG_EVENT(MSC_GTPU_GNB,"0 Failed send G-PDU ltid %u rtid %u size %u",
-                        gnb_ngu_teid,outgoing_teid,data_req_p->length);
-        } else {
-          MSC_LOG_TX_MESSAGE(
-            MSC_GTPU_GNB,
-            MSC_GTPU_SGW,
-            NULL,
-            0,
-            MSC_AS_TIME_FMT" G-PDU ltid %u rtid %u size %u",
-            0,0,
-            gnb_ngu_teid,
-            outgoing_teid,
-            data_req_p->length);
-        }
-
-        rc = nwGtpv1uMsgDelete(RC.nr_gtpv1u_data_g->gtpv1u_stack,
-                                stack_req.apiInfo.sendtoInfo.hMsg);
-
-        if (rc != NW_GTPV1U_OK) {
-          LOG_E(GTPU, "nwGtpv1uMsgDelete failed: 0x%x\n", rc);
-        }
-      }
-    }
-  }
-
-  VCD_SIGNAL_DUMPER_DUMP_FUNCTION_BY_NAME(VCD_SIGNAL_DUMPER_FUNCTIONS_GTPV1U_PROCESS_TUNNEL_DATA_REQ, VCD_FUNCTION_OUT);
-  /* Buffer still needed, do not free it */
-  //itti_free(ITTI_MSG_ORIGIN_ID(received_message_p), data_req_p->buffer);
-
-  return 0;
-}
-
-//-----------------------------------------------------------------------------
-void *gtpv1u_gNB_process_itti_msg(void *notUsed) {
-  /* Trying to fetch a message from the message queue.
-   * If the queue is empty, this function will block till a
-   * message is sent to the task.
-   */
-  instance_t  instance;
-  MessageDef *received_message_p = NULL;
-  int         rc = 0;
-  itti_receive_msg(TASK_GTPV1_U, &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;
-
-  switch (ITTI_MSG_ID(received_message_p)) {
-    case GTPV1U_GNB_NG_REQ:
-      gtpv1u_ng_req(instance, &received_message_p->ittiMsg.gtpv1uNGReq);
-      break;
-
-    case GTPV1U_GNB_DELETE_TUNNEL_REQ:
-      gtpv1u_delete_ngu_tunnel(instance, &received_message_p->ittiMsg.NRGtpv1uDeleteTunnelReq);
-      break;
-
-    // DATA COMING FROM UDP
-    case UDP_DATA_IND: {
-      udp_data_ind_t *udp_data_ind_p;
-      udp_data_ind_p = &received_message_p->ittiMsg.udp_data_ind;
-      nwGtpv1uProcessUdpReq(RC.nr_gtpv1u_data_g->gtpv1u_stack,
-                            udp_data_ind_p->buffer,
-                            udp_data_ind_p->buffer_length,
-                            udp_data_ind_p->peer_port,
-                            udp_data_ind_p->peer_address);
-    }
-    break;
-
-    // DATA TO BE SENT TO UDP
-    case GTPV1U_GNB_TUNNEL_DATA_REQ:
-      LOG_I(GTPU, "Received message %s\n", ITTI_MSG_NAME(received_message_p));
-      gtpv1u_gnb_tunnel_data_req(&GTPV1U_GNB_TUNNEL_DATA_REQ(received_message_p));
-      break;
-
-    case TERMINATE_MESSAGE: {
-      if (RC.nr_gtpv1u_data_g->ue_mapping != NULL) {
-        hashtable_destroy (&(RC.nr_gtpv1u_data_g->ue_mapping));
-      }
-
-      if (RC.nr_gtpv1u_data_g->teid_mapping != NULL) {
-        hashtable_destroy (&(RC.nr_gtpv1u_data_g->teid_mapping));
-      }
-
-      LOG_W(GTPU, " *** Exiting GTPU thread\n");
-      itti_exit_task();
-    }
-    break;
-
-    case TIMER_HAS_EXPIRED:
-      nwGtpv1uProcessTimeout(&received_message_p->ittiMsg.timer_has_expired.arg);
-      break;
-
-    default: {
-      LOG_E(GTPU, "Unkwnon message ID %d:%s\n",
-            ITTI_MSG_ID(received_message_p),
-            ITTI_MSG_NAME(received_message_p));
-    }
-    break;
-  }
-
-  rc = itti_free(ITTI_MSG_ORIGIN_ID(received_message_p), received_message_p);
-  AssertFatal(rc == EXIT_SUCCESS, "Failed to free memory (%d)!\n", rc);
-  received_message_p = NULL;
-  VCD_SIGNAL_DUMPER_DUMP_FUNCTION_BY_NAME(VCD_SIGNAL_DUMPER_FUNCTIONS_GTPV1U_ENB_TASK, VCD_FUNCTION_OUT);
-  return NULL;
-}
-
-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);
-  MSC_START_USE();
-
-  while(1) {
-    (void) gtpv1u_gNB_process_itti_msg (NULL);
-  }
-
-  return NULL;
-}
diff --git a/openair3/GTPV1-U/gtpv1u_gNB_defs.h b/openair3/GTPV1-U/gtpv1u_gNB_defs.h
deleted file mode 100644
index d4356aa3cf6..00000000000
--- a/openair3/GTPV1-U/gtpv1u_gNB_defs.h
+++ /dev/null
@@ -1,108 +0,0 @@
-/*
- * Licensed to the OpenAirInterface (OAI) Software Alliance under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The OpenAirInterface Software Alliance licenses this file to You under
- * the OAI Public License, Version 1.1  (the "License"); you may not use this file
- * except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.openairinterface.org/?page_id=698
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- *-------------------------------------------------------------------------------
- * For more information about the OpenAirInterface (OAI) Software Alliance:
- *      contact@openairinterface.org
- */
-
-/*! \file gtpv1u_gNB_defs.h
- * \brief 
- * \author Yoshio INOUE, Masayuki HARADA
- * \date 2020
- * \version 0.1
- * \email: yoshio.inoue@fujitsu.com,masayuki.harada@fujitsu.com
- *         (yoshio.inoue%40fujitsu.com%2cmasayuki.harada%40fujitsu.com) 
- */
-
-#include "hashtable.h"
-#include "NR_asn_constant.h"
-
-#ifndef GTPV1U_GNB_DEFS_H_
-#define GTPV1U_GNB_DEFS_H_
-
-#include "NwGtpv1u.h"
-
-#define GTPV1U_UDP_PORT (2152)
-
-#define NR_GTPV1U_MAX_BEARERS_ID     (max_val_NR_DRB_Identity - 3)
-
-#define GTPV1U_SOURCE_GNB (0)
-#define GTPV1U_TARGET_GNB (1)
-#define GTPV1U_MSG_FROM_SOURCE_GNB (0)
-#define GTPV1U_MSG_FROM_UPF (1)
-
-
-typedef struct nr_gtpv1u_teid_data_s {
-  /* UE identifier for oaisim stack */
-  module_id_t     gnb_id;
-  rnti_t          ue_id;
-  pdusessionid_t  pdu_session_id;
-} nr_gtpv1u_teid_data_t;
-
-
-typedef struct nr_gtpv1u_bearer_s {
-  /* TEID used in dl and ul */
-  teid_t          teid_gNB;                ///< gNB TEID
-  uintptr_t       teid_gNB_stack_session;  ///< gNB TEID
-  teid_t          teid_upf;                ///< Remote TEID
-  in_addr_t       upf_ip_addr;
-  struct in6_addr upf_ip6_addr;
-  teid_t          teid_tgNB;
-  in_addr_t       tgnb_ip_addr;				///< target gNB ipv4
-  struct in6_addr tgnb_ip6_addr;				///< target gNB ipv6
-  tcp_udp_port_t  port;
-  //NwGtpv1uStackSessionHandleT stack_session;
-  bearer_state_t state;
-} nr_gtpv1u_bearer_t;
-
-typedef struct nr_gtpv1u_ue_data_s {
-  /* UE identifier for oaisim stack */
-  rnti_t   ue_id;
-
-  /* Unique identifier used between PDCP and GTP-U to distinguish UEs */
-  uint32_t instance_id;
-  int      num_bearers;
-  /* Bearer related data.
-   * Note that the first LCID available for data is 3 and we fixed the maximum
-   * number of e-rab per UE to be (32 [id range]), max RB is 11. The real rb id will 3 + rab_id (3..32).
-   */
-  nr_gtpv1u_bearer_t bearers[NR_GTPV1U_MAX_BEARERS_ID];
-
-  //RB_ENTRY(gtpv1u_ue_data_s) gtpv1u_ue_node;
-} nr_gtpv1u_ue_data_t;
-
-typedef struct nr_gtpv1u_data_s {
-  /* nwgtpv1u stack internal data */
-  NwGtpv1uStackHandleT  gtpv1u_stack;
-
-  /* RB tree of UEs */
-  hash_table_t         *ue_mapping;   // PDCP->GTPV1U
-  hash_table_t         *teid_mapping; // GTPV1U -> PDCP
-
-  //RB_HEAD(gtpv1u_ue_map, gtpv1u_ue_data_s) gtpv1u_ue_map_head;
-  /* Local IP address to use */
-  in_addr_t             gnb_ip_address_for_NGu_up;
-  /* UDP internal data */
-  //udp_data_t            udp_data;
-
-  uint16_t              seq_num;
-  uint8_t               restart_counter;
-
-} nr_gtpv1u_data_t;
-
-
-#endif /* GTPV1U_GNB_DEFS_H_ */
diff --git a/openair3/GTPV1-U/gtpv1u_sgw_defs.h b/openair3/GTPV1-U/gtpv1u_sgw_defs.h
deleted file mode 100644
index 1d62c18bf62..00000000000
--- a/openair3/GTPV1-U/gtpv1u_sgw_defs.h
+++ /dev/null
@@ -1,97 +0,0 @@
-/*
- * Licensed to the OpenAirInterface (OAI) Software Alliance under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The OpenAirInterface Software Alliance licenses this file to You under
- * the OAI Public License, Version 1.1  (the "License"); you may not use this file
- * except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.openairinterface.org/?page_id=698
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- *-------------------------------------------------------------------------------
- * For more information about the OpenAirInterface (OAI) Software Alliance:
- *      contact@openairinterface.org
- */
-
-#ifndef GTPV1U_SGW_DEFS_H_
-#define GTPV1U_SGW_DEFS_H_
-
-#include "mme_config.h"
-#include "NwGtpv1u.h"
-#include "gtpv1u.h"
-#include "hashtable.h"
-#include "common_types.h"
-
-#define GTPV1U_UDP_PORT (2152)
-
-#define MAX_BEARERS_PER_UE (11)
-
-typedef enum {
-  BEARER_DOWN = 0,
-  BEARER_IN_CONFIG,
-  BEARER_UP,
-  BEARER_DL_HANDOVER,
-  BEARER_UL_HANDOVER,
-  BEARER_MAX,
-} bearer_state_t;
-
-#define BUFFER_TO_uint32_t(buf, x) \
-do {                            \
-    x = ((uint32_t)((buf)[0]) ) |      \
-        ((uint32_t)((buf)[1]) << 8) |      \
-        ((uint32_t)((buf)[2]) << 16)  |      \
-        ((uint32_t)((buf)[3]) << 24);             \
-} while(0)
-
-
-
-typedef struct gtpv1u_teid2enb_info_s {
-  /* TEID used in dl and ul */
-  uint32_t       teid_enb;         ///< Remote eNB TEID
-  ip_address_t   enb_ip_addr;
-  bearer_state_t state;
-  uint16_t       port; /// LG ???
-} gtpv1u_teid2enb_info_t;
-
-/*struct gtpv1u_ue_data_s {
-    // UE identifier for oaisim stack
-    uint8_t  ue_id;
-
-    // Unique identifier used between PDCP and GTP-U to distinguish UEs
-    uint32_t instance_id;
-
-    // Bearer related data.
-     // Note that the first LCID available for data is 3 and we fixed the maximum
-     // number of e-rab per UE to be 11. The real rb id will 3 + rab_id (0..10).
-     //
-    struct gtpv1u_bearer_s bearers[MAX_BEARERS_PER_UE];
-
-    RB_ENTRY(gtpv1u_ue_data_s) gtpv1u_ue_node;
-};*/
-
-typedef struct {
-  /* nwgtpv1u stack internal data */
-  NwGtpv1uStackHandleT  gtpv1u_stack;
-  /* RB tree of UEs */
-  //RB_HEAD(gtpv1u_ue_map, gtpv1u_ue_data_s) gtpv1u_ue_map_head;
-  /* Local IP address to use */
-  uint32_t  sgw_ip_address_for_S1u_S12_S4_up;
-  char                 *ip_addr;
-
-  uint16_t              seq_num;
-  uint8_t               restart_counter;
-  //gtpv1u_teid2enb_info_t* teid2enb_mapping[];
-  hash_table_t         *S1U_mapping;
-
-} gtpv1u_data_t;
-
-
-int gtpv1u_init(const mme_config_t *mme_config);
-
-#endif /* GTPV1U_SGW_DEFS_H_ */
diff --git a/openair3/GTPV1-U/gtpv1u_teid_pool.c b/openair3/GTPV1-U/gtpv1u_teid_pool.c
deleted file mode 100644
index ff0ac6f1839..00000000000
--- a/openair3/GTPV1-U/gtpv1u_teid_pool.c
+++ /dev/null
@@ -1,47 +0,0 @@
-/*
- * Licensed to the OpenAirInterface (OAI) Software Alliance under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The OpenAirInterface Software Alliance licenses this file to You under
- * the OAI Public License, Version 1.1  (the "License"); you may not use this file
- * except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.openairinterface.org/?page_id=698
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- *-------------------------------------------------------------------------------
- * For more information about the OpenAirInterface (OAI) Software Alliance:
- *      contact@openairinterface.org
- */
-
-/*! \file gtpv1u_task.c
-* \brief
-* \author Lionel Gauthier
-* \company Eurecom
-* \email: lionel.gauthier@eurecom.fr
-*/
-#include <stdlib.h>
-#include <stdint.h>
-
-#include "gtpv1u.h"
-
-//#define GTPV1U_LINEAR_TEID_ALLOCATION 1
-
-#ifdef GTPV1U_LINEAR_TEID_ALLOCATION
-static uint32_t g_gtpv1u_teid = 0;
-#endif
-
-uint32_t gtpv1u_new_teid(void)
-{
-#ifdef GTPV1U_LINEAR_TEID_ALLOCATION
-  g_gtpv1u_teid = g_gtpv1u_teid + 1;
-  return g_gtpv1u_teid;
-#else
-  return random() + random() % (RAND_MAX - 1) + 1;
-#endif
-}
diff --git a/openair3/GTPV1-U/nw-gtpv1u/AUTHORS b/openair3/GTPV1-U/nw-gtpv1u/AUTHORS
deleted file mode 100644
index b068a40fddf..00000000000
--- a/openair3/GTPV1-U/nw-gtpv1u/AUTHORS
+++ /dev/null
@@ -1 +0,0 @@
-Amit Chawre
diff --git a/openair3/GTPV1-U/nw-gtpv1u/COPYING b/openair3/GTPV1-U/nw-gtpv1u/COPYING
deleted file mode 100644
index d27832d6c11..00000000000
--- a/openair3/GTPV1-U/nw-gtpv1u/COPYING
+++ /dev/null
@@ -1,26 +0,0 @@
-Copyright (c) 2010-2011 Amit Chawre <http://www.amitchawre.net/contact.html>
-All rights reserved.
-
-Redistribution and use in source and binary forms, with or without
-modification, are permitted provided that the following conditions
-are met:
-
-1. Redistributions of source code must retain the above copyright
-notice, this list of conditions and the following disclaimer.
-2. Redistributions in binary form must reproduce the above copyright
-notice, this list of conditions and the following disclaimer in the
-documentation and/or other materials provided with the distribution.
-3. The name of the author may not be used to endorse or promote products
-derived from this software without specific prior written permission.
-
-THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR
-IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
-OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
-IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,
-INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
-NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
-DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
-THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
-(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
-THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
-
diff --git a/openair3/GTPV1-U/nw-gtpv1u/ChangeLog b/openair3/GTPV1-U/nw-gtpv1u/ChangeLog
deleted file mode 100644
index e69de29bb2d..00000000000
diff --git a/openair3/GTPV1-U/nw-gtpv1u/NEWS b/openair3/GTPV1-U/nw-gtpv1u/NEWS
deleted file mode 100644
index e69de29bb2d..00000000000
diff --git a/openair3/GTPV1-U/nw-gtpv1u/README b/openair3/GTPV1-U/nw-gtpv1u/README
deleted file mode 100644
index e69de29bb2d..00000000000
diff --git a/openair3/GTPV1-U/nw-gtpv1u/include/NwGtpv1uLog.h b/openair3/GTPV1-U/nw-gtpv1u/include/NwGtpv1uLog.h
deleted file mode 100644
index 3fb5c8dd052..00000000000
--- a/openair3/GTPV1-U/nw-gtpv1u/include/NwGtpv1uLog.h
+++ /dev/null
@@ -1,83 +0,0 @@
-/*----------------------------------------------------------------------------*
- *                                                                            *
- *                             n w - g t p v 2 u                              *
- *    G P R S   T u n n e l i n g    P r o t o c o l   v 2 u    S t a c k     *
- *                                                                            *
- *                                                                            *
- * Copyright (c) 2010-2011 Amit Chawre                                        *
- * All rights reserved.                                                       *
- *                                                                            *
- * Redistribution and use in source and binary forms, with or without         *
- * modification, are permitted provided that the following conditions         *
- * are met:                                                                   *
- *                                                                            *
- * 1. Redistributions of source code must retain the above copyright          *
- *    notice, this list of conditions and the following disclaimer.           *
- * 2. Redistributions in binary form must reproduce the above copyright       *
- *    notice, this list of conditions and the following disclaimer in the     *
- *    documentation and/or other materials provided with the distribution.    *
- * 3. The name of the author may not be used to endorse or promote products   *
- *    derived from this software without specific prior written permission.   *
- *                                                                            *
- * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR       *
- * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES  *
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.    *
- * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,           *
- * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT   *
- * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,  *
- * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY      *
- * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT        *
- * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF   *
- * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.          *
- *----------------------------------------------------------------------------*/
-
-#ifndef __NW_GTPV1U_LOG_H__
-#define __NW_GTPV1U_LOG_H__
-
-#include <stdio.h>
-#include "NwLog.h"
-
-/**
- * @file NwGtpv1uLog.h
- * @brief This header contains logging related definitions.
-*/
-
-#ifdef __cplusplus
-extern "C" {
-#endif
-
-/*---------------------------------------------------------------------------
- * Log Macro Definition
- *--------------------------------------------------------------------------*/
-
-#define NW_LOG(_gtpv1uHandle, _logLevel, ...)                           \
-  do {                                                                  \
-    if(((NwGtpv1uStackT*)(_gtpv1uHandle))->logLevel >= _logLevel)       \
-    {                                                                   \
-      char _logBuf[1024];                                               \
-      snprintf(_logBuf, 1024, __VA_ARGS__);                             \
-      ((NwGtpv1uStackT*)(_gtpv1uHandle))->logMgr.logReqCallback(((NwGtpv1uStackT*)_gtpv1uHandle)->logMgr.logMgrHandle, _logLevel, __FILE__, __LINE__, _logBuf);\
-    }                                                                   \
-  } while(0)
-
-#define NW_ENTER(_gtpv1uHandle)                                       \
-  do {                                                                  \
-    NW_LOG(_gtpv1uHandle, NW_LOG_LEVEL_DEBG, "Entering '%s'", __func__);\
-  } while(0)
-
-#define NW_LEAVE(_gtpv1uHandle)                                       \
-  do {                                                                  \
-    NW_LOG(_gtpv1uHandle, NW_LOG_LEVEL_DEBG, "Leaving '%s'", __func__);\
-  } while(0)
-
-#ifdef __cplusplus
-}
-#endif
-
-#endif /* __NW_TYPES_H__ */
-
-
-/*--------------------------------------------------------------------------*
- *                      E N D     O F    F I L E                            *
- *--------------------------------------------------------------------------*/
-
diff --git a/openair3/GTPV1-U/nw-gtpv1u/include/NwGtpv1uPrivate.h b/openair3/GTPV1-U/nw-gtpv1u/include/NwGtpv1uPrivate.h
deleted file mode 100644
index 59ffb1e1746..00000000000
--- a/openair3/GTPV1-U/nw-gtpv1u/include/NwGtpv1uPrivate.h
+++ /dev/null
@@ -1,227 +0,0 @@
-/*----------------------------------------------------------------------------*
- *                                                                            *
- *                             n w - g t p v 2 u                              *
- *                             n w - g t p v 2 u                              *
- *    G P R S    T u n n e l i n g    P r o t o c o l   v 2 u   S t a c k     *
- *                                                                            *
- *                                                                            *
- * Copyright (c) 2010-2011 Amit Chawre                                        *
- * All rights reserved.                                                       *
- *                                                                            *
- * Redistribution and use in source and binary forms, with or without         *
- * modification, are permitted provided that the following conditions         *
- * are met:                                                                   *
- *                                                                            *
- * 1. Redistributions of source code must retain the above copyright          *
- *    notice, this list of conditions and the following disclaimer.           *
- * 2. Redistributions in binary form must reproduce the above copyright       *
- *    notice, this list of conditions and the following disclaimer in the     *
- *    documentation and/or other materials provided with the distribution.    *
- * 3. The name of the author may not be used to endorse or promote products   *
- *    derived from this software without specific prior written permission.   *
- *                                                                            *
- * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR       *
- * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES  *
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.    *
- * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,           *
- * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT   *
- * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,  *
- * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY      *
- * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT        *
- * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF   *
- * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.          *
- *----------------------------------------------------------------------------*/
-
-#ifndef __NW_GTPV1U_PRIVATE_H__
-#define __NW_GTPV1U_PRIVATE_H__
-
-#include "tree.h"
-#include "queue.h"
-
-#include "NwTypes.h"
-#include "NwGtpv1uError.h"
-#include "NwGtpv1u.h"
-#include "NwGtpv1uMsg.h"
-
-
-/**
- * @file NwGtpv1uPrivate.h
- * @brief This header file contains nw-gtpv1u private definitions not to be
- * exposed to user application.
-*/
-
-#ifdef __cplusplus
-extern "C" {
-#endif
-
-#define NW_GTPV1U_MALLOC(_stack, _size, _mem, _type)                    \
-  do {                                                                  \
-    if(((NwGtpv1uStackT*)(_stack))->memMgr.memAlloc && ((NwGtpv1uStackT*)(_stack))->memMgr.memFree )\
-    {                                                                   \
-      _mem = (_type) ((NwGtpv1uStackT*) (_stack))->memMgr.memAlloc(((NwGtpv1uStackT*) (_stack))->memMgr.hMemMgr, _size, __FILE__, __LINE__);\
-    }                                                                   \
-    else                                                                \
-    {                                                                   \
-      _mem = (_type) malloc (_size);                                    \
-    }                                                                   \
-  } while (0)
-
-/*--------------------------------------------------------------------------*
- *    G T P U   S T A C K   O B J E C T   T Y P E    D E F I N I T I O N    *
- *--------------------------------------------------------------------------*/
-
-/*--------------------------------------------------------------------------*
- * GRPS Tunneling Protocol Stack Class Definition
- *--------------------------------------------------------------------------*/
-
-/**
- * gtpv1u stack class definition
- */
-
-typedef struct NwGtpv1uStack {
-  uint32_t                        stackType;/**< GTPU_STACK_ENB or GTPU_STACK_SGW   */
-  NwPtrT                        id;
-  uint32_t                        seq;
-  NwGtpv1uUlpEntityT            ulp;
-  NwGtpv1uUdpEntityT            udp;
-  NwGtpv1uMemMgrEntityT         memMgr;
-  NwGtpv1uTimerMgrEntityT       tmrMgr;
-  NwGtpv1uLogMgrEntityT         logMgr;
-  uint32_t                        logLevel;
-  RB_HEAD( NwGtpv1uOutstandingTxSeqNumTrxnMap, NwGtpv1uTrxn) outstandingTxSeqNumMap;
-  RB_HEAD( NwGtpv1uOutstandingRxSeqNumTrxnMap, NwGtpv1uTrxn) outstandingRxSeqNumMap;
-  RB_HEAD(NwGtpv1uTunnelEndPointTMap, NwGtpv1uTunnelEndPoint) sessionMap;
-  RB_HEAD(NwGtpv1uTunnelEndPointIdentifierMap, NwGtpv1uTunnelEndPoint) teidMap;
-} NwGtpv1uStackT;
-
-/**
- * GTP Tunnel End Point class definition
- */
-
-typedef struct NwGtpv1uTunnelEndPoint {
-  uint32_t                        teid;                                   /**< Gtpu Tunnel End Point Identifier   */
-  uint32_t                        peerAddr;                               /**< Peer IP address for the session    */
-  NwGtpv1uStackT*               pStack;                                 /**< Pointer to the parent stack        */
-  NwGtpv1uUlpSessionHandleT     hUlpSession;                            /**< ULP session handle for the session */
-  RB_ENTRY (NwGtpv1uTunnelEndPoint)    sessionMapRbtNode;               /**< RB Tree Data Structure Node        */
-  struct NwGtpv1uTunnelEndPoint *next;
-} NwGtpv1uTunnelEndPointT;
-
-
-/*--------------------------------------------------------------------------*
- * Timeout Info Type Definition
- *--------------------------------------------------------------------------*/
-
-/**
- * gtpv1u timeout info
- */
-
-typedef struct NwGtpv1uTimeoutInfo {
-  NwGtpv1uStackHandleT hStack;
-  void* timeoutArg;
-  NwGtpv1uRcT (*timeoutCallbackFunc)(void*);
-} NwGtpv1uTimeoutInfoT;
-
-/**
- * Start a transaction response timer
- *
- * @param[in] thiz Pointer to stack instance
- * @param[in] timeoutArg Arg to timeout function.
- * @param[out] phTmr Pointer to timer handle.
- * @return NW_GTPV1U_OK on success.
- */
-
-NwGtpv1uRcT
-nwGtpStartTrxnPeerRspTimer(NwGtpv1uStackT* thiz, NwGtpv1uTimeoutInfoT* timeoutInfo, NwGtpv1uTimerHandleT* phTmr);
-
-/**
- * Stop a transaction response timer
- *
- * @param[in] thiz Pointer to stack instance
- * @param[out] phTmr Pointer to timer handle.
- * @return NW_GTPV1U_OK on success.
- */
-
-NwGtpv1uRcT
-nwGtpStopTrxnPeerRspTimer(NwGtpv1uStackT* thiz, NwGtpv1uTimerHandleT* phTmr);
-
-
-#define NW_GTPV1U_MAX_MSG_LEN                                    (4096)  /**< Maximum supported gtpv1u packet length including header */
-
-/**
- * NwGtpv1uMsgT holds gtpv1u messages to/from the peer.
- */
-typedef struct NwGtpv1uMsg {
-  uint8_t         version;
-  uint8_t         protocolType;
-  uint8_t         extHdrFlag;
-  uint8_t         seqNumFlag;
-  uint16_t        npduNumFlag;
-  uint32_t        msgType;
-  uint16_t        msgLen;
-  uint32_t        teid;
-  uint16_t        seqNum;
-  uint8_t         npduNum;
-  uint8_t         nextExtHdrType;
-  uint8_t*        msgBuf;
-  uint32_t        msgBufLen;
-  uint32_t        msgBufOffset;
-  struct NwGtpv1uMsg* next;
-} NwGtpv1uMsgT;
-
-
-/*--------------------------------------------------------------------------*
- * R6/R4 Transaction Context Type Definition
- *--------------------------------------------------------------------------*/
-
-/**
- * Transaction structure
- */
-
-typedef struct NwGtpv1uTrxn {
-  uint32_t                        seqNum;
-  uint32_t                        peerIp;
-  uint32_t                        peerPort;
-  uint8_t                         maxRetries;
-  uint8_t                         t3Timer;
-  NwGtpv1uTimerHandleT          hRspTmr;
-  NwGtpv1uTimeoutInfoT          peerRspTimeoutInfo;
-  NwGtpv1uStackT*               pStack;
-  NwGtpv1uTunnelEndPointT*      pSession;
-  uint32_t                        hUlpTrxn;
-  NwGtpv1uMsgT*                 pMsg;
-  RB_ENTRY (NwGtpv1uTrxn)       outstandingTxSeqNumMapRbtNode;            /**< RB Tree Data Structure Node        */
-  RB_ENTRY (NwGtpv1uTrxn)       outstandingRxSeqNumMapRbtNode;            /**< RB Tree Data Structure Node        */
-  struct NwGtpv1uTrxn*          next;
-} NwGtpv1uTrxnT;
-
-
-/**
- * GTPv2 message header structure
- */
-
-#pragma pack(1)
-
-typedef struct NwGtpv1uMsgHeader {
-  uint8_t PN:1;
-  uint8_t S:1;
-  uint8_t E:1;
-  uint8_t spare:1;
-  uint8_t PT:1;
-  uint8_t version:3;
-  uint8_t msgType;
-  uint16_t msgLength;
-  uint32_t teid;
-} NwGtpv1uMsgHeaderT;
-
-#pragma pack()
-
-#ifdef __cplusplus
-}
-#endif
-
-#endif  /* __NW_GTPV1U_PRIVATE_H__ */
-/*--------------------------------------------------------------------------*
- *                      E N D     O F    F I L E                            *
- *--------------------------------------------------------------------------*/
-
diff --git a/openair3/GTPV1-U/nw-gtpv1u/include/NwGtpv1uTrxn.h b/openair3/GTPV1-U/nw-gtpv1u/include/NwGtpv1uTrxn.h
deleted file mode 100644
index 76228416a96..00000000000
--- a/openair3/GTPV1-U/nw-gtpv1u/include/NwGtpv1uTrxn.h
+++ /dev/null
@@ -1,88 +0,0 @@
-/*----------------------------------------------------------------------------*
- *                                                                            *
- *                             n w - g t p v 2 u                              *
- *    G P R S   T u n n e l i n g    P r o t o c o l   v 2 u    S t a c k     *
- *                                                                            *
- *                                                                            *
- * Copyright (c) 2010-2011 Amit Chawre                                        *
- * All rights reserved.                                                       *
- *                                                                            *
- * Redistribution and use in source and binary forms, with or without         *
- * modification, are permitted provided that the following conditions         *
- * are met:                                                                   *
- *                                                                            *
- * 1. Redistributions of source code must retain the above copyright          *
- *    notice, this list of conditions and the following disclaimer.           *
- * 2. Redistributions in binary form must reproduce the above copyright       *
- *    notice, this list of conditions and the following disclaimer in the     *
- *    documentation and/or other materials provided with the distribution.    *
- * 3. The name of the author may not be used to endorse or promote products   *
- *    derived from this software without specific prior written permission.   *
- *                                                                            *
- * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR       *
- * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES  *
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.    *
- * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,           *
- * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT   *
- * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,  *
- * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY      *
- * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT        *
- * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF   *
- * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.          *
- *----------------------------------------------------------------------------*/
-
-/**
- * @file NwGtpv1uTrxn.h
- * @author Amit Chawre
- * @brief
- *
- * This header file contains required definitions and functions
- * prototypes used by gtpv1u transactions.
- *
- **/
-
-
-#ifndef __NW_GTPV1U_TRXN_H__
-#define __NW_GTPV1U_TRXN_H__
-
-#ifdef __cplusplus
-extern "C" {
-#endif
-
-NwGtpv1uRcT
-nwGtpv1uTrxnNew( NW_IN  NwGtpv1uStackT* thiz,
-                 NW_OUT NwGtpv1uTrxnT **ppTrxn);
-
-
-NwGtpv1uRcT
-nwGtpv1uTrxnWithSeqNew( NW_IN  NwGtpv1uStackT* thiz,
-                        NW_IN  uint32_t seqNum,
-                        NW_OUT NwGtpv1uTrxnT **ppTrxn);
-
-NwGtpv1uRcT
-nwGtpv1uTrxnDelete( NW_INOUT NwGtpv1uTrxnT **ppTrxn);
-
-NwGtpv1uRcT
-nwGtpv1uTrxnNew( NW_IN  NwGtpv1uStackT* thiz,
-                 NW_OUT NwGtpv1uTrxnT **ppTrxn);
-
-NwGtpv1uRcT
-nwGtpv1uTrxnDelete( NW_INOUT NwGtpv1uTrxnT **pthiz);
-
-NwGtpv1uRcT
-nwGtpv1uTrxnCreateAndSendMsg( NW_IN  NwGtpv1uStackT* thiz,
-                              NW_IN  NwGtpv1uTrxnT *pTrxn,
-                              NW_IN  uint32_t peerIp,
-                              NW_IN  uint32_t peerPort,
-                              NW_IN  NwGtpv1uMsgT *pMsg);
-
-#ifdef __cplusplus
-}
-#endif
-
-#endif /* __NW_GTPV1U_TRXN_H__ */
-
-/*--------------------------------------------------------------------------*
- *                      E N D     O F    F I L E                            *
- *--------------------------------------------------------------------------*/
-
diff --git a/openair3/GTPV1-U/nw-gtpv1u/include/NwGtpv1uTunnelEndPoint.h b/openair3/GTPV1-U/nw-gtpv1u/include/NwGtpv1uTunnelEndPoint.h
deleted file mode 100644
index dc4fbab2642..00000000000
--- a/openair3/GTPV1-U/nw-gtpv1u/include/NwGtpv1uTunnelEndPoint.h
+++ /dev/null
@@ -1,85 +0,0 @@
-/*----------------------------------------------------------------------------*
- *                                                                            *
- *                             n w - g t p v 2 u                              *
- *    G P R S    T u n n e l i n g    P r o t o c o l   v 2 u   S t a c k     *
- *                                                                            *
- *                                                                            *
- * Copyright (c) 2010-2011 Amit Chawre                                        *
- * All rights reserved.                                                       *
- *                                                                            *
- * Redistribution and use in source and binary forms, with or without         *
- * modification, are permitted provided that the following conditions         *
- * are met:                                                                   *
- *                                                                            *
- * 1. Redistributions of source code must retain the above copyright          *
- *    notice, this list of conditions and the following disclaimer.           *
- * 2. Redistributions in binary form must reproduce the above copyright       *
- *    notice, this list of conditions and the following disclaimer in the     *
- *    documentation and/or other materials provided with the distribution.    *
- * 3. The name of the author may not be used to endorse or promote products   *
- *    derived from this software without specific prior written permission.   *
- *                                                                            *
- * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR       *
- * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES  *
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.    *
- * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,           *
- * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT   *
- * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,  *
- * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY      *
- * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT        *
- * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF   *
- * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.          *
- *----------------------------------------------------------------------------*/
-
-#include <stdio.h>
-#include <stdlib.h>
-#include <string.h>
-
-#include "NwTypes.h"
-#include "NwUtils.h"
-#include "NwGtpv1uError.h"
-#include "NwGtpv1uPrivate.h"
-#include "NwGtpv1uMsg.h"
-#include "NwGtpv1u.h"
-#include "NwGtpv1uLog.h"
-
-#ifdef __cplusplus
-extern "C" {
-#endif
-
-
-#ifndef __NW_GTPV1U_CONNECTION_H__
-#define __NW_GTPV1U_CONNECTION_H__
-
-/**
-  Constructor
-
-  @return Pointer to session on success, NULL n failure.
- */
-
-NwGtpv1uTunnelEndPointT*
-nwGtpTunnelEndPointNew(struct NwGtpv1uStack* pStack);
-
-/**
-  Destructor
-
-  @param[in] thiz: Pointer to session
-  @return NW_GTPV1U_OK on success.
- */
-
-NwGtpv1uRcT
-nwGtpTunnelEndPointDestroy(struct NwGtpv1uStack* pStack, NwGtpv1uTunnelEndPointT* thiz);
-
-NwGtpv1uRcT
-nwGtpSessionSendMsgApiToUlpEntity(NwGtpv1uTunnelEndPointT* thiz,
-                                  NwGtpv1uMsgT *pMsg);
-
-#ifdef __cplusplus
-}
-#endif
-
-#endif
-/*--------------------------------------------------------------------------*
- *                      E N D     O F    F I L E                            *
- *--------------------------------------------------------------------------*/
-
diff --git a/openair3/GTPV1-U/nw-gtpv1u/shared/NwGtpv1u.h b/openair3/GTPV1-U/nw-gtpv1u/shared/NwGtpv1u.h
deleted file mode 100644
index c6f7c3d6fac..00000000000
--- a/openair3/GTPV1-U/nw-gtpv1u/shared/NwGtpv1u.h
+++ /dev/null
@@ -1,562 +0,0 @@
-/*----------------------------------------------------------------------------*
- *                                                                            *
- *                             n w - g t p v 2 u                              *
- *    G P R S    T u n n e l i n g    P r o t o c o l   v 2 u   S t a c k     *
- *                                                                            *
- *                                                                            *
- * Copyright (c) 2010-2011 Amit Chawre                                        *
- * All rights reserved.                                                       *
- *                                                                            *
- * Redistribution and use in source and binary forms, with or without         *
- * modification, are permitted provided that the following conditions         *
- * are met:                                                                   *
- *                                                                            *
- * 1. Redistributions of source code must retain the above copyright          *
- *    notice, this list of conditions and the following disclaimer.           *
- * 2. Redistributions in binary form must reproduce the above copyright       *
- *    notice, this list of conditions and the following disclaimer in the     *
- *    documentation and/or other materials provided with the distribution.    *
- * 3. The name of the author may not be used to endorse or promote products   *
- *    derived from this software without specific prior written permission.   *
- *                                                                            *
- * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR       *
- * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES  *
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.    *
- * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,           *
- * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT   *
- * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,  *
- * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY      *
- * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT        *
- * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF   *
- * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.          *
- *----------------------------------------------------------------------------*/
-
-#ifndef __NW_GTPV1U_H__
-#define __NW_GTPV1U_H__
-
-#include <sys/types.h>
-#include <sys/socket.h>
-#include <arpa/inet.h>
-#include "NwTypes.h"
-#include "NwGtpv1uError.h"
-
-
-/**
- * @file NwGtpv1u.h
- * @author Amit Chawre
- * @brief
- *
- * This header file contains all required definitions and functions
- * prototypes for using nw-gtpv1u library.
- *
- **/
-
-#define NW_GTPU_VERSION                                         (0x01)
-#define NW_GTP_PROTOCOL_TYPE_GTP                                (0x01)
-#define NW_GTP_PROTOCOL_TYPE_GTP_PRIME                          (0x00)
-
-/*--------------------------------------------------------------------------*
- *                   S H A R E D     A P I    M A C R O S                   *
- *--------------------------------------------------------------------------*/
-
-#define NW_GTP_ECHO_REQ                                         (1)
-#define NW_GTP_ECHO_RSP                                         (2)
-#define NW_GTP_ERROR_INDICATION                                 (26)
-#define NW_GTP_SUPPORTED_EXTENSION_HEADER_INDICATION            (31)
-#define NW_GTP_END_MARKER                                       (254)
-#define NW_GTP_GPDU                                             (255)
-
-/*---------------------------------------------------------------------------
- * Opaque Gtpv2 Stack Handles
- *--------------------------------------------------------------------------*/
-
-typedef NwPtrT  NwGtpv1uStackHandleT;                     /**< Gtpv2 Stack Handle               */
-typedef NwPtrT  NwGtpv1uUlpHandleT;                       /**< Gtpv2 Stack Ulp Entity Handle    */
-typedef NwPtrT  NwGtpv1uUdpHandleT;                       /**< Gtpv2 Stack Udp Entity Handle    */
-typedef NwPtrT  NwGtpv1uMemMgrHandleT;                    /**< Gtpv2 Stack Mem Manager Handle   */
-typedef NwPtrT  NwGtpv1uTimerMgrHandleT;                  /**< Gtpv2 Stack Timer Manager Handle */
-typedef NwPtrT  NwGtpv1uLogMgrHandleT;                    /**< Gtpv2 Stack Log Mnagaer Handle   */
-typedef NwPtrT  NwGtpv1uTimerHandleT;                     /**< Gtpv2 Stack Timer Handle         */
-typedef NwPtrT  NwGtpv1uMsgHandleT;                       /**< Gtpv2 Msg Handle                 */
-
-typedef struct NwGtpv1uStackConfig {
-  uint16_t udpSrcPort;
-} NwGtpv1uStackConfigT;
-
-/*--------------------------------------------------------------------------*
- *            S T A C K        A P I      D E F I N I T I O N S             *
- *--------------------------------------------------------------------------*/
-
-/*---------------------------------------------------------------------------
- * Gtpv2 Stack ULP API type definitions
- *--------------------------------------------------------------------------*/
-
-/**
- * APIs types between ULP and Stack
- */
-
-typedef enum {
-  /* APIs from ULP to stack */
-
-  NW_GTPV1U_ULP_API_CREATE_TUNNEL_ENDPOINT = 0x00000000,        /**< Create a local teid context on stack       */
-  NW_GTPV1U_ULP_API_DESTROY_TUNNEL_ENDPOINT,                    /**< Delete a local teid context on stack       */
-  NW_GTPV1U_ULP_API_INITIAL_REQ,                                /**< Send a Initial Request over a session      */
-  NW_GTPV1U_ULP_API_TRIGGERED_REQ,                              /**< Send a Initial Request over a session      */
-  NW_GTPV1U_ULP_API_TRIGGERED_RSP,                              /**< Send a Trigger Response over a session     */
-  NW_GTPV1U_ULP_API_SEND_TPDU,                                  /**< Send a T-PDU message over teid context     */
-
-  /* APIs from stack to ULP */
-
-  NW_GTPV1U_ULP_API_RECV_TPDU,                                  /**< Receive a gtpv1u T-PDU from stack          */
-  NW_GTPV1U_ULP_API_RECV_MSG,                                   /**< Receive a gtpv1u message from stack        */
-  NW_GTPV1U_ULP_API_RSP_FAILURE,                                /**< Rsp failure for gtpv2 message from stack   */
-
-  /* Do not add below this */
-
-  NW_GTPV1U_ULP_API_END            = 0xFFFFFFFF,
-} NwGtpv1uUlpApiTypeT;
-
-/*---------------------------------------------------------------------------
- * Gtpv2 Stack API information elements definitions
- *--------------------------------------------------------------------------*/
-
-typedef NwPtrT  NwGtpv1uStackSessionHandleT;/**< Gtpv2 Stack session Handle */
-typedef uint8_t   NwGtpv1uMsgTypeT;           /**< Gtpv2 Msg Type     */
-typedef NwPtrT  NwGtpv1uTrxnHandleT;        /**< Gtpv2 Transaction Handle */
-typedef NwPtrT  NwGtpv1uUlpTrxnHandleT;     /**< Gtpv2 Ulp Transaction Handle */
-typedef NwPtrT  NwGtpv1uUlpSessionHandleT;  /**< Gtpv2 Ulp session Handle */
-
-/**
- * API information elements between ULP and Stack for
- * creating a session.
- */
-
-typedef struct {
-  NW_IN    uint32_t                       teid;
-  NW_IN    NwGtpv1uUlpSessionHandleT    hUlpSession;
-  NW_OUT   NwGtpv1uStackSessionHandleT  hStackSession;
-} NwGtpv1uCreateTunnelEndPointT;
-
-/**
- * API information elements between ULP and Stack for
- * destroying a session.
- */
-
-typedef struct {
-  NW_IN   NwGtpv1uStackSessionHandleT   hStackSessionHandle;
-} NwGtpv1uDestroyTunnelEndPointT;
-
-/**
- * API information elements between ULP and Stack for
- * sending a Gtpv1u initial message.
- */
-
-typedef struct {
-  NW_IN    NwGtpv1uUlpTrxnHandleT        hUlpTrxn;
-  NW_IN    uint32_t                        peerIp;
-  NW_IN    uint32_t                        peerPort;
-  NW_IN    uint8_t                         flags;
-  NW_IN    uint32_t                        teid;
-} NwGtpv1uInitialReqInfoT;
-
-/**
- * API information elements between ULP and Stack for
- * sending a Gtpv1u triggered response message.
- */
-
-typedef struct {
-  NW_IN    NwGtpv1uUlpTrxnHandleT        hUlpTrxn;
-  NW_IN    uint32_t                        peerIp;
-  NW_IN    uint32_t                        peerPort;
-  NW_IN    uint8_t                         flags;
-  NW_IN    uint32_t                        teid;
-  NW_IN    uint32_t                        seqNum;
-  NW_IN    NwGtpv1uMsgHandleT            hMsg;
-} NwGtpv1uTriggeredRspInfoT;
-
-/**
- * API information elements between ULP and Stack for
- * sending a Gtpv1u triggered request message.
- */
-
-typedef struct {
-  NW_IN    NwGtpv1uUlpTrxnHandleT        hUlpTrxn;
-  NW_IN    uint32_t                        peerIp;
-  NW_IN    uint32_t                        peerPort;
-  NW_IN    uint8_t                         flags;
-  NW_IN    uint32_t                        teid;
-  NW_IN    uint32_t                        seqNum;
-  NW_IN    NwGtpv1uMsgHandleT            hMsg;
-} NwGtpv1uTriggeredReqInfoT;
-
-
-/**
- * API information elements between ULP and Stack for
- * sending a Gtpv2 message over a session.
- */
-
-typedef struct {
-  NW_IN    uint32_t                       teid;
-  NW_IN    uint32_t                       ipAddr;
-  NW_IN    uint8_t                        flags;
-  NW_IN    NwGtpv1uMsgHandleT           hMsg;
-} NwGtpv1uSendtoInfoT;
-
-
-/**
- * API information elements between ULP and Stack for
- * sending a Gtpv2 message over a session.
- */
-
-typedef struct {
-  NW_OUT   NwGtpv1uStackSessionHandleT  hStackSessionHandle;
-  NW_INOUT NwGtpv1uTrxnHandleT          hTrxn;
-  NW_IN    NwGtpv1uUlpTrxnHandleT       hUlpTrxn;
-  NW_IN    NwGtpv1uMsgTypeT            msgType;
-  NW_IN    uint8_t                        flags;
-  NW_IN    NwGtpv1uMsgHandleT           hMsg;
-} NwGtpv1uSendMsgInfoT;
-
-/**
- * API information elements between ULP and Stack for
- * receiving a Gtpv2 message over a session from stack.
- */
-
-typedef struct {
-  NW_IN    NwGtpv1uUlpSessionHandleT    hUlpSession;
-  NW_IN    NwGtpv1uUlpTrxnHandleT       hUlpTrxn;
-  NW_IN    uint32_t                       teid;
-  NW_IN    uint32_t                       peerIp;
-  NW_IN    uint32_t                       peerPort;
-  NW_IN    uint32_t                       msgType;      /**< Message type                       */
-  NW_IN    NwGtpv1uMsgHandleT           hMsg;         /**< Gtp Message handle                 */
-} NwGtpv1uRecvMsgInfoT;
-
-/**
- * API information elements between ULP and Stack for
- * receiving a Gtpv2 message over a session from stack.
- */
-
-typedef struct {
-  NW_IN    NwGtpv1uUlpSessionHandleT    hUlpSession;
-  NW_IN    NwGtpv1uTrxnHandleT          hTrxn;
-} NwGtpv1uNackInfoT;
-
-/*---------------------------------------------------------------------------
- * Gtpv2 Stack API structure definition
- *--------------------------------------------------------------------------*/
-
-/**
- * API structure between ULP and Stack
- */
-
-typedef struct {
-  NwGtpv1uUlpApiTypeT                   apiType;
-  NwGtpv1uMsgHandleT                    hMsg;
-  union {
-    NwGtpv1uCreateTunnelEndPointT       createTunnelEndPointInfo;
-    NwGtpv1uDestroyTunnelEndPointT      destroyTunnelEndPointInfo;
-    NwGtpv1uInitialReqInfoT             initialReqInfo;
-    NwGtpv1uTriggeredRspInfoT           triggeredRspInfo;
-    NwGtpv1uTriggeredReqInfoT           triggeredReqInfo;
-    NwGtpv1uSendtoInfoT                 sendtoInfo;
-    NwGtpv1uSendMsgInfoT                sendMsgInfo;
-    NwGtpv1uRecvMsgInfoT                recvMsgInfo;
-    NwGtpv1uNackInfoT                   nackMsgInfo;
-  } apiInfo;
-} NwGtpv1uUlpApiT;
-
-
-/*--------------------------------------------------------------------------*
- *           S T A C K    E N T I T I E S    D E F I N I T I O N S          *
- *--------------------------------------------------------------------------*/
-
-/*---------------------------------------------------------------------------
- * ULP Entity Definitions
- *--------------------------------------------------------------------------*/
-
-/**
- * Gtpv2 ULP entity definition
- */
-
-typedef struct {
-  NwGtpv1uUlpHandleT        hUlp;
-  NwGtpv1uRcT (*ulpReqCallback) ( NW_IN        NwGtpv1uUlpHandleT hUlp,
-                                  NW_IN        NwGtpv1uUlpApiT *pUlpApi);
-} NwGtpv1uUlpEntityT;
-
-
-/*---------------------------------------------------------------------------
- * UDP Entity Definitions
- *--------------------------------------------------------------------------*/
-
-/**
- * Gtpv2 UDP entity definition
- */
-
-typedef struct {
-  NwGtpv1uUdpHandleT        hUdp;
-  NwGtpv1uRcT (*udpDataReqCallback) ( NW_IN     NwGtpv1uUdpHandleT udpHandle,
-                                      NW_IN     uint8_t* dataBuf,
-                                      NW_IN     uint32_t dataSize,
-                                      NW_IN     uint32_t dataOffset,
-                                      NW_IN     uint32_t peerIP,
-                                      NW_IN     uint16_t peerPort);
-} NwGtpv1uUdpEntityT;
-
-/**
- * Gtpv1u Memory Manager entity definition
- */
-
-typedef struct {
-  NwGtpv1uMemMgrHandleT         hMemMgr;
-  void* (*memAlloc)( NW_IN      NwGtpv1uMemMgrHandleT hMemMgr,
-                     NW_IN      uint32_t memSize,
-                     NW_IN      NwCharT* fileName,
-                     NW_IN      uint32_t lineNumber);
-
-  void (*memFree) ( NW_IN       NwGtpv1uMemMgrHandleT hMemMgr,
-                    NW_IN       void* hMem,
-                    NW_IN       NwCharT* fileName,
-                    NW_IN       uint32_t lineNumber);
-} NwGtpv1uMemMgrEntityT;
-
-
-/*---------------------------------------------------------------------------
- * Timer Entity Definitions
- *--------------------------------------------------------------------------*/
-
-#define NW_GTPV1U_TMR_TYPE_ONE_SHOT                                  (0)
-#define NW_GTPV1U_TMR_TYPE_REPETITIVE                                (1)
-
-/**
- * Gtpv2 Timer Manager entity definition
- */
-
-typedef struct {
-  NwGtpv1uTimerMgrHandleT        tmrMgrHandle;
-  NwGtpv1uRcT (*tmrStartCallback)( NW_IN       NwGtpv1uTimerMgrHandleT tmrMgrHandle,
-                                   NW_IN       uint32_t timeoutSecs,
-                                   NW_IN       uint32_t timeoutUsec,
-                                   NW_IN       uint32_t tmrType,
-                                   NW_IN       void* tmrArg,
-                                   NW_OUT      NwGtpv1uTimerHandleT* tmrHandle);
-
-  NwGtpv1uRcT (*tmrStopCallback) ( NW_IN       NwGtpv1uTimerMgrHandleT tmrMgrHandle,
-                                   NW_IN       NwGtpv1uTimerHandleT tmrHandle);
-} NwGtpv1uTimerMgrEntityT;
-
-
-/*---------------------------------------------------------------------------
- * Log Entity Definitions
- *--------------------------------------------------------------------------*/
-
-/**
- * Gtpv2 Log manager entity definition
- */
-
-typedef struct {
-  NwGtpv1uLogMgrHandleT          logMgrHandle;
-  NwGtpv1uRcT (*logReqCallback) (NW_IN      NwGtpv1uLogMgrHandleT logMgrHandle,
-                                 NW_IN      uint32_t logLevel,
-                                 NW_IN      NwCharT* file,
-                                 NW_IN      uint32_t line,
-                                 NW_IN      NwCharT* logStr);
-} NwGtpv1uLogMgrEntityT;
-
-
-/*--------------------------------------------------------------------------*
- *                     P U B L I C   F U N C T I O N S                      *
- *--------------------------------------------------------------------------*/
-
-#ifdef __cplusplus
-extern "C" {
-#endif
-
-/*---------------------------------------------------------------------------
- *  Constructor
- *--------------------------------------------------------------------------*/
-
-/**
- Initialize the nw-gtpv1u stack.
-
- @param[in,out] phGtpv1uStackHandle : Pointer to stack handle
- @param[in]     stackType : GTPU_STACK_ENB or GTPU_STACK_SGW
- */
-
-NwGtpv1uRcT
-nwGtpv1uInitialize( NW_INOUT NwGtpv1uStackHandleT* phGtpv1uStackHandle, uint32_t stackType);
-
-/*---------------------------------------------------------------------------
- * Destructor
- *--------------------------------------------------------------------------*/
-
-/**
- Destroy the nw-gtpv1u stack.
-
- @param[in] hGtpv1uStackHandle : Stack handle
- */
-
-NwGtpv1uRcT
-nwGtpv1uFinalize( NW_IN  NwGtpv1uStackHandleT hGtpv1uStackHandle);
-
-/*---------------------------------------------------------------------------
- * Configuration Get/Set Operations
- *--------------------------------------------------------------------------*/
-
-/**
- Set Configuration for the nw-gtpv1u stack.
-
- @param[in,out] phGtpv1uStackHandle : Pointer to stack handle
- */
-
-NwGtpv1uRcT
-NwGtpv1uConfigSet( NW_IN NwGtpv1uStackHandleT* phGtpv1uStackHandle, NW_IN NwGtpv1uStackConfigT* pConfig);
-
-/**
- Get Configuration for the nw-gtpv1u stack.
-
- @param[in,out] phGtpv1uStackHandle : Pointer to stack handle
- */
-
-NwGtpv1uRcT
-NwGtpv1uConfigGet( NW_IN NwGtpv1uStackHandleT* phGtpv1uStackHandle, NW_OUT NwGtpv1uStackConfigT* pConfig);
-
-/**
- Set ULP entity for the stack.
-
- @param[in] hGtpv1uStackHandle : Stack handle
- @param[in] pUlpEntity : Pointer to ULP entity.
- @return NW_GTPV1U_OK on success.
- */
-
-NwGtpv1uRcT
-nwGtpv1uSetUlpEntity( NW_IN NwGtpv1uStackHandleT hGtpv1uStackHandle,
-                      NW_IN NwGtpv1uUlpEntityT* pUlpEntity);
-
-/**
- Set UDP entity for the stack.
-
- @param[in] hGtpv1uStackHandle : Stack handle
- @param[in] pUdpEntity : Pointer to UDP entity.
- @return NW_GTPV1U_OK on success.
- */
-
-NwGtpv1uRcT
-nwGtpv1uSetUdpEntity( NW_IN NwGtpv1uStackHandleT hGtpv1uStackHandle,
-                      NW_IN NwGtpv1uUdpEntityT* pUdpEntity);
-
-/**
- Set MemMgr entity for the stack.
-
- @param[in] hGtpv1uStackHandle : Stack handle
- @param[in] pMemMgr : Pointer to Memory Manager.
- @return NW_GTPV1U_OK on success.
- */
-
-NwGtpv1uRcT
-nwGtpv1uSetMemMgrEntity( NW_IN NwGtpv1uStackHandleT hGtpv1uStackHandle,
-                         NW_IN NwGtpv1uMemMgrEntityT* pMemMgr);
-
-
-/**
- Set TmrMgr entity for the stack.
-
- @param[in] hGtpv1uStackHandle : Stack handle
- @param[in] pTmrMgr : Pointer to Timer Manager.
- @return NW_GTPV1U_OK on success.
- */
-
-NwGtpv1uRcT
-nwGtpv1uSetTimerMgrEntity( NW_IN NwGtpv1uStackHandleT hGtpv1uStackHandle,
-                           NW_IN NwGtpv1uTimerMgrEntityT* pTmrMgr);
-
-/**
- Set LogMgr entity for the stack.
-
- @param[in] hGtpv1uStackHandle : Stack handle
- @param[in] pLogMgr : Pointer to Log Manager.
- @return NW_GTPV1U_OK on success.
- */
-
-NwGtpv1uRcT
-nwGtpv1uSetLogMgrEntity( NW_IN NwGtpv1uStackHandleT hGtpv1uStackHandle,
-                         NW_IN NwGtpv1uLogMgrEntityT* pLogMgr);
-
-/**
- Set log level for the stack.
-
- @param[in] hGtpv1uStackHandle : Stack handle
- @param[in] logLevel : Log level.
- @return NW_GTPV1U_OK on success.
- */
-
-NwGtpv1uRcT
-nwGtpv1uSetLogLevel( NW_IN NwGtpv1uStackHandleT hGtpuStackHandle,
-                     NW_IN uint32_t logLevel);
-/*---------------------------------------------------------------------------
- * Process Request from Udp Layer
- *--------------------------------------------------------------------------*/
-
-/**
- Process Data Request from UDP entity.
-
- @param[in] hGtpv1uStackHandle : Stack handle
- @param[in] udpData : Pointer to received UDP data.
- @param[in] udpDataLen : Received data length.
- @param[in] dstPort : Received on port.
- @param[in] from : Received from peer information.
- @return NW_GTPV1U_OK on success.
- */
-
-NwGtpv1uRcT
-nwGtpv1uProcessUdpReq( NW_IN NwGtpv1uStackHandleT hGtpv1uStackHandle,
-                       NW_IN uint8_t* udpData,
-                       NW_IN uint32_t udpDataLen,
-                       NW_IN uint16_t peerPort,
-                       NW_IN uint32_t peerIP);
-
-/*---------------------------------------------------------------------------
- * Process Request from Upper Layer
- *--------------------------------------------------------------------------*/
-
-/**
- Process Request from ULP entity.
-
- @param[in] hGtpv1uStackHandle : Stack handle
- @param[in] pLogMgr : Pointer to Ulp Req.
- @return NW_GTPV1U_OK on success.
- */
-
-NwGtpv1uRcT
-nwGtpv1uProcessUlpReq( NW_IN NwGtpv1uStackHandleT hGtpv1uStackHandle,
-                       NW_IN NwGtpv1uUlpApiT *ulpReq);
-
-
-/*---------------------------------------------------------------------------
- * Process Timer timeout Request from Timer Manager
- *--------------------------------------------------------------------------*/
-
-/**
- Process Timer timeout Request from Timer Manager
-
- @param[in] pLogMgr : Pointer timeout arguments.
- @return NW_GTPV1U_OK on success.
- */
-
-NwGtpv1uRcT
-nwGtpv1uProcessTimeout( NW_IN void* timeoutArg);
-
-NwGtpv1uRcT
-nwGtpv1uPeerRspTimeout(void* arg);
-
-#ifdef __cplusplus
-}
-#endif
-
-#endif  /* __NW_GTPV1U_H__ */
-
-/*--------------------------------------------------------------------------*
- *                      E N D     O F    F I L E                            *
- *--------------------------------------------------------------------------*/
-
diff --git a/openair3/GTPV1-U/nw-gtpv1u/shared/NwGtpv1uError.h b/openair3/GTPV1-U/nw-gtpv1u/shared/NwGtpv1uError.h
deleted file mode 100644
index 6da3b80dfac..00000000000
--- a/openair3/GTPV1-U/nw-gtpv1u/shared/NwGtpv1uError.h
+++ /dev/null
@@ -1,63 +0,0 @@
-/*----------------------------------------------------------------------------*
- *                                                                            *
- *                              n w - g t p v 2 c                             *
- *    G P R S   T u n n e l i n g    P r o t o c o l   v 2 c    S t a c k     *
- *                                                                            *
- *                                                                            *
- * Copyright (c) 2010-2011 Amit Chawre                                        *
- * All rights reserved.                                                       *
- *                                                                            *
- * Redistribution and use in source and binary forms, with or without         *
- * modification, are permitted provided that the following conditions         *
- * are met:                                                                   *
- *                                                                            *
- * 1. Redistributions of source code must retain the above copyright          *
- *    notice, this list of conditions and the following disclaimer.           *
- * 2. Redistributions in binary form must reproduce the above copyright       *
- *    notice, this list of conditions and the following disclaimer in the     *
- *    documentation and/or other materials provided with the distribution.    *
- * 3. The name of the author may not be used to endorse or promote products   *
- *    derived from this software without specific prior written permission.   *
- *                                                                            *
- * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR       *
- * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES  *
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.    *
- * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,           *
- * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT   *
- * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,  *
- * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY      *
- * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT        *
- * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF   *
- * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.          *
- *----------------------------------------------------------------------------*/
-
-
-#ifndef __NW_GTPV1U_ERROR_H__
-#define __NW_GTPV1U_ERROR_H__
-
-/**
- * @file NwGtpv1uError.h
- * @brief This header file contains return error code type definitions.
-*/
-
-#ifdef __cplusplus
-extern "C" {
-#endif
-
-typedef enum {
-
-  NW_GTPV1U_OK                 = 0x00000000,
-  NW_GTPV1U_MANDATORY_IE_DUPLICATE,
-  NW_GTPV1U_MANDATORY_IE_MISSING,
-  NW_GTPV1U_MSG_MALFORMED,
-  NW_GTPV1U_FAILURE            = 0xFFFFFFFE
-}
-NwGtpv1uRcT;
-
-#ifdef __cplusplus
-}
-#endif
-
-#endif /* __NW_GTPV1U_ERROR_H__*/
-
-
diff --git a/openair3/GTPV1-U/nw-gtpv1u/shared/NwGtpv1uIe.h b/openair3/GTPV1-U/nw-gtpv1u/shared/NwGtpv1uIe.h
deleted file mode 100644
index 7bb51dcda0e..00000000000
--- a/openair3/GTPV1-U/nw-gtpv1u/shared/NwGtpv1uIe.h
+++ /dev/null
@@ -1,66 +0,0 @@
-/*----------------------------------------------------------------------------*
- *                                                                            *
- *                             n w - g t p v 2 u                              *
- *    G P R S   T u n n e l i n g    P r o t o c o l   v 2 u    S t a c k     *
- *                                                                            *
- *                                                                            *
- * Copyright (c) 2010-2011 Amit Chawre                                        *
- * All rights reserved.                                                       *
- *                                                                            *
- * Redistribution and use in source and binary forms, with or without         *
- * modification, are permitted provided that the following conditions         *
- * are met:                                                                   *
- *                                                                            *
- * 1. Redistributions of source code must retain the above copyright          *
- *    notice, this list of conditions and the following disclaimer.           *
- * 2. Redistributions in binary form must reproduce the above copyright       *
- *    notice, this list of conditions and the following disclaimer in the     *
- *    documentation and/or other materials provided with the distribution.    *
- * 3. The name of the author may not be used to endorse or promote products   *
- *    derived from this software without specific prior written permission.   *
- *                                                                            *
- * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR       *
- * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES  *
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.    *
- * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,           *
- * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT   *
- * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,  *
- * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY      *
- * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT        *
- * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF   *
- * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.          *
- *----------------------------------------------------------------------------*/
-
-/**
- * @file NwGtpv1uIe.h
- * @brief This header file contains Information Element definitions for GTPv1u
- * as per 3GPP TS 29281-930.
-*/
-
-#ifndef __NW_GTPV1U_IE_H__
-#define __NW_GTPV1U_IE_H__
-
-/*--------------------------------------------------------------------------*
- *   G T P V 2 U    I E  T Y P E     M A C R O     D E F I N I T I O N S    *
- *--------------------------------------------------------------------------*/
-
-#define NW_GTPV1U_IE_RECOVERY                                           (14)
-#define NW_GTPV1U_IE_TEID_DATA_I                                        (15)
-#define NW_GTPV1U_IE_GSN_ADDRESS                                        (133)
-#define NW_GTPV1U_IE_EXT_HDR_TYPE_LIST                                  (141)
-#define NW_GTPV1U_IE_PRIVATE_EXTENSION                                  (255)
-
-
-/*--------------------------------------------------------------------------*
- *   G T P V 2 U      C A U S E      V A L U E     D E F I N I T I O N S    *
- *--------------------------------------------------------------------------*/
-
-#define NW_GTPV1U_CAUSE_REQUEST_ACCEPTED                                (16)
-#define NW_GTPV1U_CAUSE_MANDATORY_IE_MISSING                            (70)
-
-#endif  /* __NW_GTPV1U_IE_H__ */
-
-/*--------------------------------------------------------------------------*
- *                      E N D     O F    F I L E                            *
- *--------------------------------------------------------------------------*/
-
diff --git a/openair3/GTPV1-U/nw-gtpv1u/shared/NwGtpv1uMsg.h b/openair3/GTPV1-U/nw-gtpv1u/shared/NwGtpv1uMsg.h
deleted file mode 100644
index f6bc0415f2a..00000000000
--- a/openair3/GTPV1-U/nw-gtpv1u/shared/NwGtpv1uMsg.h
+++ /dev/null
@@ -1,317 +0,0 @@
-/*----------------------------------------------------------------------------*
- *                                                                            *
- *                             n w - g t p v 2 u                              *
- *    G P R S   T u n n e l i n g    P r o t o c o l   v 2 u    S t a c k     *
- *                                                                            *
- *                                                                            *
- * Copyright (c) 2010-2011 Amit Chawre                                        *
- * All rights reserved.                                                       *
- *                                                                            *
- * Redistribution and use in source and binary forms, with or without         *
- * modification, are permitted provided that the following conditions         *
- * are met:                                                                   *
- *                                                                            *
- * 1. Redistributions of source code must retain the above copyright          *
- *    notice, this list of conditions and the following disclaimer.           *
- * 2. Redistributions in binary form must reproduce the above copyright       *
- *    notice, this list of conditions and the following disclaimer in the     *
- *    documentation and/or other materials provided with the distribution.    *
- * 3. The name of the author may not be used to endorse or promote products   *
- *    derived from this software without specific prior written permission.   *
- *                                                                            *
- * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR       *
- * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES  *
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.    *
- * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,           *
- * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT   *
- * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,  *
- * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY      *
- * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT        *
- * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF   *
- * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.          *
- *----------------------------------------------------------------------------*/
-
-#ifndef __NW_GTPV1U_MSG_H__
-#define __NW_GTPV1U_MSG_H__
-
-#include "NwTypes.h"
-#include "NwGtpv1u.h"
-
-/**
- * @file NwGtpv1uMsg.h
- * @brief This file defines APIs for to build new outgoing gtpv1u messages and to parse incoming messages.
-*/
-
-#ifdef __cplusplus
-extern "C" {
-#endif
-
-/*--------------------------------------------------------------------------*
- *   G T P V 2 C     I E    D A T A - T Y P E      D E F I N I T I O N S    *
- *--------------------------------------------------------------------------*/
-
-#pragma pack(1)
-
-typedef struct NwGtpv1uIeTv1 {
-  uint8_t  t;
-  uint8_t  v;
-} NwGtpv1uIeTv1T;
-
-typedef struct NwGtpv1uIeTv2 {
-  uint8_t  t;
-  uint8_t  v;
-} NwGtpv1uIeTv2T;
-
-typedef struct NwGtpv1uIeTv4 {
-  uint8_t  t;
-  uint32_t  v;
-} NwGtpv1uIeTv4T;
-
-typedef struct NwGtpv1uIeTlv {
-  uint8_t  t;
-  uint16_t l;
-} NwGtpv1uIeTlvT;
-
-#pragma pack()
-
-
-/**
- * Allocate a GPDU gtpv1u message.
- *
- * @param[in] hGtpuStackHandle : gtpv1u stack handle.
- * @param[in] teidPresent : TEID is present flag.
- * @param[in] teid : TEID for this message.
- * @param[in] seqNum : Sequence number for this message.
- * @param[out] phMsg : Pointer to message handle.
- */
-
-NwGtpv1uRcT
-nwGtpv1uMsgNew( NW_IN NwGtpv1uStackHandleT hGtpuStackHandle,
-                NW_IN uint8_t     seqNumFlag,
-                NW_IN uint8_t     npduNumFlag,
-                NW_IN uint8_t     extHdrFlag,
-                NW_IN uint8_t     msgType,
-                NW_IN uint8_t     teid,
-                NW_IN uint16_t    seqNum,
-                NW_IN uint8_t     npduNum,
-                NW_IN uint8_t     nextExtHeader,
-                NW_OUT NwGtpv1uMsgHandleT *phMsg);
-
-
-/**
- * Allocate a gtpv1u message.
- *
- * @param[in] hGtpuStackHandle : gtpv1u stack handle.
- * @param[in] teid : TEID for this message.
- * @param[in] seqNumFlag : Sequence number flag for this message.
- * @param[in] seqNum : Sequence number for this message.
- * @param[in] pTpdu: T-PDU for this message.
- * @param[in] tpduLength: T-PDU length for this message.
- * @param[out] phMsg : Pointer to message handle.
- */
-
-NwGtpv1uRcT
-nwGtpv1uGpduMsgNew( NW_IN NwGtpv1uStackHandleT hGtpuStackHandle,
-                    NW_IN uint32_t    teid,
-                    NW_IN uint8_t     seqNumFlag,
-                    NW_IN uint16_t    seqNum,
-                    NW_IN uint8_t*    tpdu,
-                    NW_IN uint16_t    tpduLength,
-                    NW_IN uint32_t    tpduOffset,
-                    NW_OUT NwGtpv1uMsgHandleT *phMsg);
-
-/**
- * Allocate a gtpv1u message from another gtpv1u message.
- *
- * @param[in] hGtpuStackHandle : gtpv1u stack handle.
- * @param[out] hMsg : Handle to input message.
- * @param[out] phMsg : Pointer to message handle.
- */
-
-NwGtpv1uRcT
-nwGtpv1uMsgFromMsgNew( NW_IN NwGtpv1uStackHandleT hGtpuStackHandle,
-                       NW_IN NwGtpv1uMsgHandleT hMsg,
-                       NW_OUT NwGtpv1uMsgHandleT *phMsg);
-/**
- * Allocate a gtpv1u message from data buffer.
- *
- * @param[in] hGtpuStackHandle : gtpv1u stack handle.
- * @param[in] pBuf: Buffer to be copied in this message.
- * @param[in] bufLen: Buffer length to be copied in this message.
- * @param[out] phMsg : Pointer to message handle.
- */
-
-NwGtpv1uRcT
-nwGtpv1uMsgFromBufferNew( NW_IN NwGtpv1uStackHandleT hGtpuStackHandle,
-                          NW_IN uint8_t* pBuf,
-                          NW_IN uint32_t bufLen,
-                          NW_OUT NwGtpv1uMsgHandleT *phMsg);
-
-/**
- * Free a gtpv1u message.
- *
- * @param[in] hGtpuStackHandle : gtpv1u stack handle.
- * @param[in] hMsg : Message handle.
- */
-
-NwGtpv1uRcT
-nwGtpv1uMsgDelete( NW_IN NwGtpv1uStackHandleT hGtpuStackHandle,
-                   NW_IN NwGtpv1uMsgHandleT hMsg);
-
-/**
- * Set TEID for gtpv1u message.
- *
- * @param[in] hMsg : Message handle.
- * @param[in] teid: TEID value.
- */
-
-NwGtpv1uRcT
-nwGtpv1uMsgSetTeid(NW_IN NwGtpv1uMsgHandleT hMsg, uint32_t teid);
-
-/**
- * Set TEID present flag for gtpv1u message.
- *
- * @param[in] hMsg : Message handle.
- * @param[in] teidPesent: Flag boolean value.
- */
-
-NwGtpv1uRcT
-nwGtpv1uMsgSetTeidPresent(NW_IN NwGtpv1uMsgHandleT hMsg, NwBoolT teidPresent);
-
-/**
- * Set sequence for gtpv1u message.
- *
- * @param[in] hMsg : Message handle.
- * @param[in] seqNum: Flag boolean value.
- */
-
-NwGtpv1uRcT
-nwGtpv1uMsgSetSeqNumber(NW_IN NwGtpv1uMsgHandleT hMsg, uint32_t seqNum);
-
-/**
- * Get TEID present for gtpv1u message.
- *
- * @param[in] hMsg : Message handle.
- */
-
-uint32_t
-nwGtpv1uMsgGetTeid(NW_IN NwGtpv1uMsgHandleT hMsg);
-
-/**
- * Get TEID present for gtpv1u message.
- *
- * @param[in] hMsg : Message handle.
- */
-
-NwBoolT
-nwGtpv1uMsgGetTeidPresent(NW_IN NwGtpv1uMsgHandleT hMsg);
-
-/**
- * Get sequence number for gtpv1u message.
- *
- * @param[in] hMsg : Message handle.
- */
-
-uint32_t
-nwGtpv1uMsgGetSeqNumber(NW_IN NwGtpv1uMsgHandleT hMsg);
-
-/**
- * Get tpdu for gtpv1u message.
- *
- * @param[in] hMsg : Message handle.
- * @param[inout] pTpduBuf : Buffer to copy the T-PDU.
- * @param[out] hMsg : T-PDU length.
- */
-
-uint32_t
-nwGtpv1uMsgGetTpdu(NW_IN NwGtpv1uMsgHandleT hMsg, uint8_t* pTpduBuf, uint32_t* pTpduLength);
-
-uint8_t*
-nwGtpv1uMsgGetTpduHandle(NW_IN NwGtpv1uMsgHandleT hMsg);
-
-uint32_t
-nwGtpv1uMsgGetTpduLength(NW_IN NwGtpv1uMsgHandleT hMsg);
-
-/**
- * Add a gtpv1u information element of length 1 to gtpv1u mesasge.
- *
- * @param[in] hMsg : Handle to gtpv1u message.
- * @param[in] type : IE type.
- * @param[in] value : IE value.
- */
-
-NwGtpv1uRcT
-nwGtpv1uMsgAddIeTV1(NW_IN NwGtpv1uMsgHandleT hMsg,
-                    NW_IN uint8_t       type,
-                    NW_IN uint8_t       value);
-
-
-/**
- * Add a gtpv1u information element of length 2 to gtpv1u mesasge.
- *
- * @param[in] hMsg : Handle to gtpv1u message.
- * @param[in] type : IE type.
- * @param[in] value : IE value.
- */
-
-NwGtpv1uRcT
-nwGtpv1uMsgAddIeTV2(NW_IN NwGtpv1uMsgHandleT hMsg,
-                    NW_IN uint8_t       type,
-                    NW_IN uint16_t      length,
-                    NW_IN uint16_t      value);
-
-
-/**
- * Add a gtpv1u information element of length 4 to gtpv1u mesasge.
- *
- * @param[in] hMsg : Handle to gtpv1u message.
- * @param[in] type : IE type.
- * @param[in] value : IE value.
- */
-
-NwGtpv1uRcT
-nwGtpv1uMsgAddIeTV4(NW_IN NwGtpv1uMsgHandleT hMsg,
-                    NW_IN uint8_t       type,
-                    NW_IN uint16_t      length,
-                    NW_IN uint32_t      value);
-
-
-/**
- * Add a gtpv1u information element of variable length to gtpv1u mesasge.
- *
- * @param[in] hMsg : Handle to gtpv1u message.
- * @param[in] type : IE type.
- * @param[in] length : IE length.
- * @param[in] value : IE value.
- */
-
-NwGtpv1uRcT
-nwGtpv1uMsgAddIe(NW_IN NwGtpv1uMsgHandleT hMsg,
-                 NW_IN uint8_t       type,
-                 NW_IN uint16_t      length,
-                 NW_IN uint8_t*      pVal);
-
-/**
- * Dump the contents of gtpv1u mesasge.
- *
- * @param[in] hMsg : Handle to gtpv1u message.
- * @param[in] fp: Pointer to output file.
- */
-
-NwGtpv1uRcT
-nwGtpv1uMsgHexDump(NwGtpv1uMsgHandleT hMsg, FILE* fp);
-
-uint32_t
-nwGtpv1uMsgGetMsgType(NW_IN NwGtpv1uMsgHandleT hMsg);
-
-#ifdef __cplusplus
-}
-#endif
-
-#endif /* __NW_TYPES_H__ */
-
-
-/*--------------------------------------------------------------------------*
- *                      E N D     O F    F I L E                            *
- *--------------------------------------------------------------------------*/
-
diff --git a/openair3/GTPV1-U/nw-gtpv1u/shared/NwLog.h b/openair3/GTPV1-U/nw-gtpv1u/shared/NwLog.h
deleted file mode 100644
index 7215216e68a..00000000000
--- a/openair3/GTPV1-U/nw-gtpv1u/shared/NwLog.h
+++ /dev/null
@@ -1,88 +0,0 @@
-/*----------------------------------------------------------------------------*
- *                                                                            *
- *                              n w - g t p v 2 c                             *
- *    G P R S   T u n n e l i n g    P r o t o c o l   v 2 c    S t a c k     *
- *                                                                            *
- *                                                                            *
- * Copyright (c) 2010-2011 Amit Chawre                                        *
- * All rights reserved.                                                       *
- *                                                                            *
- * Redistribution and use in source and binary forms, with or without         *
- * modification, are permitted provided that the following conditions         *
- * are met:                                                                   *
- *                                                                            *
- * 1. Redistributions of source code must retain the above copyright          *
- *    notice, this list of conditions and the following disclaimer.           *
- * 2. Redistributions in binary form must reproduce the above copyright       *
- *    notice, this list of conditions and the following disclaimer in the     *
- *    documentation and/or other materials provided with the distribution.    *
- * 3. The name of the author may not be used to endorse or promote products   *
- *    derived from this software without specific prior written permission.   *
- *                                                                            *
- * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR       *
- * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES  *
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.    *
- * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,           *
- * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT   *
- * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,  *
- * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY      *
- * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT        *
- * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF   *
- * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.          *
- *----------------------------------------------------------------------------*/
-
-
-#ifndef __NW_LOG_H__
-#define __NW_LOG_H__
-
-#include <libgen.h>
-
-#include "NwTypes.h"
-
-/**
- * @file NwLog.h
- * @brief This header file contains global shared logging definitions.
-*/
-
-#ifdef __cplusplus
-extern "C" {
-#endif
-
-/*---------------------------------------------------------------------------
- * Log Level Definitions
- *--------------------------------------------------------------------------*/
-
-#define NW_LOG_LEVEL_EMER                       (0) /**< system is unusable              */
-#define NW_LOG_LEVEL_ALER                       (1) /**< action must be taken immediately*/
-#define NW_LOG_LEVEL_CRIT                       (2) /**< critical conditions             */
-#define NW_LOG_LEVEL_ERRO                       (3) /**< error conditions                */
-#define NW_LOG_LEVEL_WARN                       (4) /**< warning conditions              */
-#define NW_LOG_LEVEL_NOTI                       (5) /**< normal but signification condition */
-#define NW_LOG_LEVEL_INFO                       (6) /**< informational                   */
-#define NW_LOG_LEVEL_DEBG                       (7) /**< debug-level messages            */
-
-// static
-// NwCharT* gLogLevelStr[] = {"EMER", "ALER", "CRIT",  "ERRO", "WARN", "NOTI", "INFO", "DEBG"};
-
-/*---------------------------------------------------------------------------
- * IPv4 logging macros
- *--------------------------------------------------------------------------*/
-#define NW_IPV4_ADDR                            "%u.%u.%u.%u"
-#define NW_IPV4_ADDR_FORMAT(__addr)             (uint8_t)((__addr) & 0x000000ff),        \
-                                                (uint8_t)(((__addr) & 0x0000ff00) >> 8 ), \
-                                                (uint8_t)(((__addr) & 0x00ff0000) >> 16), \
-                                                (uint8_t)(((__addr) & 0xff000000) >> 24)
-
-#define NW_IPV4_ADDR_FORMATP(__paddr)           (uint8_t)(*((uint8_t*)(__paddr)) & 0x000000ff),     \
-                                                (uint8_t)(*((uint8_t*)(__paddr + 1)) & 0x000000ff), \
-                                                (uint8_t)(*((uint8_t*)(__paddr + 2)) & 0x000000ff), \
-                                                (uint8_t)(*((uint8_t*)(__paddr + 3)) & 0x000000ff)
-
-
-#ifdef __cplusplus
-}
-#endif
-
-#endif /* __NW_LOG_H__ */
-
-
diff --git a/openair3/GTPV1-U/nw-gtpv1u/shared/NwTypes.h b/openair3/GTPV1-U/nw-gtpv1u/shared/NwTypes.h
deleted file mode 100644
index aae5c8a95bf..00000000000
--- a/openair3/GTPV1-U/nw-gtpv1u/shared/NwTypes.h
+++ /dev/null
@@ -1,78 +0,0 @@
-/*----------------------------------------------------------------------------*
- *                                                                            *
- *                              n w - g t p v 2 c                             *
- *    G P R S   T u n n e l i n g    P r o t o c o l   v 2 c    S t a c k     *
- *                                                                            *
- *                                                                            *
- * Copyright (c) 2010-2011 Amit Chawre                                        *
- * All rights reserved.                                                       *
- *                                                                            *
- * Redistribution and use in source and binary forms, with or without         *
- * modification, are permitted provided that the following conditions         *
- * are met:                                                                   *
- *                                                                            *
- * 1. Redistributions of source code must retain the above copyright          *
- *    notice, this list of conditions and the following disclaimer.           *
- * 2. Redistributions in binary form must reproduce the above copyright       *
- *    notice, this list of conditions and the following disclaimer in the     *
- *    documentation and/or other materials provided with the distribution.    *
- * 3. The name of the author may not be used to endorse or promote products   *
- *    derived from this software without specific prior written permission.   *
- *                                                                            *
- * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR       *
- * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES  *
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.    *
- * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,           *
- * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT   *
- * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,  *
- * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY      *
- * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT        *
- * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF   *
- * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.          *
- *----------------------------------------------------------------------------*/
-
-
-#include <stdlib.h>
-#include <stdint.h>
-
-#ifndef __NW_TYPES_H__
-#define __NW_TYPES_H__
-
-/**
- * @file NwTypes.h
- * @brief This header file contains basic type definitions.
-*/
-
-#ifdef __cplusplus
-extern "C" {
-#endif
-
-#define NW_IN                                   /**< An input argument                  */
-#define NW_OUT                                  /**< An output argumnet                 */
-#define NW_INOUT                                /**< An input and output argument       */
-
-#define NW_TRUE                 (1)             /**< Truth value                        */
-#define NW_FALSE                (0)             /**< False value                        */
-
-typedef signed char             NwS8T;          /**< Signed 1 byte                      */
-typedef signed short            NwS16T;         /**< Signed 2 byte                      */
-typedef signed int              NwS32T;         /**< Signed 4 byte                      */
-typedef signed long long        NwS64T;         /**< Signed 8 byte                      */
-
-typedef uintptr_t               NwPtrT;         /**< Use this for generic pointers      */
-typedef unsigned int            NwHandleT;      /**< Use this for generic handles       */
-
-typedef char                    NwBoolT;        /**< Use this for booleans              */
-
-typedef char                    NwCharT;        /**< Use this for strings               */
-
-typedef signed int              NwFdT;          /**< Use this for file descriptor               */
-
-
-#ifdef __cplusplus
-}
-#endif
-
-#endif /* __NW_TYPES_H__ */
-
-
diff --git a/openair3/GTPV1-U/nw-gtpv1u/shared/NwUtils.h b/openair3/GTPV1-U/nw-gtpv1u/shared/NwUtils.h
deleted file mode 100644
index c197ab323e9..00000000000
--- a/openair3/GTPV1-U/nw-gtpv1u/shared/NwUtils.h
+++ /dev/null
@@ -1,68 +0,0 @@
-/*----------------------------------------------------------------------------*
- *                                                                            *
- *                              n w - g t p v 2 c                             *
- *    G P R S   T u n n e l i n g    P r o t o c o l   v 2 c    S t a c k     *
- *                                                                            *
- *                                                                            *
- * Copyright (c) 2010-2011 Amit Chawre                                        *
- * All rights reserved.                                                       *
- *                                                                            *
- * Redistribution and use in source and binary forms, with or without         *
- * modification, are permitted provided that the following conditions         *
- * are met:                                                                   *
- *                                                                            *
- * 1. Redistributions of source code must retain the above copyright          *
- *    notice, this list of conditions and the following disclaimer.           *
- * 2. Redistributions in binary form must reproduce the above copyright       *
- *    notice, this list of conditions and the following disclaimer in the     *
- *    documentation and/or other materials provided with the distribution.    *
- * 3. The name of the author may not be used to endorse or promote products   *
- *    derived from this software without specific prior written permission.   *
- *                                                                            *
- * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR       *
- * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES  *
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.    *
- * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,           *
- * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT   *
- * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,  *
- * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY      *
- * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT        *
- * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF   *
- * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.          *
- *----------------------------------------------------------------------------*/
-
-#include <assert.h>
-
-#ifndef __NW_UTILS_H__
-#define __NW_UTILS_H__
-
-
-/**
- * @file NwUtils.h
- * @brief This header file contains utility macro and function definitions.
-*/
-
-#define NW_ASSERT                                       assert                  /**< Assertion */
-
-#define NW_CHK_NULL_PTR(_ptr)                           NW_ASSERT(_ptr != NULL) /**< Null pointer check */
-
-#define NW_HTONS(x)                                     ( ( ((x) & 0xff00) >> 8 ) | ( ((x) & 0x00ff) << 8 ) )
-
-#define NW_HTONL(x)                                     ( ( ((x) & 0xff000000) >> 24 ) | ( ( (x) & 0x00ff0000 ) >> 8 ) | \
-                                                        ( ( (x) & 0x0000ff00 ) << 8 ) | ( ( (x) & 0x000000ff) << 24 ) )
-
-#define NW_HTONLL(x)                                    (                                                         \
-    ( ( ((uint64_t)x) & 0xff00000000000000ULL ) >> 56 ) | ( ( ((uint64_t)x) & 0x00ff000000000000ULL ) >> 40 ) |       \
-    ( ( ((uint64_t)x) & 0x0000ff0000000000ULL ) >> 24 ) | ( ( ((uint64_t)x) & 0x000000ff00000000ULL ) >> 8  ) |       \
-    ( ( ((uint64_t)x) & 0x000000000000ff00ULL ) << 40 ) | ( ( ((uint64_t)x) & 0x00000000000000ffULL ) << 56 ) |       \
-    ( ( ((uint64_t)x) & 0x0000000000ff0000ULL ) << 24 ) | ( ( ((uint64_t)x) & 0x00000000ff000000ULL ) << 8  )         \
-    )
-
-#define NW_NTOHS                NW_HTONS
-#define NW_NTOHL                NW_HTONL
-#define NW_NTOHLL               NW_HTONLL
-
-
-#endif /* __NW_UTILS_H__ */
-
-
diff --git a/openair3/GTPV1-U/nw-gtpv1u/src/NwGtpv1u.c b/openair3/GTPV1-U/nw-gtpv1u/src/NwGtpv1u.c
deleted file mode 100644
index 0d962cad7d5..00000000000
--- a/openair3/GTPV1-U/nw-gtpv1u/src/NwGtpv1u.c
+++ /dev/null
@@ -1,1025 +0,0 @@
-/*----------------------------------------------------------------------------*
- *                                                                            *
- *                             n w - g t p v 2 u                              *
- *    G P R S    T u n n e l i n g    P r o t o c o l   v 2 u   S t a c k     *
- *                                                                            *
- *                                                                            *
- * Copyright (c) 2010-2011 Amit Chawre                                        *
- * All rights reserved.                                                       *
- *                                                                            *
- * Redistribution and use in source and binary forms, with or without         *
- * modification, are permitted provided that the following conditions         *
- * are met:                                                                   *
- *                                                                            *
- * 1. Redistributions of source code must retain the above copyright          *
- *    notice, this list of conditions and the following disclaimer.           *
- * 2. Redistributions in binary form must reproduce the above copyright       *
- *    notice, this list of conditions and the following disclaimer in the     *
- *    documentation and/or other materials provided with the distribution.    *
- * 3. The name of the author may not be used to endorse or promote products   *
- *    derived from this software without specific prior written permission.   *
- *                                                                            *
- * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR       *
- * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES  *
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.    *
- * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,           *
- * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT   *
- * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,  *
- * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY      *
- * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT        *
- * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF   *
- * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.          *
- *----------------------------------------------------------------------------*/
-
-#include <stdio.h>
-#include <stdlib.h>
-#include <string.h>
-
-#include "NwTypes.h"
-#include "NwUtils.h"
-#include "NwGtpv1uError.h"
-#include "NwGtpv1uPrivate.h"
-#include "NwGtpv1uTunnelEndPoint.h"
-#include "NwGtpv1uTrxn.h"
-#include "NwGtpv1u.h"
-#include "NwGtpv1uIe.h"
-#include "NwGtpv1uLog.h"
-
-#include "assertions.h"
-#include "intertask_interface.h"
-#include "msc.h"
-
-#include "gtpv1u.h"
-#if defined(ENB_MODE)
-#include "common/utils/LOG/log.h"
-#include "common/utils/LOG/vcd_signal_dumper.h"
-#endif
-
-#ifdef __cplusplus
-extern "C" {
-#endif
-
-//#define LOG_GTPU 1
-/*--------------------------------------------------------------------------*
- *                    P R I V A T E    F U N C T I O N S                    *
- *--------------------------------------------------------------------------*/
-
-#define NW_GTPV1U_EPC_SPECIFIC_HEADER_SIZE                             (12)   /**< Size of GTPv1u EPC specific header */
-#define NW_GTPV1U_EPC_MIN_HEADER_SIZE                                  (8)
-
-
-void
-nwGtpv1uDisplayBanner(void)
-{
-  printf(" *----------------------------------------------------------------------------*\n");
-  printf(" *                                                                            *\n");
-  printf(" *                             n w - g t p v 2 u                              *\n");
-  printf(" *    G P R S    T u n n e l i n g    P r o t o c o l   v 2 u   S t a c k     *\n");
-  printf(" *                                                                            *\n");
-  printf(" *                                                                            *\n");
-  printf(" * Copyright (c) 2010-2011 Amit Chawre                                        *\n");
-  printf(" * All rights reserved.                                                       *\n");
-  printf(" *                                                                            *\n");
-  printf(" * Redistribution and use in source and binary forms, with or without         *\n");
-  printf(" * modification, are permitted provided that the following conditions         *\n");
-  printf(" * are met:                                                                   *\n");
-  printf(" *                                                                            *\n");
-  printf(" * 1. Redistributions of source code must retain the above copyright          *\n");
-  printf(" *    notice, this list of conditions and the following disclaimer.           *\n");
-  printf(" * 2. Redistributions in binary form must reproduce the above copyright       *\n");
-  printf(" *    notice, this list of conditions and the following disclaimer in the     *\n");
-  printf(" *    documentation and/or other materials provided with the distribution.    *\n");
-  printf(" * 3. The name of the author may not be used to endorse or promote products   *\n");
-  printf(" *    derived from this software without specific prior written permission.   *\n");
-  printf(" *                                                                            *\n");
-  printf(" * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR       *\n");
-  printf(" * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES  *\n");
-  printf(" * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.    *\n");
-  printf(" * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,           *\n");
-  printf(" * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT   *\n");
-  printf(" * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,  *\n");
-  printf(" * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY      *\n");
-  printf(" * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT        *\n");
-  printf(" * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF   *\n");
-  printf(" * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.          *\n");
-  printf(" *----------------------------------------------------------------------------*\n\n");
-
-}
-/*---------------------------------------------------------------------------
- * RBTree Search Functions
- *--------------------------------------------------------------------------*/
-
-static inline NwS32T
-nwGtpv1uCompareTeid(struct NwGtpv1uTunnelEndPoint *a,
-                    struct NwGtpv1uTunnelEndPoint *b);
-
-static inline NwS32T
-nwGtpv1uCompareSeqNum(struct NwGtpv1uTrxn *a, struct NwGtpv1uTrxn *b);
-
-RB_PROTOTYPE(NwGtpv1uOutstandingTxSeqNumTrxnMap, NwGtpv1uTrxn,
-             outstandingTxSeqNumMapRbtNode, nwGtpv1uCompareSeqNum)
-RB_PROTOTYPE(NwGtpv1uOutstandingRxSeqNumTrxnMap, NwGtpv1uTrxn,
-             outstandingRxSeqNumMapRbtNode, nwGtpv1uCompareSeqNum)
-RB_PROTOTYPE(NwGtpv1uTunnelEndPointTMap, NwGtpv1uTunnelEndPoint,
-             sessionMapRbtNode, nwGtpv1uCompareTeid)
-RB_PROTOTYPE(NwGtpv1uTunnelEndPointIdentifierMap, NwGtpv1uTunnelEndPoint,
-             sessionMapRbtNode, nwGtpv1uCompareTeid)
-
-RB_GENERATE(NwGtpv1uOutstandingTxSeqNumTrxnMap, NwGtpv1uTrxn,
-            outstandingTxSeqNumMapRbtNode, nwGtpv1uCompareSeqNum)
-RB_GENERATE(NwGtpv1uOutstandingRxSeqNumTrxnMap, NwGtpv1uTrxn,
-            outstandingRxSeqNumMapRbtNode, nwGtpv1uCompareSeqNum)
-RB_GENERATE(NwGtpv1uTunnelEndPointTMap, NwGtpv1uTunnelEndPoint,
-            sessionMapRbtNode, nwGtpv1uCompareTeid)
-RB_GENERATE(NwGtpv1uTunnelEndPointIdentifierMap, NwGtpv1uTunnelEndPoint,
-            sessionMapRbtNode, nwGtpv1uCompareTeid)
-
-/**
-  Comparator funtion for comparing two sessions.
-
-  @param[in] a: Pointer to session a.
-  @param[in] b: Pointer to session b.
-  @return  An integer greater than, equal to or less than zero according to whether the
-  object pointed to by a is greater than, equal to or less than the object pointed to by b.
- */
-
-static inline NwS32T
-nwGtpv1uCompareTeid(struct NwGtpv1uTunnelEndPoint *a,
-                    struct NwGtpv1uTunnelEndPoint *b)
-{
-  if(a->teid > b->teid) {
-    return 1;
-  }
-
-  if(a->teid < b->teid) {
-    return -1;
-  }
-
-  return 0;
-}
-
-/**
-  Comparator funtion for comparing two sequence number transactions.
-
-  @param[in] a: Pointer to session a.
-  @param[in] b: Pointer to session b.
-  @return  An integer greater than, equal to or less than zero according to whether the
-  object pointed to by a is greater than, equal to or less than the object pointed to by b.
- */
-
-static inline NwS32T
-nwGtpv1uCompareSeqNum(struct NwGtpv1uTrxn *a, struct NwGtpv1uTrxn *b)
-{
-  if(a->seqNum > b->seqNum) {
-    return 1;
-  }
-
-  if(a->seqNum < b->seqNum) {
-    return -1;
-  }
-
-  if(a->peerIp > b->peerIp) {
-    return 1;
-  }
-
-  if(a->peerIp < b->peerIp) {
-    return -1;
-  }
-
-  return 0;
-}
-
-/**
-  Create and Send GTPU message.
-
-  @param[in] thiz: Stack handle
-  @return NW_GTPV1U_OK on success.
- */
-
-static NwGtpv1uRcT
-nwGtpv1uCreateAndSendMsg( NwGtpv1uStackT *thiz, uint32_t peerIp, uint16_t peerPort,
-                          NwGtpv1uMsgT *pMsg)
-{
-  NwGtpv1uRcT rc = NW_GTPV1U_FAILURE;
-  uint8_t *msgHdr;
-
-  NW_ASSERT(thiz);
-  NW_ASSERT(pMsg);
-
-#if defined(LOG_GTPU) && LOG_GTPU > 0
-  NW_ENTER(thiz);
-#endif
-
-  msgHdr = &pMsg->msgBuf[pMsg->msgBufOffset];
-  NW_ASSERT(msgHdr != NULL);
-
-  *(msgHdr++)         = (pMsg->version << 5)            |
-                        (pMsg->protocolType << 4)       |
-                        (pMsg->extHdrFlag << 2)         |
-                        (pMsg->seqNumFlag << 1)         |
-                        (pMsg->npduNumFlag);
-
-  *(msgHdr++)         = (pMsg->msgType);
-  *((uint16_t *) msgHdr) = htons(pMsg->msgLen);
-  msgHdr += 2;
-
-  *((uint32_t *) msgHdr) = htonl(pMsg->teid);
-  msgHdr += 4;
-#if defined(LOG_GTPU) && LOG_GTPU > 0
-  GTPU_DEBUG("nwGtpv1uCreateAndSendMsg to teid %u length %d offset %d\n",
-             pMsg->teid,
-             pMsg->msgLen,
-             pMsg->msgBufOffset);
-#endif
-
-  if(pMsg->seqNumFlag || pMsg->extHdrFlag || pMsg->npduNumFlag) {
-    *((uint16_t *) msgHdr) = (pMsg->seqNumFlag ? htons(pMsg->seqNum) : 0x0000);
-    msgHdr += 2;
-
-    *((uint8_t *) msgHdr) = (pMsg->npduNumFlag ? htons(pMsg->npduNum) : 0x00);
-    msgHdr++;
-
-    *((uint8_t *) msgHdr) = (pMsg->extHdrFlag ? htons(pMsg->nextExtHdrType) : 0x00);
-    msgHdr++;
-  }
-
-  rc = thiz->udp.udpDataReqCallback(thiz->udp.hUdp,
-                                    pMsg->msgBuf,
-                                    pMsg->msgBufLen,
-                                    pMsg->msgBufOffset,
-                                    peerIp,
-                                    peerPort);
-
-#if defined(LOG_GTPU) && LOG_GTPU > 0
-  NW_LEAVE(thiz);
-#endif
-  return rc;
-}
-
-/**
- * Send GTPv1u Message Indication to ULP entity.
- *
- * @param[in] hGtpuStackHandle : Stack handle
- * @return NW_GTPV1U_OK on success.
- */
-
-static NwGtpv1uRcT
-nwGtpv1uSendUlpMessageIndication( NW_IN NwGtpv1uStackT *thiz,
-                                  NW_IN uint32_t  hUlpTrxn,
-                                  NW_IN uint32_t  apiType,
-                                  NW_IN uint32_t  msgType,
-                                  NW_IN uint32_t  peerIp,
-                                  NW_IN uint16_t  peerPort,
-                                  NW_IN uint8_t  *pMsgBuf,
-                                  NW_IN uint16_t  msgLength)
-{
-  NwGtpv1uRcT rc = NW_GTPV1U_FAILURE;
-  NwGtpv1uUlpApiT ulpApi;
-
-#if defined(LOG_GTPU) && LOG_GTPU > 0
-  NW_ENTER(thiz);
-#endif
-
-  ulpApi.apiType                        = apiType;
-  ulpApi.apiInfo.recvMsgInfo.msgType    = msgType;
-  ulpApi.apiInfo.recvMsgInfo.hUlpTrxn   = hUlpTrxn;
-  ulpApi.apiInfo.recvMsgInfo.peerIp     = peerIp;
-  ulpApi.apiInfo.recvMsgInfo.peerPort   = peerPort;
-
-  if(pMsgBuf && msgLength) {
-    rc = nwGtpv1uMsgFromBufferNew((NwGtpv1uStackHandleT)thiz, pMsgBuf, msgLength,
-                                  &(ulpApi.apiInfo.recvMsgInfo.hMsg));
-    NW_ASSERT(rc == NW_GTPV1U_OK);
-  }
-
-  rc = thiz->ulp.ulpReqCallback(thiz->ulp.hUlp, &ulpApi);
-  NW_ASSERT(rc == NW_GTPV1U_OK);
-
-#if defined(LOG_GTPU) && LOG_GTPU > 0
-  NW_LEAVE(thiz);
-#endif
-
-  return rc;
-}
-
-NwGtpv1uRcT
-nwGtpv1uPeerRspTimeout(void *arg)
-{
-  NwGtpv1uRcT rc = NW_GTPV1U_OK;
-  NwGtpv1uTrxnT *thiz;
-  NwGtpv1uTimeoutInfoT *timeoutInfo = arg;
-
-  GTPU_WARNING( "Retransmission timer expired\n");
-
-  thiz = ((NwGtpv1uTrxnT *)timeoutInfo->timeoutArg);
-  rc = thiz->pStack->udp.udpDataReqCallback(thiz->pStack->udp.hUdp,
-       thiz->pMsg->msgBuf,
-       thiz->pMsg->msgLen,
-       thiz->pMsg->msgBufOffset,
-       thiz->peerIp,
-       thiz->peerPort);
-
-  if(thiz->maxRetries) {
-    rc = thiz->pStack->tmrMgr.tmrStartCallback(thiz->pStack->tmrMgr.tmrMgrHandle,
-         5, 0, NW_GTPV1U_TMR_TYPE_ONE_SHOT, (void *)timeoutInfo, &thiz->hRspTmr);
-    thiz->maxRetries--;
-  } else {
-    /* Inform session layer about path fialure */
-    GTPU_WARNING("Max retries over!\n");
-  }
-
-  return rc;
-}
-
-/*---------------------------------------------------------------------------
- * ULP API Processing Functions
- *--------------------------------------------------------------------------*/
-
-/**
-  Process NW_GTPV1U_ULP_API_CREATE_TUNNEL_ENDPOINT Request from ULP entity.
-
-  @param[in] hGtpuStackHandle : Stack handle
-  @param[in] pUlpReq : Pointer to Ulp Req.
-  @return NW_GTPV1U_OK on success.
- */
-
-static NwGtpv1uRcT
-NwGtpv1uCreateTunnelEndPoint( NW_IN  NwGtpv1uStackT *thiz,
-                              NW_IN  uint32_t teid,
-                              NW_IN  NwGtpv1uUlpSessionHandleT hUlpSession,
-                              NW_OUT NwGtpv1uStackSessionHandleT *phStackSession )
-{
-  NwGtpv1uRcT rc = NW_GTPV1U_OK;
-  NwGtpv1uTunnelEndPointT *pTunnelEndPoint;
-  NwGtpv1uTunnelEndPointT *pCollision;
-
-#if defined(LOG_GTPU) && LOG_GTPU > 0
-  NW_ENTER(thiz);
-#endif
-  pTunnelEndPoint = nwGtpTunnelEndPointNew(thiz);
-
-  if(pTunnelEndPoint) {
-
-    pTunnelEndPoint->teid           = teid;
-    pTunnelEndPoint->pStack         = thiz;
-    pTunnelEndPoint->hUlpSession    = hUlpSession;
-
-    pCollision = RB_INSERT(NwGtpv1uTunnelEndPointIdentifierMap, &(thiz->teidMap),
-                           pTunnelEndPoint);
-
-    if(pCollision) {
-      GTPU_ERROR("Tunnel end-point cannot be created for teid 0x%x. "
-                 "Tunnel already exists", teid);
-      rc = nwGtpTunnelEndPointDestroy(thiz, pTunnelEndPoint);
-      NW_ASSERT(rc == NW_GTPV1U_OK);
-      *phStackSession = (NwGtpv1uStackSessionHandleT) NULL;
-      NW_ASSERT(0);
-      rc = NW_GTPV1U_FAILURE;
-    } else {
-      *phStackSession = (NwGtpv1uStackSessionHandleT) pTunnelEndPoint;
-      pTunnelEndPoint = RB_FIND(NwGtpv1uTunnelEndPointIdentifierMap,
-                                &(thiz->teidMap), pTunnelEndPoint);
-      //NW_ASSERT(pTunnelEndPoint);
-      if (!pTunnelEndPoint) {
-        GTPU_ERROR("Tunnel end-point cannot be NULL");
-        rc = NW_GTPV1U_FAILURE;
-      } else {
-        GTPU_DEBUG("Tunnel end-point 0x%p creation successful for teid 0x%x %u(dec)",
-                   pTunnelEndPoint, (unsigned int)teid, (unsigned int)teid);
-      }
-    }
-
-  } else {
-    *phStackSession = (NwGtpv1uStackSessionHandleT) NULL;
-    rc = NW_GTPV1U_FAILURE;
-  }
-
-#if defined(LOG_GTPU) && LOG_GTPU > 0
-  NW_LEAVE(thiz);
-#endif
-  return rc;
-}
-
-/**
-  Process NW_GTPV1U_ULP_API_DESTROY_TUNNEL_ENDPOINT Request from ULP entity.
-
-  @param[in] hGtpuStackHandle : Stack handle
-  @param[in] pUlpReq : Pointer to Ulp Req.
-  @return NW_GTPV1U_OK on success.
- */
-
-static NwGtpv1uRcT
-nwGtpv1uDestroyTunnelEndPoint( NwGtpv1uStackT *thiz,
-                               NW_IN NwGtpv1uUlpApiT *pUlpReq)
-{
-  NwGtpv1uRcT rc = NW_GTPV1U_OK;
-  NwGtpv1uTunnelEndPointT *pRemovedTeid;
-
-  if(pUlpReq->apiInfo.destroyTunnelEndPointInfo.hStackSessionHandle) {
-    GTPU_DEBUG(  "Destroying Tunnel end-point '%lx'",
-                 pUlpReq->apiInfo.destroyTunnelEndPointInfo.hStackSessionHandle);
-    pRemovedTeid = RB_REMOVE(NwGtpv1uTunnelEndPointIdentifierMap, &(thiz->teidMap),
-                             (NwGtpv1uTunnelEndPointT *)(
-                               pUlpReq->apiInfo.destroyTunnelEndPointInfo.hStackSessionHandle));
-
-    NW_ASSERT(pRemovedTeid == (NwGtpv1uTunnelEndPointT *)(
-                pUlpReq->apiInfo.destroyTunnelEndPointInfo.hStackSessionHandle));
-
-    rc = nwGtpTunnelEndPointDestroy(thiz,
-                                    (NwGtpv1uTunnelEndPointT *)
-                                    pUlpReq->apiInfo.destroyTunnelEndPointInfo.hStackSessionHandle);
-  } else {
-    GTPU_WARNING("Non-existent Tunnel end-point handle '%lx'",
-                 pUlpReq->apiInfo.destroyTunnelEndPointInfo.hStackSessionHandle);
-  }
-
-  return rc;
-}
-
-/**
-  Process NW_GTPV1U_ULP_API_INITIAL_REQ Request from ULP entity.
-
-  @param[in] hGtpuStackHandle : Stack handle
-  @param[in] pUlpReq : Pointer to Ulp Req.
-  @return NW_GTPV1U_OK on success.
- */
-
-static NwGtpv1uRcT
-nwGtpv1uInitialReq( NW_IN NwGtpv1uStackT *thiz, NW_IN NwGtpv1uUlpApiT *pUlpReq)
-{
-  NwGtpv1uRcT rc = NW_GTPV1U_FAILURE;
-  NwGtpv1uTrxnT *pTrxn;
-
-#if defined(LOG_GTPU) && LOG_GTPU > 0
-  NW_ENTER(thiz);
-#endif
-  /* Create New Transaction */
-  rc = nwGtpv1uTrxnNew(thiz, &pTrxn);
-
-  if(pTrxn) {
-    rc = nwGtpv1uTrxnCreateAndSendMsg(thiz,
-                                      pTrxn,
-                                      pUlpReq->apiInfo.initialReqInfo.peerIp,
-                                      pUlpReq->apiInfo.initialReqInfo.peerPort,
-                                      (NwGtpv1uMsgT *) pUlpReq->hMsg);
-
-    if(rc == NW_GTPV1U_OK) {
-      /* Insert into search tree */
-      RB_INSERT(NwGtpv1uOutstandingTxSeqNumTrxnMap, &(thiz->outstandingTxSeqNumMap),
-                pTrxn);
-    } else {
-      rc = nwGtpv1uTrxnDelete(&pTrxn);
-      NW_ASSERT(rc == NW_GTPV1U_OK);
-    }
-  }
-
-#if defined(LOG_GTPU) && LOG_GTPU > 0
-  NW_LEAVE(thiz);
-#endif
-  return rc;
-}
-
-/**
-  Process NW_GTPV1U_ULP_API_SEND_TPDU Request from ULP entity.
-
-  @param[in] thiz: Stack handle
-  @param[in] pUlpReq : Pointer to Ulp Req.
-  @return NW_GTPV1U_OK on success.
- */
-
-static NwGtpv1uRcT
-nwGtpv1uSendto( NwGtpv1uStackT *thiz,  NW_IN NwGtpv1uUlpApiT *pUlpReq)
-{
-  NwGtpv1uRcT rc = NW_GTPV1U_FAILURE;
-
-  NW_ASSERT(thiz);
-#if defined(LOG_GTPU) && LOG_GTPU > 0
-  NW_ENTER(thiz);
-#endif
-
-  (void) nwGtpv1uMsgSetTeid(pUlpReq->apiInfo.sendtoInfo.hMsg,
-                            pUlpReq->apiInfo.sendtoInfo.teid);
-
-  rc = nwGtpv1uCreateAndSendMsg(thiz,
-                                pUlpReq->apiInfo.sendtoInfo.ipAddr,
-                                2152,
-                                (NwGtpv1uMsgT *) (NwGtpv1uMsgT *) pUlpReq->apiInfo.sendtoInfo.hMsg);
-
-#if defined(LOG_GTPU) && LOG_GTPU > 0
-  NW_LEAVE(thiz);
-#endif
-  return rc;
-}
-
-/**
-  Process GPDU from UDP entity.
-
-  @param[in] thiz: Stack handle
-  @param[in] pUlpReq : Pointer to Ulp Req.
-  @return NW_GTPV1U_OK on success.
- */
-
-static NwGtpv1uRcT
-nwGtpv1uProcessGpdu( NwGtpv1uStackT *thiz,
-                     NW_IN uint8_t *gpdu,
-                     NW_IN uint32_t gpduLen,
-                     NW_IN uint32_t peerIp)
-
-{
-  NwGtpv1uRcT              rc                = NW_GTPV1U_FAILURE;
-  NwGtpv1uMsgHeaderT      *msgHdr            = NULL;
-  NwGtpv1uTunnelEndPointT *pTunnelEndPoint   = NULL;
-  NwGtpv1uTunnelEndPointT  tunnelEndPointKey;
-  //    uint16_t                   hdr_len           = 0;
-
-#if defined(LOG_GTPU) && LOG_GTPU > 0
-  NW_ENTER(thiz);
-#endif
-
-  // no buffer offset
-  msgHdr = (NwGtpv1uMsgHeaderT *) gpdu;
-
-  tunnelEndPointKey.teid = ntohl(msgHdr->teid);
-
-  pTunnelEndPoint = RB_FIND(NwGtpv1uTunnelEndPointIdentifierMap,
-                            &(thiz->teidMap), &tunnelEndPointKey);
-
-  if(pTunnelEndPoint) {
-    NwGtpv1uMsgHandleT hMsg;
-
-    rc = nwGtpv1uMsgFromBufferNew( (NwGtpv1uStackHandleT)thiz,
-                                   (uint8_t *)gpdu,
-                                   gpduLen,
-                                   &hMsg);
-
-    /*
-      uint8_t*        msgBuf;
-      uint32_t        msgBufLen;
-      uint32_t        msgBufOffset;
-     */
-    if(NW_GTPV1U_OK == rc) {
-      NwGtpv1uMsgT *pMsg = (NwGtpv1uMsgT *) hMsg;
-#if defined(LOG_GTPU) && LOG_GTPU > 0
-      GTPU_DEBUG("Received T-PDU over tunnel end-point '%x' of size %u (%u) (decapsulated %u)from "NW_IPV4_ADDR"\n",
-                 ntohl(msgHdr->teid), gpduLen, pMsg->msgLen, pMsg->msgBufLen, NW_IPV4_ADDR_FORMAT((peerIp)));
-#endif
-      MSC_LOG_RX_MESSAGE(
-        (thiz->stackType == GTPU_STACK_ENB) ? MSC_GTPU_ENB:MSC_GTPU_SGW,
-        (thiz->stackType == GTPU_STACK_ENB) ? MSC_GTPU_SGW:MSC_GTPU_ENB,
-        NULL,
-        0,
-        " G-PDU ltid %u size %u",
-        tunnelEndPointKey.teid,
-        gpduLen);
-
-      rc = nwGtpSessionSendMsgApiToUlpEntity(pTunnelEndPoint, pMsg);
-    }
-  } else {
-    MSC_LOG_RX_DISCARDED_MESSAGE(
-      (thiz->stackType == GTPU_STACK_ENB) ? MSC_GTPU_ENB:MSC_GTPU_SGW,
-      (thiz->stackType == GTPU_STACK_ENB) ? MSC_GTPU_SGW:MSC_GTPU_ENB,
-      NULL,
-      0,
-      " G-PDU ltid %u size %u",
-      tunnelEndPointKey.teid,
-      gpduLen);
-    GTPU_DEBUG("Received T-PDU over non-existent tunnel end-point '%x' from "NW_IPV4_ADDR"\n",
-               ntohl(msgHdr->teid), NW_IPV4_ADDR_FORMAT((peerIp)));
-  }
-
-#if defined(LOG_GTPU) && LOG_GTPU > 0
-  NW_LEAVE(thiz);
-#endif
-  return rc;
-}
-
-/**
-  Handle Echo Request from Peer Entity.
-
-  @param[in] thiz : Stack context
-  @return NW_GTPV1U_OK on success.
- */
-
-static NwGtpv1uRcT
-nwGtpv1uHandleEchoReq(NW_IN NwGtpv1uStackT *thiz,
-                      NW_IN uint8_t *msgBuf,
-                      NW_IN uint32_t msgBufLen,
-                      NW_IN uint16_t peerPort,
-                      NW_IN uint32_t peerIp)
-{
-  NwGtpv1uRcT           rc     = NW_GTPV1U_FAILURE;
-  uint16_t                seqNum = 0;
-  NwGtpv1uMsgHandleT    hMsg   = 0;
-  int                   bufLen = 0;
-
-  seqNum = ntohs(*(uint16_t *) (msgBuf + (((*msgBuf) & 0x02) ? 8 : 4)));
-
-  MSC_LOG_RX_MESSAGE(
-    (thiz->stackType == GTPU_STACK_ENB) ? MSC_GTPU_ENB:MSC_GTPU_SGW,
-    (thiz->stackType == GTPU_STACK_ENB) ? MSC_GTPU_SGW:MSC_GTPU_ENB,
-    NULL,
-    0,
-    MSC_AS_TIME_FMT" ECHO-REQ seq %u size %u",
-    0,0,seqNum, msgBufLen);
-  /* Send Echo Response */
-
-  rc = nwGtpv1uMsgNew( (NwGtpv1uStackHandleT)thiz,
-                       NW_TRUE,         /* SeqNum flag    */
-                       NW_FALSE,
-                       NW_FALSE,
-                       NW_GTP_ECHO_RSP,  /* Msg Type             */
-                       0x00000000U,      /* TEID                 */
-                       seqNum,           /* Seq Number           */
-                       0,
-                       0,
-                       (&hMsg));
-
-  bufLen = sizeof(NwGtpv1uIeTv1T)+ ((NwGtpv1uMsgT*)hMsg)->msgLen;
-
-//#warning CROUX DIRTY +16, TO BE FIXED!!!
-  /* the +16 is there because by analyzing memory allocation with some external
-   * 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)->msgBufLen    = bufLen;
-  NW_ASSERT(NW_GTPV1U_OK == rc);
-
-  /*
-   * The Restart Counter value in the Recovery information element shall
-   * not be used, i.e. it shall be set to zero by the sender and shall be
-   * ignored by the receiver.
-   */
-  rc = nwGtpv1uMsgAddIeTV1(hMsg, NW_GTPV1U_IE_RECOVERY, 0x00);
-
-#if defined(LOG_GTPU) && LOG_GTPU > 0
-  GTPU_INFO("Sending NW_GTP_ECHO_RSP message to %x:%x with seq %u\n",
-            peerIp,
-            peerPort,
-            seqNum);
-#endif
-  MSC_LOG_TX_MESSAGE(
-    (thiz->stackType == GTPU_STACK_ENB) ? MSC_GTPU_ENB:MSC_GTPU_SGW,
-    (thiz->stackType == GTPU_STACK_ENB) ? MSC_GTPU_SGW:MSC_GTPU_ENB,
-    NULL,
-    0,
-    MSC_AS_TIME_FMT" ECHO-RSP seq %u",
-    0,0,seqNum);
-  rc = nwGtpv1uCreateAndSendMsg(
-         thiz,
-         peerIp,
-         peerPort,
-         (NwGtpv1uMsgT *) hMsg);
-
-  rc = nwGtpv1uMsgDelete((NwGtpv1uStackHandleT)thiz, hMsg);
-  NW_ASSERT(NW_GTPV1U_OK == rc);
-
-  return rc;
-}
-
-/*--------------------------------------------------------------------------*
- *                     P U B L I C   F U N C T I O N S                      *
- *--------------------------------------------------------------------------*/
-
-/*---------------------------------------------------------------------------
- * Constructor
- *--------------------------------------------------------------------------*/
-
-NwGtpv1uRcT
-nwGtpv1uInitialize( NW_INOUT NwGtpv1uStackHandleT *hGtpuStackHandle, uint32_t stackType)
-{
-  NwGtpv1uRcT rc = NW_GTPV1U_FAILURE;
-  NwGtpv1uStackT *thiz;
-
-  thiz = (NwGtpv1uStackT *) malloc( sizeof(NwGtpv1uStackT));
-
-  if(thiz) {
-    memset(thiz, 0, sizeof(NwGtpv1uStackT));
-    thiz->id    = (NwPtrT)thiz;
-    thiz->stackType = stackType;
-    thiz->seq   = (uint16_t) ((uintptr_t)thiz) ; // FIXME interesting casts... don't know what this is good for...
-    RB_INIT(&(thiz->outstandingTxSeqNumMap));
-    RB_INIT(&(thiz->outstandingRxSeqNumMap));
-    RB_INIT(&(thiz->sessionMap));
-    RB_INIT(&(thiz->teidMap));
-
-    if (0 == 1) {
-      nwGtpv1uDisplayBanner();
-    }
-
-    rc = NW_GTPV1U_OK;
-  } else {
-    rc = NW_GTPV1U_FAILURE;
-  }
-
-
-  *hGtpuStackHandle = (NwGtpv1uStackHandleT) thiz;
-  return rc;
-}
-
-
-/*---------------------------------------------------------------------------
- * Destructor
- *--------------------------------------------------------------------------*/
-
-NwGtpv1uRcT
-nwGtpv1uFinalize( NW_IN  NwGtpv1uStackHandleT hGtpuStackHandle)
-{
-  NwGtpv1uRcT rc = NW_GTPV1U_FAILURE;
-
-  if(hGtpuStackHandle) {
-    free((void *)hGtpuStackHandle);
-    rc = NW_GTPV1U_OK;
-  } else {
-    rc = NW_GTPV1U_FAILURE;
-  }
-
-  return rc;
-}
-
-
-/*---------------------------------------------------------------------------
- * Configuration Get/Set
- *--------------------------------------------------------------------------*/
-
-NwGtpv1uRcT
-nwGtpv1uSetUlpEntity( NW_IN NwGtpv1uStackHandleT hGtpuStackHandle,
-                      NW_IN NwGtpv1uUlpEntityT *pUlpEntity)
-{
-  NwGtpv1uRcT rc = NW_GTPV1U_FAILURE;
-  NwGtpv1uStackT *thiz = (NwGtpv1uStackT *) hGtpuStackHandle;
-
-  if(pUlpEntity) {
-    thiz->ulp = *(pUlpEntity);
-    rc = NW_GTPV1U_OK;
-  } else {
-    rc = NW_GTPV1U_FAILURE;
-  }
-
-  return rc;
-}
-
-
-NwGtpv1uRcT
-nwGtpv1uSetUdpEntity( NW_IN NwGtpv1uStackHandleT hGtpuStackHandle,
-                      NW_IN NwGtpv1uUdpEntityT *pUdpEntity)
-{
-  NwGtpv1uRcT rc = NW_GTPV1U_FAILURE;
-  NwGtpv1uStackT *thiz = (NwGtpv1uStackT *) hGtpuStackHandle;
-
-  if(pUdpEntity) {
-    thiz->udp = *(pUdpEntity);
-    rc = NW_GTPV1U_OK;
-  } else {
-    rc = NW_GTPV1U_FAILURE;
-  }
-
-  return rc;
-}
-
-NwGtpv1uRcT
-nwGtpv1uSetMemMgrEntity( NW_IN NwGtpv1uStackHandleT hGtpuStackHandle,
-                         NW_IN NwGtpv1uMemMgrEntityT *pMemMgrEntity)
-{
-  NwGtpv1uRcT rc = NW_GTPV1U_FAILURE;
-  NwGtpv1uStackT *thiz = (NwGtpv1uStackT *) hGtpuStackHandle;
-
-  if(pMemMgrEntity) {
-    thiz->memMgr = *(pMemMgrEntity);
-    rc = NW_GTPV1U_OK;
-  } else {
-    rc = NW_GTPV1U_FAILURE;
-  }
-
-  return rc;
-}
-
-
-NwGtpv1uRcT
-nwGtpv1uSetTimerMgrEntity( NW_IN NwGtpv1uStackHandleT hGtpuStackHandle,
-                           NW_IN NwGtpv1uTimerMgrEntityT *pTmrMgrEntity)
-{
-  NwGtpv1uRcT rc = NW_GTPV1U_FAILURE;
-  NwGtpv1uStackT *thiz = (NwGtpv1uStackT *) hGtpuStackHandle;
-
-  if(pTmrMgrEntity) {
-    thiz->tmrMgr = *(pTmrMgrEntity);
-    rc = NW_GTPV1U_OK;
-  } else {
-    rc = NW_GTPV1U_FAILURE;
-  }
-
-  return rc;
-}
-
-
-NwGtpv1uRcT
-nwGtpv1uSetLogMgrEntity( NW_IN NwGtpv1uStackHandleT hGtpuStackHandle,
-                         NW_IN NwGtpv1uLogMgrEntityT *pLogMgrEntity)
-{
-  NwGtpv1uRcT rc = NW_GTPV1U_FAILURE;
-  NwGtpv1uStackT *thiz = (NwGtpv1uStackT *) hGtpuStackHandle;
-
-  if(pLogMgrEntity) {
-    thiz->logMgr = *(pLogMgrEntity);
-    rc = NW_GTPV1U_OK;
-  } else {
-    rc = NW_GTPV1U_FAILURE;
-  }
-
-  return rc;
-}
-
-NwGtpv1uRcT
-nwGtpv1uSetLogLevel( NW_IN NwGtpv1uStackHandleT hGtpuStackHandle,
-                     NW_IN uint32_t logLevel)
-{
-  NwGtpv1uStackT *thiz = (NwGtpv1uStackT *) hGtpuStackHandle;
-  thiz->logLevel = logLevel;
-  return NW_GTPV1U_OK;
-}
-
-/*---------------------------------------------------------------------------
- * Process Request from Udp Layer
- *--------------------------------------------------------------------------*/
-
-NwGtpv1uRcT
-nwGtpv1uProcessUdpReq( NW_IN NwGtpv1uStackHandleT hGtpuStackHandle,
-                       NW_IN uint8_t *udpData,
-                       NW_IN uint32_t udpDataLen,
-                       NW_IN uint16_t peerPort,
-                       NW_IN uint32_t peerIp)
-{
-  NwGtpv1uRcT           ret = NW_GTPV1U_FAILURE;
-  NwGtpv1uStackT       *thiz;
-  uint16_t                msgType;
-
-#if defined(ENB_MODE)
-  VCD_SIGNAL_DUMPER_DUMP_FUNCTION_BY_NAME(VCD_SIGNAL_DUMPER_FUNCTIONS_GTPV1U_PROCESS_UDP_REQ, VCD_FUNCTION_IN);
-#endif
-  thiz = (NwGtpv1uStackT *) hGtpuStackHandle;
-
-  NW_ASSERT(thiz);
-
-  msgType = *((uint8_t *)(udpData + 1));
-
-  switch(msgType) {
-  case NW_GTP_ECHO_REQ:
-    GTPU_DEBUG("NW_GTP_ECHO_REQ\n");
-    ret = nwGtpv1uHandleEchoReq( thiz, udpData, udpDataLen, peerPort, peerIp);
-    break;
-
-  case NW_GTP_ERROR_INDICATION:
-    GTPU_DEBUG("NW_GTP_ERROR_INDICATION\n");
-    ret = nwGtpv1uSendUlpMessageIndication( thiz,
-                                            0,
-                                            NW_GTPV1U_ULP_API_RECV_MSG,
-                                            msgType,
-                                            peerIp,
-                                            peerPort,
-                                            udpData,
-                                            udpDataLen);
-
-    NW_ASSERT(ret == NW_GTPV1U_OK);
-    break;
-
-  case NW_GTP_ECHO_RSP:
-    GTPU_DEBUG("NW_GTP_ECHO_RSP\n");
-    ret = NW_GTPV1U_OK;
-    break;
-
-  case NW_GTP_GPDU:
-#if defined(LOG_GTPU) && LOG_GTPU > 0
-    GTPU_DEBUG("NW_GTP_GPDU: DATA COMING FROM UDP\n");
-#endif
-    ret = nwGtpv1uProcessGpdu(thiz, udpData, udpDataLen, peerIp);
-    break;
-
-  case NW_GTP_END_MARKER:
-#if defined(LOG_GTPU) && LOG_GTPU > 0
-    for(int i =1; i<= udpDataLen; i++){
-      printf("%02x ", (uint8_t)udpData[i-1]);
-      if(i % 20 == 0)printf("\n");
-    }
-#endif  	
-    GTPU_INFO("NW_GTP_END_MARKER\n");
-    ret = nwGtpv1uProcessGpdu(thiz, udpData, udpDataLen, peerIp);
-    break;
-
-  default:
-    ret = NW_GTPV1U_FAILURE;
-    NW_ASSERT(0);
-    break;
-  }
-
-#if defined(LOG_GTPU) && LOG_GTPU > 0
-  NW_LEAVE(thiz);
-#endif
-#if defined(ENB_MODE)
-  VCD_SIGNAL_DUMPER_DUMP_FUNCTION_BY_NAME(VCD_SIGNAL_DUMPER_FUNCTIONS_GTPV1U_PROCESS_UDP_REQ, VCD_FUNCTION_OUT);
-#endif
-  return ret;
-}
-
-
-/*---------------------------------------------------------------------------
- * Process Request from Upper Layer
- *--------------------------------------------------------------------------*/
-
-NwGtpv1uRcT
-nwGtpv1uProcessUlpReq( NW_IN NwGtpv1uStackHandleT hGtpuStackHandle,
-                       NW_IN NwGtpv1uUlpApiT *pUlpReq)
-{
-  NwGtpv1uRcT rc = NW_GTPV1U_FAILURE;
-  NwGtpv1uStackT *thiz = (NwGtpv1uStackT *) hGtpuStackHandle;
-
-  NW_ASSERT(thiz);
-  NW_ASSERT(pUlpReq != NULL);
-
-#if defined(LOG_GTPU) && LOG_GTPU > 0
-  NW_ENTER(thiz);
-#endif
-
-  switch(pUlpReq->apiType) {
-  case NW_GTPV1U_ULP_API_CREATE_TUNNEL_ENDPOINT: {
-    GTPU_DEBUG("Received NW_GTPV1U_ULP_API_CREATE_TUNNEL_ENDPOINT from ulp\n");
-    rc = NwGtpv1uCreateTunnelEndPoint(thiz,
-                                      pUlpReq->apiInfo.createTunnelEndPointInfo.teid,
-                                      pUlpReq->apiInfo.createTunnelEndPointInfo.hUlpSession,
-                                      &(pUlpReq->apiInfo.createTunnelEndPointInfo.hStackSession));
-  }
-  break;
-
-  case NW_GTPV1U_ULP_API_DESTROY_TUNNEL_ENDPOINT: {
-    GTPU_DEBUG("Received destroy session req from ulp\n");
-    rc = nwGtpv1uDestroyTunnelEndPoint(thiz,  pUlpReq);
-  }
-  break;
-
-  case NW_GTPV1U_ULP_API_INITIAL_REQ: {
-    GTPU_DEBUG("Received initial req from ulp\n");
-    rc = nwGtpv1uInitialReq(thiz, pUlpReq);
-  }
-  break;
-
-  case NW_GTPV1U_ULP_API_SEND_TPDU: {
-#if defined(LOG_GTPU) && LOG_GTPU > 0
-    GTPU_DEBUG("Received send tpdu req from ulp\n");
-#endif
-    rc = nwGtpv1uSendto(thiz,  pUlpReq);
-  }
-  break;
-
-  default:
-    GTPU_DEBUG("Unsupported API received from ulp\n");
-    rc = NW_GTPV1U_FAILURE;
-    break;
-  }
-
-#if defined(LOG_GTPU) && LOG_GTPU > 0
-  NW_LEAVE(thiz);
-#endif
-  return rc;
-}
-
-/*---------------------------------------------------------------------------
- * Process Timer timeout Request from Timer Manager
- *--------------------------------------------------------------------------*/
-
-NwGtpv1uRcT
-nwGtpv1uProcessTimeout(void *timeoutInfo)
-{
-  NwGtpv1uRcT rc = NW_GTPV1U_FAILURE;
-  NwGtpv1uStackT *thiz;
-
-  NW_ASSERT(timeoutInfo != NULL);
-
-  thiz = (NwGtpv1uStackT *) (((NwGtpv1uTimeoutInfoT *) timeoutInfo)->hStack);
-
-  NW_ASSERT(thiz != NULL);
-
-#if defined(LOG_GTPU) && LOG_GTPU > 0
-  NW_ENTER(thiz);
-#endif
-  GTPU_DEBUG("Received timeout event from ULP with timeoutInfo 0x%p!\n",
-             timeoutInfo);
-
-  rc = (((NwGtpv1uTimeoutInfoT *) timeoutInfo)->timeoutCallbackFunc) (timeoutInfo);
-
-#if defined(LOG_GTPU) && LOG_GTPU > 0
-  NW_LEAVE(thiz);
-#endif
-  return rc;
-}
-
-#ifdef __cplusplus
-}
-#endif
-
-/*--------------------------------------------------------------------------*
- *                      E N D     O F    F I L E                            *
- *--------------------------------------------------------------------------*/
-
diff --git a/openair3/GTPV1-U/nw-gtpv1u/src/NwGtpv1uMsg.c b/openair3/GTPV1-U/nw-gtpv1u/src/NwGtpv1uMsg.c
deleted file mode 100644
index 365d6d23a5f..00000000000
--- a/openair3/GTPV1-U/nw-gtpv1u/src/NwGtpv1uMsg.c
+++ /dev/null
@@ -1,558 +0,0 @@
-/*----------------------------------------------------------------------------*
- *                                                                            *
- *                             n w - g t p v 2 u                              *
- *    G P R S   T u n n e l i n g    P r o t o c o l   v 2 u    S t a c k     *
- *                                                                            *
- *                                                                            *
- * Copyright (c) 2010-2011 Amit Chawre                                        *
- * All rights reserved.                                                       *
- *                                                                            *
- * Redistribution and use in source and binary forms, with or without         *
- * modification, are permitted provided that the following conditions         *
- * are met:                                                                   *
- *                                                                            *
- * 1. Redistributions of source code must retain the above copyright          *
- *    notice, this list of conditions and the following disclaimer.           *
- * 2. Redistributions in binary form must reproduce the above copyright       *
- *    notice, this list of conditions and the following disclaimer in the     *
- *    documentation and/or other materials provided with the distribution.    *
- * 3. The name of the author may not be used to endorse or promote products   *
- *    derived from this software without specific prior written permission.   *
- *                                                                            *
- * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR       *
- * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES  *
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.    *
- * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,           *
- * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT   *
- * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,  *
- * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY      *
- * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT        *
- * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF   *
- * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.          *
- *----------------------------------------------------------------------------*/
-
-#include <stdio.h>
-#include <string.h>
-#include <ctype.h>
-
-#include "NwTypes.h"
-#include "NwLog.h"
-#include "NwUtils.h"
-#include "NwGtpv1uLog.h"
-#include "NwGtpv1u.h"
-#include "NwGtpv1uPrivate.h"
-#include "NwGtpv1uMsg.h"
-#include "assertions.h"
-
-#include "gtpv1u.h"
-#if defined(ENB_MODE)
-#include "common/utils/LOG/log.h"
-#endif
-
-#define NW_GTPV1U_EPC_SPECIFIC_HEADER_SIZE                             (12)   /**< Size of GTPv1u EPC specific header */
-#define NW_GTPV1U_EPC_MIN_HEADER_SIZE                                  (8)
-
-#ifdef __cplusplus
-extern "C" {
-#endif
-
-static NwGtpv1uMsgT *gpGtpv1uMsgPool = NULL;
-
-NwGtpv1uRcT
-nwGtpv1uMsgNew( NW_IN NwGtpv1uStackHandleT hGtpuStackHandle,
-                NW_IN uint8_t     seqNumFlag,
-                NW_IN uint8_t     npduNumFlag,
-                NW_IN uint8_t     extHdrFlag,
-                NW_IN uint8_t     msgType,
-                NW_IN uint8_t     teid,
-                NW_IN uint16_t    seqNum,
-                NW_IN uint8_t     npduNum,
-                NW_IN uint8_t     nextExtHeader,
-                NW_OUT NwGtpv1uMsgHandleT *phMsg)
-{
-  NwGtpv1uStackT *pStack = (NwGtpv1uStackT *) hGtpuStackHandle;
-  NwGtpv1uMsgT *pMsg;
-
-  if(gpGtpv1uMsgPool) {
-    pMsg = gpGtpv1uMsgPool;
-    gpGtpv1uMsgPool = gpGtpv1uMsgPool->next;
-  } else {
-    NW_GTPV1U_MALLOC(pStack, sizeof(NwGtpv1uMsgT), pMsg, NwGtpv1uMsgT *);
-  }
-
-
-  if(pMsg) {
-    pMsg->version       = NW_GTPU_VERSION;
-    pMsg->protocolType  = NW_GTP_PROTOCOL_TYPE_GTP;
-    pMsg->seqNumFlag    = seqNumFlag;
-    pMsg->npduNumFlag   = npduNumFlag;
-    pMsg->extHdrFlag    = extHdrFlag;
-    pMsg->msgType       = msgType;
-
-    if(seqNumFlag) {
-      pMsg->seqNum        = seqNum;
-    }
-
-    if(npduNumFlag) {
-      pMsg->npduNum       = npduNum;
-    }
-
-    if(extHdrFlag) {
-      pMsg->nextExtHdrType = nextExtHeader;
-    }
-
-    pMsg->msgLen        = ((pMsg->seqNumFlag || pMsg->npduNumFlag
-                            || pMsg->extHdrFlag) ?
-                           4 : 0);
-    //NW_GTPV1U_EPC_SPECIFIC_HEADER_SIZE : (NW_GTPV1U_EPC_SPECIFIC_HEADER_SIZE - 4));
-
-    pMsg->msgBuf       = NULL;
-    pMsg->msgBufLen    = 0;
-    pMsg->msgBufOffset = 0;
-    *phMsg = (NwGtpv1uMsgHandleT) pMsg;
-    return NW_GTPV1U_OK;
-  }
-
-  return NW_GTPV1U_FAILURE;
-}
-
-NwGtpv1uRcT
-nwGtpv1uGpduMsgNew( NW_IN NwGtpv1uStackHandleT hGtpuStackHandle,
-                    NW_IN uint32_t    teid,
-                    NW_IN uint8_t     seqNumFlag,
-                    NW_IN uint16_t    seqNum,
-                    NW_IN uint8_t    *tpdu,
-                    NW_IN uint16_t    tpduLength,
-                    NW_IN uint32_t    tpduOffset,
-                    NW_OUT NwGtpv1uMsgHandleT *phMsg)
-{
-  NwGtpv1uStackT *pStack = (NwGtpv1uStackT *) hGtpuStackHandle;
-  NwGtpv1uMsgT   *pMsg;
-  //uint32_t          header_len  = 0;
-  uint32_t          msgExtraLen = 0;
-
-  if(gpGtpv1uMsgPool) {
-    pMsg = gpGtpv1uMsgPool;
-    gpGtpv1uMsgPool = gpGtpv1uMsgPool->next;
-  } else {
-    NW_GTPV1U_MALLOC(pStack, sizeof(NwGtpv1uMsgT), pMsg, NwGtpv1uMsgT *);
-  }
-
-  if(pMsg) {
-    msgExtraLen        = (((seqNumFlag) || (NW_FALSE) || (NW_FALSE) ) ?
-                          (NW_GTPV1U_EPC_SPECIFIC_HEADER_SIZE - NW_GTPV1U_EPC_MIN_HEADER_SIZE)  : 0);
-    AssertFatal((msgExtraLen + NW_GTPV1U_EPC_MIN_HEADER_SIZE) <= tpduOffset,
-                "Mismatch GTPU len, msgExtraLen %u tpduOffset %u",
-                msgExtraLen,
-                (uint32_t) tpduOffset);
-    pMsg->msgBuf       = tpdu;
-    pMsg->msgBufLen    = tpduLength + msgExtraLen + NW_GTPV1U_EPC_MIN_HEADER_SIZE;
-    pMsg->msgBufOffset = tpduOffset - (msgExtraLen + NW_GTPV1U_EPC_MIN_HEADER_SIZE);
-#if defined(LOG_GTPU) && LOG_GTPU > 0
-    GTPU_DEBUG("MSG length %u, offset %u -> length %u offset %u\n",
-               tpduLength, tpduOffset,
-               pMsg->msgBufLen, pMsg->msgBufOffset);
-#endif
-
-    // Version field: This field is used to determine the version of the GTP-U protocol.
-    // The version number shall be set to '1'.
-    pMsg->version       = NW_GTPU_VERSION;
-    // Protocol Type (PT): This bit is used as a protocol discriminator between GTP (when PT is '1')
-    // and GTP' (when PT is '0'). GTP is described in this document and the GTP' protocol in 3GPP TS 32.295 [8].
-    // Note that the interpretation of the header fields may be different in GTP' than in GTP.
-    pMsg->protocolType  = NW_GTP_PROTOCOL_TYPE_GTP;
-    // Extension Header flag (E): This flag indicates the presence of a meaningful value of the Next Extension
-    // Header field. When it is set to '0', the Next Extension Header field either is not present or, if present,
-    // shall not be interpreted.
-    pMsg->extHdrFlag    = NW_FALSE;
-    // Sequence number flag (S): This flag indicates the presence of a meaningful value of the Sequence Number field.
-    // When it is set to '0', the Sequence Number field either is not present or, if present, shall not be interpreted.
-    // When it is set to '1', the Sequence Number field is present, and shall be interpreted, as described below in
-    // this section.
-    // For the Echo Request, Echo Response, Error Indication and Supported Extension Headers Notification
-    // messages, the S flag shall be set to '1'. Since the use of Sequence Numbers is optional for G-PDUs, the PGW,
-    // SGW, ePDG and eNodeB should set the flag to '0'. However, when a G-PDU (T-PDU+header) is being relayed
-    // by the Indirect Data Forwarding for Inter RAT HO procedure, then if the received G-PDU has the S flag set to
-    // '1', then the relaying entity shall set S flag to '1' and forward the G-PDU (T-PDU+header). In an End marker
-    // message the S flag shall be set to '0'.
-    pMsg->seqNumFlag    = (seqNumFlag? NW_TRUE : NW_FALSE);
-    pMsg->seqNum        = seqNum;
-    // N-PDU Number flag (PN): This flag indicates the presence of a meaningful value of the N-PDU Number field.
-    // When it is set to '0', the N-PDU Number field either is not present, or, if present, shall not be interpreted.
-    // When it is set to '1', the N-PDU Number field is present, and shall be interpreted.
-    pMsg->npduNumFlag   = NW_FALSE;
-    pMsg->npduNum       = 0x00;
-    // Message Type: This field indicates the type of GTP-U message.
-    pMsg->msgType       = NW_GTP_GPDU;
-    // Length: This field indicates the length in octets of the payload, i.e. the rest of the packet following the
-    // mandatory part of the GTP header (that is the first 8 octets).
-    // The Sequence Number, the N-PDU Number or any Extension headers shall be considered to be part of the payload,
-    // i.e. included in the length count.
-    //header_len          = ((pMsg->seqNumFlag || pMsg->npduNumFlag || pMsg->extHdrFlag ) ?
-    //                        NW_GTPV1U_EPC_SPECIFIC_HEADER_SIZE : NW_GTPV1U_EPC_MIN_HEADER_SIZE);
-    pMsg->msgLen        = msgExtraLen + tpduLength;
-
-    // Tunnel Endpoint Identifier (TEID): This field unambiguously identifies a tunnel endpoint in the receiving
-    // GTP-U protocol entity. The receiving end side of a GTP tunnel locally assigns the TEID value the transmitting
-    // side has to use. The TEID shall be used by the receiving entity to find the PDP context, except for the
-    // following cases:
-    // - The Echo Request/Response and Supported Extension Headers notification messages, where the Tunnel
-    //      Endpoint Identifier shall be set to all zeroes.
-    // - The Error Indication message where the Tunnel Endpoint Identifier shall be set to all zeros.
-    pMsg->teid          = teid;
-    pMsg->nextExtHdrType= 0x00;
-
-    //memcpy(pMsg->msgBuf + header_len, tpdu, tpduLength);
-    *phMsg = (NwGtpv1uMsgHandleT) pMsg;
-    return NW_GTPV1U_OK;
-  }
-
-  return NW_GTPV1U_FAILURE;
-}
-
-NwGtpv1uRcT
-nwGtpv1uMsgFromMsgNew( NW_IN NwGtpv1uStackHandleT hGtpuStackHandle,
-                       NW_IN NwGtpv1uMsgHandleT hMsg,
-                       NW_OUT NwGtpv1uMsgHandleT *phMsg)
-{
-  NwGtpv1uStackT *pStack = (NwGtpv1uStackT *) hGtpuStackHandle;
-  NwGtpv1uMsgT *pMsg;
-
-  if(gpGtpv1uMsgPool) {
-    pMsg = gpGtpv1uMsgPool;
-    gpGtpv1uMsgPool = gpGtpv1uMsgPool->next;
-  } else {
-    NW_GTPV1U_MALLOC(pStack, sizeof(NwGtpv1uMsgT), pMsg, NwGtpv1uMsgT *);
-  }
-
-
-  if(pMsg) {
-    memcpy(pMsg, (NwGtpv1uMsgT *)hMsg, sizeof(NwGtpv1uMsgT));
-    *phMsg = (NwGtpv1uMsgHandleT) pMsg;
-    return NW_GTPV1U_OK;
-  }
-
-  return NW_GTPV1U_FAILURE;
-}
-
-NwGtpv1uRcT
-nwGtpv1uMsgFromBufferNew( NW_IN NwGtpv1uStackHandleT hGtpuStackHandle,
-                          NW_IN uint8_t *pBuf,
-                          NW_IN uint32_t bufLen,
-                          NW_OUT NwGtpv1uMsgHandleT *phMsg)
-{
-  NwGtpv1uStackT *pStack = (NwGtpv1uStackT *) hGtpuStackHandle;
-  NwGtpv1uMsgT *pMsg;
-
-  if(gpGtpv1uMsgPool) {
-    pMsg = gpGtpv1uMsgPool;
-    gpGtpv1uMsgPool = gpGtpv1uMsgPool->next;
-  } else {
-    NW_GTPV1U_MALLOC(pStack, sizeof(NwGtpv1uMsgT), pMsg, NwGtpv1uMsgT *);
-  }
-
-
-  if(pMsg) {
-    pMsg->msgBuf    =  pBuf;
-
-    pMsg->version       = ((*pBuf) & 0xE0) >> 5;
-    pMsg->protocolType  = ((*pBuf) & 0x10) >> 4;
-    pMsg->extHdrFlag    = ((*pBuf) & 0x04) >> 2;
-    pMsg->seqNumFlag    = ((*pBuf) & 0x02) >> 1;
-    pMsg->npduNumFlag   = ((*pBuf) & 0x01);
-    pBuf++;
-
-    pMsg->msgType       = *(pBuf);
-    pBuf++;
-
-    pBuf += 2;
-
-    pMsg->teid          = ntohl(*((uint32_t *)pBuf));
-    pBuf += 4;
-
-    if(pMsg->extHdrFlag || pMsg->seqNumFlag || pMsg->npduNumFlag) {
-      pMsg->seqNum              = ntohs(*(((uint16_t *)pBuf)));
-      pBuf += 2;
-      pMsg->npduNum             = *(pBuf++);
-      pMsg->nextExtHdrType      = *(pBuf++);
-    }
-
-    pMsg->msgBufOffset = (uint32_t)(pBuf - pMsg->msgBuf);
-    pMsg->msgBufLen = bufLen - pMsg->msgBufOffset;
-    pMsg->msgLen    = bufLen;
-#if defined(LOG_GTPU) && LOG_GTPU > 0
-    GTPU_DEBUG("nwGtpv1uMsgFromBufferNew() msgLen %u msgBufLen %u msgBufOffset %u ",
-               pMsg->msgLen, pMsg->msgBufLen, pMsg->msgBufOffset);
-#endif
-    *phMsg = (NwGtpv1uMsgHandleT) pMsg;
-    return NW_GTPV1U_OK;
-  }
-
-  return NW_GTPV1U_FAILURE;
-}
-
-NwGtpv1uRcT
-nwGtpv1uMsgDelete( NW_IN NwGtpv1uStackHandleT hGtpuStackHandle,
-                   NW_IN NwGtpv1uMsgHandleT hMsg)
-{
-  ((NwGtpv1uMsgT *)hMsg)->next = gpGtpv1uMsgPool;
-  gpGtpv1uMsgPool = (NwGtpv1uMsgT *) hMsg;
-  return NW_GTPV1U_OK;
-}
-
-/**
- * Set TEID for gtpv1u message.
- *
- * @param[in] hMsg : Message handle.
- * @param[in] teid: TEID value.
- */
-
-NwGtpv1uRcT
-nwGtpv1uMsgSetTeid(NW_IN NwGtpv1uMsgHandleT hMsg, uint32_t teid)
-{
-  NwGtpv1uMsgT *thiz = (NwGtpv1uMsgT *) hMsg;
-  thiz->teid = teid;
-#if defined(LOG_GTPU) && LOG_GTPU > 0
-  GTPU_DEBUG("nwGtpv1uMsgSetTeid() teid %u", teid);
-#endif
-  return NW_GTPV1U_OK;
-}
-
-/**
- * Set sequence for gtpv1u message.
- *
- * @param[in] hMsg : Message handle.
- * @param[in] seqNum: Flag boolean value.
- */
-
-NwGtpv1uRcT
-nwGtpv1uMsgSetSeqNumber(NW_IN NwGtpv1uMsgHandleT hMsg, uint32_t seqNum)
-{
-  NwGtpv1uMsgT *thiz = (NwGtpv1uMsgT *) hMsg;
-  thiz->seqNum = seqNum;
-  return NW_GTPV1U_OK;
-}
-
-/**
- * Get TEID present for gtpv1u message.
- *
- * @param[in] hMsg : Message handle.
- */
-
-uint32_t
-nwGtpv1uMsgGetTeid(NW_IN NwGtpv1uMsgHandleT hMsg)
-{
-  NwGtpv1uMsgT *thiz = (NwGtpv1uMsgT *) hMsg;
-  return (thiz->teid);
-}
-
-
-/**
- * Get sequence number for gtpv1u message.
- *
- * @param[in] hMsg : Message handle.
- */
-
-uint32_t
-nwGtpv1uMsgGetSeqNumber(NW_IN NwGtpv1uMsgHandleT hMsg)
-{
-  NwGtpv1uMsgT *thiz = (NwGtpv1uMsgT *) hMsg;
-  return (thiz->seqNum);
-}
-
-/**
- * Get msg type for gtpv1u message.
- *
- * @param[in] hMsg : Message handle.
- */
-
-uint32_t
-nwGtpv1uMsgGetMsgType(NW_IN NwGtpv1uMsgHandleT hMsg)
-{
-  NwGtpv1uMsgT *thiz = (NwGtpv1uMsgT *) hMsg;
-  return (thiz->msgType);
-}
-
-/**
- * Get tpdu for gtpv1u message.
- *
- * @param[in] hMsg : Message handle.
- */
-
-NwGtpv1uRcT
-nwGtpv1uMsgGetTpdu(NW_IN NwGtpv1uMsgHandleT hMsg, uint8_t *pTpduBuf,
-                   uint32_t *pTpduLength)
-{
-  NwGtpv1uMsgT *thiz = (NwGtpv1uMsgT *) hMsg;
-  uint8_t headerLength = ((thiz->seqNumFlag || thiz->extHdrFlag
-                         || thiz->npduNumFlag) ? 12 : 8);
-
-  *pTpduLength = thiz->msgLen - headerLength;
-  memcpy(pTpduBuf, thiz->msgBuf + headerLength, *pTpduLength);
-  return NW_GTPV1U_OK;
-}
-
-uint8_t *
-nwGtpv1uMsgGetTpduHandle(NW_IN NwGtpv1uMsgHandleT hMsg)
-{
-  NwGtpv1uMsgT *thiz = (NwGtpv1uMsgT *) hMsg;
-  return (thiz->msgBuf + ((thiz->seqNumFlag || thiz->extHdrFlag
-                           || thiz->npduNumFlag) ? 12 : 8));
-}
-
-uint32_t
-nwGtpv1uMsgGetTpduLength(NW_IN NwGtpv1uMsgHandleT hMsg)
-{
-  NwGtpv1uMsgT *thiz = (NwGtpv1uMsgT *) hMsg;
-  return (thiz->msgLen - ((thiz->seqNumFlag || thiz->extHdrFlag
-                           || thiz->npduNumFlag) ? 12 : 8));
-}
-
-NwGtpv1uRcT
-nwGtpv1uMsgAddIeTV1(NW_IN NwGtpv1uMsgHandleT hMsg,
-                    NW_IN uint8_t       type,
-                    NW_IN uint8_t       value)
-{
-  NwGtpv1uMsgT *pMsg = (NwGtpv1uMsgT *) hMsg;
-  NwGtpv1uIeTv1T *pIe;
-
-  pIe = (NwGtpv1uIeTv1T *) (pMsg->msgBuf + pMsg->msgLen);
-
-  pIe->t        = type;
-  pIe->v        = value;
-
-  pMsg->msgLen += sizeof(NwGtpv1uIeTv1T);
-
-  return NW_GTPV1U_OK;
-}
-
-NwGtpv1uRcT
-nwGtpv1uMsgAddIeTV2(NW_IN NwGtpv1uMsgHandleT hMsg,
-                    NW_IN uint8_t       type,
-                    NW_IN uint16_t      length,
-                    NW_IN uint16_t      value)
-{
-  NwGtpv1uMsgT *pMsg = (NwGtpv1uMsgT *) hMsg;
-  NwGtpv1uIeTv2T *pIe;
-
-  pIe = (NwGtpv1uIeTv2T *) (pMsg->msgBuf + pMsg->msgLen);
-
-  pIe->t        = type;
-  pIe->v        = htons(value);
-
-  pMsg->msgLen += sizeof(NwGtpv1uIeTv2T);
-
-  return NW_GTPV1U_OK;
-}
-
-NwGtpv1uRcT
-nwGtpv1uMsgAddIeTV4(NW_IN NwGtpv1uMsgHandleT hMsg,
-                    NW_IN uint8_t       type,
-                    NW_IN uint16_t      length,
-                    NW_IN uint32_t      value)
-{
-  NwGtpv1uMsgT *pMsg = (NwGtpv1uMsgT *) hMsg;
-  NwGtpv1uIeTv4T *pIe;
-
-  pIe = (NwGtpv1uIeTv4T *) (pMsg->msgBuf + pMsg->msgLen);
-
-  pIe->t        = type;
-  pIe->v        = htonl(value);
-
-  pMsg->msgLen += sizeof(NwGtpv1uIeTv4T);
-
-  return NW_GTPV1U_OK;
-}
-
-NwGtpv1uRcT
-nwGtpv1uMsgAddIe(NW_IN NwGtpv1uMsgHandleT hMsg,
-                 NW_IN uint8_t       type,
-                 NW_IN uint16_t      length,
-                 NW_IN uint8_t      *pVal)
-{
-  NwGtpv1uMsgT *pMsg = (NwGtpv1uMsgT *) hMsg;
-  NwGtpv1uIeTlvT *pIe;
-
-  pIe = (NwGtpv1uIeTlvT *) (pMsg->msgBuf + pMsg->msgLen);
-
-  pIe->t        = type;
-  pIe->l        = htons(length);
-
-  memcpy(pIe + 4, pVal, length);
-  pMsg->msgLen += (4 + length);
-
-  return NW_GTPV1U_OK;
-}
-
-NwGtpv1uRcT
-nwGtpv1uMsgHexDump(NwGtpv1uMsgHandleT hMsg, FILE *fp)
-{
-
-  NwGtpv1uMsgT *pMsg = (NwGtpv1uMsgT *) hMsg;
-  uint8_t *data = pMsg->msgBuf;
-  uint32_t size = pMsg->msgLen;
-
-  unsigned char *p = (unsigned char *)data;
-  unsigned char c;
-  int n;
-  char bytestr[4] = {0};
-  char addrstr[10] = {0};
-  char hexstr[ 16*3 + 5] = {0};
-  char charstr[16*1 + 5] = {0};
-  fprintf((FILE *)fp, "\n");
-
-  for(n=1; n<=size; n++) {
-    if (n%16 == 1) {
-      /* store address for this line */
-      snprintf(addrstr, sizeof(addrstr), "%.4lx",
-               (p-data) );
-    }
-
-    c = *p;
-
-    if (isalnum(c) == 0) {
-      c = '.';
-    }
-
-    /* store hex str (for left side) */
-    snprintf(bytestr, sizeof(bytestr), "%02X ", *p);
-    strncat(hexstr, bytestr, sizeof(hexstr)-strlen(hexstr)-1);
-
-    /* store char str (for right side) */
-    snprintf(bytestr, sizeof(bytestr), "%c", c);
-    strncat(charstr, bytestr, sizeof(charstr)-strlen(charstr)-1);
-
-    if(n%16 == 0) {
-      /* line completed */
-      fprintf((FILE *)fp, "[%4.4s]   %-50.50s  %s\n", addrstr, hexstr, charstr);
-      hexstr[0] = 0;
-      charstr[0] = 0;
-    } else if(n%8 == 0) {
-      /* half line: add whitespaces */
-      strncat(hexstr, "  ", sizeof(hexstr)-strlen(hexstr)-1);
-      strncat(charstr, " ", sizeof(charstr)-strlen(charstr)-1);
-    }
-
-    p++; /* next byte */
-  }
-
-  if (strlen(hexstr) > 0) {
-    /* print rest of buffer if not empty */
-    fprintf((FILE *)fp, "[%4.4s]   %-50.50s  %s\n", addrstr, hexstr, charstr);
-
-  }
-
-  fprintf((FILE *)fp, "\n");
-
-  return NW_GTPV1U_OK;
-}
-
-#ifdef __cplusplus
-}
-#endif
-
-
-
-/*--------------------------------------------------------------------------*
- *                          E N D   O F   F I L E                           *
- *--------------------------------------------------------------------------*/
diff --git a/openair3/GTPV1-U/nw-gtpv1u/src/NwGtpv1uTrxn.c b/openair3/GTPV1-U/nw-gtpv1u/src/NwGtpv1uTrxn.c
deleted file mode 100644
index 27cb59050f9..00000000000
--- a/openair3/GTPV1-U/nw-gtpv1u/src/NwGtpv1uTrxn.c
+++ /dev/null
@@ -1,399 +0,0 @@
-/*----------------------------------------------------------------------------*
- *                                                                            *
- *                             n w - g t p v 2 u                              *
- *    G P R S   T u n n e l i n g    P r o t o c o l   v 2 u    S t a c k     *
- *                                                                            *
- *                                                                            *
- * Copyright (c) 2010-2011 Amit Chawre                                        *
- * All rights reserved.                                                       *
- *                                                                            *
- * Redistribution and use in source and binary forms, with or without         *
- * modification, are permitted provided that the following conditions         *
- * are met:                                                                   *
- *                                                                            *
- * 1. Redistributions of source code must retain the above copyright          *
- *    notice, this list of conditions and the following disclaimer.           *
- * 2. Redistributions in binary form must reproduce the above copyright       *
- *    notice, this list of conditions and the following disclaimer in the     *
- *    documentation and/or other materials provided with the distribution.    *
- * 3. The name of the author may not be used to endorse or promote products   *
- *    derived from this software without specific prior written permission.   *
- *                                                                            *
- * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR       *
- * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES  *
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.    *
- * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,           *
- * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT   *
- * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,  *
- * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY      *
- * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT        *
- * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF   *
- * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.          *
- *----------------------------------------------------------------------------*/
-
-#include <stdio.h>
-#include <string.h>
-#include <ctype.h>
-
-#include "NwTypes.h"
-#include "NwLog.h"
-#include "NwUtils.h"
-#include "NwGtpv1uLog.h"
-#include "NwGtpv1u.h"
-#include "NwGtpv1uPrivate.h"
-#include "NwGtpv1uTrxn.h"
-
-/*--------------------------------------------------------------------------*
- *                 P R I V A T E  D E C L A R A T I O N S                   *
- *--------------------------------------------------------------------------*/
-
-#ifdef __cplusplus
-extern "C" {
-#endif
-
-static NwGtpv1uTrxnT *gpGtpv1uTrxnPool = NULL;
-
-/*--------------------------------------------------------------------------*
- *                   P R I V A T E      F U N C T I O N S                   *
- *--------------------------------------------------------------------------*/
-
-/*---------------------------------------------------------------------------
- * Send msg retransmission to peer via data request to UDP Entity
- *--------------------------------------------------------------------------*/
-
-static NwGtpv1uRcT
-nwGtpv1uTrxnSendMsgRetransmission(NwGtpv1uTrxnT *thiz)
-{
-  NwGtpv1uRcT rc;
-
-  NW_ASSERT(thiz);
-  NW_ASSERT(thiz->pMsg);
-
-  rc = thiz->pStack->udp.udpDataReqCallback(thiz->pStack->udp.hUdp,
-       thiz->pMsg->msgBuf,
-       thiz->pMsg->msgLen,
-       thiz->pMsg->msgBufOffset,
-       thiz->peerIp,
-       thiz->peerPort);
-
-  return rc;
-}
-
-static NwGtpv1uRcT
-nwGtpv1uTrxnPeerRspTimeout(void *arg)
-{
-  NwGtpv1uRcT rc = NW_GTPV1U_OK;
-  NwGtpv1uTrxnT *thiz;
-  NwGtpv1uStackT *pStack;
-  NwGtpv1uTimeoutInfoT *timeoutInfo = arg;
-
-  thiz = ((NwGtpv1uTrxnT *)timeoutInfo->timeoutArg);
-  pStack = thiz->pStack;
-
-  NW_ASSERT(pStack);
-
-  NW_LOG(pStack, NW_LOG_LEVEL_WARN, "T3 timer expired for transaction 0x%p",
-         thiz);
-
-  rc = nwGtpv1uTrxnSendMsgRetransmission(thiz);
-
-  if(thiz->maxRetries) {
-    rc = pStack->tmrMgr.tmrStartCallback(pStack->tmrMgr.tmrMgrHandle,
-                                         thiz->t3Timer, 0, NW_GTPV1U_TMR_TYPE_ONE_SHOT, (void *)timeoutInfo,
-                                         &thiz->hRspTmr);
-    thiz->maxRetries--;
-  } else {
-    NwGtpv1uUlpApiT ulpApi;
-    ulpApi.apiType                      = NW_GTPV1U_ULP_API_RSP_FAILURE;
-    ulpApi.apiInfo.recvMsgInfo.msgType  = nwGtpv1uMsgGetMsgType((
-                                            NwGtpv1uMsgHandleT)thiz->pMsg);
-    ulpApi.apiInfo.recvMsgInfo.hUlpTrxn = thiz->hUlpTrxn;
-    ulpApi.apiInfo.recvMsgInfo.peerIp   = thiz->peerIp;
-    ulpApi.apiInfo.recvMsgInfo.peerPort = thiz->peerPort;
-    thiz->hRspTmr = 0;
-
-    rc = nwGtpv1uTrxnDelete(&thiz);
-    NW_ASSERT(rc == NW_GTPV1U_OK);
-
-    rc = pStack->ulp.ulpReqCallback(pStack->ulp.hUlp, &ulpApi);
-    NW_ASSERT(rc == NW_GTPV1U_OK);
-  }
-
-  return rc;
-}
-
-/**
-  Send timer start request to TmrMgr Entity.
-
-  @param[in] thiz : Pointer to transaction
-  @param[in] timeoutCallbackFunc : Timeout handler callback function.
-  @return NW_GTPV1U_OK on success.
- */
-
-static NwGtpv1uRcT
-nwGtpv1uTrxnStartPeerRspTimer(NwGtpv1uTrxnT *thiz,
-                              NwGtpv1uRcT (*timeoutCallbackFunc)(void *))
-{
-  NwGtpv1uRcT rc;
-  NwGtpv1uTimeoutInfoT *timeoutInfo;
-
-  NW_ASSERT(thiz->pStack->tmrMgr.tmrStartCallback != NULL);
-
-  timeoutInfo                           = &thiz->peerRspTimeoutInfo;
-  timeoutInfo->timeoutArg               = thiz;
-  timeoutInfo->timeoutCallbackFunc      = timeoutCallbackFunc;
-  timeoutInfo->hStack                   = (NwGtpv1uStackHandleT)thiz->pStack;
-
-  rc = thiz->pStack->tmrMgr.tmrStartCallback(thiz->pStack->tmrMgr.tmrMgrHandle,
-       thiz->t3Timer, 0, NW_GTPV1U_TMR_TYPE_ONE_SHOT, (void *)timeoutInfo,
-       &thiz->hRspTmr);
-
-  return rc;
-}
-
-/**
-  Send timer stop request to TmrMgr Entity.
-
-  @param[in] thiz : Pointer to transaction
-  @return NW_GTPV1U_OK on success.
- */
-
-static NwGtpv1uRcT
-nwGtpv1uTrxnStopPeerRspTimer(NwGtpv1uTrxnT *thiz)
-{
-  NwGtpv1uRcT rc;
-
-  NW_ASSERT(thiz->pStack->tmrMgr.tmrStopCallback != NULL);
-
-  rc = thiz->pStack->tmrMgr.tmrStopCallback(thiz->pStack->tmrMgr.tmrMgrHandle,
-       thiz->hRspTmr);
-
-  thiz->hRspTmr = 0;
-
-  return rc;
-}
-
-/*--------------------------------------------------------------------------*
- *                      P U B L I C    F U N C T I O N S                    *
- *--------------------------------------------------------------------------*/
-
-/**
- * Constructor
- *
- * @param[in] thiz : Pointer to stack
- * @param[out] ppTrxn : Pointer to pointer to Trxn object.
- * @return NW_GTPV1U_OK on success.
- */
-NwGtpv1uRcT
-nwGtpv1uTrxnNew( NW_IN  NwGtpv1uStackT *thiz,
-                 NW_OUT NwGtpv1uTrxnT **ppTrxn)
-{
-  NwGtpv1uRcT rc = NW_GTPV1U_OK;
-  NwGtpv1uTrxnT *pTrxn;
-
-  if(gpGtpv1uTrxnPool) {
-    pTrxn = gpGtpv1uTrxnPool;
-    gpGtpv1uTrxnPool = gpGtpv1uTrxnPool->next;
-  } else {
-    NW_GTPV1U_MALLOC(thiz, sizeof(NwGtpv1uTrxnT), pTrxn, NwGtpv1uTrxnT *);
-  }
-
-  if (pTrxn) {
-    pTrxn->maxRetries   = 2;
-    pTrxn->pStack       = thiz;
-    pTrxn->t3Timer      = 2;
-    pTrxn->seqNum       = thiz->seq;
-
-    /* Increment sequence number */
-    thiz->seq++;
-
-    if(thiz->seq == 0x800000) {
-      thiz->seq = 0;
-    }
-
-  } else {
-    rc = NW_GTPV1U_FAILURE;
-  }
-
-  NW_LOG(thiz, NW_LOG_LEVEL_DEBG, "Created transaction 0x%p", pTrxn);
-
-  *ppTrxn = pTrxn;
-
-  return rc;
-}
-
-/**
- * Overloaded Constructor
- *
- * @param[in] thiz : Pointer to stack.
- * @param[in] seqNum : Sequence number for this transaction.
- * @param[out] ppTrxn : Pointer to pointer to Trxn object.
- * @return NW_GTPV1U_OK on success.
- */
-NwGtpv1uRcT
-nwGtpv1uTrxnWithSeqNew( NW_IN  NwGtpv1uStackT *thiz,
-                        NW_IN  uint32_t seqNum,
-                        NW_OUT NwGtpv1uTrxnT **ppTrxn)
-{
-  NwGtpv1uRcT rc = NW_GTPV1U_OK;
-  NwGtpv1uTrxnT *pTrxn;
-
-  if(gpGtpv1uTrxnPool) {
-    pTrxn = gpGtpv1uTrxnPool;
-    gpGtpv1uTrxnPool = gpGtpv1uTrxnPool->next;
-  } else {
-    NW_GTPV1U_MALLOC(thiz, sizeof(NwGtpv1uTrxnT), pTrxn, NwGtpv1uTrxnT *);
-  }
-
-
-  if (pTrxn) {
-    pTrxn->maxRetries   = 2;
-    pTrxn->pStack       = thiz;
-    pTrxn->t3Timer      = 2;
-    pTrxn->seqNum       = seqNum;
-    pTrxn->pMsg         = NULL;
-  } else {
-    rc = NW_GTPV1U_FAILURE;
-  }
-
-  NW_LOG(thiz, NW_LOG_LEVEL_DEBG, "Created transaction 0x%p", pTrxn);
-
-  *ppTrxn = pTrxn;
-
-  return rc;
-}
-
-/**
- * Destructor
- *
- * @param[out] pthiz : Pointer to pointer to Trxn object.
- * @return NW_GTPV1U_OK on success.
- */
-NwGtpv1uRcT
-nwGtpv1uTrxnDelete( NW_INOUT NwGtpv1uTrxnT **pthiz)
-{
-  NwGtpv1uRcT rc = NW_GTPV1U_OK;
-  NwGtpv1uStackT *pStack;
-  NwGtpv1uTrxnT *thiz = *pthiz;
-
-  pStack = thiz->pStack;
-
-  if(thiz->hRspTmr) {
-    rc = nwGtpv1uTrxnStopPeerRspTimer(thiz);
-    NW_ASSERT(rc == NW_GTPV1U_OK);
-  }
-
-  if(thiz->pMsg) {
-    rc = nwGtpv1uMsgDelete((NwGtpv1uStackHandleT)pStack,
-                           (NwGtpv1uMsgHandleT)thiz->pMsg);
-    NW_ASSERT(rc == NW_GTPV1U_OK);
-  }
-
-  thiz->next = gpGtpv1uTrxnPool;
-  gpGtpv1uTrxnPool = thiz;
-
-  NW_LOG(pStack, NW_LOG_LEVEL_DEBG, "Purged transaction 0x%p", thiz);
-
-  *pthiz = NULL;
-  return rc;
-}
-
-
-#if 1
-/**
- * Send msg to peer via data request to UDP Entity
- *
- * @param[in] thiz : Pointer to stack.
- * @param[in] pTrxn : Pointer to Trxn object.
- * @param[in] peerIp : Peer Ip address.
- * @param[in] peerPort : Peer Ip port.
- * @param[in] pMsg : Message to be sent.
- * @return NW_GTPV1U_OK on success.
- */
-NwGtpv1uRcT
-nwGtpv1uTrxnCreateAndSendMsg( NW_IN  NwGtpv1uStackT *thiz,
-                              NW_IN  NwGtpv1uTrxnT *pTrxn,
-                              NW_IN  uint32_t peerIp,
-                              NW_IN  uint32_t peerPort,
-                              NW_IN  NwGtpv1uMsgT *pMsg)
-{
-  NwGtpv1uRcT rc;
-  uint8_t *msgHdr;
-
-  NW_ASSERT(thiz);
-  NW_ASSERT(pMsg);
-
-  msgHdr = &pMsg->msgBuf[pMsg->msgBufOffset];
-
-  NW_ASSERT(msgHdr != NULL);
-
-  *(msgHdr++)         = (pMsg->version << 5)            |
-                        (pMsg->protocolType << 4)       |
-                        (pMsg->extHdrFlag << 2)         |
-                        (pMsg->seqNumFlag << 1)         |
-                        (pMsg->npduNumFlag);
-
-  *(msgHdr++)         = (pMsg->msgType);
-  *((uint16_t *) msgHdr) = htons(pMsg->msgLen);
-  msgHdr += 2;
-
-  *((uint32_t *) msgHdr) = htonl(pMsg->teid);
-  msgHdr += 4;
-
-  if(pMsg->seqNumFlag | pMsg->extHdrFlag | pMsg->npduNumFlag) {
-    if(pMsg->seqNumFlag) {
-      *((uint16_t *) msgHdr) = htons((pTrxn ? pTrxn->seqNum : pMsg->seqNum));
-    } else {
-      *((uint16_t *) msgHdr) = 0x0000;
-    }
-
-    msgHdr += 2;
-
-    if(pMsg->npduNumFlag) {
-      *((uint8_t *) msgHdr) = pMsg->npduNumFlag;
-    } else {
-      *((uint8_t *) msgHdr) = 0x00;
-    }
-
-    msgHdr++;
-
-    if(pMsg->extHdrFlag) {
-      *((uint8_t *) msgHdr) = pMsg->extHdrFlag;
-    } else {
-      *((uint8_t *) msgHdr) = 0x00;
-    }
-
-    msgHdr++;
-  }
-
-  NW_ASSERT(thiz->udp.udpDataReqCallback != NULL);
-
-  rc = thiz->udp.udpDataReqCallback(thiz->udp.hUdp,
-                                    pMsg->msgBuf,
-                                    pMsg->msgLen,
-                                    pMsg->msgBufOffset,
-                                    peerIp,
-                                    peerPort);
-
-  /* Save the message for retransmission */
-  if(rc == NW_GTPV1U_OK && pTrxn) {
-    pTrxn->pMsg         = pMsg;
-    pTrxn->peerIp       = peerIp;
-    pTrxn->peerPort     = peerPort;
-
-    rc = nwGtpv1uTrxnStartPeerRspTimer(pTrxn, nwGtpv1uTrxnPeerRspTimeout);
-    NW_ASSERT(rc == NW_GTPV1U_OK);
-  }
-
-  return rc;
-}
-#endif
-
-
-#ifdef __cplusplus
-}
-#endif
-
-/*--------------------------------------------------------------------------*
- *                          E N D   O F   F I L E                           *
- *--------------------------------------------------------------------------*/
diff --git a/openair3/GTPV1-U/nw-gtpv1u/src/NwGtpv1uTunnelEndPoint.c b/openair3/GTPV1-U/nw-gtpv1u/src/NwGtpv1uTunnelEndPoint.c
deleted file mode 100644
index c62f60edc29..00000000000
--- a/openair3/GTPV1-U/nw-gtpv1u/src/NwGtpv1uTunnelEndPoint.c
+++ /dev/null
@@ -1,135 +0,0 @@
-/*----------------------------------------------------------------------------*
- *                                                                            *
- *                             n w - g t p v 2 u                              *
- *    G P R S    T u n n e l i n g    P r o t o c o l   v 2 u   S t a c k     *
- *                                                                            *
- *                                                                            *
- * Copyright (c) 2010-2011 Amit Chawre                                        *
- * All rights reserved.                                                       *
- *                                                                            *
- * Redistribution and use in source and binary forms, with or without         *
- * modification, are permitted provided that the following conditions         *
- * are met:                                                                   *
- *                                                                            *
- * 1. Redistributions of source code must retain the above copyright          *
- *    notice, this list of conditions and the following disclaimer.           *
- * 2. Redistributions in binary form must reproduce the above copyright       *
- *    notice, this list of conditions and the following disclaimer in the     *
- *    documentation and/or other materials provided with the distribution.    *
- * 3. The name of the author may not be used to endorse or promote products   *
- *    derived from this software without specific prior written permission.   *
- *                                                                            *
- * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR       *
- * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES  *
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.    *
- * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,           *
- * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT   *
- * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,  *
- * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY      *
- * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT        *
- * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF   *
- * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.          *
- *----------------------------------------------------------------------------*/
-
-#include <stdio.h>
-#include <stdlib.h>
-#include <string.h>
-
-#include "NwTypes.h"
-#include "NwUtils.h"
-#include "NwGtpv1uError.h"
-#include "NwGtpv1uPrivate.h"
-#include "NwGtpv1uMsg.h"
-#include "NwGtpv1uTunnelEndPoint.h"
-#include "NwGtpv1u.h"
-#include "NwGtpv1uLog.h"
-
-#ifdef __cplusplus
-extern "C" {
-#endif
-
-/*--------------------------------------------------------------------------*
- *                  P R I V A T E   D E C L A R A T I O N S                 *
- *--------------------------------------------------------------------------*/
-
-static NwGtpv1uTunnelEndPointT *gpTunnelEndPointPool = NULL;
-
-/*--------------------------------------------------------------------------*
- *                     P U B L I C   F U N C T I O N S                      *
- *--------------------------------------------------------------------------*/
-
-/**
-  Constructor
-
-  @param[in] msid: MSID
-  @param[in] peerAddr: Address of the peer.
-  @return Pointer to Session on success, NULL on failure.
- */
-
-
-NwGtpv1uTunnelEndPointT *
-nwGtpTunnelEndPointNew(struct NwGtpv1uStack *pStack)
-{
-  NwGtpv1uTunnelEndPointT *thiz;
-
-  if(gpTunnelEndPointPool) {
-    thiz = gpTunnelEndPointPool;
-    gpTunnelEndPointPool = gpTunnelEndPointPool->next;
-  } else {
-    NW_GTPV1U_MALLOC(pStack, sizeof(NwGtpv1uTunnelEndPointT), thiz,
-                     NwGtpv1uTunnelEndPointT *);
-  }
-
-  return thiz;
-}
-
-/**
-  Destructor
-
-  @param[in] thiz: Pointer to session
-  @return NW_GTPV1U_OK on success.
- */
-
-NwGtpv1uRcT
-nwGtpTunnelEndPointDestroy(struct NwGtpv1uStack *pStack,
-                           NwGtpv1uTunnelEndPointT *thiz)
-{
-  thiz->next = gpTunnelEndPointPool;
-  gpTunnelEndPointPool = thiz;
-  return NW_GTPV1U_OK;
-}
-
-/**
-  Purge a Transaction for a Session.
-
-  @param[in] thiz: Pointer to session
-  @param[in,out] pTrxn: Pointer to the trxn.
-  @return NW_GTPV1U_OK on success.
- */
-
-NwGtpv1uRcT
-nwGtpSessionSendMsgApiToUlpEntity(NwGtpv1uTunnelEndPointT *thiz,
-                                  NwGtpv1uMsgT *pMsg)
-{
-  NwGtpv1uRcT rc = NW_GTPV1U_OK;
-  NwGtpv1uUlpApiT api;
-
-  api.apiType                         = NW_GTPV1U_ULP_API_RECV_TPDU;
-  api.apiInfo.recvMsgInfo.hUlpSession = thiz->hUlpSession;
-  api.apiInfo.recvMsgInfo.teid        = thiz->teid;
-  api.apiInfo.recvMsgInfo.hMsg        = (NwGtpv1uMsgHandleT)pMsg;
-
-  NW_ASSERT(thiz->pStack->ulp.ulpReqCallback != NULL);
-
-  thiz->pStack->ulp.ulpReqCallback(thiz->pStack->ulp.hUlp, &api);
-
-  return rc;
-}
-
-#ifdef __cplusplus
-}
-#endif
-
-/*--------------------------------------------------------------------------*
- *                      E N D     O F    F I L E                            *
- *--------------------------------------------------------------------------*/
diff --git a/openair3/GTPV1-U/nw-gtpv1u/test-app/Makefile.am b/openair3/GTPV1-U/nw-gtpv1u/test-app/Makefile.am
deleted file mode 100644
index 69b8e698e9a..00000000000
--- a/openair3/GTPV1-U/nw-gtpv1u/test-app/Makefile.am
+++ /dev/null
@@ -1,5 +0,0 @@
-# this is example-file: Makefile.am
-
-# the subdirectories of the project to go into
-SUBDIRS =   \
-           nw-helloworld
diff --git a/openair3/GTPV1-U/nw-gtpv1u/test-app/Makefile.in b/openair3/GTPV1-U/nw-gtpv1u/test-app/Makefile.in
deleted file mode 100644
index 46928b9e3cf..00000000000
--- a/openair3/GTPV1-U/nw-gtpv1u/test-app/Makefile.in
+++ /dev/null
@@ -1,461 +0,0 @@
-# Makefile.in generated by automake 1.10.1 from Makefile.am.
-# @configure_input@
-
-# Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002,
-# 2003, 2004, 2005, 2006, 2007, 2008  Free Software Foundation, Inc.
-# This Makefile.in is free software; the Free Software Foundation
-# gives unlimited permission to copy and/or distribute it,
-# with or without modifications, as long as this notice is preserved.
-
-# This program is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY, to the extent permitted by law; without
-# even the implied warranty of MERCHANTABILITY or FITNESS FOR A
-# PARTICULAR PURPOSE.
-
-@SET_MAKE@
-
-# this is example-file: Makefile.am
-VPATH = @srcdir@
-pkgdatadir = $(datadir)/@PACKAGE@
-pkglibdir = $(libdir)/@PACKAGE@
-pkgincludedir = $(includedir)/@PACKAGE@
-am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd
-install_sh_DATA = $(install_sh) -c -m 644
-install_sh_PROGRAM = $(install_sh) -c
-install_sh_SCRIPT = $(install_sh) -c
-INSTALL_HEADER = $(INSTALL_DATA)
-transform = $(program_transform_name)
-NORMAL_INSTALL = :
-PRE_INSTALL = :
-POST_INSTALL = :
-NORMAL_UNINSTALL = :
-PRE_UNINSTALL = :
-POST_UNINSTALL = :
-subdir = nw-gtpv1u/test-app
-DIST_COMMON = $(srcdir)/Makefile.am $(srcdir)/Makefile.in
-ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
-am__aclocal_m4_deps = $(top_srcdir)/configure.ac
-am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
-	$(ACLOCAL_M4)
-mkinstalldirs = $(install_sh) -d
-CONFIG_CLEAN_FILES =
-SOURCES =
-DIST_SOURCES =
-RECURSIVE_TARGETS = all-recursive check-recursive dvi-recursive \
-	html-recursive info-recursive install-data-recursive \
-	install-dvi-recursive install-exec-recursive \
-	install-html-recursive install-info-recursive \
-	install-pdf-recursive install-ps-recursive install-recursive \
-	installcheck-recursive installdirs-recursive pdf-recursive \
-	ps-recursive uninstall-recursive
-RECURSIVE_CLEAN_TARGETS = mostlyclean-recursive clean-recursive	\
-  distclean-recursive maintainer-clean-recursive
-ETAGS = etags
-CTAGS = ctags
-DIST_SUBDIRS = $(SUBDIRS)
-DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
-ACLOCAL = @ACLOCAL@
-AMTAR = @AMTAR@
-AM_CFLAGS = @AM_CFLAGS@
-AM_LDFLAGS = @AM_LDFLAGS@
-AUTOCONF = @AUTOCONF@
-AUTOHEADER = @AUTOHEADER@
-AUTOMAKE = @AUTOMAKE@
-AWK = @AWK@
-CC = @CC@
-CCDEPMODE = @CCDEPMODE@
-CFLAGS = @CFLAGS@
-CPP = @CPP@
-CPPFLAGS = @CPPFLAGS@
-CXX = @CXX@
-CXXCPP = @CXXCPP@
-CXXDEPMODE = @CXXDEPMODE@
-CXXFLAGS = @CXXFLAGS@
-CYGPATH_W = @CYGPATH_W@
-DEFS = @DEFS@
-DEPDIR = @DEPDIR@
-ECHO_C = @ECHO_C@
-ECHO_N = @ECHO_N@
-ECHO_T = @ECHO_T@
-EGREP = @EGREP@
-EXEEXT = @EXEEXT@
-GREP = @GREP@
-INSTALL = @INSTALL@
-INSTALL_DATA = @INSTALL_DATA@
-INSTALL_PROGRAM = @INSTALL_PROGRAM@
-INSTALL_SCRIPT = @INSTALL_SCRIPT@
-INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@
-LDFLAGS = @LDFLAGS@
-LIBOBJS = @LIBOBJS@
-LIBS = @LIBS@
-LTLIBOBJS = @LTLIBOBJS@
-MAKEINFO = @MAKEINFO@
-MKDIR_P = @MKDIR_P@
-OBJEXT = @OBJEXT@
-PACKAGE = @PACKAGE@
-PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@
-PACKAGE_NAME = @PACKAGE_NAME@
-PACKAGE_STRING = @PACKAGE_STRING@
-PACKAGE_TARNAME = @PACKAGE_TARNAME@
-PACKAGE_VERSION = @PACKAGE_VERSION@
-PATH_SEPARATOR = @PATH_SEPARATOR@
-RANLIB = @RANLIB@
-SET_MAKE = @SET_MAKE@
-SHELL = @SHELL@
-STRIP = @STRIP@
-VERSION = @VERSION@
-abs_builddir = @abs_builddir@
-abs_srcdir = @abs_srcdir@
-abs_top_builddir = @abs_top_builddir@
-abs_top_srcdir = @abs_top_srcdir@
-ac_ct_CC = @ac_ct_CC@
-ac_ct_CXX = @ac_ct_CXX@
-am__include = @am__include@
-am__leading_dot = @am__leading_dot@
-am__quote = @am__quote@
-am__tar = @am__tar@
-am__untar = @am__untar@
-bindir = @bindir@
-build_alias = @build_alias@
-builddir = @builddir@
-datadir = @datadir@
-datarootdir = @datarootdir@
-docdir = @docdir@
-dvidir = @dvidir@
-exec_prefix = @exec_prefix@
-host_alias = @host_alias@
-htmldir = @htmldir@
-includedir = @includedir@
-infodir = @infodir@
-install_sh = @install_sh@
-libdir = @libdir@
-libexecdir = @libexecdir@
-localedir = @localedir@
-localstatedir = @localstatedir@
-mandir = @mandir@
-mkdir_p = @mkdir_p@
-oldincludedir = @oldincludedir@
-pdfdir = @pdfdir@
-prefix = @prefix@
-program_transform_name = @program_transform_name@
-psdir = @psdir@
-sbindir = @sbindir@
-sharedstatedir = @sharedstatedir@
-srcdir = @srcdir@
-sysconfdir = @sysconfdir@
-target_alias = @target_alias@
-top_builddir = @top_builddir@
-top_srcdir = @top_srcdir@
-
-# the subdirectories of the project to go into
-SUBDIRS = \
-           nw-helloworld
-
-all: all-recursive
-
-.SUFFIXES:
-$(srcdir)/Makefile.in:  $(srcdir)/Makefile.am  $(am__configure_deps)
-	@for dep in $?; do \
-	  case '$(am__configure_deps)' in \
-	    *$$dep*) \
-	      cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh \
-		&& exit 0; \
-	      exit 1;; \
-	  esac; \
-	done; \
-	echo ' cd $(top_srcdir) && $(AUTOMAKE) --gnu  nw-gtpv1u/test-app/Makefile'; \
-	cd $(top_srcdir) && \
-	  $(AUTOMAKE) --gnu  nw-gtpv1u/test-app/Makefile
-.PRECIOUS: Makefile
-Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status
-	@case '$?' in \
-	  *config.status*) \
-	    cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \
-	  *) \
-	    echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe)'; \
-	    cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe);; \
-	esac;
-
-$(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES)
-	cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
-
-$(top_srcdir)/configure:  $(am__configure_deps)
-	cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
-$(ACLOCAL_M4):  $(am__aclocal_m4_deps)
-	cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
-
-# This directory's subdirectories are mostly independent; you can cd
-# into them and run `make' without going through this Makefile.
-# To change the values of `make' variables: instead of editing Makefiles,
-# (1) if the variable is set in `config.status', edit `config.status'
-#     (which will cause the Makefiles to be regenerated when you run `make');
-# (2) otherwise, pass the desired values on the `make' command line.
-$(RECURSIVE_TARGETS):
-	@failcom='exit 1'; \
-	for f in x $$MAKEFLAGS; do \
-	  case $$f in \
-	    *=* | --[!k]*);; \
-	    *k*) failcom='fail=yes';; \
-	  esac; \
-	done; \
-	dot_seen=no; \
-	target=`echo $@ | sed s/-recursive//`; \
-	list='$(SUBDIRS)'; for subdir in $$list; do \
-	  echo "Making $$target in $$subdir"; \
-	  if test "$$subdir" = "."; then \
-	    dot_seen=yes; \
-	    local_target="$$target-am"; \
-	  else \
-	    local_target="$$target"; \
-	  fi; \
-	  (cd $$subdir && $(MAKE) $(AM_MAKEFLAGS) $$local_target) \
-	  || eval $$failcom; \
-	done; \
-	if test "$$dot_seen" = "no"; then \
-	  $(MAKE) $(AM_MAKEFLAGS) "$$target-am" || exit 1; \
-	fi; test -z "$$fail"
-
-$(RECURSIVE_CLEAN_TARGETS):
-	@failcom='exit 1'; \
-	for f in x $$MAKEFLAGS; do \
-	  case $$f in \
-	    *=* | --[!k]*);; \
-	    *k*) failcom='fail=yes';; \
-	  esac; \
-	done; \
-	dot_seen=no; \
-	case "$@" in \
-	  distclean-* | maintainer-clean-*) list='$(DIST_SUBDIRS)' ;; \
-	  *) list='$(SUBDIRS)' ;; \
-	esac; \
-	rev=''; for subdir in $$list; do \
-	  if test "$$subdir" = "."; then :; else \
-	    rev="$$subdir $$rev"; \
-	  fi; \
-	done; \
-	rev="$$rev ."; \
-	target=`echo $@ | sed s/-recursive//`; \
-	for subdir in $$rev; do \
-	  echo "Making $$target in $$subdir"; \
-	  if test "$$subdir" = "."; then \
-	    local_target="$$target-am"; \
-	  else \
-	    local_target="$$target"; \
-	  fi; \
-	  (cd $$subdir && $(MAKE) $(AM_MAKEFLAGS) $$local_target) \
-	  || eval $$failcom; \
-	done && test -z "$$fail"
-tags-recursive:
-	list='$(SUBDIRS)'; for subdir in $$list; do \
-	  test "$$subdir" = . || (cd $$subdir && $(MAKE) $(AM_MAKEFLAGS) tags); \
-	done
-ctags-recursive:
-	list='$(SUBDIRS)'; for subdir in $$list; do \
-	  test "$$subdir" = . || (cd $$subdir && $(MAKE) $(AM_MAKEFLAGS) ctags); \
-	done
-
-ID: $(HEADERS) $(SOURCES) $(LISP) $(TAGS_FILES)
-	list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \
-	unique=`for i in $$list; do \
-	    if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
-	  done | \
-	  $(AWK) '{ files[$$0] = 1; nonemtpy = 1; } \
-	      END { if (nonempty) { for (i in files) print i; }; }'`; \
-	mkid -fID $$unique
-tags: TAGS
-
-TAGS: tags-recursive $(HEADERS) $(SOURCES)  $(TAGS_DEPENDENCIES) \
-		$(TAGS_FILES) $(LISP)
-	tags=; \
-	here=`pwd`; \
-	if ($(ETAGS) --etags-include --version) >/dev/null 2>&1; then \
-	  include_option=--etags-include; \
-	  empty_fix=.; \
-	else \
-	  include_option=--include; \
-	  empty_fix=; \
-	fi; \
-	list='$(SUBDIRS)'; for subdir in $$list; do \
-	  if test "$$subdir" = .; then :; else \
-	    test ! -f $$subdir/TAGS || \
-	      tags="$$tags $$include_option=$$here/$$subdir/TAGS"; \
-	  fi; \
-	done; \
-	list='$(SOURCES) $(HEADERS)  $(LISP) $(TAGS_FILES)'; \
-	unique=`for i in $$list; do \
-	    if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
-	  done | \
-	  $(AWK) '{ files[$$0] = 1; nonempty = 1; } \
-	      END { if (nonempty) { for (i in files) print i; }; }'`; \
-	if test -z "$(ETAGS_ARGS)$$tags$$unique"; then :; else \
-	  test -n "$$unique" || unique=$$empty_fix; \
-	  $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \
-	    $$tags $$unique; \
-	fi
-ctags: CTAGS
-CTAGS: ctags-recursive $(HEADERS) $(SOURCES)  $(TAGS_DEPENDENCIES) \
-		$(TAGS_FILES) $(LISP)
-	tags=; \
-	list='$(SOURCES) $(HEADERS)  $(LISP) $(TAGS_FILES)'; \
-	unique=`for i in $$list; do \
-	    if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
-	  done | \
-	  $(AWK) '{ files[$$0] = 1; nonempty = 1; } \
-	      END { if (nonempty) { for (i in files) print i; }; }'`; \
-	test -z "$(CTAGS_ARGS)$$tags$$unique" \
-	  || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \
-	     $$tags $$unique
-
-GTAGS:
-	here=`$(am__cd) $(top_builddir) && pwd` \
-	  && cd $(top_srcdir) \
-	  && gtags -i $(GTAGS_ARGS) $$here
-
-distclean-tags:
-	-rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
-
-distdir: $(DISTFILES)
-	@srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
-	topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
-	list='$(DISTFILES)'; \
-	  dist_files=`for file in $$list; do echo $$file; done | \
-	  sed -e "s|^$$srcdirstrip/||;t" \
-	      -e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \
-	case $$dist_files in \
-	  */*) $(MKDIR_P) `echo "$$dist_files" | \
-			   sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \
-			   sort -u` ;; \
-	esac; \
-	for file in $$dist_files; do \
-	  if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \
-	  if test -d $$d/$$file; then \
-	    dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \
-	    if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \
-	      cp -pR $(srcdir)/$$file $(distdir)$$dir || exit 1; \
-	    fi; \
-	    cp -pR $$d/$$file $(distdir)$$dir || exit 1; \
-	  else \
-	    test -f $(distdir)/$$file \
-	    || cp -p $$d/$$file $(distdir)/$$file \
-	    || exit 1; \
-	  fi; \
-	done
-	list='$(DIST_SUBDIRS)'; for subdir in $$list; do \
-	  if test "$$subdir" = .; then :; else \
-	    test -d "$(distdir)/$$subdir" \
-	    || $(MKDIR_P) "$(distdir)/$$subdir" \
-	    || exit 1; \
-	    distdir=`$(am__cd) $(distdir) && pwd`; \
-	    top_distdir=`$(am__cd) $(top_distdir) && pwd`; \
-	    (cd $$subdir && \
-	      $(MAKE) $(AM_MAKEFLAGS) \
-	        top_distdir="$$top_distdir" \
-	        distdir="$$distdir/$$subdir" \
-		am__remove_distdir=: \
-		am__skip_length_check=: \
-	        distdir) \
-	      || exit 1; \
-	  fi; \
-	done
-check-am: all-am
-check: check-recursive
-all-am: Makefile
-installdirs: installdirs-recursive
-installdirs-am:
-install: install-recursive
-install-exec: install-exec-recursive
-install-data: install-data-recursive
-uninstall: uninstall-recursive
-
-install-am: all-am
-	@$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am
-
-installcheck: installcheck-recursive
-install-strip:
-	$(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \
-	  install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \
-	  `test -z '$(STRIP)' || \
-	    echo "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'"` install
-mostlyclean-generic:
-
-clean-generic:
-
-distclean-generic:
-	-test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES)
-
-maintainer-clean-generic:
-	@echo "This command is intended for maintainers to use"
-	@echo "it deletes files that may require special tools to rebuild."
-clean: clean-recursive
-
-clean-am: clean-generic mostlyclean-am
-
-distclean: distclean-recursive
-	-rm -f Makefile
-distclean-am: clean-am distclean-generic distclean-tags
-
-dvi: dvi-recursive
-
-dvi-am:
-
-html: html-recursive
-
-info: info-recursive
-
-info-am:
-
-install-data-am:
-
-install-dvi: install-dvi-recursive
-
-install-exec-am:
-
-install-html: install-html-recursive
-
-install-info: install-info-recursive
-
-install-man:
-
-install-pdf: install-pdf-recursive
-
-install-ps: install-ps-recursive
-
-installcheck-am:
-
-maintainer-clean: maintainer-clean-recursive
-	-rm -f Makefile
-maintainer-clean-am: distclean-am maintainer-clean-generic
-
-mostlyclean: mostlyclean-recursive
-
-mostlyclean-am: mostlyclean-generic
-
-pdf: pdf-recursive
-
-pdf-am:
-
-ps: ps-recursive
-
-ps-am:
-
-uninstall-am:
-
-.MAKE: $(RECURSIVE_CLEAN_TARGETS) $(RECURSIVE_TARGETS) install-am \
-	install-strip
-
-.PHONY: $(RECURSIVE_CLEAN_TARGETS) $(RECURSIVE_TARGETS) CTAGS GTAGS \
-	all all-am check check-am clean clean-generic ctags \
-	ctags-recursive distclean distclean-generic distclean-tags \
-	distdir dvi dvi-am html html-am info info-am install \
-	install-am install-data install-data-am install-dvi \
-	install-dvi-am install-exec install-exec-am install-html \
-	install-html-am install-info install-info-am install-man \
-	install-pdf install-pdf-am install-ps install-ps-am \
-	install-strip installcheck installcheck-am installdirs \
-	installdirs-am maintainer-clean maintainer-clean-generic \
-	mostlyclean mostlyclean-generic pdf pdf-am ps ps-am tags \
-	tags-recursive uninstall uninstall-am
-
-# Tell versions [3.59,3.63) of GNU make to not export all variables.
-# Otherwise a system limit (for SysV at least) may be exceeded.
-.NOEXPORT:
diff --git a/openair3/GTPV1-U/nw-gtpv1u/test-app/nw-helloworld/Makefile.am b/openair3/GTPV1-U/nw-gtpv1u/test-app/nw-helloworld/Makefile.am
deleted file mode 100644
index f60cd93f555..00000000000
--- a/openair3/GTPV1-U/nw-gtpv1u/test-app/nw-helloworld/Makefile.am
+++ /dev/null
@@ -1,17 +0,0 @@
-bin_PROGRAMS = helloworld
-
-AM_CFLAGS = -D__WITH_LIBEVENT__ -I../../shared -I../../include -I../../test-app/nw-udp -I../../test-app/nw-log @AM_CFLAGS@
-
-helloworld_SOURCES =    \
-			NwEvt.h\
-			NwMiniLogMgrEntity.h\
-			NwMiniTmrMgrEntity.h\
-			NwMiniUlpEntity.h\
-			NwMiniUdpEntity.h\
-			NwMiniLogMgrEntity.c\
-			NwMiniTmrMgrEntity.c\
-			NwMiniUlpEntity.c\
-			NwMiniUdpEntity.c\
-                        helloworld.c
-
-helloworld_LDADD =  ../../src/libNwGtpv1u.a -levent $(AM_LDFLAGS)
diff --git a/openair3/GTPV1-U/nw-gtpv1u/test-app/nw-helloworld/Makefile.in b/openair3/GTPV1-U/nw-gtpv1u/test-app/nw-helloworld/Makefile.in
deleted file mode 100644
index 769d75c16bf..00000000000
--- a/openair3/GTPV1-U/nw-gtpv1u/test-app/nw-helloworld/Makefile.in
+++ /dev/null
@@ -1,433 +0,0 @@
-# Makefile.in generated by automake 1.10.1 from Makefile.am.
-# @configure_input@
-
-# Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002,
-# 2003, 2004, 2005, 2006, 2007, 2008  Free Software Foundation, Inc.
-# This Makefile.in is free software; the Free Software Foundation
-# gives unlimited permission to copy and/or distribute it,
-# with or without modifications, as long as this notice is preserved.
-
-# This program is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY, to the extent permitted by law; without
-# even the implied warranty of MERCHANTABILITY or FITNESS FOR A
-# PARTICULAR PURPOSE.
-
-@SET_MAKE@
-
-VPATH = @srcdir@
-pkgdatadir = $(datadir)/@PACKAGE@
-pkglibdir = $(libdir)/@PACKAGE@
-pkgincludedir = $(includedir)/@PACKAGE@
-am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd
-install_sh_DATA = $(install_sh) -c -m 644
-install_sh_PROGRAM = $(install_sh) -c
-install_sh_SCRIPT = $(install_sh) -c
-INSTALL_HEADER = $(INSTALL_DATA)
-transform = $(program_transform_name)
-NORMAL_INSTALL = :
-PRE_INSTALL = :
-POST_INSTALL = :
-NORMAL_UNINSTALL = :
-PRE_UNINSTALL = :
-POST_UNINSTALL = :
-bin_PROGRAMS = helloworld$(EXEEXT)
-subdir = nw-gtpv1u/test-app/nw-helloworld
-DIST_COMMON = $(srcdir)/Makefile.am $(srcdir)/Makefile.in
-ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
-am__aclocal_m4_deps = $(top_srcdir)/configure.ac
-am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
-	$(ACLOCAL_M4)
-mkinstalldirs = $(install_sh) -d
-CONFIG_CLEAN_FILES =
-am__installdirs = "$(DESTDIR)$(bindir)"
-binPROGRAMS_INSTALL = $(INSTALL_PROGRAM)
-PROGRAMS = $(bin_PROGRAMS)
-am_helloworld_OBJECTS = NwMiniLogMgrEntity.$(OBJEXT) \
-	NwMiniTmrMgrEntity.$(OBJEXT) NwMiniUlpEntity.$(OBJEXT) \
-	NwMiniUdpEntity.$(OBJEXT) helloworld.$(OBJEXT)
-helloworld_OBJECTS = $(am_helloworld_OBJECTS)
-am__DEPENDENCIES_1 =
-helloworld_DEPENDENCIES = ../../src/libNwGtpv1u.a \
-	$(am__DEPENDENCIES_1)
-DEFAULT_INCLUDES = -I.@am__isrc@
-depcomp = $(SHELL) $(top_srcdir)/depcomp
-am__depfiles_maybe = depfiles
-COMPILE = $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) \
-	$(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS)
-CCLD = $(CC)
-LINK = $(CCLD) $(AM_CFLAGS) $(CFLAGS) $(AM_LDFLAGS) $(LDFLAGS) -o $@
-SOURCES = $(helloworld_SOURCES)
-DIST_SOURCES = $(helloworld_SOURCES)
-ETAGS = etags
-CTAGS = ctags
-DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
-ACLOCAL = @ACLOCAL@
-AMTAR = @AMTAR@
-AM_CFLAGS = -D__WITH_LIBEVENT__ -I../../shared -I../../include -I../../test-app/nw-udp -I../../test-app/nw-log @AM_CFLAGS@
-AM_LDFLAGS = @AM_LDFLAGS@
-AUTOCONF = @AUTOCONF@
-AUTOHEADER = @AUTOHEADER@
-AUTOMAKE = @AUTOMAKE@
-AWK = @AWK@
-CC = @CC@
-CCDEPMODE = @CCDEPMODE@
-CFLAGS = @CFLAGS@
-CPP = @CPP@
-CPPFLAGS = @CPPFLAGS@
-CXX = @CXX@
-CXXCPP = @CXXCPP@
-CXXDEPMODE = @CXXDEPMODE@
-CXXFLAGS = @CXXFLAGS@
-CYGPATH_W = @CYGPATH_W@
-DEFS = @DEFS@
-DEPDIR = @DEPDIR@
-ECHO_C = @ECHO_C@
-ECHO_N = @ECHO_N@
-ECHO_T = @ECHO_T@
-EGREP = @EGREP@
-EXEEXT = @EXEEXT@
-GREP = @GREP@
-INSTALL = @INSTALL@
-INSTALL_DATA = @INSTALL_DATA@
-INSTALL_PROGRAM = @INSTALL_PROGRAM@
-INSTALL_SCRIPT = @INSTALL_SCRIPT@
-INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@
-LDFLAGS = @LDFLAGS@
-LIBOBJS = @LIBOBJS@
-LIBS = @LIBS@
-LTLIBOBJS = @LTLIBOBJS@
-MAKEINFO = @MAKEINFO@
-MKDIR_P = @MKDIR_P@
-OBJEXT = @OBJEXT@
-PACKAGE = @PACKAGE@
-PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@
-PACKAGE_NAME = @PACKAGE_NAME@
-PACKAGE_STRING = @PACKAGE_STRING@
-PACKAGE_TARNAME = @PACKAGE_TARNAME@
-PACKAGE_VERSION = @PACKAGE_VERSION@
-PATH_SEPARATOR = @PATH_SEPARATOR@
-RANLIB = @RANLIB@
-SET_MAKE = @SET_MAKE@
-SHELL = @SHELL@
-STRIP = @STRIP@
-VERSION = @VERSION@
-abs_builddir = @abs_builddir@
-abs_srcdir = @abs_srcdir@
-abs_top_builddir = @abs_top_builddir@
-abs_top_srcdir = @abs_top_srcdir@
-ac_ct_CC = @ac_ct_CC@
-ac_ct_CXX = @ac_ct_CXX@
-am__include = @am__include@
-am__leading_dot = @am__leading_dot@
-am__quote = @am__quote@
-am__tar = @am__tar@
-am__untar = @am__untar@
-bindir = @bindir@
-build_alias = @build_alias@
-builddir = @builddir@
-datadir = @datadir@
-datarootdir = @datarootdir@
-docdir = @docdir@
-dvidir = @dvidir@
-exec_prefix = @exec_prefix@
-host_alias = @host_alias@
-htmldir = @htmldir@
-includedir = @includedir@
-infodir = @infodir@
-install_sh = @install_sh@
-libdir = @libdir@
-libexecdir = @libexecdir@
-localedir = @localedir@
-localstatedir = @localstatedir@
-mandir = @mandir@
-mkdir_p = @mkdir_p@
-oldincludedir = @oldincludedir@
-pdfdir = @pdfdir@
-prefix = @prefix@
-program_transform_name = @program_transform_name@
-psdir = @psdir@
-sbindir = @sbindir@
-sharedstatedir = @sharedstatedir@
-srcdir = @srcdir@
-sysconfdir = @sysconfdir@
-target_alias = @target_alias@
-top_builddir = @top_builddir@
-top_srcdir = @top_srcdir@
-helloworld_SOURCES = \
-			NwEvt.h\
-			NwMiniLogMgrEntity.h\
-			NwMiniTmrMgrEntity.h\
-			NwMiniUlpEntity.h\
-			NwMiniUdpEntity.h\
-			NwMiniLogMgrEntity.c\
-			NwMiniTmrMgrEntity.c\
-			NwMiniUlpEntity.c\
-			NwMiniUdpEntity.c\
-                        helloworld.c
-
-helloworld_LDADD = ../../src/libNwGtpv1u.a -levent $(AM_LDFLAGS)
-all: all-am
-
-.SUFFIXES:
-.SUFFIXES: .c .o .obj
-$(srcdir)/Makefile.in:  $(srcdir)/Makefile.am  $(am__configure_deps)
-	@for dep in $?; do \
-	  case '$(am__configure_deps)' in \
-	    *$$dep*) \
-	      cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh \
-		&& exit 0; \
-	      exit 1;; \
-	  esac; \
-	done; \
-	echo ' cd $(top_srcdir) && $(AUTOMAKE) --gnu  nw-gtpv1u/test-app/nw-helloworld/Makefile'; \
-	cd $(top_srcdir) && \
-	  $(AUTOMAKE) --gnu  nw-gtpv1u/test-app/nw-helloworld/Makefile
-.PRECIOUS: Makefile
-Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status
-	@case '$?' in \
-	  *config.status*) \
-	    cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \
-	  *) \
-	    echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe)'; \
-	    cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe);; \
-	esac;
-
-$(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES)
-	cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
-
-$(top_srcdir)/configure:  $(am__configure_deps)
-	cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
-$(ACLOCAL_M4):  $(am__aclocal_m4_deps)
-	cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
-install-binPROGRAMS: $(bin_PROGRAMS)
-	@$(NORMAL_INSTALL)
-	test -z "$(bindir)" || $(MKDIR_P) "$(DESTDIR)$(bindir)"
-	@list='$(bin_PROGRAMS)'; for p in $$list; do \
-	  p1=`echo $$p|sed 's/$(EXEEXT)$$//'`; \
-	  if test -f $$p \
-	  ; then \
-	    f=`echo "$$p1" | sed 's,^.*/,,;$(transform);s/$$/$(EXEEXT)/'`; \
-	   echo " $(INSTALL_PROGRAM_ENV) $(binPROGRAMS_INSTALL) '$$p' '$(DESTDIR)$(bindir)/$$f'"; \
-	   $(INSTALL_PROGRAM_ENV) $(binPROGRAMS_INSTALL) "$$p" "$(DESTDIR)$(bindir)/$$f" || exit 1; \
-	  else :; fi; \
-	done
-
-uninstall-binPROGRAMS:
-	@$(NORMAL_UNINSTALL)
-	@list='$(bin_PROGRAMS)'; for p in $$list; do \
-	  f=`echo "$$p" | sed 's,^.*/,,;s/$(EXEEXT)$$//;$(transform);s/$$/$(EXEEXT)/'`; \
-	  echo " rm -f '$(DESTDIR)$(bindir)/$$f'"; \
-	  rm -f "$(DESTDIR)$(bindir)/$$f"; \
-	done
-
-clean-binPROGRAMS:
-	-test -z "$(bin_PROGRAMS)" || rm -f $(bin_PROGRAMS)
-helloworld$(EXEEXT): $(helloworld_OBJECTS) $(helloworld_DEPENDENCIES) 
-	@rm -f helloworld$(EXEEXT)
-	$(LINK) $(helloworld_OBJECTS) $(helloworld_LDADD) $(LIBS)
-
-mostlyclean-compile:
-	-rm -f *.$(OBJEXT)
-
-distclean-compile:
-	-rm -f *.tab.c
-
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/NwMiniLogMgrEntity.Po@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/NwMiniTmrMgrEntity.Po@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/NwMiniUdpEntity.Po@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/NwMiniUlpEntity.Po@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/helloworld.Po@am__quote@
-
-.c.o:
-@am__fastdepCC_TRUE@	$(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $<
-@am__fastdepCC_TRUE@	mv -f $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po
-@AMDEP_TRUE@@am__fastdepCC_FALSE@	source='$<' object='$@' libtool=no @AMDEPBACKSLASH@
-@AMDEP_TRUE@@am__fastdepCC_FALSE@	DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
-@am__fastdepCC_FALSE@	$(COMPILE) -c $<
-
-.c.obj:
-@am__fastdepCC_TRUE@	$(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ `$(CYGPATH_W) '$<'`
-@am__fastdepCC_TRUE@	mv -f $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po
-@AMDEP_TRUE@@am__fastdepCC_FALSE@	source='$<' object='$@' libtool=no @AMDEPBACKSLASH@
-@AMDEP_TRUE@@am__fastdepCC_FALSE@	DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
-@am__fastdepCC_FALSE@	$(COMPILE) -c `$(CYGPATH_W) '$<'`
-
-ID: $(HEADERS) $(SOURCES) $(LISP) $(TAGS_FILES)
-	list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \
-	unique=`for i in $$list; do \
-	    if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
-	  done | \
-	  $(AWK) '{ files[$$0] = 1; nonemtpy = 1; } \
-	      END { if (nonempty) { for (i in files) print i; }; }'`; \
-	mkid -fID $$unique
-tags: TAGS
-
-TAGS:  $(HEADERS) $(SOURCES)  $(TAGS_DEPENDENCIES) \
-		$(TAGS_FILES) $(LISP)
-	tags=; \
-	here=`pwd`; \
-	list='$(SOURCES) $(HEADERS)  $(LISP) $(TAGS_FILES)'; \
-	unique=`for i in $$list; do \
-	    if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
-	  done | \
-	  $(AWK) '{ files[$$0] = 1; nonempty = 1; } \
-	      END { if (nonempty) { for (i in files) print i; }; }'`; \
-	if test -z "$(ETAGS_ARGS)$$tags$$unique"; then :; else \
-	  test -n "$$unique" || unique=$$empty_fix; \
-	  $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \
-	    $$tags $$unique; \
-	fi
-ctags: CTAGS
-CTAGS:  $(HEADERS) $(SOURCES)  $(TAGS_DEPENDENCIES) \
-		$(TAGS_FILES) $(LISP)
-	tags=; \
-	list='$(SOURCES) $(HEADERS)  $(LISP) $(TAGS_FILES)'; \
-	unique=`for i in $$list; do \
-	    if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
-	  done | \
-	  $(AWK) '{ files[$$0] = 1; nonempty = 1; } \
-	      END { if (nonempty) { for (i in files) print i; }; }'`; \
-	test -z "$(CTAGS_ARGS)$$tags$$unique" \
-	  || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \
-	     $$tags $$unique
-
-GTAGS:
-	here=`$(am__cd) $(top_builddir) && pwd` \
-	  && cd $(top_srcdir) \
-	  && gtags -i $(GTAGS_ARGS) $$here
-
-distclean-tags:
-	-rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
-
-distdir: $(DISTFILES)
-	@srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
-	topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
-	list='$(DISTFILES)'; \
-	  dist_files=`for file in $$list; do echo $$file; done | \
-	  sed -e "s|^$$srcdirstrip/||;t" \
-	      -e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \
-	case $$dist_files in \
-	  */*) $(MKDIR_P) `echo "$$dist_files" | \
-			   sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \
-			   sort -u` ;; \
-	esac; \
-	for file in $$dist_files; do \
-	  if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \
-	  if test -d $$d/$$file; then \
-	    dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \
-	    if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \
-	      cp -pR $(srcdir)/$$file $(distdir)$$dir || exit 1; \
-	    fi; \
-	    cp -pR $$d/$$file $(distdir)$$dir || exit 1; \
-	  else \
-	    test -f $(distdir)/$$file \
-	    || cp -p $$d/$$file $(distdir)/$$file \
-	    || exit 1; \
-	  fi; \
-	done
-check-am: all-am
-check: check-am
-all-am: Makefile $(PROGRAMS)
-installdirs:
-	for dir in "$(DESTDIR)$(bindir)"; do \
-	  test -z "$$dir" || $(MKDIR_P) "$$dir"; \
-	done
-install: install-am
-install-exec: install-exec-am
-install-data: install-data-am
-uninstall: uninstall-am
-
-install-am: all-am
-	@$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am
-
-installcheck: installcheck-am
-install-strip:
-	$(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \
-	  install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \
-	  `test -z '$(STRIP)' || \
-	    echo "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'"` install
-mostlyclean-generic:
-
-clean-generic:
-
-distclean-generic:
-	-test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES)
-
-maintainer-clean-generic:
-	@echo "This command is intended for maintainers to use"
-	@echo "it deletes files that may require special tools to rebuild."
-clean: clean-am
-
-clean-am: clean-binPROGRAMS clean-generic mostlyclean-am
-
-distclean: distclean-am
-	-rm -rf ./$(DEPDIR)
-	-rm -f Makefile
-distclean-am: clean-am distclean-compile distclean-generic \
-	distclean-tags
-
-dvi: dvi-am
-
-dvi-am:
-
-html: html-am
-
-info: info-am
-
-info-am:
-
-install-data-am:
-
-install-dvi: install-dvi-am
-
-install-exec-am: install-binPROGRAMS
-
-install-html: install-html-am
-
-install-info: install-info-am
-
-install-man:
-
-install-pdf: install-pdf-am
-
-install-ps: install-ps-am
-
-installcheck-am:
-
-maintainer-clean: maintainer-clean-am
-	-rm -rf ./$(DEPDIR)
-	-rm -f Makefile
-maintainer-clean-am: distclean-am maintainer-clean-generic
-
-mostlyclean: mostlyclean-am
-
-mostlyclean-am: mostlyclean-compile mostlyclean-generic
-
-pdf: pdf-am
-
-pdf-am:
-
-ps: ps-am
-
-ps-am:
-
-uninstall-am: uninstall-binPROGRAMS
-
-.MAKE: install-am install-strip
-
-.PHONY: CTAGS GTAGS all all-am check check-am clean clean-binPROGRAMS \
-	clean-generic ctags distclean distclean-compile \
-	distclean-generic distclean-tags distdir dvi dvi-am html \
-	html-am info info-am install install-am install-binPROGRAMS \
-	install-data install-data-am install-dvi install-dvi-am \
-	install-exec install-exec-am install-html install-html-am \
-	install-info install-info-am install-man install-pdf \
-	install-pdf-am install-ps install-ps-am install-strip \
-	installcheck installcheck-am installdirs maintainer-clean \
-	maintainer-clean-generic mostlyclean mostlyclean-compile \
-	mostlyclean-generic pdf pdf-am ps ps-am tags uninstall \
-	uninstall-am uninstall-binPROGRAMS
-
-# Tell versions [3.59,3.63) of GNU make to not export all variables.
-# Otherwise a system limit (for SysV at least) may be exceeded.
-.NOEXPORT:
diff --git a/openair3/GTPV1-U/nw-gtpv1u/test-app/nw-helloworld/NwEvt.h b/openair3/GTPV1-U/nw-gtpv1u/test-app/nw-helloworld/NwEvt.h
deleted file mode 100644
index 6df5794a5ff..00000000000
--- a/openair3/GTPV1-U/nw-gtpv1u/test-app/nw-helloworld/NwEvt.h
+++ /dev/null
@@ -1,80 +0,0 @@
-/*----------------------------------------------------------------------------*
- *                                                                            *
- * Copyright (c) 2010-2011 Amit Chawre                                        *
- * All rights reserved.                                                       *
- *                                                                            *
- * Redistribution and use in source and binary forms, with or without         *
- * modification, are permitted provided that the following conditions         *
- * are met:                                                                   *
- *                                                                            *
- * 1. Redistributions of source code must retain the above copyright          *
- *    notice, this list of conditions and the following disclaimer.           *
- * 2. Redistributions in binary form must reproduce the above copyright       *
- *    notice, this list of conditions and the following disclaimer in the     *
- *    documentation and/or other materials provided with the distribution.    *
- * 3. The name of the author may not be used to endorse or promote products   *
- *    derived from this software without specific prior written permission.   *
- *                                                                            *
- * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR       *
- * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES  *
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.    *
- * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,           *
- * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT   *
- * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,  *
- * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY      *
- * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT        *
- * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF   *
- * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.          *
- *----------------------------------------------------------------------------*/
-
-#ifndef __NW_EVT_H__
-#define __NW_EVT_H__
-/**
- * @file NwEvt.h
- * @brief
-*/
-
-#ifdef __WITH_LIBEVENT__
-
-#include <event.h>
-
-typedef struct event                    NwEventT;
-
-#define NW_EVT_READ                     (EV_READ)
-#define NW_EVT_PERSIST                  (EV_PERSIST)
-#define NW_EVT_CALLBACK(__cbFunc)       __cbFunc(int fd, short event, void *arg)
-#define NW_TMR_CALLBACK(__cbFunc)       __cbFunc(int fd, short event, void *arg)
-
-#define NW_EVT_INIT                     event_init
-#define NW_EVT_LOOP                     event_dispatch
-
-#define NW_EVENT_ADD(__ev, __evSelObj, __evCallback, __evCallbackArg, __evFlags)        \
-  do {                                                                                  \
-    event_set(&(__ev), __evSelObj, __evFlags, __evCallback, __evCallbackArg);           \
-    event_add(&(__ev), NULL);                                                           \
-  } while(0)
-
-#else
-
-#warning "Event library not defined!"
-
-/* HACK : Defining dummy values for compilation!*/
-
-typedef struct {
-  int __tbd;
-} NwEventT;
-
-#define NW_EVT_READ                     (0)
-#define NW_EVT_PERSIST                  (1)
-#define NW_EVT_CALLBACK(__cbFunc)       __cbFunc(void *arg)
-#define NW_TMR_CALLBACK(__cbFunc)       __cbFunc(void *arg)
-
-
-#define NW_EVT_INIT()                   do { printf("error: Event library not defined!\n"); exit (0); } while(0)
-#define NW_EVT_LOOP()                   do { printf("error: Event library not defined!\n"); exit (0); } while(0)
-#define NW_EVENT_ADD(...)               do { printf("error: Event library not defined!\n"); exit (0); } while(0)
-
-
-#endif
-
-#endif /* __NW_EVT_H__ */
diff --git a/openair3/GTPV1-U/nw-gtpv1u/test-app/nw-helloworld/NwMiniLogMgrEntity.c b/openair3/GTPV1-U/nw-gtpv1u/test-app/nw-helloworld/NwMiniLogMgrEntity.c
deleted file mode 100644
index c50e6a17db4..00000000000
--- a/openair3/GTPV1-U/nw-gtpv1u/test-app/nw-helloworld/NwMiniLogMgrEntity.c
+++ /dev/null
@@ -1,62 +0,0 @@
-/*----------------------------------------------------------------------------*
- *                                                                            *
- *         M I N I M A L I S T I C    L O G M G R     E N T I T Y             *
- *                                                                            *
- *                    Copyright (C) 2010 Amit Chawre.                         *
- *                                                                            *
- *----------------------------------------------------------------------------*/
-
-/**
- * @file hello-world.c
- * @brief This file contains example of a minimalistic log manager entity.
-*/
-
-#include <stdio.h>
-#include <assert.h>
-#include "NwLog.h"
-#include "NwEvt.h"
-#include "NwGtpv1u.h"
-
-#include "NwMiniLogMgrEntity.h"
-
-#ifdef __cplusplus
-extern "C" {
-#endif
-
-uint32_t g_log_level = NW_LOG_LEVEL_INFO;
-
-/*---------------------------------------------------------------------------
- * Public functions
- *--------------------------------------------------------------------------*/
-
-NwGtpv1uRcT nwMiniLogMgrInit(NwMiniLogMgrT *thiz, uint32_t logLevel )
-{
-  thiz->logLevel = logLevel;
-  return NW_GTPV1U_OK;
-}
-
-NwGtpv1uRcT nwMiniLogMgrSetLogLevel(NwMiniLogMgrT *thiz, uint32_t logLevel)
-{
-  thiz->logLevel = logLevel;
-}
-
-NwGtpv1uRcT nwMiniLogMgrLogRequest (NwGtpv1uLogMgrHandleT hLogMgr,
-                                    uint32_t logLevel,
-                                    NwCharT *file,
-                                    uint32_t line,
-                                    NwCharT *logStr)
-{
-  NwMiniLogMgrT *thiz = (NwMiniLogMgrT *) hLogMgr;
-
-  if(thiz->logLevel >= logLevel) {
-    printf("NWGTPv2U-STK  %s - %s <%s,%u>\n", gLogLevelStr[logLevel], logStr,
-           basename(file), line);
-  }
-
-  return NW_GTPV1U_OK;
-}
-
-#ifdef __cplusplus
-}
-#endif
-
diff --git a/openair3/GTPV1-U/nw-gtpv1u/test-app/nw-helloworld/NwMiniLogMgrEntity.h b/openair3/GTPV1-U/nw-gtpv1u/test-app/nw-helloworld/NwMiniLogMgrEntity.h
deleted file mode 100644
index 18b60aa6117..00000000000
--- a/openair3/GTPV1-U/nw-gtpv1u/test-app/nw-helloworld/NwMiniLogMgrEntity.h
+++ /dev/null
@@ -1,57 +0,0 @@
-/*----------------------------------------------------------------------------*
- *                                                                            *
- *         M I N I M A L I S T I C    L O G M G R     E N T I T Y             *
- *                                                                            *
- *                    Copyright (C) 2010 Amit Chawre.                         *
- *                                                                            *
- *----------------------------------------------------------------------------*/
-
-/**
- * @file hello-world.c
- * @brief This file contains example of a minimalistic log manager entity.
-*/
-
-#include <stdio.h>
-#include <assert.h>
-#include "NwEvt.h"
-#include "NwLog.h"
-
-#ifndef __NW_MINI_LOG_MGR_H__
-#define __NW_MINI_LOG_MGR_H__
-
-#ifndef NW_ASSERT
-#define NW_ASSERT assert
-#endif
-
-extern uint32_t g_log_level;
-
-
-#define NW_LOG( _logLevel, ...)                                         \
-  do {                                                                  \
-    if(g_log_level >= _logLevel)                                        \
-    {                                                                   \
-      char _logStr[1024];                                               \
-      snprintf(_logStr, 1024, __VA_ARGS__);                             \
-      printf("NWGTPv2U-APP  %s - %s <%s,%d>\n", gLogLevelStr[_logLevel], _logStr, basename(__FILE__), __LINE__);\
-    }                                                                   \
-  } while(0)
-
-typedef struct {
-  uint8_t  logLevel;
-} NwMiniLogMgrT;
-
-#ifdef __cplusplus
-extern "C" {
-#endif
-
-NwGtpv1uRcT nwMiniLogMgrLogRequest (NwGtpv1uLogMgrHandleT logMgrHandle,
-                                    uint32_t logLevel,
-                                    NwCharT* file,
-                                    uint32_t line,
-                                    NwCharT* logStr);
-
-#ifdef __cplusplus
-}
-#endif
-
-#endif
diff --git a/openair3/GTPV1-U/nw-gtpv1u/test-app/nw-helloworld/NwMiniTmrMgrEntity.c b/openair3/GTPV1-U/nw-gtpv1u/test-app/nw-helloworld/NwMiniTmrMgrEntity.c
deleted file mode 100644
index 63ad59b23f8..00000000000
--- a/openair3/GTPV1-U/nw-gtpv1u/test-app/nw-helloworld/NwMiniTmrMgrEntity.c
+++ /dev/null
@@ -1,101 +0,0 @@
-/*----------------------------------------------------------------------------*
- *                                                                            *
- *         M I N I M A L I S T I C    T M R M G R     E N T I T Y             *
- *                                                                            *
- *                    Copyright (C) 2010 Amit Chawre.                         *
- *                                                                            *
- *----------------------------------------------------------------------------*/
-
-/**
- * @file NwMiniTmrMgrEntity.c
- * @brief This file ontains example of a minimalistic timer manager entity.
-*/
-
-#include <stdio.h>
-#include <assert.h>
-#include "NwEvt.h"
-#include "NwGtpv1u.h"
-#include "NwMiniLogMgrEntity.h"
-#include "NwMiniTmrMgrEntity.h"
-
-#ifndef NW_ASSERT
-#define NW_ASSERT assert
-#endif
-
-#ifdef __cplusplus
-extern "C" {
-#endif
-
-/*---------------------------------------------------------------------------
- * Private functions
- *--------------------------------------------------------------------------*/
-
-static void
-NW_TMR_CALLBACK(nwMiniTmrMgrHandleTimeout)
-{
-  NwGtpv1uRcT rc;
-  NwMiniTmrMgrEntityT *pTmr = (NwMiniTmrMgrEntityT *) arg;
-
-  /*---------------------------------------------------------------------------
-   *  Send Timeout Request to GTPv1u Stack Instance
-   *--------------------------------------------------------------------------*/
-
-  rc = nwGtpv1uProcessTimeout(pTmr->timeoutArg);
-  NW_ASSERT( rc == NW_GTPV1U_OK );
-
-  free(pTmr);
-
-  return;
-}
-
-/*---------------------------------------------------------------------------
- * Public functions
- *--------------------------------------------------------------------------*/
-
-NwGtpv1uRcT nwTimerStart( NwGtpv1uTimerMgrHandleT tmrMgrHandle,
-                          uint32_t timeoutSec,
-                          uint32_t timeoutUsec,
-                          uint32_t tmrType,
-                          void  *timeoutArg,
-                          NwGtpv1uTimerHandleT *hTmr)
-{
-  NwGtpv1uRcT rc = NW_GTPV1U_OK;
-  NwMiniTmrMgrEntityT *pTmr;
-  struct timeval tv;
-
-  NW_LOG(NW_LOG_LEVEL_INFO,
-         "Received start timer request from stack with timer type %d , arg %x, for %d sec and %d usec",
-         tmrType, (unsigned int)timeoutArg, timeoutSec, timeoutUsec);
-
-  pTmr = (NwMiniTmrMgrEntityT *) malloc (sizeof(NwMiniTmrMgrEntityT));
-
-  /* set the timevalues*/
-  timerclear(&tv);
-  tv.tv_sec     = timeoutSec;
-  tv.tv_usec    = timeoutUsec;
-
-  pTmr->timeoutArg = timeoutArg;
-  evtimer_set(&pTmr->ev, nwMiniTmrMgrHandleTimeout, pTmr);
-
-  /*add event*/
-
-  event_add(&(pTmr->ev), &tv);
-
-  *hTmr = (NwGtpv1uTimerHandleT)pTmr;
-
-  return rc;
-}
-
-NwGtpv1uRcT nwTimerStop( NwGtpv1uTimerMgrHandleT tmrMgrHandle,
-                         NwGtpv1uTimerHandleT hTmr)
-{
-  NW_LOG(NW_LOG_LEVEL_INFO,
-         "Received stop timer request from stack for timer handle %d", hTmr);
-  evtimer_del(&(((NwMiniTmrMgrEntityT *)hTmr)->ev));
-  free((void *)hTmr);
-  return NW_GTPV1U_OK;
-}
-
-#ifdef __cplusplus
-}
-#endif
diff --git a/openair3/GTPV1-U/nw-gtpv1u/test-app/nw-helloworld/NwMiniTmrMgrEntity.h b/openair3/GTPV1-U/nw-gtpv1u/test-app/nw-helloworld/NwMiniTmrMgrEntity.h
deleted file mode 100644
index a1f16ff89b9..00000000000
--- a/openair3/GTPV1-U/nw-gtpv1u/test-app/nw-helloworld/NwMiniTmrMgrEntity.h
+++ /dev/null
@@ -1,53 +0,0 @@
-/*----------------------------------------------------------------------------*
- *                                                                            *
- *         M I N I M A L I S T I C    T M R M G R     E N T I T Y             *
- *                                                                            *
- *                    Copyright (C) 2010 Amit Chawre.                         *
- *                                                                            *
- *----------------------------------------------------------------------------*/
-
-
-/**
- * @file NwMiniTmrMgrEntity.c
- * @brief This file ontains example of a minimalistic timer manager entity.
-*/
-
-#include <stdio.h>
-#include <assert.h>
-#include "NwEvt.h"
-#include "NwLog.h"
-
-#ifndef __NW_MINI_TMR_MGR_H__
-#define __NW_MINI_TMR_MGR_H__
-
-#ifndef NW_ASSERT
-#define NW_ASSERT assert
-#endif
-
-typedef struct {
-  NwEventT      ev;
-  void*         timeoutArg;
-} NwMiniTmrMgrEntityT;
-
-
-#ifdef __cplusplus
-extern "C" {
-#endif
-
-NwGtpv1uRcT nwTimerStart( NwGtpv1uTimerMgrHandleT tmrMgrHandle,
-                          uint32_t timeoutSec,
-                          uint32_t timeoutUsec,
-                          uint32_t tmrType,
-                          void*  timeoutArg,
-                          NwGtpv1uTimerHandleT* hTmr);
-
-
-NwGtpv1uRcT nwTimerStop( NwGtpv1uTimerMgrHandleT tmrMgrHandle,
-                         NwGtpv1uTimerHandleT hTmr);
-
-
-#ifdef __cplusplus
-}
-#endif
-
-#endif
diff --git a/openair3/GTPV1-U/nw-gtpv1u/test-app/nw-helloworld/NwMiniUdpEntity.c b/openair3/GTPV1-U/nw-gtpv1u/test-app/nw-helloworld/NwMiniUdpEntity.c
deleted file mode 100644
index a63b02985c5..00000000000
--- a/openair3/GTPV1-U/nw-gtpv1u/test-app/nw-helloworld/NwMiniUdpEntity.c
+++ /dev/null
@@ -1,157 +0,0 @@
-/*----------------------------------------------------------------------------*
- *                                                                            *
- *            M I N I M A L I S T I C     U D P     E N T I T Y               *
- *                                                                            *
- *                    Copyright (C) 2010 Amit Chawre.                         *
- *                                                                            *
- *----------------------------------------------------------------------------*/
-
-
-/**
- * @file NwMiniUdpEntity.c
- * @brief This file contains example of a minimalistic ULP entity.
-*/
-
-#include <stdio.h>
-#include <string.h>
-#include <assert.h>
-#include <sys/socket.h>
-#include <arpa/inet.h>
-#include <unistd.h>
-#include <errno.h>
-#include <fcntl.h>
-
-#include "NwEvt.h"
-#include "NwGtpv1u.h"
-#include "NwMiniLogMgrEntity.h"
-#include "NwMiniUdpEntity.h"
-
-#ifndef NW_ASSERT
-#define NW_ASSERT assert
-#endif
-
-#define MAX_UDP_PAYLOAD_LEN             (4096)
-
-#ifdef __cplusplus
-extern "C" {
-#endif
-
-/*---------------------------------------------------------------------------
- * Private functions
- *--------------------------------------------------------------------------*/
-
-static
-void NW_TMR_CALLBACK(nwUdpDataIndicationCallbackData)
-{
-  NwGtpv1uRcT         rc;
-  uint8_t         udpBuf[MAX_UDP_PAYLOAD_LEN];
-  NwS32T        bytesRead;
-  uint32_t        peerLen;
-  struct sockaddr_in peer;
-  NwMiniUdpEntityT *thiz = (NwMiniUdpEntityT *) arg;
-
-  peerLen = sizeof(peer);
-
-  bytesRead = recvfrom(thiz->hSocket, udpBuf, MAX_UDP_PAYLOAD_LEN , 0,
-                       (struct sockaddr *) &peer,(socklen_t *) &peerLen);
-
-  if(bytesRead) {
-    NW_LOG(NW_LOG_LEVEL_DEBG, "Received UDP message of length %u from %X:%u",
-           bytesRead, ntohl(peer.sin_addr.s_addr), ntohs(peer.sin_port));
-    rc = nwGtpv1uProcessUdpReq(thiz->hGtpv1uStack, udpBuf, bytesRead,
-                               peer.sin_port, peer.sin_addr.s_addr);
-  } else {
-    NW_LOG(NW_LOG_LEVEL_ERRO, "%s", strerror(errno));
-  }
-}
-
-
-/*---------------------------------------------------------------------------
- * Public functions
- *--------------------------------------------------------------------------*/
-
-NwGtpv1uRcT nwMiniUdpInit(NwMiniUdpEntityT *thiz,
-                          NwGtpv1uStackHandleT hGtpv1uStack, uint8_t *ipAddr)
-{
-  int sd;
-  struct sockaddr_in addr;
-
-  sd = socket(AF_INET, SOCK_DGRAM, 0);
-
-  if (sd < 0) {
-    NW_LOG(NW_LOG_LEVEL_ERRO, "%s", strerror(errno));
-    NW_ASSERT(0);
-  }
-
-  addr.sin_family       = AF_INET;
-  addr.sin_port         = htons(2152);
-  addr.sin_addr.s_addr  = inet_addr(ipAddr);
-  memset(addr.sin_zero, '\0', sizeof (addr.sin_zero));
-
-  if(bind(sd, (struct sockaddr *)&addr, sizeof(addr)) < 0) {
-    NW_LOG(NW_LOG_LEVEL_ERRO, "%s", strerror(errno));
-    NW_ASSERT(0);
-  }
-
-  event_set(&(thiz->ev), sd, EV_READ|EV_PERSIST, nwUdpDataIndicationCallbackData,
-            thiz);
-  event_add(&(thiz->ev), NULL);
-
-  thiz->hSocket = sd;
-  thiz->hGtpv1uStack = hGtpv1uStack;
-
-  return NW_GTPV1U_OK;
-}
-
-NwGtpv1uRcT nwMiniUdpDestroy(NwMiniUdpEntityT *thiz)
-{
-  close(thiz->hSocket);
-}
-
-NwGtpv1uRcT nwMiniUdpDataReq(NwGtpv1uUdpHandleT udpHandle,
-                             uint8_t *dataBuf,
-                             uint32_t dataSize,
-                             uint32_t peerIpAddr,
-                             uint32_t peerPort)
-{
-  struct sockaddr_in peerAddr;
-  NwS32T bytesSent;
-  NwMiniUdpEntityT *thiz = (NwMiniUdpEntityT *) udpHandle;
-
-  peerAddr.sin_family       = AF_INET;
-  peerAddr.sin_port         = htons(peerPort);
-  peerAddr.sin_addr.s_addr  = (peerIpAddr);
-  memset(peerAddr.sin_zero, '\0', sizeof (peerAddr.sin_zero));
-
-  NW_LOG(NW_LOG_LEVEL_DEBG,
-         "Sending %u bytes on handle 0x%x to peer %u.%u.%u.%u:%u", dataSize, udpHandle,
-         (peerIpAddr & 0x000000ff),
-         (peerIpAddr & 0x0000ff00) >> 8,
-         (peerIpAddr & 0x00ff0000) >> 16,
-         (peerIpAddr & 0xff000000) >> 24,
-         peerPort);
-
-  bytesSent = sendto (thiz->hSocket, dataBuf, dataSize, 0,
-                      (struct sockaddr *) &peerAddr, sizeof(peerAddr));
-
-  if(bytesSent < 0) {
-    NW_LOG(NW_LOG_LEVEL_ERRO, "%s", strerror(errno));
-  } else {
-    NW_LOG(NW_LOG_LEVEL_DEBG, "Sent %u bytes on handle 0x%x to peer %u.%u.%u.%u",
-           dataSize, udpHandle,
-           (peerIpAddr & 0x000000ff),
-           (peerIpAddr & 0x0000ff00) >> 8,
-           (peerIpAddr & 0x00ff0000) >> 16,
-           (peerIpAddr & 0xff000000) >> 24);
-
-  }
-
-  return NW_GTPV1U_OK;
-}
-
-
-
-#ifdef __cplusplus
-}
-#endif
-
diff --git a/openair3/GTPV1-U/nw-gtpv1u/test-app/nw-helloworld/NwMiniUdpEntity.h b/openair3/GTPV1-U/nw-gtpv1u/test-app/nw-helloworld/NwMiniUdpEntity.h
deleted file mode 100644
index 568c5b07969..00000000000
--- a/openair3/GTPV1-U/nw-gtpv1u/test-app/nw-helloworld/NwMiniUdpEntity.h
+++ /dev/null
@@ -1,51 +0,0 @@
-/*----------------------------------------------------------------------------*
- *                                                                            *
- *            M I N I M A L I S T I C     U D P     E N T I T Y               *
- *                                                                            *
- *                    Copyright (C) 2010 Amit Chawre.                         *
- *                                                                            *
- *----------------------------------------------------------------------------*/
-
-
-/**
- * @file NwMiniUdpEntity.h
- * @brief This file contains example of a minimalistic ULP entity.
-*/
-
-#include <stdio.h>
-#include <assert.h>
-#include "NwEvt.h"
-#include "NwLog.h"
-
-#ifndef __NW_MINI_UDP_ENTITY_H__
-#define __NW_MINI_UDP_ENTITY_H__
-
-#ifndef NW_ASSERT
-#define NW_ASSERT assert
-#endif
-
-typedef struct {
-  uint32_t        hSocket;
-  NwEventT      ev;
-  NwGtpv1uStackHandleT hGtpv1uStack;
-} NwMiniUdpEntityT;
-
-#ifdef __cplusplus
-extern "C" {
-#endif
-
-NwGtpv1uRcT nwMiniUdpInit(NwMiniUdpEntityT* thiz, NwGtpv1uStackHandleT hGtpv1uStack, uint8_t* ipAddr);
-
-NwGtpv1uRcT nwMiniUdpDestroy(NwMiniUdpEntityT* thiz);
-
-NwGtpv1uRcT nwMiniUdpDataReq(NwGtpv1uUdpHandleT udpHandle,
-                             uint8_t* dataBuf,
-                             uint32_t dataSize,
-                             uint32_t peerAddr,
-                             uint32_t peerPort);
-
-#ifdef __cplusplus
-}
-#endif
-
-#endif
diff --git a/openair3/GTPV1-U/nw-gtpv1u/test-app/nw-helloworld/NwMiniUlpEntity.c b/openair3/GTPV1-U/nw-gtpv1u/test-app/nw-helloworld/NwMiniUlpEntity.c
deleted file mode 100644
index e2f505b4eb2..00000000000
--- a/openair3/GTPV1-U/nw-gtpv1u/test-app/nw-helloworld/NwMiniUlpEntity.c
+++ /dev/null
@@ -1,309 +0,0 @@
-/*----------------------------------------------------------------------------*
- *                                                                            *
- *            M I N I M A L I S T I C     U L P     E N T I T Y               *
- *                                                                            *
- *                    Copyright (C) 2010 Amit Chawre.                         *
- *                                                                            *
- *----------------------------------------------------------------------------*/
-
-/**
- * @file NwMiniUlpEntity.c
- * @brief This file contains example of a minimalistic ULP entity.
-*/
-
-#include <stdio.h>
-#include <string.h>
-#include <errno.h>
-#include <assert.h>
-#include "NwEvt.h"
-#include "NwGtpv1u.h"
-#include "NwGtpv1uIe.h"
-#include "NwMiniLogMgrEntity.h"
-#include "NwMiniUlpEntity.h"
-
-#ifndef NW_ASSERT
-#define NW_ASSERT assert
-#endif
-
-#ifdef __cplusplus
-extern "C" {
-#endif
-
-/*---------------------------------------------------------------------------
- * Private Functions
- *--------------------------------------------------------------------------*/
-
-#define MAX_UDP_PAYLOAD_LEN                     (4096)
-
-NwGtpv1uRcT
-nwMiniUlpSendEchoRequestToPeer(NwMiniUlpEntityT *thiz, uint32_t peerIp)
-{
-  NwGtpv1uRcT rc;
-  NwGtpv1uUlpApiT           ulpReq;
-
-  /*
-   *  Send Message Request to Gtpv1u Stack Instance
-   */
-
-  ulpReq.apiType = NW_GTPV1U_ULP_API_INITIAL_REQ;
-
-  ulpReq.apiInfo.initialReqInfo.hUlpTrxn        = (NwGtpv1uUlpTrxnHandleT)thiz;
-  ulpReq.apiInfo.initialReqInfo.teid            = 0x00;
-  ulpReq.apiInfo.initialReqInfo.peerIp          = (peerIp);
-  ulpReq.apiInfo.initialReqInfo.peerPort        = 2152;
-
-  /* Send Echo Request*/
-
-  rc = nwGtpv1uMsgNew( thiz->hGtpv1uStack,
-                       NW_TRUE,          /* SeqNum flag    */
-                       NW_FALSE,
-                       NW_FALSE,
-                       NW_GTP_ECHO_REQ,  /* Msg Type             */
-                       0x00000000UL,     /* TEID                 */
-                       0x5678,           /* Seq Number           */
-                       0,
-                       0,
-                       (&ulpReq.hMsg));
-
-  NW_ASSERT( rc == NW_GTPV1U_OK );
-
-  rc = nwGtpv1uMsgAddIeTV1((ulpReq.hMsg), NW_GTPV1U_IE_RECOVERY,
-                           thiz->restartCounter);
-  NW_ASSERT( rc == NW_GTPV1U_OK );
-
-  rc = nwGtpv1uProcessUlpReq(thiz->hGtpv1uStack, &ulpReq);
-  NW_ASSERT( rc == NW_GTPV1U_OK );
-
-  return NW_GTPV1U_OK;
-}
-
-static
-void NW_EVT_CALLBACK(nwMiniUlpDataIndicationCallbackData)
-{
-  NwMiniUlpEntityT *thiz = (NwMiniUlpEntityT *) arg;
-  NwGtpv1uRcT         rc;
-  uint8_t         udpBuf[MAX_UDP_PAYLOAD_LEN];
-  NwS32T        bytesRead;
-  uint32_t        peerLen;
-  struct sockaddr_in peer;
-
-  peerLen = sizeof(peer);
-
-  bytesRead = recvfrom(thiz->hSocket, udpBuf, MAX_UDP_PAYLOAD_LEN , 0,
-                       (struct sockaddr *) &peer,(socklen_t *) &peerLen);
-
-  if(bytesRead) {
-    NW_LOG(NW_LOG_LEVEL_DEBG, "Received UDP message of length %u from %X:%u",
-           bytesRead, ntohl(peer.sin_addr.s_addr), ntohs(peer.sin_port));
-    rc = nwMiniUlpTpduSend(thiz, udpBuf, bytesRead, thiz->localPort[fd]);
-  } else {
-    NW_LOG(NW_LOG_LEVEL_ERRO, "%s", strerror(errno));
-  }
-}
-
-/*---------------------------------------------------------------------------
- * Public Functions
- *--------------------------------------------------------------------------*/
-
-NwGtpv1uRcT
-nwMiniUlpInit(NwMiniUlpEntityT *thiz, NwGtpv1uStackHandleT hGtpv1uStack)
-{
-  NwGtpv1uRcT rc;
-  thiz->hGtpv1uStack = hGtpv1uStack;
-
-  return NW_GTPV1U_OK;
-}
-
-NwGtpv1uRcT
-nwMiniUlpDestroy(NwMiniUlpEntityT *thiz)
-{
-  NW_ASSERT(thiz);
-  memset(thiz, 0, sizeof(NwMiniUlpEntityT));
-  return NW_GTPV1U_OK;
-}
-
-NwGtpv1uRcT
-nwMiniUlpCreateConn(NwMiniUlpEntityT *thiz, char *localIpStr, uint16_t localport,
-                    char *peerIpStr)
-{
-  NwGtpv1uRcT rc;
-  int sd;
-  struct sockaddr_in addr;
-  NwGtpv1uUlpApiT           ulpReq;
-
-  strcpy(thiz->peerIpStr, peerIpStr);
-
-  /*
-   * Create local tunnel endpoint
-   */
-
-  NW_LOG(NW_LOG_LEVEL_NOTI, "Creating tunnel endpoint with teid %d", localport);
-  ulpReq.apiType                                        =
-    NW_GTPV1U_ULP_API_CREATE_TUNNEL_ENDPOINT;
-  ulpReq.apiInfo.createTunnelEndPointInfo.teid          = localport;
-  ulpReq.apiInfo.createTunnelEndPointInfo.hUlpSession   =
-    (NwGtpv1uUlpSessionHandleT)thiz;
-
-  rc = nwGtpv1uProcessUlpReq(thiz->hGtpv1uStack, &ulpReq);
-  NW_ASSERT( rc == NW_GTPV1U_OK );
-
-  thiz->hGtpv1uConn = ulpReq.apiInfo.createTunnelEndPointInfo.hStackSession;
-
-  /*
-   * Create local udp listening endpoint
-   */
-
-  sd = socket(AF_INET, SOCK_DGRAM, 0);
-
-  if (sd < 0) {
-    NW_LOG(NW_LOG_LEVEL_ERRO, "%s", strerror(errno));
-    NW_ASSERT(0);
-  }
-
-  addr.sin_family       = AF_INET;
-  addr.sin_port         = htons(localport);
-  addr.sin_addr.s_addr  = inet_addr(localIpStr);
-  memset(addr.sin_zero, '\0', sizeof (addr.sin_zero));
-
-  if(bind(sd, (struct sockaddr *)&addr, sizeof(addr)) < 0) {
-    NW_LOG(NW_LOG_LEVEL_ERRO, "%s", strerror(errno));
-    NW_ASSERT(0);
-  }
-
-  event_set(&(thiz->ev[sd]), sd, EV_READ|EV_PERSIST,
-            nwMiniUlpDataIndicationCallbackData, thiz);
-  event_add(&(thiz->ev[sd]), NULL);
-
-  thiz->localPort[sd] = localport;
-
-  /*
-   * Create local udp for sendign data
-   */
-
-  sd = socket(AF_INET, SOCK_DGRAM, 0);
-
-  if (sd < 0) {
-    NW_LOG(NW_LOG_LEVEL_ERRO, "%s", strerror(errno));
-    NW_ASSERT(0);
-  }
-
-
-  thiz->hSocket = sd;
-  return NW_GTPV1U_OK;
-}
-
-NwGtpv1uRcT
-nwMiniUlpDestroyConn(NwMiniUlpEntityT *thiz)
-{
-  NwGtpv1uRcT rc;
-  NwGtpv1uUlpApiT           ulpReq;
-  /*---------------------------------------------------------------------------
-   *  Send Destroy Session Request to GTPv1u Stack Instance
-   *--------------------------------------------------------------------------*/
-
-  ulpReq.apiType = NW_GTPV1U_ULP_API_DESTROY_TUNNEL_ENDPOINT;
-  ulpReq.apiInfo.destroyTunnelEndPointInfo.hStackSessionHandle = thiz->hGtpv1uConn;
-
-  rc = nwGtpv1uProcessUlpReq(thiz->hGtpv1uStack, &ulpReq);
-  NW_ASSERT( rc == NW_GTPV1U_OK );
-
-  thiz->hGtpv1uConn = 0;
-
-  return NW_GTPV1U_OK;
-}
-
-
-NwGtpv1uRcT
-nwMiniUlpTpduSend(NwMiniUlpEntityT *thiz, uint8_t *tpduBuf, uint32_t tpduLen ,
-                  uint16_t fromPort)
-{
-  NwGtpv1uRcT rc;
-  NwGtpv1uUlpApiT           ulpReq;
-
-  /*
-   *  Send Message Request to GTPv1u Stack Instance
-   */
-
-  ulpReq.apiType                        = NW_GTPV1U_ULP_API_SEND_TPDU;
-  ulpReq.apiInfo.sendtoInfo.teid        = fromPort;
-  ulpReq.apiInfo.sendtoInfo.ipAddr      = inet_addr(thiz->peerIpStr);
-
-  rc = nwGtpv1uGpduMsgNew( thiz->hGtpv1uStack,
-                           fromPort,
-                           NW_FALSE,
-                           thiz->seqNum++,
-                           tpduBuf,
-                           tpduLen,
-                           &(ulpReq.apiInfo.sendtoInfo.hMsg));
-
-  NW_ASSERT( rc == NW_GTPV1U_OK );
-
-  rc = nwGtpv1uProcessUlpReq(thiz->hGtpv1uStack, &ulpReq);
-  NW_ASSERT( rc == NW_GTPV1U_OK );
-
-  rc = nwGtpv1uMsgDelete(thiz->hGtpv1uStack, (ulpReq.apiInfo.sendtoInfo.hMsg));
-  NW_ASSERT( rc == NW_GTPV1U_OK );
-
-  return NW_GTPV1U_OK;
-}
-
-NwGtpv1uRcT
-nwMiniUlpProcessStackReqCallback (NwGtpv1uUlpHandleT hUlp,
-                                  NwGtpv1uUlpApiT *pUlpApi)
-{
-  NwMiniUlpEntityT *thiz;
-  NW_ASSERT(pUlpApi != NULL);
-
-  thiz = (NwMiniUlpEntityT *) hUlp;
-
-  switch(pUlpApi->apiType) {
-  case NW_GTPV1U_ULP_API_RECV_TPDU: {
-    struct sockaddr_in peerAddr;
-    NwS32T bytesSent;
-    uint8_t dataBuf[4096];
-    uint32_t dataSize;
-    uint32_t peerIpAddr = (inet_addr(thiz->peerIpStr));
-
-    NW_ASSERT( NW_GTPV1U_OK == nwGtpv1uMsgGetTpdu(pUlpApi->apiInfo.recvMsgInfo.hMsg,
-               dataBuf, &dataSize) );
-
-    NW_LOG(NW_LOG_LEVEL_DEBG, "Received TPDU from gtpv1u stack %u!",
-           pUlpApi->apiInfo.recvMsgInfo.teid);
-
-    peerAddr.sin_family       = AF_INET;
-    peerAddr.sin_port         = htons(pUlpApi->apiInfo.recvMsgInfo.teid);
-    peerAddr.sin_addr.s_addr  = (peerIpAddr);
-    memset(peerAddr.sin_zero, '\0', sizeof (peerAddr.sin_zero));
-
-    bytesSent = sendto (thiz->hSocket, dataBuf, dataSize, 0,
-                        (struct sockaddr *) &peerAddr, sizeof(peerAddr));
-
-    if(bytesSent < 0) {
-      NW_LOG(NW_LOG_LEVEL_ERRO, "%s", strerror(errno));
-      NW_ASSERT(0);
-    } else {
-      NW_LOG(NW_LOG_LEVEL_DEBG, "Sent %u bytes to peer %u.%u.%u.%u", dataSize,
-             (peerIpAddr & 0x000000ff),
-             (peerIpAddr & 0x0000ff00) >> 8,
-             (peerIpAddr & 0x00ff0000) >> 16,
-             (peerIpAddr & 0xff000000) >> 24);
-    }
-
-    NW_ASSERT(nwGtpv1uMsgDelete(thiz->hGtpv1uStack,
-                                (pUlpApi->apiInfo.recvMsgInfo.hMsg)) == NW_GTPV1U_OK);
-
-  }
-  break;
-
-  default:
-    NW_LOG(NW_LOG_LEVEL_WARN, "Received undefined UlpApi (%d) from gtpv1u stack!",
-           pUlpApi->apiType);
-  }
-
-  return NW_GTPV1U_OK;
-}
-
-#ifdef __cplusplus
-}
-#endif
-
diff --git a/openair3/GTPV1-U/nw-gtpv1u/test-app/nw-helloworld/NwMiniUlpEntity.h b/openair3/GTPV1-U/nw-gtpv1u/test-app/nw-helloworld/NwMiniUlpEntity.h
deleted file mode 100644
index dd55e8ed7c8..00000000000
--- a/openair3/GTPV1-U/nw-gtpv1u/test-app/nw-helloworld/NwMiniUlpEntity.h
+++ /dev/null
@@ -1,64 +0,0 @@
-/*----------------------------------------------------------------------------*
- *                                                                            *
- *            M I N I M A L I S T I C     U L P     E N T I T Y               *
- *                                                                            *
- *                    Copyright (C) 2010 Amit Chawre.                         *
- *                                                                            *
- *----------------------------------------------------------------------------*/
-
-/**
- * @file NwMiniUlpEntity.h
- * @brief This file contains example of a minimalistic ULP entity.
-*/
-
-#include <stdio.h>
-#include <assert.h>
-#include "NwEvt.h"
-#include "NwLog.h"
-
-#ifndef __NW_MINI_ULP_H__
-#define __NW_MINI_ULP_H__
-
-typedef struct {
-  int                           hSocket;
-  uint16_t                        seqNum;
-  uint8_t                         restartCounter;
-  uint8_t                         localIpStr[16];
-  uint8_t                         peerIpStr[16];
-  uint32_t                        localPort[1025];
-  NwEventT                      ev[1025];
-  NwGtpv1uStackHandleT          hGtpv1uStack;
-  NwGtpv1uStackSessionHandleT   hGtpv1uConn;
-} NwMiniUlpEntityT;
-
-#ifdef __cplusplus
-extern "C" {
-#endif
-
-NwGtpv1uRcT
-nwMiniUlpInit(NwMiniUlpEntityT* thiz, NwGtpv1uStackHandleT hGtpv1uStack);
-
-NwGtpv1uRcT
-nwMiniUlpDestroy(NwMiniUlpEntityT* thiz);
-
-NwGtpv1uRcT
-nwMiniUlpCreateConn(NwMiniUlpEntityT* thiz, char* localIpStr, uint16_t localPort, char* peerIpStr);
-
-NwGtpv1uRcT
-nwMiniUlpDestroyConn(NwMiniUlpEntityT* thiz);
-
-NwGtpv1uRcT
-nwMiniUlpSendMsg(NwMiniUlpEntityT* thiz);
-
-NwGtpv1uRcT
-nwMiniUlpTpduSend(NwMiniUlpEntityT* thiz, uint8_t* tpduBuf, uint32_t tpduLen , uint16_t fromPort);
-
-NwGtpv1uRcT
-nwMiniUlpProcessStackReqCallback (NwGtpv1uUlpHandleT hUlp,
-                                  NwGtpv1uUlpApiT *pUlpApi);
-
-#ifdef __cplusplus
-}
-#endif
-
-#endif
diff --git a/openair3/GTPV1-U/nw-gtpv1u/test-app/nw-helloworld/helloworld.c b/openair3/GTPV1-U/nw-gtpv1u/test-app/nw-helloworld/helloworld.c
deleted file mode 100644
index 2f618ad6423..00000000000
--- a/openair3/GTPV1-U/nw-gtpv1u/test-app/nw-helloworld/helloworld.c
+++ /dev/null
@@ -1,207 +0,0 @@
-/*----------------------------------------------------------------------------*
- *                                                                            *
- *                             n w - g t p v 2 u                              *
- *    G P R S    T u n n e l i n g    P r o t o c o l   v 2 u   S t a c k     *
- *                                                                            *
- *           M I N I M A L I S T I C     D E M O N S T R A T I O N            *
- *                                                                            *
- *                    Copyright (C) 2010 Amit Chawre.                         *
- *                                                                            *
- *----------------------------------------------------------------------------*/
-
-
-/**
- * @file hello-world.c
- * @brief This is a test program demostrating usage of nw-gtpv2 library.
-*/
-
-#include <stdio.h>
-#include <assert.h>
-#include "NwEvt.h"
-#include "NwGtpv1u.h"
-
-#include "NwMiniLogMgrEntity.h"
-#include "NwMiniTmrMgrEntity.h"
-#include "NwMiniUdpEntity.h"
-#include "NwMiniUlpEntity.h"
-
-#ifndef NW_ASSERT
-#define NW_ASSERT assert
-#endif
-
-/*---------------------------------------------------------------------------
- *                T H E      M A I N      F U N C T I O N
- *--------------------------------------------------------------------------*/
-
-int main(int argc, char *argv[])
-{
-  NwGtpv1uRcT rc;
-  char                         *logLevelStr;
-  uint32_t                        logLevel;
-  uint32_t                        num_of_connections;
-
-  NwGtpv1uStackHandleT          hGtpv1uStack = 0;
-  NwMiniUlpEntityT              ulpObj;
-  NwMiniUdpEntityT              udpObj;
-  NwMiniLogMgrT                 logObj;
-  NwGtpv1uUlpEntityT            ulp;
-  NwGtpv1uUdpEntityT            udp;
-  NwGtpv1uTimerMgrEntityT       tmrMgr;
-  NwGtpv1uLogMgrEntityT         logMgr;
-
-  if(argc != 4) {
-    printf("Usage: %s <num-of-connections> <local-ip> <peer-ip>\n", argv[0]);
-    exit(0);
-  }
-
-
-  logLevelStr = getenv ("NW_LOG_LEVEL");
-
-  if(logLevelStr == NULL) {
-    logLevel = NW_LOG_LEVEL_INFO;
-  } else {
-    if(strncmp(logLevelStr, "EMER",4) == 0) {
-      logLevel = NW_LOG_LEVEL_EMER;
-    } else if(strncmp(logLevelStr, "ALER",4) == 0) {
-      logLevel = NW_LOG_LEVEL_ALER;
-    } else if(strncmp(logLevelStr, "CRIT",4) == 0) {
-      logLevel = NW_LOG_LEVEL_CRIT;
-    } else if(strncmp(logLevelStr, "ERRO",4) == 0) {
-      logLevel = NW_LOG_LEVEL_ERRO ;
-    } else if(strncmp(logLevelStr, "WARN",4) == 0) {
-      logLevel = NW_LOG_LEVEL_WARN;
-    } else if(strncmp(logLevelStr, "NOTI",4) == 0) {
-      logLevel = NW_LOG_LEVEL_NOTI;
-    } else if(strncmp(logLevelStr, "INFO",4) == 0) {
-      logLevel = NW_LOG_LEVEL_INFO;
-    } else if(strncmp(logLevelStr, "DEBG",4) == 0) {
-      logLevel = NW_LOG_LEVEL_DEBG;
-    }
-  }
-
-  /*---------------------------------------------------------------------------
-   *  Initialize event library
-   *--------------------------------------------------------------------------*/
-
-  NW_EVT_INIT();
-
-  /*---------------------------------------------------------------------------
-   *  Initialize Log Manager
-   *--------------------------------------------------------------------------*/
-
-  nwMiniLogMgrInit(&logObj, logLevel);
-
-  /*---------------------------------------------------------------------------
-   *  Create GTPv1u Stack Instance
-   *--------------------------------------------------------------------------*/
-
-  rc = nwGtpv1uInitialize(&hGtpv1uStack, GTPU_STACK_ENB);
-
-  if(rc != NW_GTPV1U_OK) {
-    NW_LOG(NW_LOG_LEVEL_ERRO,
-           "Failed to create gtpv1u stack instance. Error '%u' occured", rc);
-    exit(1);
-  }
-
-  NW_LOG(NW_LOG_LEVEL_INFO, "Gtpv1u Stack Handle '%X' Creation Successful!",
-         hGtpv1uStack);
-
-  /*---------------------------------------------------------------------------
-   * Set up Ulp Entity
-   *--------------------------------------------------------------------------*/
-
-  rc = nwMiniUlpInit(&ulpObj, hGtpv1uStack);
-  NW_ASSERT( rc == NW_GTPV1U_OK );
-
-  ulp.hUlp = (NwGtpv1uUlpHandleT) &ulpObj;
-  ulp.ulpReqCallback = nwMiniUlpProcessStackReqCallback;
-
-  rc = nwGtpv1uSetUlpEntity(hGtpv1uStack, &ulp);
-  NW_ASSERT( rc == NW_GTPV1U_OK );
-
-
-  /*---------------------------------------------------------------------------
-   * Set up Udp Entity
-   *--------------------------------------------------------------------------*/
-
-  rc = nwMiniUdpInit(&udpObj, hGtpv1uStack, (argv[2]));
-  NW_ASSERT( rc == NW_GTPV1U_OK );
-
-  udp.hUdp = (NwGtpv1uUdpHandleT) &udpObj;
-  udp.udpDataReqCallback = nwMiniUdpDataReq;
-
-  rc = nwGtpv1uSetUdpEntity(hGtpv1uStack, &udp);
-  NW_ASSERT( rc == NW_GTPV1U_OK );
-
-  /*---------------------------------------------------------------------------
-   * Set up Log Entity
-   *--------------------------------------------------------------------------*/
-
-  tmrMgr.tmrMgrHandle = 0;
-  tmrMgr.tmrStartCallback = nwTimerStart;
-  tmrMgr.tmrStopCallback = nwTimerStop;
-
-  rc = nwGtpv1uSetTimerMgrEntity(hGtpv1uStack, &tmrMgr);
-  NW_ASSERT( rc == NW_GTPV1U_OK );
-
-  /*---------------------------------------------------------------------------
-   * Set up Log Entity
-   *--------------------------------------------------------------------------*/
-
-  logMgr.logMgrHandle   = (NwGtpv1uLogMgrHandleT) &logObj;
-  logMgr.logReqCallback  = nwMiniLogMgrLogRequest;
-
-  rc = nwGtpv1uSetLogMgrEntity(hGtpv1uStack, &logMgr);
-  NW_ASSERT( rc == NW_GTPV1U_OK );
-
-  /*---------------------------------------------------------------------------
-   * Set GTPv1u log level
-   *--------------------------------------------------------------------------*/
-
-  rc = nwGtpv1uSetLogLevel(hGtpv1uStack, logLevel);
-
-  /*---------------------------------------------------------------------------
-   *  Send Create Session Request to GTPv1u Stack Instance
-   *--------------------------------------------------------------------------*/
-
-  num_of_connections = atoi(argv[1]);
-
-  while ( num_of_connections-- ) {
-    //rc = nwMiniUlpCreateConn(&ulpObj, argv[2], 1234 + num_of_connections, argv[3]);
-    rc = nwMiniUlpSendEchoRequestToPeer(&ulpObj, inet_addr(argv[3]));
-    NW_ASSERT( rc == NW_GTPV1U_OK );
-  }
-
-  /*---------------------------------------------------------------------------
-   * Event loop
-   *--------------------------------------------------------------------------*/
-
-  NW_EVT_LOOP();
-
-  NW_LOG(NW_LOG_LEVEL_ERRO, "Exit from eventloop, no events to process!");
-
-  /*---------------------------------------------------------------------------
-   *  Send Destroy Session Request to GTPv1u Stack Instance
-   *--------------------------------------------------------------------------*/
-
-  rc = nwMiniUlpDestroyConn(&ulpObj);
-  NW_ASSERT( rc == NW_GTPV1U_OK );
-
-
-  /*---------------------------------------------------------------------------
-   *  Destroy GTPv1u Stack Instance
-   *--------------------------------------------------------------------------*/
-
-  rc = nwGtpv1uFinalize(hGtpv1uStack);
-
-  if(rc != NW_GTPV1U_OK) {
-    NW_LOG(NW_LOG_LEVEL_ERRO,
-           "Failed to finalize gtpv1u stack instance. Error '%u' occured", rc);
-  } else {
-    NW_LOG(NW_LOG_LEVEL_INFO, "Gtpv1u Stack Handle '%X' Finalize Successful!",
-           hGtpv1uStack);
-  }
-
-
-  return rc;
-}
diff --git a/openair3/UDP/udp_eNB_task.c b/openair3/UDP/udp_eNB_task.c
deleted file mode 100644
index 8b9fc77bb14..00000000000
--- a/openair3/UDP/udp_eNB_task.c
+++ /dev/null
@@ -1,447 +0,0 @@
-/*
- * Licensed to the OpenAirInterface (OAI) Software Alliance under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The OpenAirInterface Software Alliance licenses this file to You under
- * the OAI Public License, Version 1.1  (the "License"); you may not use this file
- * except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.openairinterface.org/?page_id=698
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- *-------------------------------------------------------------------------------
- * For more information about the OpenAirInterface (OAI) Software Alliance:
- *      contact@openairinterface.org
- */
-
-/*! \file udp_eNB_task.c
-* \brief
-* \author Sebastien ROUX, Lionel Gauthier
-* \company Eurecom
-* \email: lionel.gauthier@eurecom.fr
-*/
-#include <stdio.h>
-#include <stdlib.h>
-#include <string.h>
-#include <unistd.h>
-#include <errno.h>
-
-#include <sys/socket.h>
-#include <netinet/in.h>
-#include <arpa/inet.h>
-
-#include <pthread.h>
-
-#include "queue.h"
-#include "intertask_interface.h"
-#include "assertions.h"
-#include "udp_eNB_task.h"
-
-#include "common/utils/LOG/log.h"
-#include "common/utils/LOG/vcd_signal_dumper.h"
-#include "msc.h"
-
-
-#define IPV4_ADDR    "%u.%u.%u.%u"
-#define IPV4_ADDR_FORMAT(aDDRESS)               \
-    (uint8_t)((aDDRESS)  & 0x000000ff),         \
-    (uint8_t)(((aDDRESS) & 0x0000ff00) >> 8 ),  \
-    (uint8_t)(((aDDRESS) & 0x00ff0000) >> 16),  \
-    (uint8_t)(((aDDRESS) & 0xff000000) >> 24)
-
-
-struct udp_socket_desc_s {
-  int       sd;              /* Socket descriptor to use */
-
-  pthread_t listener_thread; /* Thread affected to recv */
-
-  char     *local_address;   /* Local ipv4 address to use */
-  uint16_t  local_port;      /* Local port to use */
-
-  task_id_t task_id;         /* Task who has requested the new endpoint */
-
-  STAILQ_ENTRY(udp_socket_desc_s) entries;
-};
-
-static STAILQ_HEAD(udp_socket_list_s, udp_socket_desc_s) udp_socket_list;
-static pthread_mutex_t udp_socket_list_mutex = PTHREAD_MUTEX_INITIALIZER;
-
-
-static
-struct udp_socket_desc_s *
-udp_eNB_get_socket_desc(task_id_t task_id);
-
-void udp_eNB_process_file_descriptors(
-  struct epoll_event *events,
-  int nb_events);
-
-static
-int
-udp_eNB_create_socket(
-  int port,
-  char *ip_addr,
-  task_id_t task_id);
-
-int
-udp_eNB_send_to(
-  int sd,
-  uint16_t port,
-  uint32_t address,
-  const uint8_t *buffer,
-  uint32_t length);
-
-void udp_eNB_receiver(struct udp_socket_desc_s *udp_sock_pP);
-
-void *udp_eNB_task(void *args_p);
-
-int udp_enb_init(void);
-/* @brief Retrieve the descriptor associated with the task_id
- */
-static
-struct udp_socket_desc_s *udp_eNB_get_socket_desc(task_id_t task_id)
-{
-  struct udp_socket_desc_s *udp_sock_p = NULL;
-
-#if defined(LOG_UDP) && LOG_UDP > 0
-  LOG_T(UDP_, "Looking for task %d\n", task_id);
-#endif
-
-  STAILQ_FOREACH(udp_sock_p, &udp_socket_list, entries) {
-    if (udp_sock_p->task_id == task_id) {
-#if defined(LOG_UDP) && LOG_UDP > 0
-      LOG_T(UDP_, "Found matching task desc\n");
-#endif
-      break;
-    }
-  }
-  return udp_sock_p;
-}
-
-void udp_eNB_process_file_descriptors(struct epoll_event *events, int nb_events)
-{
-  int                       i;
-  struct udp_socket_desc_s *udp_sock_p = NULL;
-
-  if (events == NULL) {
-    return;
-  }
-
-  for (i = 0; i < nb_events; i++) {
-    STAILQ_FOREACH(udp_sock_p, &udp_socket_list, entries) {
-      if (udp_sock_p->sd == events[i].data.fd) {
-#if defined(LOG_UDP) && LOG_UDP > 0
-        LOG_D(UDP_, "Found matching task desc\n");
-#endif
-        udp_eNB_receiver(udp_sock_p);
-        break;
-      }
-    }
-  }
-}
-
-static
-int udp_eNB_create_socket(int port, char *ip_addr, task_id_t task_id)
-{
-
-  struct udp_socket_desc_s  *udp_socket_desc_p = NULL;
-  int                       sd, rc;
-  struct sockaddr_in        sin;
-
-  LOG_I(UDP_, "Initializing UDP for local address %s with port %d\n", ip_addr, port);
-
-  sd = socket(AF_INET, SOCK_DGRAM, 0);
-  AssertFatal(sd > 0, "UDP: Failed to create new socket: (%s:%d)\n", strerror(errno), errno);
-
-  memset(&sin, 0, sizeof(struct sockaddr_in));
-  sin.sin_family      = AF_INET;
-  sin.sin_port        = htons(port);
-
-  if (ip_addr == NULL) {
-    sin.sin_addr.s_addr = inet_addr(INADDR_ANY);
-  } else {
-    sin.sin_addr.s_addr = inet_addr(ip_addr);
-  }
-
-  if ((rc = bind(sd, (struct sockaddr *)&sin, sizeof(struct sockaddr_in))) < 0) {
-    close(sd);
-    LOG_E(UDP_, "Failed to bind socket: (%s:%d) address %s port %d\n", strerror(errno), errno, ip_addr, port);
-    return -1;
-  }
-
-  /* Create a new descriptor for this connection */
-  udp_socket_desc_p = calloc(1, sizeof(struct udp_socket_desc_s));
-
-  DevAssert(udp_socket_desc_p != NULL);
-
-  udp_socket_desc_p->sd            = sd;
-  udp_socket_desc_p->local_address = ip_addr;
-  udp_socket_desc_p->local_port    = port;
-  udp_socket_desc_p->task_id       = task_id;
-
-  LOG_I(UDP_, "Inserting new descriptor for task %d, sd %d\n", udp_socket_desc_p->task_id, udp_socket_desc_p->sd);
-  pthread_mutex_lock(&udp_socket_list_mutex);
-  STAILQ_INSERT_TAIL(&udp_socket_list, udp_socket_desc_p, entries);
-  pthread_mutex_unlock(&udp_socket_list_mutex);
-
-  itti_subscribe_event_fd(TASK_UDP, sd);
-  LOG_I(UDP_, "Initializing UDP for local address %s with port %d: DONE\n", ip_addr, port);
-  return sd;
-}
-
-int
-udp_eNB_send_to(
-  int sd,
-  uint16_t port,
-  uint32_t address,
-  const uint8_t *buffer,
-  uint32_t length)
-{
-  struct sockaddr_in to;
-  socklen_t          to_length;
-
-  if (sd <= 0 || ((buffer == NULL) && (length > 0))) {
-    LOG_E(UDP_, "udp_send_to: bad param\n");
-    return -1;
-  }
-
-  memset(&to, 0, sizeof(struct sockaddr_in));
-  to_length = sizeof(to);
-
-  to.sin_family      = AF_INET;
-  to.sin_port        = htons(port);
-  to.sin_addr.s_addr = address;
-
-  if (sendto(sd, (void *)buffer, (size_t)length, 0, (struct sockaddr *)&to,
-             to_length) < 0) {
-    LOG_E(UDP_,
-          "[SD %d] Failed to send data to "IPV4_ADDR" on port %d, buffer size %u\n",
-          sd, IPV4_ADDR_FORMAT(address), port, length);
-    return -1;
-  }
-
-#if defined(LOG_UDP) && LOG_UDP > 0
-  LOG_I(UDP_, "[SD %d] Successfully sent to "IPV4_ADDR
-        " on port %d, buffer size %u, buffer address %x\n",
-        sd, IPV4_ADDR_FORMAT(address), port, length, buffer);
-#endif
-  return 0;
-}
-
-
-void udp_eNB_receiver(struct udp_socket_desc_s *udp_sock_pP)
-{
-  uint8_t                   l_buffer[NFAPI_MAX_PACKED_MESSAGE_SIZE];
-  int                n;
-  socklen_t          from_len;
-  struct sockaddr_in addr;
-  MessageDef               *message_p        = NULL;
-  udp_data_ind_t           *udp_data_ind_p   = NULL;
-  uint8_t                  *forwarded_buffer = NULL;
-
-  if (1) {
-    from_len = (socklen_t)sizeof(struct sockaddr_in);
-
-    if ((n = recvfrom(udp_sock_pP->sd, l_buffer, sizeof(l_buffer), MSG_TRUNC,
-                      (struct sockaddr *)&addr, &from_len)) < 0) {
-      LOG_E(UDP_, "Recvfrom failed %s\n", strerror(errno));
-      return;
-    } else if (n > sizeof(l_buffer)) {
-      LOG_E(UDP_, "%s(%d). Message truncated. %d\n", __FUNCTION__, __LINE__, n);
-      return;
-    } else if (n == 0) {
-      LOG_W(UDP_, "Recvfrom returned 0\n");
-      return;
-    } else {
-      forwarded_buffer = itti_malloc(TASK_UDP, udp_sock_pP->task_id, n*sizeof(uint8_t));
-      DevAssert(forwarded_buffer != NULL);
-      memcpy(forwarded_buffer, l_buffer, n);
-      message_p = itti_alloc_new_message(TASK_UDP, 0, UDP_DATA_IND);
-      DevAssert(message_p != NULL);
-      udp_data_ind_p = &message_p->ittiMsg.udp_data_ind;
-      udp_data_ind_p->buffer        = forwarded_buffer;
-      udp_data_ind_p->buffer_length = n;
-      udp_data_ind_p->peer_port     = htons(addr.sin_port);
-      udp_data_ind_p->peer_address  = addr.sin_addr.s_addr;
-
-#if defined(LOG_UDP) && LOG_UDP > 0
-      LOG_I(UDP_, "Msg of length %d received from %s:%u\n",
-            n, inet_ntoa(addr.sin_addr), ntohs(addr.sin_port));
-#endif
-
-      /* TODO: this is a hack. Let's accept failures and do nothing when
-       * it happens. Since itti_send_msg_to_task crashes when the message
-       * queue is full we wrote itti_try_send_msg_to_task that returns -1
-       * if the queue is full.
-       */
-      /* look for HACK_RLC_UM_LIMIT for others places related to the hack. Please do not remove this comment. */
-      if (itti_send_msg_to_task(udp_sock_pP->task_id, INSTANCE_DEFAULT, message_p) < 0) {
-        LOG_E(UDP_, "Failed to send message %d to task %d\n",
-              UDP_DATA_IND,
-              udp_sock_pP->task_id);
-        itti_free(TASK_UDP, message_p);
-        itti_free(TASK_UDP, forwarded_buffer);
-        return;
-      }
-    }
-  }
-
-  //close(udp_sock_p->sd);
-  //udp_sock_p->sd = -1;
-
-  //pthread_mutex_lock(&udp_socket_list_mutex);
-  //STAILQ_REMOVE(&udp_socket_list, udp_sock_p, udp_socket_desc_s, entries);
-  //pthread_mutex_unlock(&udp_socket_list_mutex);
-}
-
-
-void *udp_eNB_task(void *args_p)
-{
-  int                 nb_events;
-  struct epoll_event *events;
-  MessageDef         *received_message_p    = NULL;
-  //const char         *msg_name = NULL;
-  //instance_t          instance  = 0;
-  udp_enb_init();
-
-  itti_mark_task_ready(TASK_UDP);
-  MSC_START_USE();
-
-  while(1) {
-    itti_receive_msg(TASK_UDP, &received_message_p);
-    VCD_SIGNAL_DUMPER_DUMP_FUNCTION_BY_NAME(VCD_SIGNAL_DUMPER_FUNCTIONS_UDP_ENB_TASK, VCD_FUNCTION_IN);
-#if defined(LOG_UDP) && LOG_UDP > 0
-    LOG_D(UDP_, "Got message %p\n", &received_message_p);
-#endif
-
-    if (received_message_p != NULL) {
-
-      //msg_name = ITTI_MSG_NAME (received_message_p);
-      //instance = ITTI_MSG_DESTINATION_INSTANCE (received_message_p);
-
-      switch (ITTI_MSG_ID(received_message_p)) {
-      case UDP_INIT: {
-        LOG_D(UDP_, "Received UDP_INIT\n");
-        udp_init_t *udp_init_p;
-        udp_init_p = &received_message_p->ittiMsg.udp_init;
-        udp_eNB_create_socket(
-          udp_init_p->port,
-          udp_init_p->address,
-          ITTI_MSG_ORIGIN_ID(received_message_p));
-      }
-      break;
-
-      case UDP_DATA_REQ: {
-#if defined(LOG_UDP) && LOG_UDP > 0
-        LOG_D(UDP_, "Received UDP_DATA_REQ\n");
-#endif
-        int     udp_sd = -1;
-        ssize_t bytes_written;
-
-        struct udp_socket_desc_s *udp_sock_p = NULL;
-        udp_data_req_t           *udp_data_req_p;
-        struct sockaddr_in        peer_addr;
-
-        udp_data_req_p = &received_message_p->ittiMsg.udp_data_req;
-
-        memset(&peer_addr, 0, sizeof(struct sockaddr_in));
-
-        peer_addr.sin_family       = AF_INET;
-        peer_addr.sin_port         = htons(udp_data_req_p->peer_port);
-        peer_addr.sin_addr.s_addr  = udp_data_req_p->peer_address;
-
-        pthread_mutex_lock(&udp_socket_list_mutex);
-        udp_sock_p = udp_eNB_get_socket_desc(ITTI_MSG_ORIGIN_ID(received_message_p));
-
-        if (udp_sock_p == NULL) {
-          LOG_E(UDP_,
-                "Failed to retrieve the udp socket descriptor "
-                "associated with task %d\n",
-                ITTI_MSG_ORIGIN_ID(received_message_p));
-          pthread_mutex_unlock(&udp_socket_list_mutex);
-
-          if (udp_data_req_p->buffer) {
-            itti_free(ITTI_MSG_ORIGIN_ID(received_message_p), udp_data_req_p->buffer);
-          }
-
-          goto on_error;
-        }
-
-        udp_sd = udp_sock_p->sd;
-        pthread_mutex_unlock(&udp_socket_list_mutex);
-
-//#if defined(LOG_UDP) && LOG_UDP > 0
-        LOG_D(UDP_, "[%d] Sending message of size %u to "IPV4_ADDR" and port %u\n",
-              udp_sd,
-              udp_data_req_p->buffer_length,
-              IPV4_ADDR_FORMAT(udp_data_req_p->peer_address),
-              udp_data_req_p->peer_port);
-//#endif
-        bytes_written = sendto(
-                          udp_sd,
-                          &udp_data_req_p->buffer[udp_data_req_p->buffer_offset],
-                          udp_data_req_p->buffer_length,
-                          0,
-                          (struct sockaddr *)&peer_addr,
-                          sizeof(struct sockaddr_in));
-
-        if (bytes_written != udp_data_req_p->buffer_length) {
-          LOG_E(UDP_, "There was an error while writing to socket %d rc %zd"
-                "(%d:%s) May be normal if GTPU kernel module loaded on same host (may NF_DROP IP packet)\n",
-                udp_sd, bytes_written, errno, strerror(errno));
-        }
-
-        itti_free(ITTI_MSG_ORIGIN_ID(received_message_p), udp_data_req_p->buffer);
-      }
-      break;
-
-      case TERMINATE_MESSAGE: {
-        LOG_W(UDP_, " *** Exiting UDP thread\n");
-        itti_exit_task();
-      }
-      break;
-
-      case MESSAGE_TEST: {
-      } break;
-
-      default: {
-        LOG_W(UDP_, "Unkwnon message ID %d:%s\n",
-              ITTI_MSG_ID(received_message_p),
-              ITTI_MSG_NAME(received_message_p));
-      }
-      break;
-      }
-
-on_error:
-      itti_free (ITTI_MSG_ORIGIN_ID(received_message_p), received_message_p);
-      received_message_p = NULL;
-    }
-
-    nb_events = itti_get_events(TASK_UDP, &events);
-
-    /* Now handle notifications for other sockets */
-    if (nb_events > 0) {
-#if defined(LOG_UDP) && LOG_UDP > 0
-      LOG_D(UDP_, "UDP task Process %d events\n",nb_events);
-#endif
-      udp_eNB_process_file_descriptors(events, nb_events);
-    }
-
-    VCD_SIGNAL_DUMPER_DUMP_FUNCTION_BY_NAME(VCD_SIGNAL_DUMPER_FUNCTIONS_UDP_ENB_TASK, VCD_FUNCTION_OUT);
-  }
-
-  LOG_I(UDP_, "Task UDP eNB exiting\n");
-  return NULL;
-}
-
-int udp_enb_init(void)
-{
-  LOG_I(UDP_, "Initializing UDP task interface\n");
-  STAILQ_INIT(&udp_socket_list);
-  LOG_I(UDP_, "Initializing UDP task interface: DONE\n");
-  return 0;
-}
diff --git a/openair3/UDP/udp_eNB_task.h b/openair3/UDP/udp_eNB_task.h
deleted file mode 100644
index 8b783f7455c..00000000000
--- a/openair3/UDP/udp_eNB_task.h
+++ /dev/null
@@ -1,97 +0,0 @@
-/*
- * Licensed to the OpenAirInterface (OAI) Software Alliance under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The OpenAirInterface Software Alliance licenses this file to You under
- * the OAI Public License, Version 1.1  (the "License"); you may not use this file
- * except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.openairinterface.org/?page_id=698
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- *-------------------------------------------------------------------------------
- * For more information about the OpenAirInterface (OAI) Software Alliance:
- *      contact@openairinterface.org
- */
-
-/*! \file udp_eNB_task.h
-* \brief
-* \author Sebastien ROUX, Lionel Gauthier
-* \company Eurecom
-* \email: lionel.gauthier@eurecom.fr
-*/
-#include <pthread.h>
-#include <stdint.h>
-
-#ifndef UDP_ENB_TASK_H_
-#define UDP_ENB_TASK_H_
-#include "enb_config.h"
-
-
-/** \brief UDP recv callback prototype. Will be called every time a payload is
- *  received on socket.
- *  \param port Port on which data had been received
- *  \param address Sender Ipv4 address
- *  \param buffer Pointer to data (should be freed by user)
- *  \param length Length of message received
- *  \param arg_p User provided argument (transparent for wrappers)
- *  @returns Execution result
- */
-typedef int (*udp_recv_callback)(uint16_t  port,
-                                 uint32_t  address,
-                                 uint8_t  *buffer,
-                                 uint32_t  length,
-                                 void     *arg_p);
-
-typedef struct {
-  int       sd;              /* Socket descriptor to use */
-  pthread_t listener_thread; /* Thread affected to recv */
-  char     *local_address;   /* Local ipv4 address to use */
-  uint16_t  local_port;      /* Local port to use */
-  task_id_t task_id;         /* Task who has requested the new endpoint */
-} udp_data_t;
-
-/** \brief Create new datagram connection-less socket and create new thread
- *  for data in downstream.
- *  \param ip_addr Local IPv4 address to use
- *  \param port Local port to use
- *  \param udp_data_p
- *  \param recv_callback Pointer to data (should be freed by user)
- *  \param arg_p Optionnal argument to pass to recv_callback
- *  @returns < 0 on failure or socket descriptor on success
- */
-int udp_create_connection(char *ip_addr, uint16_t port,
-                          udp_data_t *udp_data_p,
-                          udp_recv_callback recv_callback,
-                          void *arg_p);
-
-/** \brief Send buffer to remote peer.
- *  \param sd socket descriptor to use
- *  \param port remote port
- *  \param address remote address
- *  \param buffer Data buffer to send
- *  \param length Buffer length
- *  @returns < 0 on failure or socket descriptor on success
- */
-int udp_send_to(int sd, uint16_t port, uint32_t address,
-                const uint8_t *buffer, uint32_t length);
-
-
-/** \brief UDP ITTI task on eNB.
- *  \param args_p
- *  @returns always NULL
- */
-void *udp_eNB_task(void *args_p);
-
-/** \brief init UDP layer.
- *  \param enb_config_p configuration of eNB
- *  @returns always 0
- */
-int udp_enb_init(void);
-
-#endif /* UDP_ENB_TASK_H_ */
diff --git a/openair3/ocp-gtpu/gtp_itf.cpp b/openair3/ocp-gtpu/gtp_itf.cpp
index 64146bc7cac..379ec415dc8 100644
--- a/openair3/ocp-gtpu/gtp_itf.cpp
+++ b/openair3/ocp-gtpu/gtp_itf.cpp
@@ -46,7 +46,7 @@ typedef struct Gtpv1uMsgHeader {
 #define GTP_GPDU                                             (255)
 
 
-typedef struct ocp_gtpv1u_bearer_s {
+typedef struct gtpv1u_bearer_s {
   /* TEID used in dl and ul */
   teid_t          teid_incoming;                ///< eNB TEID
   teid_t          teid_outgoing;                ///< Remote TEID
@@ -55,10 +55,10 @@ typedef struct ocp_gtpv1u_bearer_s {
   tcp_udp_port_t  outgoing_port;
   uint16_t        seqNum;
   uint8_t         npduNum;
-} ocp_gtpv1u_bearer_t;
+} gtpv1u_bearer_t;
 
 typedef struct {
-  map<int, ocp_gtpv1u_bearer_t> bearers;
+  map<int, gtpv1u_bearer_t> bearers;
 } teidData_t;
 
 typedef struct {
@@ -173,7 +173,7 @@ static void gtpv1uSend(instance_t instance, gtpv1u_enb_tunnel_data_req_t *req, b
     return;
   }
 
-  map<int, ocp_gtpv1u_bearer_t>::iterator ptr2=ptrRnti->second.bearers.find(rab_id);
+  map<int, gtpv1u_bearer_t>::iterator ptr2=ptrRnti->second.bearers.find(rab_id);
 
   if ( ptr2 == ptrRnti->second.bearers.end() ) {
     LOG_E(GTPU,"[%ld] GTP-U instance: sending a packet to a non existant RNTI:RAB: %x/%x\n", instance, rnti, rab_id);
@@ -191,7 +191,7 @@ static void gtpv1uSend(instance_t instance, gtpv1u_enb_tunnel_data_req_t *req, b
     ptr2->second.npduNum++;
 
   // copy to release the mutex
-  ocp_gtpv1u_bearer_t tmp=ptr2->second;
+  gtpv1u_bearer_t tmp=ptr2->second;
   pthread_mutex_unlock(&globGtp.gtp_lock);
   gtpv1uCreateAndSendMsg(compatInst(instance),
                          tmp.outgoing_ip_addr,
@@ -216,7 +216,7 @@ static void gtpv1uSend2(instance_t instance, gtpv1u_gnb_tunnel_data_req_t *req,
     return;
   }
 
-  map<int, ocp_gtpv1u_bearer_t>::iterator ptr2=ptrRnti->second.bearers.find(rab_id);
+  map<int, gtpv1u_bearer_t>::iterator ptr2=ptrRnti->second.bearers.find(rab_id);
 
   if ( ptr2 == ptrRnti->second.bearers.end() ) {
     LOG_D(GTPU,"GTP-U instance: %ld sending a packet to a non existant RNTI:RAB: %x/%x\n", instance, rnti, rab_id);
@@ -234,7 +234,7 @@ static void gtpv1uSend2(instance_t instance, gtpv1u_gnb_tunnel_data_req_t *req,
     ptr2->second.npduNum++;
 
   // copy to release the mutex
-  ocp_gtpv1u_bearer_t tmp=ptr2->second;
+  gtpv1u_bearer_t tmp=ptr2->second;
   pthread_mutex_unlock(&globGtp.gtp_lock);
   gtpv1uCreateAndSendMsg(compatInst(instance),
                          tmp.outgoing_ip_addr,
@@ -257,7 +257,7 @@ static void gtpv1uEndTunnel(instance_t instance, gtpv1u_enb_tunnel_data_req_t *r
     return;
   }
 
-  map<int, ocp_gtpv1u_bearer_t>::iterator ptr2=ptrRnti->second.bearers.find(rab_id);
+  map<int, gtpv1u_bearer_t>::iterator ptr2=ptrRnti->second.bearers.find(rab_id);
 
   if ( ptr2 == ptrRnti->second.bearers.end() ) {
     LOG_E(GTPU,"[%ld] GTP-U sending a packet to a non existant RNTI:RAB: %x/%x\n", instance, rnti, rab_id);
@@ -267,7 +267,7 @@ static void gtpv1uEndTunnel(instance_t instance, gtpv1u_enb_tunnel_data_req_t *r
 
   LOG_D(GTPU,"[%ld] sending a end packet packet to RNTI:RAB:teid %x/%x/%x\n",
         instance, rnti, rab_id,ptr2->second.teid_outgoing);
-  ocp_gtpv1u_bearer_t tmp=ptr2->second;
+  gtpv1u_bearer_t tmp=ptr2->second;
   pthread_mutex_unlock(&globGtp.gtp_lock);
   Gtpv1uMsgHeaderT  msgHdr;
   // N should be 0 for us (it was used only in 2G and 3G)
@@ -383,12 +383,12 @@ static  int udpServerSocket(openAddr_s addr) {
   return sockfd;
 }
 
-instance_t ocp_gtpv1Init(openAddr_t context) {
+instance_t gtpv1Init(openAddr_t context) {
   pthread_mutex_lock(&globGtp.gtp_lock);
   int id=udpServerSocket(context);
 
   if (id>=0) {
-    itti_subscribe_event_fd(OCP_GTPV1_U, id);
+    itti_subscribe_event_fd(TASK_GTPV1_U, id);
   } else
     LOG_E(GTPU,"can't create GTP-U instance\n");
 
@@ -408,7 +408,7 @@ void GtpuUpdateTunnelOutgoingTeid(instance_t instance, rnti_t rnti, ebi_t bearer
     return;
   }
 
-  map<int, ocp_gtpv1u_bearer_t>::iterator ptr2=ptrRnti->second.bearers.find(bearer_id);
+  map<int, gtpv1u_bearer_t>::iterator ptr2=ptrRnti->second.bearers.find(bearer_id);
 
   if ( ptr2 == ptrRnti->second.bearers.end() ) {
     LOG_E(GTPU,"[%ld] Update tunnel for a existing rnti %x, but wrong bearer_id %u\n", instance, rnti, bearer_id);
@@ -447,7 +447,7 @@ teid_t newGtpuCreateTunnel(instance_t instance, rnti_t rnti, int incoming_bearer
 
   inst->te2ue_mapping[incoming_teid].callBack=callBack;
 
-  ocp_gtpv1u_bearer_t *tmp=&inst->ue2te_mapping[rnti].bearers[outgoing_bearer_id];
+  gtpv1u_bearer_t *tmp=&inst->ue2te_mapping[rnti].bearers[outgoing_bearer_id];
 
   int addrs_length_in_bytes = remoteAddr.length / 8;
 
@@ -487,7 +487,7 @@ teid_t newGtpuCreateTunnel(instance_t instance, rnti_t rnti, int incoming_bearer
   return incoming_teid;
 }
 
-int ocp_gtpv1u_create_s1u_tunnel(instance_t instance,
+int gtpv1u_create_s1u_tunnel(instance_t instance,
                                  const gtpv1u_enb_create_tunnel_req_t  *create_tunnel_req,
                                  gtpv1u_enb_create_tunnel_resp_t *create_tunnel_resp) {
   LOG_D(GTPU, "[%ld] Start create tunnels for RNTI %x, num_tunnels %d, sgw_S1u_teid %x\n",
@@ -521,7 +521,7 @@ int ocp_gtpv1u_create_s1u_tunnel(instance_t instance,
   return !GTPNOK;
 }
 
-int ocp_gtpv1u_update_s1u_tunnel(
+int gtpv1u_update_s1u_tunnel(
   const instance_t                              instance,
   const gtpv1u_enb_create_tunnel_req_t *const  create_tunnel_req,
   const rnti_t                                  prior_rnti
@@ -546,7 +546,7 @@ int ocp_gtpv1u_update_s1u_tunnel(
     LOG_W(GTPU,"[%ld] Update a not existing tunnel, start create the new one (new rnti %x, old rnti %x)\n", instance, create_tunnel_req->rnti, prior_rnti);
     pthread_mutex_unlock(&globGtp.gtp_lock);
     gtpv1u_enb_create_tunnel_resp_t tmp;
-    (void)ocp_gtpv1u_create_s1u_tunnel(instance, create_tunnel_req, &tmp);
+    (void)gtpv1u_create_s1u_tunnel(instance, create_tunnel_req, &tmp);
     return 0;
   }
 
@@ -593,14 +593,14 @@ int gtpv1u_update_ngu_tunnel(
   return GTPNOK;
 }
 
-int ocp_gtpv1u_create_x2u_tunnel(
+int gtpv1u_create_x2u_tunnel(
   const instance_t instanceP,
   const gtpv1u_enb_create_x2u_tunnel_req_t   *const create_tunnel_req_pP,
   gtpv1u_enb_create_x2u_tunnel_resp_t *const create_tunnel_resp_pP) {
   AssertFatal( false, "to be developped\n");
 }
 
-int newGtpuDeleteTunnel(instance_t instance, rnti_t rnti) {
+  int newGtpuDeleteAllTunnels(instance_t instance, rnti_t rnti) {
   LOG_D(GTPU, "[%ld] Start delete tunnels for RNTI %x\n",
         instance, rnti);
   pthread_mutex_lock(&globGtp.gtp_lock);
@@ -627,20 +627,58 @@ int newGtpuDeleteTunnel(instance_t instance, rnti_t rnti) {
   LOG_I(GTPU, "[%ld] Deleted all tunnels for RNTI %x (%d tunnels deleted)\n", instance, rnti, nb);
   return !GTPNOK;
 }
-
-// Legacy delete tunnel finish by deleting all the rnti
-// so the list of bearer provided is only a design bug
-int ocp_gtpv1u_delete_s1u_tunnel( const instance_t instance,
+  
+  // Legacy delete tunnel finish by deleting all the rnti
+  // so the list of bearer provided is only a design bug
+  int gtpv1u_delete_s1u_tunnel( const instance_t instance,
                                   const gtpv1u_enb_delete_tunnel_req_t *const req_pP) {
-  return  newGtpuDeleteTunnel(instance, req_pP->rnti);
+  return  newGtpuDeleteAllTunnels(instance, req_pP->rnti);
 }
+  
+  int newGtpuDeleteTunnels(instance_t instance, rnti_t rnti, int nbTunnels, pdusessionid_t *pdusession_id) {
+  LOG_D(GTPU, "[%ld] Start delete tunnels for RNTI %x\n",
+        instance, rnti);
+  pthread_mutex_lock(&globGtp.gtp_lock);
+  auto inst=&globGtp.instances[compatInst(instance)];
+  auto ptrRNTI=inst->ue2te_mapping.find(rnti);
+
+  if ( ptrRNTI == inst->ue2te_mapping.end() ) {
+    LOG_W(GTPU,"[%ld] Delete GTP tunnels for rnti: %x, but no tunnel exits\n", instance, rnti);
+    pthread_mutex_unlock(&globGtp.gtp_lock);
+    return -1;
+  }
+
+  int nb=0;
 
+  for (int i=0; i<nbTunnels; i++) {
+    auto ptr2=ptrRNTI->second.bearers.find(pdusession_id[i]);
+    if ( ptr2 == ptrRNTI->second.bearers.end() ) {
+      LOG_E(GTPU,"[%ld] GTP-U instance: delete of not existing tunnel RNTI:RAB: %x/%x\n", instance, rnti,pdusession_id[i]);
+    } else {
+      inst->te2ue_mapping.erase(ptr2->second.teid_incoming);
+      nb++;
+    }
+  }
+  
+  if (ptrRNTI->second.bearers.size() == 0 )
+    // no tunnels on this rnti, erase the ue entry
+    inst->ue2te_mapping.erase(ptrRNTI);
+  pthread_mutex_unlock(&globGtp.gtp_lock);
+  LOG_I(GTPU, "[%ld] Deleted all tunnels for RNTI %x (%d tunnels deleted)\n", instance, rnti, nb);
+  return !GTPNOK;
+  }
+  
 int gtpv1u_delete_x2u_tunnel( const instance_t instanceP,
-                              const gtpv1u_enb_delete_tunnel_req_t *const req_pP,
-                              int enbflag) {
+                              const gtpv1u_enb_delete_tunnel_req_t *const req_pP) {
+  LOG_E(GTPU,"x2 tunnel not implemented\n");
   return 0;
 }
-
+  
+int gtpv1u_delete_ngu_tunnel( const instance_t instance,
+                                  gtpv1u_gnb_delete_tunnel_req_t * req) {
+  return  newGtpuDeleteTunnels(instance, req->rnti, req->num_pdusession, req->pdusession_id);
+}
+  
 static int Gtpv1uHandleEchoReq(int h,
                                uint8_t *msgBuf,
                                uint32_t msgBufLen,
@@ -871,14 +909,14 @@ void gtpv1uReceiver(int h) {
 
 #include <openair2/ENB_APP/enb_paramdef.h>
 
-void *ocp_gtpv1uTask(void *args)  {
+void *gtpv1uTask(void *args)  {
   while(1) {
     /* Trying to fetch a message from the message queue.
        If the queue is empty, this function will block till a
        message is sent to the task.
     */
     MessageDef *message_p = NULL;
-    itti_receive_msg(OCP_GTPV1_U, &message_p);
+    itti_receive_msg(TASK_GTPV1_U, &message_p);
 
     if (message_p != NULL ) {
       openAddr_t addr= {0};
@@ -888,7 +926,7 @@ void *ocp_gtpv1uTask(void *args)  {
         case GTPV1U_ENB_TUNNEL_DATA_REQ: {
           gtpv1uSend(compatInst(ITTI_MSG_DESTINATION_INSTANCE(message_p)),
                      &GTPV1U_ENB_TUNNEL_DATA_REQ(message_p), false, false);
-          itti_free(OCP_GTPV1_U, GTPV1U_ENB_TUNNEL_DATA_REQ(message_p).buffer);
+          itti_free(TASK_GTPV1_U, GTPV1U_ENB_TUNNEL_DATA_REQ(message_p).buffer);
         }
         break;
 
@@ -908,7 +946,7 @@ void *ocp_gtpv1uTask(void *args)  {
         case GTPV1U_ENB_END_MARKER_REQ:
           gtpv1uEndTunnel(compatInst(ITTI_MSG_DESTINATION_INSTANCE(message_p)),
                           &GTPV1U_ENB_TUNNEL_DATA_REQ(message_p));
-          itti_free(OCP_GTPV1_U, GTPV1U_ENB_TUNNEL_DATA_REQ(message_p).buffer);
+          itti_free(TASK_GTPV1_U, GTPV1U_ENB_TUNNEL_DATA_REQ(message_p).buffer);
           break;
 
         case GTPV1U_ENB_DATA_FORWARDING_REQ:
@@ -923,7 +961,7 @@ void *ocp_gtpv1uTask(void *args)  {
           strcpy(addr.originHost, GTPV1U_REQ(message_p).localAddrStr);
           strcpy(addr.originService, GTPV1U_REQ(message_p).localPortStr);
           strcpy(addr.destinationService,addr.originService);
-          AssertFatal((legacyInstanceMapping=ocp_gtpv1Init(addr))!=0,"Instance 0 reserved for legacy\n");
+          AssertFatal((legacyInstanceMapping=gtpv1Init(addr))!=0,"Instance 0 reserved for legacy\n");
           break;
 
         default:
@@ -932,12 +970,12 @@ void *ocp_gtpv1uTask(void *args)  {
           break;
       }
 
-      AssertFatal(EXIT_SUCCESS==itti_free(OCP_GTPV1_U, message_p), "Failed to free memory!\n");
+      AssertFatal(EXIT_SUCCESS==itti_free(TASK_GTPV1_U, message_p), "Failed to free memory!\n");
     }
 
     struct epoll_event *events;
 
-    int nb_events = itti_get_events(OCP_GTPV1_U, &events);
+    int nb_events = itti_get_events(TASK_GTPV1_U, &events);
 
     for (int i = 0; i < nb_events; i++)
       if ((events[i].events&EPOLLIN))
diff --git a/openair3/ocp-gtpu/gtp_itf.h b/openair3/ocp-gtpu/gtp_itf.h
index 3893acf40f0..22a86bc8878 100644
--- a/openair3/ocp-gtpu/gtp_itf.h
+++ b/openair3/ocp-gtpu/gtp_itf.h
@@ -8,19 +8,6 @@
 extern "C" {
 #endif
 
-#include <openair3/GTPV1-U/gtpv1u_eNB_defs.h>
-#if defined(NEW_GTPU)
-#define gtpv1u_create_s1u_tunnel ocp_gtpv1u_create_s1u_tunnel
-#define gtpv1u_update_s1u_tunnel ocp_gtpv1u_update_s1u_tunnel
-#define gtpv1u_delete_s1u_tunnel ocp_gtpv1u_delete_s1u_tunnel
-#define gtpv1u_create_x2u_tunnel ocp_gtpv1u_create_x2u_tunnel
-#define gtpv1u_eNB_task          ocp_gtpv1uTask
-#define nr_gtpv1u_gNB_task       ocp_gtpv1uTask
-#define TASK_VARIABLE            OCP_GTPV1_U
-#else
-#define TASK_VARIABLE            TASK_GTPV1_U
-#endif
-
 typedef boolean_t (*gtpCallback)(
   protocol_ctxt_t  *ctxt_pP,
   const srb_flag_t     srb_flagP,
@@ -43,18 +30,18 @@ typedef struct openAddr_s {
 
 // the init function create a gtp instance and return the gtp instance id
 // the parameter originInstance will be sent back in each message from gtp to the creator
-void ocp_gtpv1uReceiver(int h);
-void ocp_gtpv1uProcessTimeout(int handle,void *arg);
-int ocp_gtpv1u_create_s1u_tunnel(const instance_t instance, const gtpv1u_enb_create_tunnel_req_t  *create_tunnel_req,
+void gtpv1uReceiver(int h);
+void gtpv1uProcessTimeout(int handle,void *arg);
+int gtpv1u_create_s1u_tunnel(const instance_t instance, const gtpv1u_enb_create_tunnel_req_t  *create_tunnel_req,
                                  gtpv1u_enb_create_tunnel_resp_t *create_tunnel_resp);
-int ocp_gtpv1u_update_s1u_tunnel(const instance_t instanceP,
+int gtpv1u_update_s1u_tunnel(const instance_t instanceP,
                                  const gtpv1u_enb_create_tunnel_req_t   *create_tunnel_req_pP,
                                  const rnti_t prior_rnti
                                 );
-int ocp_gtpv1u_delete_s1u_tunnel( const instance_t instance, const gtpv1u_enb_delete_tunnel_req_t *const req_pP);
+int gtpv1u_delete_s1u_tunnel( const instance_t instance, const gtpv1u_enb_delete_tunnel_req_t *const req_pP);
 int gtpv1u_delete_s1u_tunnel( const instance_t instance, const gtpv1u_enb_delete_tunnel_req_t *const req_pP);
 
-int ocp_gtpv1u_create_x2u_tunnel(
+int gtpv1u_create_x2u_tunnel(
   const instance_t instanceP,
   const gtpv1u_enb_create_x2u_tunnel_req_t   *const create_tunnel_req_pP,
   gtpv1u_enb_create_x2u_tunnel_resp_t *const create_tunnel_resp_pP);
@@ -64,8 +51,10 @@ int ocp_gtpv1u_create_x2u_tunnel(
 teid_t newGtpuCreateTunnel(instance_t instance, rnti_t rnti, int incoming_bearer_id, int outgoing_rb_id, teid_t teid,
                            transport_layer_addr_t remoteAddr, int port, gtpCallback callBack);
 void GtpuUpdateTunnelOutgoingTeid(instance_t instance, rnti_t rnti, ebi_t bearer_id, teid_t newOutgoingTeid);
-instance_t ocp_gtpv1Init(openAddr_t context);
-void *ocp_gtpv1uTask(void *args);
+int newGtpuDeleteAllTunnels(instance_t instance, rnti_t rnti);
+  int newGtpuDeleteTunnels(instance_t instance, rnti_t rnti, int nbTunnels, pdusessionid_t *pdusession_id);
+instance_t gtpv1Init(openAddr_t context);
+void *gtpv1uTask(void *args);
 
 #ifdef __cplusplus
 }
diff --git a/openair3/GTPV1-U/gtpv1u_eNB_defs.h b/openair3/ocp-gtpu/gtpv1u_eNB_task.h
similarity index 61%
rename from openair3/GTPV1-U/gtpv1u_eNB_defs.h
rename to openair3/ocp-gtpu/gtpv1u_eNB_task.h
index fb317e4ca6f..dbfb6ae917e 100644
--- a/openair3/GTPV1-U/gtpv1u_eNB_defs.h
+++ b/openair3/ocp-gtpu/gtpv1u_eNB_task.h
@@ -19,32 +19,23 @@
  *      contact@openairinterface.org
  */
 
-/*! \file gtpv1u_eNB_defs.h
- * \brief
- * \author Sebastien ROUX, Lionel GAUTHIER
- * \version 1.0
- * \company Eurecom
- * \email: lionel.gauthier@eurecom.fr
- */
-
-#include "hashtable.h"
-#include "LTE_asn_constant.h"
+/*! \file gtpv1u_eNB_task.h
+* \brief
+* \author Lionel Gauthier
+* \company Eurecom
+* \email: lionel.gauthier@eurecom.fr
+*/
 
-#ifndef GTPV1U_ENB_DEFS_H_
-#define GTPV1U_ENB_DEFS_H_
+#ifndef GTPV1U_ENB_TASK_H_
+#define GTPV1U_ENB_TASK_H_
 
-#include "NwGtpv1u.h"
+typedef struct gtpv1u_data_s {
+ /* RB tree of UEs */
+  hash_table_t         *ue_mapping; 
+} gtpv1u_data_t;
 
-#define GTPV1U_UDP_PORT (2152)
 #define GTPV1U_BEARER_OFFSET 3
-
 #define GTPV1U_MAX_BEARERS_ID     (max_val_LTE_DRB_Identity - GTPV1U_BEARER_OFFSET)
-
-#define GTPV1U_SOURCE_ENB (0)
-#define GTPV1U_TARGET_ENB (1)
-#define GTPV1U_MSG_FROM_SOURCE_ENB (0)
-#define GTPV1U_MSG_FROM_SPGW (1)
-
 typedef enum {
   BEARER_DOWN = 0,
   BEARER_IN_CONFIG,
@@ -54,16 +45,7 @@ typedef enum {
   BEARER_MAX,
 } bearer_state_t;
 
-
-typedef struct gtpv1u_teid_data_s {
-  /* UE identifier for oaisim stack */
-  module_id_t  enb_id;
-  rnti_t       ue_id;
-  ebi_t        eps_bearer_id;
-} gtpv1u_teid_data_t;
-
-
-typedef struct gtpv1u_bearer_s {
+typedef struct fixMe_gtpv1u_bearer_s {
   /* TEID used in dl and ul */
   teid_t          teid_eNB;                ///< eNB TEID
   uintptr_t       teid_eNB_stack_session;  ///< eNB TEID
@@ -76,7 +58,7 @@ typedef struct gtpv1u_bearer_s {
   tcp_udp_port_t  port;
   //NwGtpv1uStackSessionHandleT stack_session;
   bearer_state_t state;
-} gtpv1u_bearer_t;
+} fixMe_gtpv1u_bearer_t;
 
 typedef struct gtpv1u_ue_data_s {
   /* UE identifier for oaisim stack */
@@ -89,45 +71,43 @@ typedef struct gtpv1u_ue_data_s {
    * Note that the first LCID available for data is 3 and we fixed the maximum
    * number of e-rab per UE to be (32 [id range]), max RB is 11. The real rb id will 3 + rab_id (3..32).
    */
-  gtpv1u_bearer_t bearers[GTPV1U_MAX_BEARERS_ID];
+  fixMe_gtpv1u_bearer_t bearers[GTPV1U_MAX_BEARERS_ID];
 
   //RB_ENTRY(gtpv1u_ue_data_s) gtpv1u_ue_node;
 } gtpv1u_ue_data_t;
+/*
+int
+gtpv1u_new_data_req(
+  uint8_t enb_id,
+  uint8_t ue_id,
+  uint8_t rab_id,
+  uint8_t *buffer,
+  uint32_t buf_len,
+  uint32_t buf_offset);*/
 
-typedef struct gtpv1u_data_s {
-  /* nwgtpv1u stack internal data */
-  NwGtpv1uStackHandleT  gtpv1u_stack;
-
-  /* RB tree of UEs */
-  hash_table_t         *ue_mapping;   // PDCP->GTPV1U
-  hash_table_t         *teid_mapping; // GTPV1U -> PDCP
-
-  //RB_HEAD(gtpv1u_ue_map, gtpv1u_ue_data_s) gtpv1u_ue_map_head;
-  /* Local IP address to use */
-  in_addr_t             enb_ip_address_for_S1u_S12_S4_up;
-  /* UDP internal data */
-  //udp_data_t            udp_data;
-
-  uint16_t              seq_num;
-  uint8_t               restart_counter;
-
-} gtpv1u_data_t;
+int   gtpv1u_eNB_init(void);
+void *gtpv1u_eNB_process_itti_msg(void*);
+void *gtpv1u_eNB_task(void *args);
 
 int
-gtpv1u_new_data_req(
-  uint8_t  enb_module_idP,
-  rnti_t   ue_rntiP,
-  uint8_t  rab_idP,
-  uint8_t *buffer_pP,
-  uint32_t buf_lenP,
-  uint32_t buf_offsetP
-);
+gtpv1u_create_x2u_tunnel(
+  const instance_t instanceP,
+  const gtpv1u_enb_create_x2u_tunnel_req_t *  const create_tunnel_req_pP,
+        gtpv1u_enb_create_x2u_tunnel_resp_t * const create_tunnel_resp_pP);
 
 int
-gtpv1u_initial_req(
-  gtpv1u_data_t *gtpv1u_data_p,
-  uint32_t teid,
-  uint16_t port,
-  uint32_t address);
+gtpv1u_create_s1u_tunnel(
+  const instance_t instanceP,
+  const gtpv1u_enb_create_tunnel_req_t *  const create_tunnel_req_pP,
+        gtpv1u_enb_create_tunnel_resp_t * const create_tunnel_resp_pP);
 
-#endif /* GTPV1U_ENB_DEFS_H_ */
+int
+gtpv1u_update_s1u_tunnel(
+    const instance_t                              instanceP,
+    const gtpv1u_enb_create_tunnel_req_t * const  create_tunnel_req_pP,
+    const rnti_t                                  prior_rnti);
+
+int gtpv1u_delete_x2u_tunnel(
+  const instance_t                             instanceP,
+  const gtpv1u_enb_delete_tunnel_req_t * const req_pP);
+#endif /* GTPV1U_ENB_TASK_H_ */
diff --git a/openair3/GTPV1-U/gtpv1u_gNB_task.h b/openair3/ocp-gtpu/gtpv1u_gNB_task.h
similarity index 94%
rename from openair3/GTPV1-U/gtpv1u_gNB_task.h
rename to openair3/ocp-gtpu/gtpv1u_gNB_task.h
index fcfaa90304f..cc36ee26fc1 100644
--- a/openair3/GTPV1-U/gtpv1u_gNB_task.h
+++ b/openair3/ocp-gtpu/gtpv1u_gNB_task.h
@@ -47,5 +47,8 @@ gtpv1u_update_ngu_tunnel(
   const rnti_t                                  prior_rnti
 );
 
+int gtpv1u_delete_ngu_tunnel( const instance_t instance,
+			      gtpv1u_gnb_delete_tunnel_req_t *req);
+
 #endif /* GTPV1U_GNB_TASK_H_ */
 
diff --git a/targets/COMMON/create_tasks.c b/targets/COMMON/create_tasks.c
index 4463228dc73..a6ae906d9d9 100644
--- a/targets/COMMON/create_tasks.c
+++ b/targets/COMMON/create_tasks.c
@@ -28,7 +28,6 @@
   #include "sctp_eNB_task.h"
   #include "x2ap_eNB.h"
   #include "s1ap_eNB.h"
-  #include "udp_eNB_task.h"
   #include "gtpv1u_eNB_task.h"
   #if ENABLE_RAL
     #include "lteRALue.h"
@@ -67,11 +66,7 @@ int create_tasks(uint32_t enb_nb) {
   if (EPC_MODE_ENABLED && !NODE_IS_DU(type) && ! ( split73==SPLIT73_DU ) ) {
     rc = itti_create_task(TASK_S1AP, s1ap_eNB_task, NULL);
     AssertFatal(rc >= 0, "Create task for S1AP failed\n");
-    if (!(get_softmodem_params()->emulate_rf)){
-      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_GTPV1_U, gtpv1uTask, NULL);
     AssertFatal(rc >= 0, "Create task for GTPV1U failed\n");
   }
 
@@ -91,7 +86,7 @@ int create_tasks(uint32_t enb_nb) {
     rc = itti_create_task(TASK_DU_F1, F1AP_DU_task, NULL);
     AssertFatal(rc >= 0, "Create task for DU F1AP failed\n");
     // DU is now GTP-U instead of protobuf
-    rc = itti_create_task(TASK_GTPV1_U, gtpv1u_eNB_task, NULL);
+    rc = itti_create_task(TASK_GTPV1_U, gtpv1uTask, NULL);
     AssertFatal(rc >= 0, "Create task for GTPV1U failed\n");
   }
 
diff --git a/targets/COMMON/create_tasks_mbms.c b/targets/COMMON/create_tasks_mbms.c
index 1cd3bb2f3a7..b82b4f158b1 100644
--- a/targets/COMMON/create_tasks_mbms.c
+++ b/targets/COMMON/create_tasks_mbms.c
@@ -28,7 +28,6 @@
     #include "sctp_eNB_task.h"
     #include "x2ap_eNB.h"
     #include "s1ap_eNB.h"
-    #include "udp_eNB_task.h"
     #include "gtpv1u_eNB_task.h"
     #include "m2ap_eNB.h"
     #include "m2ap_MCE.h"
@@ -75,46 +74,10 @@ int create_tasks_mbms(uint32_t enb_nb) {
   rc = itti_create_task (TASK_MCE_APP, MCE_app_task, NULL);
   AssertFatal(rc >= 0, "Create task for MCE APP failed\n");
 
-  
-//  LOG_I(ENB_APP, "Creating ENB_APP eNB Task\n");
-//  rc = itti_create_task (TASK_ENB_APP, eNB_app_task, NULL);
-//  AssertFatal(rc >= 0, "Create task for eNB APP failed\n");
-//
-//  LOG_I(RRC,"Creating RRC eNB Task\n");
-//  rc = itti_create_task (TASK_RRC_ENB, rrc_enb_task, NULL);
-//  AssertFatal(rc >= 0, "Create task for RRC eNB failed\n");
-//
-//  if (EPC_MODE_ENABLED) {
-//    rc = itti_create_task(TASK_SCTP, sctp_eNB_task, NULL);
-//    AssertFatal(rc >= 0, "Create task for SCTP failed\n");
-//  }
-// rc = itti_create_task(TASK_SCTP, sctp_eNB_task, NULL);
-//    AssertFatal(rc >= 0, "Create task for SCTP failed\n");
-//
-//
-//  if (EPC_MODE_ENABLED && !NODE_IS_DU(type)) {
-//    rc = itti_create_task(TASK_S1AP, s1ap_eNB_task, NULL);
-//    AssertFatal(rc >= 0, "Create task for S1AP failed\n");
-//    if (!(get_softmodem_params()->emulate_rf)){
-//      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);
-//    AssertFatal(rc >= 0, "Create task for GTPV1U failed\n");
-//    if (is_x2ap_enabled()) {
-//      rc = itti_create_task(TASK_X2AP, x2ap_task, NULL);
-//      AssertFatal(rc >= 0, "Create task for X2AP failed\n");
-//    } else {
-//      LOG_I(X2AP, "X2AP is disabled.\n");
-//    }
-//  }
-////
     if(!EPC_MODE_ENABLED){
    // rc = itti_create_task(TASK_SCTP, sctp_eNB_task, NULL);
    // 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_GTPV1_U, gtpv1uTask, NULL);
     AssertFatal(rc >= 0, "Create task for GTPV1U failed\n");
     }
 ///
diff --git a/targets/COMMON/create_tasks_ue.c b/targets/COMMON/create_tasks_ue.c
index 9341107af9b..cdca62c3990 100644
--- a/targets/COMMON/create_tasks_ue.c
+++ b/targets/COMMON/create_tasks_ue.c
@@ -27,7 +27,6 @@
   #include "sctp_eNB_task.h"
   #include "s1ap_eNB.h"
   #include "openair3/NAS/UE/nas_ue_task.h"
-  #include "udp_eNB_task.h"
   #include "gtpv1u_eNB_task.h"
   #if ENABLE_RAL
     #include "lteRALue.h"
diff --git a/targets/RT/USER/TOOLS/thread_ipc.h b/targets/RT/USER/TOOLS/thread_ipc.h
deleted file mode 100644
index ec008c30df2..00000000000
--- a/targets/RT/USER/TOOLS/thread_ipc.h
+++ /dev/null
@@ -1,83 +0,0 @@
-/*
- * Licensed to the OpenAirInterface (OAI) Software Alliance under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The OpenAirInterface Software Alliance licenses this file to You under
- * the OAI Public License, Version 1.1  (the "License"); you may not use this file
- * except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.openairinterface.org/?page_id=698
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- *-------------------------------------------------------------------------------
- * For more information about the OpenAirInterface (OAI) Software Alliance:
- *      contact@openairinterface.org
- */
-
-#ifndef __THREAD_IPC_H__
-#define __THREAD_IPC_H__
-
-
-#define SUB_FRAME_LENGTH 7680
-#define FRAME_LENGTH 76800
-
-#define UE_UL_DELAY 6       /*设置上行组帧在同步时钟基础上的延时(子帧个数)*/
-#define UE_UL_SEND_DELAY 6      /*上行发送子帧号在接收子帧时间戳上的延时(子帧个数)*/
-
-#define BUFFERMAX 5         /*环形缓冲区个数*/
-#define LOWBUFFER 3                 /*环形缓冲区下限, 不能为0*/
-#define HIGHBUFFER 4                /*环形缓冲区上限*/
-
-typedef struct {
-  long long subframe_num;     /*子帧编号*/
-  int buffer[SUB_FRAME_LENGTH * 2]; /*一子帧数据*/
-} buffer_t;
-
-typedef struct {
-  int packet_num;         /*环形缓冲区数据包计数器,表示环形缓冲区有效数据包个数*/
-  int isfull;           /*标记环形缓冲区有效数据包是否达到上限标志*/
-  int isempty;          /*标记环形缓冲区有效数据包是否达到下限标志*/
-
-  pthread_mutex_t buffer_mutex; /*环形缓冲区操作保护锁*/
-  pthread_cond_t full_cond;   /*环形缓冲区上限条件变量,配合isfull使用 */
-  pthread_cond_t empty_cond;    /*环形缓冲区下限条件变量,配合isempty使用*/
-
-  buffer_t loop_buf[BUFFERMAX]; /*环形缓冲区*/
-} loop_buffer_op_t;
-
-typedef struct {
-  int decoding_subframe_num;    /*待解码子帧的编号*/
-  pthread_mutex_t buffer_mutex; /*对sync_buffer临界区的保护锁*/
-  int sync_buffer[SUB_FRAME_LENGTH * 10];  /*同步线程与下行解码线程数据共享缓冲区*/
-} sync_buffer_t;
-
-typedef struct {
-  unsigned int rx_timestamp;    /*接收数据包第一个sample时间戳*/
-  unsigned int tx_timestamp;    /*待发送数据包的时间戳*/
-  unsigned long long current_subframe;  /*当前子帧编号*/
-
-  int ue_sync_state;        /*表示UE是否在同步状态,0表示失同步,1表示同步*/
-  pthread_mutex_t sync_mutex;   /*根据ue_sync_state标志,唤醒组帧线程*/
-
-  pthread_mutex_t ul_send_mutex;  /*用于sync线程唤醒发送线程发送数据*/
-  pthread_mutex_t dl_decode_mutex;/*下行解码保护锁,用于sync线程唤醒解码线程解码*/
-
-  loop_buffer_op_t loop_buffer;
-  sync_buffer_t sync_buffer;
-} g_thread_ipc_t;
-
-void loop_buffer_reset(buffer_t *loop_buf);
-int thread_ipc_init(void);
-int thread_ipc_deinit(void);
-int set_thread_attr(pthread_attr_t *attr, int policy, int priority, int cpuid);
-int find_subframe_num(unsigned long long current_subframe_num, buffer_t *buf, int *flag);
-int ue_unsync_thread_ipc_reset(void);
-
-extern g_thread_ipc_t thread_ipc;
-
-#endif
-- 
GitLab