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

March 2026

  • 1 participants
  • 1933 discussions
[XS] Change in osmo-ttcn3-hacks[master]: bsc: fix copy-paste in TC_lcls_gcr_bway_codec_mismatch
by fixeria 15 Mar '26

15 Mar '26
fixeria has uploaded this change for review. ( https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/42390?usp=email ) Change subject: bsc: fix copy-paste in TC_lcls_gcr_bway_codec_mismatch ...................................................................... bsc: fix copy-paste in TC_lcls_gcr_bway_codec_mismatch The comment says that: * first call leg uses FR, * second call leg uses HR, however the code actually modifies the first call leg to use HR. The test still exercises a codec mismatch, so LCLS non-activation is still triggered, but the leg roles are swapped relative to the stated intent. Fix this to avoid confusion. Change-Id: Ie795516a447976ffe7b94ff8efcc649af0e37790 --- M bsc/BSC_Tests_LCLS.ttcn 1 file changed, 1 insertion(+), 1 deletion(-) git pull ssh://gerrit.osmocom.org:29418/osmo-ttcn3-hacks refs/changes/90/42390/1 diff --git a/bsc/BSC_Tests_LCLS.ttcn b/bsc/BSC_Tests_LCLS.ttcn index 37b6198..3def9f2 100644 --- a/bsc/BSC_Tests_LCLS.ttcn +++ b/bsc/BSC_Tests_LCLS.ttcn @@ -409,7 +409,7 @@ /* The second call leg uses half-rate */ pars_b := pars_a; - pars_a.ass_codec_list := valueof(ts_BSSMAP_IE_CodecList({ts_CodecHR})); + pars_b.ass_codec_list := valueof(ts_BSSMAP_IE_CodecList({ts_CodecHR})); /* first call is not possible to be LS (no second leg yet) */ pars_a.lcls.exp_sts := LCLS_STS_not_possible_ls; -- To view, visit https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/42390?usp=email To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings?usp=email Gerrit-MessageType: newchange Gerrit-Project: osmo-ttcn3-hacks Gerrit-Branch: master Gerrit-Change-Id: Ie795516a447976ffe7b94ff8efcc649af0e37790 Gerrit-Change-Number: 42390 Gerrit-PatchSet: 1 Gerrit-Owner: fixeria <vyanitskiy(a)sysmocom.de>
1 0
0 0
[S] Change in osmo-ttcn3-hacks[master]: bts: f_vgcs_talker_detect(): check received req. reference
by fixeria 15 Mar '26

