From 3f0b7865a98981e44f277973ca5f09299a2192f9 Mon Sep 17 00:00:00 2001
From: Lionel Gauthier <lionel.gauthier@eurecom.fr>
Date: Mon, 1 Dec 2014 14:08:19 +0000
Subject: [PATCH] VCD measurements

git-svn-id: http://svn.eurecom.fr/openair4G/trunk@6138 818b1a75-f10b-46b9-bf7c-635c3b92a50f
---
 openair-cn/GTPV1-U/gtpv1u_eNB.c                | 2 ++
 openair-cn/GTPV1-U/nw-gtpv1u/src/NwGtpv1u.c    | 5 +++++
 openair-cn/GTPV1-U/nw-gtpv1u/src/NwGtpv1uMsg.c | 2 ++
 3 files changed, 9 insertions(+)

diff --git a/openair-cn/GTPV1-U/gtpv1u_eNB.c b/openair-cn/GTPV1-U/gtpv1u_eNB.c
index f0943a25bd..3bc19bc635 100644
--- a/openair-cn/GTPV1-U/gtpv1u_eNB.c
+++ b/openair-cn/GTPV1-U/gtpv1u_eNB.c
@@ -958,6 +958,7 @@ void *gtpv1u_eNB_task(void *args)
                 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);
 
@@ -1003,6 +1004,7 @@ void *gtpv1u_eNB_task(void *args)
                         }
                     }
                 }
+                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);
             }
diff --git a/openair-cn/GTPV1-U/nw-gtpv1u/src/NwGtpv1u.c b/openair-cn/GTPV1-U/nw-gtpv1u/src/NwGtpv1u.c
index 5c1cd07bdf..da80deec9a 100644
--- a/openair-cn/GTPV1-U/nw-gtpv1u/src/NwGtpv1u.c
+++ b/openair-cn/GTPV1-U/nw-gtpv1u/src/NwGtpv1u.c
@@ -50,6 +50,7 @@
 #include "gtpv1u.h"
 #if defined(ENB_MODE)
 #include "UTIL/LOG/log.h"
+#include "UTIL/LOG/vcd_signal_dumper.h"
 #endif
 
 #ifdef __cplusplus
@@ -240,7 +241,9 @@ nwGtpv1uCreateAndSendMsg( NwGtpv1uStackT *thiz, NwU32T peerIp, NwU16T peerPort,
                                       peerIp,
                                       peerPort);
 
+#if defined(LOG_GTPU) && LOG_GTPU > 0
     NW_LEAVE(thiz);
+#endif
     return rc;
 }
 
@@ -788,6 +791,7 @@ nwGtpv1uProcessUdpReq( NW_IN NwGtpv1uStackHandleT hGtpuStackHandle,
     NwGtpv1uStackT       *thiz;
     NwU16T                msgType;
 
+    vcd_signal_dumper_dump_function_by_name(VCD_SIGNAL_DUMPER_FUNCTIONS_GTPV1U_PROCESS_UDP_REQ, VCD_FUNCTION_IN);
     thiz = (NwGtpv1uStackT *) hGtpuStackHandle;
 
     NW_ASSERT(thiz);
@@ -835,6 +839,7 @@ nwGtpv1uProcessUdpReq( NW_IN NwGtpv1uStackHandleT hGtpuStackHandle,
 #if defined(LOG_GTPU) && LOG_GTPU > 0
     NW_LEAVE(thiz);
 #endif
+    vcd_signal_dumper_dump_function_by_name(VCD_SIGNAL_DUMPER_FUNCTIONS_GTPV1U_PROCESS_UDP_REQ, VCD_FUNCTION_OUT);
     return ret;
 }
 
diff --git a/openair-cn/GTPV1-U/nw-gtpv1u/src/NwGtpv1uMsg.c b/openair-cn/GTPV1-U/nw-gtpv1u/src/NwGtpv1uMsg.c
index 1ea33cebb4..bfc48bd6ea 100644
--- a/openair-cn/GTPV1-U/nw-gtpv1u/src/NwGtpv1uMsg.c
+++ b/openair-cn/GTPV1-U/nw-gtpv1u/src/NwGtpv1uMsg.c
@@ -304,7 +304,9 @@ nwGtpv1uMsgSetTeid(NW_IN NwGtpv1uMsgHandleT hMsg, NwU32T 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;
 }
 
-- 
GitLab