pespin has submitted this change. ( https://gerrit.osmocom.org/c/osmo-bts/+/29438 )
Change subject: vty: Print Osmux CID on lchans using Osmux ......................................................................
vty: Print Osmux CID on lchans using Osmux
Related: SYS#5987 Change-Id: Ide6edefda828e9ce04fbb60cf547857f322d5f40 --- M src/common/vty.c 1 file changed, 12 insertions(+), 6 deletions(-)
Approvals: Jenkins Builder: Verified fixeria: Looks good to me, approved
diff --git a/src/common/vty.c b/src/common/vty.c index 3cd76fb..38448b1 100644 --- a/src/common/vty.c +++ b/src/common/vty.c @@ -1939,17 +1939,23 @@
if (lchan->abis_ip.bound_ip) { ia.s_addr = htonl(lchan->abis_ip.bound_ip); - vty_out(vty, " Bound IP: %s Port %u RTP_TYPE2=%u CONN_ID=%u%s", + vty_out(vty, " Bound IP: %s Port %u CONN_ID=%u", inet_ntoa(ia), lchan->abis_ip.bound_port, - lchan->abis_ip.rtp_payload2, lchan->abis_ip.conn_id, - VTY_NEWLINE); + lchan->abis_ip.conn_id); + if (lchan->abis_ip.osmux.use) + vty_out(vty, " Osmux_CID=%u%s", lchan->abis_ip.osmux.local_cid, VTY_NEWLINE); + else + vty_out(vty, " RTP_TYPE2=%u%s", lchan->abis_ip.rtp_payload2, VTY_NEWLINE); } if (lchan->abis_ip.connect_ip) { ia.s_addr = htonl(lchan->abis_ip.connect_ip); - vty_out(vty, " Conn. IP: %s Port %u RTP_TYPE=%u SPEECH_MODE=0x%02x%s", + vty_out(vty, " Conn. IP: %s Port %u SPEECH_MODE=0x%02x", inet_ntoa(ia), lchan->abis_ip.connect_port, - lchan->abis_ip.rtp_payload, lchan->abis_ip.speech_mode, - VTY_NEWLINE); + lchan->abis_ip.speech_mode); + if (lchan->abis_ip.osmux.use) + vty_out(vty, " Osmux_CID=%u%s", lchan->abis_ip.osmux.remote_cid, VTY_NEWLINE); + else + vty_out(vty, " RTP_TYPE=%u%s", lchan->abis_ip.rtp_payload, VTY_NEWLINE); } #define LAPDM_ESTABLISHED(link, sapi_idx) \ (link).datalink[sapi_idx].dl.state == LAPD_STATE_MF_EST