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.orgpespin has submitted this change. ( https://gerrit.osmocom.org/c/osmo-bts/+/25791 )
Change subject: Move lchan_init_lapdm inside lchan_set_state(LCHAN_S_ACTIVE)
......................................................................
Move lchan_init_lapdm inside lchan_set_state(LCHAN_S_ACTIVE)
osmo-bts-trx/l1_if.c lchan_init_lapdm() for CCCH is already done when
trx_set_ts_as_pchan() calls:
"lchan_set_state(&ts->lchan[CCCH_LCHAN], LCHAN_S_ACTIVE);"
Change-Id: I7a9c3660b9aab57ff8765e2f1526349599630cd9
---
M src/common/lchan.c
M src/osmo-bts-lc15/oml.c
M src/osmo-bts-oc2g/oml.c
M src/osmo-bts-octphy/l1_oml.c
M src/osmo-bts-sysmo/oml.c
M src/osmo-bts-trx/l1_if.c
M src/osmo-bts-virtual/l1_if.c
7 files changed, 21 insertions(+), 41 deletions(-)
Approvals:
Jenkins Builder: Verified
fixeria: Looks good to me, approved
diff --git a/src/common/lchan.c b/src/common/lchan.c
index 5d12952..28ea943 100644
--- a/src/common/lchan.c
+++ b/src/common/lchan.c
@@ -272,29 +272,34 @@
gsm_lchans_name(lchan->state), gsm_lchans_name(state));
lchan->state = state;
- /* Early Immediate Assignment: if we have a cached early IA pending, send it upon becoming active, or discard it
- * when releasing. */
- if (lchan->early_rr_ia) {
- switch (lchan->state) {
- case LCHAN_S_ACT_REQ:
- /* Activation is requested, keep the early IA until active. This allows the BSC to send the IA
- * even before a dynamic timeslot is done switching to a different pchan kind (experimental). */
- break;
- case LCHAN_S_ACTIVE:
- /* Activation is done, send the RR IA now. Delay a bit more to give Um time to let the lchan
- * light up for the MS */
+ switch (lchan->state) {
+ case LCHAN_S_ACT_REQ:
+ /* Early Immediate Assignment: Activation is requested, keep the
+ * early IA until active. This allows the BSC to send the IA
+ * even before a dynamic timeslot is done switching to a
+ * different pchan kind (experimental). */
+ break;
+ case LCHAN_S_ACTIVE:
+ lchan_init_lapdm(lchan);
+ if (lchan->early_rr_ia) {
+ /* Early Immediate Assignment: Activation is done, send
+ * the RR IA now. Delay a bit more to give Um time to
+ * let the lchan light up for the MS */
osmo_timer_del(&lchan->early_rr_ia_delay);
osmo_timer_schedule(&lchan->early_rr_ia_delay, 0,
osmo_tdef_get(abis_T_defs, -15, OSMO_TDEF_US, -1));
- break;
- default:
- /* Transition to any other state means whatever IA the BSC has sent shall now not be relevant
- * anymore. */
+ }
+ break;
+ default:
+ if (lchan->early_rr_ia) {
+ /* Early Immediate Assignment: Transition to any other
+ * state means whatever IA the BSC has sent shall now
+ * not be relevant anymore. */
osmo_timer_del(&lchan->early_rr_ia_delay);
msgb_free(lchan->early_rr_ia);
lchan->early_rr_ia = NULL;
- break;
}
+ break;
}
}
diff --git a/src/osmo-bts-lc15/oml.c b/src/osmo-bts-lc15/oml.c
index 6169ef7..675e3fe 100644
--- a/src/osmo-bts-lc15/oml.c
+++ b/src/osmo-bts-lc15/oml.c
@@ -1197,10 +1197,6 @@
enqueue_sapi_act_cmd(lchan, sapi, dir);
}
-
-#warning "FIXME: Should this be in sapi_activate_cb?"
- lchan_init_lapdm(lchan);
-
return 0;
}
diff --git a/src/osmo-bts-oc2g/oml.c b/src/osmo-bts-oc2g/oml.c
index ba85f36..d12571b 100644
--- a/src/osmo-bts-oc2g/oml.c
+++ b/src/osmo-bts-oc2g/oml.c
@@ -1212,10 +1212,6 @@
enqueue_sapi_act_cmd(lchan, sapi, dir);
}
-
-#warning "FIXME: Should this be in sapi_activate_cb?"
- lchan_init_lapdm(lchan);
-
return 0;
}
diff --git a/src/osmo-bts-octphy/l1_oml.c b/src/osmo-bts-octphy/l1_oml.c
index 73ab9bd..5894c21 100644
--- a/src/osmo-bts-octphy/l1_oml.c
+++ b/src/osmo-bts-octphy/l1_oml.c
@@ -1107,9 +1107,6 @@
}
enqueue_sapi_act_cmd(lchan, sapi, dir);
}
-
- lchan_init_lapdm(lchan);
-
return 0;
}
diff --git a/src/osmo-bts-sysmo/oml.c b/src/osmo-bts-sysmo/oml.c
index 74af56b..ba60b76 100644
--- a/src/osmo-bts-sysmo/oml.c
+++ b/src/osmo-bts-sysmo/oml.c
@@ -1204,10 +1204,6 @@
continue;
enqueue_sapi_act_cmd(lchan, sapi, dir);
}
-
-#warning "FIXME: Should this be in sapi_activate_cb?"
- lchan_init_lapdm(lchan);
-
return 0;
}
diff --git a/src/osmo-bts-trx/l1_if.c b/src/osmo-bts-trx/l1_if.c
index 9faae88..5ac3e31 100644
--- a/src/osmo-bts-trx/l1_if.c
+++ b/src/osmo-bts-trx/l1_if.c
@@ -165,10 +165,6 @@
if (rc != 0)
return osmo_fsm_inst_dispatch(trx->mo.fi, NM_EV_OPSTART_NACK,
(void*)(intptr_t)NM_NACK_CANT_PERFORM);
-
- if (trx == trx->bts->c0)
- lchan_init_lapdm(&trx->ts[0].lchan[CCCH_LCHAN]);
-
/* Send OPSTART ack */
return osmo_fsm_inst_dispatch(trx->mo.fi, NM_EV_OPSTART_ACK, NULL);
}
@@ -438,8 +434,6 @@
lchan->tch.amr_mr.bts_mode[3].mode,
amr_get_initial_mode(lchan),
(lchan->ho.active == 1));
- /* init lapdm */
- lchan_init_lapdm(lchan);
/* set lchan active */
lchan_set_state(lchan, LCHAN_S_ACTIVE);
/* set initial ciphering */
diff --git a/src/osmo-bts-virtual/l1_if.c b/src/osmo-bts-virtual/l1_if.c
index a4a81bd..0d36db1 100644
--- a/src/osmo-bts-virtual/l1_if.c
+++ b/src/osmo-bts-virtual/l1_if.c
@@ -224,8 +224,6 @@
* / PRIM_INFO_ACTIVATE */
if (pinst->trx == pinst->trx->bts->c0) {
vbts_sched_start(pinst->trx->bts);
- /* init lapdm layer 3 callback for the trx on timeslot 0 == BCCH */
- lchan_init_lapdm(&pinst->trx->ts[0].lchan[CCCH_LCHAN]);
/* FIXME: This is probably the wrong location to set the CCCH to active... the OML link def. needs to be reworked and fixed. */
pinst->trx->ts[0].lchan[CCCH_LCHAN].rel_act_kind = LCHAN_REL_ACT_OML;
lchan_set_state(&pinst->trx->ts[0].lchan[CCCH_LCHAN], LCHAN_S_ACTIVE);
@@ -392,8 +390,6 @@
lchan->tch.amr_mr.bts_mode[3].mode,
amr_get_initial_mode(lchan),
(lchan->ho.active == 1));
- /* init lapdm */
- lchan_init_lapdm(lchan);
/* set lchan active */
lchan_set_state(lchan, LCHAN_S_ACTIVE);
/* set initial ciphering */
--
To view, visit https://gerrit.osmocom.org/c/osmo-bts/+/25791
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings
Gerrit-Project: osmo-bts
Gerrit-Branch: master
Gerrit-Change-Id: I7a9c3660b9aab57ff8765e2f1526349599630cd9
Gerrit-Change-Number: 25791
Gerrit-PatchSet: 2
Gerrit-Owner: pespin <pespin at sysmocom.de>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: dexter <pmaier at sysmocom.de>
Gerrit-Reviewer: fixeria <vyanitskiy at sysmocom.de>
Gerrit-Reviewer: laforge <laforge at osmocom.org>
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/20211015/99241757/attachment.htm>