15 Mar '26
fixeria has uploaded this change for review. ( https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/42393?usp=email ) Change subject: bts: f_vgcs_talker_detect(): check received req. reference ...................................................................... bts: f_vgcs_talker_detect(): check received req. reference Change-Id: Ie988408a4c13af72d93e2d29137c9e1ae9a0d408 --- M bts/BTS_Tests_ASCI.ttcn M library/GSM_RR_Types.ttcn 2 files changed, 26 insertions(+), 2 deletions(-) git pull ssh://gerrit.osmocom.org:29418/osmo-ttcn3-hacks refs/changes/93/42393/1 diff --git a/bts/BTS_Tests_ASCI.ttcn b/bts/BTS_Tests_ASCI.ttcn index b982236..85ef39c 100644 --- a/bts/BTS_Tests_ASCI.ttcn +++ b/bts/BTS_Tests_ASCI.ttcn @@ -202,7 +202,6 @@ { var octetstring uplink_free := '082B2B2B2B2B2B2B2B2B2B2B2B2B2B2B2B2B2B2B2B2B2B'O; var octetstring uplink_access := 'C0'O; - var template octetstring uplink_grant := '0609C0*'O; var RSL_Message rm; var GsmFrameNumber fn; @@ -227,7 +226,9 @@ fn := f_L1CTL_RACH(L1CTL, oct2int(uplink_access), chan_nr := g_pars.chan_nr); /* Receive UPLINK GRANT by the MS. */ - f_l1_exp_lapdm(tr_LAPDm_UI(0, cr_MT_CMD, uplink_grant)); + var RequestReference req_ref := f_compute_ReqRef(oct2int(uplink_access), fn); + var template (present) GsmRrL3Message uplink_grant := tr_VGCS_UplinkGrant(req_ref); + f_l1_exp_lapdm(tr_LAPDm_UI(0, cr_MT_CMD, decmatch uplink_grant)); log("Received VGCS UPLINK GRANT."); /* Wait for talker detection. */ diff --git a/library/GSM_RR_Types.ttcn b/library/GSM_RR_Types.ttcn index 3dc1cd5..2ea8d6a 100644 --- a/library/GSM_RR_Types.ttcn +++ b/library/GSM_RR_Types.ttcn @@ -881,6 +881,29 @@ } }; + template (value) GsmRrL3Message + ts_VGCS_UplinkGrant(template (value) RequestReference req_ref, + template (value) TimingAdvance ta) := { + header := ts_RrL3Header(VGCS_UPLINK_GRANT), + payload := { + vgcs_ul_grant := { + req_ref := req_ref, + ta := ta + } + } + }; + template (present) GsmRrL3Message + tr_VGCS_UplinkGrant(template (present) RequestReference req_ref := ?, + template (present) TimingAdvance ta := ?) := { + header := tr_RrL3Header(VGCS_UPLINK_GRANT), + payload := { + vgcs_ul_grant := { + req_ref := req_ref, + ta := ta + } + } + }; + template (value) MeasurementResults ts_MeasurementResults(template (value) uint6_t rxl_f := 63, template (value) uint6_t rxl_s := 63, -- To view, visit https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/42393?usp=email To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings?usp=email Gerrit-MessageType: newchange Gerrit-Project: osmo-ttcn3-hacks Gerrit-Branch: master Gerrit-Change-Id: Ie988408a4c13af72d93e2d29137c9e1ae9a0d408 Gerrit-Change-Number: 42393 Gerrit-PatchSet: 1 Gerrit-Owner: fixeria <vyanitskiy(a)sysmocom.de>
1 0
0 0
[S] Change in osmo-ttcn3-hacks[master]: library/GSM_RR_Types: add send/receive variants for t_RrL3Header
by fixeria 15 Mar '26

