aboutsummaryrefslogtreecommitdiffstats
path: root/src/pcu_vty_functions.cpp
diff options
context:
space:
mode:
authorMax <msuraev@sysmocom.de>2019-03-13 16:35:09 +0100
committerMax <msuraev@sysmocom.de>2019-03-24 18:54:52 +0100
commita4de02db5db1e90eee071d62a4a502d8cde4b8a7 (patch)
tree25933b45ab1ce68cf3d7c5035b4f4b4fae98eaf2 /src/pcu_vty_functions.cpp
parent02fbfc15c7678cb02a19b4c2f01f9efc80756d14 (diff)
MCS: move Mode enum outside of class definition
Move Mode (EDGE/GPRS) definition and related functions outside of GprsCodingScheme class. This allows us to use standard libosmocore value_string functions. Change-Id: I3baaac7f1ca3f5b88917a23c1679d63847455f47
Diffstat (limited to 'src/pcu_vty_functions.cpp')
-rw-r--r--src/pcu_vty_functions.cpp7
1 files changed, 3 insertions, 4 deletions
diff --git a/src/pcu_vty_functions.cpp b/src/pcu_vty_functions.cpp
index 47a0559..c93935d 100644
--- a/src/pcu_vty_functions.cpp
+++ b/src/pcu_vty_functions.cpp
@@ -79,7 +79,7 @@ static void tbf_print_vty_info(struct vty *vty, gprs_rlcmac_tbf *tbf)
ul_tbf->window_size(), win->v_q(), win->v_r());
vty_out(vty, "%s", VTY_NEWLINE);
vty_out(vty, " TBF Statistics:%s", VTY_NEWLINE);
- if(GprsCodingScheme::GPRS == tbf->ms()->mode()) {
+ if(GPRS == tbf->ms()->mode()) {
vty_out_rate_ctr_group(vty, " ", ul_tbf->m_ul_gprs_ctrs);
} else {
vty_out_rate_ctr_group(vty, " ", ul_tbf->m_ul_egprs_ctrs);
@@ -92,7 +92,7 @@ static void tbf_print_vty_info(struct vty *vty, gprs_rlcmac_tbf *tbf)
win->window_stalled() ? " STALLED" : "");
vty_out(vty, "%s", VTY_NEWLINE);
vty_out_rate_ctr_group(vty, " ", tbf->m_ctrs);
- if(GprsCodingScheme::GPRS == tbf->ms()->mode()) {
+ if(GPRS == tbf->ms()->mode()) {
vty_out_rate_ctr_group(vty, " ", dl_tbf->m_dl_gprs_ctrs);
} else {
vty_out_rate_ctr_group(vty, " ", dl_tbf->m_dl_egprs_ctrs);
@@ -153,8 +153,7 @@ static int show_ms(struct vty *vty, GprsMs *ms)
VTY_NEWLINE);
vty_out(vty, " Coding scheme downlink: %s%s", mcs_name(ms->current_cs_dl()),
VTY_NEWLINE);
- vty_out(vty, " Mode: %s%s",
- GprsCodingScheme::modeName(ms->mode()), VTY_NEWLINE);
+ vty_out(vty, " Mode: %s%s", mode_name(ms->mode()), VTY_NEWLINE);
vty_out(vty, " MS class: %d%s", ms->ms_class(), VTY_NEWLINE);
vty_out(vty, " EGPRS MS class: %d%s", ms->egprs_ms_class(), VTY_NEWLINE);
vty_out(vty, " PACCH: ");