From f7c4909243fae6fbf434da0471f7ba214bb9a255 Mon Sep 17 00:00:00 2001 From: Wim Taymans Date: Thu, 20 Oct 2022 16:44:37 +0200 Subject: [PATCH] udev: use devpath for the sysfs.path property So that it matches what pulseaudio does. Fixes #2779 --- spa/plugins/alsa/alsa-udev.c | 2 +- spa/plugins/v4l2/v4l2-udev.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/spa/plugins/alsa/alsa-udev.c b/spa/plugins/alsa/alsa-udev.c index 1a48a27ef..f89d86375 100644 --- a/spa/plugins/alsa/alsa-udev.c +++ b/spa/plugins/alsa/alsa-udev.c @@ -465,7 +465,7 @@ static int emit_object_info(struct impl *this, struct device *device) if (str && *str) { items[n_items++] = SPA_DICT_ITEM_INIT(SPA_KEY_DEVICE_BUS_PATH, str); } - if ((str = udev_device_get_syspath(dev)) && *str) { + if ((str = udev_device_get_devpath(dev)) && *str) { items[n_items++] = SPA_DICT_ITEM_INIT(SPA_KEY_DEVICE_SYSFS_PATH, str); } if ((str = udev_device_get_property_value(dev, "ID_ID")) && *str) { diff --git a/spa/plugins/v4l2/v4l2-udev.c b/spa/plugins/v4l2/v4l2-udev.c index df1b1f890..e7f926585 100644 --- a/spa/plugins/v4l2/v4l2-udev.c +++ b/spa/plugins/v4l2/v4l2-udev.c @@ -266,7 +266,7 @@ static int emit_object_info(struct impl *this, struct device *device) if (str && *str) { items[n_items++] = SPA_DICT_ITEM_INIT(SPA_KEY_DEVICE_BUS_PATH, str); } - if ((str = udev_device_get_syspath(dev)) && *str) { + if ((str = udev_device_get_devpath(dev)) && *str) { items[n_items++] = SPA_DICT_ITEM_INIT(SPA_KEY_DEVICE_SYSFS_PATH, str); } if ((str = udev_device_get_property_value(dev, "ID_ID")) && *str) {