From cornelia.huck@de.ibm.com Mon Jan 8 11:15:57 2007 From: Cornelia Huck Date: Mon, 8 Jan 2007 20:16:41 +0100 Subject: driver core: Remove device_is_registered() in device_move(). To: Greg K-H Cc: Marcel Holtmann Message-ID: <20070108201641.141b2240@gondolin.boeblingen.de.ibm.com> From: Cornelia Huck device_is_registered() will always be false for a device with no bus. Remove this check and trust the caller to know what they're doing. Signed-off-by: Cornelia Huck Cc: Marcel Holtmann Signed-off-by: Greg Kroah-Hartman --- drivers/base/core.c | 4 ---- 1 file changed, 4 deletions(-) --- gregkh-2.6.orig/drivers/base/core.c +++ gregkh-2.6/drivers/base/core.c @@ -1004,10 +1004,6 @@ int device_move(struct device *dev, stru if (!dev) return -EINVAL; - if (!device_is_registered(dev)) { - error = -EINVAL; - goto out; - } new_parent = get_device(new_parent); if (!new_parent) { error = -EINVAL;