lists.osmocom.org
Sign In Sign Up
Manage this list Sign In Sign Up

Keyboard Shortcuts

Thread View

  • j: Next unread message
  • k: Previous unread message
  • j a: Jump to all threads
  • j l: Jump to MailingList overview

gerrit-log

Thread Start a new thread
Download
Threads by month
  • ----- 2026 -----
  • November
  • October
  • September
  • August
  • July
  • June
  • May
  • April
  • March
  • February
  • January
  • ----- 2025 -----
  • December
  • November
  • October
  • September
  • August
  • July
  • June
  • May
  • April
  • March
  • February
  • January
  • ----- 2024 -----
  • December
  • November
  • October
  • September
  • August
  • July
  • June
  • May
  • April
  • March
  • February
  • January
  • ----- 2023 -----
  • December
  • November
  • October
  • September
  • August
  • July
  • June
  • May
  • April
  • March
  • February
  • January
  • ----- 2022 -----
  • December
  • November
  • October
  • September
  • August
  • July
  • June
  • May
  • April
  • March
  • February
  • January
gerrit-log@lists.osmocom.org

May 2023

  • 1 participants
  • 2583 discussions
[M] Change in libosmo-netif[arehbein/osmo_io_ipa]: stream: Add client side recv and send for IPA
by Jenkins Builder 12 May '23

