aboutsummaryrefslogtreecommitdiff
path: root/src/mm-iface-modem-simple.c
diff options
context:
space:
mode:
authorAleksander Morgado <aleksander@lanedo.com>2012-02-17 16:57:12 +0100
committerAleksander Morgado <aleksander@lanedo.com>2012-03-16 14:28:13 +0100
commit09d2f062c73a62bc32c21d2bcd9249c8a174fe82 (patch)
treefa3bfab24497997fe3ded9dbc92dd04afd8f50b3 /src/mm-iface-modem-simple.c
parent76e52236a44d87bc7aacb141b956146ab67d66eb (diff)
api,dbus: rename `AllowedBands' to just `Bands'
ModemManager will load: 1) The list of supported bands. Note that this doesn't mean that any possible combination of bands is supported, as modems may support only specific combinations, but at least gives a rough idea of what the modem is capable of handling. 2) The list of CURRENT bands. There is no such "Allowed" bands, as we do with modes, modems will have a specific set of bands being currently used, which will be reported in the `Bands' property. If the modem allows modifying the list of bands to use, this can be done with the `SetBands()' method. If the modem doesn't support using a specific combination of bands, this method will report an error.
Diffstat (limited to 'src/mm-iface-modem-simple.c')
-rw-r--r--src/mm-iface-modem-simple.c42
1 files changed, 21 insertions, 21 deletions
diff --git a/src/mm-iface-modem-simple.c b/src/mm-iface-modem-simple.c
index b112472a..5d5afc15 100644
--- a/src/mm-iface-modem-simple.c
+++ b/src/mm-iface-modem-simple.c
@@ -172,7 +172,7 @@ typedef enum {
CONNECTION_STEP_UNLOCK_CHECK,
CONNECTION_STEP_ENABLE,
CONNECTION_STEP_ALLOWED_MODES,
- CONNECTION_STEP_ALLOWED_BANDS,
+ CONNECTION_STEP_BANDS,
CONNECTION_STEP_REGISTER,
CONNECTION_STEP_BEARER,
CONNECTION_STEP_CONNECT,
@@ -286,14 +286,14 @@ set_allowed_modes_ready (MMBaseModem *self,
}
static void
-set_allowed_bands_ready (MMBaseModem *self,
- GAsyncResult *res,
- ConnectionContext *ctx)
+set_bands_ready (MMBaseModem *self,
+ GAsyncResult *res,
+ ConnectionContext *ctx)
{
GError *error = NULL;
- if (!mm_iface_modem_set_allowed_bands_finish (MM_IFACE_MODEM (self), res, &error)) {
- /* If setting allowed bands is unsupported, keep on */
+ if (!mm_iface_modem_set_bands_finish (MM_IFACE_MODEM (self), res, &error)) {
+ /* If setting bands is unsupported, keep on */
if (!g_error_matches (error,
MM_CORE_ERROR,
MM_CORE_ERROR_UNSUPPORTED)) {
@@ -303,7 +303,7 @@ set_allowed_bands_ready (MMBaseModem *self,
}
}
- /* Allowed bands set... almost there! */
+ /* Bands set... almost there! */
ctx->step++;
connection_step (ctx);
}
@@ -448,27 +448,27 @@ connection_step (ConnectionContext *ctx)
return;
}
- case CONNECTION_STEP_ALLOWED_BANDS: {
+ case CONNECTION_STEP_BANDS: {
GArray *array;
- const MMModemBand *allowed_bands = NULL;
- guint n_allowed_bands = 0;
+ const MMModemBand *bands = NULL;
+ guint n_bands = 0;
guint i;
- mm_info ("Simple connect state (%d/%d): Allowed bands",
+ mm_info ("Simple connect state (%d/%d): Bands",
ctx->step, CONNECTION_STEP_LAST);
- mm_common_connect_properties_get_allowed_bands (ctx->properties,
- &allowed_bands,
- &n_allowed_bands);
+ mm_common_connect_properties_get_bands (ctx->properties,
+ &bands,
+ &n_bands);
- array = g_array_sized_new (FALSE, FALSE, sizeof (MMModemBand), n_allowed_bands);
- for (i = 0; i < n_allowed_bands; i++)
- g_array_insert_val (array, i, allowed_bands[i]);
+ array = g_array_sized_new (FALSE, FALSE, sizeof (MMModemBand), n_bands);
+ for (i = 0; i < n_bands; i++)
+ g_array_insert_val (array, i, bands[i]);
- mm_iface_modem_set_allowed_bands (MM_IFACE_MODEM (ctx->self),
- array,
- (GAsyncReadyCallback)set_allowed_bands_ready,
- ctx);
+ mm_iface_modem_set_bands (MM_IFACE_MODEM (ctx->self),
+ array,
+ (GAsyncReadyCallback)set_bands_ready,
+ ctx);
g_array_unref (array);
return;
}