From 91ce5e9a6892dc82ba089841678cdd0264cb7da6 Mon Sep 17 00:00:00 2001 From: Aleksander Morgado Date: Mon, 23 Dec 2019 15:06:44 +0100 Subject: [PATCH] broadband-modem: remove unused method The logic in open_ports_initialization() was included in the generic ports_context_open() method, and the method was not being used anywhere. --- src/mm-broadband-modem.c | 28 ---------------------------- 1 file changed, 28 deletions(-) diff --git a/src/mm-broadband-modem.c b/src/mm-broadband-modem.c index db4e39fe..4d3899ac 100644 --- a/src/mm-broadband-modem.c +++ b/src/mm-broadband-modem.c @@ -10099,34 +10099,6 @@ initialization_started_finish (MMBroadbandModem *self, return g_task_propagate_pointer (G_TASK (res), error); } -static gboolean -open_ports_initialization (MMBroadbandModem *self, - PortsContext *ctx, - GError **error) -{ - ctx->primary = mm_base_modem_get_port_primary (MM_BASE_MODEM (self)); - if (!ctx->primary) { - g_set_error (error, - MM_CORE_ERROR, - MM_CORE_ERROR_FAILED, - "Couldn't get primary port"); - return FALSE; - } - - /* Open and send first commands to the primary serial port. - * We do keep the primary port open during the whole initialization - * sequence. Note that this port is not really passed to the interfaces, - * they will get the primary port themselves. */ - if (!mm_port_serial_open (MM_PORT_SERIAL (ctx->primary), error)) { - g_prefix_error (error, "Couldn't open primary port: "); - return FALSE; - } - - ctx->primary_open = TRUE; - - return TRUE; -} - static void initialization_started (MMBroadbandModem *self, GAsyncReadyCallback callback,