Change in osmo-bts[master]: GSMTAP: move 'gsmtap_sapi_names' from l1sap.c to vty.c

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/.

fixeria gerrit-no-reply at lists.osmocom.org
Mon Feb 15 07:33:35 UTC 2021


fixeria has submitted this change. ( https://gerrit.osmocom.org/c/osmo-bts/+/22891 )

Change subject: GSMTAP: move 'gsmtap_sapi_names' from l1sap.c to vty.c
......................................................................

GSMTAP: move 'gsmtap_sapi_names' from l1sap.c to vty.c

There is no point in having it there, as VTY is the only user.

Change-Id: If919bc1b2d456559ae9ff1ce5dd27d34742ee51c
---
M include/osmo-bts/l1sap.h
M src/common/l1sap.c
M src/common/vty.c
3 files changed, 17 insertions(+), 18 deletions(-)

Approvals:
  Jenkins Builder: Verified
  laforge: Looks good to me, but someone else must approve
  osmith: Looks good to me, approved



diff --git a/include/osmo-bts/l1sap.h b/include/osmo-bts/l1sap.h
index 85fe548..af58d5e 100644
--- a/include/osmo-bts/l1sap.h
+++ b/include/osmo-bts/l1sap.h
@@ -127,7 +127,6 @@
 extern uint16_t l1sap_log_ctx_sapi;
 extern const struct value_string l1sap_common_sapi_names[];
 
-extern const struct value_string gsmtap_sapi_names[];
 extern struct gsmtap_inst *gsmtap;
 extern uint32_t gsmtap_sapi_mask;
 extern uint8_t gsmtap_sapi_acch;
diff --git a/src/common/l1sap.c b/src/common/l1sap.c
index 97dd661..9b3b087 100644
--- a/src/common/l1sap.c
+++ b/src/common/l1sap.c
@@ -350,23 +350,6 @@
 uint32_t gsmtap_sapi_mask = 0;
 uint8_t gsmtap_sapi_acch = 0;
 
-const struct value_string gsmtap_sapi_names[] = {
-	{ GSMTAP_CHANNEL_BCCH,	"BCCH" },
-	{ GSMTAP_CHANNEL_CCCH,	"CCCH" },
-	{ GSMTAP_CHANNEL_RACH,	"RACH" },
-	{ GSMTAP_CHANNEL_AGCH,	"AGCH" },
-	{ GSMTAP_CHANNEL_PCH,	"PCH" },
-	{ GSMTAP_CHANNEL_SDCCH,	"SDCCH" },
-	{ GSMTAP_CHANNEL_TCH_F,	"TCH/F" },
-	{ GSMTAP_CHANNEL_TCH_H,	"TCH/H" },
-	{ GSMTAP_CHANNEL_PACCH,	"PACCH" },
-	{ GSMTAP_CHANNEL_PDCH,	"PDTCH" },
-	{ GSMTAP_CHANNEL_PTCCH,	"PTCCH" },
-	{ GSMTAP_CHANNEL_CBCH51,"CBCH" },
-	{ GSMTAP_CHANNEL_ACCH,  "SACCH" },
-	{ 0, NULL }
-};
-
 /* send primitive as gsmtap */
 static int gsmtap_ph_data(const struct osmo_phsap_prim *l1sap,
 			  uint8_t *chan_type, uint8_t *ss, uint32_t fn,
diff --git a/src/common/vty.c b/src/common/vty.c
index f36c09e..84e3968 100644
--- a/src/common/vty.c
+++ b/src/common/vty.c
@@ -71,6 +71,23 @@
 
 int g_vty_port_num = OSMO_VTY_PORT_BTS;
 
+static const struct value_string gsmtap_sapi_names[] = {
+	{ GSMTAP_CHANNEL_BCCH,	"BCCH" },
+	{ GSMTAP_CHANNEL_CCCH,	"CCCH" },
+	{ GSMTAP_CHANNEL_RACH,	"RACH" },
+	{ GSMTAP_CHANNEL_AGCH,	"AGCH" },
+	{ GSMTAP_CHANNEL_PCH,	"PCH" },
+	{ GSMTAP_CHANNEL_SDCCH,	"SDCCH" },
+	{ GSMTAP_CHANNEL_TCH_F,	"TCH/F" },
+	{ GSMTAP_CHANNEL_TCH_H,	"TCH/H" },
+	{ GSMTAP_CHANNEL_PACCH,	"PACCH" },
+	{ GSMTAP_CHANNEL_PDCH,	"PDTCH" },
+	{ GSMTAP_CHANNEL_PTCCH,	"PTCCH" },
+	{ GSMTAP_CHANNEL_CBCH51,"CBCH" },
+	{ GSMTAP_CHANNEL_ACCH,  "SACCH" },
+	{ 0, NULL }
+};
+
 struct phy_instance *vty_get_phy_instance(struct vty *vty, int phy_nr, int inst_nr)
 {
 	struct phy_link *plink = phy_link_by_num(phy_nr);

-- 
To view, visit https://gerrit.osmocom.org/c/osmo-bts/+/22891
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings

Gerrit-Project: osmo-bts
Gerrit-Branch: master
Gerrit-Change-Id: If919bc1b2d456559ae9ff1ce5dd27d34742ee51c
Gerrit-Change-Number: 22891
Gerrit-PatchSet: 1
Gerrit-Owner: fixeria <vyanitskiy at sysmocom.de>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: fixeria <vyanitskiy at sysmocom.de>
Gerrit-Reviewer: laforge <laforge at osmocom.org>
Gerrit-Reviewer: osmith <osmith at sysmocom.de>
Gerrit-Reviewer: pespin <pespin at sysmocom.de>
Gerrit-MessageType: merged
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osmocom.org/pipermail/gerrit-log/attachments/20210215/dabb764c/attachment.htm>


More information about the gerrit-log mailing list