15 Mar '26
fixeria has uploaded this change for review. ( https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/42392?usp=email ) Change subject: library/GSM_RR_Types: add send/receive variants for t_RrL3Header ...................................................................... library/GSM_RR_Types: add send/receive variants for t_RrL3Header Change-Id: I35e5897470154f0a868fead4800a46849585a201 --- M bsc/BSC_Tests.ttcn M library/GSM_RR_Types.ttcn 2 files changed, 11 insertions(+), 4 deletions(-) git pull ssh://gerrit.osmocom.org:29418/osmo-ttcn3-hacks refs/changes/92/42392/1 diff --git a/bsc/BSC_Tests.ttcn b/bsc/BSC_Tests.ttcn index ef02faf..17f2326 100644 --- a/bsc/BSC_Tests.ttcn +++ b/bsc/BSC_Tests.ttcn @@ -10154,7 +10154,7 @@ /* Decode the L3 message and make sure it is (RR) Assignment Command */ var GsmRrL3Message l3_msg := dec_GsmRrL3Message(ie.l3_info.payload); - if (not match(l3_msg.header, t_RrL3Header(ASSIGNMENT_COMMAND))) { + if (not match(l3_msg.header, tr_RrL3Header(ASSIGNMENT_COMMAND))) { setverdict(fail, "Failed to match Assignment Command: ", l3_msg); continue; } @@ -10224,7 +10224,7 @@ /* Decode the L3 message and make sure it is (RR) Handover Command */ var GsmRrL3Message l3_msg := dec_GsmRrL3Message(ie.l3_info.payload); - if (not match(l3_msg.header, t_RrL3Header(HANDOVER_COMMAND))) { + if (not match(l3_msg.header, tr_RrL3Header(HANDOVER_COMMAND))) { setverdict(fail, "Failed to match Handover Command: ", l3_msg); return; } diff --git a/library/GSM_RR_Types.ttcn b/library/GSM_RR_Types.ttcn index 963ad0c..3dc1cd5 100644 --- a/library/GSM_RR_Types.ttcn +++ b/library/GSM_RR_Types.ttcn @@ -205,7 +205,14 @@ RrMessageType message_type } with { variant "" }; - template RrL3Header t_RrL3Header(RrMessageType msg_type) := { + template (value) RrL3Header + ts_RrL3Header(template (value) RrMessageType msg_type) := { + skip_indicator := 0, + rr_protocol_discriminator := 6, + message_type := msg_type + } + template (present) RrL3Header + tr_RrL3Header(template (present) RrMessageType msg_type := ?) := { skip_indicator := 0, rr_protocol_discriminator := 6, message_type := msg_type @@ -897,7 +904,7 @@ template (value) GsmRrL3Message ts_MEAS_REP(template (value) MeasurementResults meas_res := ts_MeasurementResults) := { - header := t_RrL3Header(MEASUREMENT_REPORT), + header := ts_RrL3Header(MEASUREMENT_REPORT), payload := { meas_rep := { meas_res := meas_res -- To view, visit https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/42392?usp=email To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings?usp=email Gerrit-MessageType: newchange Gerrit-Project: osmo-ttcn3-hacks Gerrit-Branch: master Gerrit-Change-Id: I35e5897470154f0a868fead4800a46849585a201 Gerrit-Change-Number: 42392 Gerrit-PatchSet: 1 Gerrit-Owner: fixeria <vyanitskiy(a)sysmocom.de>
1 0
0 0
[S] Change in osmo-ttcn3-hacks[master]: bsc: f_TC_fh_params_gen_tr_ma(): simplify ma_mask calculation
by fixeria 15 Mar '26

15 Mar '26
fixeria has uploaded this change for review. ( https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/42395?usp=email ) Change subject: bsc: f_TC_fh_params_gen_tr_ma(): simplify ma_mask calculation ...................................................................... bsc: f_TC_fh_params_gen_tr_ma(): simplify ma_mask calculation Commented out code did not work back in 2020, but recent TITAN versions (we use 11.1.0) have no problems compiling/running it. Change-Id: I1892366af13b80844bcda3f84d18578284c35e08 --- M bsc/BSC_Tests.ttcn 1 file changed, 2 insertions(+), 12 deletions(-) git pull ssh://gerrit.osmocom.org:29418/osmo-ttcn3-hacks refs/changes/95/42395/1 diff --git a/bsc/BSC_Tests.ttcn b/bsc/BSC_Tests.ttcn index 17f2326..e97ecb0 100644 --- a/bsc/BSC_Tests.ttcn +++ b/bsc/BSC_Tests.ttcn @@ -9907,22 +9907,12 @@ if (full_mask[i] != '1'B) { continue; } - /* FIXME: ma_mask := ma_mask & slot_mask[i]; // triggers a bug in TITAN */ - if (slot_mask[i] == '1'B) { - ma_mask := ma_mask & '1'B; - } else { - ma_mask := ma_mask & '0'B; - } + ma_mask := ma_mask & slot_mask[i]; } /* ARFCN 0 (if present) goes to the last position of the bit-mask */ if (full_mask[0] == '1'B) { - /* FIXME: ma_mask := ma_mask & slot_mask[0]; // triggers a bug in TITAN */ - if (slot_mask[0] == '1'B) { - ma_mask := ma_mask & '1'B; - } else { - ma_mask := ma_mask & '0'B; - } + ma_mask := ma_mask & slot_mask[0]; } /* Ensure that ma_mask is octet-aligned */ -- To view, visit https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/42395?usp=email To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings?usp=email Gerrit-MessageType: newchange Gerrit-Project: osmo-ttcn3-hacks Gerrit-Branch: master Gerrit-Change-Id: I1892366af13b80844bcda3f84d18578284c35e08 Gerrit-Change-Number: 42395 Gerrit-PatchSet: 1 Gerrit-Owner: fixeria <vyanitskiy(a)sysmocom.de>
1 0
0 0
[S] Change in osmo-ttcn3-hacks[master]: bts: pre-compute RACH RA using oct2int() early
by fixeria 15 Mar '26

