summaryrefslogtreecommitdiff
path: root/include/linux/device.h
diff options
context:
space:
mode:
authorCornelia Huck <cornelia.huck@de.ibm.com>2009-03-04 14:44:00 +0300
committerGreg Kroah-Hartman <gregkh@suse.de>2009-03-25 02:38:26 +0300
commitffa6a7054d172a2f57248dff2de600ca795c5656 (patch)
treef93c6234bb90295c52fcef09e367ed77ff6c3645 /include/linux/device.h
parent60530afe1ee8a5532cb09d0ab5bc3f1a6495b780 (diff)
downloadlinux-ffa6a7054d172a2f57248dff2de600ca795c5656.tar.xz
Driver core: Fix device_move() vs. dpm list ordering, v2
dpm_list currently relies on the fact that child devices will be registered after their parents to get a correct suspend order. Using device_move() however destroys this assumption, as an already registered device may be moved under a newly registered one. This patch adds a new argument to device_move(), allowing callers to specify how dpm_list should be adapted. Signed-off-by: Cornelia Huck <cornelia.huck@de.ibm.com> Acked-by: Alan Stern <stern@rowland.harvard.edu> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Diffstat (limited to 'include/linux/device.h')
-rw-r--r--include/linux/device.h3
1 files changed, 2 insertions, 1 deletions
diff --git a/include/linux/device.h b/include/linux/device.h
index 914c1016dd8f..f98d0cfb4f81 100644
--- a/include/linux/device.h
+++ b/include/linux/device.h
@@ -494,7 +494,8 @@ extern int device_for_each_child(struct device *dev, void *data,
extern struct device *device_find_child(struct device *dev, void *data,
int (*match)(struct device *dev, void *data));
extern int device_rename(struct device *dev, char *new_name);
-extern int device_move(struct device *dev, struct device *new_parent);
+extern int device_move(struct device *dev, struct device *new_parent,
+ enum dpm_order dpm_order);
/*
* Root device objects for grouping under /sys/devices