Attention is currently required from: arehbein, daniel, laforge.
pespin has posted comments on this change. ( https://gerrit.osmocom.org/c/libosmocore/+/35079?usp=email )
Change subject: osmo_io: Remove union in struct osmo_io_ops
......................................................................
Patch Set 4:
(1 comment)
Patchset:
PS4:
I'd actually keep the union, imho there's nothing wrong with it if used, plus:
- Doesn't break ABI with previous libosmocore release
- It saves some bytes on each osmo_io (there can be a big number of them in an app).
I agree though that the comment you mentioned should be fixed by checking the correct io_mode is in used before checking the pointer, since it's shared with other io_modes through the union.
TL;DR: Fix the code bugs, leave the union.
If still others prefer merging this, I won't oppose, just saying.
--
To view, visit https://gerrit.osmocom.org/c/libosmocore/+/35079?usp=email
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings
Gerrit-Project: libosmocore
Gerrit-Branch: master
Gerrit-Change-Id: I138d57843edc29000530bb7896bcb239002ecbec
Gerrit-Change-Number: 35079
Gerrit-PatchSet: 4
Gerrit-Owner: daniel <dwillmann(a)sysmocom.de>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: arehbein <arehbein(a)sysmocom.de>
Gerrit-Reviewer: laforge <laforge(a)osmocom.org>
Gerrit-CC: pespin <pespin(a)sysmocom.de>
Gerrit-Attention: arehbein <arehbein(a)sysmocom.de>
Gerrit-Attention: laforge <laforge(a)osmocom.org>
Gerrit-Attention: daniel <dwillmann(a)sysmocom.de>
Gerrit-Comment-Date: Wed, 29 Nov 2023 18:31:40 +0000
Gerrit-HasComments: Yes
Gerrit-Has-Labels: No
Gerrit-MessageType: comment
Attention is currently required from: daniel, laforge, lynxis lazus.
pespin has posted comments on this change. ( https://gerrit.osmocom.org/c/libosmocore/+/35078?usp=email )
Change subject: osmo_io: Factor out and use common send function from backend
......................................................................
Patch Set 2:
(3 comments)
File src/core/osmo_io.c:
https://gerrit.osmocom.org/c/libosmocore/+/35078/comment/65b7ef21_6f5bf225
PS1, Line 348: if (rc > 0 && rc < msgb_length(msg)) {
> Regarding your comment about rc == 0, maybe one missing failure case is rc == 0 && rc < msgb_length […]
That should fall into the more generic "rc < msgb_length(msg)" condition, I don't think the specific case you mention should be handled differently.
https://gerrit.osmocom.org/c/libosmocore/+/35078/comment/442aee50_3a53f950
PS1, Line 360:
> IMO rc == 0 in send means we have successfully "written" 0 bytes to the socket (which also means the […]
ack, makes sense, the special case for rc=0 is in the recv path (socket closed). I doubt we'll ever see rc=0 here, I'd expect it to return -EAGAIN instead.
send(len=0) would probably return an error, or maybe it returns 0 instead to mention it is writable.
File src/core/osmo_io_uring.c:
https://gerrit.osmocom.org/c/libosmocore/+/35078/comment/be9f52f1_8e2dfc28
PS2, Line 196: iofd_handle_send_completion(iofd, rc, msghdr);
The goto can easily be dropped:
if (IOFD_FLAG_ISSET(iofd, IOFD_FLAG_CLOSED)) {
msgb_free(msghdr->msg);
iofd_msghdr_free(msghdr);
} else {
iofd_handle_send_completion(iofd, rc, msghdr);
}
iofd->u.uring.write_msghdr = NULL;
/* submit the next to-be-transmitted message for this file descriptor */
if (iofd->u.uring.write_enabled && !IOFD_FLAG_ISSET(iofd, IOFD_FLAG_CLOSED))
iofd_uring_submit_tx(iofd);
You can btw probably ass OSMO_UNLIKELY() to the if condition checking IOFD_FLAG_CLOSED.
--
To view, visit https://gerrit.osmocom.org/c/libosmocore/+/35078?usp=email
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings
Gerrit-Project: libosmocore
Gerrit-Branch: master
Gerrit-Change-Id: I6da2653d32aedd0e7872be0cf90a841b56462e59
Gerrit-Change-Number: 35078
Gerrit-PatchSet: 2
Gerrit-Owner: daniel <dwillmann(a)sysmocom.de>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: lynxis lazus <lynxis(a)fe80.eu>
Gerrit-CC: laforge <laforge(a)osmocom.org>
Gerrit-CC: pespin <pespin(a)sysmocom.de>
Gerrit-Attention: laforge <laforge(a)osmocom.org>
Gerrit-Attention: daniel <dwillmann(a)sysmocom.de>
Gerrit-Attention: lynxis lazus <lynxis(a)fe80.eu>
Gerrit-Comment-Date: Wed, 29 Nov 2023 18:26:15 +0000
Gerrit-HasComments: Yes
Gerrit-Has-Labels: No
Comment-In-Reply-To: pespin <pespin(a)sysmocom.de>
Comment-In-Reply-To: daniel <dwillmann(a)sysmocom.de>
Gerrit-MessageType: comment
pespin has uploaded this change for review. ( https://gerrit.osmocom.org/c/osmo-hnbgw/+/35168?usp=email )
Change subject: mgw_fsm: Modify RAB on HNB if IuUP local IP addr at MGW changes during MDCX
......................................................................
mgw_fsm: Modify RAB on HNB if IuUP local IP addr at MGW changes during MDCX
Allow IP address renegotation between HNB and MGW:
* Upon MGCP MDCX ACK received from the RAN-side conn, if the IP address/port
changes, then restart the RAB-Ass-Req+Resp procedure on Iuh.
* Upon RAB-Ass-Resp received from the HNB, if the IP address/port changes,
then go through another MDCX + MDCX ACK prcoedure on MGCP.
An MDCX counter is introduced to avoid infinite loops where the HNB and
the MGW keep changing their IP address triggered by the change on the
other side, eg. due to incorrect network/routing setup.
The counter is also used to track count in order to make sure that
always at least 1 MDCX is transmitted, in order to change conn_mode to
SEND_RECV.
Related: OS#6127
Change-Id: I936a50fed38a201c4a8da99b40f07082049e5157
---
M src/osmo-hnbgw/mgw_fsm.c
1 file changed, 110 insertions(+), 61 deletions(-)
git pull ssh://gerrit.osmocom.org:29418/osmo-hnbgw refs/changes/68/35168/1
diff --git a/src/osmo-hnbgw/mgw_fsm.c b/src/osmo-hnbgw/mgw_fsm.c
index e1e53fb..1e04f58 100644
--- a/src/osmo-hnbgw/mgw_fsm.c
+++ b/src/osmo-hnbgw/mgw_fsm.c
@@ -109,6 +109,11 @@
ranap_message *ranap_rab_ass_req_message;
ranap_message *ranap_rab_ass_resp_message;
struct msgb *ranap_rab_ass_resp_msgb;
+ /* IP address contained in ranap_rab_ass_resp_msgb/message: */
+ struct osmo_sockaddr hnb_rtp_addr;
+ /* Number of MDCX transmitted. Used to detect current mgw conn_mode and
+ * detect modify infinite loops: */
+ unsigned int mdcx_tx_cnt;
/* MGW context */
struct mgcp_client *mgcpc;
@@ -205,8 +210,6 @@
struct mgw_fsm_priv *mgw_fsm_priv = fi->priv;
const struct mgcp_conn_peer *mgw_info;
struct osmo_sockaddr_str addr_str;
- struct osmo_sockaddr *addr = &mgw_fsm_priv->ci_hnb_crcx_ack_addr;
- RANAP_RAB_AssignmentRequestIEs_t *ies;
int rc;
switch (event) {
@@ -224,7 +227,7 @@
addr_str.af = AF_INET6;
addr_str.port = mgw_info->port;
osmo_strlcpy(addr_str.ip, mgw_info->addr, sizeof(addr_str.ip));
- rc = osmo_sockaddr_str_to_sockaddr(&addr_str, &addr->u.sas);
+ rc = osmo_sockaddr_str_to_sockaddr(&addr_str, &mgw_fsm_priv->ci_hnb_crcx_ack_addr.u.sas);
if (rc < 0) {
LOGPFSML(fi, LOGL_ERROR,
"Failed to convert RTP IP-address (%s) and Port (%u) to its binary representation\n",
@@ -233,16 +236,6 @@
return;
}
- ies = &mgw_fsm_priv->ranap_rab_ass_req_message->msg.raB_AssignmentRequestIEs;
- rc = ranap_rab_ass_req_ies_replace_inet_addr(ies, addr, mgw_fsm_priv->rab_id);
- if (rc < 0) {
- LOGPFSML(fi, LOGL_ERROR,
- "Failed to replace RTP IP-address (%s) and Port (%u) in RAB-AssignmentRequest\n",
- mgw_info->addr, mgw_info->port);
- osmo_fsm_inst_state_chg(fi, MGW_ST_FAILURE, 0, 0);
- return;
- }
-
mgw_fsm_state_chg(fi, MGW_ST_ASSIGN);
return;
default:
@@ -256,8 +249,16 @@
struct hnbgw_context_map *map = mgw_fsm_priv->map;
RANAP_RAB_AssignmentRequestIEs_t *ies;
struct msgb *msg;
+ int rc;
ies = &mgw_fsm_priv->ranap_rab_ass_req_message->msg.raB_AssignmentRequestIEs;
+ rc = ranap_rab_ass_req_ies_replace_inet_addr(ies, &mgw_fsm_priv->ci_hnb_crcx_ack_addr, mgw_fsm_priv->rab_id);
+ if (rc < 0) {
+ LOGPFSML(fi, LOGL_ERROR, "Failed to replace RTP IP-address and Port in RAB-AssignmentRequest\n");
+ osmo_fsm_inst_state_chg(fi, MGW_ST_FAILURE, 0, 0);
+ return;
+ }
+
msg = ranap_rab_ass_req_encode(ies);
if (!msg) {
LOGPFSML(fi, LOGL_ERROR, "failed to re-encode RAB-AssignmentRequest message\n");
@@ -273,9 +274,72 @@
static void mgw_fsm_assign(struct osmo_fsm_inst *fi, uint32_t event, void *data)
{
+ struct mgw_fsm_priv *mgw_fsm_priv = fi->priv;
+ struct hnbgw_context_map *map = mgw_fsm_priv->map;
+ RANAP_RAB_AssignmentResponseIEs_t *ies;
+ bool rab_failed_at_hnb;
+ struct osmo_sockaddr addr;
+ enum mgw_fsm_state next_st;
+ int rc;
+
switch (event) {
case MGW_EV_RAB_ASS_RESP:
- mgw_fsm_state_chg(fi, MGW_ST_MDCX_HNB);
+ LOGPFSML(fi, LOGL_DEBUG, "RAB-AssignmentResponse received, completing HNB side call-leg on MGW...\n");
+ ies = &mgw_fsm_priv->ranap_rab_ass_resp_message->msg.raB_AssignmentResponseIEs;
+ rc = ranap_rab_ass_resp_ies_extract_inet_addr(&addr, ies, mgw_fsm_priv->rab_id);
+ if (rc < 0) {
+ rab_failed_at_hnb = ranap_rab_ass_resp_ies_check_failure(ies, mgw_fsm_priv->rab_id);
+ if (rab_failed_at_hnb) {
+ struct msgb *msg;
+
+ LOGPFSML(fi, LOGL_ERROR,
+ "The RAB-AssignmentResponse contains a RAB-FailedList, RAB-Assignment (%u) failed.\n",
+ mgw_fsm_priv->rab_id);
+
+ /* Forward the RAB-AssignmentResponse transparently. This will ensure that the MSC is informed
+ * about the problem. */
+ LOGPFSML(fi, LOGL_DEBUG, "forwarding unmodified RAB-AssignmentResponse to MSC\n");
+
+ msg = mgw_fsm_priv->ranap_rab_ass_resp_msgb;
+ mgw_fsm_priv->ranap_rab_ass_resp_msgb = NULL;
+ talloc_steal(OTC_SELECT, msg);
+
+ rc = map_sccp_dispatch(map, MAP_SCCP_EV_TX_DATA_REQUEST, msg);
+ if (rc < 0) {
+ LOGPFSML(fi, LOGL_DEBUG, "failed to forward RAB-AssignmentResponse message\n");
+ osmo_fsm_inst_state_chg(fi, MGW_ST_FAILURE, 0, 0);
+ }
+
+ /* Even though this is a failure situation, we still release normally as the error is located
+ * at the HNB. */
+ osmo_fsm_inst_state_chg(fi, MGW_ST_RELEASE, 0, 0);
+ return;
+ }
+
+ /* The RAB-ID we are dealing with is not on an FailedList and we were unable to parse the response
+ * normally. This is a situation we cannot recover from. */
+ LOGPFSML(fi, LOGL_ERROR, "Failed to extract RTP IP-address and Port from RAB-AssignmentResponse\n");
+ osmo_fsm_inst_state_chg(fi, MGW_ST_FAILURE, 0, 0);
+ return;
+ }
+
+ /* Break infinite loops modifications between HNB and our MGW: */
+ if (mgw_fsm_priv->mdcx_tx_cnt > 3) {
+ osmo_fsm_inst_state_chg(fi, MGW_ST_RELEASE, 0, 0);
+ return;
+ }
+
+ /* Send at least 1 MDCX in order to change conn_mode to SEND_RECV.
+ * From there on, MDCX is only needed if HNB IP/Port changed: */
+ if (mgw_fsm_priv->mdcx_tx_cnt == 0 ||
+ osmo_sockaddr_cmp(&addr, &mgw_fsm_priv->hnb_rtp_addr) != 0) {
+ next_st = MGW_ST_MDCX_HNB;
+ } else {
+ LOGPFSML(fi, LOGL_DEBUG, "RAB-AssignmentResponse received with unchanged IuUP attributes, skipping MDCX...\n");
+ next_st = MGW_ST_CRCX_MSC;
+ }
+ mgw_fsm_priv->hnb_rtp_addr = addr;
+ mgw_fsm_state_chg(fi, next_st);
return;
default:
OSMO_ASSERT(false);
@@ -287,13 +351,8 @@
struct mgw_fsm_priv *mgw_fsm_priv = fi->priv;
struct hnbgw_context_map *map = mgw_fsm_priv->map;
struct mgcp_conn_peer mgw_info;
- struct osmo_sockaddr addr;
struct osmo_sockaddr_str addr_str;
- RANAP_RAB_AssignmentResponseIEs_t *ies;
int rc;
- bool rab_failed_at_hnb;
-
- LOGPFSML(fi, LOGL_DEBUG, "RAB-AssignmentResponse received, completing HNB side call-leg on MGW...\n");
mgw_info = (struct mgcp_conn_peer) {
.call_id = map->rua_ctx_id,
@@ -303,53 +362,17 @@
mgw_info.codecs[0] = CODEC_IUFP;
mgw_info.codecs_len = 1;
- ies = &mgw_fsm_priv->ranap_rab_ass_resp_message->msg.raB_AssignmentResponseIEs;
- rc = ranap_rab_ass_resp_ies_extract_inet_addr(&addr, ies, mgw_fsm_priv->rab_id);
- if (rc < 0) {
- rab_failed_at_hnb = ranap_rab_ass_resp_ies_check_failure(ies, mgw_fsm_priv->rab_id);
- if (rab_failed_at_hnb) {
- struct msgb *msg;
-
- LOGPFSML(fi, LOGL_ERROR,
- "The RAB-AssignmentResponse contains a RAB-FailedList, RAB-Assignment (%u) failed.\n",
- mgw_fsm_priv->rab_id);
-
- /* Forward the RAB-AssignmentResponse transparently. This will ensure that the MSC is informed
- * about the problem. */
- LOGPFSML(fi, LOGL_DEBUG, "forwarding unmodified RAB-AssignmentResponse to MSC\n");
-
- msg = mgw_fsm_priv->ranap_rab_ass_resp_msgb;
- mgw_fsm_priv->ranap_rab_ass_resp_msgb = NULL;
- talloc_steal(OTC_SELECT, msg);
-
- rc = map_sccp_dispatch(map, MAP_SCCP_EV_TX_DATA_REQUEST, msg);
- if (rc < 0) {
- LOGPFSML(fi, LOGL_DEBUG, "failed to forward RAB-AssignmentResponse message\n");
- osmo_fsm_inst_state_chg(fi, MGW_ST_FAILURE, 0, 0);
- }
-
- /* Even though this is a failure situation, we still release normally as the error is located
- * at the HNB. */
- osmo_fsm_inst_state_chg(fi, MGW_ST_RELEASE, 0, 0);
- return;
- }
-
- /* The RAB-ID we are dealing with is not on an FailedList and we were unable to parse the response
- * normally. This is a situation we cannot recover from. */
- LOGPFSML(fi, LOGL_ERROR, "Failed to extract RTP IP-address and Port from RAB-AssignmentResponse\n");
- osmo_fsm_inst_state_chg(fi, MGW_ST_FAILURE, 0, 0);
- return;
- }
-
- rc = osmo_sockaddr_str_from_sockaddr(&addr_str, &addr.u.sas);
+ rc = osmo_sockaddr_str_from_sockaddr(&addr_str, &mgw_fsm_priv->hnb_rtp_addr.u.sas);
if (rc < 0) {
LOGPFSML(fi, LOGL_ERROR, "Invalid RTP IP-address or Port in RAB-AssignmentResponse\n");
osmo_fsm_inst_state_chg(fi, MGW_ST_FAILURE, 0, 0);
return;
}
+
osmo_strlcpy(mgw_info.addr, addr_str.ip, sizeof(mgw_info.addr));
mgw_info.port = addr_str.port;
+ mgw_fsm_priv->mdcx_tx_cnt++;
osmo_mgcpc_ep_ci_request(mgw_fsm_priv->mgcpc_ep_ci_hnb, MGCP_VERB_MDCX, &mgw_info, fi, MGW_EV_MGCP_OK,
MGW_EV_MGCP_FAIL, NULL);
}
@@ -387,13 +410,14 @@
}
if (osmo_sockaddr_cmp(&mgw_fsm_priv->ci_hnb_crcx_ack_addr, &addr) != 0) {
- /* FIXME: Send RAB Modify Req to HNB. See OS#6127 */
char addr_buf[INET6_ADDRSTRLEN + 8];
LOGPFSML(fi, LOGL_ERROR, "Local MGW IuUP IP address %s changed to %s during MDCX."
- " This is so far unsupported, adapt your osmo-mgw config!\n",
+ " Modifying RAB on HNB.\n",
osmo_sockaddr_to_str(&mgw_fsm_priv->ci_hnb_crcx_ack_addr),
osmo_sockaddr_to_str_buf(addr_buf, sizeof(addr_buf), &addr));
- osmo_fsm_inst_state_chg(fi, MGW_ST_FAILURE, 0, 0);
+ /* Modify RAB on the HNB with the new local IuUP address (OS#6127): */
+ mgw_fsm_priv->ci_hnb_crcx_ack_addr = addr;
+ mgw_fsm_state_chg(fi, MGW_ST_ASSIGN);
return;
}
@@ -619,6 +643,7 @@
.in_event_mask = S(MGW_EV_RAB_ASS_RESP),
.out_state_mask =
S(MGW_ST_MDCX_HNB) |
+ S(MGW_ST_CRCX_MSC) |
S(MGW_ST_FAILURE) |
S(MGW_ST_RELEASE),
},
@@ -629,6 +654,7 @@
.in_event_mask =
S(MGW_EV_MGCP_OK),
.out_state_mask =
+ S(MGW_ST_ASSIGN) |
S(MGW_ST_CRCX_MSC) |
S(MGW_ST_FAILURE) |
S(MGW_ST_RELEASE),
--
To view, visit https://gerrit.osmocom.org/c/osmo-hnbgw/+/35168?usp=email
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings
Gerrit-Project: osmo-hnbgw
Gerrit-Branch: master
Gerrit-Change-Id: I936a50fed38a201c4a8da99b40f07082049e5157
Gerrit-Change-Number: 35168
Gerrit-PatchSet: 1
Gerrit-Owner: pespin <pespin(a)sysmocom.de>
Gerrit-MessageType: newchange
Attention is currently required from: arehbein.
Hello Jenkins Builder, arehbein,
I'd like you to reexamine a change. Please visit
https://gerrit.osmocom.org/c/libosmocore/+/35079?usp=email
to look at the new patch set (#4).
Change subject: osmo_io: Remove union in struct osmo_io_ops
......................................................................
osmo_io: Remove union in struct osmo_io_ops
This allows us to check that the correct callbacks are set. The checks
are already in e.g. osmo_iofd_write_msgb(), but the union prevented us
from distinguishing between write_cb() and sendto_cb() etc.
Change-Id: I138d57843edc29000530bb7896bcb239002ecbec
Related: #OS6263
---
M TODO-RELEASE
M include/osmocom/core/osmo_io.h
M src/core/osmo_io.c
3 files changed, 49 insertions(+), 32 deletions(-)
git pull ssh://gerrit.osmocom.org:29418/libosmocore refs/changes/79/35079/4
--
To view, visit https://gerrit.osmocom.org/c/libosmocore/+/35079?usp=email
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings
Gerrit-Project: libosmocore
Gerrit-Branch: master
Gerrit-Change-Id: I138d57843edc29000530bb7896bcb239002ecbec
Gerrit-Change-Number: 35079
Gerrit-PatchSet: 4
Gerrit-Owner: daniel <dwillmann(a)sysmocom.de>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: arehbein <arehbein(a)sysmocom.de>
Gerrit-Attention: arehbein <arehbein(a)sysmocom.de>
Gerrit-MessageType: newpatchset
Attention is currently required from: arehbein.
daniel has posted comments on this change. ( https://gerrit.osmocom.org/c/libosmocore/+/35079?usp=email )
Change subject: osmo_io: Remove union in struct osmo_io_ops
......................................................................
Patch Set 3:
(1 comment)
File src/core/osmo_io.c:
https://gerrit.osmocom.org/c/libosmocore/+/35079/comment/b7664ff5_c2daa8a4
PS3, Line 546: if (iofd->io_ops.read_cb)
The fact that this happened to work is even more reason to remove the union.
--
To view, visit https://gerrit.osmocom.org/c/libosmocore/+/35079?usp=email
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings
Gerrit-Project: libosmocore
Gerrit-Branch: master
Gerrit-Change-Id: I138d57843edc29000530bb7896bcb239002ecbec
Gerrit-Change-Number: 35079
Gerrit-PatchSet: 3
Gerrit-Owner: daniel <dwillmann(a)sysmocom.de>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: arehbein <arehbein(a)sysmocom.de>
Gerrit-Attention: arehbein <arehbein(a)sysmocom.de>
Gerrit-Comment-Date: Wed, 29 Nov 2023 17:59:49 +0000
Gerrit-HasComments: Yes
Gerrit-Has-Labels: No
Gerrit-MessageType: comment
Attention is currently required from: arehbein, daniel.
Jenkins Builder has posted comments on this change. ( https://gerrit.osmocom.org/c/libosmocore/+/35079?usp=email )
Change subject: osmo_io: Remove union in struct osmo_io_ops
......................................................................
Patch Set 3:
(1 comment)
File src/core/osmo_io.c:
Robot Comment from checkpatch (run ID jenkins-gerrit-lint-12714):
https://gerrit.osmocom.org/c/libosmocore/+/35079/comment/ebf6c5e6_a0b1fc97
PS3, Line 388: static bool iofd_read_callback_set(struct osmo_io_fd* iofd)
"foo* bar" should be "foo *bar"
--
To view, visit https://gerrit.osmocom.org/c/libosmocore/+/35079?usp=email
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings
Gerrit-Project: libosmocore
Gerrit-Branch: master
Gerrit-Change-Id: I138d57843edc29000530bb7896bcb239002ecbec
Gerrit-Change-Number: 35079
Gerrit-PatchSet: 3
Gerrit-Owner: daniel <dwillmann(a)sysmocom.de>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: arehbein <arehbein(a)sysmocom.de>
Gerrit-Attention: arehbein <arehbein(a)sysmocom.de>
Gerrit-Attention: daniel <dwillmann(a)sysmocom.de>
Gerrit-Comment-Date: Wed, 29 Nov 2023 17:59:08 +0000
Gerrit-HasComments: Yes
Gerrit-Has-Labels: No
Gerrit-MessageType: comment
Attention is currently required from: arehbein, daniel.
Hello Jenkins Builder, arehbein,
I'd like you to reexamine a change. Please visit
https://gerrit.osmocom.org/c/libosmocore/+/35079?usp=email
to look at the new patch set (#3).
The following approvals got outdated and were removed:
Verified-1 by Jenkins Builder
Change subject: osmo_io: Remove union in struct osmo_io_ops
......................................................................
osmo_io: Remove union in struct osmo_io_ops
This allows us to check that the correct callbacks are set. The checks
are already in e.g. osmo_iofd_write_msgb(), but the union prevented us
from distinguishing between write_cb() and sendto_cb() etc.
Change-Id: I138d57843edc29000530bb7896bcb239002ecbec
Related: #OS6263
---
M TODO-RELEASE
M include/osmocom/core/osmo_io.h
M src/core/osmo_io.c
3 files changed, 49 insertions(+), 32 deletions(-)
git pull ssh://gerrit.osmocom.org:29418/libosmocore refs/changes/79/35079/3
--
To view, visit https://gerrit.osmocom.org/c/libosmocore/+/35079?usp=email
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings
Gerrit-Project: libosmocore
Gerrit-Branch: master
Gerrit-Change-Id: I138d57843edc29000530bb7896bcb239002ecbec
Gerrit-Change-Number: 35079
Gerrit-PatchSet: 3
Gerrit-Owner: daniel <dwillmann(a)sysmocom.de>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: arehbein <arehbein(a)sysmocom.de>
Gerrit-Attention: arehbein <arehbein(a)sysmocom.de>
Gerrit-Attention: daniel <dwillmann(a)sysmocom.de>
Gerrit-MessageType: newpatchset
Attention is currently required from: daniel, fixeria, jolly.
pespin has posted comments on this change. ( https://gerrit.osmocom.org/c/libosmocore/+/35163?usp=email )
Change subject: utils: Link with libosmoisdn to avoid undefined references
......................................................................
Patch Set 1: Code-Review+1
--
To view, visit https://gerrit.osmocom.org/c/libosmocore/+/35163?usp=email
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings
Gerrit-Project: libosmocore
Gerrit-Branch: master
Gerrit-Change-Id: I9e99231899b269a4ec0faf720aff4dc8d2b74323
Gerrit-Change-Number: 35163
Gerrit-PatchSet: 1
Gerrit-Owner: daniel <dwillmann(a)sysmocom.de>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: fixeria <axilirator(a)gmail.com>
Gerrit-Reviewer: jolly <andreas(a)eversberg.eu>
Gerrit-Reviewer: pespin <pespin(a)sysmocom.de>
Gerrit-Attention: jolly <andreas(a)eversberg.eu>
Gerrit-Attention: daniel <dwillmann(a)sysmocom.de>
Gerrit-Attention: fixeria <axilirator(a)gmail.com>
Gerrit-Comment-Date: Wed, 29 Nov 2023 17:31:22 +0000
Gerrit-HasComments: No
Gerrit-Has-Labels: Yes
Gerrit-MessageType: comment
daniel has submitted this change. ( https://gerrit.osmocom.org/c/osmo-ggsn/+/35162?usp=email )
Change subject: libgtp: Remove defines for reserved causes in gtp.h
......................................................................
libgtp: Remove defines for reserved causes in gtp.h
As discussed in Gerrit change I9c3bf64537ef2223e29f8082861fa32fde26bf68
remove defines that don't serve any purpose. These are defines for
reserved values and changing them later if a newer spec defined them
would break API.
Keep the comments to explain the missing values.
Change-Id: I8db0aa0ade59785443a407b51dea326144406dcf
---
M TODO-RELEASE
M gtp/gtp.h
2 files changed, 26 insertions(+), 9 deletions(-)
Approvals:
daniel: Looks good to me, approved
pespin: Looks good to me, but someone else must approve
Jenkins Builder: Verified
osmith: Looks good to me, but someone else must approve
diff --git a/TODO-RELEASE b/TODO-RELEASE
index d0852fc..d8cc3af 100644
--- a/TODO-RELEASE
+++ b/TODO-RELEASE
@@ -7,3 +7,4 @@
# If any interfaces have been added since the last public release: c:r:a + 1.
# If any interfaces have been removed or changed since the last public release: c:r:0.
#library what description / commit summary line
+libgtp REMOVE remove GTP cause defines of reserved values
diff --git a/gtp/gtp.h b/gtp/gtp.h
index c066fa6..7465cf1 100644
--- a/gtp/gtp.h
+++ b/gtp/gtp.h
@@ -53,7 +53,7 @@
#define GTP_UPDATE_PDP_RSP 19 /* Update PDP Context Response */
#define GTP_DELETE_PDP_REQ 20 /* Delete PDP Context Request */
#define GTP_DELETE_PDP_RSP 21 /* Delete PDP Context Response */
- /* 22-25 For future use. *//* In version GTP 1 anonomous PDP context */
+/* 22-25 For future use. *//* In version GTP 1 anonomous PDP context */
#define GTP_ERROR 26 /* Error Indication */
#define GTP_PDU_NOT_REQ 27 /* PDU Notification Request */
#define GTP_PDU_NOT_RSP 28 /* PDU Notification Response */
@@ -99,21 +99,21 @@
#define GTPCAUSE_NO_ID_NEEDED 3 /* No identity needed */
#define GTPCAUSE_MS_REFUSES_X 4 /* MS refuses */
#define GTPCAUSE_MS_NOT_RESP_X 5 /* MS is not GPRS responding */
-#define GTPCAUSE_006 6 /* For future use 6-48 */
-#define GTPCAUSE_049 49 /* Cause values reserved for GPRS charging protocol use (See GTP' in GSM 12.15) 49-63 */
-#define GTPCAUSE_064 64 /* For future use 64-127 */
+/* 6-48 For future use */
+/* 49-63 Cause values reserved for GPRS charging protocol use (See GTP' in GSM 12.15) */
+/* 64-127 For future use */
#define GTPCAUSE_ACC_REQ 128 /* Request accepted */
#define GTPCAUSE_NEW_PDP_NET_PREF 129 /* New PDP type due to network preference */
#define GTPCAUSE_NEW_PDP_ADDR_BEAR 130 /* New PDP type due to single address bearer only */
-#define GTPCAUSE_131 131 /* For future use 131-176 */
-#define GTPCAUSE_177 177 /* Cause values reserved for GPRS charging protocol use (See GTP' In GSM 12.15) 177-191 */
+/* 131-176 For future use */
+/* 177-191 Cause values reserved for GPRS charging protocol use (See GTP' In GSM 12.15) */
#define GTPCAUSE_NON_EXIST 192 /* Non-existent */
#define GTPCAUSE_INVALID_MESSAGE 193 /* Invalid message format */
#define GTPCAUSE_IMSI_NOT_KNOWN 194 /* IMSI not known */
#define GTPCAUSE_MS_DETACHED 195 /* MS is GPRS detached */
#define GTPCAUSE_MS_NOT_RESP 196 /* MS is not GPRS responding */
#define GTPCAUSE_MS_REFUSES 197 /* MS refuses */
-#define GTPCAUSE_198 198 /* For future use */
+/* 198 For future use */
#define GTPCAUSE_NO_RESOURCES 199 /* No resources available */
#define GTPCAUSE_NOT_SUPPORTED 200 /* Service not supported */
#define GTPCAUSE_MAN_IE_INCORRECT 201 /* Mandatory IE incorrect */
@@ -136,8 +136,8 @@
#define GTPCAUSE_SYN_ERR_FILTER 218 /* Syntactic errors in packet filter(s) */
#define GTPCAUSE_MISSING_APN 219 /* Missing or unknown APN */
#define GTPCAUSE_UNKNOWN_PDP 220 /* Unknown PDP address or PDP type */
-#define GTPCAUSE_221 221 /* For Future Use 221-240 */
-#define GTPCAUSE_241 241 /* Cause Values Reserved For Gprs Charging Protocol Use (See Gtp' In Gsm 12.15) 241-255 */
+/* 221-240 For future use */
+/* 241-255 Cause Values Reserved For Gprs Charging Protocol Use (See Gtp' In Gsm 12.15) */
static inline bool gtp_cause_successful(uint8_t cause)
{
--
To view, visit https://gerrit.osmocom.org/c/osmo-ggsn/+/35162?usp=email
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings
Gerrit-Project: osmo-ggsn
Gerrit-Branch: master
Gerrit-Change-Id: I8db0aa0ade59785443a407b51dea326144406dcf
Gerrit-Change-Number: 35162
Gerrit-PatchSet: 1
Gerrit-Owner: daniel <dwillmann(a)sysmocom.de>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: daniel <dwillmann(a)sysmocom.de>
Gerrit-Reviewer: osmith <osmith(a)sysmocom.de>
Gerrit-Reviewer: pespin <pespin(a)sysmocom.de>
Gerrit-MessageType: merged
daniel has posted comments on this change. ( https://gerrit.osmocom.org/c/osmo-ggsn/+/35162?usp=email )
Change subject: libgtp: Remove defines for reserved causes in gtp.h
......................................................................
Patch Set 1: Code-Review+2
--
To view, visit https://gerrit.osmocom.org/c/osmo-ggsn/+/35162?usp=email
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings
Gerrit-Project: osmo-ggsn
Gerrit-Branch: master
Gerrit-Change-Id: I8db0aa0ade59785443a407b51dea326144406dcf
Gerrit-Change-Number: 35162
Gerrit-PatchSet: 1
Gerrit-Owner: daniel <dwillmann(a)sysmocom.de>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: daniel <dwillmann(a)sysmocom.de>
Gerrit-Reviewer: osmith <osmith(a)sysmocom.de>
Gerrit-Reviewer: pespin <pespin(a)sysmocom.de>
Gerrit-Comment-Date: Wed, 29 Nov 2023 17:18:01 +0000
Gerrit-HasComments: No
Gerrit-Has-Labels: Yes
Gerrit-MessageType: comment
Attention is currently required from: arehbein.
daniel has posted comments on this change. ( https://gerrit.osmocom.org/c/libosmocore/+/35079?usp=email )
Change subject: osmo_io: Remove union in struct osmo_io_ops
......................................................................
Set Ready For Review
--
To view, visit https://gerrit.osmocom.org/c/libosmocore/+/35079?usp=email
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings
Gerrit-Project: libosmocore
Gerrit-Branch: master
Gerrit-Change-Id: I138d57843edc29000530bb7896bcb239002ecbec
Gerrit-Change-Number: 35079
Gerrit-PatchSet: 2
Gerrit-Owner: daniel <dwillmann(a)sysmocom.de>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: arehbein <arehbein(a)sysmocom.de>
Gerrit-Attention: arehbein <arehbein(a)sysmocom.de>
Gerrit-Comment-Date: Wed, 29 Nov 2023 17:16:23 +0000
Gerrit-HasComments: No
Gerrit-Has-Labels: No
Gerrit-MessageType: comment
Attention is currently required from: laforge, lynxis lazus, pespin.
daniel has posted comments on this change. ( https://gerrit.osmocom.org/c/libosmocore/+/35078?usp=email )
Change subject: osmo_io: Factor out and use common send function from backend
......................................................................
Patch Set 2:
(5 comments)
File src/core/osmo_io.c:
https://gerrit.osmocom.org/c/libosmocore/+/35078/comment/c63c3397_1e3aa3a8
PS1, Line 343: void iofd_handle_send(struct osmo_io_fd *iofd, int rc, struct iofd_msghdr *msghdr)
> this function (like unfortuntaely many functions in the code base) would benefit from a comment desc […]
Done
https://gerrit.osmocom.org/c/libosmocore/+/35078/comment/dde3791b_d6c6a0ea
PS1, Line 343: void iofd_handle_send(struct osmo_io_fd *iofd, int rc, struct iofd_msghdr *msghdr)
> this function (like unfortuntaely many functions in the code base) would benefit from a comment desc […]
Done
https://gerrit.osmocom.org/c/libosmocore/+/35078/comment/8d2930d4_ca0fc16d
PS1, Line 348: if (rc > 0 && rc < msgb_length(msg)) {
Regarding your comment about rc == 0, maybe one missing failure case is rc == 0 && rc < msgb_length(msg)?
Not sure though.
https://gerrit.osmocom.org/c/libosmocore/+/35078/comment/57942bf2_352fb2a8
PS1, Line 360:
> rc == 0 case seems to be missing here?
IMO rc == 0 in send means we have successfully "written" 0 bytes to the socket (which also means the socket is writable).
This is (IMO correctly) handled in the success case below.
The failure cases should either be rc < msgb_length() or rc == -EAGAIN.
File src/core/osmo_io_uring.c:
https://gerrit.osmocom.org/c/libosmocore/+/35078/comment/93398c92_a3e6f35c
PS1, Line 188: iofd_msghdr_free(msghdr);
> Yes, previous you didn't checked for -EAGAIN, now you're checking it and doing things based on it.
You marked this as resolved, but just to be clear: I think this behavior is okay. It's debatable whether we'd ever encounter -EAGAIN for a send in io_uring, but if we do I'd say reenqueueing is the correct behavior.
--
To view, visit https://gerrit.osmocom.org/c/libosmocore/+/35078?usp=email
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings
Gerrit-Project: libosmocore
Gerrit-Branch: master
Gerrit-Change-Id: I6da2653d32aedd0e7872be0cf90a841b56462e59
Gerrit-Change-Number: 35078
Gerrit-PatchSet: 2
Gerrit-Owner: daniel <dwillmann(a)sysmocom.de>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: lynxis lazus <lynxis(a)fe80.eu>
Gerrit-CC: laforge <laforge(a)osmocom.org>
Gerrit-CC: pespin <pespin(a)sysmocom.de>
Gerrit-Attention: laforge <laforge(a)osmocom.org>
Gerrit-Attention: pespin <pespin(a)sysmocom.de>
Gerrit-Attention: lynxis lazus <lynxis(a)fe80.eu>
Gerrit-Comment-Date: Wed, 29 Nov 2023 17:04:12 +0000
Gerrit-HasComments: Yes
Gerrit-Has-Labels: No
Comment-In-Reply-To: laforge <laforge(a)osmocom.org>
Comment-In-Reply-To: pespin <pespin(a)sysmocom.de>
Comment-In-Reply-To: daniel <dwillmann(a)sysmocom.de>
Comment-In-Reply-To: lynxis lazus <lynxis(a)fe80.eu>
Gerrit-MessageType: comment
Attention is currently required from: laforge, lynxis lazus, pespin.
Hello Jenkins Builder, lynxis lazus,
I'd like you to reexamine a change. Please visit
https://gerrit.osmocom.org/c/libosmocore/+/35078?usp=email
to look at the new patch set (#2).
The following approvals got outdated and were removed:
Code-Review+1 by lynxis lazus, Verified-1 by Jenkins Builder
Change subject: osmo_io: Factor out and use common send function from backend
......................................................................
osmo_io: Factor out and use common send function from backend
This handles reenqueuing a message on EAGAIN and incomplete write
Change-Id: I6da2653d32aedd0e7872be0cf90a841b56462e59
---
M src/core/osmo_io.c
M src/core/osmo_io_internal.h
M src/core/osmo_io_poll.c
M src/core/osmo_io_uring.c
4 files changed, 57 insertions(+), 57 deletions(-)
git pull ssh://gerrit.osmocom.org:29418/libosmocore refs/changes/78/35078/2
--
To view, visit https://gerrit.osmocom.org/c/libosmocore/+/35078?usp=email
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings
Gerrit-Project: libosmocore
Gerrit-Branch: master
Gerrit-Change-Id: I6da2653d32aedd0e7872be0cf90a841b56462e59
Gerrit-Change-Number: 35078
Gerrit-PatchSet: 2
Gerrit-Owner: daniel <dwillmann(a)sysmocom.de>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: lynxis lazus <lynxis(a)fe80.eu>
Gerrit-CC: laforge <laforge(a)osmocom.org>
Gerrit-CC: pespin <pespin(a)sysmocom.de>
Gerrit-Attention: laforge <laforge(a)osmocom.org>
Gerrit-Attention: pespin <pespin(a)sysmocom.de>
Gerrit-Attention: lynxis lazus <lynxis(a)fe80.eu>
Gerrit-MessageType: newpatchset
Attention is currently required from: dexter, fixeria.
pespin has posted comments on this change. ( https://gerrit.osmocom.org/c/osmo-pcu/+/35151?usp=email )
Change subject: gprs_rlcmac_sched: rewrite logic around idle block skip
......................................................................
Patch Set 2:
(1 comment)
File src/gprs_rlcmac_sched.cpp:
https://gerrit.osmocom.org/c/osmo-pcu/+/35151/comment/47256c5d_e54ac3a3
PS1, Line 486: * way we help BTS energy saving (on TRX!=C0) by sending nothing
> Was this ever tested?
Not myself, but I'd expect them to transmit nothing or whatever? maybe @laforge@osmocom.org can say from the top of his head since he knows better that l1 part.
It makes sense that it sends nothing, and hence why we have to force it to transmit a dummy rlcmac block on trx0.
--
To view, visit https://gerrit.osmocom.org/c/osmo-pcu/+/35151?usp=email
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings
Gerrit-Project: osmo-pcu
Gerrit-Branch: master
Gerrit-Change-Id: Iadb62748b18605bf158169b317f880352bc0a5a6
Gerrit-Change-Number: 35151
Gerrit-PatchSet: 2
Gerrit-Owner: dexter <pmaier(a)sysmocom.de>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: fixeria <vyanitskiy(a)sysmocom.de>
Gerrit-Reviewer: laforge <laforge(a)osmocom.org>
Gerrit-Reviewer: pespin <pespin(a)sysmocom.de>
Gerrit-Attention: fixeria <vyanitskiy(a)sysmocom.de>
Gerrit-Attention: dexter <pmaier(a)sysmocom.de>
Gerrit-Comment-Date: Wed, 29 Nov 2023 16:37:20 +0000
Gerrit-HasComments: Yes
Gerrit-Has-Labels: No
Comment-In-Reply-To: fixeria <vyanitskiy(a)sysmocom.de>
Comment-In-Reply-To: pespin <pespin(a)sysmocom.de>
Comment-In-Reply-To: dexter <pmaier(a)sysmocom.de>
Gerrit-MessageType: comment
Attention is currently required from: dexter, pespin.
fixeria has posted comments on this change. ( https://gerrit.osmocom.org/c/osmo-pcu/+/35151?usp=email )
Change subject: gprs_rlcmac_sched: rewrite logic around idle block skip
......................................................................
Patch Set 2:
(1 comment)
File src/gprs_rlcmac_sched.cpp:
https://gerrit.osmocom.org/c/osmo-pcu/+/35151/comment/01b4c1fc_4c03fc14
PS1, Line 486: * way we help BTS energy saving (on TRX!=C0) by sending nothing
> @fixeria bear in mind the "skip_idle && trx != 0" was only applied inside the #ifdef DIRECT_PHY [...]
It's getting more and more complicated, but it seems I have a more complete picture in my mind. The `#ifdef DIRECT_PHY` block was removed in a recent patch (I7a08d8cc670fa14f7206ffffdbc22351f3668a17), and now this patch removes the `trx != 0` constraint.
> And that was done in order to make it send stuff on C0 because those osmo-bts lowerlayers are not filling the block otherwise.
Ack. The `trx != 0` constraint was specifically needed for those DSP based models.
> I realize now though, that when proposing the cleanup in this patch, I assumed those were 1 TRX only, but lc15 has several of them right?
I am not familiar with the lc15 PHY, but AFAIR there also was a sysmoBTS model with two TRX. Also, I don't know how those DSP based models behave when getting an empty DATA.req for `trx!=0`. Was this ever tested?
--
To view, visit https://gerrit.osmocom.org/c/osmo-pcu/+/35151?usp=email
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings
Gerrit-Project: osmo-pcu
Gerrit-Branch: master
Gerrit-Change-Id: Iadb62748b18605bf158169b317f880352bc0a5a6
Gerrit-Change-Number: 35151
Gerrit-PatchSet: 2
Gerrit-Owner: dexter <pmaier(a)sysmocom.de>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: fixeria <vyanitskiy(a)sysmocom.de>
Gerrit-Reviewer: laforge <laforge(a)osmocom.org>
Gerrit-Reviewer: pespin <pespin(a)sysmocom.de>
Gerrit-Attention: pespin <pespin(a)sysmocom.de>
Gerrit-Attention: dexter <pmaier(a)sysmocom.de>
Gerrit-Comment-Date: Wed, 29 Nov 2023 16:26:25 +0000
Gerrit-HasComments: Yes
Gerrit-Has-Labels: No
Comment-In-Reply-To: pespin <pespin(a)sysmocom.de>
Comment-In-Reply-To: fixeria <vyanitskiy(a)sysmocom.de>
Comment-In-Reply-To: dexter <pmaier(a)sysmocom.de>
Gerrit-MessageType: comment
fixeria has posted comments on this change. ( https://gerrit.osmocom.org/c/docker-playground/+/35159?usp=email )
Change subject: ttcn3-pcu-test/sns: fix PCUIF version number (follow up patch)
......................................................................
Patch Set 1:
(1 comment)
Patchset:
PS1:
> Let's address this is in a follow up patch. This patch makes jenkins-sns.sh, equal to jenkins.sh. […]
Suggestion: maybe we could agree on always having the latest PCUIF version configured in `osmo-ttcn3-hacks.git` (we already do in `PCU_Tests.default`) and overwrite it here in `docker-playground.git` only if needed (e.g. for latest or `202[0-9]q[0-9]` branches).
This way patching the config file would be as easy as doing `echo "PCUIF_Types.mp_pcuif_version := 12" >> $1`.
--
To view, visit https://gerrit.osmocom.org/c/docker-playground/+/35159?usp=email
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings
Gerrit-Project: docker-playground
Gerrit-Branch: master
Gerrit-Change-Id: I1f94a0459e35d7b5632c81d7f7e2e60eb0d0229f
Gerrit-Change-Number: 35159
Gerrit-PatchSet: 1
Gerrit-Owner: dexter <pmaier(a)sysmocom.de>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: fixeria <vyanitskiy(a)sysmocom.de>
Gerrit-Reviewer: laforge <laforge(a)osmocom.org>
Gerrit-Reviewer: pespin <pespin(a)sysmocom.de>
Gerrit-Comment-Date: Wed, 29 Nov 2023 16:02:50 +0000
Gerrit-HasComments: Yes
Gerrit-Has-Labels: No
Comment-In-Reply-To: pespin <pespin(a)sysmocom.de>
Comment-In-Reply-To: dexter <pmaier(a)sysmocom.de>
Gerrit-MessageType: comment
Attention is currently required from: pespin.
osmith has posted comments on this change. ( https://gerrit.osmocom.org/c/osmo-gsm-tester/+/35157?usp=email )
Change subject: Update git URLs
......................................................................
Patch Set 2:
(2 comments)
Commit Message:
https://gerrit.osmocom.org/c/osmo-gsm-tester/+/35157/comment/9ecedff9_d5b73…
PS2, Line 9: git.osmocom.org has been deprecated
> Huh? I thought it's only the `git://` protocol has been deprecated and was disabled yesterday. […]
right, `git clone https://git.osmocom.org/libosmocore` still works... agreed that the commit message could be better, but the change still makes sense given that gerrit.osmocom.org is more recent. I should have written: git://git.osmocom.org is deprecated. Sorry, had merged it already just before your comment arrived.
I guess it failed in jenkins because the workspaces weren't cleaned when git:// was changed to https:// in I5f51b260445624759e77a70c5065838b29ec8c01. I have cleaned them as I tested the patch here.
File contrib/jenkins-build-osmo-bts.sh:
https://gerrit.osmocom.org/c/osmo-gsm-tester/+/35157/comment/c86e1de5_403b2…
PS1, Line 7: (git_url=https://gitea.osmocom.org/cellular-infrastructure
> It needs to be this url for octphy-2g-headers only (not on gerrit), everything else should be retrie […]
Done
--
To view, visit https://gerrit.osmocom.org/c/osmo-gsm-tester/+/35157?usp=email
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings
Gerrit-Project: osmo-gsm-tester
Gerrit-Branch: master
Gerrit-Change-Id: I03a06d23e87a75257eb731a97facd7a67c40a2c6
Gerrit-Change-Number: 35157
Gerrit-PatchSet: 2
Gerrit-Owner: osmith <osmith(a)sysmocom.de>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: fixeria <vyanitskiy(a)sysmocom.de>
Gerrit-Reviewer: laforge <laforge(a)osmocom.org>
Gerrit-Reviewer: osmith <osmith(a)sysmocom.de>
Gerrit-Reviewer: pespin <pespin(a)sysmocom.de>
Gerrit-Attention: pespin <pespin(a)sysmocom.de>
Gerrit-Comment-Date: Wed, 29 Nov 2023 15:55:17 +0000
Gerrit-HasComments: Yes
Gerrit-Has-Labels: No
Comment-In-Reply-To: osmith <osmith(a)sysmocom.de>
Comment-In-Reply-To: fixeria <vyanitskiy(a)sysmocom.de>
Comment-In-Reply-To: pespin <pespin(a)sysmocom.de>
Gerrit-MessageType: comment
Attention is currently required from: pespin.
fixeria has posted comments on this change. ( https://gerrit.osmocom.org/c/osmo-gsm-tester/+/35157?usp=email )
Change subject: Update git URLs
......................................................................
Patch Set 2:
(2 comments)
Commit Message:
https://gerrit.osmocom.org/c/osmo-gsm-tester/+/35157/comment/8913f5a1_96c58…
PS2, Line 9: git.osmocom.org has been deprecated
Huh? I thought it's only the `git://` protocol has been deprecated and was disabled yesterday. When doing `git clone https://git.osmocom.org/...`, you'll be redirected to Gitea anyway...
The sync delay (which may be different in different projects) is a more reasonable argument against using `https://git.osmocom.org`, IMO.
File contrib/jenkins-build-osmo-bts.sh:
https://gerrit.osmocom.org/c/osmo-gsm-tester/+/35157/comment/98f9a961_97627…
PS1, Line 7: (git_url=https://gitea.osmocom.org/cellular-infrastructure
> It needs to be this url for octphy-2g-headers only (not on gerrit), everything else should be retrie […]
Likewise, cloning from `https://git.osmocom.org/octphy-2g-headers` works fine, git client gets redirected to `https://gitea.osmocom.org/cellular-infrastructure/octphy-2g-headers/`.
--
To view, visit https://gerrit.osmocom.org/c/osmo-gsm-tester/+/35157?usp=email
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings
Gerrit-Project: osmo-gsm-tester
Gerrit-Branch: master
Gerrit-Change-Id: I03a06d23e87a75257eb731a97facd7a67c40a2c6
Gerrit-Change-Number: 35157
Gerrit-PatchSet: 2
Gerrit-Owner: osmith <osmith(a)sysmocom.de>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: fixeria <vyanitskiy(a)sysmocom.de>
Gerrit-Reviewer: laforge <laforge(a)osmocom.org>
Gerrit-Reviewer: osmith <osmith(a)sysmocom.de>
Gerrit-Reviewer: pespin <pespin(a)sysmocom.de>
Gerrit-Attention: pespin <pespin(a)sysmocom.de>
Gerrit-Comment-Date: Wed, 29 Nov 2023 15:50:09 +0000
Gerrit-HasComments: Yes
Gerrit-Has-Labels: No
Comment-In-Reply-To: osmith <osmith(a)sysmocom.de>
Comment-In-Reply-To: pespin <pespin(a)sysmocom.de>
Gerrit-MessageType: comment
Attention is currently required from: daniel.
osmith has posted comments on this change. ( https://gerrit.osmocom.org/c/osmo-ggsn/+/35162?usp=email )
Change subject: libgtp: Remove defines for reserved causes in gtp.h
......................................................................
Patch Set 1: Code-Review+1
--
To view, visit https://gerrit.osmocom.org/c/osmo-ggsn/+/35162?usp=email
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings
Gerrit-Project: osmo-ggsn
Gerrit-Branch: master
Gerrit-Change-Id: I8db0aa0ade59785443a407b51dea326144406dcf
Gerrit-Change-Number: 35162
Gerrit-PatchSet: 1
Gerrit-Owner: daniel <dwillmann(a)sysmocom.de>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: osmith <osmith(a)sysmocom.de>
Gerrit-Reviewer: pespin <pespin(a)sysmocom.de>
Gerrit-Attention: daniel <dwillmann(a)sysmocom.de>
Gerrit-Comment-Date: Wed, 29 Nov 2023 15:49:50 +0000
Gerrit-HasComments: No
Gerrit-Has-Labels: Yes
Gerrit-MessageType: comment
Attention is currently required from: daniel, osmith.
pespin has posted comments on this change. ( https://gerrit.osmocom.org/c/osmo-ggsn/+/35162?usp=email )
Change subject: libgtp: Remove defines for reserved causes in gtp.h
......................................................................
Patch Set 1: Code-Review+1
--
To view, visit https://gerrit.osmocom.org/c/osmo-ggsn/+/35162?usp=email
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings
Gerrit-Project: osmo-ggsn
Gerrit-Branch: master
Gerrit-Change-Id: I8db0aa0ade59785443a407b51dea326144406dcf
Gerrit-Change-Number: 35162
Gerrit-PatchSet: 1
Gerrit-Owner: daniel <dwillmann(a)sysmocom.de>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: osmith <osmith(a)sysmocom.de>
Gerrit-Reviewer: pespin <pespin(a)sysmocom.de>
Gerrit-Attention: osmith <osmith(a)sysmocom.de>
Gerrit-Attention: daniel <dwillmann(a)sysmocom.de>
Gerrit-Comment-Date: Wed, 29 Nov 2023 15:49:06 +0000
Gerrit-HasComments: No
Gerrit-Has-Labels: Yes
Gerrit-MessageType: comment
osmith has submitted this change. ( https://gerrit.osmocom.org/c/osmo-gsm-tester/+/35157?usp=email )
Change subject: Update git URLs
......................................................................
Update git URLs
git.osmocom.org has been deprecated, use gerrit or gitea urls instead.
Related: https://osmocom.org/projects/cellular-infrastructure/wiki/Git_infrastructure
Related: OS#6251
Change-Id: I03a06d23e87a75257eb731a97facd7a67c40a2c6
---
M README.md
M contrib/jenkins-build-common.sh
M contrib/jenkins-build-manuals.sh
M contrib/jenkins-build-osmo-bts.sh
M doc/manuals/chapters/ansible.adoc
M doc/manuals/chapters/docker.adoc
M doc/manuals/osmo-gsm-tester-manual-docinfo.xml
M src/osmo_gsm_tester/obj/osmo_vty.py
M sysmocom/ttcn3/README.txt
9 files changed, 32 insertions(+), 16 deletions(-)
Approvals:
laforge: Looks good to me, approved
pespin: Looks good to me, but someone else must approve
osmith: Verified
diff --git a/README.md b/README.md
index 3394969..9bc1dcf 100644
--- a/README.md
+++ b/README.md
@@ -16,11 +16,12 @@
Ansible scripts to set up hosts to be used as Osmo-GSM-Tester Main Units or/and
Slave Units on the above mentioned setup can be found at
-https://git.osmocom.org/osmo-ci/tree/ansible, which actually install sample
-system configuration files from _utils/_ directory in this same repository.
+https://gitea.osmocom.org/osmocom/osmo-ci/src/branch/master/ansible, which
+actually install sample system configuration files from _utils/_ directory in
+this same repository.
A sample Docker setup is also maintained publicly at
-https://git.osmocom.org/docker-playground/tree/osmo-gsm-tester.
+https://gitea.osmocom.org/osmocom/docker-playground/src/branch/master/osmo-gsm-tester.
For the complete documentation, please refer to Osmo-GSM-Tester User manual,
available in sources under _doc/manuals/_ under this same repository, and
diff --git a/contrib/jenkins-build-common.sh b/contrib/jenkins-build-common.sh
index b41fc05..59d0d11 100644
--- a/contrib/jenkins-build-common.sh
+++ b/contrib/jenkins-build-common.sh
@@ -42,7 +42,7 @@
exit 1
fi
-git_url="${git_url:-https://git.osmocom.org}"
+git_url="${git_url:-https://gerrit.osmocom.org}"
prefix="${prefix:-$base/inst-$name}"
# prefix_real is usually identical with prefix, except when installing to a
# different $DESTDIR than /, which is the case for example when building
diff --git a/contrib/jenkins-build-manuals.sh b/contrib/jenkins-build-manuals.sh
index 48f7780..cf2a4d8 100755
--- a/contrib/jenkins-build-manuals.sh
+++ b/contrib/jenkins-build-manuals.sh
@@ -15,7 +15,7 @@
if [ -d "$OSMO_GSM_MANUALS_DIR" ]; then
git -C "$OSMO_GSM_MANUALS_DIR" pull
else
- git clone "https://git.osmocom.org/osmo-gsm-manuals" "$OSMO_GSM_MANUALS_DIR"
+ git clone "https://gerrit.osmocom.org/osmo-gsm-manuals" "$OSMO_GSM_MANUALS_DIR"
fi
git -C "$OSMO_GSM_MANUALS_DIR" checkout -f HEAD
diff --git a/contrib/jenkins-build-osmo-bts.sh b/contrib/jenkins-build-osmo-bts.sh
index 6e9416a..d0b9e02 100755
--- a/contrib/jenkins-build-osmo-bts.sh
+++ b/contrib/jenkins-build-osmo-bts.sh
@@ -4,7 +4,8 @@
name="osmo-bts"
. "$(dirname "$0")/jenkins-build-common.sh"
-have_repo octphy-2g-headers
+(git_url=https://gitea.osmocom.org/cellular-infrastructure
+ have_repo octphy-2g-headers)
build_repo libosmocore ${SANITIZE_FLAGS} --disable-doxygen --disable-uring
build_repo libosmo-abis ${SANITIZE_FLAGS} --disable-dahdi
diff --git a/doc/manuals/chapters/ansible.adoc b/doc/manuals/chapters/ansible.adoc
index 4c80723..d8970aa 100644
--- a/doc/manuals/chapters/ansible.adoc
+++ b/doc/manuals/chapters/ansible.adoc
@@ -5,8 +5,8 @@
and tedious, nowadays the Osmocom RnD and Production {app-name} setups are
installed and maintained using Ansible scripts. The set of ansible scripts is
available in Osmocom's git repository
-link:https://git.osmocom.org/osmo-ci/[osmo-ci.git] under 'ansible' subdirectory,
-with the rest of ansible scripts to set jenkins slaves, etc.
+link:https://gitea.osmocom.org/osmocom/osmo-ci/[osmo-ci.git] under 'ansible'
+subdirectory, with the rest of ansible scripts to set jenkins slaves, etc.
Since these set of scripts is mainly aimed at Osmocom's own setup, and debian is
used there, so far only debian hosts are supported officially, though patches to
diff --git a/doc/manuals/chapters/docker.adoc b/doc/manuals/chapters/docker.adoc
index bc8ad00..985edc3 100644
--- a/doc/manuals/chapters/docker.adoc
+++ b/doc/manuals/chapters/docker.adoc
@@ -3,8 +3,8 @@
A sample {app-name} setup based on docker containers and maintained by the
Osmocom community is available in Osmocom's git repository
-link:https://git.osmocom.org/docker-playground/[docker-playground.git], under
-'osmo-gsm-tester' subdirectory. In there, one can find:
+link:https://gitea.osmocom.org/osmocom/docker-playground/[docker-playground.git],
+under 'osmo-gsm-tester' subdirectory. In there, one can find:
- A 'Dockerfile' file can be found which builds a docker image which can
be used both to run as an osmo-gsm-tester <<install_main_unit,Main Unit>> or as
diff --git a/doc/manuals/osmo-gsm-tester-manual-docinfo.xml b/doc/manuals/osmo-gsm-tester-manual-docinfo.xml
index d7b112f..d59fc73 100644
--- a/doc/manuals/osmo-gsm-tester-manual-docinfo.xml
+++ b/doc/manuals/osmo-gsm-tester-manual-docinfo.xml
@@ -51,8 +51,8 @@
</para>
<para>
The Asciidoc source code of this manual can be found at
- <ulink url="http://git.osmocom.org/osmo-gsm-manuals/">
- http://git.osmocom.org/osmo-gsm-manuals/
+ <ulink url="https://gitea.osmocom.org/cellular-infrastructure/osmo-gsm-manuals">
+ https://gitea.osmocom.org/cellular-infrastructure/osmo-gsm-manuals
</ulink>
</para>
</legalnotice>
diff --git a/src/osmo_gsm_tester/obj/osmo_vty.py b/src/osmo_gsm_tester/obj/osmo_vty.py
index 1b414c9..80697c9 100644
--- a/src/osmo_gsm_tester/obj/osmo_vty.py
+++ b/src/osmo_gsm_tester/obj/osmo_vty.py
@@ -80,7 +80,7 @@
def _command(self, command_str, timeout=10, strict=True):
'''Send a command and return the response.'''
- # (copied from https://git.osmocom.org/python/osmo-python-tests/tree/osmopy/osmo_interact/…)
+ # (copied from osmo-python-tests.git/osmopy/osmo_interact/vty.py)
self.dbg('Sending', command_str=command_str)
self.sck.send(command_str.encode())
@@ -159,7 +159,7 @@
self.sck.setblocking(1)
# read first prompt
- # (copied from https://git.osmocom.org/python/osmo-python-tests/tree/osmopy/osmo_interact/…)
+ # (copied from osmo-python-tests.git/osmopy/osmo_interact/vty.py)
self.this_node = None
self.this_prompt_char = '>' # slight cheat for initial prompt char
self.last_node = None
@@ -209,7 +209,7 @@
with self:
return self.cmd(command_str, timeout, strict)
- # (copied from https://git.osmocom.org/python/osmo-python-tests/tree/osmopy/osmo_interact/…)
+ # (copied from osmo-python-tests.git/osmopy/osmo_interact/vty.py)
command_str = command_str or '\r'
if command_str[-1] not in '?\r\t':
command_str = command_str + '\r'
diff --git a/sysmocom/ttcn3/README.txt b/sysmocom/ttcn3/README.txt
index 3886c80..2e10105 100644
--- a/sysmocom/ttcn3/README.txt
+++ b/sysmocom/ttcn3/README.txt
@@ -1,5 +1,6 @@
This directory contains a set of scripts and osmo-gsm-tester testsuites to run
-osmo-ttcn3-hacks.git BTS_tests.ttcn (https://git.osmocom.org/osmo-ttcn3-hacks/tree/bts).
+osmo-ttcn3-hacks.git BTS_tests.ttcn
+(https://gitea.osmocom.org/ttcn3/osmo-ttcn3-hacks/src/branch/master/bts).
The idea is to set up automatically the following components:
TTCN3 <-> osmocon (osmocom-bb) <-> motorola C123 <-> RF network <-> BTS_TO_TEST <-> TTCN3 + osmo-bsc
--
To view, visit https://gerrit.osmocom.org/c/osmo-gsm-tester/+/35157?usp=email
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings
Gerrit-Project: osmo-gsm-tester
Gerrit-Branch: master
Gerrit-Change-Id: I03a06d23e87a75257eb731a97facd7a67c40a2c6
Gerrit-Change-Number: 35157
Gerrit-PatchSet: 2
Gerrit-Owner: osmith <osmith(a)sysmocom.de>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: fixeria <vyanitskiy(a)sysmocom.de>
Gerrit-Reviewer: laforge <laforge(a)osmocom.org>
Gerrit-Reviewer: osmith <osmith(a)sysmocom.de>
Gerrit-Reviewer: pespin <pespin(a)sysmocom.de>
Gerrit-MessageType: merged
daniel has posted comments on this change. ( https://gerrit.osmocom.org/c/osmo-ggsn/+/35084?usp=email )
Change subject: gtp: Add net GTP cause values and a function to check for success
......................................................................
Patch Set 2:
(1 comment)
File gtp/gtp.h:
https://gerrit.osmocom.org/c/osmo-ggsn/+/35084/comment/6c8690c8_c0d44bed
PS2, Line 106: #define GTPCAUSE_129 129 /* For future use 129-176 */
> Agree, please submit a patch dropping all of them.
See https://gerrit.osmocom.org/c/osmo-ggsn/+/35162
--
To view, visit https://gerrit.osmocom.org/c/osmo-ggsn/+/35084?usp=email
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings
Gerrit-Project: osmo-ggsn
Gerrit-Branch: master
Gerrit-Change-Id: I9c3bf64537ef2223e29f8082861fa32fde26bf68
Gerrit-Change-Number: 35084
Gerrit-PatchSet: 2
Gerrit-Owner: daniel <dwillmann(a)sysmocom.de>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: daniel <dwillmann(a)sysmocom.de>
Gerrit-Reviewer: laforge <laforge(a)osmocom.org>
Gerrit-Reviewer: lynxis lazus <lynxis(a)fe80.eu>
Gerrit-Reviewer: osmith <osmith(a)sysmocom.de>
Gerrit-CC: pespin <pespin(a)sysmocom.de>
Gerrit-Comment-Date: Wed, 29 Nov 2023 15:42:10 +0000
Gerrit-HasComments: Yes
Gerrit-Has-Labels: No
Comment-In-Reply-To: pespin <pespin(a)sysmocom.de>
Comment-In-Reply-To: daniel <dwillmann(a)sysmocom.de>
Gerrit-MessageType: comment
daniel has uploaded this change for review. ( https://gerrit.osmocom.org/c/osmo-ggsn/+/35162?usp=email )
Change subject: libgtp: Remove defines for reserved causes in gtp.h
......................................................................
libgtp: Remove defines for reserved causes in gtp.h
As discussed in Gerrit change I9c3bf64537ef2223e29f8082861fa32fde26bf68
remove defines that don't serve any purpose. These are defines for
reserved values and changing them later if a newer spec defined them
would break API.
Keep the comments to explain the missing values.
Change-Id: I8db0aa0ade59785443a407b51dea326144406dcf
---
M TODO-RELEASE
M gtp/gtp.h
2 files changed, 26 insertions(+), 9 deletions(-)
git pull ssh://gerrit.osmocom.org:29418/osmo-ggsn refs/changes/62/35162/1
diff --git a/TODO-RELEASE b/TODO-RELEASE
index d0852fc..d8cc3af 100644
--- a/TODO-RELEASE
+++ b/TODO-RELEASE
@@ -7,3 +7,4 @@
# If any interfaces have been added since the last public release: c:r:a + 1.
# If any interfaces have been removed or changed since the last public release: c:r:0.
#library what description / commit summary line
+libgtp REMOVE remove GTP cause defines of reserved values
diff --git a/gtp/gtp.h b/gtp/gtp.h
index c066fa6..7465cf1 100644
--- a/gtp/gtp.h
+++ b/gtp/gtp.h
@@ -53,7 +53,7 @@
#define GTP_UPDATE_PDP_RSP 19 /* Update PDP Context Response */
#define GTP_DELETE_PDP_REQ 20 /* Delete PDP Context Request */
#define GTP_DELETE_PDP_RSP 21 /* Delete PDP Context Response */
- /* 22-25 For future use. *//* In version GTP 1 anonomous PDP context */
+/* 22-25 For future use. *//* In version GTP 1 anonomous PDP context */
#define GTP_ERROR 26 /* Error Indication */
#define GTP_PDU_NOT_REQ 27 /* PDU Notification Request */
#define GTP_PDU_NOT_RSP 28 /* PDU Notification Response */
@@ -99,21 +99,21 @@
#define GTPCAUSE_NO_ID_NEEDED 3 /* No identity needed */
#define GTPCAUSE_MS_REFUSES_X 4 /* MS refuses */
#define GTPCAUSE_MS_NOT_RESP_X 5 /* MS is not GPRS responding */
-#define GTPCAUSE_006 6 /* For future use 6-48 */
-#define GTPCAUSE_049 49 /* Cause values reserved for GPRS charging protocol use (See GTP' in GSM 12.15) 49-63 */
-#define GTPCAUSE_064 64 /* For future use 64-127 */
+/* 6-48 For future use */
+/* 49-63 Cause values reserved for GPRS charging protocol use (See GTP' in GSM 12.15) */
+/* 64-127 For future use */
#define GTPCAUSE_ACC_REQ 128 /* Request accepted */
#define GTPCAUSE_NEW_PDP_NET_PREF 129 /* New PDP type due to network preference */
#define GTPCAUSE_NEW_PDP_ADDR_BEAR 130 /* New PDP type due to single address bearer only */
-#define GTPCAUSE_131 131 /* For future use 131-176 */
-#define GTPCAUSE_177 177 /* Cause values reserved for GPRS charging protocol use (See GTP' In GSM 12.15) 177-191 */
+/* 131-176 For future use */
+/* 177-191 Cause values reserved for GPRS charging protocol use (See GTP' In GSM 12.15) */
#define GTPCAUSE_NON_EXIST 192 /* Non-existent */
#define GTPCAUSE_INVALID_MESSAGE 193 /* Invalid message format */
#define GTPCAUSE_IMSI_NOT_KNOWN 194 /* IMSI not known */
#define GTPCAUSE_MS_DETACHED 195 /* MS is GPRS detached */
#define GTPCAUSE_MS_NOT_RESP 196 /* MS is not GPRS responding */
#define GTPCAUSE_MS_REFUSES 197 /* MS refuses */
-#define GTPCAUSE_198 198 /* For future use */
+/* 198 For future use */
#define GTPCAUSE_NO_RESOURCES 199 /* No resources available */
#define GTPCAUSE_NOT_SUPPORTED 200 /* Service not supported */
#define GTPCAUSE_MAN_IE_INCORRECT 201 /* Mandatory IE incorrect */
@@ -136,8 +136,8 @@
#define GTPCAUSE_SYN_ERR_FILTER 218 /* Syntactic errors in packet filter(s) */
#define GTPCAUSE_MISSING_APN 219 /* Missing or unknown APN */
#define GTPCAUSE_UNKNOWN_PDP 220 /* Unknown PDP address or PDP type */
-#define GTPCAUSE_221 221 /* For Future Use 221-240 */
-#define GTPCAUSE_241 241 /* Cause Values Reserved For Gprs Charging Protocol Use (See Gtp' In Gsm 12.15) 241-255 */
+/* 221-240 For future use */
+/* 241-255 Cause Values Reserved For Gprs Charging Protocol Use (See Gtp' In Gsm 12.15) */
static inline bool gtp_cause_successful(uint8_t cause)
{
--
To view, visit https://gerrit.osmocom.org/c/osmo-ggsn/+/35162?usp=email
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings
Gerrit-Project: osmo-ggsn
Gerrit-Branch: master
Gerrit-Change-Id: I8db0aa0ade59785443a407b51dea326144406dcf
Gerrit-Change-Number: 35162
Gerrit-PatchSet: 1
Gerrit-Owner: daniel <dwillmann(a)sysmocom.de>
Gerrit-MessageType: newchange
dexter has submitted this change. ( https://gerrit.osmocom.org/c/pysim/+/35161?usp=email )
Change subject: pySim-shell: Do not use self.lchan.scc when sending raw APDUs.
......................................................................
pySim-shell: Do not use self.lchan.scc when sending raw APDUs.
When sending raw APDUs, we access the scc (SimCardCommands) object via
the scc member in the lchan object. Unfortunately self.lchan will not be
populated when the rs (RuntimeState) object is missing. This is in
particular the case when no profile could be detected for the card,
which is a common situation when we boostrap an unprovisioned card.
So let's access the scc object through the card object. This is also
more logical since when we send raw APDUs we work below the level of
logical channels.
Change-Id: I6bbaebe7d7a2013f0ce558ca2da7d58f5e6d991a
Related: OS#6278
---
M pySim-shell.py
1 file changed, 29 insertions(+), 4 deletions(-)
Approvals:
Jenkins Builder: Verified
laforge: Looks good to me, but someone else must approve
fixeria: Looks good to me, approved
diff --git a/pySim-shell.py b/pySim-shell.py
index 4e08eb7..3d8bd86 100755
--- a/pySim-shell.py
+++ b/pySim-shell.py
@@ -237,10 +237,15 @@
@cmd2.with_argparser(apdu_cmd_parser)
def do_apdu(self, opts):
"""Send a raw APDU to the card, and print SW + Response.
- DANGEROUS: pySim-shell will not know any card state changes, and
- not continue to work as expected if you e.g. select a different
- file."""
- data, sw = self.lchan.scc._tp.send_apdu(opts.APDU)
+ CAUTION: this command bypasses the logical channel handling of pySim-shell and card state changes are not
+ tracked. Dpending on the raw APDU sent, pySim-shell may not continue to work as expected if you e.g. select
+ a different file."""
+
+ # When sending raw APDUs we access the scc object through _scc member of the card object. It should also be
+ # noted that the apdu command plays an exceptional role since it is the only card accessing command that
+ # can be executed without the presence of a runtime state (self.rs) object. However, this also means that
+ # self.lchan is also not present (see method equip).
+ data, sw = self.card._scc._tp.send_apdu(opts.APDU)
if data:
self.poutput("SW: %s, RESP: %s" % (sw, data))
else:
--
To view, visit https://gerrit.osmocom.org/c/pysim/+/35161?usp=email
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings
Gerrit-Project: pysim
Gerrit-Branch: master
Gerrit-Change-Id: I6bbaebe7d7a2013f0ce558ca2da7d58f5e6d991a
Gerrit-Change-Number: 35161
Gerrit-PatchSet: 4
Gerrit-Owner: dexter <pmaier(a)sysmocom.de>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: dexter <pmaier(a)sysmocom.de>
Gerrit-Reviewer: fixeria <vyanitskiy(a)sysmocom.de>
Gerrit-Reviewer: laforge <laforge(a)osmocom.org>
Gerrit-MessageType: merged
Attention is currently required from: dexter.
fixeria has posted comments on this change. ( https://gerrit.osmocom.org/c/pysim/+/35161?usp=email )
Change subject: pySim-shell: Do not use self.lchan.scc when sending raw APDUs.
......................................................................
Patch Set 4: Code-Review+2
--
To view, visit https://gerrit.osmocom.org/c/pysim/+/35161?usp=email
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings
Gerrit-Project: pysim
Gerrit-Branch: master
Gerrit-Change-Id: I6bbaebe7d7a2013f0ce558ca2da7d58f5e6d991a
Gerrit-Change-Number: 35161
Gerrit-PatchSet: 4
Gerrit-Owner: dexter <pmaier(a)sysmocom.de>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: fixeria <vyanitskiy(a)sysmocom.de>
Gerrit-Reviewer: laforge <laforge(a)osmocom.org>
Gerrit-Attention: dexter <pmaier(a)sysmocom.de>
Gerrit-Comment-Date: Wed, 29 Nov 2023 15:16:54 +0000
Gerrit-HasComments: No
Gerrit-Has-Labels: Yes
Gerrit-MessageType: comment
Attention is currently required from: daniel.
pespin has posted comments on this change. ( https://gerrit.osmocom.org/c/osmo-ggsn/+/35084?usp=email )
Change subject: gtp: Add net GTP cause values and a function to check for success
......................................................................
Patch Set 2:
(1 comment)
File gtp/gtp.h:
https://gerrit.osmocom.org/c/osmo-ggsn/+/35084/comment/0615ecd5_413c5d61
PS2, Line 106: #define GTPCAUSE_129 129 /* For future use 129-176 */
> I'm not opposed, but then that would mean removing all eight of these defines: […]
Agree, please submit a patch dropping all of them.
--
To view, visit https://gerrit.osmocom.org/c/osmo-ggsn/+/35084?usp=email
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings
Gerrit-Project: osmo-ggsn
Gerrit-Branch: master
Gerrit-Change-Id: I9c3bf64537ef2223e29f8082861fa32fde26bf68
Gerrit-Change-Number: 35084
Gerrit-PatchSet: 2
Gerrit-Owner: daniel <dwillmann(a)sysmocom.de>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: daniel <dwillmann(a)sysmocom.de>
Gerrit-Reviewer: laforge <laforge(a)osmocom.org>
Gerrit-Reviewer: lynxis lazus <lynxis(a)fe80.eu>
Gerrit-Reviewer: osmith <osmith(a)sysmocom.de>
Gerrit-CC: pespin <pespin(a)sysmocom.de>
Gerrit-Attention: daniel <dwillmann(a)sysmocom.de>
Gerrit-Comment-Date: Wed, 29 Nov 2023 14:59:03 +0000
Gerrit-HasComments: Yes
Gerrit-Has-Labels: No
Comment-In-Reply-To: pespin <pespin(a)sysmocom.de>
Comment-In-Reply-To: daniel <dwillmann(a)sysmocom.de>
Gerrit-MessageType: comment
daniel has posted comments on this change. ( https://gerrit.osmocom.org/c/osmo-ggsn/+/35084?usp=email )
Change subject: gtp: Add net GTP cause values and a function to check for success
......................................................................
Patch Set 2:
(2 comments)
File gtp/gtp.h:
https://gerrit.osmocom.org/c/osmo-ggsn/+/35084/comment/f62b203f_67e652e1
PS2, Line 106: #define GTPCAUSE_129 129 /* For future use 129-176 */
> You broke the API compat here. […]
I'm not opposed, but then that would mean removing all eight of these defines:
```c
#define GTPCAUSE_006 6 /* For future use 6-48 */
#define GTPCAUSE_049 49 /* Cause values reserved for GPRS charging protocol use (See GTP' in GSM 12.15) 49-63 */
#define GTPCAUSE_064 64 /* For future use 64-127 */
#define GTPCAUSE_131 131 /* For future use 131-176 */
#define GTPCAUSE_177 177 /* Cause values reserved for GPRS charging protocol use (See GTP' In GSM 12.15) 177-191 */
#define GTPCAUSE_198 198 /* For future use */
#define GTPCAUSE_221 221 /* For Future Use 221-240 */
#define GTPCAUSE_241 241 /* Cause Values Reserved For Gprs Charging Protocol Use (See Gtp' In Gsm 12.15) 241-255 */
```
Having one value defined for a range is pretty useless anyway.
https://gerrit.osmocom.org/c/osmo-ggsn/+/35084/comment/b39e4a66_057fb93c
PS2, Line 142: static inline bool gtp_cause_successful(uint8_t cause)
> not sure this is really useful to have here, I'd would have left it for the specific app. […]
It's used directly in libgtp as well: https://gerrit.osmocom.org/c/osmo-ggsn/+/35125
--
To view, visit https://gerrit.osmocom.org/c/osmo-ggsn/+/35084?usp=email
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings
Gerrit-Project: osmo-ggsn
Gerrit-Branch: master
Gerrit-Change-Id: I9c3bf64537ef2223e29f8082861fa32fde26bf68
Gerrit-Change-Number: 35084
Gerrit-PatchSet: 2
Gerrit-Owner: daniel <dwillmann(a)sysmocom.de>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: daniel <dwillmann(a)sysmocom.de>
Gerrit-Reviewer: laforge <laforge(a)osmocom.org>
Gerrit-Reviewer: lynxis lazus <lynxis(a)fe80.eu>
Gerrit-Reviewer: osmith <osmith(a)sysmocom.de>
Gerrit-CC: pespin <pespin(a)sysmocom.de>
Gerrit-Comment-Date: Wed, 29 Nov 2023 14:45:28 +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.
laforge has posted comments on this change. ( https://gerrit.osmocom.org/c/osmo-hnbgw/+/35153?usp=email )
Change subject: mgw_fsm: Assume IuUP HNB IP addr = Iuh during MGCP CRCX on RAN side
......................................................................
Patch Set 2: Code-Review+1
--
To view, visit https://gerrit.osmocom.org/c/osmo-hnbgw/+/35153?usp=email
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings
Gerrit-Project: osmo-hnbgw
Gerrit-Branch: master
Gerrit-Change-Id: Icf43e3a1cde809d844f17ef2d0600efe64bc3dfe
Gerrit-Change-Number: 35153
Gerrit-PatchSet: 2
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: Wed, 29 Nov 2023 14:37:44 +0000
Gerrit-HasComments: No
Gerrit-Has-Labels: Yes
Gerrit-MessageType: comment
Attention is currently required from: dexter, fixeria.
laforge has posted comments on this change. ( https://gerrit.osmocom.org/c/pysim/+/35161?usp=email )
Change subject: pySim-shell: Do not use self.lchan.scc when sending raw APDUs.
......................................................................
Patch Set 4: Code-Review+1
--
To view, visit https://gerrit.osmocom.org/c/pysim/+/35161?usp=email
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings
Gerrit-Project: pysim
Gerrit-Branch: master
Gerrit-Change-Id: I6bbaebe7d7a2013f0ce558ca2da7d58f5e6d991a
Gerrit-Change-Number: 35161
Gerrit-PatchSet: 4
Gerrit-Owner: dexter <pmaier(a)sysmocom.de>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: fixeria <vyanitskiy(a)sysmocom.de>
Gerrit-Reviewer: laforge <laforge(a)osmocom.org>
Gerrit-Attention: fixeria <vyanitskiy(a)sysmocom.de>
Gerrit-Attention: dexter <pmaier(a)sysmocom.de>
Gerrit-Comment-Date: Wed, 29 Nov 2023 14:34:35 +0000
Gerrit-HasComments: No
Gerrit-Has-Labels: Yes
Gerrit-MessageType: comment
laforge has submitted this change. ( https://gerrit.osmocom.org/c/docker-playground/+/35159?usp=email )
Change subject: ttcn3-pcu-test/sns: fix PCUIF version number (follow up patch)
......................................................................
ttcn3-pcu-test/sns: fix PCUIF version number (follow up patch)
Unfortunately we had to revert [1] because it worked for current master
but not for latest. The mistake here was to change the PCUIF version
number in PCU_Tests.cfg to PCUIF v12. This is indeed the correct version
for current master, but latest still uses v11. Also the change we made in
jenkins-sns only affected 2023q1 builds, it does not affect latest. This
is the reason why the previous patch broke latest.
This follow up patch now copies the approach we already successfully use
with the normal ttcn3-pcu-test / ttcn3-pcu-test-latest. (see also
jenkins.sh)
[1] I0b37f01f4c7bb829053231339e39ab734f4c8cbc
Change-Id: I1f94a0459e35d7b5632c81d7f7e2e60eb0d0229f
Related: OS#6275
---
M ttcn3-pcu-test/jenkins-sns.sh
1 file changed, 32 insertions(+), 0 deletions(-)
Approvals:
pespin: Looks good to me, but someone else must approve
laforge: Looks good to me, approved
Jenkins Builder: Verified
diff --git a/ttcn3-pcu-test/jenkins-sns.sh b/ttcn3-pcu-test/jenkins-sns.sh
index 50027d3..06f833e 100755
--- a/ttcn3-pcu-test/jenkins-sns.sh
+++ b/ttcn3-pcu-test/jenkins-sns.sh
@@ -13,6 +13,15 @@
if image_suffix_is_2023q1; then
sed -i 's/PCUIF_Types.mp_pcuif_version := 11/PCUIF_Types.mp_pcuif_version := 10/g' $1
fi
+
+ # This changes the PCUIF module parameter of the TTCN3 testsuite when the testsuite is
+ # executed for current master. For latest the PCUIF module parameter must stay at v.11
+ # since in osmo-pcu-latest PCUIF v.12 is not yet supported. After the next release, PCUIF
+ # v.12 will be supported in osmo-pcu-latest as well and this function, including the
+ # PCUIF_Types.mp_pcuif_version setting in the configuration files can be removed.
+ if image_suffix_is_master; then
+ sed -i 's/PCUIF_Types.mp_pcuif_version := 11/PCUIF_Types.mp_pcuif_version := 12/g' $1
+ fi
}
mkdir $VOL_BASE_DIR/pcu-tester
--
To view, visit https://gerrit.osmocom.org/c/docker-playground/+/35159?usp=email
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings
Gerrit-Project: docker-playground
Gerrit-Branch: master
Gerrit-Change-Id: I1f94a0459e35d7b5632c81d7f7e2e60eb0d0229f
Gerrit-Change-Number: 35159
Gerrit-PatchSet: 1
Gerrit-Owner: dexter <pmaier(a)sysmocom.de>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: fixeria <vyanitskiy(a)sysmocom.de>
Gerrit-Reviewer: laforge <laforge(a)osmocom.org>
Gerrit-Reviewer: pespin <pespin(a)sysmocom.de>
Gerrit-MessageType: merged
Attention is currently required from: fixeria, laforge.
Hello Jenkins Builder, fixeria, laforge,
I'd like you to reexamine a change. Please visit
https://gerrit.osmocom.org/c/pysim/+/35161?usp=email
to look at the new patch set (#4).
The following approvals got outdated and were removed:
Verified+1 by Jenkins Builder
Change subject: pySim-shell: Do not use self.lchan.scc when sending raw APDUs.
......................................................................
pySim-shell: Do not use self.lchan.scc when sending raw APDUs.
When sending raw APDUs, we access the scc (SimCardCommands) object via
the scc member in the lchan object. Unfortunately self.lchan will not be
populated when the rs (RuntimeState) object is missing. This is in
particular the case when no profile could be detected for the card,
which is a common situation when we boostrap an unprovisioned card.
So let's access the scc object through the card object. This is also
more logical since when we send raw APDUs we work below the level of
logical channels.
Change-Id: I6bbaebe7d7a2013f0ce558ca2da7d58f5e6d991a
Related: OS#6278
---
M pySim-shell.py
1 file changed, 29 insertions(+), 4 deletions(-)
git pull ssh://gerrit.osmocom.org:29418/pysim refs/changes/61/35161/4
--
To view, visit https://gerrit.osmocom.org/c/pysim/+/35161?usp=email
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings
Gerrit-Project: pysim
Gerrit-Branch: master
Gerrit-Change-Id: I6bbaebe7d7a2013f0ce558ca2da7d58f5e6d991a
Gerrit-Change-Number: 35161
Gerrit-PatchSet: 4
Gerrit-Owner: dexter <pmaier(a)sysmocom.de>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: fixeria <vyanitskiy(a)sysmocom.de>
Gerrit-Reviewer: laforge <laforge(a)osmocom.org>
Gerrit-Attention: laforge <laforge(a)osmocom.org>
Gerrit-Attention: fixeria <vyanitskiy(a)sysmocom.de>
Gerrit-MessageType: newpatchset
Attention is currently required from: fixeria, pespin.
dexter has posted comments on this change. ( https://gerrit.osmocom.org/c/docker-playground/+/35159?usp=email )
Change subject: ttcn3-pcu-test/sns: fix PCUIF version number (follow up patch)
......................................................................
Patch Set 1:
(1 comment)
Patchset:
PS1:
> In general I'd prefer having v12 (newest version) configured everywhere and sed it to 10 or 11 on th […]
Let's address this is in a follow up patch. This patch makes jenkins-sns.sh, equal to jenkins.sh. I think this is an improvement.
We then might consider to set the version to something like "XX" in the configs and put a comment next to it that the version number is set in the jenkins(-sns).sh scripts. And then we explicitly set the version number for each variant (master, latest, 2323q3 etc.)
--
To view, visit https://gerrit.osmocom.org/c/docker-playground/+/35159?usp=email
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings
Gerrit-Project: docker-playground
Gerrit-Branch: master
Gerrit-Change-Id: I1f94a0459e35d7b5632c81d7f7e2e60eb0d0229f
Gerrit-Change-Number: 35159
Gerrit-PatchSet: 1
Gerrit-Owner: dexter <pmaier(a)sysmocom.de>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: fixeria <vyanitskiy(a)sysmocom.de>
Gerrit-Reviewer: pespin <pespin(a)sysmocom.de>
Gerrit-Attention: pespin <pespin(a)sysmocom.de>
Gerrit-Attention: fixeria <vyanitskiy(a)sysmocom.de>
Gerrit-Comment-Date: Wed, 29 Nov 2023 14:12:25 +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: fixeria, laforge.
dexter has posted comments on this change. ( https://gerrit.osmocom.org/c/pysim/+/35161?usp=email )
Change subject: pySim-shell: Do not use self.lchan.scc when sending raw APDUs.
......................................................................
Patch Set 3:
(1 comment)
File pySim-shell.py:
https://gerrit.osmocom.org/c/pysim/+/35161/comment/686947c7_1ee83c6b
PS2, Line 244: When sending raw APDUs we access the scc object through _scc member of the card object. It should also be
: # noted that the apdu command plays an exceptional role since it is the only card accessing command that
: # can be executed without the presence of a runt
> Sure, the note is more directed to the programmer so that we do not excellently change it back. […]
Done
--
To view, visit https://gerrit.osmocom.org/c/pysim/+/35161?usp=email
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings
Gerrit-Project: pysim
Gerrit-Branch: master
Gerrit-Change-Id: I6bbaebe7d7a2013f0ce558ca2da7d58f5e6d991a
Gerrit-Change-Number: 35161
Gerrit-PatchSet: 3
Gerrit-Owner: dexter <pmaier(a)sysmocom.de>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: fixeria <vyanitskiy(a)sysmocom.de>
Gerrit-Reviewer: laforge <laforge(a)osmocom.org>
Gerrit-Attention: laforge <laforge(a)osmocom.org>
Gerrit-Attention: fixeria <vyanitskiy(a)sysmocom.de>
Gerrit-Comment-Date: Wed, 29 Nov 2023 14:03:59 +0000
Gerrit-HasComments: Yes
Gerrit-Has-Labels: No
Comment-In-Reply-To: laforge <laforge(a)osmocom.org>
Comment-In-Reply-To: dexter <pmaier(a)sysmocom.de>
Gerrit-MessageType: comment
Attention is currently required from: fixeria, laforge.
dexter has posted comments on this change. ( https://gerrit.osmocom.org/c/pysim/+/35161?usp=email )
Change subject: pySim-shell: Do not use self.lchan.scc when sending raw APDUs.
......................................................................
Patch Set 3:
(1 comment)
File pySim-shell.py:
https://gerrit.osmocom.org/c/pysim/+/35161/comment/1c07e118_8e9ca643
PS2, Line 244: When sending raw APDUs we access the scc object through _scc member of the card object. It should also be
: # noted that the apdu command plays an exceptional role since it is the only card accessing command that
: # can be executed without the presence of a runt
> I think the improtant bit for the user is not how we access the scc object. […]
Sure, the note is more directed to the programmer so that we do not excellently change it back. I have now updated the docstring as well.
--
To view, visit https://gerrit.osmocom.org/c/pysim/+/35161?usp=email
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings
Gerrit-Project: pysim
Gerrit-Branch: master
Gerrit-Change-Id: I6bbaebe7d7a2013f0ce558ca2da7d58f5e6d991a
Gerrit-Change-Number: 35161
Gerrit-PatchSet: 3
Gerrit-Owner: dexter <pmaier(a)sysmocom.de>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: fixeria <vyanitskiy(a)sysmocom.de>
Gerrit-Reviewer: laforge <laforge(a)osmocom.org>
Gerrit-Attention: laforge <laforge(a)osmocom.org>
Gerrit-Attention: fixeria <vyanitskiy(a)sysmocom.de>
Gerrit-Comment-Date: Wed, 29 Nov 2023 14:03:32 +0000
Gerrit-HasComments: Yes
Gerrit-Has-Labels: No
Comment-In-Reply-To: laforge <laforge(a)osmocom.org>
Gerrit-MessageType: comment
Attention is currently required from: fixeria, laforge.
Hello Jenkins Builder, fixeria, laforge,
I'd like you to reexamine a change. Please visit
https://gerrit.osmocom.org/c/pysim/+/35161?usp=email
to look at the new patch set (#3).
The following approvals got outdated and were removed:
Verified+1 by Jenkins Builder
Change subject: pySim-shell: Do not use self.lchan.scc when sending raw APDUs.
......................................................................
pySim-shell: Do not use self.lchan.scc when sending raw APDUs.
When sending raw APDUs, we access the scc (SimCardCommands) object via
the scc member in the lchan object. Unfortunately self.lchan will not be
populated when the rs (RuntimeState) object is missing. This is in
particular the case when no profile could be detected for the card,
which is a common situation when we boostrap an unprovisioned card.
So let's access the scc object through the card object. This is also
more logical since when we send raw APDUs we work below the level of
logical channels.
Change-Id: I6bbaebe7d7a2013f0ce558ca2da7d58f5e6d991a
Related: OS#6278
---
M pySim-shell.py
1 file changed, 29 insertions(+), 4 deletions(-)
git pull ssh://gerrit.osmocom.org:29418/pysim refs/changes/61/35161/3
--
To view, visit https://gerrit.osmocom.org/c/pysim/+/35161?usp=email
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings
Gerrit-Project: pysim
Gerrit-Branch: master
Gerrit-Change-Id: I6bbaebe7d7a2013f0ce558ca2da7d58f5e6d991a
Gerrit-Change-Number: 35161
Gerrit-PatchSet: 3
Gerrit-Owner: dexter <pmaier(a)sysmocom.de>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: fixeria <vyanitskiy(a)sysmocom.de>
Gerrit-Reviewer: laforge <laforge(a)osmocom.org>
Gerrit-Attention: laforge <laforge(a)osmocom.org>
Gerrit-Attention: fixeria <vyanitskiy(a)sysmocom.de>
Gerrit-MessageType: newpatchset
jolly has submitted this change. ( https://gerrit.osmocom.org/c/libosmocore/+/35160?usp=email )
Change subject: Add flag to enable RTS based polling
......................................................................
Add flag to enable RTS based polling
RTS based polling in LAPDm code is disabled by default. Make libosmogsm
stay compatible with existing applications that do not use RTS based
polling.
This patch fixes the issue that LAPDM_ENT_F_POLLING_ONLY did enable RTS
based polling too, which breaks existing applications like older
versions of osmo-bts.
Change-Id: I2a75c192bbc24e85bfc1656b2be21cea7a92814a
---
M include/osmocom/gsm/lapdm.h
M src/gsm/lapdm.c
2 files changed, 23 insertions(+), 5 deletions(-)
Approvals:
Jenkins Builder: Verified
pespin: Looks good to me, approved
diff --git a/include/osmocom/gsm/lapdm.h b/include/osmocom/gsm/lapdm.h
index 42ebbce..6812102 100644
--- a/include/osmocom/gsm/lapdm.h
+++ b/include/osmocom/gsm/lapdm.h
@@ -51,6 +51,7 @@
#define LAPDM_ENT_F_EMPTY_FRAME 0x0001
#define LAPDM_ENT_F_POLLING_ONLY 0x0002
#define LAPDM_ENT_F_DROP_2ND_REJ 0x0004
+#define LAPDM_ENT_F_RTS 0x0008
/*! a LAPDm Entity */
struct lapdm_entity {
diff --git a/src/gsm/lapdm.c b/src/gsm/lapdm.c
index fb892d2..1fc986d 100644
--- a/src/gsm/lapdm.c
+++ b/src/gsm/lapdm.c
@@ -363,8 +363,8 @@
if (le->tx_pending || le->flags & LAPDM_ENT_F_POLLING_ONLY) {
struct msgb *old_msg;
- /* In 'Polling only' mode there can be only one message. */
- if (le->flags & LAPDM_ENT_F_POLLING_ONLY) {
+ /* In 'RTS' mode there can be only one message. */
+ if (le->flags & LAPDM_ENT_F_RTS) {
/* Overwrite existing message by removing it first. */
if ((old_msg = msgb_dequeue(&dl->dl.tx_queue))) {
msgb_free(old_msg);
@@ -424,8 +424,8 @@
{
struct msgb *msg;
- /* Call RTS function of LAPD, to poll next frame. */
- if (dl->entity->flags & LAPDM_ENT_F_POLLING_ONLY) {
+ /* Call RTS function of LAPD, to queue next frame. */
+ if (dl->entity->flags & LAPDM_ENT_F_RTS) {
struct lapd_msg_ctx lctx;
int rc;
@@ -1635,7 +1635,7 @@
le->flags = flags;
/* Set flags at LAPD. */
- if (le->flags & LAPDM_ENT_F_POLLING_ONLY)
+ if (le->flags & LAPDM_ENT_F_RTS)
dl_flags |= LAPD_F_RTS;
if (le->flags & LAPDM_ENT_F_DROP_2ND_REJ)
dl_flags |= LAPD_F_DROP_2ND_REJ;
--
To view, visit https://gerrit.osmocom.org/c/libosmocore/+/35160?usp=email
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings
Gerrit-Project: libosmocore
Gerrit-Branch: master
Gerrit-Change-Id: I2a75c192bbc24e85bfc1656b2be21cea7a92814a
Gerrit-Change-Number: 35160
Gerrit-PatchSet: 2
Gerrit-Owner: jolly <andreas(a)eversberg.eu>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: fixeria <vyanitskiy(a)sysmocom.de>
Gerrit-Reviewer: jolly <andreas(a)eversberg.eu>
Gerrit-Reviewer: laforge <laforge(a)osmocom.org>
Gerrit-Reviewer: pespin <pespin(a)sysmocom.de>
Gerrit-MessageType: merged