aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorNeels Hofmeyr <neels@hofmeyr.de>2018-07-11 19:53:39 +0200
committerNeels Hofmeyr <neels@hofmeyr.de>2018-07-28 12:18:23 +0200
commit3c5612f82b29a8c57e88499d6cc7cf334d66d6cb (patch)
tree9b550bc3c0340ec412edbd8928ed99b812b1987b
parent2fc79dd2207b0c2a563edddea13f7ebda9213e70 (diff)
create separate logging categories for lchan,ts,as FSMs
-rw-r--r--include/osmocom/bsc/debug.h3
-rw-r--r--src/osmo-bsc/assignment_fsm.c2
-rw-r--r--src/osmo-bsc/lchan_fsm.c2
-rw-r--r--src/osmo-bsc/lchan_rtp_fsm.c2
-rw-r--r--src/osmo-bsc/osmo_bsc_main.c18
-rw-r--r--src/osmo-bsc/timeslot_fsm.c2
-rw-r--r--tests/handover/handover_test.c18
7 files changed, 43 insertions, 4 deletions
diff --git a/include/osmocom/bsc/debug.h b/include/osmocom/bsc/debug.h
index 1133bf6f6..e78ba59a8 100644
--- a/include/osmocom/bsc/debug.h
+++ b/include/osmocom/bsc/debug.h
@@ -24,5 +24,8 @@ enum {
DFILTER,
DPCU,
DLCLS,
+ DCHAN,
+ DTS,
+ DAS,
Debug_LastEntry,
};
diff --git a/src/osmo-bsc/assignment_fsm.c b/src/osmo-bsc/assignment_fsm.c
index a2b17463f..e37ec9cb0 100644
--- a/src/osmo-bsc/assignment_fsm.c
+++ b/src/osmo-bsc/assignment_fsm.c
@@ -642,7 +642,7 @@ static struct osmo_fsm assignment_fsm = {
.name = "assignment",
.states = assignment_fsm_states,
.num_states = ARRAY_SIZE(assignment_fsm_states),
- .log_subsys = DRSL,
+ .log_subsys = DAS,
.event_names = assignment_fsm_event_names,
.allstate_action = assignment_fsm_allstate_action,
.allstate_event_mask = 0
diff --git a/src/osmo-bsc/lchan_fsm.c b/src/osmo-bsc/lchan_fsm.c
index 940afe8de..9c22bded4 100644
--- a/src/osmo-bsc/lchan_fsm.c
+++ b/src/osmo-bsc/lchan_fsm.c
@@ -1275,7 +1275,7 @@ static struct osmo_fsm lchan_fsm = {
.name = "lchan",
.states = lchan_fsm_states,
.num_states = ARRAY_SIZE(lchan_fsm_states),
- .log_subsys = DRSL,
+ .log_subsys = DCHAN,
.event_names = lchan_fsm_event_names,
.allstate_action = lchan_fsm_allstate_action,
.allstate_event_mask = 0
diff --git a/src/osmo-bsc/lchan_rtp_fsm.c b/src/osmo-bsc/lchan_rtp_fsm.c
index 3530b8a72..f7efc1ba8 100644
--- a/src/osmo-bsc/lchan_rtp_fsm.c
+++ b/src/osmo-bsc/lchan_rtp_fsm.c
@@ -736,7 +736,7 @@ static struct osmo_fsm lchan_rtp_fsm = {
.name = "lchan_rtp",
.states = lchan_rtp_fsm_states,
.num_states = ARRAY_SIZE(lchan_rtp_fsm_states),
- .log_subsys = DRSL,
+ .log_subsys = DCHAN,
.event_names = lchan_rtp_fsm_event_names,
.timer_cb = lchan_rtp_fsm_timer_cb,
.cleanup = lchan_rtp_fsm_cleanup,
diff --git a/src/osmo-bsc/osmo_bsc_main.c b/src/osmo-bsc/osmo_bsc_main.c
index 8dc90986e..37e8665dd 100644
--- a/src/osmo-bsc/osmo_bsc_main.c
+++ b/src/osmo-bsc/osmo_bsc_main.c
@@ -679,6 +679,24 @@ static const struct log_info_cat osmo_bsc_categories[] = {
.color = "\033[1;35m",
.enabled = 1, .loglevel = LOGL_NOTICE,
},
+ [DCHAN] = {
+ .name = "DCHAN",
+ .description = "lchan FSM",
+ .color = "\033[1;32m",
+ .enabled = 1, .loglevel = LOGL_NOTICE,
+ },
+ [DTS] = {
+ .name = "DTS",
+ .description = "timeslot FSM",
+ .color = "\033[1;31m",
+ .enabled = 1, .loglevel = LOGL_NOTICE,
+ },
+ [DAS] = {
+ .name = "DAS",
+ .description = "assignment FSM",
+ .color = "\033[1;33m",
+ .enabled = 1, .loglevel = LOGL_NOTICE,
+ },
[DNM] = {
.name = "DNM",
.description = "A-bis Network Management / O&M (NM/OML)",
diff --git a/src/osmo-bsc/timeslot_fsm.c b/src/osmo-bsc/timeslot_fsm.c
index 21de2fa67..56b335773 100644
--- a/src/osmo-bsc/timeslot_fsm.c
+++ b/src/osmo-bsc/timeslot_fsm.c
@@ -834,7 +834,7 @@ static struct osmo_fsm ts_fsm = {
.states = ts_fsm_states,
.num_states = ARRAY_SIZE(ts_fsm_states),
.timer_cb = ts_fsm_timer_cb,
- .log_subsys = DRSL,
+ .log_subsys = DTS,
.event_names = ts_fsm_event_names,
.allstate_event_mask = 0
| S(TS_EV_OML_DOWN)
diff --git a/tests/handover/handover_test.c b/tests/handover/handover_test.c
index 92c002dcc..a9627772a 100644
--- a/tests/handover/handover_test.c
+++ b/tests/handover/handover_test.c
@@ -1357,6 +1357,24 @@ static const struct log_info_cat log_categories[] = {
.description = "Mobile Switching Center",
.enabled = 1, .loglevel = LOGL_DEBUG,
},
+ [DCHAN] = {
+ .name = "DCHAN",
+ .description = "lchan FSM",
+ .color = "\033[1;32m",
+ .enabled = 1, .loglevel = LOGL_DEBUG,
+ },
+ [DTS] = {
+ .name = "DTS",
+ .description = "timeslot FSM",
+ .color = "\033[1;31m",
+ .enabled = 1, .loglevel = LOGL_DEBUG,
+ },
+ [DAS] = {
+ .name = "DAS",
+ .description = "assignment FSM",
+ .color = "\033[1;33m",
+ .enabled = 1, .loglevel = LOGL_DEBUG,
+ },
};
const struct log_info log_info = {