Change in osmo-bsc[master]: abis_rsl: Count successful channel requests

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

laforge gerrit-no-reply at lists.osmocom.org
Tue Jun 16 08:43:46 UTC 2020


laforge has submitted this change. ( https://gerrit.osmocom.org/c/osmo-bsc/+/18719 )

Change subject: abis_rsl: Count successful channel requests
......................................................................

abis_rsl: Count successful channel requests

Ticket: SYS#4877
Change-Id: I5c51956569223e802f4789dc5ed1605d18f80aea
---
M include/osmocom/bsc/gsm_data.h
M src/osmo-bsc/abis_rsl.c
2 files changed, 9 insertions(+), 1 deletion(-)

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



diff --git a/include/osmocom/bsc/gsm_data.h b/include/osmocom/bsc/gsm_data.h
index 8dc4105..7e55089 100644
--- a/include/osmocom/bsc/gsm_data.h
+++ b/include/osmocom/bsc/gsm_data.h
@@ -1384,6 +1384,7 @@
 
 enum bts_counter_id {
 	BTS_CTR_CHREQ_TOTAL,
+	BTS_CTR_CHREQ_SUCCESSFUL,
 	BTS_CTR_CHREQ_NO_CHANNEL,
 	BTS_CTR_CHAN_RF_FAIL,
 	BTS_CTR_CHAN_RLL_ERR,
@@ -1430,6 +1431,7 @@
 
 static const struct rate_ctr_desc bts_ctr_description[] = {
 	[BTS_CTR_CHREQ_TOTAL] = 		{"chreq:total", "Received channel requests"},
+	[BTS_CTR_CHREQ_SUCCESSFUL] =  		{"chreq:successful", "Successful channel requests (immediate assign sent)"},
 	[BTS_CTR_CHREQ_NO_CHANNEL] = 		{"chreq:no_channel", "Sent to MS no channel available"},
 	[BTS_CTR_CHAN_RF_FAIL] = 		{"chan:rf_fail", "Received a RF failure indication from BTS"},
 	[BTS_CTR_CHAN_RLL_ERR] = 		{"chan:rll_err", "Received a RLL failure with T200 cause from BTS"},
diff --git a/src/osmo-bsc/abis_rsl.c b/src/osmo-bsc/abis_rsl.c
index 4a1d314..705e759 100644
--- a/src/osmo-bsc/abis_rsl.c
+++ b/src/osmo-bsc/abis_rsl.c
@@ -1428,6 +1428,7 @@
 
 int rsl_tx_imm_assignment(struct gsm_lchan *lchan)
 {
+	int rc;
 	struct gsm_bts *bts = lchan->ts->trx->bts;
 	uint8_t buf[GSM_MACBLOCK_LEN];
 	struct gsm48_imm_ass *ia = (struct gsm48_imm_ass *) buf;
@@ -1453,7 +1454,12 @@
 	ia->l2_plen = GSM48_LEN2PLEN((sizeof(*ia)-1) + ia->mob_alloc_len);
 
 	/* send IMMEDIATE ASSIGN CMD on RSL to BTS (to send on CCCH to MS) */
-	return rsl_imm_assign_cmd(bts, sizeof(*ia)+ia->mob_alloc_len, (uint8_t *) ia);
+	rc = rsl_imm_assign_cmd(bts, sizeof(*ia)+ia->mob_alloc_len, (uint8_t *) ia);
+
+	if (!rc)
+		rate_ctr_inc(&bts->bts_ctrs->ctr[BTS_CTR_CHREQ_SUCCESSFUL]);
+
+	return rc;
 }
 
 /* current load on the CCCH */

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

Gerrit-Project: osmo-bsc
Gerrit-Branch: master
Gerrit-Change-Id: I5c51956569223e802f4789dc5ed1605d18f80aea
Gerrit-Change-Number: 18719
Gerrit-PatchSet: 4
Gerrit-Owner: daniel <dwillmann at sysmocom.de>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: daniel <dwillmann at sysmocom.de>
Gerrit-Reviewer: laforge <laforge at osmocom.org>
Gerrit-Reviewer: lynxis lazus <lynxis at fe80.eu>
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/20200616/50ce60d9/attachment.htm>


More information about the gerrit-log mailing list