log.c simplification, fix usefull functionality which never worked, move all log code from openair2 to common

This commit is contained in:
frtabu
2018-07-30 20:07:22 +02:00
parent c30a2fa607
commit b85cbddeec
152 changed files with 1247 additions and 1907 deletions
@@ -54,7 +54,7 @@
#include "socket.h"
#include "multicast_link.h"
#include "UTIL/LOG/log.h"
#include "common/utils/LOG/log.h"
extern unsigned short Master_id;
+3 -5
View File
@@ -47,7 +47,7 @@
#include "LAYER2/MAC/mac_vars.h"
#include "OCG_vars.h"
#include "UTIL/LOG/log.h"
#include "common/utils/LOG/log.h"
#include "UTIL/LISTS/list.h"
#include "unitary_defs.h"
@@ -647,7 +647,6 @@ int main(int argc, char **argv)
int two_thread_flag=0;
int DLSCH_RB_ALLOC = 0;
int log_level = LOG_ERR;
int dci_received;
PHY_VARS_eNB *eNB;
RU_t *ru;
@@ -999,7 +998,7 @@ int main(int argc, char **argv)
break;
case 'L':
log_level=atoi(optarg);
set_glog(atoi(optarg));
break;
case 'h':
@@ -1047,8 +1046,7 @@ int main(int argc, char **argv)
"cannot load configuration module, exiting\n");
logInit();
// enable these lines if you need debug info
set_comp_log(PHY,LOG_INFO,LOG_HIGH,1);
set_glog(log_level,LOG_HIGH);
set_glog(LOG_DEBUG);
// moreover you need to init itti with the following line
// however itti will catch all signals, so ctrl-c won't work anymore
// alternatively you can disable ITTI completely in CMakeLists.txt
+4
View File
@@ -1143,6 +1143,10 @@ int main(int argc, char **argv)
if (mcs < 11) modulation_type = 2;
else if (mcs < 21) modulation_type = 4;
else if (mcs < 29) modulation_type = 6;
else {
LOG_E(USIM,"mcs %i is not valid\n",mcs);
exit(-1);
}
fill_ulsch_dci(eNB,proc_rxtx->frame_rx,subframe,&sched_resp,14,(void*)&UL_alloc_pdu,first_rb,nb_rb,(round==0)?mcs:(28+rvidx[round]),modulation_type,ndi,get_TBS_UL(mcs,nb_rb),cqi_flag,beta_CQI,beta_RI,cqi_size);
+1 -1
View File
@@ -29,7 +29,7 @@
#include "PHY/TOOLS/tools_defs.h"
#include "sim.h"
#include "scm_corrmat.h"
#include "UTIL/LOG/log.h"
#include "common/utils/LOG/log.h"
//#define DEBUG_CH
#include "assertions.h"