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 -----
  • 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

January 2024

  • 1 participants
  • 1559 discussions
[M] Change in ...osmo-epdg[master]: Split auth_handler module into SWm files for ePDG and AAA Server
by pespin 26 Jan '24

26 Jan '24
pespin has posted comments on this change. ( https://gerrit.osmocom.org/c/erlang/osmo-epdg/+/35689?usp=email ) Change subject: Split auth_handler module into SWm files for ePDG and AAA Server ...................................................................... Patch Set 1: Code-Review+2 -- To view, visit https://gerrit.osmocom.org/c/erlang/osmo-epdg/+/35689?usp=email To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings Gerrit-Project: erlang/osmo-epdg Gerrit-Branch: master Gerrit-Change-Id: Ieb925445fb0cf45a58439fd0c4cd9e4d779a0a79 Gerrit-Change-Number: 35689 Gerrit-PatchSet: 1 Gerrit-Owner: pespin <pespin(a)sysmocom.de> Gerrit-Reviewer: Jenkins Builder Gerrit-Reviewer: laforge <laforge(a)osmocom.org> Gerrit-Reviewer: pespin <pespin(a)sysmocom.de> Gerrit-Comment-Date: Fri, 26 Jan 2024 14:45:19 +0000 Gerrit-HasComments: No Gerrit-Has-Labels: Yes Gerrit-MessageType: comment
1 0
0 0
[S] Change in ...osmo-epdg[master]: Rename s/epdg_diameter_swx/aaa_diameter_swx
by pespin 26 Jan '24

26 Jan '24
pespin has posted comments on this change. ( https://gerrit.osmocom.org/c/erlang/osmo-epdg/+/35688?usp=email ) Change subject: Rename s/epdg_diameter_swx/aaa_diameter_swx ...................................................................... Patch Set 1: Code-Review+2 -- To view, visit https://gerrit.osmocom.org/c/erlang/osmo-epdg/+/35688?usp=email To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings Gerrit-Project: erlang/osmo-epdg Gerrit-Branch: master Gerrit-Change-Id: Ie6a056bb8616fcda262f285241d38ba26e47f184 Gerrit-Change-Number: 35688 Gerrit-PatchSet: 1 Gerrit-Owner: pespin <pespin(a)sysmocom.de> Gerrit-Reviewer: Jenkins Builder Gerrit-Reviewer: laforge <laforge(a)osmocom.org> Gerrit-Reviewer: pespin <pespin(a)sysmocom.de> Gerrit-Comment-Date: Fri, 26 Jan 2024 14:45:13 +0000 Gerrit-HasComments: No Gerrit-Has-Labels: Yes Gerrit-MessageType: comment
1 0
0 0
[S] Change in ...osmo-epdg[master]: s6b: Answer Diameter STR with STA
by pespin 26 Jan '24

26 Jan '24
pespin has posted comments on this change. ( https://gerrit.osmocom.org/c/erlang/osmo-epdg/+/35687?usp=email ) Change subject: s6b: Answer Diameter STR with STA ...................................................................... Patch Set 1: Code-Review+2 -- To view, visit https://gerrit.osmocom.org/c/erlang/osmo-epdg/+/35687?usp=email To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings Gerrit-Project: erlang/osmo-epdg Gerrit-Branch: master Gerrit-Change-Id: I34f803c1f772bab9b267e4eaad7146e7b1ac2894 Gerrit-Change-Number: 35687 Gerrit-PatchSet: 1 Gerrit-Owner: pespin <pespin(a)sysmocom.de> Gerrit-Reviewer: Jenkins Builder Gerrit-Reviewer: laforge <laforge(a)osmocom.org> Gerrit-Reviewer: pespin <pespin(a)sysmocom.de> Gerrit-Comment-Date: Fri, 26 Jan 2024 14:45:09 +0000 Gerrit-HasComments: No Gerrit-Has-Labels: Yes Gerrit-MessageType: comment
1 0
0 0
[S] Change in ...osmo-epdg[master]: Rename s/ue_fsm/epdg_ue_fsm/g
by pespin 26 Jan '24

26 Jan '24
Attention is currently required from: lynxis lazus. pespin has posted comments on this change. ( https://gerrit.osmocom.org/c/erlang/osmo-epdg/+/35686?usp=email ) Change subject: Rename s/ue_fsm/epdg_ue_fsm/g ...................................................................... Patch Set 1: Code-Review+2 -- To view, visit https://gerrit.osmocom.org/c/erlang/osmo-epdg/+/35686?usp=email To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings Gerrit-Project: erlang/osmo-epdg Gerrit-Branch: master Gerrit-Change-Id: If0852f4aedd0fb0cb9bf6cfcf77f00acd4a3fcbf Gerrit-Change-Number: 35686 Gerrit-PatchSet: 1 Gerrit-Owner: pespin <pespin(a)sysmocom.de> Gerrit-Reviewer: Jenkins Builder Gerrit-Reviewer: laforge <laforge(a)osmocom.org> Gerrit-Reviewer: lynxis lazus <lynxis(a)fe80.eu> Gerrit-Reviewer: pespin <pespin(a)sysmocom.de> Gerrit-Attention: lynxis lazus <lynxis(a)fe80.eu> Gerrit-Comment-Date: Fri, 26 Jan 2024 14:45:07 +0000 Gerrit-HasComments: No Gerrit-Has-Labels: Yes Gerrit-MessageType: comment
1 0
0 0
[S] Change in osmocom-bb[master]: mobile: VTY: disable DATA_CALL_TR_V34_9600 (not supported)
by fixeria 26 Jan '24

26 Jan '24
fixeria has submitted this change. ( https://gerrit.osmocom.org/c/osmocom-bb/+/35694?usp=email ) Change subject: mobile: VTY: disable DATA_CALL_TR_V34_9600 (not supported) ...................................................................... mobile: VTY: disable DATA_CALL_TR_V34_9600 (not supported) We cannot initiate V.34 data calls because gsm48_encode_bearer_cap() does not support octet 6d. This variant should not be selectable. Change-Id: Ibafb9a693654672fb9a6abf665c500a27c87bf22 Related: OS#4396, OS#6344 --- M src/host/layer23/src/mobile/mnccms.c M src/host/layer23/src/mobile/vty_interface.c 2 files changed, 19 insertions(+), 2 deletions(-) Approvals: jolly: Looks good to me, but someone else must approve pespin: Looks good to me, but someone else must approve Jenkins Builder: Verified fixeria: Looks good to me, approved diff --git a/src/host/layer23/src/mobile/mnccms.c b/src/host/layer23/src/mobile/mnccms.c index 95d7f0d..2a4989d 100644 --- a/src/host/layer23/src/mobile/mnccms.c +++ b/src/host/layer23/src/mobile/mnccms.c @@ -244,7 +244,10 @@ [DATA_CALL_TR_V34_9600] = { .ir = GSM48_BCAP_IR_16k, .ur = GSM48_BCAP_UR_9600, - .mt = GSM48_BCAP_MT_V34, /* XXX */ + .mt = GSM48_BCAP_MT_V32, + /* (Octet 6c) Modem type: According to ITU-T Rec. V.32 + * (Octet 6d) Other modem type: According to ITU-T Rec. V.34 (2) + * TODO: gsm48_encode_bearer_cap() does not support octet 6d */ }, #endif [DATA_CALL_TR_V110_300] = { diff --git a/src/host/layer23/src/mobile/vty_interface.c b/src/host/layer23/src/mobile/vty_interface.c index edff584..7b9a199 100644 --- a/src/host/layer23/src/mobile/vty_interface.c +++ b/src/host/layer23/src/mobile/vty_interface.c @@ -656,8 +656,9 @@ { DATA_CALL_TR_V26ter_2400, "2400 bps (V.26ter)" }, { DATA_CALL_TR_V32_4800, "4800 bps (V.32)" }, { DATA_CALL_TR_V32_9600, "9600 bps (V.32)" }, - { DATA_CALL_TR_V34_9600, "9600 bps (V.34)" }, #if 0 + /* TODO: V.34 is not supported, see notes in bcap_data_set[] */ + { DATA_CALL_TR_V34_9600, "9600 bps (V.34)" }, /* TODO: rates below 2400 bps are not supported */ { DATA_CALL_TR_V110_300, "300 bps (V.110)" }, { DATA_CALL_TR_V110_1200, "1200 bps (V.110)" }, -- To view, visit https://gerrit.osmocom.org/c/osmocom-bb/+/35694?usp=email To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings Gerrit-Project: osmocom-bb Gerrit-Branch: master Gerrit-Change-Id: Ibafb9a693654672fb9a6abf665c500a27c87bf22 Gerrit-Change-Number: 35694 Gerrit-PatchSet: 2 Gerrit-Owner: fixeria <vyanitskiy(a)sysmocom.de> Gerrit-Reviewer: Jenkins Builder Gerrit-Reviewer: fixeria <vyanitskiy(a)sysmocom.de> Gerrit-Reviewer: jolly <andreas(a)eversberg.eu> Gerrit-Reviewer: pespin <pespin(a)sysmocom.de> Gerrit-MessageType: merged
1 0
0 0
[M] Change in osmocom-bb[master]: mobile: properly handle different TRAFFIC.{ind,req} formats for CSD
by fixeria 26 Jan '24

26 Jan '24
fixeria has submitted this change. ( https://gerrit.osmocom.org/c/osmocom-bb/+/35695?usp=email ) Change subject: mobile: properly handle different TRAFFIC.{ind,req} formats for CSD ...................................................................... mobile: properly handle different TRAFFIC.{ind,req} formats for CSD So far we supported the Texas Instruments format (TCH_DATA_IOF_TI), which is used by Calypso based phones (e.g. Motorola C1xx), but not the format that trxcon speaks/understands (TCH_DATA_IOF_OSMO). Change-Id: Ib17e800e91ad536db53aa55661076089f0ce34b0 Related: OS#4396 --- M src/host/layer23/src/mobile/tch_data.c 1 file changed, 44 insertions(+), 16 deletions(-) Approvals: Jenkins Builder: Verified fixeria: Looks good to me, approved jolly: Looks good to me, but someone else must approve pespin: Looks good to me, but someone else must approve diff --git a/src/host/layer23/src/mobile/tch_data.c b/src/host/layer23/src/mobile/tch_data.c index 451f267..06df85f 100644 --- a/src/host/layer23/src/mobile/tch_data.c +++ b/src/host/layer23/src/mobile/tch_data.c @@ -290,9 +290,7 @@ const struct gsm48_rr_cd *cd = &ms->rrlayer.cd_now; const struct csd_v110_frame_desc *desc; ubit_t data[4 * 60]; - - if (msgb_l3len(msg) < 30) - return -EINVAL; + size_t data_len; if ((cd->chan_nr & RSL_CHAN_NR_MASK) == RSL_CHAN_Bm_ACCHs) desc = &csd_v110_lchan_desc[cd->mode].fr; @@ -301,18 +299,26 @@ if (OSMO_UNLIKELY(desc->num_blocks == 0)) return -ENOTSUP; + data_len = desc->num_blocks * desc->num_bits; + OSMO_ASSERT(sizeof(data) >= data_len); + switch (ms->settings.tch_data.io_format) { case TCH_DATA_IOF_OSMO: + /* trxcon emits raw bits from the convolutional decoder */ + if (OSMO_UNLIKELY(msgb_l3len(msg) != data_len)) + return -EINVAL; + memcpy(&data[0], msgb_l3(msg), msgb_l3len(msg)); break; case TCH_DATA_IOF_TI: - /* the layer1 firmware emits frames with swapped words (LE ordering) */ + /* the layer1 firmware emits packed bits (LE ordering) */ + if (OSMO_UNLIKELY(msgb_l3len(msg) < data_len / 8)) + return -EINVAL; + /* ... with swapped words (LE ordering) */ swap_words(msgb_l3(msg), msgb_l3len(msg)); + osmo_pbit2ubit_ext(data, 0, msgb_l3(msg), 0, data_len, 1); break; } - /* unpack packed bits (MSB goes first) */ - osmo_pbit2ubit_ext(data, 0, msgb_l3(msg), 0, sizeof(data), 1); - for (unsigned int i = 0; i < desc->num_blocks; i++) { struct osmo_v110_decoded_frame df; @@ -340,6 +346,7 @@ const struct csd_v110_frame_desc *desc; ubit_t data[60 * 4]; struct msgb *nmsg; + size_t data_len; if ((cd->chan_nr & RSL_CHAN_NR_MASK) == RSL_CHAN_Bm_ACCHs) desc = &csd_v110_lchan_desc[cd->mode].fr; @@ -348,6 +355,9 @@ if (OSMO_UNLIKELY(desc->num_blocks == 0)) return -ENOTSUP; + data_len = desc->num_blocks * desc->num_bits; + OSMO_ASSERT(sizeof(data) >= data_len); + for (unsigned int i = 0; i < desc->num_blocks; i++) { struct osmo_v110_decoded_frame df; @@ -368,19 +378,23 @@ osmo_csd_3k6_encode_frame(&data[i * 36], 36, &df); } - nmsg = msgb_alloc_headroom(33 + 64, 64, __func__); - OSMO_ASSERT(nmsg != NULL); - - nmsg->l2h = msgb_put(nmsg, 33); /* XXX: proper size */ - - /* pack unpacked bits (MSB goes first) */ - osmo_ubit2pbit_ext(msgb_l2(nmsg), 0, &data[0], 0, sizeof(data), 1); - switch (ms->settings.tch_data.io_format) { case TCH_DATA_IOF_OSMO: + /* trxcon operates on unpacked bits */ + nmsg = msgb_alloc_headroom(data_len + 64, 64, __func__); + if (nmsg == NULL) + return -ENOMEM; + memcpy(msgb_put(nmsg, data_len), &data[0], data_len); break; case TCH_DATA_IOF_TI: - /* the layer1 firmware expects frames with swapped words (LE ordering) */ + /* XXX: the layer1 firmware expects TRAFFIC.req with len=33 bytes */ + nmsg = msgb_alloc_headroom(33 + 64, 64, __func__); + if (nmsg == NULL) + return -ENOMEM; + nmsg->l2h = msgb_put(nmsg, 33); + /* the layer1 firmware expects packed bits (LE ordering) */ + osmo_ubit2pbit_ext(msgb_l2(nmsg), 0, &data[0], 0, sizeof(data), 1); + /* ... with swapped words (LE ordering) */ swap_words(msgb_l2(nmsg), msgb_l2len(nmsg)); break; } -- To view, visit https://gerrit.osmocom.org/c/osmocom-bb/+/35695?usp=email To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings Gerrit-Project: osmocom-bb Gerrit-Branch: master Gerrit-Change-Id: Ib17e800e91ad536db53aa55661076089f0ce34b0 Gerrit-Change-Number: 35695 Gerrit-PatchSet: 2 Gerrit-Owner: fixeria <vyanitskiy(a)sysmocom.de> Gerrit-Reviewer: Jenkins Builder Gerrit-Reviewer: fixeria <vyanitskiy(a)sysmocom.de> Gerrit-Reviewer: jolly <andreas(a)eversberg.eu> Gerrit-Reviewer: pespin <pespin(a)sysmocom.de> Gerrit-MessageType: merged
1 0
0 0
[M] Change in osmocom-bb[master]: mobile: fix rate adaption checking for MO/MT CSD calls
by fixeria 26 Jan '24

26 Jan '24
fixeria has submitted this change. ( https://gerrit.osmocom.org/c/osmocom-bb/+/35696?usp=email ) Change subject: mobile: fix rate adaption checking for MO/MT CSD calls ...................................................................... mobile: fix rate adaption checking for MO/MT CSD calls Currently we unconditionally expect the rate adaption (octet 5) in the Bearer Capability IE to be GSM48_BCAP_RA_V110_X30. This is correct for UDI (GSM48_BCAP_ITCAP_UNR_DIG_INF), but not for 3.1 kHz audio (GSM48_BCAP_ITCAP_3k1_AUDIO) and fax (GSM48_BCAP_ITCAP_FAX_G3) calls. For the later two it should be GSM48_BCAP_RA_NONE. Change-Id: I70d36b3540ed2469068e050809a17ed07b434ad7 Related: OS#4396 --- M src/host/layer23/src/mobile/mnccms.c M src/host/layer23/src/mobile/tch_data.c 2 files changed, 50 insertions(+), 11 deletions(-) Approvals: pespin: Looks good to me, but someone else must approve jolly: Looks good to me, but someone else must approve Jenkins Builder: Verified fixeria: Looks good to me, approved diff --git a/src/host/layer23/src/mobile/mnccms.c b/src/host/layer23/src/mobile/mnccms.c index 2a4989d..67cf5a7 100644 --- a/src/host/layer23/src/mobile/mnccms.c +++ b/src/host/layer23/src/mobile/mnccms.c @@ -414,12 +414,28 @@ static int mncc_handle_bcap_data(const struct gsm_mncc_bearer_cap *bcap, const struct gsm_settings *set) { - if (bcap->data.rate_adaption != GSM48_BCAP_RA_V110_X30) { - LOGP(DMNCC, LOGL_ERROR, - "%s(): Rate adaption (octet 5) 0x%02x is not supported\n", - __func__, bcap->data.rate_adaption); - return -ENOTSUP; + switch (bcap->transfer) { + case GSM48_BCAP_ITCAP_UNR_DIG_INF: + if (bcap->data.rate_adaption != GSM48_BCAP_RA_V110_X30) { + LOGP(DMNCC, LOGL_ERROR, + "%s(): Rate adaption (octet 5) 0x%02x is not supported\n", + __func__, bcap->data.rate_adaption); + return -ENOTSUP; + } + break; + case GSM48_BCAP_ITCAP_3k1_AUDIO: + case GSM48_BCAP_ITCAP_FAX_G3: + if (bcap->data.rate_adaption != GSM48_BCAP_RA_NONE) { + LOGP(DMNCC, LOGL_ERROR, + "%s(): Rate adaption (octet 5) 0x%02x was expected to be NONE\n", + __func__, bcap->data.rate_adaption); + return -ENOTSUP; + } + break; + default: + break; } + if (bcap->data.sig_access != GSM48_BCAP_SA_I440_I450) { LOGP(DMNCC, LOGL_ERROR, "%s(): Signalling access protocol (octet 5) 0x%02x is not supported\n", diff --git a/src/host/layer23/src/mobile/tch_data.c b/src/host/layer23/src/mobile/tch_data.c index 06df85f..c93c828 100644 --- a/src/host/layer23/src/mobile/tch_data.c +++ b/src/host/layer23/src/mobile/tch_data.c @@ -426,8 +426,21 @@ switch (bcap->transfer) { case GSM48_BCAP_ITCAP_UNR_DIG_INF: + if (bcap->data.rate_adaption != GSM48_BCAP_RA_V110_X30) { + LOGP(DCSD, LOGL_ERROR, + "%s(): Rate adaption (octet 5) 0x%02x is not supported\n", + __func__, bcap->data.rate_adaption); + return -ENOTSUP; + } + break; case GSM48_BCAP_ITCAP_3k1_AUDIO: case GSM48_BCAP_ITCAP_FAX_G3: + if (bcap->data.rate_adaption != GSM48_BCAP_RA_NONE) { + LOGP(DCSD, LOGL_ERROR, + "%s(): Rate adaption (octet 5) 0x%02x was expected to be NONE\n", + __func__, bcap->data.rate_adaption); + return -ENOTSUP; + } break; default: LOGP(DCSD, LOGL_ERROR, @@ -436,12 +449,6 @@ return -ENOTSUP; } - if (bcap->data.rate_adaption != GSM48_BCAP_RA_V110_X30) { - LOGP(DCSD, LOGL_ERROR, - "%s(): Rate adaption (octet 5) 0x%02x is not supported\n", - __func__, bcap->data.rate_adaption); - return -ENOTSUP; - } if (bcap->data.sig_access != GSM48_BCAP_SA_I440_I450) { LOGP(DCSD, LOGL_ERROR, "%s(): Signalling access protocol (octet 5) 0x%02x is not supported\n", -- To view, visit https://gerrit.osmocom.org/c/osmocom-bb/+/35696?usp=email To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings Gerrit-Project: osmocom-bb Gerrit-Branch: master Gerrit-Change-Id: I70d36b3540ed2469068e050809a17ed07b434ad7 Gerrit-Change-Number: 35696 Gerrit-PatchSet: 2 Gerrit-Owner: fixeria <vyanitskiy(a)sysmocom.de> Gerrit-Reviewer: Jenkins Builder Gerrit-Reviewer: fixeria <vyanitskiy(a)sysmocom.de> Gerrit-Reviewer: jolly <andreas(a)eversberg.eu> Gerrit-Reviewer: pespin <pespin(a)sysmocom.de> Gerrit-MessageType: merged
1 0
0 0
[L] Change in osmocom-bb[master]: mobile: VTY: store/read data call params to/from config file
by fixeria 26 Jan '24

26 Jan '24
fixeria has submitted this change. ( https://gerrit.osmocom.org/c/osmocom-bb/+/35699?usp=email ) Change subject: mobile: VTY: store/read data call params to/from config file ...................................................................... mobile: VTY: store/read data call params to/from config file We already have VTY commands to configure data call parameters at run-time, but so far there was no way to save and restore them. This commit adds the respective commands to TCH_DATA_NODE. Change-Id: I4453f2e7e048b3f3ebb1727f6d26f018c792c92d Related: OS#4396 --- M doc/examples/mobile/default.cfg M src/host/layer23/src/mobile/vty_interface.c 2 files changed, 232 insertions(+), 105 deletions(-) Approvals: pespin: Looks good to me, but someone else must approve jolly: Looks good to me, but someone else must approve fixeria: Looks good to me, approved Jenkins Builder: Verified diff --git a/doc/examples/mobile/default.cfg b/doc/examples/mobile/default.cfg index ac756bb..3b46a85 100644 --- a/doc/examples/mobile/default.cfg +++ b/doc/examples/mobile/default.cfg @@ -65,6 +65,12 @@ io-handler unix-sock io-tch-format ti unix-socket /tmp/ms_data_1 + call-params type-rate 71 + call-params ce transparent + call-params async + call-params async nr-stop-bits 1 + call-params async nr-data-bits 8 + call-params async parity none tch-voice io-handler l1phy ! io-format ti diff --git a/src/host/layer23/src/mobile/vty_interface.c b/src/host/layer23/src/mobile/vty_interface.c index 7b9a199..b0457e3 100644 --- a/src/host/layer23/src/mobile/vty_interface.c +++ b/src/host/layer23/src/mobile/vty_interface.c @@ -644,6 +644,11 @@ CALL_PARAMS_CMD_DESC \ "Parameters for data calls\n" +#define CFG_TCH_DATA_CALL_PARAMS_CMD \ + "call-params" +#define CFG_TCH_DATA_CALL_PARAMS_CMD_DESC \ + "Parameters for data calls\n" + /* only supported rate/type ('<speed>' in AT+CBST) values are listed here */ static const struct value_string data_type_rate_descs[] = { #if 0 @@ -673,18 +678,33 @@ { 0, NULL } }; -static char *call_params_data_type_rate_cmd_string(void *ctx) +static void _data_type_rate_cmd_string(void *ctx, struct cmd_element *cmd) { const struct value_string *vs; char *string; - string = talloc_asprintf(ctx, CALL_PARAMS_DATA_CMD " type-rate ("); + string = talloc_asprintf(ctx, "%s type-rate (", cmd->string); for (vs = &data_type_rate_descs[0]; vs->value || vs->str; vs++) string = talloc_asprintf_append(string, "%u|", vs->value); string[strlen(string) - 1] = ')'; + cmd->string = string; +} - return string; +DEFUN(cfg_ms_tch_data_cp_type_rate, + cfg_ms_tch_data_cp_type_rate_cmd, + CFG_TCH_DATA_CALL_PARAMS_CMD /* generated */, + CFG_TCH_DATA_CALL_PARAMS_CMD_DESC /* generated */) +{ + struct osmocom_ms *ms = (struct osmocom_ms *)vty->index; + struct data_call_params *cp = &ms->settings.call_params.data; + int val; + + val = atoi(argv[0]); + OSMO_ASSERT(get_value_string_or_null(data_type_rate_descs, val) != NULL); + cp->type_rate = (enum data_call_type_rate)val; + + return CMD_SUCCESS; } DEFUN(call_params_data_type_rate, @@ -692,50 +712,36 @@ CALL_PARAMS_DATA_CMD /* generated */, CALL_PARAMS_DATA_CMD_DESC /* generated */) { - struct osmocom_ms *ms; - struct gsm_settings *set; - struct data_call_params *cp; - int val; - - ms = l23_vty_get_ms(argv[0], vty); - if (!ms) + vty->index = l23_vty_get_ms(argv[0], vty); + if (vty->index == NULL) return CMD_WARNING; - set = &ms->settings; - cp = &set->call_params.data; - val = atoi(argv[1]); - OSMO_ASSERT(get_value_string_or_null(data_type_rate_descs, val) != NULL); - cp->type_rate = (enum data_call_type_rate)val; - - return CMD_SUCCESS; + return cfg_ms_tch_data_cp_type_rate(self, vty, argc - 1, argv + 1); } -DEFUN(call_params_data_ce, - call_params_data_ce_cmd, - CALL_PARAMS_DATA_CMD " ce (transparent|non-transparent) [prefer]", - CALL_PARAMS_DATA_CMD_DESC - "Connection element (does not apply to FAX calls)\n" - "Transparent connection\n" - "Non-transparent connection (RLP)\n" - "Prefer the selected mode, but also accept other(s)\n") +#define CALL_PARAMS_CE_CMD \ + "ce (transparent|non-transparent) [prefer]" +#define CALL_PARAMS_CE_CMD_DESC \ + "Connection element (does not apply to FAX calls)\n" \ + "Transparent connection\n" \ + "Non-transparent connection (RLP)\n" \ + "Prefer the selected mode, but also accept other(s)\n" + +DEFUN(cfg_ms_tch_data_cp_ce, + cfg_ms_tch_data_cp_ce_cmd, + CFG_TCH_DATA_CALL_PARAMS_CMD " " CALL_PARAMS_CE_CMD, + CFG_TCH_DATA_CALL_PARAMS_CMD_DESC CALL_PARAMS_CE_CMD_DESC) { - struct osmocom_ms *ms; - struct gsm_settings *set; - struct data_call_params *cp; + struct osmocom_ms *ms = (struct osmocom_ms *)vty->index; + struct data_call_params *cp = &ms->settings.call_params.data; - ms = l23_vty_get_ms(argv[0], vty); - if (!ms) - return CMD_WARNING; - set = &ms->settings; - cp = &set->call_params.data; - - if (!strcmp(argv[1], "transparent")) { - if (argc > 2) + if (!strcmp(argv[0], "transparent")) { + if (argc > 1) cp->transp = GSM48_BCAP_TR_TR_PREF; else cp->transp = GSM48_BCAP_TR_TRANSP; - } else if (!strcmp(argv[1], "non-transparent")) { - if (argc > 2) + } else if (!strcmp(argv[0], "non-transparent")) { + if (argc > 1) cp->transp = GSM48_BCAP_TR_RLP_PREF; else cp->transp = GSM48_BCAP_TR_RLP; @@ -746,76 +752,114 @@ return CMD_SUCCESS; } -DEFUN(call_params_data_sync_async, - call_params_data_sync_async_cmd, - CALL_PARAMS_DATA_CMD " (sync|async)", - CALL_PARAMS_DATA_CMD_DESC - "Synchronous connection (always used for FAX calls)\n" - "Asynchronous connection (does not apply to FAX calls)\n") +DEFUN(call_params_data_ce, + call_params_data_ce_cmd, + CALL_PARAMS_DATA_CMD " " CALL_PARAMS_CE_CMD, + CALL_PARAMS_DATA_CMD_DESC CALL_PARAMS_CE_CMD_DESC) { - struct osmocom_ms *ms; - struct gsm_settings *set; - struct data_call_params *cp; - - ms = l23_vty_get_ms(argv[0], vty); - if (!ms) + vty->index = l23_vty_get_ms(argv[0], vty); + if (vty->index == NULL) return CMD_WARNING; - set = &ms->settings; - cp = &set->call_params.data; - cp->is_async = (argv[1][0] == 'a'); + return cfg_ms_tch_data_cp_ce(self, vty, argc - 1, argv + 1); +} + +#define CALL_PARAMS_SYNC_ASYNC_CMD "(sync|async)" +#define CALL_PARAMS_SYNC_ASYNC_CMD_DESC \ + "Synchronous connection (always used for FAX calls)\n" \ + "Asynchronous connection (does not apply to FAX calls)\n" + +DEFUN(cfg_ms_tch_data_cp_sync_async, + cfg_ms_tch_data_cp_sync_async_cmd, + CFG_TCH_DATA_CALL_PARAMS_CMD " " CALL_PARAMS_SYNC_ASYNC_CMD, + CFG_TCH_DATA_CALL_PARAMS_CMD_DESC CALL_PARAMS_SYNC_ASYNC_CMD_DESC) +{ + struct osmocom_ms *ms = (struct osmocom_ms *)vty->index; + struct data_call_params *cp = &ms->settings.call_params.data; + + cp->is_async = (argv[0][0] == 'a'); return CMD_SUCCESS; } -#define CALL_PARAMS_DATA_ASYNC_CMD \ - CALL_PARAMS_DATA_CMD " async" -#define CALL_PARAMS_DATA_ASYNC_CMD_DESC \ - CALL_PARAMS_DATA_CMD_DESC \ +DEFUN(call_params_data_sync_async, + call_params_data_sync_async_cmd, + CALL_PARAMS_DATA_CMD " " CALL_PARAMS_SYNC_ASYNC_CMD, + CALL_PARAMS_DATA_CMD_DESC CALL_PARAMS_SYNC_ASYNC_CMD_DESC) +{ + vty->index = l23_vty_get_ms(argv[0], vty); + if (vty->index == NULL) + return CMD_WARNING; + + return cfg_ms_tch_data_cp_sync_async(self, vty, argc - 1, argv + 1); +} + +#define CALL_PARAMS_ASYNC_CMD "async" +#define CALL_PARAMS_ASYNC_CMD_DESC \ "Asynchronous connection params (does not apply to FAX calls)\n" +#define CALL_PARAMS_ASYNC_NR_STOP_BITS_CMD \ + CALL_PARAMS_ASYNC_CMD " nr-stop-bits <1-2>" +#define CALL_PARAMS_ASYNC_NR_STOP_BITS_CMD_DESC \ + CALL_PARAMS_ASYNC_CMD_DESC \ + "Number of stop bits (soft-UART config)\n" \ + "Number of stop bits (default: 1)\n" + +DEFUN(cfg_ms_tch_data_cp_async_nr_stop_bits, + cfg_ms_tch_data_cp_async_nr_stop_bits_cmd, + CFG_TCH_DATA_CALL_PARAMS_CMD " " CALL_PARAMS_ASYNC_NR_STOP_BITS_CMD, + CFG_TCH_DATA_CALL_PARAMS_CMD_DESC CALL_PARAMS_ASYNC_NR_STOP_BITS_CMD_DESC) +{ + struct osmocom_ms *ms = (struct osmocom_ms *)vty->index; + struct data_call_params *cp = &ms->settings.call_params.data; + + cp->nr_stop_bits = atoi(argv[0]); + + return CMD_SUCCESS; +} + DEFUN(call_params_data_async_nr_stop_bits, call_params_data_async_nr_stop_bits_cmd, - CALL_PARAMS_DATA_ASYNC_CMD " nr-stop-bits <1-2>", - CALL_PARAMS_DATA_ASYNC_CMD_DESC - "Number of stop bits (soft-UART config)\n" - "Number of stop bits (default: 1)\n") + CALL_PARAMS_DATA_CMD " " CALL_PARAMS_ASYNC_NR_STOP_BITS_CMD, + CALL_PARAMS_DATA_CMD_DESC CALL_PARAMS_ASYNC_NR_STOP_BITS_CMD_DESC) { - struct osmocom_ms *ms; - struct gsm_settings *set; - struct data_call_params *cp; - - ms = l23_vty_get_ms(argv[0], vty); - if (!ms) + vty->index = l23_vty_get_ms(argv[0], vty); + if (vty->index == NULL) return CMD_WARNING; - set = &ms->settings; - cp = &set->call_params.data; - cp->nr_stop_bits = atoi(argv[1]); + return cfg_ms_tch_data_cp_async_nr_stop_bits(self, vty, argc - 1, argv + 1); +} + +#define CALL_PARAMS_ASYNC_NR_DATA_BITS_CMD \ + CALL_PARAMS_ASYNC_CMD " nr-data-bits <7-8>" +#define CALL_PARAMS_ASYNC_NR_DATA_BITS_CMD_DESC \ + CALL_PARAMS_ASYNC_CMD_DESC \ + "Number of data bits (soft-UART config)\n" \ + "Number of data bits (default: 8)\n" + +DEFUN(cfg_ms_tch_data_cp_async_nr_data_bits, + cfg_ms_tch_data_cp_async_nr_data_bits_cmd, + CFG_TCH_DATA_CALL_PARAMS_CMD " " CALL_PARAMS_ASYNC_NR_DATA_BITS_CMD, + CFG_TCH_DATA_CALL_PARAMS_CMD_DESC CALL_PARAMS_ASYNC_NR_DATA_BITS_CMD_DESC) +{ + struct osmocom_ms *ms = (struct osmocom_ms *)vty->index; + struct data_call_params *cp = &ms->settings.call_params.data; + + cp->nr_data_bits = atoi(argv[0]); return CMD_SUCCESS; } DEFUN(call_params_data_async_nr_data_bits, call_params_data_async_nr_data_bits_cmd, - CALL_PARAMS_DATA_ASYNC_CMD " nr-data-bits <7-8>", - CALL_PARAMS_DATA_ASYNC_CMD_DESC - "Number of data bits (soft-UART config)\n" - "Number of data bits (default: 8)\n") + CALL_PARAMS_DATA_CMD " " CALL_PARAMS_ASYNC_NR_DATA_BITS_CMD, + CALL_PARAMS_DATA_CMD_DESC CALL_PARAMS_ASYNC_NR_DATA_BITS_CMD_DESC) { - struct osmocom_ms *ms; - struct gsm_settings *set; - struct data_call_params *cp; - - ms = l23_vty_get_ms(argv[0], vty); - if (!ms) + vty->index = l23_vty_get_ms(argv[0], vty); + if (vty->index == NULL) return CMD_WARNING; - set = &ms->settings; - cp = &set->call_params.data; - cp->nr_data_bits = atoi(argv[1]); - - return CMD_SUCCESS; + return cfg_ms_tch_data_cp_async_nr_data_bits(self, vty, argc - 1, argv + 1); } static const struct value_string async_parity_names[] = { @@ -836,29 +880,42 @@ { 0, NULL } }; -DEFUN(call_params_data_async_parity, - call_params_data_async_parity_cmd, - CALL_PARAMS_DATA_ASYNC_CMD /* generated */, - CALL_PARAMS_DATA_ASYNC_CMD_DESC /* generated */) +#define CALL_PARAMS_ASYNC_PARITY_CMD \ + CALL_PARAMS_ASYNC_CMD " parity" +#define CALL_PARAMS_ASYNC_PARITY_CMD_DESC \ + CALL_PARAMS_ASYNC_CMD_DESC \ + "Parity mode (soft-UART config)\n" + +DEFUN(cfg_ms_tch_data_cp_async_parity, + cfg_ms_tch_data_cp_async_parity_cmd, + CFG_TCH_DATA_CALL_PARAMS_CMD /* generated */, + CFG_TCH_DATA_CALL_PARAMS_CMD_DESC + CALL_PARAMS_ASYNC_PARITY_CMD_DESC /* generated */) { - struct osmocom_ms *ms; - struct gsm_settings *set; - struct data_call_params *cp; + struct osmocom_ms *ms = (struct osmocom_ms *)vty->index; + struct data_call_params *cp = &ms->settings.call_params.data; int val; - ms = l23_vty_get_ms(argv[0], vty); - if (!ms) - return CMD_WARNING; - set = &ms->settings; - cp = &set->call_params.data; - - val = get_string_value(async_parity_names, argv[1]); + val = get_string_value(async_parity_names, argv[0]); OSMO_ASSERT(val >= 0); /* should not happen */ cp->parity = (enum gsm48_bcap_parity)val; return CMD_SUCCESS; } +DEFUN(call_params_data_async_parity, + call_params_data_async_parity_cmd, + CALL_PARAMS_DATA_CMD /* generated */, + CALL_PARAMS_DATA_CMD_DESC + CALL_PARAMS_ASYNC_PARITY_CMD_DESC /* generated */) +{ + vty->index = l23_vty_get_ms(argv[0], vty); + if (vty->index == NULL) + return CMD_WARNING; + + return cfg_ms_tch_data_cp_async_parity(self, vty, argc - 1, argv + 1); +} + DEFUN(sms, sms_cmd, "sms MS_NAME NUMBER .LINE", "Send an SMS\nName of MS (see \"show ms\")\nPhone number to send SMS " "(Use digits '0123456789*#abc', and '+' to dial international)\n" @@ -1606,6 +1663,32 @@ set->tch_data.unix_socket_path, VTY_NEWLINE); } + vty_out(vty, " call-params type-rate %d%s", + (int)set->call_params.data.type_rate, VTY_NEWLINE); + switch (set->call_params.data.transp) { + case GSM48_BCAP_TR_TR_PREF: + vty_out(vty, " call-params ce transparent prefer%s", VTY_NEWLINE); + break; + case GSM48_BCAP_TR_TRANSP: + vty_out(vty, " call-params ce transparent%s", VTY_NEWLINE); + break; + case GSM48_BCAP_TR_RLP_PREF: + vty_out(vty, " call-params ce non-transparent prefer%s", VTY_NEWLINE); + break; + case GSM48_BCAP_TR_RLP: + vty_out(vty, " call-params ce non-transparent%s", VTY_NEWLINE); + break; + } + vty_out(vty, " call-params %s%s", + set->call_params.data.is_async ? "async" : "sync", VTY_NEWLINE); + vty_out(vty, " call-params async nr-stop-bits %u%s", + set->call_params.data.nr_stop_bits, VTY_NEWLINE); + vty_out(vty, " call-params async nr-data-bits %u%s", + set->call_params.data.nr_data_bits, VTY_NEWLINE); + vty_out(vty, " call-params async parity %s%s", + get_value_string(async_parity_names, set->call_params.data.parity), + VTY_NEWLINE); + if (ms->lua_script) vty_out(vty, " lua-script %s%s", ms->lua_script, VTY_NEWLINE); @@ -2869,9 +2952,16 @@ { int rc; - call_params_data_type_rate_cmd.string = - call_params_data_type_rate_cmd_string(NULL); + _data_type_rate_cmd_string(NULL, &cfg_ms_tch_data_cp_type_rate_cmd); + _data_type_rate_cmd_string(NULL, &call_params_data_type_rate_cmd); + cfg_ms_tch_data_cp_type_rate_cmd.doc = + vty_cmd_string_from_valstr(NULL, + data_type_rate_descs, + CFG_TCH_DATA_CALL_PARAMS_CMD_DESC + "Type and rate (values like in AT+CBST; " + "see 3GPP TS 27.007, section 6.7)\n", + "\n", "", 0); call_params_data_type_rate_cmd.doc = vty_cmd_string_from_valstr(NULL, data_type_rate_descs, @@ -2880,17 +2970,28 @@ "see 3GPP TS 27.007, section 6.7)\n", "\n", "", 0); + cfg_ms_tch_data_cp_async_parity_cmd.string = + vty_cmd_string_from_valstr(NULL, + async_parity_names, + CFG_TCH_DATA_CALL_PARAMS_CMD " " + CALL_PARAMS_ASYNC_PARITY_CMD " (", + "|", ")", 0); call_params_data_async_parity_cmd.string = vty_cmd_string_from_valstr(NULL, async_parity_names, - CALL_PARAMS_DATA_ASYNC_CMD - " parity (", "|", ")", 0); + CALL_PARAMS_DATA_CMD " " + CALL_PARAMS_ASYNC_PARITY_CMD " (", + "|", ")", 0); + cfg_ms_tch_data_cp_async_parity_cmd.doc = + vty_cmd_string_from_valstr(NULL, + async_parity_descs, + cfg_ms_tch_data_cp_async_parity_cmd.doc, + "\n", "", 0); call_params_data_async_parity_cmd.doc = vty_cmd_string_from_valstr(NULL, async_parity_descs, - CALL_PARAMS_DATA_ASYNC_CMD_DESC - "Parity mode (soft-UART config)\n", + call_params_data_async_parity_cmd.doc, "\n", "", 0); if ((rc = l23_vty_init(config_write, l23_vty_signal_cb)) < 0) @@ -3083,6 +3184,12 @@ install_element(TCH_DATA_NODE, &cfg_ms_tch_data_no_io_handler_cmd); install_element(TCH_DATA_NODE, &cfg_ms_tch_data_io_tch_format_cmd); install_element(TCH_DATA_NODE, &cfg_ms_tch_data_unix_sock_cmd); + install_element(TCH_DATA_NODE, &cfg_ms_tch_data_cp_type_rate_cmd); + install_element(TCH_DATA_NODE, &cfg_ms_tch_data_cp_ce_cmd); + install_element(TCH_DATA_NODE, &cfg_ms_tch_data_cp_sync_async_cmd); + install_element(TCH_DATA_NODE, &cfg_ms_tch_data_cp_async_nr_stop_bits_cmd); + install_element(TCH_DATA_NODE, &cfg_ms_tch_data_cp_async_nr_data_bits_cmd); + install_element(TCH_DATA_NODE, &cfg_ms_tch_data_cp_async_parity_cmd); return 0; } -- To view, visit https://gerrit.osmocom.org/c/osmocom-bb/+/35699?usp=email To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings Gerrit-Project: osmocom-bb Gerrit-Branch: master Gerrit-Change-Id: I4453f2e7e048b3f3ebb1727f6d26f018c792c92d Gerrit-Change-Number: 35699 Gerrit-PatchSet: 2 Gerrit-Owner: fixeria <vyanitskiy(a)sysmocom.de> Gerrit-Reviewer: Jenkins Builder Gerrit-Reviewer: fixeria <vyanitskiy(a)sysmocom.de> Gerrit-Reviewer: jolly <andreas(a)eversberg.eu> Gerrit-Reviewer: pespin <pespin(a)sysmocom.de> Gerrit-MessageType: merged
1 0
0 0
[L] Change in osmocom-bb[master]: mobile: VTY: store/read data call params to/from config file
by fixeria 26 Jan '24

26 Jan '24
Attention is currently required from: jolly. fixeria has posted comments on this change. ( https://gerrit.osmocom.org/c/osmocom-bb/+/35699?usp=email ) Change subject: mobile: VTY: store/read data call params to/from config file ...................................................................... Patch Set 1: Code-Review+2 (1 comment) File src/host/layer23/src/mobile/vty_interface.c: https://gerrit.osmocom.org/c/osmocom-bb/+/35699/comment/63c0df80_1b5f8f24 PS1, Line 1683: set->call_params.data.is_async > In case of "async", uart parameters can be omitted. But this is only a cosmetic issue. I prefer printing these params even for `sync`, so that we don't loose user preferences when saving file and then using it next time. -- To view, visit https://gerrit.osmocom.org/c/osmocom-bb/+/35699?usp=email To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings Gerrit-Project: osmocom-bb Gerrit-Branch: master Gerrit-Change-Id: I4453f2e7e048b3f3ebb1727f6d26f018c792c92d Gerrit-Change-Number: 35699 Gerrit-PatchSet: 1 Gerrit-Owner: fixeria <vyanitskiy(a)sysmocom.de> Gerrit-Reviewer: Jenkins Builder Gerrit-Reviewer: fixeria <vyanitskiy(a)sysmocom.de> Gerrit-Reviewer: jolly <andreas(a)eversberg.eu> Gerrit-Reviewer: pespin <pespin(a)sysmocom.de> Gerrit-Attention: jolly <andreas(a)eversberg.eu> Gerrit-Comment-Date: Fri, 26 Jan 2024 14:29:39 +0000 Gerrit-HasComments: Yes Gerrit-Has-Labels: Yes Comment-In-Reply-To: jolly <andreas(a)eversberg.eu> Gerrit-MessageType: comment
1 0
0 0
[M] Change in osmocom-bb[master]: mobile: properly handle different TRAFFIC.{ind,req} formats for CSD
by fixeria 26 Jan '24

26 Jan '24
fixeria has posted comments on this change. ( https://gerrit.osmocom.org/c/osmocom-bb/+/35695?usp=email ) Change subject: mobile: properly handle different TRAFFIC.{ind,req} formats for CSD ...................................................................... Patch Set 1: Code-Review+2 -- To view, visit https://gerrit.osmocom.org/c/osmocom-bb/+/35695?usp=email To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings Gerrit-Project: osmocom-bb Gerrit-Branch: master Gerrit-Change-Id: Ib17e800e91ad536db53aa55661076089f0ce34b0 Gerrit-Change-Number: 35695 Gerrit-PatchSet: 1 Gerrit-Owner: fixeria <vyanitskiy(a)sysmocom.de> Gerrit-Reviewer: Jenkins Builder Gerrit-Reviewer: fixeria <vyanitskiy(a)sysmocom.de> Gerrit-Reviewer: jolly <andreas(a)eversberg.eu> Gerrit-Reviewer: pespin <pespin(a)sysmocom.de> Gerrit-Comment-Date: Fri, 26 Jan 2024 14:23:48 +0000 Gerrit-HasComments: No Gerrit-Has-Labels: Yes Gerrit-MessageType: comment
1 0
0 0
  • ← Newer
  • 1
  • ...
  • 27
  • 28
  • 29
  • 30
  • 31
  • 32
  • 33
  • ...
  • 156
  • Older →

HyperKitty Powered by HyperKitty version 1.3.12.