aboutsummaryrefslogtreecommitdiffstats
path: root/include/acpi
diff options
context:
space:
mode:
Diffstat (limited to 'include/acpi')
-rw-r--r--include/acpi/acpi_bus.h21
-rw-r--r--include/acpi/container.h12
2 files changed, 18 insertions, 15 deletions
diff --git a/include/acpi/acpi_bus.h b/include/acpi/acpi_bus.h
index 36ed7e025bfc..227ba7dc293d 100644
--- a/include/acpi/acpi_bus.h
+++ b/include/acpi/acpi_bus.h
@@ -84,19 +84,29 @@ struct acpi_driver;
84struct acpi_device; 84struct acpi_device;
85 85
86/* 86/*
87 * ACPI Scan Handler
88 * -----------------
89 */
90
91struct acpi_scan_handler {
92 const struct acpi_device_id *ids;
93 struct list_head list_node;
94 int (*attach)(struct acpi_device *dev, const struct acpi_device_id *id);
95 void (*detach)(struct acpi_device *dev);
96};
97
98/*
87 * ACPI Driver 99 * ACPI Driver
88 * ----------- 100 * -----------
89 */ 101 */
90 102
91typedef int (*acpi_op_add) (struct acpi_device * device); 103typedef int (*acpi_op_add) (struct acpi_device * device);
92typedef int (*acpi_op_remove) (struct acpi_device * device, int type); 104typedef int (*acpi_op_remove) (struct acpi_device * device);
93typedef int (*acpi_op_start) (struct acpi_device * device);
94typedef void (*acpi_op_notify) (struct acpi_device * device, u32 event); 105typedef void (*acpi_op_notify) (struct acpi_device * device, u32 event);
95 106
96struct acpi_device_ops { 107struct acpi_device_ops {
97 acpi_op_add add; 108 acpi_op_add add;
98 acpi_op_remove remove; 109 acpi_op_remove remove;
99 acpi_op_start start;
100 acpi_op_notify notify; 110 acpi_op_notify notify;
101}; 111};
102 112
@@ -271,6 +281,7 @@ struct acpi_device {
271 struct acpi_device_wakeup wakeup; 281 struct acpi_device_wakeup wakeup;
272 struct acpi_device_perf performance; 282 struct acpi_device_perf performance;
273 struct acpi_device_dir dir; 283 struct acpi_device_dir dir;
284 struct acpi_scan_handler *handler;
274 struct acpi_driver *driver; 285 struct acpi_driver *driver;
275 void *driver_data; 286 void *driver_data;
276 struct device dev; 287 struct device dev;
@@ -384,6 +395,10 @@ int acpi_bus_receive_event(struct acpi_bus_event *event);
384static inline int acpi_bus_generate_proc_event(struct acpi_device *device, u8 type, int data) 395static inline int acpi_bus_generate_proc_event(struct acpi_device *device, u8 type, int data)
385 { return 0; } 396 { return 0; }
386#endif 397#endif
398
399void acpi_scan_lock_acquire(void);
400void acpi_scan_lock_release(void);
401int acpi_scan_add_handler(struct acpi_scan_handler *handler);
387int acpi_bus_register_driver(struct acpi_driver *driver); 402int acpi_bus_register_driver(struct acpi_driver *driver);
388void acpi_bus_unregister_driver(struct acpi_driver *driver); 403void acpi_bus_unregister_driver(struct acpi_driver *driver);
389int acpi_bus_scan(acpi_handle handle); 404int acpi_bus_scan(acpi_handle handle);
diff --git a/include/acpi/container.h b/include/acpi/container.h
deleted file mode 100644
index a703f14e049e..000000000000
--- a/include/acpi/container.h
+++ /dev/null
@@ -1,12 +0,0 @@
1#ifndef __ACPI_CONTAINER_H
2#define __ACPI_CONTAINER_H
3
4#include <linux/kernel.h>
5
6struct acpi_container {
7 acpi_handle handle;
8 unsigned long sun;
9 int state;
10};
11
12#endif /* __ACPI_CONTAINER_H */