This is merely a historical archive of years 2008-2021, before the migration to mailman3.
A maintained and still updated list archive can be found at https://lists.osmocom.org/hyperkitty/list/gerrit-log@lists.osmocom.org/.
pespin gerrit-no-reply at lists.osmocom.orgpespin has submitted this change. ( https://gerrit.osmocom.org/c/osmo-pcu/+/22187 ) Change subject: Move ns_dialect field from BTS to PCU ...................................................................... Move ns_dialect field from BTS to PCU Change-Id: Iffb22b776b91f93d6d2a7ccfa47deeecc22c33f0 --- M src/bts.cpp M src/bts.h M src/gprs_bssgp_pcu.cpp M src/gprs_pcu.c M src/gprs_pcu.h M src/pcu_vty.c 6 files changed, 8 insertions(+), 12 deletions(-) Approvals: Jenkins Builder: Verified lynxis lazus: Looks good to me, approved laforge: Looks good to me, approved diff --git a/src/bts.cpp b/src/bts.cpp index c2b8696..4a9910f 100644 --- a/src/bts.cpp +++ b/src/bts.cpp @@ -201,7 +201,6 @@ bts->n3103 = 4; bts->n3105 = 8; bts->si13_is_set = false; - bts->ns_dialect = NS2_DIALECT_IPACCESS; /* TODO: increase them when CRBB decoding is implemented */ bts->ws_base = 64; diff --git a/src/bts.h b/src/bts.h index 040386e..2902074 100644 --- a/src/bts.h +++ b/src/bts.h @@ -120,9 +120,6 @@ */ struct BTS *bts; - /* Are we talking Gb with IP-SNS (true) or classic Gb? */ - enum gprs_ns2_dialect ns_dialect; - /* Packet Application Information (3GPP TS 44.060 11.2.47, usually ETWS primary message). We don't need to store * more than one message, because they get sent so rarely. */ struct msgb *app_info; diff --git a/src/gprs_bssgp_pcu.cpp b/src/gprs_bssgp_pcu.cpp index 0db6a51..89edd2b 100644 --- a/src/gprs_bssgp_pcu.cpp +++ b/src/gprs_bssgp_pcu.cpp @@ -984,7 +984,7 @@ bts->nse = gprs_ns2_nse_by_nsei(the_pcu->nsi, nsei); if (!bts->nse) bts->nse = gprs_ns2_create_nse(the_pcu->nsi, nsei, - GPRS_NS2_LL_UDP, bts->ns_dialect); + GPRS_NS2_LL_UDP, the_pcu->vty.ns_dialect); if (!bts->nse) { LOGP(DBSSGP, LOGL_ERROR, "Failed to create NSE\n"); @@ -997,7 +997,7 @@ continue; /* FIXME: for SNS we just use the first successful NS-VC instead of all for the initial connect */ - if (bts->ns_dialect == NS2_DIALECT_SNS) { + if (the_pcu->vty.ns_dialect == NS2_DIALECT_SNS) { rc = gprs_ns2_sns_add_endpoint(bts->nse, &remote[i]); if (!rc) return rc; @@ -1066,7 +1066,7 @@ gprs_ns2_free_nses(the_pcu->nsi); gprs_ns2_free_binds(the_pcu->nsi); rc = ns_create_nsvc(bts, nsei, local, remote, nsvci, valid); - } else if (bts->ns_dialect == NS2_DIALECT_SNS) { + } else if (the_pcu->vty.ns_dialect == NS2_DIALECT_SNS) { /* SNS: check if the initial nsvc is the same, if not recreate it */ const struct osmo_sockaddr *initial = gprs_ns2_nse_sns_remote(bts->nse); for (unsigned int i = 0; i < PCU_IF_NUM_NSVC; i++) { diff --git a/src/gprs_pcu.c b/src/gprs_pcu.c index cfe8896..01ead33 100644 --- a/src/gprs_pcu.c +++ b/src/gprs_pcu.c @@ -89,6 +89,7 @@ pcu->vty.mcs_lqual_ranges[7].high = 24; pcu->vty.mcs_lqual_ranges[8].low = 23; pcu->vty.mcs_lqual_ranges[8].high = 256; + pcu->vty.ns_dialect = NS2_DIALECT_IPACCESS; pcu->T_defs = T_defs_pcu; osmo_tdefs_reset(pcu->T_defs); diff --git a/src/gprs_pcu.h b/src/gprs_pcu.h index 916169e..ff73cc9 100644 --- a/src/gprs_pcu.h +++ b/src/gprs_pcu.h @@ -88,6 +88,7 @@ /* Link quality range for each UL (M)CS. Below or above, next/prev (M)CS is selected. */ struct {int16_t low; int16_t high; } cs_lqual_ranges[MAX_GPRS_CS]; struct {int16_t low; int16_t high; } mcs_lqual_ranges[MAX_EDGE_MCS]; + enum gprs_ns2_dialect ns_dialect; /* Are we talking Gb with IP-SNS (true) or classic Gb? */ } vty; struct gsmtap_inst *gsmtap; diff --git a/src/pcu_vty.c b/src/pcu_vty.c index 3abfba7..b0c941d 100644 --- a/src/pcu_vty.c +++ b/src/pcu_vty.c @@ -243,7 +243,7 @@ } } - if (bts->ns_dialect == NS2_DIALECT_SNS) + if (the_pcu->vty.ns_dialect == NS2_DIALECT_SNS) vty_out(vty, " gb-dialect ip-sns%s", VTY_NEWLINE); else vty_out(vty, " gb-dialect classic%s", VTY_NEWLINE); @@ -1067,12 +1067,10 @@ "Classic Gb interface with NS-{RESET,BLOCK,UNBLOCK} and static configuration\n" "Modern Gb interface with IP-SNS (Sub Network Service) and dynamic configuration\n") { - struct gprs_rlcmac_bts *bts = bts_main_data(); - if (!strcmp(argv[0], "ip-sns")) { - bts->ns_dialect = NS2_DIALECT_SNS; + the_pcu->vty.ns_dialect = NS2_DIALECT_SNS; } else { - bts->ns_dialect = NS2_DIALECT_IPACCESS; + the_pcu->vty.ns_dialect = NS2_DIALECT_IPACCESS; } return CMD_SUCCESS; -- To view, visit https://gerrit.osmocom.org/c/osmo-pcu/+/22187 To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings Gerrit-Project: osmo-pcu Gerrit-Branch: master Gerrit-Change-Id: Iffb22b776b91f93d6d2a7ccfa47deeecc22c33f0 Gerrit-Change-Number: 22187 Gerrit-PatchSet: 4 Gerrit-Owner: pespin <pespin at sysmocom.de> Gerrit-Reviewer: Jenkins Builder Gerrit-Reviewer: laforge <laforge at osmocom.org> Gerrit-Reviewer: lynxis lazus <lynxis at fe80.eu> Gerrit-Reviewer: pespin <pespin at sysmocom.de> Gerrit-MessageType: merged -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://lists.osmocom.org/pipermail/gerrit-log/attachments/20210118/71d3015b/attachment.htm>