Attention is currently required from: daniel.
pespin has posted comments on this change. ( https://gerrit.osmocom.org/c/libosmo-netif/+/34338?usp=email )
Change subject: stream_srv: Fix connection error handling
......................................................................
Patch Set 2: Code-Review+1
(1 comment)
File src/stream_srv.c:
https://gerrit.osmocom.org/c/libosmo-netif/+/34338/comment/2ebaa55c_94d79846
PS2, Line 492: } else {
did you think about simply doing early return here instead?
--
To view, visit https://gerrit.osmocom.org/c/libosmo-netif/+/34338?usp=email
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings
Gerrit-Project: libosmo-netif
Gerrit-Branch: master
Gerrit-Change-Id: I84eea2717f3762830f3f5b115e6fc8545eaa4fd5
Gerrit-Change-Number: 34338
Gerrit-PatchSet: 2
Gerrit-Owner: daniel <dwillmann(a)sysmocom.de>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: pespin <pespin(a)sysmocom.de>
Gerrit-Attention: daniel <dwillmann(a)sysmocom.de>
Gerrit-Comment-Date: Thu, 07 Sep 2023 16:48:25 +0000
Gerrit-HasComments: Yes
Gerrit-Has-Labels: Yes
Gerrit-MessageType: comment
pespin has uploaded this change for review. ( https://gerrit.osmocom.org/c/osmo-bts/+/34340?usp=email )
Change subject: bts-trx: Fix CCCH not enabled if BS_AG_BLKS_RES!=1 is provided by BSC
......................................................................
bts-trx: Fix CCCH not enabled if BS_AG_BLKS_RES!=1 is provided by BSC
Other bts models like sysmo,lc15,oc2g properly handled
rel_act_kind=LCHAN_REL_ACT_REACT under the bts_model_lchan_deactivate()
implementation, but bts-trx didn't.
As a result, when BCCH_INFO(SYSINFO_TYPE_3) coming from BSC (RSL)
containing a different BS_AG_BLKS_RES triggers CCCH re-activation,
it would only deactivate it but not re-activate it.
That means no SIs were being scheduled if bts was configured with
"channel-descrption bs-ag-blks-res 2" in osmo-bsc.cfg, and phones would
not see the cell.
Related: OS#1575
Change-Id: I61e1681fbaa2c993b529d58b581c99166b62bda3
---
M src/common/rsl.c
M src/osmo-bts-trx/l1_if.c
2 files changed, 37 insertions(+), 9 deletions(-)
git pull ssh://gerrit.osmocom.org:29418/osmo-bts refs/changes/40/34340/1
diff --git a/src/common/rsl.c b/src/common/rsl.c
index b37dd43..972de85 100644
--- a/src/common/rsl.c
+++ b/src/common/rsl.c
@@ -630,10 +630,12 @@
switch (osmo_si) {
case SYSINFO_TYPE_3:
if (trx->nr == 0 && num_agch(trx, "RSL") != 1) {
- lchan_deactivate(&trx->bts->c0->ts[0].lchan[CCCH_LCHAN]);
- /* will be reactivated by sapi_deactivate_cb() */
trx->bts->c0->ts[0].lchan[CCCH_LCHAN].rel_act_kind =
LCHAN_REL_ACT_REACT;
+ lchan_deactivate(&trx->bts->c0->ts[0].lchan[CCCH_LCHAN]);
+ /* will be reactivated by (see OS#1575):
+ * - bts-trx: lchan_deactivate()
+ * - sysmo,lc15,oc2g: lchan_deactivate()....[async]...sapi_deactivate_cb() */
}
/* decode original SI3 Rest Octets as sent by BSC */
si_buf = (const uint8_t *) GSM_BTS_SI(bts, osmo_si);
diff --git a/src/osmo-bts-trx/l1_if.c b/src/osmo-bts-trx/l1_if.c
index a1329a8..ab66094 100644
--- a/src/osmo-bts-trx/l1_if.c
+++ b/src/osmo-bts-trx/l1_if.c
@@ -90,16 +90,21 @@
int bts_model_lchan_deactivate(struct gsm_lchan *lchan)
{
- if (lchan->rel_act_kind == LCHAN_REL_ACT_REACT) {
- lchan->rel_act_kind = LCHAN_REL_ACT_RSL;
- /* FIXME: perform whatever is needed (if any) to set proper PCH/AGCH allocation according to
- 3GPP TS 44.018 Table 10.5.2.11.1 using num_agch(lchan->ts->trx, "TRX L1"); function */
- return 0;
- }
+ int rc;
/* set lchan inactive */
lchan_set_state(lchan, LCHAN_S_NONE);
- return trx_sched_set_lchan(lchan, gsm_lchan2chan_nr(lchan), LID_DEDIC, false);
+ /* Disable it on the scheduler: */
+ rc = trx_sched_set_lchan(lchan, gsm_lchan2chan_nr(lchan), LID_DEDIC, false);
+
+ /* Reactivate CCCH due to SI3 update in RSL */
+ if (lchan->rel_act_kind == LCHAN_REL_ACT_REACT) {
+ lchan->rel_act_kind = LCHAN_REL_ACT_RSL;
+ trx_sched_set_lchan(lchan, gsm_lchan2chan_nr(lchan), LID_DEDIC, true);
+ lchan_set_state(lchan, LCHAN_S_ACTIVE);
+ return rc;
+ }
+ return rc;
}
int bts_model_lchan_deactivate_sacch(struct gsm_lchan *lchan)
--
To view, visit https://gerrit.osmocom.org/c/osmo-bts/+/34340?usp=email
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings
Gerrit-Project: osmo-bts
Gerrit-Branch: master
Gerrit-Change-Id: I61e1681fbaa2c993b529d58b581c99166b62bda3
Gerrit-Change-Number: 34340
Gerrit-PatchSet: 1
Gerrit-Owner: pespin <pespin(a)sysmocom.de>
Gerrit-MessageType: newchange
Attention is currently required from: arehbein, laforge.
dexter has posted comments on this change. ( https://gerrit.osmocom.org/c/osmo-bsc/+/33891?usp=email )
Change subject: osmo-bsc: Have PCU socket connection use osmo_wqueue
......................................................................
Patch Set 2: Verified+1 Code-Review+1
(1 comment)
File src/osmo-bsc/pcu_sock.c:
https://gerrit.osmocom.org/c/osmo-bsc/+/33891/comment/eb2e81e8_f699fae8
PS2, Line 725: "%u messages waiting). Closing connection\n",
We usually try to avoid breaking strings since it makes it them harder to grep. This is also what kernel coding style recommends.
--
To view, visit https://gerrit.osmocom.org/c/osmo-bsc/+/33891?usp=email
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings
Gerrit-Project: osmo-bsc
Gerrit-Branch: master
Gerrit-Change-Id: Ifd9741045a87338e17eec3492590a5de9c308cb5
Gerrit-Change-Number: 33891
Gerrit-PatchSet: 2
Gerrit-Owner: arehbein <arehbein(a)sysmocom.de>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: dexter <pmaier(a)sysmocom.de>
Gerrit-Reviewer: pespin <pespin(a)sysmocom.de>
Gerrit-CC: laforge <laforge(a)osmocom.org>
Gerrit-Attention: arehbein <arehbein(a)sysmocom.de>
Gerrit-Attention: laforge <laforge(a)osmocom.org>
Gerrit-Comment-Date: Thu, 07 Sep 2023 16:15:25 +0000
Gerrit-HasComments: Yes
Gerrit-Has-Labels: Yes
Gerrit-MessageType: comment
Attention is currently required from: pespin.
daniel has posted comments on this change. ( https://gerrit.osmocom.org/c/libosmo-netif/+/34338?usp=email )
Change subject: stream_srv: Fix connection error handling
......................................................................
Patch Set 2:
(2 comments)
File src/stream_srv.c:
https://gerrit.osmocom.org/c/libosmo-netif/+/34338/comment/51457438_4e5307f5
PS1, Line 489: if (res <= 0) {
> OSMO_UNLIKELY()
Done
https://gerrit.osmocom.org/c/libosmo-netif/+/34338/comment/3efda64c_aa233bdb
PS1, Line 493: if (conn->flags & OSMO_STREAM_SRV_F_FLUSH_DESTROY) {
> so if iofd_read_cb is not sent you won't destroy the conn? this looks wrong?
You're right, thanks! It's also leaking msg if iofd_read_cb is not set, though I'm unsure how common/useful an osmo_stream_srv without a read callback even is.
--
To view, visit https://gerrit.osmocom.org/c/libosmo-netif/+/34338?usp=email
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings
Gerrit-Project: libosmo-netif
Gerrit-Branch: master
Gerrit-Change-Id: I84eea2717f3762830f3f5b115e6fc8545eaa4fd5
Gerrit-Change-Number: 34338
Gerrit-PatchSet: 2
Gerrit-Owner: daniel <dwillmann(a)sysmocom.de>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: pespin <pespin(a)sysmocom.de>
Gerrit-Attention: pespin <pespin(a)sysmocom.de>
Gerrit-Comment-Date: Thu, 07 Sep 2023 15:56:00 +0000
Gerrit-HasComments: Yes
Gerrit-Has-Labels: No
Comment-In-Reply-To: pespin <pespin(a)sysmocom.de>
Gerrit-MessageType: comment
Attention is currently required from: pespin.
Hello Jenkins Builder, pespin,
I'd like you to reexamine a change. Please visit
https://gerrit.osmocom.org/c/libosmo-netif/+/34338?usp=email
to look at the new patch set (#2).
The following approvals got outdated and were removed:
Code-Review-1 by pespin, Verified+1 by Jenkins Builder
Change subject: stream_srv: Fix connection error handling
......................................................................
stream_srv: Fix connection error handling
If read returned an error or the stream got closed then simply destroy
the connection.
If the user code called osmo_stream_srv_set_flush_and_destroy() then
ignore any incoming messages and destroy the connection once the tx
queue is empty.
Change-Id: I84eea2717f3762830f3f5b115e6fc8545eaa4fd5
---
M src/stream_srv.c
1 file changed, 31 insertions(+), 12 deletions(-)
git pull ssh://gerrit.osmocom.org:29418/libosmo-netif refs/changes/38/34338/2
--
To view, visit https://gerrit.osmocom.org/c/libosmo-netif/+/34338?usp=email
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings
Gerrit-Project: libosmo-netif
Gerrit-Branch: master
Gerrit-Change-Id: I84eea2717f3762830f3f5b115e6fc8545eaa4fd5
Gerrit-Change-Number: 34338
Gerrit-PatchSet: 2
Gerrit-Owner: daniel <dwillmann(a)sysmocom.de>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: pespin <pespin(a)sysmocom.de>
Gerrit-Attention: pespin <pespin(a)sysmocom.de>
Gerrit-MessageType: newpatchset