[PATCH] novatel-lte: remove unnecessary MM_BASE_MODEM() casts
Ben Chan
benchan at chromium.org
Mon Jan 6 11:47:08 PST 2014
---
plugins/novatel/mm-broadband-bearer-novatel-lte.c | 19 +++++--------------
plugins/novatel/mm-sim-novatel-lte.c | 2 +-
2 files changed, 6 insertions(+), 15 deletions(-)
diff --git a/plugins/novatel/mm-broadband-bearer-novatel-lte.c b/plugins/novatel/mm-broadband-bearer-novatel-lte.c
index ed6b027..fc0a511 100644
--- a/plugins/novatel/mm-broadband-bearer-novatel-lte.c
+++ b/plugins/novatel/mm-broadband-bearer-novatel-lte.c
@@ -173,9 +173,7 @@ connect_3gpp_qmistatus_ready (MMBaseModem *modem,
gchar *normalized_result;
GError *error = NULL;
- result = mm_base_modem_at_command_finish (MM_BASE_MODEM (ctx->modem),
- res,
- &error);
+ result = mm_base_modem_at_command_finish (modem, res, &error);
if (!result) {
mm_warn ("QMI connection status failed: %s", error->message);
if (!g_error_matches (error, MM_MOBILE_EQUIPMENT_ERROR, MM_MOBILE_EQUIPMENT_ERROR_UNKNOWN)) {
@@ -258,9 +256,7 @@ connect_3gpp_qmiconnect_ready (MMBaseModem *modem,
const gchar *result;
GError *error = NULL;
- result = mm_base_modem_at_command_finish (MM_BASE_MODEM (modem),
- res,
- &error);
+ result = mm_base_modem_at_command_finish (modem, res, &error);
if (!result) {
mm_warn ("QMI connection failed: %s", error->message);
g_simple_async_result_take_error (ctx->result, error);
@@ -325,8 +321,7 @@ connect_3gpp (MMBroadbandBearer *self,
ctx->retries = 60;
/* Get a 'net' data port */
- ctx->data = mm_base_modem_get_best_data_port (MM_BASE_MODEM (modem),
- MM_PORT_TYPE_NET);
+ ctx->data = mm_base_modem_get_best_data_port (ctx->modem, MM_PORT_TYPE_NET);
if (!ctx->data) {
g_simple_async_result_set_error (
ctx->result,
@@ -411,9 +406,7 @@ disconnect_3gpp_status_ready (MMBaseModem *modem,
GError *error = NULL;
gboolean is_connected = FALSE;
- result = mm_base_modem_at_command_finish (MM_BASE_MODEM (modem),
- res,
- &error);
+ result = mm_base_modem_at_command_finish (modem, res, &error);
if (result) {
mm_dbg ("QMI connection status: %s", result);
if (is_qmistatus_disconnected (result)) {
@@ -478,9 +471,7 @@ disconnect_3gpp_check_status (MMBaseModem *modem,
{
GError *error = NULL;
- mm_base_modem_at_command_finish (MM_BASE_MODEM (modem),
- res,
- &error);
+ mm_base_modem_at_command_finish (modem, res, &error);
if (error) {
mm_dbg("Disconnection error: %s", error->message);
g_error_free (error);
diff --git a/plugins/novatel/mm-sim-novatel-lte.c b/plugins/novatel/mm-sim-novatel-lte.c
index b5bccdb..489dd02 100644
--- a/plugins/novatel/mm-sim-novatel-lte.c
+++ b/plugins/novatel/mm-sim-novatel-lte.c
@@ -188,7 +188,7 @@ load_imsi (MMSim *self,
mm_dbg ("loading (Novatel LTE) IMSI...");
mm_base_modem_at_command (
- MM_BASE_MODEM (modem),
+ modem,
"+CRSM=176,28423,0,0,9",
3,
FALSE,
--
1.8.5.1
More information about the ModemManager-devel
mailing list