Modified timer log to use oaisim / lte-softmodem logging rather than fprintf when available.

Moved itti initialization in oaisim to have log initialized just before.

git-svn-id: http://svn.eurecom.fr/openair4G/trunk@4594 818b1a75-f10b-46b9-bf7c-635c3b92a50f
This commit is contained in:
winckel
2013-12-04 16:33:36 +00:00
parent b566d59dd5
commit c5a3b8a954
3 changed files with 23 additions and 9 deletions
+10 -3
View File
@@ -41,14 +41,19 @@
#include "assertions.h"
#include "intertask_interface.h"
#include "timer.h"
#include "log.h"
#include "queue.h"
#if defined (LOG_D) && defined (LOG_E)
# define TMR_DEBUG(x, args...) LOG_D(TMR, x, ##args)
# define TMR_ERROR(x, args...) LOG_E(TMR, x, ##args)
#endif
#ifndef TMR_DEBUG
# define TMR_DEBUG(x, args...) do { fprintf(stdout, "[TMR][D]"x, ##args); } while(0)
# define TMR_DEBUG(x, args...) do { fprintf(stdout, "[TMR][D]"x, ##args); } while(0)
#endif
#ifndef TMR_ERROR
# define TMR_ERROR(x, args...) do { fprintf(stdout, "[TMR][E]"x, ##args); } while(0)
# define TMR_ERROR(x, args...) do { fprintf(stdout, "[TMR][E]"x, ##args); } while(0)
#endif
int timer_handle_signal(siginfo_t *info);
@@ -204,6 +209,8 @@ int timer_setup(
pthread_mutex_lock(&timer_desc.timer_list_mutex);
STAILQ_INSERT_TAIL(&timer_desc.timer_queue, timer_p, entries);
pthread_mutex_unlock(&timer_desc.timer_list_mutex);
#else
return -1;
#endif
return 0;