aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--plugins/ublox/77-mm-ublox-port-types.rules7
-rw-r--r--plugins/ublox/mm-plugin-ublox.c29
2 files changed, 3 insertions, 33 deletions
diff --git a/plugins/ublox/77-mm-ublox-port-types.rules b/plugins/ublox/77-mm-ublox-port-types.rules
index 0c5b0961..cb77f0e0 100644
--- a/plugins/ublox/77-mm-ublox-port-types.rules
+++ b/plugins/ublox/77-mm-ublox-port-types.rules
@@ -8,13 +8,12 @@ LABEL="mm_ublox_port_types"
SUBSYSTEMS=="usb", ATTRS{bInterfaceNumber}=="?*", ENV{.MM_USBIFNUM}="$attr{bInterfaceNumber}"
# Toby-L4 port types
-# ttyACM0 (if #2): secondary
+# ttyACM0 (if #2): secondary (ignore)
# ttyACM1 (if #4): debug port (ignore)
# ttyACM2 (if #6): primary
# ttyACM3 (if #8): AT port for FOTA (ignore)
-ATTRS{idVendor}=="1546", ATTRS{idProduct}=="1010", ENV{.MM_USBIFNUM}=="02", ENV{ID_MM_UBLOX_SECONDARY_PORT}="1"
+ATTRS{idVendor}=="1546", ATTRS{idProduct}=="1010", ENV{.MM_USBIFNUM}=="02", ENV{ID_MM_PORT_IGNORE}="1"
ATTRS{idVendor}=="1546", ATTRS{idProduct}=="1010", ENV{.MM_USBIFNUM}=="04", ENV{ID_MM_PORT_IGNORE}="1"
-ATTRS{idVendor}=="1546", ATTRS{idProduct}=="1010", ENV{.MM_USBIFNUM}=="06", ENV{ID_MM_UBLOX_PRIMARY_PORT}="1"
ATTRS{idVendor}=="1546", ATTRS{idProduct}=="1010", ENV{.MM_USBIFNUM}=="08", ENV{ID_MM_PORT_IGNORE}="1"
-LABEL="mm_ublox_port_types_end" \ No newline at end of file
+LABEL="mm_ublox_port_types_end"
diff --git a/plugins/ublox/mm-plugin-ublox.c b/plugins/ublox/mm-plugin-ublox.c
index 5ee09a20..fc9ec0c6 100644
--- a/plugins/ublox/mm-plugin-ublox.c
+++ b/plugins/ublox/mm-plugin-ublox.c
@@ -47,34 +47,6 @@ create_modem (MMPlugin *self,
product));
}
-static gboolean
-grab_port (MMPlugin *self,
- MMBaseModem *modem,
- MMPortProbe *probe,
- GError **error)
-{
- MMPortSerialAtFlag pflags = MM_PORT_SERIAL_AT_FLAG_NONE;
- MMKernelDevice *port;
- MMPortType port_type;
-
- port_type = mm_port_probe_get_port_type (probe);
- port = mm_port_probe_peek_port (probe);
-
- if (mm_kernel_device_get_property_as_boolean (port, "ID_MM_UBLOX_PRIMARY_PORT")) {
- mm_dbg ("(%s/%s)' port flagged as primary",
- mm_port_probe_get_port_subsys (probe),
- mm_port_probe_get_port_name (probe));
- pflags = MM_PORT_SERIAL_AT_FLAG_PRIMARY;
- } else if (mm_kernel_device_get_property_as_boolean (port, "ID_MM_UBLOX_SECONDARY_PORT")) {
- mm_dbg ("(%s/%s) port flagged as secondary",
- mm_port_probe_get_port_subsys (probe),
- mm_port_probe_get_port_name (probe));
- pflags = MM_PORT_SERIAL_AT_FLAG_SECONDARY;
- }
-
- return mm_base_modem_grab_port (modem, port, port_type, pflags, error);
-}
-
/*****************************************************************************/
/* Custom init context */
@@ -295,5 +267,4 @@ mm_plugin_ublox_class_init (MMPluginUbloxClass *klass)
MMPluginClass *plugin_class = MM_PLUGIN_CLASS (klass);
plugin_class->create_modem = create_modem;
- plugin_class->grab_port = grab_port;
}