Attention is currently required from: pespin.
laforge has posted comments on this change. ( https://gerrit.osmocom.org/c/libosmo-gprs/+/30921 )
Change subject: llc: Allow app provided callbacks to retain ownership of passed primitive
......................................................................
Patch Set 1: Code-Review+1
(1 comment)
Patchset:
PS1:
we've done this pattern in other places. Maybe it's time to introduce some kind of RET_SUCCESS_TAKEN_OWNERSHIP #define?
--
To view, visit https://gerrit.osmocom.org/c/libosmo-gprs/+/30921
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings
Gerrit-Project: libosmo-gprs
Gerrit-Branch: master
Gerrit-Change-Id: I6ea91b8f190a399c4bcf6c7cba9a65809aaf3ddb
Gerrit-Change-Number: 30921
Gerrit-PatchSet: 1
Gerrit-Owner: pespin <pespin(a)sysmocom.de>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: laforge <laforge(a)osmocom.org>
Gerrit-Attention: pespin <pespin(a)sysmocom.de>
Gerrit-Comment-Date: Tue, 10 Jan 2023 17:25:09 +0000
Gerrit-HasComments: Yes
Gerrit-Has-Labels: Yes
Gerrit-MessageType: comment
Attention is currently required from: dexter.
laforge has posted comments on this change. ( https://gerrit.osmocom.org/c/osmo-bsc/+/30922 )
Change subject: abis_rsl: fix frame number calculation
......................................................................
Patch Set 1: Code-Review+1
(1 comment)
Patchset:
PS1:
We might want to generalize this and introduce a macro or an inline function for euclidian modulo in libosmocore. There might very well be other locations in osmocom where we need an actual modulo, not just the remainder operation offered by C?
--
To view, visit https://gerrit.osmocom.org/c/osmo-bsc/+/30922
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings
Gerrit-Project: osmo-bsc
Gerrit-Branch: master
Gerrit-Change-Id: I5fb2b0ada8d409730ac22963741fb4ab0026abdd
Gerrit-Change-Number: 30922
Gerrit-PatchSet: 1
Gerrit-Owner: dexter <pmaier(a)sysmocom.de>
Gerrit-Reviewer: laforge <laforge(a)osmocom.org>
Gerrit-Attention: dexter <pmaier(a)sysmocom.de>
Gerrit-Comment-Date: Tue, 10 Jan 2023 17:22:29 +0000
Gerrit-HasComments: Yes
Gerrit-Has-Labels: Yes
Gerrit-MessageType: comment
dexter has uploaded this change for review. ( https://gerrit.osmocom.org/c/osmo-bsc/+/30922 )
Change subject: abis_rsl: fix frame number calculation
......................................................................
abis_rsl: fix frame number calculation
The formula that is used to recover the (relative) frame number from the
T1, T2, T3 parameters matches the definition in the spec, but since the
partial term t3-t2 can be negative special precaution is required when
performing the MOD 26 operation. This is due to the modulo
implementation in C/C++, which has a very specific understanding on how
to deal with negative input parameters.
Change-Id: I5fb2b0ada8d409730ac22963741fb4ab0026abdd
Related: OS#5198
---
M src/osmo-bsc/abis_rsl.c
1 file changed, 3 insertions(+), 1 deletion(-)
git pull ssh://gerrit.osmocom.org:29418/osmo-bsc refs/changes/22/30922/1
diff --git a/src/osmo-bsc/abis_rsl.c b/src/osmo-bsc/abis_rsl.c
index 640ff4d..fe5cfc6 100644
--- a/src/osmo-bsc/abis_rsl.c
+++ b/src/osmo-bsc/abis_rsl.c
@@ -1817,10 +1817,12 @@
rqd_ta = rqd->ta;
/* See also 3GPP TS 04.08, section 10.5.2.38 and 3GPP TS 08.58, section 9.3.8 */
+ /* NOTE: The forumula to compute fn was slightly altered to account for the C/C++
+ * specific modulo definition. */
t1 = rqd->ref.t1;
t2 = rqd->ref.t2;
t3 = rqd->ref.t3_low | (rqd->ref.t3_high << 3);
- fn = (51 * ((t3-t2) % 26) + t3 + 51 * 26 * t1);
+ fn = 51 * ((((t3-t2) % 26) + 26) % 26) + t3 + 51 * 26 * t1;
LOG_BTS(rqd->bts, DRSL, LOGL_INFO, "CHAN RQD: fn(t1=%u,t3=%u,t2=%u) = %u\n", t1, t3, t2, fn);
}
--
To view, visit https://gerrit.osmocom.org/c/osmo-bsc/+/30922
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings
Gerrit-Project: osmo-bsc
Gerrit-Branch: master
Gerrit-Change-Id: I5fb2b0ada8d409730ac22963741fb4ab0026abdd
Gerrit-Change-Number: 30922
Gerrit-PatchSet: 1
Gerrit-Owner: dexter <pmaier(a)sysmocom.de>
Gerrit-MessageType: newchange
pespin has uploaded this change for review. ( https://gerrit.osmocom.org/c/libosmo-gprs/+/30921 )
Change subject: llc: Allow app provided callbacks to retain ownership of passed primitive
......................................................................
llc: Allow app provided callbacks to retain ownership of passed primitive
This way the app can, for instance, simply forward the primtiive pointer
from LLC callback to SNDCP layer, which will in the end take the
ownership of the primitive and free it.
Change-Id: I6ea91b8f190a399c4bcf6c7cba9a65809aaf3ddb
---
M src/llc/llc_prim.c
1 file changed, 6 insertions(+), 2 deletions(-)
git pull ssh://gerrit.osmocom.org:29418/libosmo-gprs refs/changes/21/30921/1
diff --git a/src/llc/llc_prim.c b/src/llc/llc_prim.c
index e789819..b5fab8f 100644
--- a/src/llc/llc_prim.c
+++ b/src/llc/llc_prim.c
@@ -142,7 +142,9 @@
rc = g_ctx->llc_up_cb(llc_prim, g_ctx->llc_up_cb_user_data);
else
rc = llc_up_cb_dummy(llc_prim, g_ctx->llc_up_cb_user_data);
- msgb_free(llc_prim->oph.msg);
+ /* Special return value '1' means: do not free */
+ if (rc != 1)
+ msgb_free(llc_prim->oph.msg);
return rc;
}
@@ -178,7 +180,9 @@
rc = g_ctx->llc_down_cb(llc_prim, g_ctx->llc_down_cb_user_data);
else
rc = llc_down_cb_dummy(llc_prim, g_ctx->llc_down_cb_user_data);
- msgb_free(llc_prim->oph.msg);
+ /* Special return value '1' means: do not free */
+ if (rc != 1)
+ msgb_free(llc_prim->oph.msg);
return rc;
}
--
To view, visit https://gerrit.osmocom.org/c/libosmo-gprs/+/30921
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings
Gerrit-Project: libosmo-gprs
Gerrit-Branch: master
Gerrit-Change-Id: I6ea91b8f190a399c4bcf6c7cba9a65809aaf3ddb
Gerrit-Change-Number: 30921
Gerrit-PatchSet: 1
Gerrit-Owner: pespin <pespin(a)sysmocom.de>
Gerrit-MessageType: newchange
Attention is currently required from: dexter.
Hello Jenkins Builder, laforge, pespin,
I'd like you to reexamine a change. Please visit
https://gerrit.osmocom.org/c/osmo-bsc/+/30849
to look at the new patch set (#4).
Change subject: pcu_sock: drop unused variable pcu_direct
......................................................................
pcu_sock: drop unused variable pcu_direct
The variable pcu_direct is set to one permanently, lets remove it.
Change-Id: I7917ee5abc3347776dc9793cfb4ec3e99df94683
Related: OS#5198
---
M src/osmo-bsc/pcu_sock.c
1 file changed, 1 insertion(+), 4 deletions(-)
git pull ssh://gerrit.osmocom.org:29418/osmo-bsc refs/changes/49/30849/4
--
To view, visit https://gerrit.osmocom.org/c/osmo-bsc/+/30849
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings
Gerrit-Project: osmo-bsc
Gerrit-Branch: master
Gerrit-Change-Id: I7917ee5abc3347776dc9793cfb4ec3e99df94683
Gerrit-Change-Number: 30849
Gerrit-PatchSet: 4
Gerrit-Owner: dexter <pmaier(a)sysmocom.de>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: laforge <laforge(a)osmocom.org>
Gerrit-Reviewer: pespin <pespin(a)sysmocom.de>
Gerrit-Attention: dexter <pmaier(a)sysmocom.de>
Gerrit-MessageType: newpatchset