aboutsummaryrefslogtreecommitdiff
path: root/src/mm-plugin.c
diff options
context:
space:
mode:
authorAleksander Morgado <aleksander@lanedo.com>2012-08-21 11:32:24 +0200
committerAleksander Morgado <aleksander@lanedo.com>2012-08-29 17:26:46 +0200
commit494a70a8ffff4a50d0a00e99e964165054ff36aa (patch)
tree1e4c4ff6bc9f484b0e4fac4ab06743d8dd108de9 /src/mm-plugin.c
parent8cb021293ce0aa316028339c8f213c0bf72c9158 (diff)
core: handle the 'usb'->'usbmisc' subsystem rename in the kernel
We'll try to cope with getting devices being reported in either 'usb' or 'usbmisc', trying to avoid the need of checking kernel version during runtime.
Diffstat (limited to 'src/mm-plugin.c')
-rw-r--r--src/mm-plugin.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/src/mm-plugin.c b/src/mm-plugin.c
index 8948e96c..a1a1c33f 100644
--- a/src/mm-plugin.c
+++ b/src/mm-plugin.c
@@ -188,6 +188,10 @@ apply_pre_probing_filters (MMPlugin *self,
for (i = 0; self->priv->subsystems[i]; i++) {
if (g_str_equal (subsys, self->priv->subsystems[i]))
break;
+ /* New kernels may report as 'usbmisc' the subsystem */
+ else if (g_str_equal (self->priv->subsystems[i], "usb") &&
+ g_str_equal (subsys, "usbmisc"))
+ break;
}
/* If we didn't match any subsystem: unsupported */