[PATCH] mbim: fix inconsistency in WITH_QMI guards
Aleksander Morgado
aleksander at aleksander.es
Thu Aug 23 07:45:15 UTC 2018
On 22/08/18 22:26, Ben Chan wrote:
> ---
> src/mm-broadband-modem-mbim.c | 4 ++--
> src/mm-port-mbim.c | 4 ++--
> src/mm-port-mbim.h | 2 +-
> src/mm-port-probe.c | 2 +-
> 4 files changed, 6 insertions(+), 6 deletions(-)
>
Pushed, thanks
> diff --git a/src/mm-broadband-modem-mbim.c b/src/mm-broadband-modem-mbim.c
> index eb9e723b..5460fd46 100644
> --- a/src/mm-broadband-modem-mbim.c
> +++ b/src/mm-broadband-modem-mbim.c
> @@ -1895,7 +1895,7 @@ initialization_started (MMBroadbandModem *self,
> return;
> }
>
> -#if WITH_QMI && QMI_MBIM_QMUX_SUPPORTED
> +#if defined WITH_QMI && QMI_MBIM_QMUX_SUPPORTED
> /* Setup services to open */
> ctx->qmi_services[0] = QMI_SERVICE_DMS;
> ctx->qmi_services[1] = QMI_SERVICE_PDS;
> @@ -1905,7 +1905,7 @@ initialization_started (MMBroadbandModem *self,
>
> /* Now open our MBIM port */
> mm_port_mbim_open (ctx->mbim,
> -#if WITH_QMI && QMI_MBIM_QMUX_SUPPORTED
> +#if defined WITH_QMI && QMI_MBIM_QMUX_SUPPORTED
> TRUE, /* With QMI over MBIM support if available */
> #endif
> NULL,
> diff --git a/src/mm-port-mbim.c b/src/mm-port-mbim.c
> index cd6d9f22..11c61116 100644
> --- a/src/mm-port-mbim.c
> +++ b/src/mm-port-mbim.c
> @@ -302,7 +302,7 @@ mbim_device_new_ready (GObject *unused,
>
> void
> mm_port_mbim_open (MMPortMbim *self,
> -#if WITH_QMI && QMI_MBIM_QMUX_SUPPORTED
> +#if defined WITH_QMI && QMI_MBIM_QMUX_SUPPORTED
> gboolean try_qmi_over_mbim,
> #endif
> GCancellable *cancellable,
> @@ -335,7 +335,7 @@ mm_port_mbim_open (MMPortMbim *self,
> fullpath = g_strdup_printf ("/dev/%s", mm_port_get_device (MM_PORT (self)));
> file = g_file_new_for_path (fullpath);
>
> -#if WITH_QMI && QMI_MBIM_QMUX_SUPPORTED
> +#if defined WITH_QMI && QMI_MBIM_QMUX_SUPPORTED
> /* If we want to try QMI over MBIM, store the GFile as task data */
> if (try_qmi_over_mbim)
> g_task_set_task_data (task, g_object_ref (file), g_object_unref);
> diff --git a/src/mm-port-mbim.h b/src/mm-port-mbim.h
> index f2606ea7..3bd20e48 100644
> --- a/src/mm-port-mbim.h
> +++ b/src/mm-port-mbim.h
> @@ -55,7 +55,7 @@ GType mm_port_mbim_get_type (void);
> MMPortMbim *mm_port_mbim_new (const gchar *name);
>
> void mm_port_mbim_open (MMPortMbim *self,
> -#if WITH_QMI && QMI_MBIM_QMUX_SUPPORTED
> +#if defined WITH_QMI && QMI_MBIM_QMUX_SUPPORTED
> gboolean try_qmi_over_mbim,
> #endif
> GCancellable *cancellable,
> diff --git a/src/mm-port-probe.c b/src/mm-port-probe.c
> index 961964f9..e89ecafa 100644
> --- a/src/mm-port-probe.c
> +++ b/src/mm-port-probe.c
> @@ -584,7 +584,7 @@ wdm_probe_mbim (MMPortProbe *self)
> /* Create a port and try to open it */
> ctx->mbim_port = mm_port_mbim_new (mm_kernel_device_get_name (self->priv->port));
> mm_port_mbim_open (ctx->mbim_port,
> -#if WITH_QMI
> +#if defined WITH_QMI
> FALSE, /* Don't check QMI over MBIM support at this stage */
> #endif
> NULL,
>
--
Aleksander
https://aleksander.es
More information about the ModemManager-devel
mailing list