15 Mar '26
fixeria has uploaded this change for review. ( https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/42394?usp=email ) Change subject: bts: pre-compute RACH RA using oct2int() early ...................................................................... bts: pre-compute RACH RA using oct2int() early Change-Id: I03e8748cf56fa1aa9b598d237d325989d91ca372 --- M bts/BTS_Tests_ASCI.ttcn 1 file changed, 6 insertions(+), 6 deletions(-) git pull ssh://gerrit.osmocom.org:29418/osmo-ttcn3-hacks refs/changes/94/42394/1 diff --git a/bts/BTS_Tests_ASCI.ttcn b/bts/BTS_Tests_ASCI.ttcn index 85ef39c..0eb4a05 100644 --- a/bts/BTS_Tests_ASCI.ttcn +++ b/bts/BTS_Tests_ASCI.ttcn @@ -201,7 +201,7 @@ private function f_vgcs_talker_detect() runs on ConnHdlr { var octetstring uplink_free := '082B2B2B2B2B2B2B2B2B2B2B2B2B2B2B2B2B2B2B2B2B2B'O; - var octetstring uplink_access := 'C0'O; + var uint8_t ra := oct2int('C0'O); var RSL_Message rm; var GsmFrameNumber fn; @@ -223,10 +223,10 @@ /* Send UPLINK ACCESS on VGCS channel. */ log("Send UPLINK ACCESS."); - fn := f_L1CTL_RACH(L1CTL, oct2int(uplink_access), chan_nr := g_pars.chan_nr); + fn := f_L1CTL_RACH(L1CTL, ra, chan_nr := g_pars.chan_nr); /* Receive UPLINK GRANT by the MS. */ - var RequestReference req_ref := f_compute_ReqRef(oct2int(uplink_access), fn); + var RequestReference req_ref := f_compute_ReqRef(ra, fn); var template (present) GsmRrL3Message uplink_grant := tr_VGCS_UplinkGrant(req_ref); f_l1_exp_lapdm(tr_LAPDm_UI(0, cr_MT_CMD, decmatch uplink_grant)); log("Received VGCS UPLINK GRANT."); @@ -343,7 +343,7 @@ private function f_TC_vgcs_listener_det(charstring id) runs on ConnHdlr { - var octetstring uplink_access := '25'O; + var uint8_t ra := oct2int('25'O); var RSL_Message rm; var GsmFrameNumber fn; @@ -359,7 +359,7 @@ /* Send UPLINK ACCESS on VGCS channel. */ log("Send UPLINK ACCESS."); - fn := f_L1CTL_RACH(L1CTL, oct2int(uplink_access), chan_nr := g_pars.chan_nr); + fn := f_L1CTL_RACH(L1CTL, ra, chan_nr := g_pars.chan_nr); /* Wait for listener detection. */ timer T := 2.0; @@ -381,7 +381,7 @@ /* Send UPLINK ACCESS on VGCS channel. */ log("Send second UPLINK ACCESS."); - fn := f_L1CTL_RACH(L1CTL, oct2int(uplink_access), chan_nr := g_pars.chan_nr); + fn := f_L1CTL_RACH(L1CTL, ra, chan_nr := g_pars.chan_nr); /* Wait for listener detection. */ T.start; -- To view, visit https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/42394?usp=email To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings?usp=email Gerrit-MessageType: newchange Gerrit-Project: osmo-ttcn3-hacks Gerrit-Branch: master Gerrit-Change-Id: I03e8748cf56fa1aa9b598d237d325989d91ca372 Gerrit-Change-Number: 42394 Gerrit-PatchSet: 1 Gerrit-Owner: fixeria <vyanitskiy(a)sysmocom.de>
1 0
0 0
[S] Change in pysim[master]: global_platform: refactor gen_install_parameters()
by fixeria 15 Mar '26

