mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-29 11:11:45 -04:00
Merge branch 'acpi-pm'
* acpi-pm: PM / core: Drop run_wake flag from struct dev_pm_info PCI / PM: Simplify device wakeup settings code PCI / PM: Drop pme_interrupt flag from struct pci_dev ACPI / PM: Consolidate device wakeup settings code ACPI / PM: Drop run_wake from struct acpi_device_wakeup_flags ACPI / sleep: EC-based wakeup from suspend-to-idle on recent systems platform: x86: intel-hid: Wake up the system from suspend-to-idle platform: x86: intel-vbtn: Wake up the system from suspend-to-idle ACPI / PM: Ignore spurious SCI wakeups from suspend-to-idle platform/x86: Add driver for ACPI INT0002 Virtual GPIO device PCI / PM: Restore PME Enable if skipping wakeup setup PM / sleep: Print timing information if debug is enabled ACPI / PM: Clean up device wakeup enable/disable code ACPI / PM: Change log level of wakeup-related message USB / PCI / PM: Allow the PCI core to do the resume cleanup ACPI / PM: Run wakeup notify handlers synchronously Conflicts: drivers/base/power/main.c
This commit is contained in:
commit
8f8e5c3e27
35 changed files with 669 additions and 301 deletions
|
|
@ -315,13 +315,12 @@ struct acpi_device_perf {
|
|||
/* Wakeup Management */
|
||||
struct acpi_device_wakeup_flags {
|
||||
u8 valid:1; /* Can successfully enable wakeup? */
|
||||
u8 run_wake:1; /* Run-Wake GPE devices */
|
||||
u8 notifier_present:1; /* Wake-up notify handler has been installed */
|
||||
u8 enabled:1; /* Enabled for wakeup */
|
||||
};
|
||||
|
||||
struct acpi_device_wakeup_context {
|
||||
struct work_struct work;
|
||||
void (*func)(struct acpi_device_wakeup_context *context);
|
||||
struct device *dev;
|
||||
};
|
||||
|
||||
|
|
@ -600,15 +599,20 @@ static inline bool acpi_device_always_present(struct acpi_device *adev)
|
|||
#endif
|
||||
|
||||
#ifdef CONFIG_PM
|
||||
void acpi_pm_wakeup_event(struct device *dev);
|
||||
acpi_status acpi_add_pm_notifier(struct acpi_device *adev, struct device *dev,
|
||||
void (*work_func)(struct work_struct *work));
|
||||
void (*func)(struct acpi_device_wakeup_context *context));
|
||||
acpi_status acpi_remove_pm_notifier(struct acpi_device *adev);
|
||||
bool acpi_pm_device_can_wakeup(struct device *dev);
|
||||
int acpi_pm_device_sleep_state(struct device *, int *, int);
|
||||
int acpi_pm_device_run_wake(struct device *, bool);
|
||||
int acpi_pm_set_device_wakeup(struct device *dev, bool enable);
|
||||
#else
|
||||
static inline void acpi_pm_wakeup_event(struct device *dev)
|
||||
{
|
||||
}
|
||||
static inline acpi_status acpi_add_pm_notifier(struct acpi_device *adev,
|
||||
struct device *dev,
|
||||
void (*work_func)(struct work_struct *work))
|
||||
void (*func)(struct acpi_device_wakeup_context *context))
|
||||
{
|
||||
return AE_SUPPORT;
|
||||
}
|
||||
|
|
@ -616,6 +620,10 @@ static inline acpi_status acpi_remove_pm_notifier(struct acpi_device *adev)
|
|||
{
|
||||
return AE_SUPPORT;
|
||||
}
|
||||
static inline bool acpi_pm_device_can_wakeup(struct device *dev)
|
||||
{
|
||||
return false;
|
||||
}
|
||||
static inline int acpi_pm_device_sleep_state(struct device *d, int *p, int m)
|
||||
{
|
||||
if (p)
|
||||
|
|
@ -624,16 +632,7 @@ static inline int acpi_pm_device_sleep_state(struct device *d, int *p, int m)
|
|||
return (m >= ACPI_STATE_D0 && m <= ACPI_STATE_D3_COLD) ?
|
||||
m : ACPI_STATE_D0;
|
||||
}
|
||||
static inline int acpi_pm_device_run_wake(struct device *dev, bool enable)
|
||||
{
|
||||
return -ENODEV;
|
||||
}
|
||||
#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)
|
||||
static inline int acpi_pm_set_device_wakeup(struct device *dev, bool enable)
|
||||
{
|
||||
return -ENODEV;
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in a new issue