12 May '23
Jenkins Builder has posted comments on this change. ( https://gerrit.osmocom.org/c/libosmo-netif/+/32709 ) Change subject: stream: Add client side recv and send for IPA ...................................................................... Patch Set 1: (2 comments) File src/stream.c: Robot Comment from checkpatch (run ID jenkins-gerrit-lint-6952): https://gerrit.osmocom.org/c/libosmo-netif/+/32709/comment/3ae1b305_427a34b4 PS1, Line 1233: msgb_pull(msg, sizeof (struct ipa_head)); space prohibited between function name and open parenthesis '(' Robot Comment from checkpatch (run ID jenkins-gerrit-lint-6952): https://gerrit.osmocom.org/c/libosmo-netif/+/32709/comment/e4d03b9e_0f6cb802 PS1, Line 1244: msgb_pull(msg, sizeof (struct ipa_head_ext)); space prohibited between function name and open parenthesis '(' -- To view, visit https://gerrit.osmocom.org/c/libosmo-netif/+/32709 To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings Gerrit-Project: libosmo-netif Gerrit-Branch: arehbein/osmo_io_ipa Gerrit-Change-Id: Ic93b2d96fd14ad1a1dc063924498d87f0b1d8a56 Gerrit-Change-Number: 32709 Gerrit-PatchSet: 1 Gerrit-Owner: arehbein <arehbein(a)sysmocom.de> Gerrit-CC: Jenkins Builder Gerrit-Comment-Date: Fri, 12 May 2023 13:57:17 +0000 Gerrit-HasComments: Yes Gerrit-Has-Labels: No Gerrit-MessageType: comment
1 0
0 0
[M] Change in libosmo-netif[arehbein/osmo_io_ipa]: stream: Add client side recv and send for IPA
by arehbein 12 May '23

12 May '23
arehbein has uploaded this change for review. ( https://gerrit.osmocom.org/c/libosmo-netif/+/32709 ) Change subject: stream: Add client side recv and send for IPA ...................................................................... stream: Add client side recv and send for IPA Related: OS#5753 Change-Id: Ic93b2d96fd14ad1a1dc063924498d87f0b1d8a56 --- M include/osmocom/netif/stream.h M src/stream.c 2 files changed, 79 insertions(+), 0 deletions(-) git pull ssh://gerrit.osmocom.org:29418/libosmo-netif refs/changes/09/32709/1 diff --git a/include/osmocom/netif/stream.h b/include/osmocom/netif/stream.h index cd1dd22..7f2c37e 100644 --- a/include/osmocom/netif/stream.h +++ b/include/osmocom/netif/stream.h @@ -4,6 +4,7 @@ #include <stdint.h> #include <osmocom/core/msgb.h> +#include <osmocom/gsm/protocol/ipaccess.h> /*! \addtogroup stream * @{ @@ -108,7 +109,11 @@ void osmo_stream_cli_close(struct osmo_stream_cli *cli); void osmo_stream_cli_send(struct osmo_stream_cli *cli, struct msgb *msg); +void osmo_stream_cli_send_ipa(struct osmo_stream_cli *cli, enum ipaccess_proto p, + enum ipaccess_proto_ext pe, struct msgb *msg); int osmo_stream_cli_recv(struct osmo_stream_cli *cli, struct msgb *msg); +int osmo_stream_cli_recv_ipa(struct osmo_stream_cli *cli, enum ipaccess_proto p, + enum ipaccess_proto_ext pe, struct msgb *msg); void osmo_stream_cli_clear_tx_queue(struct osmo_stream_cli *cli); diff --git a/src/stream.c b/src/stream.c index d61a8d6..ac2dcec 100644 --- a/src/stream.c +++ b/src/stream.c @@ -37,6 +37,8 @@ #include <osmocom/core/utils.h> #include <osmocom/gsm/tlv.h> #include <osmocom/gsm/ipa.h> +#include <osmocom/netif/ipa.h> +#include <osmocom/gsm/protocol/ipaccess.h> #include <osmocom/core/msgb.h> #include <osmocom/core/osmo_io.h> #include <osmocom/core/panic.h> @@ -1155,6 +1157,23 @@ } } +/*! \brief Enqueue IPA data to be sent via an Osmocom stream client + * \param[in] cli Stream client through which we want to send + * \param[in] p Protocol transported by IPA + * \param[in] pe Ignored, unless p == IPAC_PROTO_OSMO, in which case this specifies the + * Osmocom protocol extension + * \param[in] msg Message buffer to encapsulate as IPA (or possibly IPA + IPA extended + * enqueue in transmit queue) */ +void osmo_stream_cli_send_ipa(struct osmo_stream_cli *cli, enum ipaccess_proto p, + enum ipaccess_proto_ext pe, struct msgb *msg) +{ + OSMO_ASSERT(msg); + if (p == IPAC_PROTO_OSMO) + ipa_prepend_header_ext(msg, pe); + osmo_ipa_msg_push_header(msg, p); + osmo_stream_cli_send(cli, msg); +} + /*! \brief Receive data via an Osmocom stream client * \param[in] cli Stream Client through which we want to send * \param msg pre-allocate message buffer to which received data is appended @@ -1182,6 +1201,51 @@ return ret; } +/*! \brief Receive IPA data via an Osmocom stream client + * \param[in] cli Stream Client through which we want to send + * \param[in] p Expected protocol to be transported by IPA + * \param[in] pe Ignored, unless p == IPAC_PROTO_OSMO, in which case this specifies the + * Osmocom protocol extension expected to be received + * \param msg pre-allocated message buffer to which received data is appended + * \returns number of bytes read; <=0 in case of error. */ +int osmo_stream_cli_recv_ipa(struct osmo_stream_cli *cli, enum ipaccess_proto p, + enum ipaccess_proto_ext pe, struct msgb *msg) +{ + struct ipa_head *ih; + struct ipa_head_ext *ihe; + size_t bytes; + int ret = osmo_stream_cli_recv(cli, msg); + if (ret <= 0) { + LOGSCLI(cli, LOGL_ERROR, "Couldn't receive IPA message\n"); + return ret; + } + bytes = ret; + if ((ret = osmo_ipa_process_msg(msg)) < 0) { + LOGSCLI(cli, LOGL_ERROR, "Error processing IPA message\n"); + return ret; + } + ih = (struct ipa_head *)msg->data; + if (ih->proto != p) { + LOGSCLI(cli, LOGL_ERROR, "Unexpected IPA protocol received: 0x%02x " + "(expected: 0x%02x)\n", ih->proto, p); + return -ENOMSG; + } + msgb_pull(msg, sizeof (struct ipa_head)); + msg->l1h = NULL; + if (ih->proto != IPAC_PROTO_OSMO) /* No extensions expected */ + return bytes; + + ihe = (struct ipa_head_ext *)msg; + if (ihe->proto != pe) { + LOGSCLI(cli, LOGL_ERROR, "Unexpected IPA Osmocom protocol extension " + "received: 0x%02x (expected: 0x%02x)\n", ihe->proto, pe); + return -ENOMSG; + } + msgb_pull(msg, sizeof (struct ipa_head_ext)); + msg->l2h = NULL; + return ret; +} + void osmo_stream_cli_clear_tx_queue(struct osmo_stream_cli *cli) { switch (cli->mode) { -- To view, visit https://gerrit.osmocom.org/c/libosmo-netif/+/32709 To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings Gerrit-Project: libosmo-netif Gerrit-Branch: arehbein/osmo_io_ipa Gerrit-Change-Id: Ic93b2d96fd14ad1a1dc063924498d87f0b1d8a56 Gerrit-Change-Number: 32709 Gerrit-PatchSet: 1 Gerrit-Owner: arehbein <arehbein(a)sysmocom.de> Gerrit-MessageType: newchange
1 0
0 0
[S] Change in libosmo-netif[arehbein/osmo_io_ipa]: examples: Add IPA segmentation to example
by arehbein 12 May '23

12 May '23
arehbein has uploaded this change for review. ( https://gerrit.osmocom.org/c/libosmo-netif/+/32708 ) Change subject: examples: Add IPA segmentation to example ...................................................................... examples: Add IPA segmentation to example Related: OS#5753 Change-Id: I9a5335f1719e691567a8bc9c33745e0010902253 --- M examples/ipa-stream-client.c M examples/ipa-stream-server.c 2 files changed, 12 insertions(+), 0 deletions(-) git pull ssh://gerrit.osmocom.org:29418/libosmo-netif refs/changes/08/32708/1 diff --git a/examples/ipa-stream-client.c b/examples/ipa-stream-client.c index fc48a50..48421b7 100644 --- a/examples/ipa-stream-client.c +++ b/examples/ipa-stream-client.c @@ -176,6 +176,7 @@ osmo_stream_cli_set_iofd_read_cb(conn, read_cb); osmo_stream_cli_set_data(conn, &num_msgs); osmo_stream_cli_set_nodelay(conn, true); + osmo_stream_cli_set_stream_proto(conn, OSMO_STREAM_IPAC); if (osmo_stream_cli_open(conn) < 0) { fprintf(stderr, "cannot open client\n"); diff --git a/examples/ipa-stream-server.c b/examples/ipa-stream-server.c index d667f42..e88e39e 100644 --- a/examples/ipa-stream-server.c +++ b/examples/ipa-stream-server.c @@ -105,6 +105,7 @@ osmo_stream_srv_link_set_port(srv, 10000); osmo_stream_srv_link_set_accept_cb(srv, accept_cb); osmo_stream_srv_link_set_nodelay(srv, true); + osmo_stream_srv_link_set_stream_proto(srv, OSMO_STREAM_IPAC); if (osmo_stream_srv_link_open(srv) < 0) { fprintf(stderr, "cannot open client\n"); -- To view, visit https://gerrit.osmocom.org/c/libosmo-netif/+/32708 To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings Gerrit-Project: libosmo-netif Gerrit-Branch: arehbein/osmo_io_ipa Gerrit-Change-Id: I9a5335f1719e691567a8bc9c33745e0010902253 Gerrit-Change-Number: 32708 Gerrit-PatchSet: 1 Gerrit-Owner: arehbein <arehbein(a)sysmocom.de> Gerrit-MessageType: newchange
1 0
0 0
[S] Change in osmo-hnbgw[master]: vty: make legacy 'hnbgw'/'sccp cr max...' fatal
by laforge 12 May '23

12 May '23
Attention is currently required from: neels. laforge has posted comments on this change. ( https://gerrit.osmocom.org/c/osmo-hnbgw/+/32676 ) Change subject: vty: make legacy 'hnbgw'/'sccp cr max...' fatal ...................................................................... Patch Set 1: Code-Review+2 -- To view, visit https://gerrit.osmocom.org/c/osmo-hnbgw/+/32676 To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings Gerrit-Project: osmo-hnbgw Gerrit-Branch: master Gerrit-Change-Id: I71f82efe07af2c32f2aa01084bc8da6ce5c6cd1a Gerrit-Change-Number: 32676 Gerrit-PatchSet: 1 Gerrit-Owner: neels <nhofmeyr(a)sysmocom.de> Gerrit-Reviewer: Jenkins Builder Gerrit-Reviewer: laforge <laforge(a)osmocom.org> Gerrit-Attention: neels <nhofmeyr(a)sysmocom.de> Gerrit-Comment-Date: Fri, 12 May 2023 08:15:14 +0000 Gerrit-HasComments: No Gerrit-Has-Labels: Yes Gerrit-MessageType: comment
1 0
0 0
[S] Change in osmo-pcu[master]: gprs_rlcmac: also use direct TLLI PCUIF for paging macblocks
by dexter 12 May '23

12 May '23
dexter has uploaded this change for review. ( https://gerrit.osmocom.org/c/osmo-pcu/+/32694 ) Change subject: gprs_rlcmac: also use direct TLLI PCUIF for paging macblocks ...................................................................... gprs_rlcmac: also use direct TLLI PCUIF for paging macblocks In the current code we still send PAGING COMMAND macblocks via SAPI PCU_IF_SAPI_PCH, which technically belongs to the older PCUIF version (v.10), which we are going to deprecate soon. To give some background information it should be noted that this bug has its root cause in a misconception on how the receiving end should behave when it receives PAGING COMMAND macblocks. It was not clear that PAGING COMMAND and IMMEDIATE ASSIGNMENT (via PCH) require a confirmation by the receiving end. Since osmo-bts uses the old V.10 PCUIF interface we get a confirmation for both message types, but osmo-bsc, which uses the newer V.11 interface will only confirm IMMEDIATE ASSIGNMENT messages, to distinguish between both message types it uses SAPI PCU_IF_SAPI_PCH for PAGING COMMAND and PCU_IF_SAPI_PCH_DT for IMMEDIATE ASSIGNMENT (confirmed). It is not only confusing to use two different SAPIs to access the PCH, but also wrong. In the new PCUIF interface we should only use PCU_IF_SAPI_PCH_DT. A coresponding patch for osmo-bsc is already submitted (see Depends). Depends: osmo-bsc.git I82443f2b402aa2416469c8c50b1c050323ef3b8f Related: OS##5927 Change-Id: I99cfe373fa157cfb32b74c113ad9935347653a71 --- M src/gprs_rlcmac.c M src/pcu_l1_if.cpp M src/pcu_l1_if.h 3 files changed, 40 insertions(+), 9 deletions(-) git pull ssh://gerrit.osmocom.org:29418/osmo-pcu refs/changes/94/32694/1 diff --git a/src/gprs_rlcmac.c b/src/gprs_rlcmac.c index 3163c32..07c7e25 100644 --- a/src/gprs_rlcmac.c +++ b/src/gprs_rlcmac.c @@ -17,6 +17,7 @@ */ #include <osmocom/gsm/gsm48.h> +#include <osmocom/core/bitvec.h> #include <pcu_l1_if.h> #include <gprs_rlcmac.h> @@ -43,7 +44,12 @@ return -1; } bts_do_rate_ctr_inc(bts, CTR_PCH_REQUESTS); - pcu_l1if_tx_pch(bts, paging_request, plen, imsi); + + if (the_pcu->pcu_if_version >= 0x0b) + pcu_l1if_tx_pch_dt(bts, paging_request, plen, imsi, mi->tmsi); + else + pcu_l1if_tx_pch(bts, paging_request, plen, imsi); + bitvec_free(paging_request); return 0; diff --git a/src/pcu_l1_if.cpp b/src/pcu_l1_if.cpp index 85aaddc..51c03d9 100644 --- a/src/pcu_l1_if.cpp +++ b/src/pcu_l1_if.cpp @@ -286,13 +286,9 @@ pcu_tx_data_req(bts, 0, 0, PCU_IF_SAPI_PCH, 0, 0, 0, data, sizeof(data)); } -/* Send a block via the paging channel and require a confirmation by the receiving end */ -void pcu_l1if_tx_pch_dt(struct gprs_rlcmac_bts *bts, bitvec *block, int plen, const char *imsi, uint32_t tlli) +/* Send a macblock via the paging channel (and get confirmation by the receiving end) */ +void pcu_l1if_tx_pch_dt(struct gprs_rlcmac_bts *bts, struct bitvec *block, int plen, const char *imsi, uint32_t tlli) { - /* NOTE: This is in practice only used to transmit IMMEDIATE ASSIGNMENT messages through the paging channel and - * it is not guaranteed to work with other message types. The prepended TLLI will be used as an identifier in - * the confirmation message. */ - struct gsm_pcu_if_pch_dt pch_dt = { 0 }; pch_dt.tlli = tlli; diff --git a/src/pcu_l1_if.h b/src/pcu_l1_if.h index f787c40..88e84c3 100644 --- a/src/pcu_l1_if.h +++ b/src/pcu_l1_if.h @@ -17,6 +17,7 @@ #define PCU_L1_IF_H #include <stdint.h> + #ifdef __cplusplus extern "C" { #endif @@ -147,8 +148,6 @@ uint32_t fn, uint8_t block_nr, uint8_t *data, size_t data_len); void pcu_l1if_tx_agch(struct gprs_rlcmac_bts *bts, bitvec *block, int len); - -void pcu_l1if_tx_pch_dt(struct gprs_rlcmac_bts *bts, bitvec *block, int plen, const char *imsi, uint32_t tlli); #endif #ifdef __cplusplus @@ -158,6 +157,7 @@ int pcu_tx_neigh_addr_res_req(struct gprs_rlcmac_bts *bts, const struct neigh_cache_entry_key *neigh_key); void pcu_l1if_tx_pch(struct gprs_rlcmac_bts *bts, struct bitvec *block, int plen, const char *imsi); +void pcu_l1if_tx_pch_dt(struct gprs_rlcmac_bts *bts, struct bitvec *block, int plen, const char *imsi, uint32_t tlli); int pcu_rx(struct gsm_pcu_if *pcu_prim, size_t pcu_prim_length); int pcu_l1if_open(void); -- To view, visit https://gerrit.osmocom.org/c/osmo-pcu/+/32694 To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings Gerrit-Project: osmo-pcu Gerrit-Branch: master Gerrit-Change-Id: I99cfe373fa157cfb32b74c113ad9935347653a71 Gerrit-Change-Number: 32694 Gerrit-PatchSet: 1 Gerrit-Owner: dexter <pmaier(a)sysmocom.de> Gerrit-MessageType: newchange
1 0
0 0
[M] Change in osmo-bsc[master]: pcu_sock: fix PCUIF interface (PCH)
by dexter 12 May '23

12 May '23
dexter has uploaded this change for review. ( https://gerrit.osmocom.org/c/osmo-bsc/+/32693 ) Change subject: pcu_sock: fix PCUIF interface (PCH) ...................................................................... pcu_sock: fix PCUIF interface (PCH) The PCUIF interface implementation in osmo-bsc provides two ways to access the paging channel (PCH). 1) Under the SAPI PCU_IF_SAPI_PCH PAGING COMMAND messages are accepted as whole macblocks but the format is in the style that we are going to deprecate with PCUIF v.11. Also at the moment those PAGING COMMANDs are not confirmed towards the PCU, but should (see paging.c in osmo-bts, which confirms PAGING COMMANDs and IMMEDIATE ASSIGNMENT messages). 2) Under the SAPI PCU_IF_SAPI_PCH_DT messages are also accepded as macblocks but are also tagged with a TLLI for reference. Those are confirmed towards the PCU as it should be. The existence of the two SAPIs in the osmo-bsc implementation are due to a misconception of the PCUIF and if PAGING COMMAND macblocks should be confirmed as well. The problem is fixed on osmo-pcu now (see Depends). Since in osmo-bsc PAGING COMMAND and IMMEDIATE ASSIGNMENT are two different RSL commands we have to distinguish both by the massage type field in the macblock now. Also since SAPI SAPI_PCU_IF_PCH is now no longer used in PCUIF v.11 we may drop this code path. Depends: osmo-pcu.git I99cfe373fa157cfb32b74c113ad9935347653a71 Related: OS##5927 Change-Id: I82443f2b402aa2416469c8c50b1c050323ef3b8f --- M include/osmocom/bsc/pcu_if.h M src/osmo-bsc/abis_rsl.c M src/osmo-bsc/pcu_sock.c 3 files changed, 56 insertions(+), 49 deletions(-) git pull ssh://gerrit.osmocom.org:29418/osmo-bsc refs/changes/93/32693/1 diff --git a/include/osmocom/bsc/pcu_if.h b/include/osmocom/bsc/pcu_if.h index 5dc6e37..525b2e4 100644 --- a/include/osmocom/bsc/pcu_if.h +++ b/include/osmocom/bsc/pcu_if.h @@ -25,11 +25,7 @@ uint8_t is_11bit, enum ph_burst_type burst_type); /* Confirm the sending of an immediate assignment to the pcu */ -int pcu_tx_imm_ass_sent(struct gsm_bts *bts, uint32_t tlli); - - -/* Confirm the sending of an immediate assignment to the pcu */ -int pcu_tx_imm_ass_sent(struct gsm_bts *bts, uint32_t tlli); +int pcu_tx_pch_confirm(struct gsm_bts *bts, uint32_t tlli); /* Open connection to PCU */ int pcu_sock_init(struct gsm_network *net); diff --git a/src/osmo-bsc/abis_rsl.c b/src/osmo-bsc/abis_rsl.c index 72acc85..54357de 100644 --- a/src/osmo-bsc/abis_rsl.c +++ b/src/osmo-bsc/abis_rsl.c @@ -2398,7 +2398,7 @@ else { msgb_pull(msg, 1); /* drop previous data to use msg_pull_u32 */ tlli = msgb_pull_u32(msg); - pcu_tx_imm_ass_sent(sign_link->trx->bts, tlli); + pcu_tx_pch_confirm(sign_link->trx->bts, tlli); } return 0; } diff --git a/src/osmo-bsc/pcu_sock.c b/src/osmo-bsc/pcu_sock.c index eb4f265..823b6f6 100644 --- a/src/osmo-bsc/pcu_sock.c +++ b/src/osmo-bsc/pcu_sock.c @@ -436,7 +436,7 @@ } /* Confirm the sending of an immediate assignment to the pcu */ -int pcu_tx_imm_ass_sent(struct gsm_bts *bts, uint32_t tlli) +int pcu_tx_pch_confirm(struct gsm_bts *bts, uint32_t tlli) { struct msgb *msg; struct gsm_pcu_if *pcu_prim; @@ -460,9 +460,9 @@ * Encoding::write_paging_request) and extract the mobile identity * (P-TMSI) from it */ static int pcu_rx_rr_paging(struct gsm_bts *bts, uint8_t paging_group, - const uint8_t *raw_rr_msg) + const struct gsm_pcu_if_pch_dt *pch_dt) { - struct gsm48_paging1 *p1 = (struct gsm48_paging1 *) raw_rr_msg; + struct gsm48_paging1 *p1 = (struct gsm48_paging1 *) pch_dt->data; uint8_t chan_needed; struct osmo_mobile_identity mi; int rc; @@ -502,28 +502,25 @@ break; } + pcu_tx_pch_confirm(bts, pch_dt->tlli); return rc; } -/* Helper function for pcu_rx_data_req() to extract paging group info (3 byte) */ -static uint8_t extract_paging_group(struct gsm_bts *bts, uint8_t *data) +static int pcu_rx_rr_imm_ass(struct gsm_bts *bts, uint8_t paging_group, + const struct gsm_pcu_if_pch_dt *pch_dt) { - char imsi_digit_buf[4]; - uint8_t pag_grp; + LOG_BTS(bts, DPCU, LOGL_DEBUG, "PCU Sends immediate assignment via PCH (TLLI=0x%08x, IMSI=%s, Paging group=0x%02x)\n", + pch_dt->tlli, pch_dt->imsi, paging_group); - /* the first three bytes are the last three digits of the IMSI, which we need to compute the paging group */ - imsi_digit_buf[0] = data[0]; - imsi_digit_buf[1] = data[1]; - imsi_digit_buf[2] = data[2]; - imsi_digit_buf[3] = '\0'; + /* NOTE: Sending an IMMEDIATE ASSIGNMENT via PCH became necessary with GPRS in order to be able to + * assign downlink TBFs directly through the paging channel. However, this method never became part + * of the RSL specs. This means that each BTS vendor has to come up with a proprietary method. At + * the moment we only support Ericsson RBS here. */ + if (is_ericsson_bts(bts)) + return rsl_ericsson_imm_assign_cmd(bts, pch_dt->tlli, sizeof(pch_dt->data), pch_dt->data, paging_group); - pag_grp = gsm0502_calc_paging_group(&bts->si_common.chan_desc, - str_to_imsi(imsi_digit_buf)); - - LOG_BTS(bts, DPCU, LOGL_DEBUG, "Calculating paging group: imsi_digit_buf=%s ==> pag_grp=0x%02x\n", - imsi_digit_buf, pag_grp); - - return pag_grp; + LOG_BTS(bts, DPCU, LOGL_ERROR, "BTS model does not support sending immediate assignment via PCH!\n"); + return -ENOTSUP; } static int pcu_rx_data_req(struct gsm_bts *bts, uint8_t msg_type, @@ -532,6 +529,7 @@ uint8_t pag_grp; int rc = 0; struct gsm_pcu_if_pch_dt *pch_dt; + struct gsm48_imm_ass *gsm48_imm_ass; LOG_BTS(bts, DPCU, LOGL_DEBUG, "Data request received: sapi=%s arfcn=%d " "block=%d data=%s\n", sapi_string[data_req->sapi], @@ -539,18 +537,13 @@ osmo_hexdump(data_req->data, data_req->len)); switch (data_req->sapi) { - case PCU_IF_SAPI_PCH: - /* Extract 3 byte paging group */ - pag_grp = extract_paging_group(bts, data_req->data); - pcu_rx_rr_paging(bts, pag_grp, data_req->data+3); - break; case PCU_IF_SAPI_AGCH: if (rsl_imm_assign_cmd(bts, data_req->len, data_req->data)) rc = -EIO; break; case PCU_IF_SAPI_PCH_DT: /* DT = direct TLLI. A tlli is prefixed so that the BSC/BTS can confirm the sending of the downlink - * IMMEDIATE ASSIGNMENT towards the PCU using this TLLI as a reference. */ + * IMMEDIATE ASSIGNMENT or PAGING COMMAND towards the PCU using this TLLI as a reference. */ if (data_req->len < sizeof(struct gsm_pcu_if_pch_dt)) { LOG_BTS(bts, DPCU, LOGL_ERROR, "Received PCU data request with invalid/small length %d\n", @@ -561,24 +554,10 @@ pch_dt = (struct gsm_pcu_if_pch_dt *)data_req->data; pag_grp = gsm0502_calc_paging_group(&bts->si_common.chan_desc, str_to_imsi(pch_dt->imsi)); - LOG_BTS(bts, DPCU, LOGL_DEBUG, "PCU Sends immediate assignment via PCH (TLLI=0x%08x, IMSI=%s, Paging group=0x%02x)\n", - pch_dt->tlli, pch_dt->imsi, pag_grp); - - /* NOTE: Sending an IMMEDIATE ASSIGNMENT via PCH became necessary with GPRS in order to be able to - * assign downlink TBFs directly through the paging channel. However, this method never became part - * of the RSL specs. This means that each BTS vendor has to come up with a proprietary method. At - * the moment we only support Ericsson RBS here. */ - if (is_ericsson_bts(bts)) { - rc = rsl_ericsson_imm_assign_cmd(bts, pch_dt->tlli, sizeof(pch_dt->data), - pch_dt->data, pag_grp); - } else { - LOG_BTS(bts, DPCU, LOGL_ERROR, "BTS model does not support sending immediate assignment via PCH!\n"); - rc = -ENOTSUP; - } - - if (rc) - rc = -EIO; - break; + gsm48_imm_ass = (struct gsm48_imm_ass *)pch_dt->data; + if (gsm48_imm_ass->msg_type == GSM48_MT_RR_IMM_ASS) + return pcu_rx_rr_imm_ass(bts, pag_grp, pch_dt); + return pcu_rx_rr_paging(bts, pag_grp, pch_dt); default: LOG_BTS(bts, DPCU, LOGL_ERROR, "Received PCU data request with " "unsupported sapi %d\n", data_req->sapi); -- To view, visit https://gerrit.osmocom.org/c/osmo-bsc/+/32693 To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings Gerrit-Project: osmo-bsc Gerrit-Branch: master Gerrit-Change-Id: I82443f2b402aa2416469c8c50b1c050323ef3b8f Gerrit-Change-Number: 32693 Gerrit-PatchSet: 1 Gerrit-Owner: dexter <pmaier(a)sysmocom.de> Gerrit-MessageType: newchange
1 0
0 0
[S] Change in osmo-iuh[master]: add ranap_new_msg_reset2() with GlobalRNC-ID
by neels 11 May '23

11 May '23
neels has uploaded this change for review. ( https://gerrit.osmocom.org/c/osmo-iuh/+/32692 ) Change subject: add ranap_new_msg_reset2() with GlobalRNC-ID ...................................................................... add ranap_new_msg_reset2() with GlobalRNC-ID So far we are omitting the GlobalRNC-ID from all of our RANAP RESET messages, because clearly, in 3GPP TS 25.413 9.1.39, the Global RNC-ID is listed as optional. OTOH, section 8.26.2.1 says "The RNC shall include the Global RNC-ID IE in the RESET message." Apparently an RNC must include this ID, while a CN omits it. Related: SYS#6441 Change-Id: Iec70c3054333f01bc27ca0e69bfa325bbe36edd0 --- M include/osmocom/ranap/ranap_msg_factory.h M src/ranap_msg_factory.c 2 files changed, 37 insertions(+), 0 deletions(-) git pull ssh://gerrit.osmocom.org:29418/osmo-iuh refs/changes/92/32692/1 diff --git a/include/osmocom/ranap/ranap_msg_factory.h b/include/osmocom/ranap/ranap_msg_factory.h index d89a1ae..4b42d05 100644 --- a/include/osmocom/ranap/ranap_msg_factory.h +++ b/include/osmocom/ranap/ranap_msg_factory.h @@ -47,6 +47,9 @@ /*! \brief generate RANAP RESET message */ struct msgb *ranap_new_msg_reset(RANAP_CN_DomainIndicator_t domain, const RANAP_Cause_t *cause); +struct msgb *ranap_new_msg_reset2(RANAP_CN_DomainIndicator_t domain, + const RANAP_Cause_t *cause, + RANAP_GlobalRNC_ID_t *rnc_id); /*! \brief generate RANAP RESET ACK message */ struct msgb *ranap_new_msg_reset_ack(RANAP_CN_DomainIndicator_t domain, diff --git a/src/ranap_msg_factory.c b/src/ranap_msg_factory.c index b871343..44b879f 100644 --- a/src/ranap_msg_factory.c +++ b/src/ranap_msg_factory.c @@ -43,6 +43,14 @@ struct msgb *ranap_new_msg_reset(RANAP_CN_DomainIndicator_t domain, const RANAP_Cause_t *cause) { + return ranap_new_msg_reset2(domain, cause, NULL); +} + +/*! generate RANAP RESET message. Like ranap_new_msg_reset(), but allows passing a Global-RNC-ID. */ +struct msgb *ranap_new_msg_reset2(RANAP_CN_DomainIndicator_t domain, + const RANAP_Cause_t *cause, + RANAP_GlobalRNC_ID_t *rnc_id) +{ RANAP_ResetIEs_t ies; RANAP_Reset_t out; struct msgb *msg; @@ -53,6 +61,14 @@ if (cause) memcpy(&ies.cause, cause, sizeof(ies.cause)); + if (rnc_id) { + ies.presenceMask = RESETIES_RANAP_GLOBALRNC_ID_PRESENT; + OCTET_STRING_noalloc(&ies.globalRNC_ID.pLMNidentity, + rnc_id->pLMNidentity.buf, + rnc_id->pLMNidentity.size); + ies.globalRNC_ID.rNC_ID = rnc_id->rNC_ID; + } + memset(&out, 0, sizeof(out)); rc = ranap_encode_reseties(&out, &ies); if (rc < 0) { -- To view, visit https://gerrit.osmocom.org/c/osmo-iuh/+/32692 To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings Gerrit-Project: osmo-iuh Gerrit-Branch: master Gerrit-Change-Id: Iec70c3054333f01bc27ca0e69bfa325bbe36edd0 Gerrit-Change-Number: 32692 Gerrit-PatchSet: 1 Gerrit-Owner: neels <nhofmeyr(a)sysmocom.de> Gerrit-MessageType: newchange
1 0
0 0
[S] Change in osmo-bsc[master]: pcu_connected(): constify parameter
by msuraev 11 May '23

11 May '23
msuraev has submitted this change. ( https://gerrit.osmocom.org/c/osmo-bsc/+/32633 ) Change subject: pcu_connected(): constify parameter ...................................................................... pcu_connected(): constify parameter Change-Id: I6d18ec0ad2bd6f71e0187ed70b03c3a2d0447f21 --- M include/osmocom/bsc/pcu_if.h M src/osmo-bsc/pcu_sock.c 2 files changed, 11 insertions(+), 2 deletions(-) Approvals: fixeria: Looks good to me, but someone else must approve pespin: Looks good to me, approved Jenkins Builder: Verified diff --git a/include/osmocom/bsc/pcu_if.h b/include/osmocom/bsc/pcu_if.h index 34349dc..5dc6e37 100644 --- a/include/osmocom/bsc/pcu_if.h +++ b/include/osmocom/bsc/pcu_if.h @@ -15,7 +15,7 @@ }; /* Check if BTS has a PCU connection */ -bool pcu_connected(struct gsm_network *net); +bool pcu_connected(const struct gsm_network *net); /* PCU relevant information has changed; Inform PCU (if connected) */ void pcu_info_update(struct gsm_bts *bts); diff --git a/src/osmo-bsc/pcu_sock.c b/src/osmo-bsc/pcu_sock.c index 0988c3b..eb4f265 100644 --- a/src/osmo-bsc/pcu_sock.c +++ b/src/osmo-bsc/pcu_sock.c @@ -59,7 +59,7 @@ [PCU_IF_SAPI_PCH_DT] = "PCH_DT", }; -bool pcu_connected(struct gsm_network *net) +bool pcu_connected(const struct gsm_network *net) { struct pcu_sock_state *state = net->pcu_state; -- To view, visit https://gerrit.osmocom.org/c/osmo-bsc/+/32633 To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings Gerrit-Project: osmo-bsc Gerrit-Branch: master Gerrit-Change-Id: I6d18ec0ad2bd6f71e0187ed70b03c3a2d0447f21 Gerrit-Change-Number: 32633 Gerrit-PatchSet: 2 Gerrit-Owner: msuraev <msuraev(a)sysmocom.de> Gerrit-Reviewer: Jenkins Builder Gerrit-Reviewer: fixeria <vyanitskiy(a)sysmocom.de> Gerrit-Reviewer: msuraev <msuraev(a)sysmocom.de> Gerrit-Reviewer: pespin <pespin(a)sysmocom.de> Gerrit-MessageType: merged
1 0
0 0
[S] Change in osmo-bsc[master]: pcu_connected(): constify parameter
by msuraev 11 May '23

11 May '23
Attention is currently required from: fixeria. msuraev has posted comments on this change. ( https://gerrit.osmocom.org/c/osmo-bsc/+/32633 ) Change subject: pcu_connected(): constify parameter ...................................................................... Patch Set 1: (1 comment) File src/osmo-bsc/pcu_sock.c: https://gerrit.osmocom.org/c/osmo-bsc/+/32633/comment/f472eca4_31189860 PS1, Line 64: struct pcu_sock_state *state > this pointer can also be made const, btw Ack -- To view, visit https://gerrit.osmocom.org/c/osmo-bsc/+/32633 To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings Gerrit-Project: osmo-bsc Gerrit-Branch: master Gerrit-Change-Id: I6d18ec0ad2bd6f71e0187ed70b03c3a2d0447f21 Gerrit-Change-Number: 32633 Gerrit-PatchSet: 1 Gerrit-Owner: msuraev <msuraev(a)sysmocom.de> Gerrit-Reviewer: Jenkins Builder Gerrit-Reviewer: fixeria <vyanitskiy(a)sysmocom.de> Gerrit-Reviewer: pespin <pespin(a)sysmocom.de> Gerrit-Attention: fixeria <vyanitskiy(a)sysmocom.de> Gerrit-Comment-Date: Thu, 11 May 2023 18:19:18 +0000 Gerrit-HasComments: Yes Gerrit-Has-Labels: No Comment-In-Reply-To: fixeria <vyanitskiy(a)sysmocom.de> Gerrit-MessageType: comment
1 0
0 0
[S] Change in osmo-hnbgw[master]: hnbgw: put copyright into define
by neels 11 May '23

11 May '23
neels has submitted this change. ( https://gerrit.osmocom.org/c/osmo-hnbgw/+/32679 ) Change subject: hnbgw: put copyright into define ...................................................................... hnbgw: put copyright into define Fix the following compile error, seen on ubuntu 18.04 with GCC 7.5.0, opensuse 15.4 and our OE builds: hnbgw.c:549:15: error: initializer element is not constant .copyright = hnbgw_copyright, ^~~~~~~~~~~~~~~ Fixes: 04844415 ("move main() to separate file") Change-Id: I13b2569a369724e0298b064a0876b95d6dafd9d0 --- M src/osmo-hnbgw/hnbgw.c 1 file changed, 25 insertions(+), 8 deletions(-) Approvals: Jenkins Builder: Verified laforge: Looks good to me, but someone else must approve neels: Looks good to me, approved diff --git a/src/osmo-hnbgw/hnbgw.c b/src/osmo-hnbgw/hnbgw.c index 8876580..6bf7b3f 100644 --- a/src/osmo-hnbgw/hnbgw.c +++ b/src/osmo-hnbgw/hnbgw.c @@ -491,13 +491,13 @@ return ranap_msg; } -static const char * const hnbgw_copyright = - "OsmoHNBGW - Osmocom Home Node B Gateway implementation\r\n" - "Copyright (C) 2016-2023 by sysmocom s.f.m.c. GmbH <info(a)sysmocom.de>\r\n" - "Contributions by Daniel Willmann, Harald Welte, Neels Hofmeyr\r\n" - "License AGPLv3+: GNU AGPL version 3 or later <http://gnu.org/licenses/agpl-3.0.html>\r\n" - "This is free software: you are free to change and redistribute it.\r\n" - "There is NO WARRANTY, to the extent permitted by law.\r\n"; +#define HNBGW_COPYRIGHT \ + "OsmoHNBGW - Osmocom Home Node B Gateway implementation\r\n" \ + "Copyright (C) 2016-2023 by sysmocom s.f.m.c. GmbH <info(a)sysmocom.de>\r\n" \ + "Contributions by Daniel Willmann, Harald Welte, Neels Hofmeyr\r\n" \ + "License AGPLv3+: GNU AGPL version 3 or later <http://gnu.org/licenses/agpl-3.0.html>\r\n" \ + "This is free software: you are free to change and redistribute it.\r\n" \ + "There is NO WARRANTY, to the extent permitted by law.\r\n" static const struct log_info_cat hnbgw_log_cat[] = { [DMAIN] = { @@ -546,5 +546,5 @@ .name = "OsmoHNBGW", .version = PACKAGE_VERSION, .go_parent_cb = hnbgw_vty_go_parent, - .copyright = hnbgw_copyright, + .copyright = HNBGW_COPYRIGHT, }; -- To view, visit https://gerrit.osmocom.org/c/osmo-hnbgw/+/32679 To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings Gerrit-Project: osmo-hnbgw Gerrit-Branch: master Gerrit-Change-Id: I13b2569a369724e0298b064a0876b95d6dafd9d0 Gerrit-Change-Number: 32679 Gerrit-PatchSet: 1 Gerrit-Owner: osmith <osmith(a)sysmocom.de> Gerrit-Reviewer: Jenkins Builder Gerrit-Reviewer: daniel <dwillmann(a)sysmocom.de> Gerrit-Reviewer: fixeria <vyanitskiy(a)sysmocom.de> Gerrit-Reviewer: laforge <laforge(a)osmocom.org> Gerrit-Reviewer: neels <nhofmeyr(a)sysmocom.de> Gerrit-MessageType: merged
1 0
0 0
  • ← Newer
  • 1
  • ...
  • 176
  • 177
  • 178
  • 179
  • 180
  • 181
  • 182
  • ...
  • 259
  • Older →

HyperKitty Powered by HyperKitty version 1.3.12.