diff options
Diffstat (limited to 'include/linux/device.h')
| -rw-r--r-- | include/linux/device.h | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/include/linux/device.h b/include/linux/device.h index 23423daa895c..69797acdc546 100644 --- a/include/linux/device.h +++ b/include/linux/device.h @@ -64,6 +64,7 @@ struct device_driver { }; struct device { + struct list_head g_list; /* node in depth-first order list */ struct list_head node; /* node in sibling list */ struct list_head children; struct device * parent; @@ -99,6 +100,12 @@ list_to_dev(struct list_head *node) return list_entry(node, struct device, node); } +static inline struct device * +g_list_to_dev(struct list_head *g_list) +{ + return list_entry(g_list, struct device, g_list); +} + /* * High level routines for use by the bus drivers */ |
