aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/mm-broadband-modem-mbim.c12
-rw-r--r--src/mm-broadband-modem-qmi.c12
-rw-r--r--src/mm-broadband-modem.c4
-rw-r--r--src/mm-iface-modem-location.c145
-rw-r--r--src/mm-iface-modem-location.h15
-rw-r--r--src/mm-shared-qmi.c18
-rw-r--r--src/mm-shared-qmi.h2
-rw-r--r--src/plugins/cinterion/mm-broadband-modem-cinterion.c34
-rw-r--r--src/plugins/cinterion/mm-broadband-modem-mbim-cinterion.c22
-rw-r--r--src/plugins/cinterion/mm-broadband-modem-qmi-cinterion.c22
-rw-r--r--src/plugins/cinterion/mm-shared-cinterion.c10
-rw-r--r--src/plugins/cinterion/mm-shared-cinterion.h2
-rw-r--r--src/plugins/foxconn/mm-broadband-modem-mbim-foxconn.c6
-rw-r--r--src/plugins/huawei/mm-broadband-modem-huawei.c14
-rw-r--r--src/plugins/intel/mm-broadband-modem-mbim-intel.c10
-rw-r--r--src/plugins/mbm/mm-broadband-modem-mbm.c14
-rw-r--r--src/plugins/option/mm-broadband-modem-hso.c14
-rw-r--r--src/plugins/quectel/mm-broadband-modem-mbim-quectel.c10
-rw-r--r--src/plugins/quectel/mm-broadband-modem-qmi-quectel.c8
-rw-r--r--src/plugins/quectel/mm-broadband-modem-quectel.c10
-rw-r--r--src/plugins/quectel/mm-shared-quectel.c18
-rw-r--r--src/plugins/quectel/mm-shared-quectel.h6
-rw-r--r--src/plugins/simtech/mm-broadband-modem-qmi-simtech.c14
-rw-r--r--src/plugins/simtech/mm-broadband-modem-simtech.c22
-rw-r--r--src/plugins/simtech/mm-shared-simtech.c8
-rw-r--r--src/plugins/simtech/mm-shared-simtech.h2
-rw-r--r--src/plugins/telit/mm-broadband-modem-telit.c16
-rw-r--r--src/plugins/xmm/mm-broadband-modem-mbim-xmm.c12
-rw-r--r--src/plugins/xmm/mm-broadband-modem-xmm.c14
-rw-r--r--src/plugins/xmm/mm-shared-xmm.c14
-rw-r--r--src/plugins/xmm/mm-shared-xmm.h2
31 files changed, 244 insertions, 268 deletions
diff --git a/src/mm-broadband-modem-mbim.c b/src/mm-broadband-modem-mbim.c
index 64666eb8..842736ba 100644
--- a/src/mm-broadband-modem-mbim.c
+++ b/src/mm-broadband-modem-mbim.c
@@ -55,7 +55,7 @@ static void iface_modem_init (MMIfaceModemInterface
static void iface_modem_3gpp_init (MMIfaceModem3gppInterface *iface);
static void iface_modem_3gpp_profile_manager_init (MMIfaceModem3gppProfileManagerInterface *iface);
static void iface_modem_3gpp_ussd_init (MMIfaceModem3gppUssdInterface *iface);
-static void iface_modem_location_init (MMIfaceModemLocation *iface);
+static void iface_modem_location_init (MMIfaceModemLocationInterface *iface);
static void iface_modem_messaging_init (MMIfaceModemMessaging *iface);
static void iface_modem_signal_init (MMIfaceModemSignal *iface);
static void iface_modem_sar_init (MMIfaceModemSar *iface);
@@ -64,10 +64,10 @@ static void shared_qmi_init (MMSharedQmi
#endif
#if defined WITH_QMI && QMI_MBIM_QMUX_SUPPORTED
-static MMIfaceModemLocation *iface_modem_location_parent;
+static MMIfaceModemLocationInterface *iface_modem_location_parent;
#endif
-static MMIfaceModemSignal *iface_modem_signal_parent;
-static MMIfaceModemInterface *iface_modem_parent;
+static MMIfaceModemSignal *iface_modem_signal_parent;
+static MMIfaceModemInterface *iface_modem_parent;
G_DEFINE_TYPE_EXTENDED (MMBroadbandModemMbim, mm_broadband_modem_mbim, MM_TYPE_BROADBAND_MODEM, 0,
G_IMPLEMENT_INTERFACE (MM_TYPE_IFACE_MODEM, iface_modem_init)
@@ -10265,7 +10265,7 @@ iface_modem_3gpp_ussd_init (MMIfaceModem3gppUssdInterface *iface)
}
static void
-iface_modem_location_init (MMIfaceModemLocation *iface)
+iface_modem_location_init (MMIfaceModemLocationInterface *iface)
{
#if defined WITH_QMI && QMI_MBIM_QMUX_SUPPORTED
iface_modem_location_parent = g_type_interface_peek_parent (iface);
@@ -10350,7 +10350,7 @@ iface_modem_sar_init (MMIfaceModemSar *iface)
#if defined WITH_QMI && QMI_MBIM_QMUX_SUPPORTED
-static MMIfaceModemLocation *
+static MMIfaceModemLocationInterface *
peek_parent_location_interface (MMSharedQmi *self)
{
return iface_modem_location_parent;
diff --git a/src/mm-broadband-modem-qmi.c b/src/mm-broadband-modem-qmi.c
index 62959543..be91c2c7 100644
--- a/src/mm-broadband-modem-qmi.c
+++ b/src/mm-broadband-modem-qmi.c
@@ -60,16 +60,16 @@ static void iface_modem_3gpp_ussd_init (MMIfaceModem3gppUssdInterface
static void iface_modem_voice_init (MMIfaceModemVoice *iface);
static void iface_modem_cdma_init (MMIfaceModemCdma *iface);
static void iface_modem_messaging_init (MMIfaceModemMessaging *iface);
-static void iface_modem_location_init (MMIfaceModemLocation *iface);
+static void iface_modem_location_init (MMIfaceModemLocationInterface *iface);
static void iface_modem_oma_init (MMIfaceModemOma *iface);
static void iface_modem_firmware_init (MMIfaceModemFirmwareInterface *iface);
static void iface_modem_sar_init (MMIfaceModemSar *iface);
static void iface_modem_signal_init (MMIfaceModemSignal *iface);
static void shared_qmi_init (MMSharedQmi *iface);
-static MMIfaceModemLocation *iface_modem_location_parent;
-static MMIfaceModemMessaging *iface_modem_messaging_parent;
-static MMIfaceModemVoice *iface_modem_voice_parent;
+static MMIfaceModemLocationInterface *iface_modem_location_parent;
+static MMIfaceModemMessaging *iface_modem_messaging_parent;
+static MMIfaceModemVoice *iface_modem_voice_parent;
G_DEFINE_TYPE_EXTENDED (MMBroadbandModemQmi, mm_broadband_modem_qmi, MM_TYPE_BROADBAND_MODEM, 0,
G_IMPLEMENT_INTERFACE (MM_TYPE_IFACE_MODEM, iface_modem_init)
@@ -14102,7 +14102,7 @@ iface_modem_messaging_init (MMIfaceModemMessaging *iface)
}
static void
-iface_modem_location_init (MMIfaceModemLocation *iface)
+iface_modem_location_init (MMIfaceModemLocationInterface *iface)
{
iface_modem_location_parent = g_type_interface_peek_parent (iface);
@@ -14187,7 +14187,7 @@ iface_modem_firmware_init (MMIfaceModemFirmwareInterface *iface)
iface->change_current_finish = firmware_change_current_finish;
}
-static MMIfaceModemLocation *
+static MMIfaceModemLocationInterface *
peek_parent_location_interface (MMSharedQmi *self)
{
return iface_modem_location_parent;
diff --git a/src/mm-broadband-modem.c b/src/mm-broadband-modem.c
index 4b375bb1..c866f60a 100644
--- a/src/mm-broadband-modem.c
+++ b/src/mm-broadband-modem.c
@@ -67,7 +67,7 @@ static void iface_modem_3gpp_profile_manager_init (MMIfaceModem3gppProfileManage
static void iface_modem_3gpp_ussd_init (MMIfaceModem3gppUssdInterface *iface);
static void iface_modem_cdma_init (MMIfaceModemCdma *iface);
static void iface_modem_simple_init (MMIfaceModemSimple *iface);
-static void iface_modem_location_init (MMIfaceModemLocation *iface);
+static void iface_modem_location_init (MMIfaceModemLocationInterface *iface);
static void iface_modem_messaging_init (MMIfaceModemMessaging *iface);
static void iface_modem_voice_init (MMIfaceModemVoice *iface);
static void iface_modem_time_init (MMIfaceModemTime *iface);
@@ -13670,7 +13670,7 @@ iface_modem_simple_init (MMIfaceModemSimple *iface)
}
static void
-iface_modem_location_init (MMIfaceModemLocation *iface)
+iface_modem_location_init (MMIfaceModemLocationInterface *iface)
{
iface->load_capabilities = modem_location_load_capabilities;
iface->load_capabilities_finish = modem_location_load_capabilities_finish;
diff --git a/src/mm-iface-modem-location.c b/src/mm-iface-modem-location.c
index 8867a501..7ce16a16 100644
--- a/src/mm-iface-modem-location.c
+++ b/src/mm-iface-modem-location.c
@@ -31,6 +31,8 @@
static GQuark location_context_quark;
+G_DEFINE_INTERFACE (MMIfaceModemLocation, mm_iface_modem_location, MM_TYPE_IFACE_MODEM)
+
/*****************************************************************************/
void
@@ -644,7 +646,7 @@ enable_location_gathering_ready (MMIfaceModemLocation *self,
ctx = g_task_get_task_data (task);
- if (!MM_IFACE_MODEM_LOCATION_GET_INTERFACE (self)->enable_location_gathering_finish (self, res, &error)) {
+ if (!MM_IFACE_MODEM_LOCATION_GET_IFACE (self)->enable_location_gathering_finish (self, res, &error)) {
gchar *str;
update_location_source_status (self, ctx->current, FALSE);
@@ -674,7 +676,7 @@ disable_location_gathering_ready (MMIfaceModemLocation *self,
ctx = g_task_get_task_data (task);
- if (!MM_IFACE_MODEM_LOCATION_GET_INTERFACE (self)->disable_location_gathering_finish (self, res, &error)) {
+ if (!MM_IFACE_MODEM_LOCATION_GET_IFACE (self)->disable_location_gathering_finish (self, res, &error)) {
gchar *str;
/* Back to enabled then */
@@ -726,9 +728,9 @@ setup_gathering_step (GTask *task)
update_location_source_status (self, ctx->current, TRUE);
/* Plugins can run custom actions to enable location gathering */
- if (MM_IFACE_MODEM_LOCATION_GET_INTERFACE (self)->enable_location_gathering &&
- MM_IFACE_MODEM_LOCATION_GET_INTERFACE (self)->enable_location_gathering_finish) {
- MM_IFACE_MODEM_LOCATION_GET_INTERFACE (self)->enable_location_gathering (
+ if (MM_IFACE_MODEM_LOCATION_GET_IFACE (self)->enable_location_gathering &&
+ MM_IFACE_MODEM_LOCATION_GET_IFACE (self)->enable_location_gathering_finish) {
+ MM_IFACE_MODEM_LOCATION_GET_IFACE (self)->enable_location_gathering (
MM_IFACE_MODEM_LOCATION (self),
ctx->current,
(GAsyncReadyCallback)enable_location_gathering_ready,
@@ -746,9 +748,9 @@ setup_gathering_step (GTask *task)
update_location_source_status (self, ctx->current, FALSE);
/* Plugins can run custom actions to disable location gathering */
- if (MM_IFACE_MODEM_LOCATION_GET_INTERFACE (self)->disable_location_gathering &&
- MM_IFACE_MODEM_LOCATION_GET_INTERFACE (self)->disable_location_gathering_finish) {
- MM_IFACE_MODEM_LOCATION_GET_INTERFACE (self)->disable_location_gathering (
+ if (MM_IFACE_MODEM_LOCATION_GET_IFACE (self)->disable_location_gathering &&
+ MM_IFACE_MODEM_LOCATION_GET_IFACE (self)->disable_location_gathering_finish) {
+ MM_IFACE_MODEM_LOCATION_GET_IFACE (self)->disable_location_gathering (
MM_IFACE_MODEM_LOCATION (self),
ctx->current,
(GAsyncReadyCallback)disable_location_gathering_ready,
@@ -1050,7 +1052,7 @@ set_supl_server_ready (MMIfaceModemLocation *self,
{
GError *error = NULL;
- if (!MM_IFACE_MODEM_LOCATION_GET_INTERFACE (self)->set_supl_server_finish (self, res, &error))
+ if (!MM_IFACE_MODEM_LOCATION_GET_IFACE (self)->set_supl_server_finish (self, res, &error))
mm_dbus_method_invocation_take_error (ctx->invocation, error);
else {
mm_gdbus_modem_location_set_supl_server (ctx->skeleton, ctx->supl);
@@ -1089,8 +1091,8 @@ handle_set_supl_server_auth_ready (MMBaseModem *self,
}
/* Check if plugin implements it */
- if (!MM_IFACE_MODEM_LOCATION_GET_INTERFACE (self)->set_supl_server ||
- !MM_IFACE_MODEM_LOCATION_GET_INTERFACE (self)->set_supl_server_finish) {
+ if (!MM_IFACE_MODEM_LOCATION_GET_IFACE (self)->set_supl_server ||
+ !MM_IFACE_MODEM_LOCATION_GET_IFACE (self)->set_supl_server_finish) {
mm_dbus_method_invocation_return_error_literal (ctx->invocation, MM_CORE_ERROR, MM_CORE_ERROR_UNSUPPORTED,
"Cannot set SUPL server: not implemented");
handle_set_supl_server_context_free (ctx);
@@ -1099,10 +1101,11 @@ handle_set_supl_server_auth_ready (MMBaseModem *self,
/* Request to change SUPL server */
mm_obj_info (self, "processing user request to set SUPL server...");
- MM_IFACE_MODEM_LOCATION_GET_INTERFACE (self)->set_supl_server (ctx->self,
- ctx->supl,
- (GAsyncReadyCallback)set_supl_server_ready,
- ctx);
+ MM_IFACE_MODEM_LOCATION_GET_IFACE (self)->set_supl_server (
+ ctx->self,
+ ctx->supl,
+ (GAsyncReadyCallback)set_supl_server_ready,
+ ctx);
}
static gboolean
@@ -1153,7 +1156,7 @@ inject_assistance_data_ready (MMIfaceModemLocation *self,
{
GError *error = NULL;
- if (!MM_IFACE_MODEM_LOCATION_GET_INTERFACE (self)->inject_assistance_data_finish (self, res, &error))
+ if (!MM_IFACE_MODEM_LOCATION_GET_IFACE (self)->inject_assistance_data_finish (self, res, &error))
mm_dbus_method_invocation_take_error (ctx->invocation, error);
else
mm_gdbus_modem_location_complete_inject_assistance_data (ctx->skeleton, ctx->invocation);
@@ -1184,8 +1187,8 @@ handle_inject_assistance_data_auth_ready (MMBaseModem *sel
}
/* Check if plugin implements it */
- if (!MM_IFACE_MODEM_LOCATION_GET_INTERFACE (self)->inject_assistance_data ||
- !MM_IFACE_MODEM_LOCATION_GET_INTERFACE (self)->inject_assistance_data_finish) {
+ if (!MM_IFACE_MODEM_LOCATION_GET_IFACE (self)->inject_assistance_data ||
+ !MM_IFACE_MODEM_LOCATION_GET_IFACE (self)->inject_assistance_data_finish) {
mm_dbus_method_invocation_return_error_literal (ctx->invocation, MM_CORE_ERROR, MM_CORE_ERROR_UNSUPPORTED,
"Cannot inject assistance data: not implemented");
handle_inject_assistance_data_context_free (ctx);
@@ -1196,11 +1199,12 @@ handle_inject_assistance_data_auth_ready (MMBaseModem *sel
/* Request to inject assistance data */
mm_obj_info (self, "processing user request to inject assistance data...");
- MM_IFACE_MODEM_LOCATION_GET_INTERFACE (self)->inject_assistance_data (ctx->self,
- data,
- data_size,
- (GAsyncReadyCallback)inject_assistance_data_ready,
- ctx);
+ MM_IFACE_MODEM_LOCATION_GET_IFACE (self)->inject_assistance_data (
+ ctx->self,
+ data,
+ data_size,
+ (GAsyncReadyCallback)inject_assistance_data_ready,
+ ctx);
}
static gboolean
@@ -1655,7 +1659,7 @@ load_assistance_data_servers_ready (MMIfaceModemLocation *self,
ctx = g_task_get_task_data (task);
- servers = MM_IFACE_MODEM_LOCATION_GET_INTERFACE (self)->load_assistance_data_servers_finish (self, res, &error);
+ servers = MM_IFACE_MODEM_LOCATION_GET_IFACE (self)->load_assistance_data_servers_finish (self, res, &error);
if (error) {
mm_obj_warn (self, "couldn't load assistance data servers: %s", error->message);
g_error_free (error);
@@ -1680,7 +1684,7 @@ load_supported_assistance_data_ready (MMIfaceModemLocation *self,
ctx = g_task_get_task_data (task);
- mask = MM_IFACE_MODEM_LOCATION_GET_INTERFACE (self)->load_supported_assistance_data_finish (self, res, &error);
+ mask = MM_IFACE_MODEM_LOCATION_GET_IFACE (self)->load_supported_assistance_data_finish (self, res, &error);
if (error) {
mm_obj_warn (self, "couldn't load supported assistance data types: %s", error->message);
g_error_free (error);
@@ -1704,7 +1708,7 @@ load_supl_server_ready (MMIfaceModemLocation *self,
ctx = g_task_get_task_data (task);
- supl = MM_IFACE_MODEM_LOCATION_GET_INTERFACE (self)->load_supl_server_finish (self, res, &error);
+ supl = MM_IFACE_MODEM_LOCATION_GET_IFACE (self)->load_supl_server_finish (self, res, &error);
if (error) {
mm_obj_warn (self, "couldn't load SUPL server: %s", error->message);
g_error_free (error);
@@ -1728,7 +1732,7 @@ load_capabilities_ready (MMIfaceModemLocation *self,
ctx = g_task_get_task_data (task);
- ctx->capabilities = MM_IFACE_MODEM_LOCATION_GET_INTERFACE (self)->load_capabilities_finish (self, res, &error);
+ ctx->capabilities = MM_IFACE_MODEM_LOCATION_GET_IFACE (self)->load_capabilities_finish (self, res, &error);
if (error) {
mm_obj_warn (self, "couldn't load location capabilities: %s", error->message);
g_error_free (error);
@@ -1769,9 +1773,9 @@ interface_initialization_step (GTask *task)
existing_capabilities = mm_gdbus_modem_location_get_capabilities (ctx->skeleton);
if (existing_capabilities != MM_MODEM_LOCATION_SOURCE_NONE) {
ctx->capabilities = existing_capabilities;
- } else if (MM_IFACE_MODEM_LOCATION_GET_INTERFACE (self)->load_capabilities &&
- MM_IFACE_MODEM_LOCATION_GET_INTERFACE (self)->load_capabilities_finish) {
- MM_IFACE_MODEM_LOCATION_GET_INTERFACE (self)->load_capabilities (
+ } else if (MM_IFACE_MODEM_LOCATION_GET_IFACE (self)->load_capabilities &&
+ MM_IFACE_MODEM_LOCATION_GET_IFACE (self)->load_capabilities_finish) {
+ MM_IFACE_MODEM_LOCATION_GET_IFACE (self)->load_capabilities (
self,
(GAsyncReadyCallback)load_capabilities_ready,
task);
@@ -1798,9 +1802,9 @@ interface_initialization_step (GTask *task)
/* If the modem supports A-GPS, load SUPL server */
if ((ctx->capabilities & (MM_MODEM_LOCATION_SOURCE_AGPS_MSA |
MM_MODEM_LOCATION_SOURCE_AGPS_MSB)) &&
- MM_IFACE_MODEM_LOCATION_GET_INTERFACE (self)->load_supl_server &&
- MM_IFACE_MODEM_LOCATION_GET_INTERFACE (self)->load_supl_server_finish) {
- MM_IFACE_MODEM_LOCATION_GET_INTERFACE (self)->load_supl_server (
+ MM_IFACE_MODEM_LOCATION_GET_IFACE (self)->load_supl_server &&
+ MM_IFACE_MODEM_LOCATION_GET_IFACE (self)->load_supl_server_finish) {
+ MM_IFACE_MODEM_LOCATION_GET_IFACE (self)->load_supl_server (
self,
(GAsyncReadyCallback)load_supl_server_ready,
task);
@@ -1815,9 +1819,9 @@ interface_initialization_step (GTask *task)
MM_MODEM_LOCATION_SOURCE_AGPS_MSB |
MM_MODEM_LOCATION_SOURCE_GPS_RAW |
MM_MODEM_LOCATION_SOURCE_GPS_NMEA)) &&
- MM_IFACE_MODEM_LOCATION_GET_INTERFACE (self)->load_supported_assistance_data &&
- MM_IFACE_MODEM_LOCATION_GET_INTERFACE (self)->load_supported_assistance_data_finish) {
- MM_IFACE_MODEM_LOCATION_GET_INTERFACE (self)->load_supported_assistance_data (
+ MM_IFACE_MODEM_LOCATION_GET_IFACE (self)->load_supported_assistance_data &&
+ MM_IFACE_MODEM_LOCATION_GET_IFACE (self)->load_supported_assistance_data_finish) {
+ MM_IFACE_MODEM_LOCATION_GET_IFACE (self)->load_supported_assistance_data (
self,
(GAsyncReadyCallback)load_supported_assistance_data_ready,
task);
@@ -1829,9 +1833,9 @@ interface_initialization_step (GTask *task)
case INITIALIZATION_STEP_ASSISTANCE_DATA_SERVERS:
/* If any assistance data supported, load servers */
if ((mm_gdbus_modem_location_get_supported_assistance_data (ctx->skeleton) != MM_MODEM_LOCATION_ASSISTANCE_DATA_TYPE_NONE) &&
- MM_IFACE_MODEM_LOCATION_GET_INTERFACE (self)->load_assistance_data_servers &&
- MM_IFACE_MODEM_LOCATION_GET_INTERFACE (self)->load_assistance_data_servers_finish) {
- MM_IFACE_MODEM_LOCATION_GET_INTERFACE (self)->load_assistance_data_servers (
+ MM_IFACE_MODEM_LOCATION_GET_IFACE (self)->load_assistance_data_servers &&
+ MM_IFACE_MODEM_LOCATION_GET_IFACE (self)->load_assistance_data_servers_finish) {
+ MM_IFACE_MODEM_LOCATION_GET_IFACE (self)->load_assistance_data_servers (
self,
(GAsyncReadyCallback)load_assistance_data_servers_ready,
task);
@@ -1954,52 +1958,29 @@ mm_iface_modem_location_shutdown (MMIfaceModemLocation *self)
/*****************************************************************************/
static void
-iface_modem_location_init (gpointer g_iface)
+mm_iface_modem_location_default_init (MMIfaceModemLocationInterface *iface)
{
- static gboolean initialized = FALSE;
+ static gsize initialized = 0;
- if (initialized)
+ if (!g_once_init_enter (&initialized))
return;
/* Properties */
- g_object_interface_install_property
- (g_iface,
- g_param_spec_object (MM_IFACE_MODEM_LOCATION_DBUS_SKELETON,
- "Location DBus skeleton",
- "DBus skeleton for the Location interface",
- MM_GDBUS_TYPE_MODEM_LOCATION_SKELETON,
- G_PARAM_READWRITE));
-
- g_object_interface_install_property
- (g_iface,
- g_param_spec_boolean (MM_IFACE_MODEM_LOCATION_ALLOW_GPS_UNMANAGED_ALWAYS,
- "Allow unmanaged GPS always",
- "Whether to always allow GPS unmanaged, even when raw/nmea GPS sources are enabled",
- FALSE,
- G_PARAM_READWRITE | G_PARAM_CONSTRUCT_ONLY));
-
- initialized = TRUE;
-}
-
-GType
-mm_iface_modem_location_get_type (void)
-{
- static GType iface_modem_location_type = 0;
-
- if (!G_UNLIKELY (iface_modem_location_type)) {
- static const GTypeInfo info = {
- sizeof (MMIfaceModemLocation), /* class_size */
- iface_modem_location_init, /* base_init */
- NULL, /* base_finalize */
- };
-
- iface_modem_location_type = g_type_register_static (G_TYPE_INTERFACE,
- "MMIfaceModemLocation",
- &info,
- 0);
-
- g_type_interface_add_prerequisite (iface_modem_location_type, MM_TYPE_IFACE_MODEM);
- }
-
- return iface_modem_location_type;
+ g_object_interface_install_property (
+ iface,
+ g_param_spec_object (MM_IFACE_MODEM_LOCATION_DBUS_SKELETON,
+ "Location DBus skeleton",
+ "DBus skeleton for the Location interface",
+ MM_GDBUS_TYPE_MODEM_LOCATION_SKELETON,
+ G_PARAM_READWRITE));
+
+ g_object_interface_install_property (
+ iface,
+ g_param_spec_boolean (MM_IFACE_MODEM_LOCATION_ALLOW_GPS_UNMANAGED_ALWAYS,
+ "Allow unmanaged GPS always",
+ "Whether to always allow GPS unmanaged, even when raw/nmea GPS sources are enabled",
+ FALSE,
+ G_PARAM_READWRITE | G_PARAM_CONSTRUCT_ONLY));
+
+ g_once_init_leave (&initialized, 1);
}
diff --git a/src/mm-iface-modem-location.h b/src/mm-iface-modem-location.h
index c0a7fbd9..0385c010 100644
--- a/src/mm-iface-modem-location.h
+++ b/src/mm-iface-modem-location.h
@@ -22,17 +22,15 @@
#define _LIBMM_INSIDE_MM
#include <libmm-glib.h>
-#define MM_TYPE_IFACE_MODEM_LOCATION (mm_iface_modem_location_get_type ())
-#define MM_IFACE_MODEM_LOCATION(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), MM_TYPE_IFACE_MODEM_LOCATION, MMIfaceModemLocation))
-#define MM_IS_IFACE_MODEM_LOCATION(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), MM_TYPE_IFACE_MODEM_LOCATION))
-#define MM_IFACE_MODEM_LOCATION_GET_INTERFACE(obj) (G_TYPE_INSTANCE_GET_INTERFACE ((obj), MM_TYPE_IFACE_MODEM_LOCATION, MMIfaceModemLocation))
+#include "mm-iface-modem.h"
+
+#define MM_TYPE_IFACE_MODEM_LOCATION mm_iface_modem_location_get_type ()
+G_DECLARE_INTERFACE (MMIfaceModemLocation, mm_iface_modem_location, MM, IFACE_MODEM_LOCATION, MMIfaceModem)
#define MM_IFACE_MODEM_LOCATION_DBUS_SKELETON "iface-modem-location-dbus-skeleton"
#define MM_IFACE_MODEM_LOCATION_ALLOW_GPS_UNMANAGED_ALWAYS "iface-modem-location-allow-gps-unmanaged-always"
-typedef struct _MMIfaceModemLocation MMIfaceModemLocation;
-
-struct _MMIfaceModemLocation {
+struct _MMIfaceModemLocationInterface {
GTypeInterface g_iface;
/* Loading of the Capabilities property */
@@ -105,9 +103,6 @@ struct _MMIfaceModemLocation {
GError **error);
};
-GType mm_iface_modem_location_get_type (void);
-G_DEFINE_AUTOPTR_CLEANUP_FUNC (MMIfaceModemLocation, g_object_unref)
-
/* Initialize Location interface (async) */
void mm_iface_modem_location_initialize (MMIfaceModemLocation *self,
GCancellable *cancellable,
diff --git a/src/mm-shared-qmi.c b/src/mm-shared-qmi.c
index 71d66280..8da4ecc6 100644
--- a/src/mm-shared-qmi.c
+++ b/src/mm-shared-qmi.c
@@ -81,15 +81,15 @@ typedef struct {
GArray *supported_bands;
/* Location helpers */
- MMIfaceModemLocation *iface_modem_location_parent;
- MMModemLocationSource enabled_sources;
- QmiClient *pds_client;
- gulong pds_location_event_report_indication_id;
- QmiClient *loc_client;
- gulong loc_location_nmea_indication_id;
- gchar **loc_assistance_data_servers;
- guint32 loc_assistance_data_max_file_size;
- guint32 loc_assistance_data_max_part_size;
+ MMIfaceModemLocationInterface *iface_modem_location_parent;
+ MMModemLocationSource enabled_sources;
+ QmiClient *pds_client;
+ gulong pds_location_event_report_indication_id;
+ QmiClient *loc_client;
+ gulong loc_location_nmea_indication_id;
+ gchar **loc_assistance_data_servers;
+ guint32 loc_assistance_data_max_file_size;
+ guint32 loc_assistance_data_max_part_size;
/* Carrier config helpers */
gboolean config_active_default;
diff --git a/src/mm-shared-qmi.h b/src/mm-shared-qmi.h
index 8e419900..014d87cb 100644
--- a/src/mm-shared-qmi.h
+++ b/src/mm-shared-qmi.h
@@ -46,7 +46,7 @@ struct _MMSharedQmi {
GError **error);
/* Peek location interface of the parent class of the object */
- MMIfaceModemLocation * (* peek_parent_location_interface) (MMSharedQmi *self);
+ MMIfaceModemLocationInterface * (* peek_parent_location_interface) (MMSharedQmi *self);
};
GType mm_shared_qmi_get_type (void);
diff --git a/src/plugins/cinterion/mm-broadband-modem-cinterion.c b/src/plugins/cinterion/mm-broadband-modem-cinterion.c
index 1077bd56..c3ff2693 100644
--- a/src/plugins/cinterion/mm-broadband-modem-cinterion.c
+++ b/src/plugins/cinterion/mm-broadband-modem-cinterion.c
@@ -42,21 +42,21 @@
#include "mm-broadband-bearer-cinterion.h"
#include "mm-iface-modem-signal.h"
-static void iface_modem_init (MMIfaceModemInterface *iface);
-static void iface_modem_3gpp_init (MMIfaceModem3gppInterface *iface);
-static void iface_modem_messaging_init (MMIfaceModemMessaging *iface);
-static void iface_modem_location_init (MMIfaceModemLocation *iface);
-static void iface_modem_voice_init (MMIfaceModemVoice *iface);
-static void iface_modem_time_init (MMIfaceModemTime *iface);
-static void iface_modem_signal_init (MMIfaceModemSignal *iface);
-static void shared_cinterion_init (MMSharedCinterion *iface);
-
-static MMIfaceModemInterface *iface_modem_parent;
-static MMIfaceModem3gppInterface *iface_modem_3gpp_parent;
-static MMIfaceModemLocation *iface_modem_location_parent;
-static MMIfaceModemVoice *iface_modem_voice_parent;
-static MMIfaceModemTime *iface_modem_time_parent;
-static MMIfaceModemSignal *iface_modem_signal_parent;
+static void iface_modem_init (MMIfaceModemInterface *iface);
+static void iface_modem_3gpp_init (MMIfaceModem3gppInterface *iface);
+static void iface_modem_messaging_init (MMIfaceModemMessaging *iface);
+static void iface_modem_location_init (MMIfaceModemLocationInterface *iface);
+static void iface_modem_voice_init (MMIfaceModemVoice *iface);
+static void iface_modem_time_init (MMIfaceModemTime *iface);
+static void iface_modem_signal_init (MMIfaceModemSignal *iface);
+static void shared_cinterion_init (MMSharedCinterion *iface);
+
+static MMIfaceModemInterface *iface_modem_parent;
+static MMIfaceModem3gppInterface *iface_modem_3gpp_parent;
+static MMIfaceModemLocationInterface *iface_modem_location_parent;
+static MMIfaceModemVoice *iface_modem_voice_parent;
+static MMIfaceModemTime *iface_modem_time_parent;
+static MMIfaceModemSignal *iface_modem_signal_parent;
G_DEFINE_TYPE_EXTENDED (MMBroadbandModemCinterion, mm_broadband_modem_cinterion, MM_TYPE_BROADBAND_MODEM, 0,
G_IMPLEMENT_INTERFACE (MM_TYPE_IFACE_MODEM, iface_modem_init)
@@ -3535,7 +3535,7 @@ iface_modem_messaging_init (MMIfaceModemMessaging *iface)
}
static void
-iface_modem_location_init (MMIfaceModemLocation *iface)
+iface_modem_location_init (MMIfaceModemLocationInterface *iface)
{
iface_modem_location_parent = g_type_interface_peek_parent (iface);
@@ -3547,7 +3547,7 @@ iface_modem_location_init (MMIfaceModemLocation *iface)
iface->disable_location_gathering_finish = mm_shared_cinterion_disable_location_gathering_finish;
}
-static MMIfaceModemLocation *
+static MMIfaceModemLocationInterface *
peek_parent_location_interface (MMSharedCinterion *self)
{
return iface_modem_location_parent;
diff --git a/src/plugins/cinterion/mm-broadband-modem-mbim-cinterion.c b/src/plugins/cinterion/mm-broadband-modem-mbim-cinterion.c
index 54520a2e..830ef159 100644
--- a/src/plugins/cinterion/mm-broadband-modem-mbim-cinterion.c
+++ b/src/plugins/cinterion/mm-broadband-modem-mbim-cinterion.c
@@ -30,16 +30,16 @@
#include "mm-broadband-modem-mbim-cinterion.h"
#include "mm-shared-cinterion.h"
-static void iface_modem_init (MMIfaceModemInterface *iface);
-static void iface_modem_location_init (MMIfaceModemLocation *iface);
-static void iface_modem_voice_init (MMIfaceModemVoice *iface);
-static void iface_modem_time_init (MMIfaceModemTime *iface);
-static void shared_cinterion_init (MMSharedCinterion *iface);
+static void iface_modem_init (MMIfaceModemInterface *iface);
+static void iface_modem_location_init (MMIfaceModemLocationInterface *iface);
+static void iface_modem_voice_init (MMIfaceModemVoice *iface);
+static void iface_modem_time_init (MMIfaceModemTime *iface);
+static void shared_cinterion_init (MMSharedCinterion *iface);
-static MMIfaceModemInterface *iface_modem_parent;
-static MMIfaceModemLocation *iface_modem_location_parent;
-static MMIfaceModemVoice *iface_modem_voice_parent;
-static MMIfaceModemTime *iface_modem_time_parent;
+static MMIfaceModemInterface *iface_modem_parent;
+static MMIfaceModemLocationInterface *iface_modem_location_parent;
+static MMIfaceModemVoice *iface_modem_voice_parent;
+static MMIfaceModemTime *iface_modem_time_parent;
G_DEFINE_TYPE_EXTENDED (MMBroadbandModemMbimCinterion, mm_broadband_modem_mbim_cinterion, MM_TYPE_BROADBAND_MODEM_MBIM, 0,
G_IMPLEMENT_INTERFACE (MM_TYPE_IFACE_MODEM, iface_modem_init)
@@ -95,7 +95,7 @@ peek_parent_interface (MMSharedCinterion *self)
}
static void
-iface_modem_location_init (MMIfaceModemLocation *iface)
+iface_modem_location_init (MMIfaceModemLocationInterface *iface)
{
iface_modem_location_parent = g_type_interface_peek_parent (iface);
@@ -107,7 +107,7 @@ iface_modem_location_init (MMIfaceModemLocation *iface)
iface->disable_location_gathering_finish = mm_shared_cinterion_disable_location_gathering_finish;
}
-static MMIfaceModemLocation *
+static MMIfaceModemLocationInterface *
peek_parent_location_interface (MMSharedCinterion *self)
{
return iface_modem_location_parent;
diff --git a/src/plugins/cinterion/mm-broadband-modem-qmi-cinterion.c b/src/plugins/cinterion/mm-broadband-modem-qmi-cinterion.c
index e20b506e..0534f768 100644
--- a/src/plugins/cinterion/mm-broadband-modem-qmi-cinterion.c
+++ b/src/plugins/cinterion/mm-broadband-modem-qmi-cinterion.c
@@ -31,16 +31,16 @@
#include "mm-broadband-modem-qmi-cinterion.h"
#include "mm-shared-cinterion.h"
-static void iface_modem_init (MMIfaceModemInterface *iface);
-static void iface_modem_location_init (MMIfaceModemLocation *iface);
-static void iface_modem_voice_init (MMIfaceModemVoice *iface);
-static void iface_modem_time_init (MMIfaceModemTime *iface);
-static void shared_cinterion_init (MMSharedCinterion *iface);
+static void iface_modem_init (MMIfaceModemInterface *iface);
+static void iface_modem_location_init (MMIfaceModemLocationInterface *iface);
+static void iface_modem_voice_init (MMIfaceModemVoice *iface);
+static void iface_modem_time_init (MMIfaceModemTime *iface);
+static void shared_cinterion_init (MMSharedCinterion *iface);
-static MMIfaceModemInterface *iface_modem_parent;
-static MMIfaceModemLocation *iface_modem_location_parent;
-static MMIfaceModemVoice *iface_modem_voice_parent;
-static MMIfaceModemTime *iface_modem_time_parent;
+static MMIfaceModemInterface *iface_modem_parent;
+static MMIfaceModemLocationInterface *iface_modem_location_parent;
+static MMIfaceModemVoice *iface_modem_voice_parent;
+static MMIfaceModemTime *iface_modem_time_parent;
G_DEFINE_TYPE_EXTENDED (MMBroadbandModemQmiCinterion, mm_broadband_modem_qmi_cinterion, MM_TYPE_BROADBAND_MODEM_QMI, 0,
G_IMPLEMENT_INTERFACE (MM_TYPE_IFACE_MODEM, iface_modem_init)
@@ -94,7 +94,7 @@ peek_parent_interface (MMSharedCinterion *self)
}
static void
-iface_modem_location_init (MMIfaceModemLocation *iface)
+iface_modem_location_init (MMIfaceModemLocationInterface *iface)
{
iface_modem_location_parent = g_type_interface_peek_parent (iface);
@@ -106,7 +106,7 @@ iface_modem_location_init (MMIfaceModemLocation *iface)
iface->disable_location_gathering_finish = mm_shared_cinterion_disable_location_gathering_finish;
}
-static MMIfaceModemLocation *
+static MMIfaceModemLocationInterface *
peek_parent_location_interface (MMSharedCinterion *self)
{
return iface_modem_location_parent;
diff --git a/src/plugins/cinterion/mm-shared-cinterion.c b/src/plugins/cinterion/mm-shared-cinterion.c
index 0724c3cd..2ac2ab2a 100644
--- a/src/plugins/cinterion/mm-shared-cinterion.c
+++ b/src/plugins/cinterion/mm-shared-cinterion.c
@@ -47,11 +47,11 @@ typedef struct {
/* modem */
MMIfaceModemInterface *iface_modem_parent;
/* location */
- MMIfaceModemLocation *iface_modem_location_parent;
- MMModemLocationSource supported_sources;
- MMModemLocationSource enabled_sources;
- FeatureSupport sgpss_support;
- FeatureSupport sgpsc_support;
+ MMIfaceModemLocationInterface *iface_modem_location_parent;
+ MMModemLocationSource supported_sources;
+ MMModemLocationSource enabled_sources;
+ FeatureSupport sgpss_support;
+ FeatureSupport sgpsc_support;
/* voice */
MMIfaceModemVoice *iface_modem_voice_parent;
FeatureSupport slcc_support;
diff --git a/src/plugins/cinterion/mm-shared-cinterion.h b/src/plugins/cinterion/mm-shared-cinterion.h
index 5605408f..41e99a8b 100644
--- a/src/plugins/cinterion/mm-shared-cinterion.h
+++ b/src/plugins/cinterion/mm-shared-cinterion.h
@@ -44,7 +44,7 @@ struct _MMSharedCinterion {
MMIfaceModemInterface * (* peek_parent_interface) (MMSharedCinterion *self);
/* Peek location interface of the parent class of the object */
- MMIfaceModemLocation * (* peek_parent_location_interface) (MMSharedCinterion *self);
+ MMIfaceModemLocationInterface * (* peek_parent_location_interface) (MMSharedCinterion *self);
/* Peek voice interface of the parent class of the object */
MMIfaceModemVoice * (* peek_parent_voice_interface) (MMSharedCinterion *self);
diff --git a/src/plugins/foxconn/mm-broadband-modem-mbim-foxconn.c b/src/plugins/foxconn/mm-broadband-modem-mbim-foxconn.c
index b8ad339b..060194e1 100644
--- a/src/plugins/foxconn/mm-broadband-modem-mbim-foxconn.c
+++ b/src/plugins/foxconn/mm-broadband-modem-mbim-foxconn.c
@@ -39,12 +39,12 @@
# include "mm-log.h"
#endif
-static void iface_modem_location_init (MMIfaceModemLocation *iface);
+static void iface_modem_location_init (MMIfaceModemLocationInterface *iface);
#if defined WITH_QMI && QMI_MBIM_QMUX_SUPPORTED
static void iface_modem_firmware_init (MMIfaceModemFirmwareInterface *iface);
#endif
-static MMIfaceModemLocation *iface_modem_location_parent;
+static MMIfaceModemLocationInterface *iface_modem_location_parent;
G_DEFINE_TYPE_EXTENDED (MMBroadbandModemMbimFoxconn, mm_broadband_modem_mbim_foxconn, MM_TYPE_BROADBAND_MODEM_MBIM, 0,
#if defined WITH_QMI && QMI_MBIM_QMUX_SUPPORTED
@@ -581,7 +581,7 @@ mm_broadband_modem_mbim_foxconn_init (MMBroadbandModemMbimFoxconn *self)
}
static void
-iface_modem_location_init (MMIfaceModemLocation *iface)
+iface_modem_location_init (MMIfaceModemLocationInterface *iface)
{
iface_modem_location_parent = g_type_interface_peek_parent (iface);
diff --git a/src/plugins/huawei/mm-broadband-modem-huawei.c b/src/plugins/huawei/mm-broadband-modem-huawei.c
index 294bef30..eb71e6a5 100644
--- a/src/plugins/huawei/mm-broadband-modem-huawei.c
+++ b/src/plugins/huawei/mm-broadband-modem-huawei.c
@@ -53,17 +53,17 @@
static void iface_modem_init (MMIfaceModemInterface *iface);
static void iface_modem_3gpp_init (MMIfaceModem3gppInterface *iface);
static void iface_modem_3gpp_ussd_init (MMIfaceModem3gppUssdInterface *iface);
-static void iface_modem_location_init (MMIfaceModemLocation *iface);
+static void iface_modem_location_init (MMIfaceModemLocationInterface *iface);
static void iface_modem_cdma_init (MMIfaceModemCdma *iface);
static void iface_modem_time_init (MMIfaceModemTime *iface);
static void iface_modem_voice_init (MMIfaceModemVoice *iface);
static void iface_modem_signal_init (MMIfaceModemSignal *iface);
-static MMIfaceModemInterface *iface_modem_parent;
-static MMIfaceModem3gppInterface *iface_modem_3gpp_parent;
-static MMIfaceModemLocation *iface_modem_location_parent;
-static MMIfaceModemCdma *iface_modem_cdma_parent;
-static MMIfaceModemVoice *iface_modem_voice_parent;
+static MMIfaceModemInterface *iface_modem_parent;
+static MMIfaceModem3gppInterface *iface_modem_3gpp_parent;
+static MMIfaceModemLocationInterface *iface_modem_location_parent;
+static MMIfaceModemCdma *iface_modem_cdma_parent;
+static MMIfaceModemVoice *iface_modem_voice_parent;
G_DEFINE_TYPE_EXTENDED (MMBroadbandModemHuawei, mm_broadband_modem_huawei, MM_TYPE_BROADBAND_MODEM, 0,
G_IMPLEMENT_INTERFACE (MM_TYPE_IFACE_MODEM, iface_modem_init)
@@ -5061,7 +5061,7 @@ iface_modem_cdma_init (MMIfaceModemCdma *iface)
}
static void
-iface_modem_location_init (MMIfaceModemLocation *iface)
+iface_modem_location_init (MMIfaceModemLocationInterface *iface)
{
iface_modem_location_parent = g_type_interface_peek_parent (iface);
diff --git a/src/plugins/intel/mm-broadband-modem-mbim-intel.c b/src/plugins/intel/mm-broadband-modem-mbim-intel.c
index da26077d..105043a7 100644
--- a/src/plugins/intel/mm-broadband-modem-mbim-intel.c
+++ b/src/plugins/intel/mm-broadband-modem-mbim-intel.c
@@ -30,10 +30,10 @@
#include "mm-iface-modem-location.h"
#include "mm-shared-xmm.h"
-static void iface_modem_location_init (MMIfaceModemLocation *iface);
-static void shared_xmm_init (MMSharedXmm *iface);
+static void iface_modem_location_init (MMIfaceModemLocationInterface *iface);
+static void shared_xmm_init (MMSharedXmm *iface);
-static MMIfaceModemLocation *iface_modem_location_parent;
+static MMIfaceModemLocationInterface *iface_modem_location_parent;
G_DEFINE_TYPE_EXTENDED (MMBroadbandModemMbimIntel, mm_broadband_modem_mbim_intel, MM_TYPE_BROADBAND_MODEM_MBIM, 0,
G_IMPLEMENT_INTERFACE (MM_TYPE_IFACE_MODEM_LOCATION, iface_modem_location_init)
@@ -102,7 +102,7 @@ mm_broadband_modem_mbim_intel_init (MMBroadbandModemMbimIntel *self)
}
static void
-iface_modem_location_init (MMIfaceModemLocation *iface)
+iface_modem_location_init (MMIfaceModemLocationInterface *iface)
{
iface_modem_location_parent = g_type_interface_peek_parent (iface);
@@ -124,7 +124,7 @@ peek_parent_broadband_modem_class (MMSharedXmm *self)
return MM_BROADBAND_MODEM_CLASS (mm_broadband_modem_mbim_intel_parent_class);
}
-static MMIfaceModemLocation *
+static MMIfaceModemLocationInterface *
peek_parent_location_interface (MMSharedXmm *self)
{
return iface_modem_location_parent;
diff --git a/src/plugins/mbm/mm-broadband-modem-mbm.c b/src/plugins/mbm/mm-broadband-modem-mbm.c
index ff8e1d67..15d54d9f 100644
--- a/src/plugins/mbm/mm-broadband-modem-mbm.c
+++ b/src/plugins/mbm/mm-broadband-modem-mbm.c
@@ -47,13 +47,13 @@
/* sets the interval in seconds on how often the card emits the NMEA sentences */
#define MBM_GPS_NMEA_INTERVAL "5"
-static void iface_modem_init (MMIfaceModemInterface *iface);
-static void iface_modem_3gpp_init (MMIfaceModem3gppInterface *iface);
-static void iface_modem_location_init (MMIfaceModemLocation *iface);
+static void iface_modem_init (MMIfaceModemInterface *iface);
+static void iface_modem_3gpp_init (MMIfaceModem3gppInterface *iface);
+static void iface_modem_location_init (MMIfaceModemLocationInterface *iface);
-static MMIfaceModemInterface *iface_modem_parent;
-static MMIfaceModem3gppInterface *iface_modem_3gpp_parent;
-static MMIfaceModemLocation *iface_modem_location_parent;
+static MMIfaceModemInterface *iface_modem_parent;
+static MMIfaceModem3gppInterface *iface_modem_3gpp_parent;
+static MMIfaceModemLocationInterface *iface_modem_location_parent;
G_DEFINE_TYPE_EXTENDED (MMBroadbandModemMbm, mm_broadband_modem_mbm, MM_TYPE_BROADBAND_MODEM, 0,
G_IMPLEMENT_INTERFACE (MM_TYPE_IFACE_MODEM, iface_modem_init)
@@ -1585,7 +1585,7 @@ iface_modem_3gpp_init (MMIfaceModem3gppInterface *iface)
}
static void
-iface_modem_location_init (MMIfaceModemLocation *iface)
+iface_modem_location_init (MMIfaceModemLocationInterface *iface)
{
iface_modem_location_parent = g_type_interface_peek_parent (iface);
diff --git a/src/plugins/option/mm-broadband-modem-hso.c b/src/plugins/option/mm-broadband-modem-hso.c
index 5ce4d2e6..12abe897 100644
--- a/src/plugins/option/mm-broadband-modem-hso.c
+++ b/src/plugins/option/mm-broadband-modem-hso.c
@@ -36,13 +36,13 @@
#include "mm-bearer-list.h"
#include "mm-shared-option.h"
-static void shared_option_init (MMSharedOption *iface);
-static void iface_modem_init (MMIfaceModemInterface *iface);
-static void iface_modem_3gpp_init (MMIfaceModem3gppInterface *iface);
-static void iface_modem_location_init (MMIfaceModemLocation *iface);
+static void shared_option_init (MMSharedOption *iface);
+static void iface_modem_init (MMIfaceModemInterface *iface);
+static void iface_modem_3gpp_init (MMIfaceModem3gppInterface *iface);
+static void iface_modem_location_init (MMIfaceModemLocationInterface *iface);
-static MMIfaceModem3gppInterface *iface_modem_3gpp_parent;
-static MMIfaceModemLocation *iface_modem_location_parent;
+static MMIfaceModem3gppInterface *iface_modem_3gpp_parent;
+static MMIfaceModemLocationInterface *iface_modem_location_parent;
G_DEFINE_TYPE_EXTENDED (MMBroadbandModemHso, mm_broadband_modem_hso, MM_TYPE_BROADBAND_MODEM_OPTION, 0,
G_IMPLEMENT_INTERFACE (MM_TYPE_SHARED_OPTION, shared_option_init)
@@ -813,7 +813,7 @@ iface_modem_3gpp_init (MMIfaceModem3gppInterface *iface)
}
static void
-iface_modem_location_init (MMIfaceModemLocation *iface)
+iface_modem_location_init (MMIfaceModemLocationInterface *iface)
{
iface_modem_location_parent = g_type_interface_peek_parent (iface);
diff --git a/src/plugins/quectel/mm-broadband-modem-mbim-quectel.c b/src/plugins/quectel/mm-broadband-modem-mbim-quectel.c
index e0174cc6..c5e3eab6 100644
--- a/src/plugins/quectel/mm-broadband-modem-mbim-quectel.c
+++ b/src/plugins/quectel/mm-broadband-modem-mbim-quectel.c
@@ -24,12 +24,12 @@
static void iface_modem_init (MMIfaceModemInterface *iface);
static void iface_modem_firmware_init (MMIfaceModemFirmwareInterface *iface);
-static void iface_modem_location_init (MMIfaceModemLocation *iface);
+static void iface_modem_location_init (MMIfaceModemLocationInterface *iface);
static void iface_modem_time_init (MMIfaceModemTime *iface);
static void shared_quectel_init (MMSharedQuectel *iface);
-static MMIfaceModemInterface *iface_modem_parent;
-static MMIfaceModemLocation *iface_modem_location_parent;
+static MMIfaceModemInterface *iface_modem_parent;
+static MMIfaceModemLocationInterface *iface_modem_location_parent;
G_DEFINE_TYPE_EXTENDED (MMBroadbandModemMbimQuectel, mm_broadband_modem_mbim_quectel, MM_TYPE_BROADBAND_MODEM_MBIM, 0,
G_IMPLEMENT_INTERFACE (MM_TYPE_IFACE_MODEM, iface_modem_init)
@@ -88,7 +88,7 @@ iface_modem_firmware_init (MMIfaceModemFirmwareInterface *iface)
}
static void
-iface_modem_location_init (MMIfaceModemLocation *iface)
+iface_modem_location_init (MMIfaceModemLocationInterface *iface)
{
iface_modem_location_parent = g_type_interface_peek_parent (iface);
@@ -113,7 +113,7 @@ peek_parent_modem_interface (MMSharedQuectel *self)
return iface_modem_parent;
}
-static MMIfaceModemLocation *
+static MMIfaceModemLocationInterface *
peek_parent_modem_location_interface (MMSharedQuectel *self)
{
return iface_modem_location_parent;
diff --git a/src/plugins/quectel/mm-broadband-modem-qmi-quectel.c b/src/plugins/quectel/mm-broadband-modem-qmi-quectel.c
index e28308b6..349c3013 100644
--- a/src/plugins/quectel/mm-broadband-modem-qmi-quectel.c
+++ b/src/plugins/quectel/mm-broadband-modem-qmi-quectel.c
@@ -27,13 +27,13 @@
static void iface_modem_init (MMIfaceModemInterface *iface);
static void iface_modem_firmware_init (MMIfaceModemFirmwareInterface *iface);
-static void iface_modem_location_init (MMIfaceModemLocation *iface);
+static void iface_modem_location_init (MMIfaceModemLocationInterface *iface);
static void iface_modem_time_init (MMIfaceModemTime *iface);
static void iface_modem_3gpp_profile_manager_init (MMIfaceModem3gppProfileManagerInterface *iface);
static void shared_quectel_init (MMSharedQuectel *iface);
static MMIfaceModemInterface *iface_modem_parent;
-static MMIfaceModemLocation *iface_modem_location_parent;
+static MMIfaceModemLocationInterface *iface_modem_location_parent;
static MMIfaceModem3gppProfileManagerInterface *iface_modem_3gpp_profile_manager_parent;
G_DEFINE_TYPE_EXTENDED (MMBroadbandModemQmiQuectel, mm_broadband_modem_qmi_quectel, MM_TYPE_BROADBAND_MODEM_QMI, 0,
@@ -170,7 +170,7 @@ iface_modem_firmware_init (MMIfaceModemFirmwareInterface *iface)
}
static void
-iface_modem_location_init (MMIfaceModemLocation *iface)
+iface_modem_location_init (MMIfaceModemLocationInterface *iface)
{
iface_modem_location_parent = g_type_interface_peek_parent (iface);
@@ -201,7 +201,7 @@ peek_parent_modem_interface (MMSharedQuectel *self)
return iface_modem_parent;
}
-static MMIfaceModemLocation *
+static MMIfaceModemLocationInterface *
peek_parent_modem_location_interface (MMSharedQuectel *self)
{
return iface_modem_location_parent;
diff --git a/src/plugins/quectel/mm-broadband-modem-quectel.c b/src/plugins/quectel/mm-broadband-modem-quectel.c
index 2bf15483..5ca5b480 100644
--- a/src/plugins/quectel/mm-broadband-modem-quectel.c
+++ b/src/plugins/quectel/mm-broadband-modem-quectel.c
@@ -24,12 +24,12 @@
static void iface_modem_init (MMIfaceModemInterface *iface);
static void iface_modem_firmware_init (MMIfaceModemFirmwareInterface *iface);
-static void iface_modem_location_init (MMIfaceModemLocation *iface);
+static void iface_modem_location_init (MMIfaceModemLocationInterface *iface);
static void iface_modem_time_init (MMIfaceModemTime *iface);
static void shared_quectel_init (MMSharedQuectel *iface);
-static MMIfaceModemInterface *iface_modem_parent;
-static MMIfaceModemLocation *iface_modem_location_parent;
+static MMIfaceModemInterface *iface_modem_parent;
+static MMIfaceModemLocationInterface *iface_modem_location_parent;
G_DEFINE_TYPE_EXTENDED (MMBroadbandModemQuectel, mm_broadband_modem_quectel, MM_TYPE_BROADBAND_MODEM, 0,
G_IMPLEMENT_INTERFACE (MM_TYPE_IFACE_MODEM, iface_modem_init)
@@ -85,7 +85,7 @@ iface_modem_firmware_init (MMIfaceModemFirmwareInterface *iface)
}
static void
-iface_modem_location_init (MMIfaceModemLocation *iface)
+iface_modem_location_init (MMIfaceModemLocationInterface *iface)
{
iface_modem_location_parent = g_type_interface_peek_parent (iface);
@@ -116,7 +116,7 @@ peek_parent_modem_interface (MMSharedQuectel *self)
return iface_modem_parent;
}
-static MMIfaceModemLocation *
+static MMIfaceModemLocationInterface *
peek_parent_modem_location_interface (MMSharedQuectel *self)
{
return iface_modem_location_parent;
diff --git a/src/plugins/quectel/mm-shared-quectel.c b/src/plugins/quectel/mm-shared-quectel.c
index 93cd3d23..ea6358b1 100644
--- a/src/plugins/quectel/mm-shared-quectel.c
+++ b/src/plugins/quectel/mm-shared-quectel.c
@@ -48,15 +48,15 @@ typedef enum {
} FeatureSupport;
typedef struct {
- MMBroadbandModemClass *broadband_modem_class_parent;
- MMIfaceModemInterface *iface_modem_parent;
- MMIfaceModemLocation *iface_modem_location_parent;
- MMModemLocationSource provided_sources;
- MMModemLocationSource enabled_sources;
- FeatureSupport qgps_supported;
- GRegex *qgpsurc_regex;
- GRegex *qlwurc_regex;
- GRegex *rdy_regex;
+ MMBroadbandModemClass *broadband_modem_class_parent;
+ MMIfaceModemInterface *iface_modem_parent;
+ MMIfaceModemLocationInterface *iface_modem_location_parent;
+ MMModemLocationSource provided_sources;
+ MMModemLocationSource enabled_sources;
+ FeatureSupport qgps_supported;
+ GRegex *qgpsurc_regex;
+ GRegex *qlwurc_regex;
+ GRegex *rdy_regex;
} Private;
static void
diff --git a/src/plugins/quectel/mm-shared-quectel.h b/src/plugins/quectel/mm-shared-quectel.h
index 802b6c8a..b63a1641 100644
--- a/src/plugins/quectel/mm-shared-quectel.h
+++ b/src/plugins/quectel/mm-shared-quectel.h
@@ -37,9 +37,9 @@ typedef struct _MMSharedQuectel MMSharedQuectel;
struct _MMSharedQuectel {
GTypeInterface g_iface;
- MMBroadbandModemClass * (* peek_parent_broadband_modem_class) (MMSharedQuectel *self);
- MMIfaceModemInterface * (* peek_parent_modem_interface) (MMSharedQuectel *self);
- MMIfaceModemLocation * (* peek_parent_modem_location_interface) (MMSharedQuectel *self);
+ MMBroadbandModemClass * (* peek_parent_broadband_modem_class) (MMSharedQuectel *self);
+ MMIfaceModemInterface * (* peek_parent_modem_interface) (MMSharedQuectel *self);
+ MMIfaceModemLocationInterface * (* peek_parent_modem_location_interface) (MMSharedQuectel *self);
};
GType mm_shared_quectel_get_type (void);
diff --git a/src/plugins/simtech/mm-broadband-modem-qmi-simtech.c b/src/plugins/simtech/mm-broadband-modem-qmi-simtech.c
index 05dee87c..7ae1dde2 100644
--- a/src/plugins/simtech/mm-broadband-modem-qmi-simtech.c
+++ b/src/plugins/simtech/mm-broadband-modem-qmi-simtech.c
@@ -28,12 +28,12 @@
#include "mm-broadband-modem-qmi-simtech.h"
#include "mm-shared-simtech.h"
-static void iface_modem_location_init (MMIfaceModemLocation *iface);
-static void iface_modem_voice_init (MMIfaceModemVoice *iface);
-static void shared_simtech_init (MMSharedSimtech *iface);
+static void iface_modem_location_init (MMIfaceModemLocationInterface *iface);
+static void iface_modem_voice_init (MMIfaceModemVoice *iface);
+static void shared_simtech_init (MMSharedSimtech *iface);
-static MMIfaceModemLocation *iface_modem_location_parent;
-static MMIfaceModemVoice *iface_modem_voice_parent;
+static MMIfaceModemLocationInterface *iface_modem_location_parent;
+static MMIfaceModemVoice *iface_modem_voice_parent;
G_DEFINE_TYPE_EXTENDED (MMBroadbandModemQmiSimtech, mm_broadband_modem_qmi_simtech, MM_TYPE_BROADBAND_MODEM_QMI, 0,
G_IMPLEMENT_INTERFACE (MM_TYPE_IFACE_MODEM_LOCATION, iface_modem_location_init)
@@ -71,7 +71,7 @@ mm_broadband_modem_qmi_simtech_init (MMBroadbandModemQmiSimtech *self)
}
static void
-iface_modem_location_init (MMIfaceModemLocation *iface)
+iface_modem_location_init (MMIfaceModemLocationInterface *iface)
{
iface_modem_location_parent = g_type_interface_peek_parent (iface);
@@ -83,7 +83,7 @@ iface_modem_location_init (MMIfaceModemLocation *iface)
iface->disable_location_gathering_finish = mm_shared_simtech_disable_location_gathering_finish;
}
-static MMIfaceModemLocation *
+static MMIfaceModemLocationInterface *
peek_parent_location_interface (MMSharedSimtech *self)
{
return iface_modem_location_parent;
diff --git a/src/plugins/simtech/mm-broadband-modem-simtech.c b/src/plugins/simtech/mm-broadband-modem-simtech.c
index 5501ee9b..e70dbd4a 100644
--- a/src/plugins/simtech/mm-broadband-modem-simtech.c
+++ b/src/plugins/simtech/mm-broadband-modem-simtech.c
@@ -37,16 +37,16 @@
#include "mm-shared-simtech.h"
#include "mm-broadband-modem-simtech.h"
-static void iface_modem_init (MMIfaceModemInterface *iface);
-static void iface_modem_3gpp_init (MMIfaceModem3gppInterface *iface);
-static void iface_modem_location_init (MMIfaceModemLocation *iface);
-static void iface_modem_voice_init (MMIfaceModemVoice *iface);
-static void shared_simtech_init (MMSharedSimtech *iface);
+static void iface_modem_init (MMIfaceModemInterface *iface);
+static void iface_modem_3gpp_init (MMIfaceModem3gppInterface *iface);
+static void iface_modem_location_init (MMIfaceModemLocationInterface *iface);
+static void iface_modem_voice_init (MMIfaceModemVoice *iface);
+static void shared_simtech_init (MMSharedSimtech *iface);
-static MMIfaceModemInterface *iface_modem_parent;
-static MMIfaceModem3gppInterface *iface_modem_3gpp_parent;
-static MMIfaceModemLocation *iface_modem_location_parent;
-static MMIfaceModemVoice *iface_modem_voice_parent;
+static MMIfaceModemInterface *iface_modem_parent;
+static MMIfaceModem3gppInterface *iface_modem_3gpp_parent;
+static MMIfaceModemLocationInterface *iface_modem_location_parent;
+static MMIfaceModemVoice *iface_modem_voice_parent;
G_DEFINE_TYPE_EXTENDED (MMBroadbandModemSimtech, mm_broadband_modem_simtech, MM_TYPE_BROADBAND_MODEM, 0,
G_IMPLEMENT_INTERFACE (MM_TYPE_IFACE_MODEM, iface_modem_init)
@@ -1476,7 +1476,7 @@ iface_modem_3gpp_init (MMIfaceModem3gppInterface *iface)
}
static void
-iface_modem_location_init (MMIfaceModemLocation *iface)
+iface_modem_location_init (MMIfaceModemLocationInterface *iface)
{
iface_modem_location_parent = g_type_interface_peek_parent (iface);
@@ -1488,7 +1488,7 @@ iface_modem_location_init (MMIfaceModemLocation *iface)
iface->disable_location_gathering_finish = mm_shared_simtech_disable_location_gathering_finish;
}
-static MMIfaceModemLocation *
+static MMIfaceModemLocationInterface *
peek_parent_location_interface (MMSharedSimtech *self)
{
return iface_modem_location_parent;
diff --git a/src/plugins/simtech/mm-shared-simtech.c b/src/plugins/simtech/mm-shared-simtech.c
index 240483b5..8992d7b8 100644
--- a/src/plugins/simtech/mm-shared-simtech.c
+++ b/src/plugins/simtech/mm-shared-simtech.c
@@ -44,10 +44,10 @@ typedef enum {
typedef struct {
/* location */
- MMIfaceModemLocation *iface_modem_location_parent;
- MMModemLocationSource supported_sources;
- MMModemLocationSource enabled_sources;
- FeatureSupport cgps_support;
+ MMIfaceModemLocationInterface *iface_modem_location_parent;
+ MMModemLocationSource supported_sources;
+ MMModemLocationSource enabled_sources;
+ FeatureSupport cgps_support;
/* voice */
MMIfaceModemVoice *iface_modem_voice_parent;
FeatureSupport cpcmreg_support;
diff --git a/src/plugins/simtech/mm-shared-simtech.h b/src/plugins/simtech/mm-shared-simtech.h
index 37a221ca..028c5894 100644
--- a/src/plugins/simtech/mm-shared-simtech.h
+++ b/src/plugins/simtech/mm-shared-simtech.h
@@ -38,7 +38,7 @@ struct _MMSharedSimtech {
GTypeInterface g_iface;
/* Peek location interface of the parent class of the object */
- MMIfaceModemLocation * (* peek_parent_location_interface) (MMSharedSimtech *self);
+ MMIfaceModemLocationInterface * (* peek_parent_location_interface) (MMSharedSimtech *self);
/* Peek voice interface of the parent class of the object */
MMIfaceModemVoice * (* peek_parent_voice_interface) (MMSharedSimtech *self);
diff --git a/src/plugins/telit/mm-broadband-modem-telit.c b/src/plugins/telit/mm-broadband-modem-telit.c
index b7940555..105bf177 100644
--- a/src/plugins/telit/mm-broadband-modem-telit.c
+++ b/src/plugins/telit/mm-broadband-modem-telit.c
@@ -36,14 +36,14 @@
#include "mm-telit-enums-types.h"
#include "mm-shared-telit.h"
-static void iface_modem_init (MMIfaceModemInterface *iface);
-static void iface_modem_3gpp_init (MMIfaceModem3gppInterface *iface);
-static void shared_telit_init (MMSharedTelit *iface);
-static void iface_modem_location_init (MMIfaceModemLocation *iface);
+static void iface_modem_init (MMIfaceModemInterface *iface);
+static void iface_modem_3gpp_init (MMIfaceModem3gppInterface *iface);
+static void shared_telit_init (MMSharedTelit *iface);
+static void iface_modem_location_init (MMIfaceModemLocationInterface *iface);
-static MMIfaceModemInterface *iface_modem_parent;
-static MMIfaceModem3gppInterface *iface_modem_3gpp_parent;
-static MMIfaceModemLocation *iface_modem_location_parent;
+static MMIfaceModemInterface *iface_modem_parent;
+static MMIfaceModem3gppInterface *iface_modem_3gpp_parent;
+static MMIfaceModemLocationInterface *iface_modem_location_parent;
G_DEFINE_TYPE_EXTENDED (MMBroadbandModemTelit, mm_broadband_modem_telit, MM_TYPE_BROADBAND_MODEM, 0,
G_IMPLEMENT_INTERFACE (MM_TYPE_IFACE_MODEM, iface_modem_init)
@@ -1597,7 +1597,7 @@ shared_telit_init (MMSharedTelit *iface)
}
static void
-iface_modem_location_init (MMIfaceModemLocation *iface)
+iface_modem_location_init (MMIfaceModemLocationInterface *iface)
{
iface_modem_location_parent = g_type_interface_peek_parent (iface);
diff --git a/src/plugins/xmm/mm-broadband-modem-mbim-xmm.c b/src/plugins/xmm/mm-broadband-modem-mbim-xmm.c
index 9698fa51..04308fec 100644
--- a/src/plugins/xmm/mm-broadband-modem-mbim-xmm.c
+++ b/src/plugins/xmm/mm-broadband-modem-mbim-xmm.c
@@ -27,11 +27,11 @@
#include "mm-broadband-modem-mbim-xmm.h"
#include "mm-shared-xmm.h"
-static void iface_modem_init (MMIfaceModemInterface *iface);
-static void iface_modem_location_init (MMIfaceModemLocation *iface);
-static void shared_xmm_init (MMSharedXmm *iface);
+static void iface_modem_init (MMIfaceModemInterface *iface);
+static void iface_modem_location_init (MMIfaceModemLocationInterface *iface);
+static void shared_xmm_init (MMSharedXmm *iface);
-static MMIfaceModemLocation *iface_modem_location_parent;
+static MMIfaceModemLocationInterface *iface_modem_location_parent;
G_DEFINE_TYPE_EXTENDED (MMBroadbandModemMbimXmm, mm_broadband_modem_mbim_xmm, MM_TYPE_BROADBAND_MODEM_MBIM, 0,
G_IMPLEMENT_INTERFACE (MM_TYPE_IFACE_MODEM, iface_modem_init)
@@ -96,7 +96,7 @@ iface_modem_init (MMIfaceModemInterface *iface)
}
static void
-iface_modem_location_init (MMIfaceModemLocation *iface)
+iface_modem_location_init (MMIfaceModemLocationInterface *iface)
{
iface_modem_location_parent = g_type_interface_peek_parent (iface);
@@ -118,7 +118,7 @@ peek_parent_broadband_modem_class (MMSharedXmm *self)
return MM_BROADBAND_MODEM_CLASS (mm_broadband_modem_mbim_xmm_parent_class);
}
-static MMIfaceModemLocation *
+static MMIfaceModemLocationInterface *
peek_parent_location_interface (MMSharedXmm *self)
{
return iface_modem_location_parent;
diff --git a/src/plugins/xmm/mm-broadband-modem-xmm.c b/src/plugins/xmm/mm-broadband-modem-xmm.c
index cc7731c9..9998efd2 100644
--- a/src/plugins/xmm/mm-broadband-modem-xmm.c
+++ b/src/plugins/xmm/mm-broadband-modem-xmm.c
@@ -27,12 +27,12 @@
#include "mm-broadband-modem-xmm.h"
#include "mm-shared-xmm.h"
-static void iface_modem_init (MMIfaceModemInterface *iface);
-static void shared_xmm_init (MMSharedXmm *iface);
-static void iface_modem_signal_init (MMIfaceModemSignal *iface);
-static void iface_modem_location_init (MMIfaceModemLocation *iface);
+static void iface_modem_init (MMIfaceModemInterface *iface);
+static void shared_xmm_init (MMSharedXmm *iface);
+static void iface_modem_signal_init (MMIfaceModemSignal *iface);
+static void iface_modem_location_init (MMIfaceModemLocationInterface *iface);
-static MMIfaceModemLocation *iface_modem_location_parent;
+static MMIfaceModemLocationInterface *iface_modem_location_parent;
G_DEFINE_TYPE_EXTENDED (MMBroadbandModemXmm, mm_broadband_modem_xmm, MM_TYPE_BROADBAND_MODEM, 0,
G_IMPLEMENT_INTERFACE (MM_TYPE_IFACE_MODEM, iface_modem_init)
@@ -99,7 +99,7 @@ iface_modem_init (MMIfaceModemInterface *iface)
static void
-iface_modem_location_init (MMIfaceModemLocation *iface)
+iface_modem_location_init (MMIfaceModemLocationInterface *iface)
{
iface_modem_location_parent = g_type_interface_peek_parent (iface);
@@ -121,7 +121,7 @@ peek_parent_broadband_modem_class (MMSharedXmm *self)
return MM_BROADBAND_MODEM_CLASS (mm_broadband_modem_xmm_parent_class);
}
-static MMIfaceModemLocation *
+static MMIfaceModemLocationInterface *
peek_parent_location_interface (MMSharedXmm *self)
{
return iface_modem_location_parent;
diff --git a/src/plugins/xmm/mm-shared-xmm.c b/src/plugins/xmm/mm-shared-xmm.c
index 999c0fc6..69820dfc 100644
--- a/src/plugins/xmm/mm-shared-xmm.c
+++ b/src/plugins/xmm/mm-shared-xmm.c
@@ -57,13 +57,13 @@ typedef struct {
MMModemMode allowed_modes;
/* Location interface support */
- MMIfaceModemLocation *iface_modem_location_parent;
- MMModemLocationSource supported_sources;
- MMModemLocationSource enabled_sources;
- GpsEngineState gps_engine_state;
- MMPortSerialAt *gps_port;
- GRegex *xlsrstop_regex;
- GRegex *nmea_regex;
+ MMIfaceModemLocationInterface *iface_modem_location_parent;
+ MMModemLocationSource supported_sources;
+ MMModemLocationSource enabled_sources;
+ GpsEngineState gps_engine_state;
+ MMPortSerialAt *gps_port;
+ GRegex *xlsrstop_regex;
+ GRegex *nmea_regex;
/* Asynchronous GPS engine stop task completion */
GTask *pending_gps_engine_stop_task;
diff --git a/src/plugins/xmm/mm-shared-xmm.h b/src/plugins/xmm/mm-shared-xmm.h
index a1f51639..7fb4fdb3 100644
--- a/src/plugins/xmm/mm-shared-xmm.h
+++ b/src/plugins/xmm/mm-shared-xmm.h
@@ -41,7 +41,7 @@ struct _MMSharedXmm {
MMBroadbandModemClass * (* peek_parent_broadband_modem_class) (MMSharedXmm *self);
/* Peek location interface of the parent class of the object */
- MMIfaceModemLocation * (* peek_parent_location_interface) (MMSharedXmm *self);
+ MMIfaceModemLocationInterface * (* peek_parent_location_interface) (MMSharedXmm *self);
};
GType mm_shared_xmm_get_type (void);