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

November 2023

  • 1 participants
  • 1508 discussions
[M] Change in pysim[master]: transport/pcsc: Allow opening PC/SC readers by a regex of their name
by fixeria 04 Nov '23

04 Nov '23
Attention is currently required from: dexter, laforge. fixeria has posted comments on this change. ( https://gerrit.osmocom.org/c/pysim/+/34960?usp=email ) Change subject: transport/pcsc: Allow opening PC/SC readers by a regex of their name ...................................................................... Patch Set 2: (2 comments) File pySim/transport/pcsc.py: https://gerrit.osmocom.org/c/pysim/+/34960/comment/aaf1e628_331b7156 PS2, Line 50: is_a_number(reader_number): Looks like you always expect `reader_number` to be a string: either with the reader number or a regexp. But why does the type is `Union[int, str]` then? Looking at the type I would expect checking like `if type(reader_number) is int`... https://gerrit.osmocom.org/c/pysim/+/34960/comment/914df167_f35cc43e PS2, Line 132: '--pcsc-device (just a suggestion) maybe keep this argument unchanged (and keep it as `int`), and add another one like `--pcsc-device-regexp` (`type=str`)? -- To view, visit https://gerrit.osmocom.org/c/pysim/+/34960?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: I983f19c6741904c1adf27749c9801b44a03a5d78 Gerrit-Change-Number: 34960 Gerrit-PatchSet: 2 Gerrit-Owner: laforge <laforge(a)osmocom.org> Gerrit-Reviewer: Jenkins Builder Gerrit-Reviewer: dexter <pmaier(a)sysmocom.de> Gerrit-Reviewer: fixeria <vyanitskiy(a)sysmocom.de> Gerrit-Attention: laforge <laforge(a)osmocom.org> Gerrit-Attention: dexter <pmaier(a)sysmocom.de> Gerrit-Comment-Date: Sat, 04 Nov 2023 12:01:06 +0000 Gerrit-HasComments: Yes Gerrit-Has-Labels: No Gerrit-MessageType: comment
1 0
0 0
[M] Change in pysim[master]: Use construct 'Flag' instead of 'Bit' for type descriptions
by fixeria 04 Nov '23

04 Nov '23
Attention is currently required from: dexter, laforge. fixeria has posted comments on this change. ( https://gerrit.osmocom.org/c/pysim/+/34957?usp=email ) Change subject: Use construct 'Flag' instead of 'Bit' for type descriptions ...................................................................... Patch Set 3: Code-Review+2 -- To view, visit https://gerrit.osmocom.org/c/pysim/+/34957?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: Ib025f9c4551af7cf57090a0678ab0f66a6684fa4 Gerrit-Change-Number: 34957 Gerrit-PatchSet: 3 Gerrit-Owner: laforge <laforge(a)osmocom.org> Gerrit-Reviewer: Jenkins Builder Gerrit-Reviewer: dexter <pmaier(a)sysmocom.de> Gerrit-Reviewer: fixeria <vyanitskiy(a)sysmocom.de> Gerrit-Attention: laforge <laforge(a)osmocom.org> Gerrit-Attention: dexter <pmaier(a)sysmocom.de> Gerrit-Comment-Date: Sat, 04 Nov 2023 11:29:47 +0000 Gerrit-HasComments: No Gerrit-Has-Labels: Yes Gerrit-MessageType: comment
1 0
0 0
[S] Change in pysim[master]: transport: Log it explicitly if user doesn't specify a reader
by fixeria 04 Nov '23

04 Nov '23
Attention is currently required from: dexter, laforge. fixeria has posted comments on this change. ( https://gerrit.osmocom.org/c/pysim/+/34959?usp=email ) Change subject: transport: Log it explicitly if user doesn't specify a reader ...................................................................... Patch Set 1: Code-Review+2 -- To view, visit https://gerrit.osmocom.org/c/pysim/+/34959?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: I37e9d62fabf237ece7e49d8f2253c606999d3d02 Gerrit-Change-Number: 34959 Gerrit-PatchSet: 1 Gerrit-Owner: laforge <laforge(a)osmocom.org> Gerrit-Reviewer: Jenkins Builder Gerrit-Reviewer: dexter <pmaier(a)sysmocom.de> Gerrit-Reviewer: fixeria <vyanitskiy(a)sysmocom.de> Gerrit-Attention: laforge <laforge(a)osmocom.org> Gerrit-Attention: dexter <pmaier(a)sysmocom.de> Gerrit-Comment-Date: Sat, 04 Nov 2023 11:29:40 +0000 Gerrit-HasComments: No Gerrit-Has-Labels: Yes Gerrit-MessageType: comment
1 0
0 0
[M] Change in pysim[master]: Use construct 'Flag' instead of 'Bit' for type descriptions
by fixeria 04 Nov '23

04 Nov '23
Attention is currently required from: dexter, laforge. fixeria has posted comments on this change. ( https://gerrit.osmocom.org/c/pysim/+/34957?usp=email ) Change subject: Use construct 'Flag' instead of 'Bit' for type descriptions ...................................................................... Patch Set 3: Code-Review+1 -- To view, visit https://gerrit.osmocom.org/c/pysim/+/34957?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: Ib025f9c4551af7cf57090a0678ab0f66a6684fa4 Gerrit-Change-Number: 34957 Gerrit-PatchSet: 3 Gerrit-Owner: laforge <laforge(a)osmocom.org> Gerrit-Reviewer: Jenkins Builder Gerrit-Reviewer: dexter <pmaier(a)sysmocom.de> Gerrit-Reviewer: fixeria <vyanitskiy(a)sysmocom.de> Gerrit-Attention: laforge <laforge(a)osmocom.org> Gerrit-Attention: dexter <pmaier(a)sysmocom.de> Gerrit-Comment-Date: Sat, 04 Nov 2023 10:47:34 +0000 Gerrit-HasComments: No Gerrit-Has-Labels: Yes Gerrit-MessageType: comment
1 0
0 0
[M] Change in osmo-mgw[master]: invent fmtp 'gsm-hr-format', for RFC5993 vs 3GPP TS 101.318
by neels 03 Nov '23

03 Nov '23
Attention is currently required from: dexter, laforge, pespin. neels has posted comments on this change. ( https://gerrit.osmocom.org/c/osmo-mgw/+/31214?usp=email ) Change subject: invent fmtp 'gsm-hr-format', for RFC5993 vs 3GPP TS 101.318 ...................................................................... Patch Set 15: Code-Review-1 (2 comments) Patchset: PS15: my conclusion is that this patch needs more work, explained below File src/libosmo-mgcp/mgcp_network.c: https://gerrit.osmocom.org/c/osmo-mgw/+/31214/comment/5d099e5b_773d446b PS13, Line 692: explicitly specified the target format will be the opposite of the input : * format. > this makes no sense to me. […] I took a look and this is what i find: Before this patch, we have a VTY option that would enable the HR conversion for an entire trunk. This does not indicate which format should appear on which side, it always converts the format that arrives to the other format. This works when one entire side of the MGW consistently uses one HR format, while the other side consistently uses the other format. This does not work when any one BTS has a different format, or when any CN call leg happens to already send the BTS format. A good solution is the fmtp that this patch added, because with it we can indicate on each side of each endpoint individually which format is used. If we forward a HR packet, convert only when the packet has the wrong format. The presence of the fmtp alone is not sufficient. Other idea, relatively simple: in the very first HR packet arriving on a conn, look which format is used on that side. From then on use that format to forward future HR to that side. -- To view, visit https://gerrit.osmocom.org/c/osmo-mgw/+/31214?usp=email To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings Gerrit-Project: osmo-mgw Gerrit-Branch: master Gerrit-Change-Id: Idde8da27fd335dc03b8fbd9e0fedc1491b77e9e4 Gerrit-Change-Number: 31214 Gerrit-PatchSet: 15 Gerrit-Owner: dexter <pmaier(a)sysmocom.de> Gerrit-Reviewer: Jenkins Builder Gerrit-Reviewer: laforge <laforge(a)osmocom.org> Gerrit-Reviewer: neels <nhofmeyr(a)sysmocom.de> Gerrit-Reviewer: pespin <pespin(a)sysmocom.de> Gerrit-Attention: laforge <laforge(a)osmocom.org> Gerrit-Attention: pespin <pespin(a)sysmocom.de> Gerrit-Attention: dexter <pmaier(a)sysmocom.de> Gerrit-Comment-Date: Fri, 03 Nov 2023 22:09:01 +0000 Gerrit-HasComments: Yes Gerrit-Has-Labels: Yes Comment-In-Reply-To: neels <nhofmeyr(a)sysmocom.de> Gerrit-MessageType: comment
1 0
0 0
[L] Change in libosmocore[master]: tests: Test gsmtap logging if write queue fills up
by laforge 03 Nov '23

03 Nov '23
Attention is currently required from: daniel. laforge has posted comments on this change. ( https://gerrit.osmocom.org/c/libosmocore/+/34967?usp=email ) Change subject: tests: Test gsmtap logging if write queue fills up ...................................................................... Patch Set 2: Code-Review+1 (1 comment) Patchset: PS2: i guess you don't want the wqueue code logging the pointer? -- To view, visit https://gerrit.osmocom.org/c/libosmocore/+/34967?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: Id5ae0c4c3820a9ed59eaf4003d2c57b6bdfe3468 Gerrit-Change-Number: 34967 Gerrit-PatchSet: 2 Gerrit-Owner: daniel <dwillmann(a)sysmocom.de> Gerrit-Reviewer: Jenkins Builder Gerrit-Reviewer: laforge <laforge(a)osmocom.org> Gerrit-Attention: daniel <dwillmann(a)sysmocom.de> Gerrit-Comment-Date: Fri, 03 Nov 2023 20:39:34 +0000 Gerrit-HasComments: Yes Gerrit-Has-Labels: Yes Gerrit-MessageType: comment
1 0
0 0
[S] Change in libosmocore[master]: logging_gsmtap: Temporarily disable logging when sending the logs
by laforge 03 Nov '23

03 Nov '23
Attention is currently required from: daniel. laforge has posted comments on this change. ( https://gerrit.osmocom.org/c/libosmocore/+/34966?usp=email ) Change subject: logging_gsmtap: Temporarily disable logging when sending the logs ...................................................................... Patch Set 1: Code-Review+1 (1 comment) File src/core/logging_gsmtap.c: https://gerrit.osmocom.org/c/libosmocore/+/34966/comment/1076a316_b05a2ff0 PS1, Line 117: the language: "error [singular] ... doesn't" or "errors [plural] don't" -- To view, visit https://gerrit.osmocom.org/c/libosmocore/+/34966?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: I19203cadbad6019a3834793b8ac816d903fe088e Gerrit-Change-Number: 34966 Gerrit-PatchSet: 1 Gerrit-Owner: daniel <dwillmann(a)sysmocom.de> Gerrit-Reviewer: Jenkins Builder Gerrit-Reviewer: laforge <laforge(a)osmocom.org> Gerrit-Attention: daniel <dwillmann(a)sysmocom.de> Gerrit-Comment-Date: Fri, 03 Nov 2023 20:38:06 +0000 Gerrit-HasComments: Yes Gerrit-Has-Labels: Yes Gerrit-MessageType: comment
1 0
0 0
[S] Change in osmocom-bb[master]: mobile: gsm_settings_init(): set TCH frame format explicitly
by fixeria 03 Nov '23

03 Nov '23
fixeria has submitted this change. ( https://gerrit.osmocom.org/c/osmocom-bb/+/34914?usp=email ) Change subject: mobile: gsm_settings_init(): set TCH frame format explicitly ...................................................................... mobile: gsm_settings_init(): set TCH frame format explicitly Change-Id: I4660b07977b6701ad5dc4bf25f12cba374101f8b Related: OS#4396 --- M src/host/layer23/src/common/settings.c 1 file changed, 11 insertions(+), 0 deletions(-) Approvals: laforge: Looks good to me, approved Jenkins Builder: Verified pespin: Looks good to me, but someone else must approve diff --git a/src/host/layer23/src/common/settings.c b/src/host/layer23/src/common/settings.c index 8768349..f251833 100644 --- a/src/host/layer23/src/common/settings.c +++ b/src/host/layer23/src/common/settings.c @@ -50,6 +50,7 @@ /* TCH voice: drop frames by default */ set->tch_voice.io_handler = TCH_VOICE_IOH_NONE; + set->tch_voice.io_format = TCH_VOICE_IOF_RTP; OSMO_STRLCPY_ARRAY(set->tch_voice.alsa_output_dev, alsa_dev_default); OSMO_STRLCPY_ARRAY(set->tch_voice.alsa_input_dev, alsa_dev_default); -- To view, visit https://gerrit.osmocom.org/c/osmocom-bb/+/34914?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: I4660b07977b6701ad5dc4bf25f12cba374101f8b Gerrit-Change-Number: 34914 Gerrit-PatchSet: 3 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: laforge <laforge(a)osmocom.org> Gerrit-Reviewer: pespin <pespin(a)sysmocom.de> Gerrit-MessageType: merged
1 0
0 0
[S] Change in osmocom-bb[master]: mobile: cosmetic: rename gsm48_rr_tx_{voice->traffic}()
by fixeria 03 Nov '23

03 Nov '23
fixeria has submitted this change. ( https://gerrit.osmocom.org/c/osmocom-bb/+/34916?usp=email ) ( 2 is the latest approved patch-set. No files were changed between the latest approved patch-set and the submitted one. )Change subject: mobile: cosmetic: rename gsm48_rr_tx_{voice->traffic}() ...................................................................... mobile: cosmetic: rename gsm48_rr_tx_{voice->traffic}() Not only this function can be used to transmit a voice frame, but also a data frame during a CSD call. Change-Id: I920300ae477e3c3d7c413cd1a35f2bc385266960 Related: OS#4396 --- M src/host/layer23/include/osmocom/bb/mobile/gsm48_rr.h M src/host/layer23/src/mobile/gsm48_rr.c M src/host/layer23/src/mobile/voice.c 3 files changed, 16 insertions(+), 3 deletions(-) Approvals: laforge: Looks good to me, but someone else must approve pespin: Looks good to me, approved Jenkins Builder: Verified diff --git a/src/host/layer23/include/osmocom/bb/mobile/gsm48_rr.h b/src/host/layer23/include/osmocom/bb/mobile/gsm48_rr.h index 16f7fb3..112e85a 100644 --- a/src/host/layer23/include/osmocom/bb/mobile/gsm48_rr.h +++ b/src/host/layer23/include/osmocom/bb/mobile/gsm48_rr.h @@ -251,7 +251,7 @@ int gsm48_rr_start_monitor(struct osmocom_ms *ms); int gsm48_rr_stop_monitor(struct osmocom_ms *ms); int gsm48_rr_alter_delay(struct osmocom_ms *ms); -int gsm48_rr_tx_voice(struct osmocom_ms *ms, struct msgb *msg); +int gsm48_rr_tx_traffic(struct osmocom_ms *ms, struct msgb *msg); int gsm48_rr_audio_mode(struct osmocom_ms *ms, uint8_t mode); #endif /* _GSM48_RR_H */ diff --git a/src/host/layer23/src/mobile/gsm48_rr.c b/src/host/layer23/src/mobile/gsm48_rr.c index 00e51a8..97ba173 100644 --- a/src/host/layer23/src/mobile/gsm48_rr.c +++ b/src/host/layer23/src/mobile/gsm48_rr.c @@ -7117,7 +7117,7 @@ #endif -int gsm48_rr_tx_voice(struct osmocom_ms *ms, struct msgb *msg) +int gsm48_rr_tx_traffic(struct osmocom_ms *ms, struct msgb *msg) { struct gsm48_rrlayer *rr = &ms->rrlayer; uint8_t ch_type, ch_subch, ch_ts; diff --git a/src/host/layer23/src/mobile/voice.c b/src/host/layer23/src/mobile/voice.c index 9b3ffdc..699bd80 100644 --- a/src/host/layer23/src/mobile/voice.c +++ b/src/host/layer23/src/mobile/voice.c @@ -106,7 +106,7 @@ int gsm_send_voice_msg(struct osmocom_ms *ms, struct msgb *msg) { /* Forward to RR */ - return gsm48_rr_tx_voice(ms, msg); + return gsm48_rr_tx_traffic(ms, msg); } /* gsm_send_voice_msg() wrapper accepting an MNCC structure */ -- To view, visit https://gerrit.osmocom.org/c/osmocom-bb/+/34916?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: I920300ae477e3c3d7c413cd1a35f2bc385266960 Gerrit-Change-Number: 34916 Gerrit-PatchSet: 3 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: laforge <laforge(a)osmocom.org> Gerrit-Reviewer: pespin <pespin(a)sysmocom.de> Gerrit-MessageType: merged
1 0
0 0
[M] Change in osmocom-bb[master]: mobile: add params and VTY commands for data calls
by fixeria 03 Nov '23

03 Nov '23
fixeria has submitted this change. ( https://gerrit.osmocom.org/c/osmocom-bb/+/34915?usp=email ) Change subject: mobile: add params and VTY commands for data calls ...................................................................... mobile: add params and VTY commands for data calls Change-Id: If52fa70cb202f0736a17fe8eb63d226186637f62 Related: OS#4396 --- M src/host/layer23/include/osmocom/bb/common/settings.h M src/host/layer23/include/osmocom/bb/mobile/vty.h M src/host/layer23/src/common/settings.c M src/host/layer23/src/mobile/vty_interface.c 4 files changed, 162 insertions(+), 0 deletions(-) Approvals: laforge: Looks good to me, approved Jenkins Builder: Verified pespin: Looks good to me, but someone else must approve diff --git a/src/host/layer23/include/osmocom/bb/common/settings.h b/src/host/layer23/include/osmocom/bb/common/settings.h index 458828a..3873611 100644 --- a/src/host/layer23/include/osmocom/bb/common/settings.h +++ b/src/host/layer23/include/osmocom/bb/common/settings.h @@ -44,6 +44,20 @@ static inline const char *tch_voice_io_handler_name(enum tch_voice_io_handler val) { return get_value_string(tch_voice_io_handler_names, val); } +/* TCH I/O handler for data calls */ +enum tch_data_io_handler { + /* No handler, drop frames */ + TCH_DATA_IOH_NONE = 0, + /* UNIX socket */ + TCH_DATA_IOH_UNIX_SOCK, + /* Return to sender */ + TCH_DATA_IOH_LOOPBACK, +}; + +extern const struct value_string tch_data_io_handler_names[]; +static inline const char *tch_data_io_handler_name(enum tch_data_io_handler val) +{ return get_value_string(tch_data_io_handler_names, val); } + /* TCH I/O format for voice calls */ enum tch_voice_io_format { /* RFC3551 for FR/EFR, RFC5993 for HR, RFC4867 for AMR */ @@ -56,6 +70,18 @@ static inline const char *tch_voice_io_format_name(enum tch_voice_io_format val) { return get_value_string(tch_voice_io_format_names, val); } +/* TCH I/O format for data calls */ +enum tch_data_io_format { + /* Osmocom format, used by trxcon and virtphy */ + TCH_DATA_IOF_OSMO, + /* Texas Instruments format, used by Calypso based phones (e.g. Motorola C1xx) */ + TCH_DATA_IOF_TI, +}; + +extern const struct value_string tch_data_io_format_names[]; +static inline const char *tch_data_io_format_name(enum tch_data_io_format val) +{ return get_value_string(tch_data_io_format_names, val); } + struct tch_voice_settings { enum tch_voice_io_handler io_handler; enum tch_voice_io_format io_format; @@ -63,6 +89,12 @@ char alsa_input_dev[128]; }; +struct tch_data_settings { + enum tch_data_io_handler io_handler; + enum tch_data_io_format io_format; + char unix_socket_path[128]; +}; + struct test_sim_settings { char imsi[OSMO_IMSI_BUF_SIZE]; uint32_t tmsi; @@ -123,6 +155,7 @@ /* TCH settings */ struct tch_voice_settings tch_voice; + struct tch_data_settings tch_data; /* IMEI */ char imei[GSM23003_IMEI_NUM_DIGITS + 1]; diff --git a/src/host/layer23/include/osmocom/bb/mobile/vty.h b/src/host/layer23/include/osmocom/bb/mobile/vty.h index b681440..f03012e 100644 --- a/src/host/layer23/include/osmocom/bb/mobile/vty.h +++ b/src/host/layer23/include/osmocom/bb/mobile/vty.h @@ -11,6 +11,7 @@ enum ms_vty_node { SUPPORT_NODE = _LAST_L23VTY_NODE + 1, TCH_VOICE_NODE, + TCH_DATA_NODE, VGCS_NODE, VBS_NODE, }; diff --git a/src/host/layer23/src/common/settings.c b/src/host/layer23/src/common/settings.c index f251833..3fca52d 100644 --- a/src/host/layer23/src/common/settings.c +++ b/src/host/layer23/src/common/settings.c @@ -34,6 +34,7 @@ static char *sap_socket_path = "/tmp/osmocom_sap"; static char *mncc_socket_path = "/tmp/ms_mncc"; +static char *data_socket_path = "/tmp/ms_data"; static char *alsa_dev_default = "default"; int gsm_settings_init(struct osmocom_ms *ms) @@ -54,6 +55,13 @@ OSMO_STRLCPY_ARRAY(set->tch_voice.alsa_output_dev, alsa_dev_default); OSMO_STRLCPY_ARRAY(set->tch_voice.alsa_input_dev, alsa_dev_default); + /* TCH data: drop frames by default */ + set->tch_data.io_handler = TCH_DATA_IOH_NONE; + set->tch_data.io_format = TCH_DATA_IOF_OSMO; + snprintf(set->tch_data.unix_socket_path, + sizeof(set->tch_data.unix_socket_path) - 1, + "%s_%s", data_socket_path, ms->name); + /* Built-in MNCC handler */ set->mncc_handler = MNCC_HANDLER_INTERNAL; @@ -236,12 +244,24 @@ { 0, NULL } }; +const struct value_string tch_data_io_handler_names[] = { + { TCH_DATA_IOH_NONE, "none" }, + { TCH_DATA_IOH_UNIX_SOCK, "unix-sock" }, + { TCH_DATA_IOH_LOOPBACK, "loopback" }, + { 0, NULL } +}; + const struct value_string tch_voice_io_format_names[] = { { TCH_VOICE_IOF_RTP, "rtp" }, { TCH_VOICE_IOF_TI, "ti" }, { 0, NULL } }; +const struct value_string tch_data_io_format_names[] = { + { TCH_DATA_IOF_OSMO, "osmo" }, + { TCH_DATA_IOF_TI, "ti" }, + { 0, NULL } +}; int gprs_settings_init(struct osmocom_ms *ms) { diff --git a/src/host/layer23/src/mobile/vty_interface.c b/src/host/layer23/src/mobile/vty_interface.c index d6bac5a..6293768 100644 --- a/src/host/layer23/src/mobile/vty_interface.c +++ b/src/host/layer23/src/mobile/vty_interface.c @@ -55,6 +55,12 @@ 1 }; +struct cmd_node tch_data_node = { + TCH_DATA_NODE, + "%s(tch-data)# ", + 1 +}; + struct cmd_node vgcs_node = { VGCS_NODE, "%s(group-call)# ", @@ -1487,6 +1493,16 @@ &set->tch_voice.alsa_input_dev[0], VTY_NEWLINE); } + vty_out(vty, " tch-data%s", VTY_NEWLINE); + vty_out(vty, " io-handler %s%s", + tch_data_io_handler_name(set->tch_data.io_handler), VTY_NEWLINE); + vty_out(vty, " io-tch-format %s%s", + tch_data_io_format_name(set->tch_data.io_format), VTY_NEWLINE); + if (set->tch_data.io_handler == TCH_DATA_IOH_UNIX_SOCK) { + vty_out(vty, " unix-socket %s%s", + set->tch_data.unix_socket_path, VTY_NEWLINE); + } + if (ms->lua_script) vty_out(vty, " lua-script %s%s", ms->lua_script, VTY_NEWLINE); @@ -2592,6 +2608,81 @@ return CMD_SUCCESS; } +DEFUN(cfg_ms_tch_data, + cfg_ms_tch_data_cmd, + "tch-data", "Configure TCH (Traffic CHannel) params for data calls\n") +{ + vty->node = TCH_DATA_NODE; + return CMD_SUCCESS; +} + +static int set_tch_data_io_handler(struct vty *vty, enum tch_data_io_handler val) +{ + struct osmocom_ms *ms = (struct osmocom_ms *) vty->index; + struct gsm_settings *set = &ms->settings; + + /* Don't restart on unchanged value */ + if (val == set->tch_data.io_handler) + return CMD_SUCCESS; + set->tch_data.io_handler = val; + + /* Restart required */ + vty_restart_if_started(vty, ms); + + return CMD_SUCCESS; +} + +DEFUN(cfg_ms_tch_data_io_handler, + cfg_ms_tch_data_io_handler_cmd, + "io-handler (none|unix-sock|loopback)", + "Set TCH frame I/O handler for data calls\n" + "No handler, drop TCH frames (default)\n" + "UNIX socket (path set by 'data-unix-socket')\n" + "Return TCH frame payload back to sender\n") +{ + int val = get_string_value(tch_data_io_handler_names, argv[0]); + + return set_tch_data_io_handler(vty, val); +} + +DEFUN(cfg_ms_tch_data_no_io_handler, + cfg_ms_tch_data_no_io_handler_cmd, + "no io-handler", NO_STR "Disable TCH frame handling for data calls\n") +{ + return set_tch_data_io_handler(vty, TCH_DATA_IOH_NONE); +} + +DEFUN(cfg_ms_tch_data_io_tch_format, + cfg_ms_tch_data_io_tch_format_cmd, + "io-tch-format (osmo|ti)", + "Set TCH I/O frame format used by the L1 PHY\n" + "Osmocom format used by both trxcon and viryphy (default)\n" + "Texas Instruments format, used by Calypso based phones (e.g. Motorola C1xx)\n") +{ + int val = get_string_value(tch_data_io_format_names, argv[0]); + struct osmocom_ms *ms = (struct osmocom_ms *)vty->index; + struct gsm_settings *set = &ms->settings; + + OSMO_ASSERT(val >= 0); + set->tch_data.io_format = val; + + return CMD_SUCCESS; +} + +DEFUN(cfg_ms_tch_data_unix_sock, + cfg_ms_tch_data_unix_sock_cmd, + "unix-socket PATH", + "Define UNIX socket path (for 'io-handler unix-sock')\n" + "UNIX socket path (default '/tmp/ms_data_' + MS_NAME)\n") +{ + struct osmocom_ms *ms = (struct osmocom_ms *)vty->index; + struct gsm_settings *set = &ms->settings; + + OSMO_STRLCPY_ARRAY(set->tch_data.unix_socket_path, argv[0]); + + return CMD_SUCCESS; +} + DEFUN(cfg_ms_script_load_run, cfg_ms_script_load_run_cmd, "lua-script FILENAME", "Load and execute a LUA script\nFilename for lua script") { @@ -2765,6 +2856,7 @@ install_element(MS_NODE, &cfg_ms_no_abbrev_cmd); install_element(MS_NODE, &cfg_ms_tch_voice_cmd); install_element(MS_NODE, &cfg_ms_audio_cmd); + install_element(MS_NODE, &cfg_ms_tch_data_cmd); install_element(MS_NODE, &cfg_ms_neighbour_cmd); install_element(MS_NODE, &cfg_ms_no_neighbour_cmd); install_element(MS_NODE, &cfg_ms_any_timeout_cmd); @@ -2856,6 +2948,12 @@ install_element(TCH_VOICE_NODE, &cfg_ms_tch_voice_alsa_out_dev_cmd); install_element(TCH_VOICE_NODE, &cfg_ms_tch_voice_alsa_in_dev_cmd); + install_node(&tch_data_node, config_write_dummy); + install_element(TCH_DATA_NODE, &cfg_ms_tch_data_io_handler_cmd); + 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); + return 0; } -- To view, visit https://gerrit.osmocom.org/c/osmocom-bb/+/34915?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: If52fa70cb202f0736a17fe8eb63d226186637f62 Gerrit-Change-Number: 34915 Gerrit-PatchSet: 3 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: laforge <laforge(a)osmocom.org> Gerrit-Reviewer: pespin <pespin(a)sysmocom.de> Gerrit-MessageType: merged
1 0
0 0
  • ← Newer
  • 1
  • ...
  • 125
  • 126
  • 127
  • 128
  • 129
  • 130
  • 131
  • ...
  • 151
  • Older →

HyperKitty Powered by HyperKitty version 1.3.12.