Change in osmo-bts[master]: bts-trx: Fix osmocom dyn ts assert hit during Adm State Unlock

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

pespin gerrit-no-reply at lists.osmocom.org
Thu Jul 23 12:33:35 UTC 2020


pespin has uploaded this change for review. ( https://gerrit.osmocom.org/c/osmo-bts/+/19374 )


Change subject: bts-trx: Fix osmocom dyn ts assert hit during Adm State Unlock
......................................................................

bts-trx: Fix osmocom dyn ts assert hit during Adm State Unlock

How to reproduce:
* Configure a TS to be TCH/F_TCH/H_PDCH in osmo-bsc.cfg
* Run the network with osmo-bts-trx, then use osmo-bsc's "rf_locked 1"
* Then, unlock it: "rf_locked 0"
* The following assert will be hit:
Assert failed ts->dyn.pchan_is == ts->dyn.pchan_want /osmo-bts/src/osmo-bts-trx/l1_if.c:349
"""
(gdb) bt
 #0  0x00007ffff5bb9355 in raise () from /usr/lib/libc.so.6
 #1  0x00007ffff5ba2853 in abort () from /usr/lib/libc.so.6
 #2  0x00007ffff6832361 in osmo_panic_default (
    fmt=0x555555814e60 "Assert failed %s %s:%d\n", args=0x7fffffffc6e0)
    at /libosmocore/src/panic.c:49
 #3  0x00007ffff683249d in osmo_panic (
    fmt=0x555555814e60 "Assert failed %s %s:%d\n")
    at /libosmocore/src/panic.c:84
 #4  0x000055555570fdf7 in trx_set_ts (ts=0x7ffff1e6bce8)
    at /osmo-bts/src/osmo-bts-trx/l1_if.c:349
 #5  0x00005555557133c1 in bts_model_chg_adm_state (bts=0x627000000160,
    mo=0x7ffff1e0f8a0, obj=0x7ffff1e0f860, adm_state=2 '\002')
    at /osmo-bts/src/osmo-bts-trx/l1_if.c:681
 #6  0x0000555555769978 in oml_rx_chg_adm_state (bts=0x627000000160,
    msg=0x633000003e00)
    at /osmo-bts/src/common/oml.c:1044
 #7  0x000055555576a8d3 in down_fom (bts=0x627000000160, msg=0x633000003e00)
    at /osmo-bts/src/common/oml.c:1129
 #8  0x0000555555770aed in down_oml (bts=0x627000000160, msg=0x633000003e00)
    at /osmo-bts/src/common/oml.c:1476
 #9  0x00005555557f8174 in sign_link_cb (msg=0x633000003e00)
    at /osmo-bts/src/common/abis.c:188
 #10 0x00007ffff73b5935 in ipaccess_bts_read_cb (link=0x6120000030a0,
--Type <RET> for more, q to quit, c to continue without paging--
    msg=0x633000003e00)
    at /libosmo-abis/src/input/ipaccess.c:980
 #11 0x00007ffff73a1060 in ipa_client_read (link=0x6120000030a0)
    at /libosmo-abis/src/input/ipa.c:72
 #12 0x00007ffff73a2458 in ipa_client_fd_cb (ofd=0x62f000038a50, what=1)
    at /libosmo-abis/src/input/ipa.c:136
 #13 0x00007ffff67ebfa7 in osmo_fd_disp_fds (_rset=0x7fffffffdda0,
    _wset=0x7fffffffde40, _eset=0x7fffffffdee0)
    at /libosmocore/src/select.c:227
 #14 0x00007ffff67ec38c in _osmo_select_main (polling=0)
    at /libosmocore/src/select.c:265
 #15 0x00007ffff67ec46b in osmo_select_main (polling=0)
    at /libosmocore/src/select.c:274
 #16 0x00005555557ef089 in bts_main (argc=7, argv=0x7fffffffe208)
    at /osmo-bts/src/common/main.c:354
 #17 0x00005555556fe621 in main (argc=7, argv=0x7fffffffe208)
    at /osmo-bts/src/osmo-bts-trx/main.c:176
"""

Related: OS#4920
Change-Id: Ia3210e24b921fd0c67f77068b7ef4a65f270cd11
---
M src/osmo-bts-trx/l1_if.c
1 file changed, 7 insertions(+), 0 deletions(-)



  git pull ssh://gerrit.osmocom.org:29418/osmo-bts refs/changes/74/19374/1

diff --git a/src/osmo-bts-trx/l1_if.c b/src/osmo-bts-trx/l1_if.c
index d65900f..bc936c0 100644
--- a/src/osmo-bts-trx/l1_if.c
+++ b/src/osmo-bts-trx/l1_if.c
@@ -678,6 +678,13 @@
 			/* Activate timeslots in scheduler and start power ramp up */
 			for (i = 0; i < ARRAY_SIZE(trx->ts); i++) {
 				struct gsm_bts_trx_ts *ts = &trx->ts[i];
+				if (ts->pchan == GSM_PCHAN_TCH_F_TCH_H_PDCH) {
+					/* dyn.pchan_is is set to GSM_PCHAN_NONE when
+					 * internally deactivated during locking. Simply
+					 * internally restore the old status here.
+					 */
+					ts->dyn.pchan_is = ts->dyn.pchan_want;
+				}
 				trx_set_ts(ts);
 			}
 			rc = l1if_trx_start_power_ramp(trx, bts_model_chg_adm_state_ramp_compl_cb);

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

Gerrit-Project: osmo-bts
Gerrit-Branch: master
Gerrit-Change-Id: Ia3210e24b921fd0c67f77068b7ef4a65f270cd11
Gerrit-Change-Number: 19374
Gerrit-PatchSet: 1
Gerrit-Owner: pespin <pespin at sysmocom.de>
Gerrit-MessageType: newchange
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osmocom.org/pipermail/gerrit-log/attachments/20200723/e80a6aae/attachment.htm>


More information about the gerrit-log mailing list