15 Mar '26
Attention is currently required from: fixeria. Hello Jenkins Builder, I'd like you to reexamine a change. Please visit https://gerrit.osmocom.org/c/pysim/+/42378?usp=email to look at the new patch set (#2). The following approvals got outdated and were removed: Verified-1 by Jenkins Builder Change subject: global_platform: refactor gen_install_parameters() ...................................................................... global_platform: refactor gen_install_parameters() Change-Id: I8756fb38016cdf0527fe2e21edb44381d1dc557f --- M pySim/global_platform/install_param.py M tests/unittests/test_globalplatform.py 2 files changed, 15 insertions(+), 15 deletions(-) git pull ssh://gerrit.osmocom.org:29418/pysim refs/changes/78/42378/2 -- To view, visit https://gerrit.osmocom.org/c/pysim/+/42378?usp=email To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings?usp=email Gerrit-MessageType: newpatchset Gerrit-Project: pysim Gerrit-Branch: master Gerrit-Change-Id: I8756fb38016cdf0527fe2e21edb44381d1dc557f Gerrit-Change-Number: 42378 Gerrit-PatchSet: 2 Gerrit-Owner: fixeria <vyanitskiy(a)sysmocom.de> Gerrit-Reviewer: Jenkins Builder Gerrit-Attention: fixeria <vyanitskiy(a)sysmocom.de>
1 0
0 0
[XS] Change in pysim[master]: cdma_ruim: fix inaccurate comment for EF_AD
by fixeria 15 Mar '26

