- Remove unused loggers in TTCN3.

master
faluco 4 years ago committed by faluco
parent eaf20fa4f3
commit fd6c1e16a8

@ -225,9 +225,6 @@ private:
srslte::logger& logger_file; srslte::logger& logger_file;
srslte::logger* old_logger = nullptr; srslte::logger* old_logger = nullptr;
srslte::log_ref log; srslte::log_ref log;
srslte::log_ref ss_mac_log{"SS-MAC"};
srslte::log_ref ss_rlc_log{"SS-RLC"};
srslte::log_ref ss_pdcp_log{"SS-PDCP"};
all_args_t args = {}; all_args_t args = {};
@ -262,8 +259,7 @@ private:
{ {
public: public:
syssim_cell_t(ttcn3_syssim* ss) : syssim_cell_t(ttcn3_syssim* ss) :
rlc(ss->ss_rlc_log->get_service_name().c_str()), rlc(ss->ss_rlc_logger.id().c_str()), pdcp(&ss->stack.task_sched, ss->ss_pdcp_logger.id().c_str())
pdcp(&ss->stack.task_sched, ss->ss_pdcp_log->get_service_name().c_str())
{} {}
cell_config_t config; cell_config_t config;

@ -83,14 +83,8 @@ int ttcn3_syssim::init(const all_args_t& args_)
srslte::logmap::set_default_logger(old_logger); srslte::logmap::set_default_logger(old_logger);
// init and configure logging // init and configure logging
srslte::logmap::register_log(std::unique_ptr<srslte::log>{new log_filter{"SS ", old_logger, true}});
srslte::logmap::register_log(std::unique_ptr<srslte::log>{new log_filter{"SS-RLC", old_logger}});
srslte::logmap::register_log(std::unique_ptr<srslte::log>{new log_filter{"SS-PDCP", old_logger}});
log->set_level(args.log.all_level); log->set_level(args.log.all_level);
ss_mac_log->set_level(args.log.all_level);
ss_rlc_log->set_level(args.log.all_level);
ss_pdcp_log->set_level(args.log.all_level);
auto logger_lvl = srslog::str_to_basic_level(args.log.all_level); auto logger_lvl = srslog::str_to_basic_level(args.log.all_level);
logger.set_level(logger_lvl); logger.set_level(logger_lvl);
@ -105,9 +99,6 @@ int ttcn3_syssim::init(const all_args_t& args_)
ss_pdcp_logger.set_level(logger_lvl); ss_pdcp_logger.set_level(logger_lvl);
log->set_hex_limit(args.log.all_hex_limit); log->set_hex_limit(args.log.all_hex_limit);
ss_mac_log->set_hex_limit(args.log.all_hex_limit);
ss_rlc_log->set_hex_limit(args.log.all_hex_limit);
ss_pdcp_log->set_hex_limit(args.log.all_hex_limit);
logger.set_hex_dump_max_size(args.log.all_hex_limit); logger.set_hex_dump_max_size(args.log.all_hex_limit);
ut_logger.set_hex_dump_max_size(args.log.all_hex_limit); ut_logger.set_hex_dump_max_size(args.log.all_hex_limit);

@ -30,6 +30,8 @@ int if_handler_test()
int main(int argc, char** argv) int main(int argc, char** argv)
{ {
srslog::init();
if_handler_test(); if_handler_test();
return SRSLTE_SUCCESS; return SRSLTE_SUCCESS;

Loading…
Cancel
Save