[lkml]   [2006]   [Oct]   [23]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
Messages in this thread
Patch in this message
Subject[PATCH] Call platform_notify_remove later
This patch moves the call to platform_notify_remove() to after the call
to bus_remove_device(), where it belongs. It's bogus to notify the
platform of removal while drivers are still attached to the device and
possibly still operating since the platform might use this callback to
tear down some resources used by the driver (ACPI bits, iommu
table, ...)

Signed-off-by: Benjamin Herrenschmidt <>

Note that Len Browned wrote "AFAICS, your change is logical and should
be fine." which I consider an ACK, though I didn't add an Acked-by
line :)

This patch should go in imho after 2.6.19 (it might even be considered a
bug fix for 2.6.19 but it's probably not bad enough, so let's have it
simmer in your tree and -mm for a little while).

This is orthogonal to my other patch adding a notifier which we can
continue discussing separately.

Index: linux-cell/drivers/base/core.c
--- linux-cell.orig/drivers/base/core.c 2006-10-06 13:48:02.000000000 +1000
+++ linux-cell/drivers/base/core.c 2006-10-18 11:53:50.000000000 +1000
@@ -608,12 +608,13 @@ void device_del(struct device * dev)

+ bus_remove_device(dev);
/* Notify the platform of the removal, in case they
* need to do anything...
if (platform_notify_remove)
- bus_remove_device(dev);
kobject_uevent(&dev->kobj, KOBJ_REMOVE);

To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to
More majordomo info at
Please read the FAQ at

 \ /
  Last update: 2006-10-23 06:49    [W:0.097 / U:9.904 seconds]
©2003-2018 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site