enums: replace Roman numeral suffixes in MM_MODEM_BAND_EUTRAN_*

3GPP TS 36.101 Table 5.5-1 refers the E-UTRA operating bands as 1, 2, 3,
..., etc.
This commit is contained in:
Ben Chan
2017-06-28 18:21:25 +02:00
committed by Aleksander Morgado
parent 0fb0184a2f
commit 989ade7b8c
8 changed files with 239 additions and 240 deletions
+3 -3
View File
@@ -57,8 +57,8 @@ mm_telit_get_band_flag (GArray *bands_array,
}
if (flag4g != NULL &&
band >= MM_MODEM_BAND_EUTRAN_I && band <= MM_MODEM_BAND_EUTRAN_XLIV) {
mask4g += 1 << (band - MM_MODEM_BAND_EUTRAN_I);
band >= MM_MODEM_BAND_EUTRAN_1 && band <= MM_MODEM_BAND_EUTRAN_44) {
mask4g += 1 << (band - MM_MODEM_BAND_EUTRAN_1);
found4g = TRUE;
}
}
@@ -480,7 +480,7 @@ mm_telit_get_4g_mm_bands(GMatchInfo *match_info,
for (i = 0; value > 0; i++) {
if (value % 2 != 0) {
band = MM_MODEM_BAND_EUTRAN_I + i;
band = MM_MODEM_BAND_EUTRAN_1 + i;
g_array_append_val (*bands, band);
}
value = value >> 1;
@@ -189,14 +189,14 @@ static BNDResponseTest supported_band_mapping_tests [] = {
MM_MODEM_BAND_U2100,
MM_MODEM_BAND_U850,
MM_MODEM_BAND_U900,
MM_MODEM_BAND_EUTRAN_I} },
MM_MODEM_BAND_EUTRAN_1} },
{ "#BND: (0),(0),(1-3)", TRUE, TRUE, TRUE, 5, { MM_MODEM_BAND_EGSM,
MM_MODEM_BAND_DCS,
MM_MODEM_BAND_U2100,
MM_MODEM_BAND_EUTRAN_I,
MM_MODEM_BAND_EUTRAN_II} },
{ "#BND: (0),(0),(1-3)", FALSE, FALSE, TRUE, 2, { MM_MODEM_BAND_EUTRAN_I,
MM_MODEM_BAND_EUTRAN_II} },
MM_MODEM_BAND_EUTRAN_1,
MM_MODEM_BAND_EUTRAN_2} },
{ "#BND: (0),(0),(1-3)", FALSE, FALSE, TRUE, 2, { MM_MODEM_BAND_EUTRAN_1,
MM_MODEM_BAND_EUTRAN_2} },
{ NULL, FALSE, FALSE, FALSE, 0, {}},
};
@@ -261,17 +261,17 @@ static BNDResponseTest current_band_mapping_tests [] = {
{ "#BND: 3,0,1", TRUE, TRUE, TRUE, 4, { MM_MODEM_BAND_PCS,
MM_MODEM_BAND_G850,
MM_MODEM_BAND_U2100,
MM_MODEM_BAND_EUTRAN_I
MM_MODEM_BAND_EUTRAN_1
}
},
{ "#BND: 0,0,3", TRUE, FALSE, TRUE, 4, { MM_MODEM_BAND_EGSM,
MM_MODEM_BAND_DCS,
MM_MODEM_BAND_EUTRAN_I,
MM_MODEM_BAND_EUTRAN_II
MM_MODEM_BAND_EUTRAN_1,
MM_MODEM_BAND_EUTRAN_2
}
},
{ "#BND: 0,0,3", FALSE, FALSE, TRUE, 2, { MM_MODEM_BAND_EUTRAN_I,
MM_MODEM_BAND_EUTRAN_II
{ "#BND: 0,0,3", FALSE, FALSE, TRUE, 2, { MM_MODEM_BAND_EUTRAN_1,
MM_MODEM_BAND_EUTRAN_2
}
},
{ NULL, FALSE, FALSE, FALSE, 0, {}},
@@ -471,8 +471,8 @@ static void
test_telit_get_4g_bnd_flag (void)
{
GArray *bands_array;
MMModemBand eutran_i = MM_MODEM_BAND_EUTRAN_I;
MMModemBand eutran_ii = MM_MODEM_BAND_EUTRAN_II;
MMModemBand eutran_i = MM_MODEM_BAND_EUTRAN_1;
MMModemBand eutran_ii = MM_MODEM_BAND_EUTRAN_2;
MMModemBand egsm = MM_MODEM_BAND_EGSM;
gint flag = -1;