diff options
Diffstat (limited to 'include/linux/acpi.h')
-rw-r--r-- | include/linux/acpi.h | 26 |
1 files changed, 11 insertions, 15 deletions
diff --git a/include/linux/acpi.h b/include/linux/acpi.h index d7a5fcf9ef0f..6bff83b1f298 100644 --- a/include/linux/acpi.h +++ b/include/linux/acpi.h | |||
@@ -572,16 +572,26 @@ static inline void arch_reserve_mem_area(acpi_physical_address addr, | |||
572 | #define acpi_os_set_prepare_sleep(func, pm1a_ctrl, pm1b_ctrl) do { } while (0) | 572 | #define acpi_os_set_prepare_sleep(func, pm1a_ctrl, pm1b_ctrl) do { } while (0) |
573 | #endif | 573 | #endif |
574 | 574 | ||
575 | #if defined(CONFIG_ACPI) && defined(CONFIG_PM_RUNTIME) | 575 | #if defined(CONFIG_ACPI) && defined(CONFIG_PM) |
576 | int acpi_dev_runtime_suspend(struct device *dev); | 576 | int acpi_dev_runtime_suspend(struct device *dev); |
577 | int acpi_dev_runtime_resume(struct device *dev); | 577 | int acpi_dev_runtime_resume(struct device *dev); |
578 | int acpi_subsys_runtime_suspend(struct device *dev); | 578 | int acpi_subsys_runtime_suspend(struct device *dev); |
579 | int acpi_subsys_runtime_resume(struct device *dev); | 579 | int acpi_subsys_runtime_resume(struct device *dev); |
580 | struct acpi_device *acpi_dev_pm_get_node(struct device *dev); | ||
581 | int acpi_dev_pm_attach(struct device *dev, bool power_on); | ||
580 | #else | 582 | #else |
581 | static inline int acpi_dev_runtime_suspend(struct device *dev) { return 0; } | 583 | static inline int acpi_dev_runtime_suspend(struct device *dev) { return 0; } |
582 | static inline int acpi_dev_runtime_resume(struct device *dev) { return 0; } | 584 | static inline int acpi_dev_runtime_resume(struct device *dev) { return 0; } |
583 | static inline int acpi_subsys_runtime_suspend(struct device *dev) { return 0; } | 585 | static inline int acpi_subsys_runtime_suspend(struct device *dev) { return 0; } |
584 | static inline int acpi_subsys_runtime_resume(struct device *dev) { return 0; } | 586 | static inline int acpi_subsys_runtime_resume(struct device *dev) { return 0; } |
587 | static inline struct acpi_device *acpi_dev_pm_get_node(struct device *dev) | ||
588 | { | ||
589 | return NULL; | ||
590 | } | ||
591 | static inline int acpi_dev_pm_attach(struct device *dev, bool power_on) | ||
592 | { | ||
593 | return -ENODEV; | ||
594 | } | ||
585 | #endif | 595 | #endif |
586 | 596 | ||
587 | #if defined(CONFIG_ACPI) && defined(CONFIG_PM_SLEEP) | 597 | #if defined(CONFIG_ACPI) && defined(CONFIG_PM_SLEEP) |
@@ -604,20 +614,6 @@ static inline int acpi_subsys_suspend(struct device *dev) { return 0; } | |||
604 | static inline int acpi_subsys_freeze(struct device *dev) { return 0; } | 614 | static inline int acpi_subsys_freeze(struct device *dev) { return 0; } |
605 | #endif | 615 | #endif |
606 | 616 | ||
607 | #if defined(CONFIG_ACPI) && defined(CONFIG_PM) | ||
608 | struct acpi_device *acpi_dev_pm_get_node(struct device *dev); | ||
609 | int acpi_dev_pm_attach(struct device *dev, bool power_on); | ||
610 | #else | ||
611 | static inline struct acpi_device *acpi_dev_pm_get_node(struct device *dev) | ||
612 | { | ||
613 | return NULL; | ||
614 | } | ||
615 | static inline int acpi_dev_pm_attach(struct device *dev, bool power_on) | ||
616 | { | ||
617 | return -ENODEV; | ||
618 | } | ||
619 | #endif | ||
620 | |||
621 | #ifdef CONFIG_ACPI | 617 | #ifdef CONFIG_ACPI |
622 | __printf(3, 4) | 618 | __printf(3, 4) |
623 | void acpi_handle_printk(const char *level, acpi_handle handle, | 619 | void acpi_handle_printk(const char *level, acpi_handle handle, |