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

September 2024

  • 1 participants
  • 1983 discussions
[S] Change in osmo-bsc[master]: tests/vty: Validate allocating all possible BTS
by pespin 10 Sep '24

10 Sep '24
pespin has submitted this change. ( https://gerrit.osmocom.org/c/osmo-bsc/+/38064?usp=email ) Change subject: tests/vty: Validate allocating all possible BTS ...................................................................... tests/vty: Validate allocating all possible BTS Change-Id: I91603872de1287e8f69edd05a1f485e03909b3b4 --- M tests/vty_test_runner.py 1 file changed, 20 insertions(+), 0 deletions(-) Approvals: laforge: Looks good to me, but someone else must approve dexter: Looks good to me, but someone else must approve Jenkins Builder: Verified pespin: Looks good to me, approved diff --git a/tests/vty_test_runner.py b/tests/vty_test_runner.py index 50bf6a0..ac9fad3 100755 --- a/tests/vty_test_runner.py +++ b/tests/vty_test_runner.py @@ -174,6 +174,26 @@ res = self.vty.command("show network") self.assertTrue(res.startswith('BSC is on Country Code') >= 0) + def testTonsOfBTS(self): + self.vty.enable() + self.assertTrue(self.vty.verify("configure terminal",[''])) + self.assertTrue(self.vty.verify("network",[''])) + num_of_bts = 255 + for i in range(num_of_bts): + self.assertTrue(self.vty.verify("bts " + str(i),[''])) + self.assertEqual(self.vty.node(), 'config-net-bts') + self.checkForEndAndExit() + self.assertTrue(self.vty.verify("trx 0",[''])) + self.assertEqual(self.vty.node(), 'config-net-bts-trx') + self.checkForEndAndExit() + self.assertTrue(self.vty.verify("exit",[''])) + self.assertEqual(self.vty.node(), 'config-net-bts') + self.assertTrue(self.vty.verify("exit",[''])) + self.assertEqual(self.vty.node(), 'config-net') + + self.assertTrue(self.vty.verify("bts " + str(num_of_bts+1),['% Unknown command.'])) + self.assertEqual(self.vty.node(), 'config-net') + def add_bsc_test(suite, workdir): if not os.path.isfile(os.path.join(workdir, "src/osmo-bsc/osmo-bsc")): -- To view, visit https://gerrit.osmocom.org/c/osmo-bsc/+/38064?usp=email To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings?usp=email Gerrit-MessageType: merged Gerrit-Project: osmo-bsc Gerrit-Branch: master Gerrit-Change-Id: I91603872de1287e8f69edd05a1f485e03909b3b4 Gerrit-Change-Number: 38064 Gerrit-PatchSet: 4 Gerrit-Owner: pespin <pespin(a)sysmocom.de> Gerrit-Reviewer: Jenkins Builder Gerrit-Reviewer: dexter <pmaier(a)sysmocom.de> Gerrit-Reviewer: laforge <laforge(a)osmocom.org> Gerrit-Reviewer: pespin <pespin(a)sysmocom.de>
1 0
0 0
[M] Change in osmo-bsc[master]: Convert bts->depends_on from bitmask to llist
by pespin 10 Sep '24

10 Sep '24
pespin has submitted this change. ( https://gerrit.osmocom.org/c/osmo-bsc/+/38050?usp=email ) Change subject: Convert bts->depends_on from bitmask to llist ...................................................................... Convert bts->depends_on from bitmask to llist The amount of dependencies on each BTS is usually zero or a small number, hence the computation cost is mostly similar regardless of using a llist or a bitmask buffer. Right now, even if the dependency chains are (almost) empty, the previous code allocated (N * 256/8) bytes, where N is the amount of bts configured. Since we are now planning to increase the amount of bts (N) from uint8_t to uint16_t, that means with this change we will then avoid: * Increasing memory use to O(N * 65536/8). * Having to adapt code operating on bitmask (size) Related: SYS#7062 Change-Id: I59e37d6baa020aeafdffc2c3538e988effd37620 --- M include/osmocom/bsc/bts.h M src/osmo-bsc/bts.c M src/osmo-bsc/bts_vty.c 3 files changed, 52 insertions(+), 46 deletions(-) Approvals: Jenkins Builder: Verified pespin: Looks good to me, approved diff --git a/include/osmocom/bsc/bts.h b/include/osmocom/bsc/bts.h index e9634ee..f2f7217 100644 --- a/include/osmocom/bsc/bts.h +++ b/include/osmocom/bsc/bts.h @@ -326,6 +326,12 @@ struct gprs_rlc_cfg rlc_cfg; }; +/* See (struct gsm_bts *)->depends_on */ +struct bts_depends_on_entry { + struct llist_head list; + uint8_t bts_nr; /* See (struct gsm_bts *)->nr */ +}; + /* One BTS */ struct gsm_bts { /* list header in net->bts_list */ @@ -596,8 +602,8 @@ /* supported codecs beside FR */ struct bts_codec_conf codec; - /* BTS dependencies bit field */ - uint32_t depends_on[256/(8*4)]; + /* BTS dependencies bit field, list of "struct bts_depends_on_entry" */ + struct llist_head depends_on; /* full and half rate multirate config */ struct amr_multirate_conf mr_full; @@ -830,10 +836,10 @@ } /* dependency handling */ -void bts_depend_mark(struct gsm_bts *bts, int dep); +int bts_depend_mark(struct gsm_bts *bts, int dep); void bts_depend_clear(struct gsm_bts *bts, int dep); -int bts_depend_check(struct gsm_bts *bts); -int bts_depend_is_depedency(struct gsm_bts *base, struct gsm_bts *other); +bool bts_depend_check(struct gsm_bts *bts); +bool bts_depend_is_depedency(struct gsm_bts *base, struct gsm_bts *other); int gsm_bts_get_radio_link_timeout(const struct gsm_bts *bts); void gsm_bts_set_radio_link_timeout(struct gsm_bts *bts, int value); diff --git a/src/osmo-bsc/bts.c b/src/osmo-bsc/bts.c index 8cc9e9a..28d4c65 100644 --- a/src/osmo-bsc/bts.c +++ b/src/osmo-bsc/bts.c @@ -343,6 +343,7 @@ INIT_LLIST_HEAD(&bts->neighbors); INIT_LLIST_HEAD(&bts->oml_fail_rep); INIT_LLIST_HEAD(&bts->chan_rqd_queue); + INIT_LLIST_HEAD(&bts->depends_on); /* Don't pin the BTS to any MGW by default: */ bts->mgw_pool_target = -1; @@ -869,37 +870,43 @@ } } -/* Assume there are only 256 possible bts */ -osmo_static_assert(sizeof(((struct gsm_bts *) 0)->nr) == 1, _bts_nr_is_256); -static void depends_calc_index_bit(int bts_nr, int *idx, int *bit) +int bts_depend_mark(struct gsm_bts *bts, int dep) { - *idx = bts_nr / (8 * 4); - *bit = bts_nr % (8 * 4); + struct bts_depends_on_entry *entry; + entry = talloc_zero(bts, struct bts_depends_on_entry); + if (!entry) { + LOG_BTS(bts, DNM, LOGL_ERROR, "Alloc of struct bts_depends_on_entry failed"); + return -1; + } + entry->bts_nr = dep; + llist_add_tail(&entry->list, &bts->depends_on); + return 0; } -void bts_depend_mark(struct gsm_bts *bts, int dep) +static struct bts_depends_on_entry *bts_depend_find_entry(const struct gsm_bts *bts, int dep) { - int idx, bit; - depends_calc_index_bit(dep, &idx, &bit); - - bts->depends_on[idx] |= 1U << bit; + struct bts_depends_on_entry *entry; + llist_for_each_entry(entry, &bts->trx_list, list) { + if (entry->bts_nr == dep) + return entry; + } + return NULL; } void bts_depend_clear(struct gsm_bts *bts, int dep) { - int idx, bit; - depends_calc_index_bit(dep, &idx, &bit); - - bts->depends_on[idx] &= ~(1U << bit); + struct bts_depends_on_entry *entry; + entry = bts_depend_find_entry(bts, dep); + if (!entry) + return; + llist_del(&entry->list); + talloc_free(entry); } -int bts_depend_is_depedency(struct gsm_bts *base, struct gsm_bts *other) +bool bts_depend_is_depedency(struct gsm_bts *base, struct gsm_bts *other) { - int idx, bit; - depends_calc_index_bit(other->nr, &idx, &bit); - - /* Check if there is a depends bit */ - return (base->depends_on[idx] & (1U << bit)) > 0; + struct bts_depends_on_entry *entry = bts_depend_find_entry(base, other->nr); + return !!entry; } static bool bts_is_online(const struct gsm_bts *bts) @@ -914,7 +921,7 @@ return bts->mo.nm_state.operational == NM_OPSTATE_ENABLED; } -int bts_depend_check(struct gsm_bts *bts) +bool bts_depend_check(struct gsm_bts *bts) { struct gsm_bts *other_bts; @@ -923,9 +930,9 @@ continue; if (bts_is_online(other_bts)) continue; - return 0; + return false; } - return 1; + return true; } /* get the radio link timeout (based on SACCH decode errors, according diff --git a/src/osmo-bsc/bts_vty.c b/src/osmo-bsc/bts_vty.c index 24224f6..3c0c2ef 100644 --- a/src/osmo-bsc/bts_vty.c +++ b/src/osmo-bsc/bts_vty.c @@ -2633,7 +2633,8 @@ return CMD_WARNING; } - bts_depend_mark(bts, dep); + if (bts_depend_mark(bts, dep) < 0) + return CMD_WARNING; return CMD_SUCCESS; } @@ -4490,6 +4491,14 @@ vty_out(vty, "%s", VTY_NEWLINE); } +static void config_write_bts_depends_on(struct vty *vty, const char *prefix, const struct gsm_bts *bts) +{ + struct bts_depends_on_entry *entry; + llist_for_each_entry(entry, &bts->depends_on, list) { + vty_out(vty, "%sdepends-on-bts %u%s", prefix, entry->bts_nr, VTY_NEWLINE); + } +} + static void config_write_bts_single(struct vty *vty, struct gsm_bts *bts) { int i; @@ -4775,23 +4784,7 @@ vty_out(vty, " %sforce-combined-si%s", bts->force_combined_si ? "" : "no ", VTY_NEWLINE); - for (i = 0; i < ARRAY_SIZE(bts->depends_on); ++i) { - int j; - - if (bts->depends_on[i] == 0) - continue; - - for (j = 0; j < sizeof(bts->depends_on[i]) * 8; ++j) { - int bts_nr; - - if ((bts->depends_on[i] & (1<<j)) == 0) - continue; - - bts_nr = (i * sizeof(bts->depends_on[i]) * 8) + j; - vty_out(vty, " depends-on-bts %d%s", bts_nr, VTY_NEWLINE); - } - } - + config_write_bts_depends_on(vty, " ", bts); ho_vty_write_bts(vty, bts); if (bts->top_acch_cap.overpower_db > 0) { -- To view, visit https://gerrit.osmocom.org/c/osmo-bsc/+/38050?usp=email To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings?usp=email Gerrit-MessageType: merged Gerrit-Project: osmo-bsc Gerrit-Branch: master Gerrit-Change-Id: I59e37d6baa020aeafdffc2c3538e988effd37620 Gerrit-Change-Number: 38050 Gerrit-PatchSet: 6 Gerrit-Owner: pespin <pespin(a)sysmocom.de> Gerrit-Reviewer: Jenkins Builder Gerrit-Reviewer: dexter <pmaier(a)sysmocom.de> Gerrit-Reviewer: fixeria <vyanitskiy(a)sysmocom.de> Gerrit-Reviewer: laforge <laforge(a)osmocom.org> Gerrit-Reviewer: pespin <pespin(a)sysmocom.de>
1 0
0 0
[M] Change in osmo-bsc[master]: Introduce typedef for bts->nr gsm_bts_nr_t
by pespin 10 Sep '24

10 Sep '24
pespin has submitted this change. ( https://gerrit.osmocom.org/c/osmo-bsc/+/38051?usp=email ) Change subject: Introduce typedef for bts->nr gsm_bts_nr_t ...................................................................... Introduce typedef for bts->nr gsm_bts_nr_t The size of bts->nr is implicitly or explicitly used or taken into account in several places in the code. Add a new type to make it easier to define its size and range in one place. This also helps in identifying fields contains an BSC-implementation "bts_nr" vs theip.access Abis OML "bts_nr" sent over the wire, which is always a uint8_t according to spec. Related: SYS#7062 Change-Id: Ic0db2873fa9795024aba4399da495a0d8f7504b0 --- M include/osmocom/bsc/bts.h M include/osmocom/bsc/gsm_data.h M src/osmo-bsc/abis_nm_vty.c M src/osmo-bsc/abis_om2000_vty.c M src/osmo-bsc/bsc_vty.c M src/osmo-bsc/bts.c M src/osmo-bsc/bts_vty.c M src/osmo-bsc/gsm_data.c M src/osmo-bsc/neighbor_ident_vty.c M src/osmo-bsc/smscb_vty.c M tests/handover/handover_test.c 11 files changed, 66 insertions(+), 56 deletions(-) Approvals: laforge: Looks good to me, but someone else must approve pespin: Looks good to me, approved dexter: Looks good to me, but someone else must approve Jenkins Builder: Verified diff --git a/include/osmocom/bsc/bts.h b/include/osmocom/bsc/bts.h index f2f7217..a8680d8 100644 --- a/include/osmocom/bsc/bts.h +++ b/include/osmocom/bsc/bts.h @@ -329,7 +329,7 @@ /* See (struct gsm_bts *)->depends_on */ struct bts_depends_on_entry { struct llist_head list; - uint8_t bts_nr; /* See (struct gsm_bts *)->nr */ + gsm_bts_nr_t bts_nr; /* See (struct gsm_bts *)->nr */ }; /* One BTS */ @@ -341,7 +341,7 @@ struct llist_head loc_list; /* number of this BTS in network */ - uint8_t nr; + gsm_bts_nr_t nr; /* human readable name / description */ char *description; /* Cell Identity */ @@ -836,8 +836,8 @@ } /* dependency handling */ -int bts_depend_mark(struct gsm_bts *bts, int dep); -void bts_depend_clear(struct gsm_bts *bts, int dep); +int bts_depend_mark(struct gsm_bts *bts, gsm_bts_nr_t dep); +void bts_depend_clear(struct gsm_bts *bts, gsm_bts_nr_t dep); bool bts_depend_check(struct gsm_bts *bts); bool bts_depend_is_depedency(struct gsm_bts *base, struct gsm_bts *other); diff --git a/include/osmocom/bsc/gsm_data.h b/include/osmocom/bsc/gsm_data.h index 6bffcc4..d67ebc1 100644 --- a/include/osmocom/bsc/gsm_data.h +++ b/include/osmocom/bsc/gsm_data.h @@ -21,6 +21,7 @@ #include <osmocom/core/time_cc.h> #include <osmocom/core/linuxlist.h> #include <osmocom/core/linuxrbtree.h> +#include <osmocom/core/utils.h> #include <osmocom/crypt/auth.h> @@ -96,6 +97,13 @@ #define DLCI2RSL_LINK_ID(dlci) \ ((dlci & 0xc0) == 0xc0 ? 0x40 : 0x00) | (dlci & 0x07) +typedef uint8_t gsm_bts_nr_t; /* See (struct gsm_bts *)->nr */ +/* BTS_NR_MAX = ((2 << ((sizeof(gsm_bts_nr_t) * 8) - 1)) - 1) + * This is needed as a constant so that the value can be stringified properly: */ +#define BTS_NR_MAX 255 +#define BTS_NR_MAX_STR OSMO_STRINGIFY_VAL(BTS_NR_MAX) +#define BTS_NR_VTY_ARG_VAL "<0-" BTS_NR_MAX_STR ">" + /* 3-bit long values */ #define EARFCN_PRIO_INVALID 8 #define EARFCN_MEAS_BW_INVALID 8 @@ -881,7 +889,7 @@ struct gsm_network *gsm_network_init(void *ctx); -struct gsm_bts *gsm_bts_num(const struct gsm_network *net, int num); +struct gsm_bts *gsm_bts_num(const struct gsm_network *net, gsm_bts_nr_t num); struct gsm_bts *gsm_bts_by_cell_id(const struct gsm_network *net, const struct gsm0808_cell_id *cell_id, int match_idx); @@ -975,7 +983,7 @@ struct rate_ctr_group *bsc_ctrs; struct osmo_stat_item_group *bsc_statg; - unsigned int num_bts; + gsm_bts_nr_t num_bts; struct llist_head bts_list; struct llist_head bts_rejected; diff --git a/src/osmo-bsc/abis_nm_vty.c b/src/osmo-bsc/abis_nm_vty.c index bbd2d15..d7ddcb9 100644 --- a/src/osmo-bsc/abis_nm_vty.c +++ b/src/osmo-bsc/abis_nm_vty.c @@ -76,7 +76,7 @@ DEFUN(oml_class_inst, oml_class_inst_cmd, - "bts <0-255> oml class " NM_OBJCLASS_VTY + "bts " BTS_NR_VTY_ARG_VAL " oml class " NM_OBJCLASS_VTY " instance <0-255> <0-255> <0-255>", "BTS related commands\n" "BTS Number\n" "Manipulate the OML managed objects\n" @@ -111,7 +111,7 @@ } DEFUN(oml_classnum_inst, oml_classnum_inst_cmd, - "bts <0-255> oml class <0-255> instance <0-255> <0-255> <0-255>", + "bts " BTS_NR_VTY_ARG_VAL " oml class <0-255> instance <0-255> <0-255> <0-255>", "BTS related commands\n" "BTS Number\n" "Manipulate the OML managed objects\n" "Object Class\n" "Object Class\n" diff --git a/src/osmo-bsc/abis_om2000_vty.c b/src/osmo-bsc/abis_om2000_vty.c index 7604807..efec05e 100644 --- a/src/osmo-bsc/abis_om2000_vty.c +++ b/src/osmo-bsc/abis_om2000_vty.c @@ -79,7 +79,7 @@ #define OM2K_VTY_HELP "Configure OM2K specific parameters\n" DEFUN(om2k_class_inst, om2k_class_inst_cmd, - "bts <0-255> om2000 class " OM2K_OBJCLASS_VTY + "bts " BTS_NR_VTY_ARG_VAL " om2000 class " OM2K_OBJCLASS_VTY " <0-255> <0-255> <0-255>", "BTS related commands\n" "BTS Number\n" "Manipulate the OM2000 managed objects\n" @@ -120,7 +120,7 @@ } DEFUN(om2k_classnum_inst, om2k_classnum_inst_cmd, - "bts <0-255> om2000 class <0-255> <0-255> <0-255> <0-255>", + "bts " BTS_NR_VTY_ARG_VAL " om2000 class <0-255> <0-255> <0-255> <0-255>", "BTS related commands\n" "BTS Number\n" "Manipulate the OML managed objects\n" "Object Class\n" "Object Class\n" @@ -748,7 +748,7 @@ } DEFUN(show_om2k_mo, show_om2k_mo_cmd, - "show bts <0-255> om2k-mo", + "show bts " BTS_NR_VTY_ARG_VAL " om2k-mo", SHOW_STR "Display information about a BTS\n" "BTS number\n" "OM2000 Managed Object information\n") { diff --git a/src/osmo-bsc/bsc_vty.c b/src/osmo-bsc/bsc_vty.c index 8690a47..f04c7ec 100644 --- a/src/osmo-bsc/bsc_vty.c +++ b/src/osmo-bsc/bsc_vty.c @@ -232,7 +232,7 @@ return CMD_SUCCESS; } -DEFUN(show_bts, show_bts_cmd, "show bts [<0-255>]", +DEFUN(show_bts, show_bts_cmd, "show bts [" BTS_NR_VTY_ARG_VAL "]", SHOW_STR "Display information about a BTS\n" "BTS number\n") { @@ -273,7 +273,7 @@ return CMD_SUCCESS; } -DEFUN(show_bts_fail_rep, show_bts_fail_rep_cmd, "show bts <0-255> fail-rep [reset]", +DEFUN(show_bts_fail_rep, show_bts_fail_rep_cmd, "show bts " BTS_NR_VTY_ARG_VAL " fail-rep [reset]", SHOW_STR "Display information about a BTS\n" "BTS number\n" "OML failure reports\n" "Clear the list of failure reports after showing them\n") @@ -457,7 +457,7 @@ DEFUN(show_trx, show_trx_cmd, - "show trx [<0-255>] [<0-255>]", + "show trx [" BTS_NR_VTY_ARG_VAL "] [<0-255>]", SHOW_STR "Display information about a TRX\n" BTS_TRX_STR) { @@ -500,7 +500,7 @@ DEFUN(show_ts, show_ts_cmd, - "show timeslot [<0-255>] [<0-255>] [<0-7>]", + "show timeslot [" BTS_NR_VTY_ARG_VAL "] [<0-255>] [<0-7>]", SHOW_STR "Display information about a TS\n" BTS_TRX_TS_STR) { @@ -727,7 +727,7 @@ DEFUN(show_lchan, show_lchan_cmd, - "show lchan [<0-255>] [<0-255>] [<0-7>] [<0-7>]", + "show lchan [" BTS_NR_VTY_ARG_VAL "] [<0-255>] [<0-7>] [<0-7>]", SHOW_STR "Display information about a logical channel\n" BTS_TRX_TS_LCHAN_STR) { @@ -736,7 +736,7 @@ DEFUN(show_lchan_summary, show_lchan_summary_cmd, - "show lchan summary [<0-255>] [<0-255>] [<0-7>] [<0-7>]", + "show lchan summary [" BTS_NR_VTY_ARG_VAL "] [<0-255>] [<0-7>] [<0-7>]", SHOW_STR "Display information about a logical channel\n" "Short summary (used lchans)\n" BTS_TRX_TS_LCHAN_STR) @@ -746,7 +746,7 @@ DEFUN(show_lchan_summary_all, show_lchan_summary_all_cmd, - "show lchan summary-all [<0-255>] [<0-255>] [<0-7>] [<0-7>]", + "show lchan summary-all [" BTS_NR_VTY_ARG_VAL "] [<0-255>] [<0-7>] [<0-7>]", SHOW_STR "Display information about a logical channel\n" "Short summary (all lchans)\n" BTS_TRX_TS_LCHAN_STR) @@ -912,7 +912,7 @@ DEFUN(handover_subscr_conn, handover_subscr_conn_cmd, - "bts <0-255> trx <0-255> timeslot <0-7> sub-slot <0-7> handover <0-255>", + "bts " BTS_NR_VTY_ARG_VAL " trx <0-255> timeslot <0-7> sub-slot <0-7> handover " BTS_NR_VTY_ARG_VAL, BTS_NR_TRX_TS_SS_STR2 MANUAL_HANDOVER_STR "New " BTS_NR_STR) @@ -922,7 +922,7 @@ DEFUN(assignment_subscr_conn, assignment_subscr_conn_cmd, - "bts <0-255> trx <0-255> timeslot <0-7> sub-slot <0-7> assignment", + "bts " BTS_NR_VTY_ARG_VAL " trx <0-255> timeslot <0-7> sub-slot <0-7> assignment", BTS_NR_TRX_TS_SS_STR2 MANUAL_ASSIGNMENT_STR) { @@ -1089,7 +1089,7 @@ DEFUN(show_paging, show_paging_cmd, - "show paging [<0-255>]", + "show paging [" BTS_NR_VTY_ARG_VAL "]", SHOW_STR "Display information about paging requests of a BTS\n" BTS_NR_STR) { @@ -1120,7 +1120,7 @@ DEFUN(show_paging_group, show_paging_group_cmd, - "show paging-group <0-255> IMSI", + "show paging-group " BTS_NR_VTY_ARG_VAL " IMSI", SHOW_STR "Display the paging group\n" BTS_NR_STR "IMSI\n") { @@ -1313,7 +1313,7 @@ } DEFUN(restart_bts, restart_bts_cmd, - "restart-bts <0-65535>", + "restart-bts " BTS_NR_VTY_ARG_VAL, "Restart ip.access nanoBTS through OML\n" BTS_NR_STR) { @@ -1352,7 +1352,7 @@ DEFUN(bts_resend_sysinfo, bts_resend_sysinfo_cmd, - "bts <0-255> resend-system-information", + "bts " BTS_NR_VTY_ARG_VAL " resend-system-information", "BTS Specific Commands\n" BTS_NR_STR "Re-generate + re-send BCCH SYSTEM INFORMATION\n") { @@ -1386,7 +1386,7 @@ DEFUN(bts_resend_power_ctrl_params, bts_resend_power_ctrl_params_cmd, - "bts <0-255> resend-power-control-defaults", + "bts " BTS_NR_VTY_ARG_VAL " resend-power-control-defaults", "BTS Specific Commands\n" BTS_NR_STR "Re-generate + re-send default MS/BS Power control parameters\n") { @@ -1425,7 +1425,7 @@ DEFUN(bts_c0_power_red, bts_c0_power_red_cmd, - "bts <0-255> c0-power-reduction <0-6>", + "bts " BTS_NR_VTY_ARG_VAL " c0-power-reduction <0-6>", "BTS Specific Commands\n" BTS_NR_STR "BCCH carrier power reduction operation\n" "Power reduction value (in dB, even numbers only)\n") @@ -1469,7 +1469,7 @@ /* this command is now hidden, as it's a low-level debug hack, and people should * instead use osmo-cbc these days */ DEFUN_HIDDEN(smscb_cmd, smscb_cmd_cmd, - "bts <0-255> smscb-command (normal|schedule|default) <1-4> HEXSTRING", + "bts " BTS_NR_VTY_ARG_VAL " smscb-command (normal|schedule|default) <1-4> HEXSTRING", "BTS related commands\n" BTS_NR_STR "SMS Cell Broadcast\n" "Normal (one-shot) SMSCB Message; sent once over Abis+Um\n" @@ -1539,7 +1539,7 @@ } DEFUN(pdch_act, pdch_act_cmd, - "bts <0-255> trx <0-255> timeslot <0-7> pdch (activate|deactivate)", + "bts " BTS_NR_VTY_ARG_VAL " trx <0-255> timeslot <0-7> pdch (activate|deactivate)", BTS_NR_TRX_TS_STR2 "Packet Data Channel\n" "Activate Dynamic PDCH/TCH (-> PDCH mode)\n" @@ -1796,7 +1796,7 @@ * manually in a given mode/codec. This is useful for receiver * performance testing (FER/RBER/...) */ DEFUN(lchan_act, lchan_act_cmd, - "bts <0-255> trx <0-255> timeslot <0-7> (sub-slot|vamos-sub-slot) <0-7> (activate|activate-vamos) (hr|fr|efr|amr|sig) [<0-7>]", + "bts " BTS_NR_VTY_ARG_VAL " trx <0-255> timeslot <0-7> (sub-slot|vamos-sub-slot) <0-7> (activate|activate-vamos) (hr|fr|efr|amr|sig) [<0-7>]", BTS_NR_TRX_TS_STR2 "Primary sub-slot\n" "VAMOS secondary shadow subslot, range <0-1>, only valid for TCH type timeslots\n" SS_NR_STR @@ -1808,7 +1808,7 @@ } DEFUN(lchan_deact, lchan_deact_cmd, - "bts <0-255> trx <0-255> timeslot <0-7> (sub-slot|vamos-sub-slot) <0-7> deactivate", + "bts " BTS_NR_VTY_ARG_VAL " trx <0-255> timeslot <0-7> (sub-slot|vamos-sub-slot) <0-7> deactivate", BTS_NR_TRX_TS_STR2 "Primary sub-slot\n" "VAMOS secondary shadow subslot, range <0-1>, only valid for TCH type timeslots\n" SS_NR_STR @@ -1855,7 +1855,7 @@ /* Similar to lchan_act, but activates all lchans on the specified BTS at once, * this is intended to perform lab tests / measurements. */ DEFUN_HIDDEN(lchan_act_all_bts, lchan_act_all_bts_cmd, - "bts <0-255> (activate-all-lchan|deactivate-all-lchan)", + "bts " BTS_NR_VTY_ARG_VAL " (activate-all-lchan|deactivate-all-lchan)", "BTS Specific Commands\n" BTS_NR_STR ACTIVATE_ALL_LCHANS_STR DEACTIVATE_ALL_LCHANS_STR) @@ -1895,7 +1895,7 @@ /* Similar to lchan_act, but activates all lchans on the specified BTS at once, * this is intended to perform lab tests / measurements. */ DEFUN_HIDDEN(lchan_act_all_trx, lchan_act_all_trx_cmd, - "bts <0-255> trx <0-255> (activate-all-lchan|deactivate-all-lchan)", + "bts " BTS_NR_VTY_ARG_VAL " trx <0-255> (activate-all-lchan|deactivate-all-lchan)", "BTS for manual command\n" BTS_NR_STR "TRX for manual command\n" TRX_NR_STR ACTIVATE_ALL_LCHANS_STR @@ -1937,7 +1937,7 @@ } DEFUN(lchan_set_mspower, lchan_set_mspower_cmd, - "bts <0-255> trx <0-255> timeslot <0-7> sub-slot <0-7> ms-power <0-40> [verify]\n", + "bts " BTS_NR_VTY_ARG_VAL " trx <0-255> timeslot <0-7> sub-slot <0-7> ms-power <0-40> [verify]\n", BTS_NR_TRX_TS_SS_STR2 "Manually force MS Uplink Power Level in dBm on the lchan (for testing)\n" "Set transmit power of the MS in dBm\n" @@ -1988,7 +1988,7 @@ } DEFUN(vamos_modify_lchan, vamos_modify_lchan_cmd, - "bts <0-255> trx <0-255> timeslot <0-7> sub-slot <0-7> modify (vamos|non-vamos) " TSC_ARGS_OPT, + "bts " BTS_NR_VTY_ARG_VAL " trx <0-255> timeslot <0-7> sub-slot <0-7> modify (vamos|non-vamos) " TSC_ARGS_OPT, BTS_NR_TRX_TS_SS_STR2 "Manually send Channel Mode Modify (for debugging)\n" "Enable VAMOS channel mode\n" "Disable VAMOS channel mode\n" @@ -2026,7 +2026,7 @@ /* Debug command to send lchans from state LCHAN_ST_UNUSED to state * LCHAN_ST_BORKEN and vice versa. */ DEFUN_HIDDEN(lchan_set_borken, lchan_set_borken_cmd, - "bts <0-255> trx <0-255> timeslot <0-7> sub-slot <0-7> (borken|unused)", + "bts " BTS_NR_VTY_ARG_VAL " trx <0-255> timeslot <0-7> sub-slot <0-7> (borken|unused)", BTS_NR_TRX_TS_SS_STR2 "send lchan to state LCHAN_ST_BORKEN (for debugging)\n" "send lchan to state LCHAN_ST_UNUSED (for debugging)\n") @@ -2071,7 +2071,7 @@ } DEFUN(lchan_mdcx, lchan_mdcx_cmd, - "bts <0-255> trx <0-255> timeslot <0-7> sub-slot <0-7> mdcx A.B.C.D <0-65535>", + "bts " BTS_NR_VTY_ARG_VAL " trx <0-255> timeslot <0-7> sub-slot <0-7> mdcx A.B.C.D <0-65535>", BTS_NR_TRX_TS_SS_STR2 "Modify RTP Connection\n" "MGW IP Address\n" "MGW UDP Port\n") { @@ -2109,7 +2109,7 @@ } DEFUN(lchan_reassign, lchan_reassign_cmd, - "bts <0-255> trx <0-255> timeslot <0-7> (sub-slot|vamos-sub-slot) <0-7> " + "bts " BTS_NR_VTY_ARG_VAL " trx <0-255> timeslot <0-7> (sub-slot|vamos-sub-slot) <0-7> " "reassign-to trx <0-255> timeslot <0-7> (sub-slot|vamos-sub-slot) <0-7> " TSC_ARGS_OPT, BTS_NR_TRX_TS_STR2 @@ -3219,7 +3219,7 @@ DEFUN(bts_unblock_setup_ramping, bts_unblock_setup_ramping_cmd, - "bts <0-255> unblock-setup-ramping", + "bts " BTS_NR_VTY_ARG_VAL " unblock-setup-ramping", "BTS Specific Commands\n" BTS_NR_STR "Unblock and allow to configure a BTS if kept back by BTS ramping\n") { @@ -3325,7 +3325,7 @@ DEFUN(gen_position_trap, gen_position_trap_cmd, - "generate-location-state-trap <0-255>", + "generate-location-state-trap " BTS_NR_VTY_ARG_VAL, "Generate location state report\n" "BTS to report\n") { diff --git a/src/osmo-bsc/bts.c b/src/osmo-bsc/bts.c index 28d4c65..260e24e 100644 --- a/src/osmo-bsc/bts.c +++ b/src/osmo-bsc/bts.c @@ -870,7 +870,7 @@ } } -int bts_depend_mark(struct gsm_bts *bts, int dep) +int bts_depend_mark(struct gsm_bts *bts, gsm_bts_nr_t dep) { struct bts_depends_on_entry *entry; entry = talloc_zero(bts, struct bts_depends_on_entry); @@ -883,7 +883,7 @@ return 0; } -static struct bts_depends_on_entry *bts_depend_find_entry(const struct gsm_bts *bts, int dep) +static struct bts_depends_on_entry *bts_depend_find_entry(const struct gsm_bts *bts, gsm_bts_nr_t dep) { struct bts_depends_on_entry *entry; llist_for_each_entry(entry, &bts->trx_list, list) { @@ -893,7 +893,7 @@ return NULL; } -void bts_depend_clear(struct gsm_bts *bts, int dep) +void bts_depend_clear(struct gsm_bts *bts, gsm_bts_nr_t dep) { struct bts_depends_on_entry *entry; entry = bts_depend_find_entry(bts, dep); diff --git a/src/osmo-bsc/bts_vty.c b/src/osmo-bsc/bts_vty.c index 3c0c2ef..81c4022 100644 --- a/src/osmo-bsc/bts_vty.c +++ b/src/osmo-bsc/bts_vty.c @@ -106,7 +106,7 @@ /* per-BTS configuration */ DEFUN_ATTR(cfg_bts, cfg_bts_cmd, - "bts <0-255>", + "bts " BTS_NR_VTY_ARG_VAL, "Select a BTS to configure\n" BTS_NR_STR, CMD_ATTR_IMMEDIATE) @@ -2605,7 +2605,7 @@ } DEFUN_ATTR(cfg_bts_depends_on, cfg_bts_depends_on_cmd, - "depends-on-bts <0-255>", + "depends-on-bts " BTS_NR_VTY_ARG_VAL, "This BTS can only be started if another one is up\n" BTS_NR_STR, CMD_ATTR_IMMEDIATE) { @@ -2639,7 +2639,7 @@ } DEFUN_ATTR(cfg_bts_no_depends_on, cfg_bts_no_depends_on_cmd, - "no depends-on-bts <0-255>", + "no depends-on-bts " BTS_NR_VTY_ARG_VAL, NO_STR "This BTS can only be started if another one is up\n" BTS_NR_STR, CMD_ATTR_IMMEDIATE) { diff --git a/src/osmo-bsc/gsm_data.c b/src/osmo-bsc/gsm_data.c index b11607e..814cd56 100644 --- a/src/osmo-bsc/gsm_data.c +++ b/src/osmo-bsc/gsm_data.c @@ -49,6 +49,8 @@ void *tall_bsc_ctx = NULL; +osmo_static_assert(BTS_NR_MAX == ((2 << ((sizeof(gsm_bts_nr_t) * 8) - 1)) - 1), _gsm_bts_nr_t_size); + void set_ts_e1link(struct gsm_bts_trx_ts *ts, uint8_t e1_nr, uint8_t e1_ts, uint8_t e1_ts_ss) { @@ -250,7 +252,7 @@ return get_value_string(chreq_names, c); } -struct gsm_bts *gsm_bts_num(const struct gsm_network *net, int num) +struct gsm_bts *gsm_bts_num(const struct gsm_network *net, gsm_bts_nr_t num) { struct gsm_bts *bts; diff --git a/src/osmo-bsc/neighbor_ident_vty.c b/src/osmo-bsc/neighbor_ident_vty.c index 44b9057..5cdab11 100644 --- a/src/osmo-bsc/neighbor_ident_vty.c +++ b/src/osmo-bsc/neighbor_ident_vty.c @@ -57,7 +57,7 @@ #define CGI_PS_ARGC 5 #define CGI_PS_DOC "Neighbor cell by cgi (Packet Switched, with RAC)\n" "MCC\n" "MNC\n" "LAC\n" "RAC\n" "CI\n" -#define LOCAL_BTS_PARAMS "bts <0-255>" +#define LOCAL_BTS_PARAMS "bts " BTS_NR_VTY_ARG_VAL #define LOCAL_BTS_DOC "Neighbor cell by local BTS number\n" "BTS number\n" static int neighbor_ident_vty_parse_lac(struct vty *vty, struct gsm0808_cell_id *cell_id, const char **argv) @@ -579,7 +579,7 @@ } DEFUN(show_bts_neighbor, show_bts_neighbor_cmd, - "show bts <0-255> neighbor " CELL_AB_VTY_PARAMS, + "show bts " BTS_NR_VTY_ARG_VAL " neighbor " CELL_AB_VTY_PARAMS, SHOW_STR "Display information about a BTS\n" "BTS number\n" "Query which cell would be the target for this neighbor ARFCN+BSIC\n" CELL_AB_VTY_DOC) diff --git a/src/osmo-bsc/smscb_vty.c b/src/osmo-bsc/smscb_vty.c index b13d2db..c43866e 100644 --- a/src/osmo-bsc/smscb_vty.c +++ b/src/osmo-bsc/smscb_vty.c @@ -391,7 +391,7 @@ } DEFUN(bts_show_cbs, bts_show_cbs_cmd, - "show bts <0-255> smscb [(basic|extended)]", + "show bts " BTS_NR_VTY_ARG_VAL " smscb [(basic|extended)]", SHOW_STR "Display information about a BTS\n" "BTS number\n" "SMS Cell Broadcast State\n" "Show only information related to CBCH BASIC\n" diff --git a/tests/handover/handover_test.c b/tests/handover/handover_test.c index 174e9e1..e4c7873 100644 --- a/tests/handover/handover_test.c +++ b/tests/handover/handover_test.c @@ -847,7 +847,7 @@ return trx; } -#define LCHAN_ARGS "lchan <0-255> <0-255> <0-7> <0-7>" +#define LCHAN_ARGS "lchan " BTS_NR_VTY_ARG_VAL " <0-255> <0-7> <0-7>" #define LCHAN_ARGS_DOC "identify an lchan\nBTS nr\nTRX nr\nTimeslot nr\nSubslot nr\n" static struct gsm_lchan *parse_lchan_args(const char **argv) @@ -858,7 +858,7 @@ return &ts->lchan[atoi(argv[3])]; } -#define LCHAN_WILDCARD_ARGS "lchan (<0-255>|*) (<0-255>|*) (<0-7>|*) (<0-7>|*)" +#define LCHAN_WILDCARD_ARGS "lchan (" BTS_NR_VTY_ARG_VAL "|*) (<0-255>|*) (<0-7>|*) (<0-7>|*)" #define LCHAN_WILDCARD_ARGS_DOC "identify an lchan\nBTS nr\nall BTS\nTRX nr\nall BTS\nTimeslot nr\nall TS\nSubslot nr\nall subslots\n" static void parse_lchan_wildcard_args(const char **argv, void (*cb)(struct gsm_lchan*, void*), void *cb_data) @@ -1104,7 +1104,7 @@ } DEFUN(res_ind, res_ind_cmd, - "res-ind trx <0-255> <0-255> levels .LEVELS", + "res-ind trx " BTS_NR_VTY_ARG_VAL " <0-255> levels .LEVELS", "Send Resource Indication for a specific TRX, indicating interference levels per lchan\n" "Indicate a BTS and TRX\n" "BTS nr\n" "TRX nr\n" "Indicate interference levels: each level is an index to bts->interf_meas_params.bounds_dbm[]," @@ -1398,7 +1398,7 @@ } DEFUN(expect_ts_use, expect_ts_use_cmd, - "expect-ts-use trx <0-255> <0-255> states" TS_USE TS_USE TS_USE TS_USE TS_USE TS_USE TS_USE TS_USE, + "expect-ts-use trx " BTS_NR_VTY_ARG_VAL " <0-255> states" TS_USE TS_USE TS_USE TS_USE TS_USE TS_USE TS_USE TS_USE, "Expect timeslots of a BTS' TRX to be in a specific state\n" "Indicate a BTS and TRX\n" "BTS nr\n" "TRX nr\n" "List of 8 expected TS states\n" @@ -1435,7 +1435,7 @@ } DEFUN(set_arfcn, set_arfcn_cmd, - "set-arfcn trx <0-255> <0-255> <0-1023>", + "set-arfcn trx " BTS_NR_VTY_ARG_VAL " <0-255> <0-1023>", "Set the ARFCN for a BTS' TRX\n" "Indicate a BTS and TRX\n" "BTS nr\n" "TRX nr\n" "Absolute Radio Frequency Channel Number\n") @@ -1467,7 +1467,7 @@ } DEFUN(set_band, set_band_cmd, - "set-band bts <0-255> BAND", + "set-band bts " BTS_NR_VTY_ARG_VAL " BAND", "Set the frequency band for a BTS\n" "Indicate a BTS\n" "BTS nr\n" "Frequency band\n") @@ -1488,7 +1488,7 @@ } DEFUN(set_ts_use, set_ts_use_cmd, - "set-ts-use trx <0-255> <0-255> states" TS_USE TS_USE TS_USE TS_USE TS_USE TS_USE TS_USE TS_USE, + "set-ts-use trx " BTS_NR_VTY_ARG_VAL " <0-255> states" TS_USE TS_USE TS_USE TS_USE TS_USE TS_USE TS_USE TS_USE, "Put timeslots of a BTS' TRX into a specific state\n" "Indicate a BTS and TRX\n" "BTS nr\n" "TRX nr\n" "List of 8 TS states to apply\n" -- To view, visit https://gerrit.osmocom.org/c/osmo-bsc/+/38051?usp=email To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings?usp=email Gerrit-MessageType: merged Gerrit-Project: osmo-bsc Gerrit-Branch: master Gerrit-Change-Id: Ic0db2873fa9795024aba4399da495a0d8f7504b0 Gerrit-Change-Number: 38051 Gerrit-PatchSet: 6 Gerrit-Owner: pespin <pespin(a)sysmocom.de> Gerrit-Reviewer: Jenkins Builder Gerrit-Reviewer: dexter <pmaier(a)sysmocom.de> Gerrit-Reviewer: laforge <laforge(a)osmocom.org> Gerrit-Reviewer: pespin <pespin(a)sysmocom.de>
1 0
0 0
[S] Change in osmo-bsc[master]: tests/vty: Validate allocating all possible BTS
by pespin 10 Sep '24

10 Sep '24
pespin has posted comments on this change by pespin. ( https://gerrit.osmocom.org/c/osmo-bsc/+/38064?usp=email ) Change subject: tests/vty: Validate allocating all possible BTS ...................................................................... Patch Set 4: Code-Review+2 -- To view, visit https://gerrit.osmocom.org/c/osmo-bsc/+/38064?usp=email To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings?usp=email Gerrit-MessageType: comment Gerrit-Project: osmo-bsc Gerrit-Branch: master Gerrit-Change-Id: I91603872de1287e8f69edd05a1f485e03909b3b4 Gerrit-Change-Number: 38064 Gerrit-PatchSet: 4 Gerrit-Owner: pespin <pespin(a)sysmocom.de> Gerrit-Reviewer: Jenkins Builder Gerrit-Reviewer: dexter <pmaier(a)sysmocom.de> Gerrit-Reviewer: laforge <laforge(a)osmocom.org> Gerrit-Reviewer: pespin <pespin(a)sysmocom.de> Gerrit-Comment-Date: Tue, 10 Sep 2024 12:05:15 +0000 Gerrit-HasComments: No Gerrit-Has-Labels: Yes
1 0
0 0
[M] Change in osmo-bsc[master]: Introduce typedef for bts->nr gsm_bts_nr_t
by pespin 10 Sep '24

10 Sep '24
pespin has posted comments on this change by pespin. ( https://gerrit.osmocom.org/c/osmo-bsc/+/38051?usp=email ) Change subject: Introduce typedef for bts->nr gsm_bts_nr_t ...................................................................... Patch Set 6: Code-Review+2 -- To view, visit https://gerrit.osmocom.org/c/osmo-bsc/+/38051?usp=email To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings?usp=email Gerrit-MessageType: comment Gerrit-Project: osmo-bsc Gerrit-Branch: master Gerrit-Change-Id: Ic0db2873fa9795024aba4399da495a0d8f7504b0 Gerrit-Change-Number: 38051 Gerrit-PatchSet: 6 Gerrit-Owner: pespin <pespin(a)sysmocom.de> Gerrit-Reviewer: Jenkins Builder Gerrit-Reviewer: dexter <pmaier(a)sysmocom.de> Gerrit-Reviewer: laforge <laforge(a)osmocom.org> Gerrit-Reviewer: pespin <pespin(a)sysmocom.de> Gerrit-Comment-Date: Tue, 10 Sep 2024 12:05:11 +0000 Gerrit-HasComments: No Gerrit-Has-Labels: Yes
1 0
0 0
[M] Change in osmo-bsc[master]: Convert bts->depends_on from bitmask to llist
by pespin 10 Sep '24

10 Sep '24
Attention is currently required from: dexter, fixeria, laforge. pespin has posted comments on this change by pespin. ( https://gerrit.osmocom.org/c/osmo-bsc/+/38050?usp=email ) Change subject: Convert bts->depends_on from bitmask to llist ...................................................................... Patch Set 6: Code-Review+2 -- To view, visit https://gerrit.osmocom.org/c/osmo-bsc/+/38050?usp=email To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings?usp=email Gerrit-MessageType: comment Gerrit-Project: osmo-bsc Gerrit-Branch: master Gerrit-Change-Id: I59e37d6baa020aeafdffc2c3538e988effd37620 Gerrit-Change-Number: 38050 Gerrit-PatchSet: 6 Gerrit-Owner: pespin <pespin(a)sysmocom.de> Gerrit-Reviewer: Jenkins Builder Gerrit-Reviewer: dexter <pmaier(a)sysmocom.de> Gerrit-Reviewer: fixeria <vyanitskiy(a)sysmocom.de> Gerrit-Reviewer: laforge <laforge(a)osmocom.org> Gerrit-Reviewer: pespin <pespin(a)sysmocom.de> Gerrit-Attention: laforge <laforge(a)osmocom.org> Gerrit-Attention: fixeria <vyanitskiy(a)sysmocom.de> Gerrit-Attention: dexter <pmaier(a)sysmocom.de> Gerrit-Comment-Date: Tue, 10 Sep 2024 12:05:05 +0000 Gerrit-HasComments: No Gerrit-Has-Labels: Yes
1 0
0 0
[M] Change in osmo-bsc[master]: Convert bts->depends_on from bitmask to llist
by pespin 10 Sep '24

10 Sep '24
Attention is currently required from: dexter, fixeria, laforge. pespin has posted comments on this change by pespin. ( https://gerrit.osmocom.org/c/osmo-bsc/+/38050?usp=email ) Change subject: Convert bts->depends_on from bitmask to llist ...................................................................... Patch Set 5: (1 comment) Commit Message: https://gerrit.osmocom.org/c/osmo-bsc/+/38050/comment/eb9cd6c1_ca973a84?usp… : PS5, Line 14: iprevious code allocated (N * 256/8) bytes, where N is the amount of bts > iprevious? Done -- To view, visit https://gerrit.osmocom.org/c/osmo-bsc/+/38050?usp=email To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings?usp=email Gerrit-MessageType: comment Gerrit-Project: osmo-bsc Gerrit-Branch: master Gerrit-Change-Id: I59e37d6baa020aeafdffc2c3538e988effd37620 Gerrit-Change-Number: 38050 Gerrit-PatchSet: 5 Gerrit-Owner: pespin <pespin(a)sysmocom.de> Gerrit-Reviewer: Jenkins Builder Gerrit-Reviewer: dexter <pmaier(a)sysmocom.de> Gerrit-Reviewer: fixeria <vyanitskiy(a)sysmocom.de> Gerrit-Reviewer: laforge <laforge(a)osmocom.org> Gerrit-Attention: laforge <laforge(a)osmocom.org> Gerrit-Attention: fixeria <vyanitskiy(a)sysmocom.de> Gerrit-Attention: dexter <pmaier(a)sysmocom.de> Gerrit-Comment-Date: Tue, 10 Sep 2024 12:04:08 +0000 Gerrit-HasComments: Yes Gerrit-Has-Labels: No Comment-In-Reply-To: dexter <pmaier(a)sysmocom.de>
1 0
0 0
[M] Change in osmo-bsc[master]: Convert bts->depends_on from bitmask to llist
by pespin 10 Sep '24

10 Sep '24
Attention is currently required from: dexter, fixeria, laforge, pespin. Hello Jenkins Builder, dexter, fixeria, laforge, I'd like you to reexamine a change. Please visit https://gerrit.osmocom.org/c/osmo-bsc/+/38050?usp=email to look at the new patch set (#6). The following approvals got outdated and were removed: Code-Review+1 by dexter, Code-Review+1 by fixeria Change subject: Convert bts->depends_on from bitmask to llist ...................................................................... Convert bts->depends_on from bitmask to llist The amount of dependencies on each BTS is usually zero or a small number, hence the computation cost is mostly similar regardless of using a llist or a bitmask buffer. Right now, even if the dependency chains are (almost) empty, the previous code allocated (N * 256/8) bytes, where N is the amount of bts configured. Since we are now planning to increase the amount of bts (N) from uint8_t to uint16_t, that means with this change we will then avoid: * Increasing memory use to O(N * 65536/8). * Having to adapt code operating on bitmask (size) Related: SYS#7062 Change-Id: I59e37d6baa020aeafdffc2c3538e988effd37620 --- M include/osmocom/bsc/bts.h M src/osmo-bsc/bts.c M src/osmo-bsc/bts_vty.c 3 files changed, 52 insertions(+), 46 deletions(-) git pull ssh://gerrit.osmocom.org:29418/osmo-bsc refs/changes/50/38050/6 -- To view, visit https://gerrit.osmocom.org/c/osmo-bsc/+/38050?usp=email To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings?usp=email Gerrit-MessageType: newpatchset Gerrit-Project: osmo-bsc Gerrit-Branch: master Gerrit-Change-Id: I59e37d6baa020aeafdffc2c3538e988effd37620 Gerrit-Change-Number: 38050 Gerrit-PatchSet: 6 Gerrit-Owner: pespin <pespin(a)sysmocom.de> Gerrit-Reviewer: Jenkins Builder Gerrit-Reviewer: dexter <pmaier(a)sysmocom.de> Gerrit-Reviewer: fixeria <vyanitskiy(a)sysmocom.de> Gerrit-Reviewer: laforge <laforge(a)osmocom.org> Gerrit-Attention: laforge <laforge(a)osmocom.org> Gerrit-Attention: fixeria <vyanitskiy(a)sysmocom.de> Gerrit-Attention: pespin <pespin(a)sysmocom.de> Gerrit-Attention: dexter <pmaier(a)sysmocom.de>
1 0
0 0
[M] Change in osmo-bsc[master]: Initial support for >256 BTS
by pespin 10 Sep '24

10 Sep '24
Attention is currently required from: dexter. pespin has posted comments on this change by pespin. ( https://gerrit.osmocom.org/c/osmo-bsc/+/38052?usp=email ) Change subject: Initial support for >256 BTS ...................................................................... Patch Set 4: (1 comment) Patchset: PS4: > To me this patch looks reasonable. […] I did exactly that, explained in here: https://projects.sysmocom.de/issues/7062#note-6 -- To view, visit https://gerrit.osmocom.org/c/osmo-bsc/+/38052?usp=email To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings?usp=email Gerrit-MessageType: comment Gerrit-Project: osmo-bsc Gerrit-Branch: master Gerrit-Change-Id: I607a68efeb5f4a50cce107d11d3c5126b7d8f81a Gerrit-Change-Number: 38052 Gerrit-PatchSet: 4 Gerrit-Owner: pespin <pespin(a)sysmocom.de> Gerrit-Reviewer: Jenkins Builder Gerrit-Reviewer: dexter <pmaier(a)sysmocom.de> Gerrit-Reviewer: fixeria <vyanitskiy(a)sysmocom.de> Gerrit-Reviewer: laforge <laforge(a)osmocom.org> Gerrit-Attention: dexter <pmaier(a)sysmocom.de> Gerrit-Comment-Date: Tue, 10 Sep 2024 11:57:13 +0000 Gerrit-HasComments: Yes Gerrit-Has-Labels: No Comment-In-Reply-To: dexter <pmaier(a)sysmocom.de>
1 0
0 0
[M] Change in osmo-bsc[master]: Convert bts->depends_on from bitmask to llist
by dexter 10 Sep '24

10 Sep '24
Attention is currently required from: laforge, pespin. dexter has posted comments on this change by pespin. ( https://gerrit.osmocom.org/c/osmo-bsc/+/38050?usp=email ) Change subject: Convert bts->depends_on from bitmask to llist ...................................................................... Patch Set 5: Code-Review+1 (2 comments) Patchset: PS5: I think lists are always nice Commit Message: https://gerrit.osmocom.org/c/osmo-bsc/+/38050/comment/2b19116f_36bf7e99?usp… : PS5, Line 14: iprevious code allocated (N * 256/8) bytes, where N is the amount of bts iprevious? -- To view, visit https://gerrit.osmocom.org/c/osmo-bsc/+/38050?usp=email To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings?usp=email Gerrit-MessageType: comment Gerrit-Project: osmo-bsc Gerrit-Branch: master Gerrit-Change-Id: I59e37d6baa020aeafdffc2c3538e988effd37620 Gerrit-Change-Number: 38050 Gerrit-PatchSet: 5 Gerrit-Owner: pespin <pespin(a)sysmocom.de> Gerrit-Reviewer: Jenkins Builder Gerrit-Reviewer: dexter <pmaier(a)sysmocom.de> Gerrit-Reviewer: fixeria <vyanitskiy(a)sysmocom.de> Gerrit-Reviewer: laforge <laforge(a)osmocom.org> Gerrit-Attention: laforge <laforge(a)osmocom.org> Gerrit-Attention: pespin <pespin(a)sysmocom.de> Gerrit-Comment-Date: Tue, 10 Sep 2024 11:43:35 +0000 Gerrit-HasComments: Yes Gerrit-Has-Labels: Yes
1 0
0 0
  • ← Newer
  • 1
  • ...
  • 136
  • 137
  • 138
  • 139
  • 140
  • 141
  • 142
  • ...
  • 199
  • Older →

HyperKitty Powered by HyperKitty version 1.3.12.