pespin has uploaded this change for review. ( 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(-)
git pull ssh://gerrit.osmocom.org:29418/osmo-bsc refs/changes/72/29372/1
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: 1
Gerrit-Owner: pespin <pespin(a)sysmocom.de>
Gerrit-MessageType: newchange
pespin has uploaded this change for review. ( https://gerrit.osmocom.org/c/osmo-bsc/+/29373 )
Change subject: ipaccess-config: Initialize RSL ts driver fd to proper value
......................................................................
ipaccess-config: Initialize RSL ts driver fd to proper value
ipaccess-config sets up the entire line in a fake way.
That requires also setting the fd of each TS used to -1 in order to
avoid library code interacting with it during tear down if an error
occurs.
Change-Id: I19eb23a46f89b96dd8d63742ca2078ecd5c9ab6b
---
M src/ipaccess/ipaccess-config.c
1 file changed, 1 insertion(+), 0 deletions(-)
git pull ssh://gerrit.osmocom.org:29418/osmo-bsc refs/changes/73/29373/1
diff --git a/src/ipaccess/ipaccess-config.c b/src/ipaccess/ipaccess-config.c
index a214d28..4d5e8b1 100644
--- a/src/ipaccess/ipaccess-config.c
+++ b/src/ipaccess/ipaccess-config.c
@@ -148,6 +148,7 @@
/* create E1 timeslots for signalling and TRAU frames */
e1inp_ts_config_sign(sign_ts, line);
e1inp_ts_config_sign(rsl_ts, line);
+ rsl_ts->driver.ipaccess.fd.fd = -1;
/* create signalling links for TRX0 */
oml_link = e1inp_sign_link_create(sign_ts, E1INP_SIGN_OML,
--
To view, visit https://gerrit.osmocom.org/c/osmo-bsc/+/29373
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings
Gerrit-Project: osmo-bsc
Gerrit-Branch: master
Gerrit-Change-Id: I19eb23a46f89b96dd8d63742ca2078ecd5c9ab6b
Gerrit-Change-Number: 29373
Gerrit-PatchSet: 1
Gerrit-Owner: pespin <pespin(a)sysmocom.de>
Gerrit-MessageType: newchange
Attention is currently required from: pespin.
Hello Jenkins Builder,
I'd like you to reexamine a change. Please visit
https://gerrit.osmocom.org/c/libosmo-abis/+/29370
to look at the new patch set (#2).
Change subject: ipaccess_close(): No need to lookup already available struct e1i_ts
......................................................................
ipaccess_close(): No need to lookup already available struct e1i_ts
Change-Id: I54a69cad5adc3df3f95dd51e00ea68bb04ba9963
---
M src/input/ipaccess.c
1 file changed, 4 insertions(+), 8 deletions(-)
git pull ssh://gerrit.osmocom.org:29418/libosmo-abis refs/changes/70/29370/2
--
To view, visit https://gerrit.osmocom.org/c/libosmo-abis/+/29370
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings
Gerrit-Project: libosmo-abis
Gerrit-Branch: master
Gerrit-Change-Id: I54a69cad5adc3df3f95dd51e00ea68bb04ba9963
Gerrit-Change-Number: 29370
Gerrit-PatchSet: 2
Gerrit-Owner: pespin <pespin(a)sysmocom.de>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Attention: pespin <pespin(a)sysmocom.de>
Gerrit-MessageType: newpatchset
Jenkins Builder has posted comments on this change. ( https://gerrit.osmocom.org/c/libosmo-abis/+/29370 )
Change subject: ipaccess_close(): No need to lookup already available struct e1i_ts
......................................................................
Patch Set 1:
(1 comment)
File src/input/ipaccess.c:
Robot Comment from checkpatch (run ID jenkins-gerrit-libosmo-abis-lint-36):
https://gerrit.osmocom.org/c/libosmo-abis/+/29370/comment/bc0212e4_8002d650
PS1, Line 457: struct osmo_fsm_inst* ka_fsm = e1i_ts->driver.ipaccess.ka_fsm;
"foo* bar" should be "foo *bar"
--
To view, visit https://gerrit.osmocom.org/c/libosmo-abis/+/29370
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings
Gerrit-Project: libosmo-abis
Gerrit-Branch: master
Gerrit-Change-Id: I54a69cad5adc3df3f95dd51e00ea68bb04ba9963
Gerrit-Change-Number: 29370
Gerrit-PatchSet: 1
Gerrit-Owner: pespin <pespin(a)sysmocom.de>
Gerrit-CC: Jenkins Builder
Gerrit-Comment-Date: Fri, 16 Sep 2022 17:24:44 +0000
Gerrit-HasComments: Yes
Gerrit-Has-Labels: No
Gerrit-MessageType: comment
pespin has uploaded this change for review. ( https://gerrit.osmocom.org/c/libosmo-abis/+/29370 )
Change subject: ipaccess_close(): No need to lookup already available struct e1i_ts
......................................................................
ipaccess_close(): No need to lookup already available struct e1i_ts
Change-Id: I54a69cad5adc3df3f95dd51e00ea68bb04ba9963
---
M src/input/ipaccess.c
1 file changed, 4 insertions(+), 8 deletions(-)
git pull ssh://gerrit.osmocom.org:29418/libosmo-abis refs/changes/70/29370/1
diff --git a/src/input/ipaccess.c b/src/input/ipaccess.c
index 9331d07..fd6eabc 100644
--- a/src/input/ipaccess.c
+++ b/src/input/ipaccess.c
@@ -453,14 +453,10 @@
struct osmo_fd *bfd = &e1i_ts->driver.ipaccess.fd;
struct e1inp_line *line = e1i_ts->line;
- /* line might not exist if != bsc||bts */
- if (line) {
- /* depending on caller the fsm might be dead */
- struct osmo_fsm_inst* ka_fsm = ipaccess_line_ts(bfd, line)->driver.ipaccess.ka_fsm;
- if (ka_fsm)
- ipa_keepalive_fsm_stop(ka_fsm);
-
- }
+ /* depending on caller the fsm might be dead */
+ struct osmo_fsm_inst* ka_fsm = e1i_ts->driver.ipaccess.ka_fsm;
+ if (ka_fsm)
+ ipa_keepalive_fsm_stop(ka_fsm);
e1inp_int_snd_event(e1i_ts, sign_link, S_L_INP_TEI_DN);
/* the first e1inp_sign_link_destroy call closes the socket. */
--
To view, visit https://gerrit.osmocom.org/c/libosmo-abis/+/29370
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings
Gerrit-Project: libosmo-abis
Gerrit-Branch: master
Gerrit-Change-Id: I54a69cad5adc3df3f95dd51e00ea68bb04ba9963
Gerrit-Change-Number: 29370
Gerrit-PatchSet: 1
Gerrit-Owner: pespin <pespin(a)sysmocom.de>
Gerrit-MessageType: newchange
pespin has uploaded this change for review. ( https://gerrit.osmocom.org/c/libosmo-abis/+/29371 )
Change subject: ipaccess: Call line->ops->sign_link_down() only if set
......................................................................
ipaccess: Call line->ops->sign_link_down() only if set
This op must not necessarily be set by the user, so check if it is set
before calling it.
Change-Id: I666c5bbf157fe604e336df44f7eac098572d42ba
---
M src/input/ipaccess.c
1 file changed, 2 insertions(+), 1 deletion(-)
git pull ssh://gerrit.osmocom.org:29418/libosmo-abis refs/changes/71/29371/1
diff --git a/src/input/ipaccess.c b/src/input/ipaccess.c
index fd6eabc..0180e12 100644
--- a/src/input/ipaccess.c
+++ b/src/input/ipaccess.c
@@ -123,7 +123,8 @@
e1i_ts->pending_msg = NULL;
/* e1inp_sign_link_destroy releases the socket descriptors for us. */
- line->ops->sign_link_down(line);
+ if (line->ops->sign_link_down)
+ line->ops->sign_link_down(line);
e1inp_line_put2(line, __func__);
return ret;
--
To view, visit https://gerrit.osmocom.org/c/libosmo-abis/+/29371
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings
Gerrit-Project: libosmo-abis
Gerrit-Branch: master
Gerrit-Change-Id: I666c5bbf157fe604e336df44f7eac098572d42ba
Gerrit-Change-Number: 29371
Gerrit-PatchSet: 1
Gerrit-Owner: pespin <pespin(a)sysmocom.de>
Gerrit-MessageType: newchange