LKML Archive on
help / color / mirror / Atom feed
From: "Rafael J. Wysocki" <>
To: Greg KH <>
Cc: Alan Stern <>,
	Len Brown <>, LKML <>,
	Pavel Machek <>,
	pm list <>
Subject: [PATCH] Device core: Remove dpm_sysfs_remove() from error path of device_add()
Date: Mon, 3 Mar 2008 23:46:51 +0100	[thread overview]
Message-ID: <> (raw)

Hi Greg,

The appended patch fixes a bug in the error path of device_add().

Please accept it for 2.6.25.


From: Rafael J. Wysocki <>

Since device_pm_remove(dev) calls dpm_sysfs_remove(dev), it's
incorrect to call the latter after the former in the device_add()
error path.

Signed-off-by: Rafael J. Wysocki <>
 drivers/base/core.c |    1 -
 1 file changed, 1 deletion(-)

Index: linux-2.6/drivers/base/core.c
--- linux-2.6.orig/drivers/base/core.c
+++ linux-2.6/drivers/base/core.c
@@ -839,7 +839,6 @@ int device_add(struct device *dev)
 	return error;
-	dpm_sysfs_remove(dev);
 	if (dev->bus)

                 reply	other threads:[~2008-03-03 22:48 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

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:

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

  git send-email \ \ \ \ \ \ \ \ \
    --subject='Re: [PATCH] Device core: Remove dpm_sysfs_remove() from error path of device_add()' \

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).