]> err.no Git - systemd/commitdiff
[PATCH] If a LABEL rule has a BUS id, then we must check to see if the device is...
authorgreg@kroah.com <greg@kroah.com>
Thu, 25 Dec 2003 08:33:00 +0000 (00:33 -0800)
committerGreg KH <gregkh@suse.de>
Wed, 27 Apr 2005 04:13:11 +0000 (21:13 -0700)
namedev.c

index de1b20618022f8f48820fca1c01691b2c08167e2..813f26b035ecf3a633e05c8333a32a28f410b2d1 100644 (file)
--- a/namedev.c
+++ b/namedev.c
@@ -473,7 +473,10 @@ static int do_label(struct sysfs_class_device *class_dev, struct udevice *udev,
                if (dev->type != LABEL)
                        continue;
 
-               if (sysfs_device) {
+               if (dev->bus[0] != '\0') {
+                       /* as the user specified a bus, we must match it up */
+                       if (!sysfs_device)
+                               continue;
                        dbg("dev->bus='%s' sysfs_device->bus='%s'", dev->bus, sysfs_device->bus);
                        if (strcasecmp(dev->bus, sysfs_device->bus) != 0)
                                continue;