15 Mar '26
fixeria has uploaded this change for review. ( https://gerrit.osmocom.org/c/pysim/+/42388?usp=email ) Change subject: cdma_ruim: fix inaccurate comment for EF_AD ...................................................................... cdma_ruim: fix inaccurate comment for EF_AD Change-Id: I71ea27fd30e44685ff35f49843072ca392995973 --- M pySim/cdma_ruim.py 1 file changed, 1 insertion(+), 1 deletion(-) git pull ssh://gerrit.osmocom.org:29418/pysim refs/changes/88/42388/1 diff --git a/pySim/cdma_ruim.py b/pySim/cdma_ruim.py index 7bfebae..6b71251 100644 --- a/pySim/cdma_ruim.py +++ b/pySim/cdma_ruim.py @@ -131,7 +131,7 @@ desc='Administrative Data', size=(3, None), **kwargs): super().__init__(fid, sfid=sfid, name=name, desc=desc, size=size, **kwargs) self._construct = Struct( - # Byte 1: Display Condition + # Byte 1: MS operation mode 'ms_operation_mode'/Enum(Byte, self.OP_MODE), # Bytes 2-3: Additional information 'additional_info'/Bytes(2), -- To view, visit https://gerrit.osmocom.org/c/pysim/+/42388?usp=email To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings?usp=email Gerrit-MessageType: newchange Gerrit-Project: pysim Gerrit-Branch: master Gerrit-Change-Id: I71ea27fd30e44685ff35f49843072ca392995973 Gerrit-Change-Number: 42388 Gerrit-PatchSet: 1 Gerrit-Owner: fixeria <vyanitskiy(a)sysmocom.de>
1 0
0 0
[XS] Change in pysim[master]: esim/saip: raise an exception properly
by fixeria 15 Mar '26

15 Mar '26
fixeria has uploaded this change for review. ( https://gerrit.osmocom.org/c/pysim/+/42389?usp=email ) Change subject: esim/saip: raise an exception properly ...................................................................... esim/saip: raise an exception properly Change-Id: Ia3749c02120fdc16e556214d0461cbeca032447b --- M pySim/esim/saip/__init__.py 1 file changed, 1 insertion(+), 1 deletion(-) git pull ssh://gerrit.osmocom.org:29418/pysim refs/changes/89/42389/1 diff --git a/pySim/esim/saip/__init__.py b/pySim/esim/saip/__init__.py index bdbbccf..9fa1d28 100644 --- a/pySim/esim/saip/__init__.py +++ b/pySim/esim/saip/__init__.py @@ -441,7 +441,7 @@ elif k == 'fillFileContent': stream.write(v) else: - return ValueError("Unknown key '%s' in tuple list" % k) + raise ValueError("Unknown key '%s' in tuple list" % k) return stream.getvalue() def file_content_to_tuples(self, optimize:bool = False) -> List[Tuple]: -- To view, visit https://gerrit.osmocom.org/c/pysim/+/42389?usp=email To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings?usp=email Gerrit-MessageType: newchange Gerrit-Project: pysim Gerrit-Branch: master Gerrit-Change-Id: Ia3749c02120fdc16e556214d0461cbeca032447b Gerrit-Change-Number: 42389 Gerrit-PatchSet: 1 Gerrit-Owner: fixeria <vyanitskiy(a)sysmocom.de>
1 0
0 0
[XS] Change in pysim[master]: global_platform: fix s/GET/STORE/ DATA in docs
by fixeria 15 Mar '26

15 Mar '26
fixeria has uploaded this change for review. ( https://gerrit.osmocom.org/c/pysim/+/42376?usp=email ) Change subject: global_platform: fix s/GET/STORE/ DATA in docs ...................................................................... global_platform: fix s/GET/STORE/ DATA in docs Both `do_store_data` and `store_data` have identical docstrings that incorrectly describe the command as GET DATA. Should be "STORE DATA". Take a chance to fix missing space between `v2.3` and `Section`. Change-Id: I33fc80ab8ca50fadc38217b0005eec6169c8e34e --- M pySim/global_platform/__init__.py 1 file changed, 4 insertions(+), 4 deletions(-) git pull ssh://gerrit.osmocom.org:29418/pysim refs/changes/76/42376/1 diff --git a/pySim/global_platform/__init__.py b/pySim/global_platform/__init__.py index a836134..22554c6 100644 --- a/pySim/global_platform/__init__.py +++ b/pySim/global_platform/__init__.py @@ -562,14 +562,14 @@ @cmd2.with_argparser(store_data_parser) def do_store_data(self, opts): - """Perform the GlobalPlatform GET DATA command in order to store some card-specific data. - See GlobalPlatform CardSpecification v2.3Section 11.11 for details.""" + """Perform the GlobalPlatform STORE DATA command in order to store some card-specific data. + See GlobalPlatform CardSpecification v2.3 Section 11.11 for details.""" response_permitted = opts.response == 'may_be_returned' self.store_data(h2b(opts.DATA), opts.data_structure, opts.encryption, response_permitted) def store_data(self, data: bytes, structure:str = 'none', encryption:str = 'none', response_permitted: bool = False) -> bytes: - """Perform the GlobalPlatform GET DATA command in order to store some card-specific data. - See GlobalPlatform CardSpecification v2.3Section 11.11 for details.""" + """Perform the GlobalPlatform STORE DATA command in order to store some card-specific data. + See GlobalPlatform CardSpecification v2.3 Section 11.11 for details.""" max_cmd_len = self._cmd.lchan.scc.max_cmd_len # Table 11-89 of GP Card Specification v2.3 remainder = data -- To view, visit https://gerrit.osmocom.org/c/pysim/+/42376?usp=email To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings?usp=email Gerrit-MessageType: newchange Gerrit-Project: pysim Gerrit-Branch: master Gerrit-Change-Id: I33fc80ab8ca50fadc38217b0005eec6169c8e34e Gerrit-Change-Number: 42376 Gerrit-PatchSet: 1 Gerrit-Owner: fixeria <vyanitskiy(a)sysmocom.de>
1 0
0 0
[S] Change in pysim[master]: global_platform: refactor gen_install_parameters()
by fixeria 15 Mar '26

15 Mar '26
fixeria has uploaded this change for review. ( https://gerrit.osmocom.org/c/pysim/+/42378?usp=email ) Change subject: global_platform: refactor gen_install_parameters() ...................................................................... global_platform: refactor gen_install_parameters() Change-Id: I8756fb38016cdf0527fe2e21edb44381d1dc557f --- M pySim/global_platform/install_param.py 1 file changed, 14 insertions(+), 14 deletions(-) git pull ssh://gerrit.osmocom.org:29418/pysim refs/changes/78/42378/1 diff --git a/pySim/global_platform/install_param.py b/pySim/global_platform/install_param.py index 89e6c7f..fc96792 100644 --- a/pySim/global_platform/install_param.py +++ b/pySim/global_platform/install_param.py @@ -17,6 +17,8 @@ # along with this program. If not, see <http://www.gnu.org/licenses/>. # +from typing import Optional + from osmocom.construct import * from osmocom.utils import * from osmocom.tlv import * @@ -46,7 +48,9 @@ # GPD_SPE_013, table 11-49 pass -def gen_install_parameters(non_volatile_memory_quota:int, volatile_memory_quota:int, stk_parameter:str): +def gen_install_parameters(non_volatile_memory_quota: Optional[int] = None, + volatile_memory_quota: Optional[int] = None, + stk_parameter: Optional[str] = None): # GPD_SPE_013, table 11-49 @@ -54,19 +58,15 @@ install_params = InstallParams() install_params_dict = [{'app_specific_params': None}] - #Conditional - if non_volatile_memory_quota and volatile_memory_quota and stk_parameter: - system_specific_params = [] - #Optional - if non_volatile_memory_quota: - system_specific_params += [{'non_volatile_memory_quota': non_volatile_memory_quota}] - #Optional - if volatile_memory_quota: - system_specific_params += [{'volatile_memory_quota': volatile_memory_quota}] - #Optional - if stk_parameter: - system_specific_params += [{'stk_parameter': stk_parameter}] - install_params_dict += [{'system_specific_params': system_specific_params}] + system_specific_params = [] + if non_volatile_memory_quota is not None: + system_specific_params.append({'non_volatile_memory_quota': non_volatile_memory_quota}) + if volatile_memory_quota is not None: + system_specific_params.append({'volatile_memory_quota': volatile_memory_quota}) + if stk_parameter is not None: + system_specific_params.append({'stk_parameter': stk_parameter}) + if system_specific_params: + install_params_dict.append({'system_specific_params': system_specific_params}) install_params.from_dict(install_params_dict) return b2h(install_params.to_bytes()) -- To view, visit https://gerrit.osmocom.org/c/pysim/+/42378?usp=email To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings?usp=email Gerrit-MessageType: newchange Gerrit-Project: pysim Gerrit-Branch: master Gerrit-Change-Id: I8756fb38016cdf0527fe2e21edb44381d1dc557f Gerrit-Change-Number: 42378 Gerrit-PatchSet: 1 Gerrit-Owner: fixeria <vyanitskiy(a)sysmocom.de>
1 0
0 0
  • ← Newer
  • 1
  • ...
  • 118
  • 119
  • 120
  • 121
  • 122
  • 123
  • 124
  • ...
  • 194
  • Older →

HyperKitty Powered by HyperKitty version 1.3.12.