]> err.no Git - systemd/commitdiff
[PATCH] detect NAME="" as ignore_device rule
authorkay.sievers@vrfy.org <kay.sievers@vrfy.org>
Mon, 21 Feb 2005 13:05:52 +0000 (14:05 +0100)
committerGreg KH <gregkh@suse.de>
Wed, 27 Apr 2005 06:36:13 +0000 (23:36 -0700)
namedev.c
namedev_parse.c

index 0a37ef2fbca2aee86d0c628cf1100d71cd67da1c..a5c711bdf65dd282d95ca56f74d5bca7f9856ab9 100644 (file)
--- a/namedev.c
+++ b/namedev.c
@@ -749,15 +749,6 @@ int namedev_name_device(struct udevice *udev, struct sysfs_class_device *class_d
                dbg("process rule");
                if (match_rule(udev, dev, class_dev, sysfs_device) == 0) {
 
-                       /* FIXME: remove old style ignore rule and make OPTION="ignore" mandatory */
-                       if (dev->name[0] == '\0' && dev->symlink[0] == '\0' &&
-                           dev->mode == 0000 && dev->owner[0] == '\0' && dev->group[0] == '\0' &&
-                           !dev->ignore_device && !dev->partitions && !dev->ignore_remove) {
-                               info("configured rule in '%s[%i]' applied, '%s' is ignored",
-                                    dev->config_file, dev->config_line, udev->kernel_name);
-                               return -1;
-                       }
-
                        /* apply options */
                        if (dev->ignore_device) {
                                info("configured rule in '%s[%i]' applied, '%s' is ignored",
index eabd9c98bb1957f089af68b14e958cf7d22fd009..7cd676c390dd7c900e685980238d8cf73dcbddff 100644 (file)
@@ -259,7 +259,10 @@ static int namedev_parse(const char *filename, void *data)
                                                dev.ignore_remove = 1;
                                        }
                                }
-                               strfieldcpy(dev.name, temp3);
+                               if (temp3[0] != '\0')
+                                       strfieldcpy(dev.name, temp3);
+                               else
+                                       dev.ignore_device = 1;
                                valid = 1;
                                continue;
                        }