aboutsummaryrefslogtreecommitdiffstats
path: root/include/acpi
diff options
context:
space:
mode:
Diffstat (limited to 'include/acpi')
-rw-r--r--include/acpi/acpi_bus.h41
-rw-r--r--include/acpi/acpi_drivers.h8
2 files changed, 12 insertions, 37 deletions
diff --git a/include/acpi/acpi_bus.h b/include/acpi/acpi_bus.h
index 1a681ee2aa08..cf0817a555e4 100644
--- a/include/acpi/acpi_bus.h
+++ b/include/acpi/acpi_bus.h
@@ -370,49 +370,20 @@ acpi_status acpi_bus_get_status_handle(acpi_handle handle,
370 unsigned long long *sta); 370 unsigned long long *sta);
371int acpi_bus_get_status(struct acpi_device *device); 371int acpi_bus_get_status(struct acpi_device *device);
372 372
373#ifdef CONFIG_PM
374int acpi_bus_set_power(acpi_handle handle, int state); 373int acpi_bus_set_power(acpi_handle handle, int state);
375const char *acpi_power_state_string(int state); 374const char *acpi_power_state_string(int state);
376int acpi_device_get_power(struct acpi_device *device, int *state); 375int acpi_device_get_power(struct acpi_device *device, int *state);
377int acpi_device_set_power(struct acpi_device *device, int state); 376int acpi_device_set_power(struct acpi_device *device, int state);
378int acpi_bus_init_power(struct acpi_device *device); 377int acpi_bus_init_power(struct acpi_device *device);
378int acpi_device_fix_up_power(struct acpi_device *device);
379int acpi_bus_update_power(acpi_handle handle, int *state_p); 379int acpi_bus_update_power(acpi_handle handle, int *state_p);
380bool acpi_bus_power_manageable(acpi_handle handle); 380bool acpi_bus_power_manageable(acpi_handle handle);
381
382#ifdef CONFIG_PM
381bool acpi_bus_can_wakeup(acpi_handle handle); 383bool acpi_bus_can_wakeup(acpi_handle handle);
382#else /* !CONFIG_PM */ 384#else
383static inline int acpi_bus_set_power(acpi_handle handle, int state) 385static inline bool acpi_bus_can_wakeup(acpi_handle handle) { return false; }
384{ 386#endif
385 return 0;
386}
387static inline const char *acpi_power_state_string(int state)
388{
389 return "D0";
390}
391static inline int acpi_device_get_power(struct acpi_device *device, int *state)
392{
393 return 0;
394}
395static inline int acpi_device_set_power(struct acpi_device *device, int state)
396{
397 return 0;
398}
399static inline int acpi_bus_init_power(struct acpi_device *device)
400{
401 return 0;
402}
403static inline int acpi_bus_update_power(acpi_handle handle, int *state_p)
404{
405 return 0;
406}
407static inline bool acpi_bus_power_manageable(acpi_handle handle)
408{
409 return false;
410}
411static inline bool acpi_bus_can_wakeup(acpi_handle handle)
412{
413 return false;
414}
415#endif /* !CONFIG_PM */
416 387
417#ifdef CONFIG_ACPI_PROC_EVENT 388#ifdef CONFIG_ACPI_PROC_EVENT
418int acpi_bus_generate_proc_event(struct acpi_device *device, u8 type, int data); 389int acpi_bus_generate_proc_event(struct acpi_device *device, u8 type, int data);
diff --git a/include/acpi/acpi_drivers.h b/include/acpi/acpi_drivers.h
index e6168a24b9f0..b420939f5eb5 100644
--- a/include/acpi/acpi_drivers.h
+++ b/include/acpi/acpi_drivers.h
@@ -123,7 +123,9 @@ extern int register_dock_notifier(struct notifier_block *nb);
123extern void unregister_dock_notifier(struct notifier_block *nb); 123extern void unregister_dock_notifier(struct notifier_block *nb);
124extern int register_hotplug_dock_device(acpi_handle handle, 124extern int register_hotplug_dock_device(acpi_handle handle,
125 const struct acpi_dock_ops *ops, 125 const struct acpi_dock_ops *ops,
126 void *context); 126 void *context,
127 void (*init)(void *),
128 void (*release)(void *));
127extern void unregister_hotplug_dock_device(acpi_handle handle); 129extern void unregister_hotplug_dock_device(acpi_handle handle);
128#else 130#else
129static inline int is_dock_device(acpi_handle handle) 131static inline int is_dock_device(acpi_handle handle)
@@ -139,7 +141,9 @@ static inline void unregister_dock_notifier(struct notifier_block *nb)
139} 141}
140static inline int register_hotplug_dock_device(acpi_handle handle, 142static inline int register_hotplug_dock_device(acpi_handle handle,
141 const struct acpi_dock_ops *ops, 143 const struct acpi_dock_ops *ops,
142 void *context) 144 void *context,
145 void (*init)(void *),
146 void (*release)(void *))
143{ 147{
144 return -ENODEV; 148 return -ENODEV;
145} 149}