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

January 2023

  • 1 participants
  • 2205 discussions
Change in osmocom-bb[master]: layer23: Move settings.{c,h} under common/
by pespin 13 Jan '23

13 Jan '23
pespin has uploaded this change for review. ( https://gerrit.osmocom.org/c/osmocom-bb/+/30975 ) Change subject: layer23: Move settings.{c,h} under common/ ...................................................................... layer23: Move settings.{c,h} under common/ Some of those can be reused by other apps (like modem). Change-Id: I0a741b2384195d512fdc49eda6762241f385b1f1 --- M src/host/layer23/include/osmocom/bb/common/Makefile.am M src/host/layer23/include/osmocom/bb/common/ms.h R src/host/layer23/include/osmocom/bb/common/settings.h M src/host/layer23/include/osmocom/bb/mobile/Makefile.am M src/host/layer23/src/common/Makefile.am R src/host/layer23/src/common/settings.c M src/host/layer23/src/mobile/Makefile.am M src/host/layer23/src/mobile/gsm322.c M src/host/layer23/src/mobile/gsm48_rr.c M src/host/layer23/src/mobile/mnccms.c 10 files changed, 8 insertions(+), 8 deletions(-) git pull ssh://gerrit.osmocom.org:29418/osmocom-bb refs/changes/75/30975/1 diff --git a/src/host/layer23/include/osmocom/bb/common/Makefile.am b/src/host/layer23/include/osmocom/bb/common/Makefile.am index f09353b..270f079 100644 --- a/src/host/layer23/include/osmocom/bb/common/Makefile.am +++ b/src/host/layer23/include/osmocom/bb/common/Makefile.am @@ -12,6 +12,7 @@ sap_proto.h \ sap_fsm.h \ sap_interface.h \ + settings.h \ sim.h \ subscriber.h \ support.h \ diff --git a/src/host/layer23/include/osmocom/bb/common/ms.h b/src/host/layer23/include/osmocom/bb/common/ms.h index db6b276..9fd4c7a 100644 --- a/src/host/layer23/include/osmocom/bb/common/ms.h +++ b/src/host/layer23/include/osmocom/bb/common/ms.h @@ -5,9 +5,8 @@ #include <osmocom/gsm/gsm_utils.h> #include <osmocom/core/write_queue.h> -/* FIXME no 'mobile' specific stuff should be here */ -#include <osmocom/bb/mobile/settings.h> #include <osmocom/gsm/lapdm.h> +#include <osmocom/bb/common/settings.h> #include <osmocom/bb/common/subscriber.h> #include <osmocom/bb/common/support.h> #include <osmocom/bb/common/sap_interface.h> diff --git a/src/host/layer23/include/osmocom/bb/mobile/settings.h b/src/host/layer23/include/osmocom/bb/common/settings.h similarity index 100% rename from src/host/layer23/include/osmocom/bb/mobile/settings.h rename to src/host/layer23/include/osmocom/bb/common/settings.h diff --git a/src/host/layer23/include/osmocom/bb/mobile/Makefile.am b/src/host/layer23/include/osmocom/bb/mobile/Makefile.am index 6d9950b..14694bb 100644 --- a/src/host/layer23/include/osmocom/bb/mobile/Makefile.am +++ b/src/host/layer23/include/osmocom/bb/mobile/Makefile.am @@ -1,4 +1,4 @@ noinst_HEADERS = gsm322.h gsm480_ss.h gsm411_sms.h gsm48_cc.h gsm48_mm.h \ - gsm48_rr.h mncc.h settings.h \ + gsm48_rr.h mncc.h \ transaction.h vty.h mncc_sock.h mncc_ms.h primitives.h \ app_mobile.h voice.h gapk_io.h diff --git a/src/host/layer23/src/common/Makefile.am b/src/host/layer23/src/common/Makefile.am index 4dfa1f3..9abc802 100644 --- a/src/host/layer23/src/common/Makefile.am +++ b/src/host/layer23/src/common/Makefile.am @@ -23,6 +23,7 @@ sap_fsm.c \ sap_proto.c \ sap_interface.c \ + settings.c \ sim.c \ subscriber.c \ support.c \ diff --git a/src/host/layer23/src/mobile/settings.c b/src/host/layer23/src/common/settings.c similarity index 98% rename from src/host/layer23/src/mobile/settings.c rename to src/host/layer23/src/common/settings.c index b6e251b..0d56f91 100644 --- a/src/host/layer23/src/mobile/settings.c +++ b/src/host/layer23/src/common/settings.c @@ -21,7 +21,7 @@ #include <osmocom/core/talloc.h> #include <osmocom/bb/mobile/app_mobile.h> -#include <osmocom/bb/mobile/settings.h> +#include <osmocom/bb/common/settings.h> #include <osmocom/bb/common/utils.h> #include <osmocom/bb/common/logging.h> #include <osmocom/bb/common/osmocom_data.h> diff --git a/src/host/layer23/src/mobile/Makefile.am b/src/host/layer23/src/mobile/Makefile.am index dedee5f..b87063b 100644 --- a/src/host/layer23/src/mobile/Makefile.am +++ b/src/host/layer23/src/mobile/Makefile.am @@ -27,7 +27,6 @@ mnccms.c \ mncc_sock.c \ primitives.c \ - settings.c \ transaction.c \ vty_interface.c \ voice.c \ diff --git a/src/host/layer23/src/mobile/gsm322.c b/src/host/layer23/src/mobile/gsm322.c index 4b73594..df26e82 100644 --- a/src/host/layer23/src/mobile/gsm322.c +++ b/src/host/layer23/src/mobile/gsm322.c @@ -35,11 +35,11 @@ #include <osmocom/bb/common/ms.h> #include <osmocom/bb/common/networks.h> #include <osmocom/bb/common/utils.h> +#include <osmocom/bb/common/settings.h> #include <osmocom/bb/mobile/vty.h> #include <osmocom/bb/mobile/app_mobile.h> #include <osmocom/bb/mobile/gsm322.h> #include <osmocom/bb/mobile/gsm48_mm.h> -#include <osmocom/bb/mobile/settings.h> #include <l1ctl_proto.h> diff --git a/src/host/layer23/src/mobile/gsm48_rr.c b/src/host/layer23/src/mobile/gsm48_rr.c index 87a0dcd..5d5e003 100644 --- a/src/host/layer23/src/mobile/gsm48_rr.c +++ b/src/host/layer23/src/mobile/gsm48_rr.c @@ -76,11 +76,11 @@ #include <osmocom/bb/common/networks.h> #include <osmocom/bb/common/l1ctl.h> #include <osmocom/bb/common/utils.h> +#include <osmocom/bb/common/settings.h> #include <osmocom/bb/mobile/gapk_io.h> #include <osmocom/bb/mobile/vty.h> #include <osmocom/bb/mobile/gsm48_rr.h> -#include <osmocom/bb/mobile/settings.h> #include <l1ctl_proto.h> diff --git a/src/host/layer23/src/mobile/mnccms.c b/src/host/layer23/src/mobile/mnccms.c index 16cabc1..bfc95e4 100644 --- a/src/host/layer23/src/mobile/mnccms.c +++ b/src/host/layer23/src/mobile/mnccms.c @@ -26,10 +26,10 @@ #include <osmocom/bb/common/logging.h> #include <osmocom/bb/common/osmocom_data.h> #include <osmocom/bb/common/ms.h> +#include <osmocom/bb/common/settings.h> #include <osmocom/bb/mobile/mncc.h> #include <osmocom/bb/mobile/mncc_ms.h> #include <osmocom/bb/mobile/vty.h> -#include <osmocom/bb/mobile/settings.h> static uint32_t new_callref = 1; static LLIST_HEAD(call_list); -- To view, visit https://gerrit.osmocom.org/c/osmocom-bb/+/30975 To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings Gerrit-Project: osmocom-bb Gerrit-Branch: master Gerrit-Change-Id: I0a741b2384195d512fdc49eda6762241f385b1f1 Gerrit-Change-Number: 30975 Gerrit-PatchSet: 1 Gerrit-Owner: pespin <pespin(a)sysmocom.de> Gerrit-MessageType: newchange
1 0
0 0
Change in osmocom-bb[master]: layer23: Initial VTY framework to share VTY code between apps
by pespin 13 Jan '23

13 Jan '23
Attention is currently required from: pespin. Hello Jenkins Builder, fixeria, I'd like you to reexamine a change. Please visit https://gerrit.osmocom.org/c/osmocom-bb/+/30961 to look at the new patch set (#6). Change subject: layer23: Initial VTY framework to share VTY code between apps ...................................................................... layer23: Initial VTY framework to share VTY code between apps A small layer23 framework is added which allows apps to easily share/reuse VTY commands while giving some flexiblity to add new per-app specific configs/cmds, since not all commands may be relevant for all apps. Some of the mobile app code is moved to common, and sample infra is added to modem app. Future commits will most probably keep moving more stuff mobile->common and then reusing those in modem app, as found needed. Change-Id: Iabfb3129199488d790b89884bc1e424f2aca696f --- M src/host/layer23/include/osmocom/bb/common/Makefile.am A src/host/layer23/include/osmocom/bb/common/vty.h M src/host/layer23/include/osmocom/bb/mobile/vty.h M src/host/layer23/include/osmocom/bb/modem/Makefile.am A src/host/layer23/include/osmocom/bb/modem/vty.h M src/host/layer23/src/common/Makefile.am A src/host/layer23/src/common/vty.c M src/host/layer23/src/mobile/vty_interface.c M src/host/layer23/src/modem/Makefile.am M src/host/layer23/src/modem/app_modem.c A src/host/layer23/src/modem/vty.c 11 files changed, 340 insertions(+), 75 deletions(-) git pull ssh://gerrit.osmocom.org:29418/osmocom-bb refs/changes/61/30961/6 -- To view, visit https://gerrit.osmocom.org/c/osmocom-bb/+/30961 To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings Gerrit-Project: osmocom-bb Gerrit-Branch: master Gerrit-Change-Id: Iabfb3129199488d790b89884bc1e424f2aca696f Gerrit-Change-Number: 30961 Gerrit-PatchSet: 6 Gerrit-Owner: pespin <pespin(a)sysmocom.de> Gerrit-Reviewer: Jenkins Builder Gerrit-Reviewer: fixeria <vyanitskiy(a)sysmocom.de> Gerrit-Attention: pespin <pespin(a)sysmocom.de> Gerrit-MessageType: newpatchset
1 0
0 0
Change in osmocom-bb[master]: layer23: Move '(no) shutdown' VTY code to common/vty.c
by pespin 13 Jan '23

13 Jan '23
pespin has uploaded this change for review. ( https://gerrit.osmocom.org/c/osmocom-bb/+/30972 ) Change subject: layer23: Move '(no) shutdown' VTY code to common/vty.c ...................................................................... layer23: Move '(no) shutdown' VTY code to common/vty.c Change-Id: Ib5c9b6f3efa255d67980945db9f98dd8a112af0e --- A doc/examples/modem/modem.cfg M src/host/layer23/include/osmocom/bb/common/osmocom_data.h M src/host/layer23/include/osmocom/bb/common/vty.h M src/host/layer23/src/common/vty.c M src/host/layer23/src/mobile/vty_interface.c M src/host/layer23/src/modem/vty.c 6 files changed, 152 insertions(+), 62 deletions(-) git pull ssh://gerrit.osmocom.org:29418/osmocom-bb refs/changes/72/30972/1 diff --git a/doc/examples/modem/modem.cfg b/doc/examples/modem/modem.cfg new file mode 100644 index 0000000..d2cb81f --- /dev/null +++ b/doc/examples/modem/modem.cfg @@ -0,0 +1,9 @@ +! +! OsmocomBB example configuration for modem application +!! +! +line vty + no login +! +ms 1 + no shutdown diff --git a/src/host/layer23/include/osmocom/bb/common/osmocom_data.h b/src/host/layer23/include/osmocom/bb/common/osmocom_data.h index d78edc3..86351a5 100644 --- a/src/host/layer23/include/osmocom/bb/common/osmocom_data.h +++ b/src/host/layer23/include/osmocom/bb/common/osmocom_data.h @@ -1,13 +1,16 @@ #pragma once #include <stdint.h> +#include <stdbool.h> struct osmocom_ms; struct gapk_io_state; +struct vty; enum osmobb_sig_subsys { SS_L1CTL, SS_GLOBAL, + SS_L23_VTY, }; enum osmobb_l1ctl_sig { @@ -26,6 +29,24 @@ S_GLOBAL_SHUTDOWN, }; +enum osmobb_l23_vty_sig { + S_L23_VTY_MS_START, + S_L23_VTY_MS_STOP, +}; + +struct osmobb_l23_vty_sig_data { + struct vty *vty; + struct { + struct osmocom_ms *ms; + int rc; /* CMD_SUCCESS/CMD_WARNING */ + } ms_start; + struct { + struct osmocom_ms *ms; + bool force; + int rc; /* CMD_SUCCESS/CMD_WARNING */ + } ms_stop; +}; + struct osmobb_fbsb_res { struct osmocom_ms *ms; int8_t snr; diff --git a/src/host/layer23/include/osmocom/bb/common/vty.h b/src/host/layer23/include/osmocom/bb/common/vty.h index 815f1f2..4aeb6cb 100644 --- a/src/host/layer23/include/osmocom/bb/common/vty.h +++ b/src/host/layer23/include/osmocom/bb/common/vty.h @@ -4,6 +4,7 @@ #include <osmocom/vty/vty.h> #include <osmocom/vty/buffer.h> #include <osmocom/vty/command.h> +#include <osmocom/core/signal.h> struct osmocom_ms; @@ -13,13 +14,13 @@ }; int l23_vty_go_parent(struct vty *vty); -int l23_vty_init(int (*config_write_ms_node_cb)(struct vty *)); +int l23_vty_init(int (*config_write_ms_node_cb)(struct vty *), osmo_signal_cbfn *l23_vty_signal_cb); struct osmocom_ms *l23_vty_get_ms(const char *name, struct vty *vty); void l23_ms_dump(struct osmocom_ms *ms, struct vty *vty); void l23_vty_config_write_ms_node(struct vty *vty, struct osmocom_ms *ms, const char *prefix); void l23_vty_config_write_ms_node_contents(struct vty *vty, struct osmocom_ms *ms, const char *prefix); - +void l23_vty_config_write_ms_node_contents_final(struct vty *vty, struct osmocom_ms *ms, const char *prefix); extern struct llist_head ms_list; extern struct cmd_element l23_show_ms_cmd; diff --git a/src/host/layer23/src/common/vty.c b/src/host/layer23/src/common/vty.c index 46606c7..2d71c53 100644 --- a/src/host/layer23/src/common/vty.c +++ b/src/host/layer23/src/common/vty.c @@ -151,6 +151,56 @@ return CMD_WARNING; } +DEFUN(cfg_ms_no_shutdown, cfg_ms_no_shutdown_cmd, "no shutdown", + NO_STR "Activate and run MS") +{ + struct osmocom_ms *ms = vty->index; + + struct osmobb_l23_vty_sig_data data; + memset(&data, 0, sizeof(data)); + + data.vty = vty; + data.ms_start.ms = ms; + data.ms_start.rc = CMD_SUCCESS; + osmo_signal_dispatch(SS_L23_VTY, S_L23_VTY_MS_START, &data); + + return data.ms_start.rc; +} + +DEFUN(cfg_ms_shutdown, cfg_ms_shutdown_cmd, "shutdown", + "Shut down and deactivate MS") +{ + struct osmocom_ms *ms = vty->index; + + struct osmobb_l23_vty_sig_data data; + memset(&data, 0, sizeof(data)); + + data.vty = vty; + data.ms_stop.ms = ms; + data.ms_stop.force = false; + data.ms_stop.rc = CMD_SUCCESS; + osmo_signal_dispatch(SS_L23_VTY, S_L23_VTY_MS_STOP, &data); + + return data.ms_stop.rc; +} + +DEFUN(cfg_ms_shutdown_force, cfg_ms_shutdown_force_cmd, "shutdown force", + "Shut down and deactivate MS\nDo not perform IMSI detach") +{ + struct osmocom_ms *ms = vty->index; + + struct osmobb_l23_vty_sig_data data; + memset(&data, 0, sizeof(data)); + + data.vty = vty; + data.ms_stop.ms = ms; + data.ms_stop.force = true; + data.ms_stop.rc = CMD_SUCCESS; + osmo_signal_dispatch(SS_L23_VTY, S_L23_VTY_MS_STOP, &data); + + return data.ms_stop.rc; +} + void l23_vty_config_write_ms_node(struct vty *vty, struct osmocom_ms *ms, const char *prefix) { size_t prefix_len = strlen(prefix); @@ -162,6 +212,7 @@ vty_out(vty, "%sms %s%s", prefix, ms->name, VTY_NEWLINE); l23_vty_config_write_ms_node_contents(vty, ms, prefix_content); + l23_vty_config_write_ms_node_contents_final(vty, ms, prefix_content); } void l23_vty_config_write_ms_node_contents(struct vty *vty, struct osmocom_ms *ms, const char *prefix) @@ -169,6 +220,16 @@ /* placeholder for shared VTY commands */ } +void l23_vty_config_write_ms_node_contents_final(struct vty *vty, struct osmocom_ms *ms, const char *prefix) +{ + /* placeholder for shared VTY commands. Must be put at the end of the node: */ + + /* no shutdown must be written to config, because shutdown is default */ + vty_out(vty, " %sshutdown%s", (ms->shutdown != MS_SHUTDOWN_NONE) ? "" : "no ", + VTY_NEWLINE); + vty_out(vty, "!%s", VTY_NEWLINE); +} + int l23_vty_go_parent(struct vty *vty) { switch (vty->node) { @@ -183,13 +244,18 @@ return vty->node; } -int l23_vty_init(int (*config_write_ms_node_cb)(struct vty *)) +int l23_vty_init(int (*config_write_ms_node_cb)(struct vty *), osmo_signal_cbfn *l23_vty_signal_cb) { + int rc = 0; install_node(&ms_node, config_write_ms_node_cb); + install_element(MS_NODE, &cfg_ms_shutdown_cmd); + install_element(MS_NODE, &cfg_ms_shutdown_force_cmd); + install_element(MS_NODE, &cfg_ms_no_shutdown_cmd); /* Register the talloc context introspection command */ osmo_talloc_vty_add_cmds(); - - return 0; + if (l23_vty_signal_cb) + rc = osmo_signal_register_handler(SS_L23_VTY, l23_vty_signal_cb, NULL); + return rc; } diff --git a/src/host/layer23/src/mobile/vty_interface.c b/src/host/layer23/src/mobile/vty_interface.c index 0945faa..706ddec 100644 --- a/src/host/layer23/src/mobile/vty_interface.c +++ b/src/host/layer23/src/mobile/vty_interface.c @@ -1533,12 +1533,10 @@ set->audio.alsa_input_dev, VTY_NEWLINE); } - /* no shutdown must be written to config, because shutdown is default */ - vty_out(vty, " %sshutdown%s", (ms->shutdown != MS_SHUTDOWN_NONE) ? "" : "no ", - VTY_NEWLINE); if (ms->lua_script) vty_out(vty, " lua-script %s%s", ms->lua_script, VTY_NEWLINE); - vty_out(vty, "!%s", VTY_NEWLINE); + + l23_vty_config_write_ms_node_contents_final(vty, ms, " "); } static int config_write(struct vty *vty) @@ -2902,53 +2900,6 @@ return CMD_SUCCESS; } -DEFUN(cfg_no_shutdown, cfg_ms_no_shutdown_cmd, "no shutdown", - NO_STR "Activate and run MS") -{ - struct osmocom_ms *ms = vty->index; - char *other_name = NULL; - int rc; - - rc = mobile_start(ms, &other_name); - switch (rc) { - case -1: - vty_out(vty, "Cannot start MS '%s', because MS '%s' " - "use the same layer2-socket.%sPlease shutdown " - "MS '%s' first.%s", ms->name, other_name, - VTY_NEWLINE, other_name, VTY_NEWLINE); - return CMD_WARNING; - case -2: - vty_out(vty, "Cannot start MS '%s', because MS '%s' " - "use the same sap-socket.%sPlease shutdown " - "MS '%s' first.%s", ms->name, other_name, - VTY_NEWLINE, other_name, VTY_NEWLINE); - return CMD_WARNING; - case -3: - vty_out(vty, "Connection to layer 1 failed!%s", - VTY_NEWLINE); - return CMD_WARNING; - } - - return CMD_SUCCESS; -} - -DEFUN(cfg_shutdown, cfg_ms_shutdown_cmd, "shutdown", - "Shut down and deactivate MS") -{ - struct osmocom_ms *ms = vty->index; - mobile_stop(ms, 0); - return CMD_SUCCESS; -} - -DEFUN(cfg_shutdown_force, cfg_ms_shutdown_force_cmd, "shutdown force", - "Shut down and deactivate MS\nDo not perform IMSI detach") -{ - struct osmocom_ms *ms = vty->index; - - mobile_stop(ms, 1); - 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") { @@ -2996,12 +2947,56 @@ return CMD_SUCCESS; } +/* run ms instance, if layer1 is available */ +static int l23_vty_signal_cb(unsigned int subsys, unsigned int signal, + void *handler_data, void *signal_data) +{ + struct osmobb_l23_vty_sig_data *d = signal_data; + struct vty *vty = d->vty; + char *other_name = NULL; + int rc; + + if (subsys != SS_L23_VTY) + return 0; + + switch (signal) { + case S_L23_VTY_MS_START: + rc = mobile_start(d->ms_start.ms, &other_name); + switch (rc) { + case -1: + vty_out(vty, "Cannot start MS '%s', because MS '%s' " + "use the same layer2-socket.%sPlease shutdown " + "MS '%s' first.%s", d->ms_start.ms->name, other_name, + VTY_NEWLINE, other_name, VTY_NEWLINE); + break; + case -2: + vty_out(vty, "Cannot start MS '%s', because MS '%s' " + "use the same sap-socket.%sPlease shutdown " + "MS '%s' first.%s", d->ms_start.ms->name, other_name, + VTY_NEWLINE, other_name, VTY_NEWLINE); + break; + case -3: + vty_out(vty, "Connection to layer 1 failed!%s", + VTY_NEWLINE); + break; + } + d->ms_start.rc = (rc == 0) ? CMD_SUCCESS : CMD_WARNING; + break; + case S_L23_VTY_MS_STOP: + mobile_stop(d->ms_stop.ms, d->ms_stop.force); + d->ms_start.rc = CMD_SUCCESS; + break; + } + return 0; +} + + #define SUP_NODE(item) \ install_element(SUPPORT_NODE, &cfg_ms_sup_item_cmd); int ms_vty_init(void) { - l23_vty_init(config_write); + l23_vty_init(config_write, l23_vty_signal_cb); install_element_ve(&show_ms_cmd); install_element_ve(&show_subscr_cmd); @@ -3168,9 +3163,6 @@ install_element(TESTSIM_NODE, &cfg_test_rplmn_cmd); install_element(TESTSIM_NODE, &cfg_test_rplmn_att_cmd); install_element(TESTSIM_NODE, &cfg_test_hplmn_cmd); - install_element(MS_NODE, &cfg_ms_shutdown_cmd); - install_element(MS_NODE, &cfg_ms_shutdown_force_cmd); - install_element(MS_NODE, &cfg_ms_no_shutdown_cmd); install_element(MS_NODE, &cfg_ms_script_load_run_cmd); install_element(MS_NODE, &cfg_ms_no_script_load_run_cmd); diff --git a/src/host/layer23/src/modem/vty.c b/src/host/layer23/src/modem/vty.c index 88f7e7a..a28c5fd 100644 --- a/src/host/layer23/src/modem/vty.c +++ b/src/host/layer23/src/modem/vty.c @@ -31,8 +31,9 @@ static int config_write(struct vty *vty) { struct osmocom_ms *ms; - llist_for_each_entry(ms, &ms_list, entity) + llist_for_each_entry(ms, &ms_list, entity) { l23_vty_config_write_ms_node(vty, ms, ""); + } return CMD_SUCCESS; } @@ -48,7 +49,7 @@ int modem_vty_init(void) { - l23_vty_init(config_write); + l23_vty_init(config_write, NULL); install_element_ve(&l23_show_ms_cmd); install_element(CONFIG_NODE, &l23_cfg_ms_cmd); -- To view, visit https://gerrit.osmocom.org/c/osmocom-bb/+/30972 To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings Gerrit-Project: osmocom-bb Gerrit-Branch: master Gerrit-Change-Id: Ib5c9b6f3efa255d67980945db9f98dd8a112af0e Gerrit-Change-Number: 30972 Gerrit-PatchSet: 1 Gerrit-Owner: pespin <pespin(a)sysmocom.de> Gerrit-MessageType: newchange
1 0
0 0
Change in osmo-trx[master]: ms: update submodule to currently known working version
by pespin 13 Jan '23

13 Jan '23
Attention is currently required from: Hoernchen, fixeria. pespin has posted comments on this change. ( https://gerrit.osmocom.org/c/osmo-trx/+/30967 ) Change subject: ms: update submodule to currently known working version ...................................................................... Patch Set 4: Code-Review+1 -- To view, visit https://gerrit.osmocom.org/c/osmo-trx/+/30967 To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings Gerrit-Project: osmo-trx Gerrit-Branch: master Gerrit-Change-Id: I690f508d1f0cee0b623196dd4574c3ee456f07fa Gerrit-Change-Number: 30967 Gerrit-PatchSet: 4 Gerrit-Owner: Hoernchen <ewild(a)sysmocom.de> Gerrit-Reviewer: Jenkins Builder Gerrit-Reviewer: fixeria <vyanitskiy(a)sysmocom.de> Gerrit-Reviewer: pespin <pespin(a)sysmocom.de> Gerrit-Attention: Hoernchen <ewild(a)sysmocom.de> Gerrit-Attention: fixeria <vyanitskiy(a)sysmocom.de> Gerrit-Comment-Date: Fri, 13 Jan 2023 14:45:55 +0000 Gerrit-HasComments: No Gerrit-Has-Labels: Yes Gerrit-MessageType: comment
1 0
0 0
Change in osmo-trx[master]: ms: adjust float<->integral type conversion
by pespin 13 Jan '23

13 Jan '23
Attention is currently required from: Hoernchen. pespin has posted comments on this change. ( https://gerrit.osmocom.org/c/osmo-trx/+/30966 ) Change subject: ms: adjust float<->integral type conversion ...................................................................... Patch Set 4: Code-Review+1 -- To view, visit https://gerrit.osmocom.org/c/osmo-trx/+/30966 To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings Gerrit-Project: osmo-trx Gerrit-Branch: master Gerrit-Change-Id: I93f077f967daf2ed382d12cc20a54846b3688634 Gerrit-Change-Number: 30966 Gerrit-PatchSet: 4 Gerrit-Owner: Hoernchen <ewild(a)sysmocom.de> Gerrit-Reviewer: Jenkins Builder Gerrit-Reviewer: pespin <pespin(a)sysmocom.de> Gerrit-Attention: Hoernchen <ewild(a)sysmocom.de> Gerrit-Comment-Date: Fri, 13 Jan 2023 14:45:37 +0000 Gerrit-HasComments: No Gerrit-Has-Labels: Yes Gerrit-MessageType: comment
1 0
0 0
Change in osmo-trx[master]: .clang-format: adjust template formatting
by pespin 13 Jan '23

13 Jan '23
Attention is currently required from: Hoernchen. pespin has posted comments on this change. ( https://gerrit.osmocom.org/c/osmo-trx/+/30970 ) Change subject: .clang-format: adjust template formatting ...................................................................... Patch Set 2: Code-Review+1 -- To view, visit https://gerrit.osmocom.org/c/osmo-trx/+/30970 To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings Gerrit-Project: osmo-trx Gerrit-Branch: master Gerrit-Change-Id: I9345693982ce33e6bc811be9e98b9d3da2add7a1 Gerrit-Change-Number: 30970 Gerrit-PatchSet: 2 Gerrit-Owner: Hoernchen <ewild(a)sysmocom.de> Gerrit-Reviewer: Jenkins Builder Gerrit-Reviewer: pespin <pespin(a)sysmocom.de> Gerrit-Attention: Hoernchen <ewild(a)sysmocom.de> Gerrit-Comment-Date: Fri, 13 Jan 2023 14:40:18 +0000 Gerrit-HasComments: No Gerrit-Has-Labels: Yes Gerrit-MessageType: comment
1 0
0 0
Change in osmo-trx[master]: mstrx: do not wait forever if clock locking fails
by Hoernchen 13 Jan '23

13 Jan '23
Hoernchen has submitted this change. ( https://gerrit.osmocom.org/c/osmo-trx/+/30940 ) Change subject: mstrx: do not wait forever if clock locking fails ...................................................................... mstrx: do not wait forever if clock locking fails Change-Id: Ib85f2452b66fb4d9881fe9676e69e4f6a8ba8f74 --- M Transceiver52M/ms/ms_upper.cpp M Transceiver52M/ms/uhd_specific.h 2 files changed, 16 insertions(+), 1 deletion(-) Approvals: pespin: Looks good to me, but someone else must approve fixeria: Looks good to me, approved Jenkins Builder: Verified diff --git a/Transceiver52M/ms/ms_upper.cpp b/Transceiver52M/ms/ms_upper.cpp index 281716e..2f3bdc6 100644 --- a/Transceiver52M/ms/ms_upper.cpp +++ b/Transceiver52M/ms/ms_upper.cpp @@ -482,6 +482,10 @@ trx->do_auto_gain = true; status = trx->init_dev_and_streams(); + if (status < 0) { + std::cerr << "Error initializing hardware, quitting.." << std::endl; + return -1; + } trx->set_name_aff_sched("main", 3, SCHED_FIFO, sched_get_priority_max(SCHED_FIFO) - 5); if (!trxcon::trxc_l1ctl_init(tall_trxcon_ctx)) { diff --git a/Transceiver52M/ms/uhd_specific.h b/Transceiver52M/ms/uhd_specific.h index ed88faa..edf7f79 100644 --- a/Transceiver52M/ms/uhd_specific.h +++ b/Transceiver52M/ms/uhd_specific.h @@ -133,6 +133,7 @@ int init_device(bh_fn_t rxh, bh_fn_t txh) { auto const lock_delay_ms = 500; + auto clock_lock_attempts = 15; // x lock_delay_ms auto const mcr = 26e6; auto const rate = (1625e3 / 6) * 4; auto const ref = "external"; @@ -157,8 +158,18 @@ dev->set_tx_bandwidth(bw, channel); while (!(dev->get_rx_sensor("lo_locked", channel).to_bool() && - dev->get_mboard_sensor("ref_locked").to_bool())) + dev->get_mboard_sensor("ref_locked").to_bool()) && + clock_lock_attempts > 0) { + std::cerr << "clock source lock attempts remaining: " << clock_lock_attempts << ".." + << std::endl; std::this_thread::sleep_for(std::chrono::milliseconds(lock_delay_ms)); + clock_lock_attempts--; + } + + if (clock_lock_attempts <= 0) { + std::cerr << "Error locking clock, gpsdo missing? quitting.." << std::endl; + return -1; + } uhd::stream_args_t stream_args("sc16", "sc16"); rx_stream = dev->get_rx_stream(stream_args); -- To view, visit https://gerrit.osmocom.org/c/osmo-trx/+/30940 To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings Gerrit-Project: osmo-trx Gerrit-Branch: master Gerrit-Change-Id: Ib85f2452b66fb4d9881fe9676e69e4f6a8ba8f74 Gerrit-Change-Number: 30940 Gerrit-PatchSet: 1 Gerrit-Owner: Hoernchen <ewild(a)sysmocom.de> Gerrit-Reviewer: Hoernchen <ewild(a)sysmocom.de> Gerrit-Reviewer: Jenkins Builder Gerrit-Reviewer: fixeria <vyanitskiy(a)sysmocom.de> Gerrit-Reviewer: pespin <pespin(a)sysmocom.de> Gerrit-MessageType: merged
1 0
0 0
Change in osmo-trx[master]: ms: update submodule to currently known working version
by Hoernchen 13 Jan '23

13 Jan '23
Attention is currently required from: fixeria. Hoernchen has posted comments on this change. ( https://gerrit.osmocom.org/c/osmo-trx/+/30967 ) Change subject: ms: update submodule to currently known working version ...................................................................... Patch Set 4: (1 comment) File Transceiver52M/ms/ms.h: https://gerrit.osmocom.org/c/osmo-trx/+/30967/comment/7a5327a0_5a6052d1 PS3, Line 88: template <typename T> > unrelated? Loks like I accidently squashed the formatting into the wrong commit after reordering the formatting changes... -- To view, visit https://gerrit.osmocom.org/c/osmo-trx/+/30967 To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings Gerrit-Project: osmo-trx Gerrit-Branch: master Gerrit-Change-Id: I690f508d1f0cee0b623196dd4574c3ee456f07fa Gerrit-Change-Number: 30967 Gerrit-PatchSet: 4 Gerrit-Owner: Hoernchen <ewild(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: Fri, 13 Jan 2023 14:00:39 +0000 Gerrit-HasComments: Yes Gerrit-Has-Labels: No Comment-In-Reply-To: fixeria <vyanitskiy(a)sysmocom.de> Gerrit-MessageType: comment
1 0
0 0
Change in osmo-trx[master]: ms: adjust float<->integral type conversion
by Hoernchen 13 Jan '23

13 Jan '23
Attention is currently required from: pespin. Hello Jenkins Builder, I'd like you to reexamine a change. Please visit https://gerrit.osmocom.org/c/osmo-trx/+/30966 to look at the new patch set (#4). Change subject: ms: adjust float<->integral type conversion ...................................................................... ms: adjust float<->integral type conversion Given integral type A and non integral type B and depending on rounding mode, optimization, compiler, and phase of the moon A(A)*B != A(A*B) so split the two cases. While at it, also make the template automagically work for complex types instead of requiring manual casts, the general idea here is to allow inlining and vectorization by treating all args as plain arrays, which is fine. This works as expected with -tune=native, x64 implies sse2, and we do not target any neon-less arm versions either. Clang only array length hints can improve this even more. Change-Id: I93f077f967daf2ed382d12cc20a54846b3688634 --- M Transceiver52M/Complex.h M Transceiver52M/ms/ms.cpp M Transceiver52M/ms/ms.h M Transceiver52M/ms/ms_rx_burst_test.cpp M Transceiver52M/ms/ms_rx_lower.cpp M Transceiver52M/ms/ms_upper.cpp 6 files changed, 58 insertions(+), 21 deletions(-) git pull ssh://gerrit.osmocom.org:29418/osmo-trx refs/changes/66/30966/4 -- To view, visit https://gerrit.osmocom.org/c/osmo-trx/+/30966 To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings Gerrit-Project: osmo-trx Gerrit-Branch: master Gerrit-Change-Id: I93f077f967daf2ed382d12cc20a54846b3688634 Gerrit-Change-Number: 30966 Gerrit-PatchSet: 4 Gerrit-Owner: Hoernchen <ewild(a)sysmocom.de> Gerrit-Reviewer: Jenkins Builder Gerrit-CC: pespin <pespin(a)sysmocom.de> Gerrit-Attention: pespin <pespin(a)sysmocom.de> Gerrit-MessageType: newpatchset
1 0
0 0
Change in osmocom-bb[master]: layer23: Initialize osmocom_ms further in common code
by fixeria 13 Jan '23

13 Jan '23
Attention is currently required from: pespin. fixeria has posted comments on this change. ( https://gerrit.osmocom.org/c/osmocom-bb/+/30971 ) Change subject: layer23: Initialize osmocom_ms further in common code ...................................................................... Patch Set 1: Code-Review+1 -- To view, visit https://gerrit.osmocom.org/c/osmocom-bb/+/30971 To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings Gerrit-Project: osmocom-bb Gerrit-Branch: master Gerrit-Change-Id: Ic629cf229167ddd4c533a2abf1b82ad78d1144a9 Gerrit-Change-Number: 30971 Gerrit-PatchSet: 1 Gerrit-Owner: pespin <pespin(a)sysmocom.de> Gerrit-Reviewer: Jenkins Builder Gerrit-Reviewer: fixeria <vyanitskiy(a)sysmocom.de> Gerrit-Attention: pespin <pespin(a)sysmocom.de> Gerrit-Comment-Date: Fri, 13 Jan 2023 13:56:27 +0000 Gerrit-HasComments: No Gerrit-Has-Labels: Yes Gerrit-MessageType: comment
1 0
0 0
  • ← Newer
  • 1
  • ...
  • 124
  • 125
  • 126
  • 127
  • 128
  • 129
  • 130
  • ...
  • 221
  • Older →

HyperKitty Powered by HyperKitty version 1.3.12.