[MERGED] osmo-bts[master]: vty: print version and description for each phy

This is merely a historical archive of years 2008-2021, before the migration to mailman3.

A maintained and still updated list archive can be found at https://lists.osmocom.org/hyperkitty/list/gerrit-log@lists.osmocom.org/.

Harald Welte gerrit-no-reply at lists.osmocom.org
Sat Sep 30 12:13:15 UTC 2017


Harald Welte has submitted this change and it was merged.

Change subject: vty: print version and description for each phy
......................................................................


vty: print version and description for each phy

When printing BTS via 'show bts ..' let's also print each TRX, which phy
number and version it uses and its description. It's helpful in
troubleshooting low-level issues as it allows vendor-specific code to
easily expose firmware version.

Related: SYS#3884
Change-Id: Iabcc862566b40a9314f3e1d17fda61d8ab24a3cd
---
M src/common/vty.c
1 file changed, 12 insertions(+), 0 deletions(-)

Approvals:
  Harald Welte: Looks good to me, approved
  Jenkins Builder: Verified



diff --git a/src/common/vty.c b/src/common/vty.c
index ef56705..77bb47d 100644
--- a/src/common/vty.c
+++ b/src/common/vty.c
@@ -730,6 +730,7 @@
 static void bts_dump_vty(struct vty *vty, struct gsm_bts *bts)
 {
 	struct gsm_bts_role_bts *btsb = bts->role;
+	struct gsm_bts_trx *trx;
 
 	vty_out(vty, "BTS %u is of %s type in band %s, has CI %u LAC %u, "
 		"BSIC %u and %u TRX%s",
@@ -767,6 +768,17 @@
 		VTY_NEWLINE);
 	vty_out(vty, "  OML Link state: %s.%s",
 		bts->oml_link ? "connected" : "disconnected", VTY_NEWLINE);
+
+	llist_for_each_entry(trx, &bts->trx_list, list) {
+		struct phy_instance *pinst = trx_phy_instance(trx);
+		vty_out(vty, "  TRX %u%s", trx->nr, VTY_NEWLINE);
+		if (pinst) {
+			vty_out(vty, "    phy %d %s", pinst->num, pinst->version);
+			if (pinst->description)
+				vty_out(vty, " (%s)", pinst->description);
+			vty_out(vty, "%s", VTY_NEWLINE);
+		}
+	}
 }
 
 

-- 
To view, visit https://gerrit.osmocom.org/4058
To unsubscribe, visit https://gerrit.osmocom.org/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: Iabcc862566b40a9314f3e1d17fda61d8ab24a3cd
Gerrit-PatchSet: 3
Gerrit-Project: osmo-bts
Gerrit-Branch: master
Gerrit-Owner: Max <msuraev at sysmocom.de>
Gerrit-Reviewer: Harald Welte <laforge at gnumonks.org>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: Max <msuraev at sysmocom.de>
Gerrit-Reviewer: Pau Espin Pedrol <pespin at sysmocom.de>



More information about the gerrit-log mailing list