lists.osmocom.org
Sign In Sign Up
Manage this list Sign In Sign Up

Keyboard Shortcuts

Thread View

  • j: Next unread message
  • k: Previous unread message
  • j a: Jump to all threads
  • j l: Jump to MailingList overview

gerrit-log

Thread Start a new thread
Download
Threads by month
  • ----- 2026 -----
  • October
  • September
  • August
  • July
  • June
  • May
  • April
  • March
  • February
  • January
  • ----- 2025 -----
  • December
  • November
  • October
  • September
  • August
  • July
  • June
  • May
  • April
  • March
  • February
  • January
  • ----- 2024 -----
  • December
  • November
  • October
  • September
  • August
  • July
  • June
  • May
  • April
  • March
  • February
  • January
  • ----- 2023 -----
  • December
  • November
  • October
  • September
  • August
  • July
  • June
  • May
  • April
  • March
  • February
  • January
  • ----- 2022 -----
  • December
  • November
  • October
  • September
  • August
  • July
  • June
  • May
  • April
  • March
  • February
  • January
gerrit-log@lists.osmocom.org

April 2023

  • 1 participants
  • 2252 discussions
[M] Change in osmo-ttcn3-hacks[master]: bsc: add TC_mscpool_sccp_n_pcstate_attaches_msc
by neels 14 Apr '23

