driver core: revert "device" link creation check
authorCornelia Huck <cornelia.huck@de.ibm.com>
Wed, 25 Jul 2007 07:58:08 +0000 (09:58 +0200)
committerGreg Kroah-Hartman <gregkh@suse.de>
Mon, 30 Jul 2007 21:25:12 +0000 (14:25 -0700)
driver core: revert "device" link creation check

Commit 2ee97caf0a6602f749ddbfdb1449e383e1212707 introduced an extra
check on when to create the "device" symlink. Unfortunately, this
breaks input, so let's revert to the old behaviour.

Signed-off-by: Cornelia Huck <cornelia.huck@de.ibm.com>
Acked-by: Kay Sievers <kay.sievers@vrfy.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
drivers/base/core.c

index b9bb3995db8422788e3a139f86ad353159557643..e6738bcbe5a9b2da343e5d20a67b51a6b28545ee 100644 (file)
@@ -678,8 +678,7 @@ static int device_add_class_symlinks(struct device *dev)
                if (error)
                        goto out_subsys;
        }
-       /* only bus-device parents get a "device"-link */
-       if (dev->parent && dev->parent->bus) {
+       if (dev->parent) {
                error = sysfs_create_link(&dev->kobj, &dev->parent->kobj,
                                          "device");
                if (error)