aboutsummaryrefslogtreecommitdiff
path: root/src/mm-device.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/mm-device.c')
-rw-r--r--src/mm-device.c11
1 files changed, 11 insertions, 0 deletions
diff --git a/src/mm-device.c b/src/mm-device.c
index 6af43dae..faf7c942 100644
--- a/src/mm-device.c
+++ b/src/mm-device.c
@@ -140,6 +140,17 @@ get_device_ids (GUdevDevice *device,
/* Platform devices don't usually have a VID/PID */
success = TRUE;
goto out;
+ } else if (!strcmp (parent_subsys, "usb") &&
+ !strcmp (g_udev_device_get_driver (parent), "qmi_wwan")) {
+ /* Need to look for vendor/product in the parent of the QMI device */
+ GUdevDevice *qmi_parent;
+
+ qmi_parent = g_udev_device_get_parent (parent);
+ if (qmi_parent) {
+ vid = g_udev_device_get_property (qmi_parent, "ID_VENDOR_ID");
+ pid = g_udev_device_get_property (qmi_parent, "ID_MODEL_ID");
+ g_object_unref (qmi_parent);
+ }
}
}
}