aboutsummaryrefslogtreecommitdiffstats
path: root/include/acpi/acpi_bus.h
diff options
context:
space:
mode:
authorBjorn Helgaas <bhelgaas@google.com>2013-01-10 13:18:41 -0500
committerBjorn Helgaas <bhelgaas@google.com>2013-01-10 13:18:41 -0500
commit295a7f6235bfa21be3454aebc1bea1eaf0b74fb7 (patch)
treeae253b12eb331e1d093a3f348b4f8045e80f5e53 /include/acpi/acpi_bus.h
parentb3e65e1f9185a2eb034defe4270ba178ba70b9a9 (diff)
parentf95988de06ea62ef5bd861f06e9ef56cea405ed1 (diff)
Merge branch 'acpi-scan' of git://git.kernel.org/pub/scm/linux/kernel/git/rafael/linux-pm into pci/yinghai-survey-resources+acpi-scan
* 'acpi-scan' of git://git.kernel.org/pub/scm/linux/kernel/git/rafael/linux-pm: ACPI / scan: Treat power resources in a special way ACPI: Remove unused struct acpi_pci_root.id member ACPI: Drop ACPI device .bind() and .unbind() callbacks ACPI / PCI: Move the _PRT setup and cleanup code to pci-acpi.c ACPI / PCI: Rework the setup and cleanup of device wakeup ACPI: Add .setup() and .cleanup() callbacks to struct acpi_bus_type ACPI: Make acpi_bus_scan() and acpi_bus_add() take only one argument ACPI: Replace ACPI device add_type field with a match_driver flag ACPI: Drop the second argument of acpi_bus_scan() ACPI: Remove the arguments of acpi_bus_add() that are not used ACPI: Remove acpi_start_single_object() and acpi_bus_start() ACPI / PCI: Fold acpi_pci_root_start() into acpi_pci_root_add() ACPI: Change the ordering of acpi_bus_check_add() ACPI: Replace struct acpi_bus_ops with enum type ACPI: Reduce the usage of struct acpi_bus_ops ACPI: Make acpi_bus_add() and acpi_bus_start() visibly different ACPI: Change the ordering of PCI root bridge driver registrarion ACPI: Separate adding ACPI device objects from probing ACPI drivers Conflicts: drivers/acpi/pci_root.c
Diffstat (limited to 'include/acpi/acpi_bus.h')
-rw-r--r--include/acpi/acpi_bus.h18
1 files changed, 5 insertions, 13 deletions
diff --git a/include/acpi/acpi_bus.h b/include/acpi/acpi_bus.h
index 7ced5dc20dd3..a9e1421cd007 100644
--- a/include/acpi/acpi_bus.h
+++ b/include/acpi/acpi_bus.h
@@ -95,17 +95,10 @@ typedef int (*acpi_op_bind) (struct acpi_device * device);
95typedef int (*acpi_op_unbind) (struct acpi_device * device); 95typedef int (*acpi_op_unbind) (struct acpi_device * device);
96typedef void (*acpi_op_notify) (struct acpi_device * device, u32 event); 96typedef void (*acpi_op_notify) (struct acpi_device * device, u32 event);
97 97
98struct acpi_bus_ops {
99 u32 acpi_op_add:1;
100 u32 acpi_op_start:1;
101};
102
103struct acpi_device_ops { 98struct acpi_device_ops {
104 acpi_op_add add; 99 acpi_op_add add;
105 acpi_op_remove remove; 100 acpi_op_remove remove;
106 acpi_op_start start; 101 acpi_op_start start;
107 acpi_op_bind bind;
108 acpi_op_unbind unbind;
109 acpi_op_notify notify; 102 acpi_op_notify notify;
110}; 103};
111 104
@@ -148,7 +141,8 @@ struct acpi_device_flags {
148 u32 power_manageable:1; 141 u32 power_manageable:1;
149 u32 performance_manageable:1; 142 u32 performance_manageable:1;
150 u32 eject_pending:1; 143 u32 eject_pending:1;
151 u32 reserved:24; 144 u32 match_driver:1;
145 u32 reserved:23;
152}; 146};
153 147
154/* File System */ 148/* File System */
@@ -283,7 +277,6 @@ struct acpi_device {
283 struct acpi_driver *driver; 277 struct acpi_driver *driver;
284 void *driver_data; 278 void *driver_data;
285 struct device dev; 279 struct device dev;
286 struct acpi_bus_ops bus_ops; /* workaround for different code path for hotplug */
287 enum acpi_bus_removal_type removal_type; /* indicate for different removal type */ 280 enum acpi_bus_removal_type removal_type; /* indicate for different removal type */
288 u8 physical_node_count; 281 u8 physical_node_count;
289 struct list_head physical_node_list; 282 struct list_head physical_node_list;
@@ -356,11 +349,9 @@ static inline int acpi_bus_generate_proc_event(struct acpi_device *device, u8 ty
356#endif 349#endif
357int acpi_bus_register_driver(struct acpi_driver *driver); 350int acpi_bus_register_driver(struct acpi_driver *driver);
358void acpi_bus_unregister_driver(struct acpi_driver *driver); 351void acpi_bus_unregister_driver(struct acpi_driver *driver);
359int acpi_bus_add(struct acpi_device **child, struct acpi_device *parent, 352int acpi_bus_add(acpi_handle handle);
360 acpi_handle handle, int type);
361void acpi_bus_hot_remove_device(void *context); 353void acpi_bus_hot_remove_device(void *context);
362int acpi_bus_trim(struct acpi_device *start, int rmdevice); 354int acpi_bus_trim(struct acpi_device *start, int rmdevice);
363int acpi_bus_start(struct acpi_device *device);
364acpi_status acpi_bus_get_ejd(acpi_handle handle, acpi_handle * ejd); 355acpi_status acpi_bus_get_ejd(acpi_handle handle, acpi_handle * ejd);
365int acpi_match_device_ids(struct acpi_device *device, 356int acpi_match_device_ids(struct acpi_device *device,
366 const struct acpi_device_id *ids); 357 const struct acpi_device_id *ids);
@@ -390,6 +381,8 @@ struct acpi_bus_type {
390 int (*find_device) (struct device *, acpi_handle *); 381 int (*find_device) (struct device *, acpi_handle *);
391 /* For bridges, such as PCI root bridge, IDE controller */ 382 /* For bridges, such as PCI root bridge, IDE controller */
392 int (*find_bridge) (struct device *, acpi_handle *); 383 int (*find_bridge) (struct device *, acpi_handle *);
384 void (*setup)(struct device *);
385 void (*cleanup)(struct device *);
393}; 386};
394int register_acpi_bus_type(struct acpi_bus_type *); 387int register_acpi_bus_type(struct acpi_bus_type *);
395int unregister_acpi_bus_type(struct acpi_bus_type *); 388int unregister_acpi_bus_type(struct acpi_bus_type *);
@@ -397,7 +390,6 @@ int unregister_acpi_bus_type(struct acpi_bus_type *);
397struct acpi_pci_root { 390struct acpi_pci_root {
398 struct list_head node; 391 struct list_head node;
399 struct acpi_device * device; 392 struct acpi_device * device;
400 struct acpi_pci_id id;
401 struct pci_bus *bus; 393 struct pci_bus *bus;
402 u16 segment; 394 u16 segment;
403 struct resource secondary; /* downstream bus range */ 395 struct resource secondary; /* downstream bus range */