pespin has submitted this change. (
https://gerrit.osmocom.org/c/osmo-bsc/+/29372 )
Change subject: ipaccess-config: Initiate missing IPA osmo_link
......................................................................
ipaccess-config: Initiate missing IPA osmo_link
Since this is created by osmo-bsc, it is also expected to be there by
ipaccess_drop_oml() in the shared libbsc code. But ipaccess-config was
not creating it, so let's do so.
Let's explicitly assert this condition in the code path expecting the
pointer to be instantiated in shared code, to easily track related
issues in the future.
Change-Id: I3f63f6827f7c5d7a21ac125b7ca6b35244efbb65
---
M src/ipaccess/ipaccess-config.c
M src/osmo-bsc/bts_ipaccess_nanobts.c
2 files changed, 5 insertions(+), 1 deletion(-)
Approvals:
neels: Looks good to me, but someone else must approve
fixeria: Looks good to me, but someone else must approve
pespin: Looks good to me, approved
Jenkins Builder: Verified
diff --git a/src/ipaccess/ipaccess-config.c b/src/ipaccess/ipaccess-config.c
index 7c8d486..a214d28 100644
--- a/src/ipaccess/ipaccess-config.c
+++ b/src/ipaccess/ipaccess-config.c
@@ -129,7 +129,7 @@
{
struct e1inp_line *line;
struct e1inp_ts *sign_ts, *rsl_ts;
- struct e1inp_sign_link *oml_link, *rsl_link;
+ struct e1inp_sign_link *oml_link, *osmo_link, *rsl_link;
line = talloc_zero(tall_bsc_ctx, struct e1inp_line);
if (!line)
@@ -152,11 +152,14 @@
/* create signalling links for TRX0 */
oml_link = e1inp_sign_link_create(sign_ts, E1INP_SIGN_OML,
bts->c0, IPAC_PROTO_OML, 0);
+ osmo_link = e1inp_sign_link_create(sign_ts, E1INP_SIGN_OSMO,
+ bts->c0, IPAC_PROTO_OSMO, 0);
rsl_link = e1inp_sign_link_create(rsl_ts, E1INP_SIGN_RSL,
bts->c0, IPAC_PROTO_RSL, 0);
/* create back-links from bts/trx */
bts->oml_link = oml_link;
+ bts->osmo_link = osmo_link;
bts->c0->rsl_link_primary = rsl_link;
/* default port at BTS for incoming connections is 3006 */
diff --git a/src/osmo-bsc/bts_ipaccess_nanobts.c b/src/osmo-bsc/bts_ipaccess_nanobts.c
index 3165944..c4df29e 100644
--- a/src/osmo-bsc/bts_ipaccess_nanobts.c
+++ b/src/osmo-bsc/bts_ipaccess_nanobts.c
@@ -616,6 +616,7 @@
gsm_bts_stats_reset(bts);
/* Also drop the associated OSMO link */
+ OSMO_ASSERT(bts->osmo_link);
e1inp_sign_link_destroy(bts->osmo_link);
bts->osmo_link = NULL;
--
To view, visit
https://gerrit.osmocom.org/c/osmo-bsc/+/29372
To unsubscribe, or for help writing mail filters, visit
https://gerrit.osmocom.org/settings
Gerrit-Project: osmo-bsc
Gerrit-Branch: master
Gerrit-Change-Id: I3f63f6827f7c5d7a21ac125b7ca6b35244efbb65
Gerrit-Change-Number: 29372
Gerrit-PatchSet: 2
Gerrit-Owner: pespin <pespin(a)sysmocom.de>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: fixeria <vyanitskiy(a)sysmocom.de>
Gerrit-Reviewer: neels <nhofmeyr(a)sysmocom.de>
Gerrit-Reviewer: pespin <pespin(a)sysmocom.de>
Gerrit-MessageType: merged