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/.
Harald Welte gerrit-no-reply at lists.osmocom.orgHarald Welte has submitted this change and it was merged. Change subject: gsm0808_test: cosmetic: test non-hex MCC ...................................................................... gsm0808_test: cosmetic: test non-hex MCC The test currently sets the MCC by a hex value, which is a weird choice. The MCC gets BCD'd and hence we will see the decimal values 1:1 in the encoded octets as hex digits. Using hex as input obscures that: Right now it sets mcc = 0x123, which is actually 291 in decimal, and we hence see "92 .1" in the expected BCD result. Using 0x124 in the test source actually makes it hard to see where the 0x123 went. Change the MCC to decimal notation (123, 124, 125) and adjust the expected encoded output. Change-Id: I973835c54a90fefe50d2b3581324d12556715f58 --- M tests/gsm0808/gsm0808_test.c 1 file changed, 6 insertions(+), 6 deletions(-) Approvals: Harald Welte: Looks good to me, approved Jenkins Builder: Verified diff --git a/tests/gsm0808/gsm0808_test.c b/tests/gsm0808/gsm0808_test.c index c25344a..abdb26e 100644 --- a/tests/gsm0808/gsm0808_test.c +++ b/tests/gsm0808/gsm0808_test.c @@ -1001,9 +1001,9 @@ struct gsm0808_cell_id_list2 dec_cil; struct msgb *msg; uint8_t cil_enc_expected[] = { GSM0808_IE_CELL_IDENTIFIER_LIST, 0x16, 0x00, - 0x92, 0x61, 0x54, 0x23, 0x42, 0x00, 0x1, - 0x92, 0x72, 0x54, 0x24, 0x43, 0x00, 0x2, - 0x92, 0x83, 0x54, 0x25, 0x44, 0x00, 0x77 + 0x21, 0x63, 0x54, 0x23, 0x42, 0x00, 0x1, + 0x21, 0x74, 0x54, 0x24, 0x43, 0x00, 0x2, + 0x21, 0x85, 0x54, 0x25, 0x44, 0x00, 0x77 }; uint8_t rc_enc; int rc_dec, i; @@ -1014,21 +1014,21 @@ .id_list = { { .global = { - .lai = { .plmn = { .mcc = 0x123, .mnc = 456 }, + .lai = { .plmn = { .mcc = 123, .mnc = 456 }, .lac = 0x2342 }, .cell_identity = 1, } }, { .global = { - .lai = { .plmn = { .mcc = 0x124, .mnc = 457 }, + .lai = { .plmn = { .mcc = 124, .mnc = 457 }, .lac = 0x2443 }, .cell_identity = 2, } }, { .global = { - .lai = { .plmn = { .mcc = 0x125, .mnc = 458 }, + .lai = { .plmn = { .mcc = 125, .mnc = 458 }, .lac = 0x2544 }, .cell_identity = 119, } -- To view, visit https://gerrit.osmocom.org/7473 To unsubscribe, visit https://gerrit.osmocom.org/settings Gerrit-MessageType: merged Gerrit-Change-Id: I973835c54a90fefe50d2b3581324d12556715f58 Gerrit-PatchSet: 2 Gerrit-Project: libosmocore Gerrit-Branch: master Gerrit-Owner: Neels Hofmeyr <nhofmeyr at sysmocom.de> Gerrit-Reviewer: Harald Welte <laforge at gnumonks.org> Gerrit-Reviewer: Jenkins Builder Gerrit-Reviewer: Stefan Sperling <ssperling at sysmocom.de>