All of lore.kernel.org
 help / color / mirror / Atom feed
From: Kay Sievers <kay.sievers@vrfy.org>
To: Larry Finger <Larry.Finger@lwfinger.net>
Cc: Greg Kroah-Hartman <gregkh@suse.de>, LKML <linux-kernel@vger.kernel.org>
Subject: Re: linux-2.6.23-git3: Many sysfs-related warnings in dmesg
Date: Fri, 26 Oct 2007 20:07:44 +0200	[thread overview]
Message-ID: <1193422064.2190.6.camel@lov.site> (raw)
In-Reply-To: <47221E6F.1090607@lwfinger.net>

On Fri, 2007-10-26 at 12:05 -0500, Larry Finger wrote:
> On my openSUSE 10.3 x86_64 system running v2.6.24-rc1-281-g22d2aa1,
> I get the sysfs rename messages.

Care to try this? Seems like a silly bug in the core if
SYSFS_DEPRECATED=y. That's why we didn't catch this earlier, sorry.

Thanks a lot for the help,
Kay



From: Kay Sievers <kay.sievers@vrfy.org>
Subject: Driver Core: fix bug in device_rename() for SYSFS_DEPRECATED=y

Signed-off-by: Kay Sievers <kay.sievers@vrfy.org>
---

diff --git a/drivers/base/core.c b/drivers/base/core.c
index c134341..3f4d6aa 100644
--- a/drivers/base/core.c
+++ b/drivers/base/core.c
@@ -1228,18 +1228,18 @@ int device_rename(struct device *dev, char *new_name)
 			sysfs_remove_link(&dev->parent->kobj, old_class_name);
 		}
 	}
-#endif
-
+#else
 	if (dev->class) {
 		sysfs_remove_link(&dev->class->subsys.kobj, old_device_name);
 		error = sysfs_create_link(&dev->class->subsys.kobj, &dev->kobj,
 					  dev->bus_id);
 		if (error) {
-			/* Uh... how to unravel this if restoring can fail? */
 			dev_err(dev, "%s: sysfs_create_symlink failed (%d)\n",
 				__FUNCTION__, error);
 		}
 	}
+#endif
+
 out:
 	put_device(dev);
 


  reply	other threads:[~2007-10-26 18:06 UTC|newest]

Thread overview: 27+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-10-26 17:05 linux-2.6.23-git3: Many sysfs-related warnings in dmesg Larry Finger
2007-10-26 18:07 ` Kay Sievers [this message]
2007-10-26 18:20   ` Larry Finger
2007-10-27  2:36   ` Greg KH
2007-10-27  6:08     ` Kay Sievers
2007-10-27  6:32       ` Greg KH
  -- strict thread matches above, loose matches on Subject: below --
2007-10-13 19:26 Rafael J. Wysocki
2007-10-16  4:50 ` Greg KH
2007-10-16 20:04   ` Rafael J. Wysocki
2007-10-16 20:42     ` Greg KH
2007-10-16 20:50       ` Jens Axboe
2007-10-16 21:13         ` Rafael J. Wysocki
2007-10-16 21:36           ` Greg KH
2007-10-16 23:58             ` Rafael J. Wysocki
2007-10-17 10:17               ` Kay Sievers
2007-10-17 17:35                 ` Rafael J. Wysocki
2007-10-16 21:37         ` Greg KH
2007-10-16 22:32           ` David Miller
2007-10-16 23:23             ` Greg KH
2007-10-17 10:16               ` Kay Sievers
2007-10-24 23:43                 ` Greg KH
2007-10-24 23:52                   ` Greg KH
2007-10-25 16:58                     ` Kay Sievers
2007-10-17 10:22         ` Kay Sievers
2007-10-17 10:33           ` Jens Axboe
2007-10-17 10:44             ` Jens Axboe
2007-10-16 20:49     ` Jens Axboe

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1193422064.2190.6.camel@lov.site \
    --to=kay.sievers@vrfy.org \
    --cc=Larry.Finger@lwfinger.net \
    --cc=gregkh@suse.de \
    --cc=linux-kernel@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.