[MERGED] osmo-bts[master]: osmo-bts-trx: fix lchan deactivation

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

Neels Hofmeyr gerrit-no-reply at lists.osmocom.org
Tue Dec 13 00:52:17 UTC 2016


Neels Hofmeyr has submitted this change and it was merged.

Change subject: osmo-bts-trx: fix lchan deactivation
......................................................................


osmo-bts-trx: fix lchan deactivation

Use chan_nr for deactivating lchan instead of lchan->nr: chan_nr is the
RSL Channel Number IE value, a bitfield aggregation of lchan type
bits (cbits) and lchan number (lowest three bits). The error was
introduced in 36153239bfd0b633c4d259a9de0a759f41197a2b.

Change-Id: I6dd7060422ab9d18743c1ff2ab419e3e7299d74d
---
M src/osmo-bts-trx/l1_if.c
1 file changed, 4 insertions(+), 2 deletions(-)

Approvals:
  pierre.baudry: Looks good to me, but someone else must approve; Verified
  Neels Hofmeyr: Looks good to me, approved
  Jenkins Builder: Verified



diff --git a/src/osmo-bts-trx/l1_if.c b/src/osmo-bts-trx/l1_if.c
index 6304c1f..a42d39a 100644
--- a/src/osmo-bts-trx/l1_if.c
+++ b/src/osmo-bts-trx/l1_if.c
@@ -155,14 +155,16 @@
 	/* set lchan inactive */
 	lchan_set_state(lchan, LCHAN_S_NONE);
 
-	return trx_sched_set_lchan(&l1h->l1s, lchan->nr, LID_DEDIC, 0);
+	return trx_sched_set_lchan(&l1h->l1s, gsm_lchan2chan_nr(lchan),
+				   LID_DEDIC, 0);
 }
 
 int bts_model_lchan_deactivate_sacch(struct gsm_lchan *lchan)
 {
 	struct phy_instance *pinst = trx_phy_instance(lchan->ts->trx);
 	struct trx_l1h *l1h = pinst->u.osmotrx.hdl;
-	return trx_sched_set_lchan(&l1h->l1s, lchan->nr, LID_SACCH, 0);
+	return trx_sched_set_lchan(&l1h->l1s, gsm_lchan2chan_nr(lchan),
+				   LID_SACCH, 0);
 }
 
 /*

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I6dd7060422ab9d18743c1ff2ab419e3e7299d74d
Gerrit-PatchSet: 1
Gerrit-Project: osmo-bts
Gerrit-Branch: master
Gerrit-Owner: Max <msuraev at sysmocom.de>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: Neels Hofmeyr <nhofmeyr at sysmocom.de>
Gerrit-Reviewer: pierre.baudry <pierre.baudry at diateam.net>



More information about the gerrit-log mailing list