aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDan Williams <dcbw@redhat.com>2013-03-13 10:31:06 -0500
committerDan Williams <dcbw@redhat.com>2013-03-13 10:31:06 -0500
commit671d34cf925c63e0c06934bb3516d42581efeb35 (patch)
treea5bf78c8370fb585d80943aca4cc0b3296cf3756
parentbee388098cb892c8697419f5f007f8d506ec8dd4 (diff)
qcdm: add auto-LTE modes for GSM and CDMA
as in, CDMA+EVDO+LTE and GSM+UMTS+LTE which were missing before.
-rw-r--r--libqcdm/tests/modepref.c16
1 files changed, 14 insertions, 2 deletions
diff --git a/libqcdm/tests/modepref.c b/libqcdm/tests/modepref.c
index e6925324..43272411 100644
--- a/libqcdm/tests/modepref.c
+++ b/libqcdm/tests/modepref.c
@@ -429,7 +429,7 @@ static void
usage (const char *prog)
{
fprintf (stderr, "Usage: %s <DM port> [<mode>] [--debug]\n", prog);
- fprintf (stderr, " <mode> = lte, auto-cdma, auto, cdma, evdo, auto-gsm, gprs, umts\n");
+ fprintf (stderr, " <mode> = auto, lte, auto-cdma-lte, auto-cdma, cdma, evdo, auto-gsm-lte, auto-gsm, gsm, umts\n");
fprintf (stderr, " If <mode> is missing, current mode will be printed.\n\n");
}
@@ -445,6 +445,13 @@ parse_mode (const char *s,
return TRUE;
}
+ if (strcasecmp (s, "auto-cdma-lte") == 0) {
+ *out_mode = QCDM_CMD_NV_MODE_PREF_ITEM_MODE_PREF_1X_HDR_LTE_ONLY;
+ *out_hdrpref = QCDM_CMD_NV_HDR_REV_PREF_ITEM_REV_PREF_EHRPD;
+ *out_set_evdo = TRUE;
+ return TRUE;
+ }
+
if (strcasecmp (s, "auto-cdma") == 0) {
*out_mode = QCDM_CMD_NV_MODE_PREF_ITEM_MODE_PREF_1X_HDR_ONLY;
*out_hdrpref = QCDM_CMD_NV_HDR_REV_PREF_ITEM_REV_PREF_A;
@@ -473,12 +480,17 @@ parse_mode (const char *s,
return TRUE;
}
+ if (strcasecmp (s, "auto-gsm-lte") == 0) {
+ *out_mode = QCDM_CMD_NV_MODE_PREF_ITEM_MODE_PREF_GSM_UMTS_LTE_ONLY;
+ return TRUE;
+ }
+
if (strcasecmp (s, "auto-gsm") == 0) {
*out_mode = QCDM_CMD_NV_MODE_PREF_ITEM_MODE_PREF_GSM_UMTS_ONLY;
return TRUE;
}
- if (strcasecmp (s, "gprs") == 0) {
+ if (strcasecmp (s, "gsm") == 0) {
*out_mode = QCDM_CMD_NV_MODE_PREF_ITEM_MODE_PREF_GPRS_ONLY;
return TRUE;
}