14 Apr '23
neels has submitted this change. ( https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/32217 ) Change subject: bsc: add TC_mscpool_sccp_n_pcstate_attaches_msc ...................................................................... bsc: add TC_mscpool_sccp_n_pcstate_attaches_msc Related: I3a0869598b8395601a16d78dbc46eec400c0ea84 (osmo-bsc) Change-Id: Ib4a5330df30a73e744c316898817b2fa3271d75e --- M bsc/BSC_Tests.ttcn 1 file changed, 84 insertions(+), 16 deletions(-) Approvals: laforge: Looks good to me, but someone else must approve neels: Looks good to me, approved pespin: Looks good to me, but someone else must approve Jenkins Builder: Verified diff --git a/bsc/BSC_Tests.ttcn b/bsc/BSC_Tests.ttcn index 39c82ab..dccfdc3 100644 --- a/bsc/BSC_Tests.ttcn +++ b/bsc/BSC_Tests.ttcn @@ -646,6 +646,8 @@ /* are we initialized yet */ var boolean g_initialized := false; + var boolean g_handler_mode := false; + /* Osmux is enabled through VTY */ var boolean g_osmux_enabled_cn := false; var boolean g_osmux_enabled_bts := false; @@ -1210,6 +1212,27 @@ } } +private function f_bssap_idx_init(integer bssap_idx) runs on test_CT { + /* Call a function of our 'parent component' RAN_Adapter_CT to start the + * MSC-side BSSAP emulation */ + if (g_handler_mode) { + var RanOps ranops := MSC_RanOps; + ranops.use_osmux := g_osmux_enabled_cn; + f_ran_adapter_init(g_bssap[bssap_idx], mp_bssap_cfg[bssap_idx], "VirtMSC", ranops); + connect(self:SCCPLITE_IPA_CTRL, g_bssap[bssap_idx].vc_RAN:CTRL_CLIENT); + f_ran_adapter_start(g_bssap[bssap_idx]); + } else { + f_ran_adapter_init(g_bssap[bssap_idx], mp_bssap_cfg[bssap_idx], "VirtMSC", omit); + connect(self:BSSAP, g_bssap[bssap_idx].vc_SCCP:SCCP_SP_PORT); + f_ran_adapter_start(g_bssap[bssap_idx]); + f_legacy_bssap_reset(); + } +} + +private function f_bssap_idx_disconnect(integer bssap_idx) runs on test_CT { + f_ran_adapter_cleanup(g_bssap[bssap_idx]); +} + /* global initialization function * \param nr_bts Number of BTSs we should start/bring up * \param handler_mode Start an RSL_Emulation_CT component (true) or not (false). @@ -1238,22 +1261,10 @@ f_vty_transceive(BSCVTY, "msc " & int2str(bssap_idx) & " bssmap reset", strict := false); } + g_handler_mode := handler_mode; for (bssap_idx := 0; bssap_idx < nr_msc; bssap_idx := bssap_idx+1) { allow_attach[bssap_idx] := true; - /* Call a function of our 'parent component' RAN_Adapter_CT to start the - * MSC-side BSSAP emulation */ - if (handler_mode) { - var RanOps ranops := MSC_RanOps; - ranops.use_osmux := g_osmux_enabled_cn; - f_ran_adapter_init(g_bssap[bssap_idx], mp_bssap_cfg[bssap_idx], "VirtMSC", ranops); - connect(self:SCCPLITE_IPA_CTRL, g_bssap[bssap_idx].vc_RAN:CTRL_CLIENT); - f_ran_adapter_start(g_bssap[bssap_idx]); - } else { - f_ran_adapter_init(g_bssap[bssap_idx], mp_bssap_cfg[bssap_idx], "VirtMSC", omit); - connect(self:BSSAP, g_bssap[bssap_idx].vc_SCCP:SCCP_SP_PORT); - f_ran_adapter_start(g_bssap[bssap_idx]); - f_legacy_bssap_reset(); - } + f_bssap_idx_init(bssap_idx); } if (mp_enable_lcs_tests) { @@ -9190,8 +9201,7 @@ f_ctrs_msc_expect(1, "mscpool:subscr:new"); f_logp(BSCVTY, "disconnecting msc0"); - /* Disconnect the first MSC */ - f_ran_adapter_cleanup(g_bssap[0]); + f_bssap_idx_disconnect(0); /* Now round-robin would wrap to the first MSC, but since the first MSC is disconnected, it wraps around to msc * 2 again. */ @@ -9205,6 +9215,53 @@ f_shutdown_helper(); } +/* When an MSC point-code gets an SCCP N-PCSTATE saying it is now reachable, immediately trigger RESET and bring up the + * MSC. */ +testcase TC_mscpool_sccp_n_pcstate_attaches_msc() runs on test_CT { + + f_init(nr_bts := 3, handler_mode := true, nr_msc := 1); + f_sleep(1.0); + + /* Control which MSC gets chosen next by the round-robin, otherwise + * would be randomly affected by which other tests ran before this. */ + f_vty_transceive(BSCVTY, "mscpool roundrobin next 0"); + + f_ctrs_msc_init(); + + /* There is only one MSC, round robin stays on msc0 */ + var MSC_ConnHdlr vc_conn1; + var TestHdlrParams pars1 := f_gen_test_hdlr_pars(bssap_idx := 0); + pars1.mscpool.rsl_idx := 0; + pars1.mscpool.l3_info := valueof(ts_LU_REQ(LU_Type_IMSI_Attach, valueof(ts_MI_IMSI_LV('0010100230000001'H)), '00F110'O)); + vc_conn1 := f_start_handler(refers(f_tc_mscpool_compl_l3), pars1); + vc_conn1.done; + f_ctrs_msc_expect(0, "mscpool:subscr:new"); + + var MSC_ConnHdlr vc_conn2; + var TestHdlrParams pars2 := f_gen_test_hdlr_pars(bssap_idx := 0); + pars2.mscpool.rsl_idx := 1; + pars2.mscpool.l3_info := valueof(ts_CM_SERV_REQ(CM_TYPE_MO_CALL, valueof(ts_MI_IMSI_LV('001010023000002'H)))); + vc_conn2 := f_start_handler(refers(f_tc_mscpool_compl_l3), pars2); + vc_conn2.done; + f_ctrs_msc_expect(0, "mscpool:subscr:new"); + + f_logp(BSCVTY, "connecting msc1"); + f_vty_msc_allow_attach(BSCVTY, { true, true }); + f_bssap_idx_init(1); + f_sleep(1.0); + + /* This time round-robin wraps to the second MSC, because it is now online. */ + var MSC_ConnHdlr vc_conn4; + var TestHdlrParams pars4 := f_gen_test_hdlr_pars(bssap_idx := 1); + pars4.mscpool.rsl_idx := 2; + pars4.mscpool.l3_info := valueof(ts_PAG_RESP(valueof(ts_MI_IMSI_LV('001010023000003'H)))); + vc_conn4 := f_start_handler(refers(f_tc_mscpool_compl_l3), pars4); + vc_conn4.done; + f_ctrs_msc_expect(1, "mscpool:subscr:new"); + + f_shutdown_helper(); +} + /* Allow/Deny emergency calls globally via VTY */ private function f_vty_allow_emerg_msc(boolean allow) runs on test_CT { f_vty_enter_cfg_msc(BSCVTY, 0); @@ -12509,6 +12566,7 @@ execute( TC_mscpool_no_allow_attach_valid_nri() ); execute( TC_mscpool_sccp_n_pcstate_detaches_msc() ); + execute( TC_mscpool_sccp_n_pcstate_attaches_msc() ); } execute( TC_early_conn_fail() ); -- To view, visit https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/32217 To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings Gerrit-Project: osmo-ttcn3-hacks Gerrit-Branch: master Gerrit-Change-Id: Ib4a5330df30a73e744c316898817b2fa3271d75e Gerrit-Change-Number: 32217 Gerrit-PatchSet: 4 Gerrit-Owner: neels <nhofmeyr(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-CC: fixeria <vyanitskiy(a)sysmocom.de> Gerrit-MessageType: merged
1 0
0 0
[S] Change in osmo-ttcn3-hacks[master]: L3_Templates, bsc: set ts_PAG_RESP() arg to template (value)
by neels 14 Apr '23

14 Apr '23
neels has submitted this change. ( https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/32244 ) Change subject: L3_Templates, bsc: set ts_PAG_RESP() arg to template (value) ...................................................................... L3_Templates, bsc: set ts_PAG_RESP() arg to template (value) Change-Id: Ib77fc2377c1cf86abca9cf3082b74926d3c2c431 --- M bsc/BSC_Tests.ttcn M library/L3_Templates.ttcn 2 files changed, 22 insertions(+), 13 deletions(-) Approvals: laforge: Looks good to me, approved fixeria: Looks good to me, approved pespin: Looks good to me, but someone else must approve Jenkins Builder: Verified diff --git a/bsc/BSC_Tests.ttcn b/bsc/BSC_Tests.ttcn index dccfdc3..f40b19e 100644 --- a/bsc/BSC_Tests.ttcn +++ b/bsc/BSC_Tests.ttcn @@ -3737,7 +3737,7 @@ var BSSAP_N_CONNECT_ind rx_c_ind; var DchanTuple dt; - var PDU_ML3_MS_NW l3 := valueof(ts_PAG_RESP(valueof(ts_MI_IMSI_LV('001010008880018'H)))); + var PDU_ML3_MS_NW l3 := valueof(ts_PAG_RESP(ts_MI_IMSI_LV('001010008880018'H))); var octetstring rr_pag_resp := enc_PDU_ML3_MS_NW(l3); /* Send CHAN RQD and wait for allocation; acknowledge it */ @@ -8621,7 +8621,7 @@ f_MscConnHdlr_init(g_pars.media_nr, "127.0.0.2", "127.0.0.3", FR_AMR); f_perform_compl_l3(RSL, RSL_PROC, ts_LU_REQ(LU_Type_IMSI_Attach, valueof(ts_MI_IMSI_LV('001010000000001'H)), '00F110'O) ); f_perform_compl_l3(RSL, RSL_PROC, ts_CM_SERV_REQ(CM_TYPE_MO_SMS, valueof(ts_MI_IMSI_LV('001010000000002'H))) ); - f_perform_compl_l3(RSL, RSL_PROC, ts_PAG_RESP(valueof(ts_MI_IMSI_LV('001010000000003'H))) ); + f_perform_compl_l3(RSL, RSL_PROC, ts_PAG_RESP(ts_MI_IMSI_LV('001010000000003'H)) ); f_perform_compl_l3(RSL, RSL_PROC, ts_ML3_MO_MM_IMSI_DET_Ind(valueof(ts_MI_IMSI_LV('001010000000004'H))) ); } testcase TC_mscpool_L3Compl_on_1_msc() runs on test_CT { @@ -8674,7 +8674,7 @@ var MSC_ConnHdlr vc_conn3; var TestHdlrParams pars3 := f_gen_test_hdlr_pars(bssap_idx := 0); pars3.mscpool.rsl_idx := 2; - pars3.mscpool.l3_info := valueof(ts_PAG_RESP(valueof(ts_MI_IMSI_LV('001010000000003'H)))); + pars3.mscpool.l3_info := valueof(ts_PAG_RESP(ts_MI_IMSI_LV('001010000000003'H))); vc_conn3 := f_start_handler(refers(f_tc_mscpool_compl_l3), pars3); vc_conn3.done; f_ctrs_msc_expect(0, "mscpool:subscr:new"); @@ -8830,7 +8830,7 @@ var TestHdlrParams pars1 := f_gen_test_hdlr_pars(bssap_idx := 0); pars1.mscpool.rsl_idx := 0; /* An NRI that is assigned to an unconnected MSC */ - pars1.mscpool.l3_info := valueof(ts_PAG_RESP(valueof(ts_MI_TMSI_NRI_LV(512)))); + pars1.mscpool.l3_info := valueof(ts_PAG_RESP(ts_MI_TMSI_NRI_LV(512))); vc_conn1 := f_start_handler(refers(f_tc_mscpool_compl_l3), pars1); vc_conn1.done; f_ctrs_msc_add(2, "mscpool:subscr:attach_lost"); @@ -8890,7 +8890,7 @@ var TestHdlrParams pars2 := f_gen_test_hdlr_pars(bssap_idx := 1); pars2.mscpool.rsl_idx := 1; /* An NRI of the second MSC's range (256-511) */ - pars2.mscpool.l3_info := valueof(ts_PAG_RESP(valueof(ts_MI_TMSI_NRI_LV(260)))); + pars2.mscpool.l3_info := valueof(ts_PAG_RESP(ts_MI_TMSI_NRI_LV(260))); vc_conn2 := f_start_handler(refers(f_tc_mscpool_compl_l3), pars2); vc_conn2.done; f_ctrs_msc_expect(1, "mscpool:subscr:known"); @@ -8934,7 +8934,7 @@ var TestHdlrParams pars2 := f_gen_test_hdlr_pars(bssap_idx := 2); pars2.mscpool.rsl_idx := 1; /* An NRI of the third MSC's range (512-767) */ - pars2.mscpool.l3_info := valueof(ts_PAG_RESP(valueof(ts_MI_TMSI_NRI_LV(678)))); + pars2.mscpool.l3_info := valueof(ts_PAG_RESP(ts_MI_TMSI_NRI_LV(678))); vc_conn2 := f_start_handler(refers(f_tc_mscpool_compl_l3), pars2); vc_conn2.done; f_ctrs_msc_expect(2, "mscpool:subscr:known"); @@ -9010,7 +9010,7 @@ /* Despite the round robin pointing at the second MSC ('roundrobin next 1'), the earlier Paging for the same IMSI * causes this Paging Response to go to the first MSC (bssap_idx := 0). */ - f_perform_compl_l3(RSL, RSL_PROC, ts_PAG_RESP(valueof(ts_MI_IMSI_LV(imsi))) ); + f_perform_compl_l3(RSL, RSL_PROC, ts_PAG_RESP(ts_MI_IMSI_LV(imsi)) ); f_sleep(1.0); } testcase TC_mscpool_paging_and_response_imsi() runs on test_CT { @@ -9062,7 +9062,7 @@ /* Despite the NRI matching the second MSC (NRI from 'msc 1' in osmo-bsc.cfg) and round robin pointing at the * third MSC ('roundrobin next 2'), the earlier Paging for the same TMSI causes this Paging Response to go to * the first MSC (bssap_idx := 0). */ - f_perform_compl_l3(RSL, RSL_PROC, ts_PAG_RESP(valueof(ts_MI_TMSI_NRI_LV(nri_v))) ); + f_perform_compl_l3(RSL, RSL_PROC, ts_PAG_RESP(ts_MI_TMSI_NRI_LV(nri_v)) ); f_sleep(1.0); } testcase TC_mscpool_paging_and_response_tmsi() runs on test_CT { @@ -9121,7 +9121,7 @@ var MSC_ConnHdlr vc_conn3; var TestHdlrParams pars3 := f_gen_test_hdlr_pars(bssap_idx := 0); pars3.mscpool.rsl_idx := 2; - pars3.mscpool.l3_info := valueof(ts_PAG_RESP(valueof(ts_MI_IMSI_LV('001010000000003'H)))); + pars3.mscpool.l3_info := valueof(ts_PAG_RESP(ts_MI_IMSI_LV('001010000000003'H))); vc_conn3 := f_start_handler(refers(f_tc_mscpool_compl_l3), pars3); vc_conn3.done; f_ctrs_msc_expect(0, "mscpool:subscr:new"); @@ -9208,7 +9208,7 @@ var MSC_ConnHdlr vc_conn3; var TestHdlrParams pars3 := f_gen_test_hdlr_pars(bssap_idx := 1); pars3.mscpool.rsl_idx := 2; - pars3.mscpool.l3_info := valueof(ts_PAG_RESP(valueof(ts_MI_IMSI_LV('001010000000003'H)))); + pars3.mscpool.l3_info := valueof(ts_PAG_RESP(ts_MI_IMSI_LV('001010000000003'H))); vc_conn3 := f_start_handler(refers(f_tc_mscpool_compl_l3), pars3); vc_conn3.done; f_ctrs_msc_expect(1, "mscpool:subscr:new"); @@ -9254,7 +9254,7 @@ var MSC_ConnHdlr vc_conn4; var TestHdlrParams pars4 := f_gen_test_hdlr_pars(bssap_idx := 1); pars4.mscpool.rsl_idx := 2; - pars4.mscpool.l3_info := valueof(ts_PAG_RESP(valueof(ts_MI_IMSI_LV('001010023000003'H)))); + pars4.mscpool.l3_info := valueof(ts_PAG_RESP(ts_MI_IMSI_LV('001010023000003'H))); vc_conn4 := f_start_handler(refers(f_tc_mscpool_compl_l3), pars4); vc_conn4.done; f_ctrs_msc_expect(1, "mscpool:subscr:new"); @@ -10354,7 +10354,7 @@ /* MS requests channel. Since the Paging was for LCS, the Paging Response does not trigger a Complete Layer 3 to * the MSC, and releases the lchan directly. */ - f_perform_compl_l3(RSL, RSL_PROC, ts_PAG_RESP(valueof(ts_MI_IMSI_LV(g_pars.imsi))), do_clear := false, expect_bssmap_l3 := false); + f_perform_compl_l3(RSL, RSL_PROC, ts_PAG_RESP(ts_MI_IMSI_LV(g_pars.imsi)), do_clear := false, expect_bssmap_l3 := false); f_expect_lchan_rel(RSL, RSL_PROC); /* From the Paging Response, the TA is now known to the BSC, and it responds to the SMLC. */ diff --git a/library/L3_Templates.ttcn b/library/L3_Templates.ttcn index 610d410..1ea8b82 100644 --- a/library/L3_Templates.ttcn +++ b/library/L3_Templates.ttcn @@ -567,7 +567,7 @@ /* Send template for PAGING RESPONSE */ -template (value) PDU_ML3_MS_NW ts_PAG_RESP(MobileIdentityLV mi_lv) := { +template (value) PDU_ML3_MS_NW ts_PAG_RESP(template (value) MobileIdentityLV mi_lv) := { discriminator := '0000'B, /* overwritten */ tiOrSkip := { skipIndicator := '0000'B -- To view, visit https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/32244 To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings Gerrit-Project: osmo-ttcn3-hacks Gerrit-Branch: master Gerrit-Change-Id: Ib77fc2377c1cf86abca9cf3082b74926d3c2c431 Gerrit-Change-Number: 32244 Gerrit-PatchSet: 3 Gerrit-Owner: neels <nhofmeyr(a)sysmocom.de> Gerrit-Reviewer: Jenkins Builder Gerrit-Reviewer: fixeria <vyanitskiy(a)sysmocom.de> Gerrit-Reviewer: laforge <laforge(a)osmocom.org> Gerrit-Reviewer: neels <nhofmeyr(a)sysmocom.de> Gerrit-Reviewer: pespin <pespin(a)sysmocom.de> Gerrit-MessageType: merged
1 0
0 0
[M] Change in osmo-ttcn3-hacks[master]: bsc: add TC_mscpool_sccp_n_pcstate_attaches_msc
by neels 14 Apr '23

14 Apr '23
Attention is currently required from: fixeria. neels has posted comments on this change. ( https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/32217 ) Change subject: bsc: add TC_mscpool_sccp_n_pcstate_attaches_msc ...................................................................... Patch Set 3: Code-Review+2 -- To view, visit https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/32217 To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings Gerrit-Project: osmo-ttcn3-hacks Gerrit-Branch: master Gerrit-Change-Id: Ib4a5330df30a73e744c316898817b2fa3271d75e Gerrit-Change-Number: 32217 Gerrit-PatchSet: 3 Gerrit-Owner: neels <nhofmeyr(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-CC: fixeria <vyanitskiy(a)sysmocom.de> Gerrit-Attention: fixeria <vyanitskiy(a)sysmocom.de> Gerrit-Comment-Date: Fri, 14 Apr 2023 22:25:12 +0000 Gerrit-HasComments: No Gerrit-Has-Labels: Yes Gerrit-MessageType: comment
1 0
0 0
[S] Change in osmo-bsc[master]: fix comment typo
by neels 14 Apr '23

14 Apr '23
neels has submitted this change. ( https://gerrit.osmocom.org/c/osmo-bsc/+/32319 ) Change subject: fix comment typo ...................................................................... fix comment typo Change-Id: I5c38f47cdf21d4e787341bf68e1e63c713003bbd --- M include/osmocom/bsc/gsm_data.h 1 file changed, 10 insertions(+), 1 deletion(-) Approvals: Jenkins Builder: Verified neels: Looks good to me, approved diff --git a/include/osmocom/bsc/gsm_data.h b/include/osmocom/bsc/gsm_data.h index 7779449..6e81610 100644 --- a/include/osmocom/bsc/gsm_data.h +++ b/include/osmocom/bsc/gsm_data.h @@ -883,7 +883,7 @@ struct bsc_sccp_inst { struct osmo_sccp_instance *sccp; /* backpointer */ - /* rbtree root of 'sstruct gsm_subscriber_connection' in this instance, ordered by conn_id */ + /* rbtree root of 'struct bscp_sccp_conn_node' in this instance, ordered by conn_id */ struct rb_root connections; uint32_t next_id; /* next id to allocate */ }; -- To view, visit https://gerrit.osmocom.org/c/osmo-bsc/+/32319 To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings Gerrit-Project: osmo-bsc Gerrit-Branch: master Gerrit-Change-Id: I5c38f47cdf21d4e787341bf68e1e63c713003bbd Gerrit-Change-Number: 32319 Gerrit-PatchSet: 1 Gerrit-Owner: neels <nhofmeyr(a)sysmocom.de> Gerrit-Reviewer: Jenkins Builder Gerrit-Reviewer: neels <nhofmeyr(a)sysmocom.de> Gerrit-MessageType: merged
1 0
0 0
[S] Change in osmo-bsc[master]: fix comment typo
by neels 14 Apr '23

14 Apr '23
neels has posted comments on this change. ( https://gerrit.osmocom.org/c/osmo-bsc/+/32319 ) Change subject: fix comment typo ...................................................................... Patch Set 1: Code-Review+2 (1 comment) Patchset: PS1: trivial -- To view, visit https://gerrit.osmocom.org/c/osmo-bsc/+/32319 To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings Gerrit-Project: osmo-bsc Gerrit-Branch: master Gerrit-Change-Id: I5c38f47cdf21d4e787341bf68e1e63c713003bbd Gerrit-Change-Number: 32319 Gerrit-PatchSet: 1 Gerrit-Owner: neels <nhofmeyr(a)sysmocom.de> Gerrit-Reviewer: Jenkins Builder Gerrit-Reviewer: neels <nhofmeyr(a)sysmocom.de> Gerrit-Comment-Date: Fri, 14 Apr 2023 22:24:00 +0000 Gerrit-HasComments: Yes Gerrit-Has-Labels: Yes Gerrit-MessageType: comment
1 0
0 0
[M] Change in libosmo-pfcp[master]: pfcp_msg: refactor LOG_PFCP_MSG
by neels 14 Apr '23

14 Apr '23
neels has submitted this change. ( https://gerrit.osmocom.org/c/libosmo-pfcp/+/32173 ) Change subject: pfcp_msg: refactor LOG_PFCP_MSG ...................................................................... pfcp_msg: refactor LOG_PFCP_MSG It was requested during code review to make this a function and not a macro. One effective change: no longer log "NULL{fi=NULL}" when no m->ctx.session_fi or .peer_fi are set. Change-Id: Ic84090c9b1a34185577cfb2ea1efa9c07542df34 --- M include/osmocom/pfcp/pfcp_msg.h M src/libosmo-pfcp/pfcp_msg.c 2 files changed, 49 insertions(+), 20 deletions(-) Approvals: neels: Looks good to me, approved Jenkins Builder: Verified diff --git a/include/osmocom/pfcp/pfcp_msg.h b/include/osmocom/pfcp/pfcp_msg.h index 4affa54..0023353 100644 --- a/include/osmocom/pfcp/pfcp_msg.h +++ b/include/osmocom/pfcp/pfcp_msg.h @@ -42,30 +42,15 @@ #define OSMO_PFCP_MSGB_ALLOC_SIZE 2048 -#define OSMO_LOG_PFCP_MSG_SRC(M, LEVEL, file, line, FMT, ARGS...) do { \ - struct osmo_fsm_inst *_fi = (M) ? ((M)->ctx.session_fi ?: (M)->ctx.peer_fi) : NULL; \ - enum osmo_pfcp_cause *cause = osmo_pfcp_msg_cause(M); \ - if ((M)->h.seid_present) { \ - LOGPFSMSLSRC(_fi, DLPFCP, LEVEL, file, line, \ - "%s%s PFCP seq-%u SEID-0x%"PRIx64" %s%s%s: " FMT, \ - _fi ? "" : osmo_sockaddr_to_str_c(OTC_SELECT, &(M)->remote_addr), \ - (M)->rx ? "-rx->" : "<-tx-", (M)->h.sequence_nr, \ - (M)->h.seid, \ - osmo_pfcp_message_type_str((M)->h.message_type), cause ? ": " : "", \ - cause ? osmo_pfcp_cause_str(*cause) : "", ##ARGS); \ - } else { \ - LOGPFSMSLSRC(_fi, DLPFCP, LEVEL, file, line, \ - "%s%s PFCP seq-%u %s%s%s: " FMT, \ - _fi ? "" : osmo_sockaddr_to_str_c(OTC_SELECT, &(M)->remote_addr), \ - (M)->rx ? "-rx->" : "<-tx-", (M)->h.sequence_nr, \ - osmo_pfcp_message_type_str((M)->h.message_type), cause ? ": " : "", \ - cause ? osmo_pfcp_cause_str(*cause) : "", ##ARGS); \ - } \ - } while (0) +#define OSMO_LOG_PFCP_MSG_SRC(M, LEVEL, file, line, FMT, ARGS...) \ + LOGPSRC(DLPFCP, LEVEL, file, line, "%s: " FMT, osmo_pfcp_msg_log_info_c(OTC_SELECT, M), ##ARGS) #define OSMO_LOG_PFCP_MSG(M, LEVEL, FMT, ARGS...) \ OSMO_LOG_PFCP_MSG_SRC(M, LEVEL, __FILE__, __LINE__, FMT, ##ARGS) +int osmo_pfcp_msg_log_info_buf(char *buf, size_t buflen, const struct osmo_pfcp_msg *m); +char *osmo_pfcp_msg_log_info_c(void *ctx, const struct osmo_pfcp_msg *m); + struct osmo_pfcp_header_parsed { uint8_t version; enum osmo_pfcp_message_type message_type; diff --git a/src/libosmo-pfcp/pfcp_msg.c b/src/libosmo-pfcp/pfcp_msg.c index 9893cb2..74335fe 100644 --- a/src/libosmo-pfcp/pfcp_msg.c +++ b/src/libosmo-pfcp/pfcp_msg.c @@ -550,3 +550,32 @@ { OSMO_NAME_C_IMPL(ctx, 256, "ERROR", osmo_pfcp_msg_to_str_buf, m) } + +int osmo_pfcp_msg_log_info_buf(char *buf, size_t buflen, const struct osmo_pfcp_msg *m) +{ + struct osmo_strbuf sb = { .buf = buf, .len = buflen }; + struct osmo_fsm_inst *fi = m ? (m->ctx.session_fi ?: m->ctx.peer_fi) : NULL; + enum osmo_pfcp_cause *cause = osmo_pfcp_msg_cause(m); + + if (fi) + OSMO_STRBUF_PRINTF(sb, "%s{%s}: ", + osmo_fsm_inst_name(fi), + osmo_fsm_state_name(fi->fsm, fi->state)); + else + OSMO_STRBUF_APPEND(sb, osmo_sockaddr_to_str_buf2, &m->remote_addr); + OSMO_STRBUF_PRINTF(sb, "%s PFCP seq-%u", + m->rx ? "-rx->" : "<-tx-", + m->h.sequence_nr); + if (m->h.seid_present) + OSMO_STRBUF_PRINTF(sb, " SEID-0x%"PRIx64, m->h.seid); + + OSMO_STRBUF_PRINTF(sb, " %s", osmo_pfcp_message_type_str(m->h.message_type)); + if (cause) + OSMO_STRBUF_PRINTF(sb, ": %s", osmo_pfcp_cause_str(*cause)); + return sb.chars_needed; +} + +char *osmo_pfcp_msg_log_info_c(void *ctx, const struct osmo_pfcp_msg *m) +{ + OSMO_NAME_C_IMPL(ctx, 128, "ERROR", osmo_pfcp_msg_log_info_buf, m) +} -- To view, visit https://gerrit.osmocom.org/c/libosmo-pfcp/+/32173 To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings Gerrit-Project: libosmo-pfcp Gerrit-Branch: master Gerrit-Change-Id: Ic84090c9b1a34185577cfb2ea1efa9c07542df34 Gerrit-Change-Number: 32173 Gerrit-PatchSet: 2 Gerrit-Owner: neels <nhofmeyr(a)sysmocom.de> Gerrit-Reviewer: Jenkins Builder Gerrit-Reviewer: laforge <laforge(a)osmocom.org> Gerrit-Reviewer: msuraev <msuraev(a)sysmocom.de> Gerrit-Reviewer: neels <nhofmeyr(a)sysmocom.de> Gerrit-Reviewer: pespin <pespin(a)sysmocom.de> Gerrit-MessageType: merged
1 0
0 0
[M] Change in libosmo-pfcp[master]: pfcp_msg: refactor LOG_PFCP_MSG
by neels 14 Apr '23

14 Apr '23
neels has posted comments on this change. ( https://gerrit.osmocom.org/c/libosmo-pfcp/+/32173 ) Change subject: pfcp_msg: refactor LOG_PFCP_MSG ...................................................................... Patch Set 2: Code-Review+2 (1 comment) Patchset: PS2: (just an indentation tweak) -- To view, visit https://gerrit.osmocom.org/c/libosmo-pfcp/+/32173 To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings Gerrit-Project: libosmo-pfcp Gerrit-Branch: master Gerrit-Change-Id: Ic84090c9b1a34185577cfb2ea1efa9c07542df34 Gerrit-Change-Number: 32173 Gerrit-PatchSet: 2 Gerrit-Owner: neels <nhofmeyr(a)sysmocom.de> Gerrit-Reviewer: Jenkins Builder Gerrit-Reviewer: laforge <laforge(a)osmocom.org> Gerrit-Reviewer: msuraev <msuraev(a)sysmocom.de> Gerrit-Reviewer: neels <nhofmeyr(a)sysmocom.de> Gerrit-Reviewer: pespin <pespin(a)sysmocom.de> Gerrit-Comment-Date: Fri, 14 Apr 2023 22:20:18 +0000 Gerrit-HasComments: Yes Gerrit-Has-Labels: Yes Gerrit-MessageType: comment
1 0
0 0
[M] Change in libosmo-pfcp[master]: pfcp_msg: refactor LOG_PFCP_MSG
by neels 14 Apr '23

14 Apr '23
Attention is currently required from: neels. Hello Jenkins Builder, laforge, pespin, msuraev, I'd like you to reexamine a change. Please visit https://gerrit.osmocom.org/c/libosmo-pfcp/+/32173 to look at the new patch set (#2). Change subject: pfcp_msg: refactor LOG_PFCP_MSG ...................................................................... pfcp_msg: refactor LOG_PFCP_MSG It was requested during code review to make this a function and not a macro. One effective change: no longer log "NULL{fi=NULL}" when no m->ctx.session_fi or .peer_fi are set. Change-Id: Ic84090c9b1a34185577cfb2ea1efa9c07542df34 --- M include/osmocom/pfcp/pfcp_msg.h M src/libosmo-pfcp/pfcp_msg.c 2 files changed, 49 insertions(+), 20 deletions(-) git pull ssh://gerrit.osmocom.org:29418/libosmo-pfcp refs/changes/73/32173/2 -- To view, visit https://gerrit.osmocom.org/c/libosmo-pfcp/+/32173 To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings Gerrit-Project: libosmo-pfcp Gerrit-Branch: master Gerrit-Change-Id: Ic84090c9b1a34185577cfb2ea1efa9c07542df34 Gerrit-Change-Number: 32173 Gerrit-PatchSet: 2 Gerrit-Owner: neels <nhofmeyr(a)sysmocom.de> Gerrit-Reviewer: Jenkins Builder Gerrit-Reviewer: laforge <laforge(a)osmocom.org> Gerrit-Reviewer: msuraev <msuraev(a)sysmocom.de> Gerrit-Reviewer: pespin <pespin(a)sysmocom.de> Gerrit-Attention: neels <nhofmeyr(a)sysmocom.de> Gerrit-MessageType: newpatchset
1 0
0 0
[S] Change in osmo-msc[master]: TODO-RELEASE: add note on osmo-sip-connector and SDP
by neels 14 Apr '23

14 Apr '23
Attention is currently required from: pespin. neels has posted comments on this change. ( https://gerrit.osmocom.org/c/osmo-msc/+/32274 ) Change subject: TODO-RELEASE: add note on osmo-sip-connector and SDP ...................................................................... Patch Set 1: (1 comment) Patchset: PS1: > IIUC not necessarily at the same time, but current osmo-msc master depends on osmo-sip-connector > 1 […] no, not correct. I just want to make it so that when osmo-msc is released with full SDP support, that users can also install a released osmo-sip-connector that actually feeds SDP to osmo-msc. Otherwise it's no point releasing the SDP feature really. new osmo-msc *of course*!!!!!!! still works fine with earlier osmo-sip-connectors, where no SDP is included, just then it is not benefiting from the SIP's SDP at all and going mostly blind concerning the other call leg's codecs. so can we merge this now? -- To view, visit https://gerrit.osmocom.org/c/osmo-msc/+/32274 To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings Gerrit-Project: osmo-msc Gerrit-Branch: master Gerrit-Change-Id: I37fb5e18f06a5379d0320ee7d47885c9283cbd06 Gerrit-Change-Number: 32274 Gerrit-PatchSet: 1 Gerrit-Owner: neels <nhofmeyr(a)sysmocom.de> Gerrit-Reviewer: Jenkins Builder Gerrit-CC: pespin <pespin(a)sysmocom.de> Gerrit-Attention: pespin <pespin(a)sysmocom.de> Gerrit-Comment-Date: Fri, 14 Apr 2023 22:15:24 +0000 Gerrit-HasComments: Yes Gerrit-Has-Labels: No Comment-In-Reply-To: pespin <pespin(a)sysmocom.de> Gerrit-MessageType: comment
1 0
0 0
[S] Change in osmo-bsc[master]: fix comment typo
by neels 14 Apr '23

14 Apr '23
neels has uploaded this change for review. ( https://gerrit.osmocom.org/c/osmo-bsc/+/32319 ) Change subject: fix comment typo ...................................................................... fix comment typo Change-Id: I5c38f47cdf21d4e787341bf68e1e63c713003bbd --- M include/osmocom/bsc/gsm_data.h 1 file changed, 10 insertions(+), 1 deletion(-) git pull ssh://gerrit.osmocom.org:29418/osmo-bsc refs/changes/19/32319/1 diff --git a/include/osmocom/bsc/gsm_data.h b/include/osmocom/bsc/gsm_data.h index 7779449..6e81610 100644 --- a/include/osmocom/bsc/gsm_data.h +++ b/include/osmocom/bsc/gsm_data.h @@ -883,7 +883,7 @@ struct bsc_sccp_inst { struct osmo_sccp_instance *sccp; /* backpointer */ - /* rbtree root of 'sstruct gsm_subscriber_connection' in this instance, ordered by conn_id */ + /* rbtree root of 'struct bscp_sccp_conn_node' in this instance, ordered by conn_id */ struct rb_root connections; uint32_t next_id; /* next id to allocate */ }; -- To view, visit https://gerrit.osmocom.org/c/osmo-bsc/+/32319 To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings Gerrit-Project: osmo-bsc Gerrit-Branch: master Gerrit-Change-Id: I5c38f47cdf21d4e787341bf68e1e63c713003bbd Gerrit-Change-Number: 32319 Gerrit-PatchSet: 1 Gerrit-Owner: neels <nhofmeyr(a)sysmocom.de> Gerrit-MessageType: newchange
1 0
0 0
  • ← Newer
  • 1
  • ...
  • 152
  • 153
  • 154
  • 155
  • 156
  • 157
  • 158
  • ...
  • 226
  • Older →

HyperKitty Powered by HyperKitty version 1.3.12.