aboutsummaryrefslogtreecommitdiffstats
path: root/include/linux/device.h
diff options
context:
space:
mode:
authorDmitry Torokhov <dmitry.torokhov@gmail.com>2009-07-23 00:47:29 -0400
committerDmitry Torokhov <dmitry.torokhov@gmail.com>2009-07-23 00:47:29 -0400
commitbd072111e7319d90a7b8127f91c2806b9a6f279e (patch)
tree1686978814a2387ebfc16f9f5778a7f0caaf319b /include/linux/device.h
parent24d01c0681bfbc10a99304c48a89ad213d2d7a4b (diff)
parent4be3bd7849165e7efa6b0b35a23d6a3598d97465 (diff)
Merge commit 'v2.6.31-rc4' into next
Diffstat (limited to 'include/linux/device.h')
-rw-r--r--include/linux/device.h12
1 files changed, 5 insertions, 7 deletions
diff --git a/include/linux/device.h b/include/linux/device.h
index 5d5c197bad45..aebb81036db2 100644
--- a/include/linux/device.h
+++ b/include/linux/device.h
@@ -25,8 +25,6 @@
25#include <asm/atomic.h> 25#include <asm/atomic.h>
26#include <asm/device.h> 26#include <asm/device.h>
27 27
28#define BUS_ID_SIZE 20
29
30struct device; 28struct device;
31struct device_private; 29struct device_private;
32struct device_driver; 30struct device_driver;
@@ -62,8 +60,6 @@ struct bus_type {
62 void (*shutdown)(struct device *dev); 60 void (*shutdown)(struct device *dev);
63 61
64 int (*suspend)(struct device *dev, pm_message_t state); 62 int (*suspend)(struct device *dev, pm_message_t state);
65 int (*suspend_late)(struct device *dev, pm_message_t state);
66 int (*resume_early)(struct device *dev);
67 int (*resume)(struct device *dev); 63 int (*resume)(struct device *dev);
68 64
69 struct dev_pm_ops *pm; 65 struct dev_pm_ops *pm;
@@ -116,6 +112,8 @@ extern int bus_unregister_notifier(struct bus_type *bus,
116#define BUS_NOTIFY_BOUND_DRIVER 0x00000003 /* driver bound to device */ 112#define BUS_NOTIFY_BOUND_DRIVER 0x00000003 /* driver bound to device */
117#define BUS_NOTIFY_UNBIND_DRIVER 0x00000004 /* driver about to be 113#define BUS_NOTIFY_UNBIND_DRIVER 0x00000004 /* driver about to be
118 unbound */ 114 unbound */
115#define BUS_NOTIFY_UNBOUND_DRIVER 0x00000005 /* driver is unbound
116 from the device */
119 117
120extern struct kset *bus_get_kset(struct bus_type *bus); 118extern struct kset *bus_get_kset(struct bus_type *bus);
121extern struct klist *bus_get_device_klist(struct bus_type *bus); 119extern struct klist *bus_get_device_klist(struct bus_type *bus);
@@ -194,6 +192,7 @@ struct class {
194 struct kobject *dev_kobj; 192 struct kobject *dev_kobj;
195 193
196 int (*dev_uevent)(struct device *dev, struct kobj_uevent_env *env); 194 int (*dev_uevent)(struct device *dev, struct kobj_uevent_env *env);
195 char *(*nodename)(struct device *dev);
197 196
198 void (*class_release)(struct class *class); 197 void (*class_release)(struct class *class);
199 void (*dev_release)(struct device *dev); 198 void (*dev_release)(struct device *dev);
@@ -289,11 +288,9 @@ struct device_type {
289 const char *name; 288 const char *name;
290 struct attribute_group **groups; 289 struct attribute_group **groups;
291 int (*uevent)(struct device *dev, struct kobj_uevent_env *env); 290 int (*uevent)(struct device *dev, struct kobj_uevent_env *env);
291 char *(*nodename)(struct device *dev);
292 void (*release)(struct device *dev); 292 void (*release)(struct device *dev);
293 293
294 int (*suspend)(struct device *dev, pm_message_t state);
295 int (*resume)(struct device *dev);
296
297 struct dev_pm_ops *pm; 294 struct dev_pm_ops *pm;
298}; 295};
299 296
@@ -491,6 +488,7 @@ extern struct device *device_find_child(struct device *dev, void *data,
491extern int device_rename(struct device *dev, char *new_name); 488extern int device_rename(struct device *dev, char *new_name);
492extern int device_move(struct device *dev, struct device *new_parent, 489extern int device_move(struct device *dev, struct device *new_parent,
493 enum dpm_order dpm_order); 490 enum dpm_order dpm_order);
491extern const char *device_get_nodename(struct device *dev, const char **tmp);
494 492
495/* 493/*
496 * Root device objects for grouping under /sys/devices 494 * Root device objects for grouping under /sys/devices