diff options
author | Rafael J. Wysocki <rafael.j.wysocki@intel.com> | 2013-07-04 21:03:25 -0400 |
---|---|---|
committer | Rafael J. Wysocki <rafael.j.wysocki@intel.com> | 2013-07-14 19:33:12 -0400 |
commit | f09ce741a03ad7de591aa47e760fbeee28567b63 (patch) | |
tree | 2cbbd5f36902f161102ca5e9348bb6bdae62600f /include/acpi/acpi_drivers.h | |
parent | e6c215f15a1cbf4cdd6996d95fba0c0d6c0f3ccc (diff) |
ACPI / dock / PCI: Drop ACPI dock notifier chain
The only user of the ACPI dock notifier chain is the ACPI-based PCI
hotplug (acpiphp) driver that uses it to carry out post-dock fixups
needed by some systems with broken _DCK. However, it is not
necessary to use a separate notifier chain for that, as it can be
simply replaced with a new callback in struct acpi_dock_ops.
For this reason, add a new .fixup() callback to struct acpi_dock_ops
and make hotplug_dock_devices() execute it for all dock devices with
hotplug operations registered. Accordingly, make acpiphp point that
callback to the function carrying out the post-dock fixups and
do not register a separate dock notifier for each device
registering dock operations. Finally, drop the ACPI dock notifier
chain that has no more users.
Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
Diffstat (limited to 'include/acpi/acpi_drivers.h')
-rw-r--r-- | include/acpi/acpi_drivers.h | 10 |
1 files changed, 1 insertions, 9 deletions
diff --git a/include/acpi/acpi_drivers.h b/include/acpi/acpi_drivers.h index 0cf85786ed21..1cedfcb1bd88 100644 --- a/include/acpi/acpi_drivers.h +++ b/include/acpi/acpi_drivers.h | |||
@@ -113,14 +113,13 @@ void pci_acpi_crs_quirks(void); | |||
113 | Dock Station | 113 | Dock Station |
114 | -------------------------------------------------------------------------- */ | 114 | -------------------------------------------------------------------------- */ |
115 | struct acpi_dock_ops { | 115 | struct acpi_dock_ops { |
116 | acpi_notify_handler fixup; | ||
116 | acpi_notify_handler handler; | 117 | acpi_notify_handler handler; |
117 | acpi_notify_handler uevent; | 118 | acpi_notify_handler uevent; |
118 | }; | 119 | }; |
119 | 120 | ||
120 | #ifdef CONFIG_ACPI_DOCK | 121 | #ifdef CONFIG_ACPI_DOCK |
121 | extern int is_dock_device(acpi_handle handle); | 122 | extern int is_dock_device(acpi_handle handle); |
122 | extern int register_dock_notifier(struct notifier_block *nb); | ||
123 | extern void unregister_dock_notifier(struct notifier_block *nb); | ||
124 | extern int register_hotplug_dock_device(acpi_handle handle, | 123 | extern int register_hotplug_dock_device(acpi_handle handle, |
125 | const struct acpi_dock_ops *ops, | 124 | const struct acpi_dock_ops *ops, |
126 | void *context, | 125 | void *context, |
@@ -132,13 +131,6 @@ static inline int is_dock_device(acpi_handle handle) | |||
132 | { | 131 | { |
133 | return 0; | 132 | return 0; |
134 | } | 133 | } |
135 | static inline int register_dock_notifier(struct notifier_block *nb) | ||
136 | { | ||
137 | return -ENODEV; | ||
138 | } | ||
139 | static inline void unregister_dock_notifier(struct notifier_block *nb) | ||
140 | { | ||
141 | } | ||
142 | static inline int register_hotplug_dock_device(acpi_handle handle, | 134 | static inline int register_hotplug_dock_device(acpi_handle handle, |
143 | const struct acpi_dock_ops *ops, | 135 | const struct acpi_dock_ops *ops, |
144 | void *context, | 136 | void *context, |