From 950abbf8ee8624827d63a0d0186beac81232e8f6 Mon Sep 17 00:00:00 2001 From: Aleksander Morgado Date: Fri, 6 Nov 2020 12:27:40 +0100 Subject: core: stop monitoring the 'usb' subsystem Back in Linux < 3.6 days, the cdc-wdm ports exposed by the QMI driver were flagged as owned by the 'usb' subsystem. That changed in 3.6 when the subsystem was renamed to 'usbmisc': https://mail.gnome.org/archives/networkmanager-list/2012-June/msg00125.html This patch removes all monitoring of the 'usb' subsystem completely, which is anyway a valid subsystem but for which we shouldn't need any special handling. Right now, with newer kernels, we were using that monitoring exclusively to get notified of full USB device remove events, which is really not required as we already process the port removals one by one. We simplify the logic everywhere that attempted to match either the 'usb' or 'usbmisc' subsystems, and we no longer require the explicit checks for the port name being named 'cdc-wdm[0-9]*' in the code, as that is already taken care of by the ID_MM_CANDIDATE udev tag rule. --- plugins/simtech/mm-plugin-simtech.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'plugins/simtech/mm-plugin-simtech.c') diff --git a/plugins/simtech/mm-plugin-simtech.c b/plugins/simtech/mm-plugin-simtech.c index 48daa842..99c7697d 100644 --- a/plugins/simtech/mm-plugin-simtech.c +++ b/plugins/simtech/mm-plugin-simtech.c @@ -68,7 +68,7 @@ create_modem (MMPlugin *self, G_MODULE_EXPORT MMPlugin * mm_plugin_create (void) { - static const gchar *subsystems[] = { "tty", "net", "usb", NULL }; + static const gchar *subsystems[] = { "tty", "net", "usbmisc", NULL }; static const guint16 vendor_ids[] = { 0x1e0e, /* A-Link (for now) */ 0 }; -- cgit v1.2.3-70-g09d2