aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorAleksander Morgado <aleksander@aleksander.es>2020-11-30 16:05:52 +0100
committerAleksander Morgado <aleksander@aleksander.es>2020-12-21 12:05:57 +0000
commitc99cc9210e7a93be1b572d686f5acdeb0160dd3f (patch)
treefe5744e5226c075f8a2e0a7897e385d56daf9328 /src
parent5613215db8e5b3d4bbd7d3e6ad937b342ccd4c76 (diff)
iface-modem-3gpp: log requested/updates initial EPS bearer settings
Diffstat (limited to 'src')
-rw-r--r--src/mm-iface-modem-3gpp.c44
1 files changed, 44 insertions, 0 deletions
diff --git a/src/mm-iface-modem-3gpp.c b/src/mm-iface-modem-3gpp.c
index b933064e..df8df272 100644
--- a/src/mm-iface-modem-3gpp.c
+++ b/src/mm-iface-modem-3gpp.c
@@ -973,6 +973,45 @@ handle_set_initial_eps_bearer_settings_context_free (HandleSetInitialEpsBearerSe
}
static void
+log_initial_eps_bearer_settings (MMIfaceModem3gpp *self,
+ MMBearerProperties *properties)
+{
+ const gchar *apn;
+ MMBearerAllowedAuth allowed_auth;
+ const gchar *user;
+ const gchar *password;
+ MMBearerIpFamily ip_family;
+
+ apn = mm_bearer_properties_get_apn (properties);
+ if (apn)
+ mm_obj_dbg (self, " APN: '%s'", apn);
+
+ allowed_auth = mm_bearer_properties_get_allowed_auth (properties);
+ if (allowed_auth != MM_BEARER_ALLOWED_AUTH_UNKNOWN) {
+ g_autofree gchar *allowed_auth_str = NULL;
+
+ allowed_auth_str = mm_bearer_allowed_auth_build_string_from_mask (allowed_auth);
+ mm_obj_dbg (self, " allowed auth: '%s'", allowed_auth_str);
+ }
+
+ user = mm_bearer_properties_get_user (properties);
+ if (user)
+ mm_obj_dbg (self, " user: '%s'", user);
+
+ password = mm_bearer_properties_get_password (properties);
+ if (password)
+ mm_obj_dbg (self, " password: '%s'", password);
+
+ ip_family = mm_bearer_properties_get_ip_type (properties);
+ if (ip_family != MM_BEARER_IP_FAMILY_NONE) {
+ g_autofree gchar *ip_family_str = NULL;
+
+ ip_family_str = mm_bearer_ip_family_build_string_from_mask (ip_family);
+ mm_obj_dbg (self, " ip family: '%s'", ip_family_str);
+ }
+}
+
+static void
after_set_load_initial_eps_bearer_settings_ready (MMIfaceModem3gpp *self,
GAsyncResult *res,
HandleSetInitialEpsBearerSettingsContext *ctx)
@@ -987,7 +1026,12 @@ after_set_load_initial_eps_bearer_settings_ready (MMIfaceModem3gpp
return;
}
+ mm_obj_dbg (self, "Updated initial EPS bearer settings:");
+ log_initial_eps_bearer_settings (self, new_config);
+
if (!mm_bearer_properties_cmp (new_config, ctx->config)) {
+ mm_obj_dbg (self, "Requested initial EPS bearer settings:");
+ log_initial_eps_bearer_settings (self, ctx->config);
g_dbus_method_invocation_return_error_literal (ctx->invocation, MM_CORE_ERROR, MM_CORE_ERROR_FAILED,
"Initial EPS bearer settings were not updated");
} else {