X-Git-Url: http://drtracing.org/?a=blobdiff_plain;f=include%2Facpi%2Facpi_bus.h;h=8ef68a16aa0352861608442789193648df9193ef;hb=761afb869f649ea23e2dea7bfe9b550d3a1b7631;hp=4de84ce3a927123f118861df950202a8dba1a536;hpb=cd07202cc8262e1669edff0d97715f3dd9260917;p=deliverable%2Flinux.git diff --git a/include/acpi/acpi_bus.h b/include/acpi/acpi_bus.h index 4de84ce3a927..8ef68a16aa03 100644 --- a/include/acpi/acpi_bus.h +++ b/include/acpi/acpi_bus.h @@ -389,21 +389,25 @@ struct acpi_pci_root *acpi_pci_find_root(acpi_handle handle); int acpi_enable_wakeup_device_power(struct acpi_device *dev, int state); int acpi_disable_wakeup_device_power(struct acpi_device *dev); -#ifdef CONFIG_PM_SLEEP +#ifdef CONFIG_PM_OPS int acpi_pm_device_sleep_state(struct device *, int *); -int acpi_pm_device_sleep_wake(struct device *, bool); -#else /* !CONFIG_PM_SLEEP */ +#else static inline int acpi_pm_device_sleep_state(struct device *d, int *p) { if (p) *p = ACPI_STATE_D0; return ACPI_STATE_D3; } +#endif + +#ifdef CONFIG_PM_SLEEP +int acpi_pm_device_sleep_wake(struct device *, bool); +#else static inline int acpi_pm_device_sleep_wake(struct device *dev, bool enable) { return -ENODEV; } -#endif /* !CONFIG_PM_SLEEP */ +#endif #endif /* CONFIG_ACPI */