diff options
author | Vadim Yanitskiy <vyanitskiy@sysmocom.de> | 2021-10-22 19:59:15 +0300 |
---|---|---|
committer | fixeria <vyanitskiy@sysmocom.de> | 2021-10-25 14:51:21 +0000 |
commit | e50223074e9841aa1ae37f7546ed4a10ff90a305 (patch) | |
tree | 971b8bf1a140266ad2ac783fa2a5c4775b615917 | |
parent | c5f75f0bcf7060254362a015e2ba64efed306ffc (diff) |
[overpower] lchan_dump_full_vty(): print overpower state
Change-Id: I052f1d68b27b2dc7203835b4a93d40c94b0c8d82
Depends: Ia28293a12de0af71f55e701fb65c46e905dae217
Related: SYS#5319
-rw-r--r-- | src/common/vty.c | 31 |
1 files changed, 31 insertions, 0 deletions
diff --git a/src/common/vty.c b/src/common/vty.c index 124f7ef2..97bd6589 100644 --- a/src/common/vty.c +++ b/src/common/vty.c @@ -1759,6 +1759,34 @@ static void lchan_acch_rep_state_dump(struct vty *vty, unsigned int indent, indent -= 2; } +static void lchan_acch_top_state_dump(struct vty *vty, unsigned int indent, + const struct gsm_lchan *lchan) +{ + if (lchan->top_acch_cap.overpower_db == 0) + return; + + cfg_out(vty, "Temporary ACCH overpower:%s", VTY_NEWLINE); + indent += 2; + + cfg_out(vty, "Overpower value: %u dB%s", + lchan->top_acch_cap.overpower_db, VTY_NEWLINE); + + cfg_out(vty, "SACCH overpower: %sabled%s", + lchan->top_acch_cap.sacch_enable ? "en" : "dis", + VTY_NEWLINE); + cfg_out(vty, "FACCH overpower: %sabled%s", + lchan->top_acch_cap.facch_enable ? "en" : "dis", + VTY_NEWLINE); + + if (lchan->top_acch_cap.rxqual == 0) { + cfg_out(vty, "RxQual threshold: disabled " + "(overpower is always on)%s", VTY_NEWLINE); + } else { + cfg_out(vty, "RxQual threshold: %u%s", + lchan->top_acch_cap.rxqual, VTY_NEWLINE); + } +} + static void lchan_dump_full_vty(struct vty *vty, const struct gsm_lchan *lchan) { struct in_addr ia; @@ -1841,7 +1869,10 @@ static void lchan_dump_full_vty(struct vty *vty, const struct gsm_lchan *lchan) /* BS/MS Power Control state and parameters */ lchan_bs_power_ctrl_state_dump(vty, 2, lchan); lchan_ms_power_ctrl_state_dump(vty, 2, lchan); + + /* ACCH repetition / overpower state */ lchan_acch_rep_state_dump(vty, 2, lchan); + lchan_acch_top_state_dump(vty, 2, lchan); } static void lchan_dump_short_vty(struct vty *vty, const struct gsm_lchan *lchan) |