Here is a least intrusive patch by my opinion...
Just copy pm_disk_mode from pm_ops supplied by platform.
ACPI sets it to PM_DISK_PLATFORM if it has S4,
and it should be zero otherwise, patch does not copy it then.
Regards,
Alex.
Yu, Luming wrote:
>> There is a problem with swsuspend and GPE events.
>> Now they are restored from acpi_pm_finish(), which is called only if we
>> suspend with "platform" option, what means that if we suspended to disk
>> with the default "shutdown" option after resume all the GPEs
>> will be disabled.
>> This presents us with the overheating problem after resume at
>> very least.
>> I see two solutions: one is to make "platform" to be default
>> option if ACPI is enabled,
>> and second -- enable GPE events from some other function,
>> which will be called in any case.
>>
>> What do you think?
>>
>
> I prefer platform S4 as default...
>
> --Luming
> -
> To unsubscribe from this list: send the line "unsubscribe linux-acpi" in
> the body of a message to [EMAIL PROTECTED]
> More majordomo info at http://vger.kernel.org/majordomo-info.html
>
Copy non-null pm_disk_mode option from pm_ops.
From: Alexey Starikovskiy <[EMAIL PROTECTED]>
---
kernel/power/main.c | 2 ++
1 files changed, 2 insertions(+), 0 deletions(-)
diff --git a/kernel/power/main.c b/kernel/power/main.c
index 873228c..2085611 100644
--- a/kernel/power/main.c
+++ b/kernel/power/main.c
@@ -38,6 +38,8 @@ void pm_set_ops(struct pm_ops * ops)
{
down(&pm_sem);
pm_ops = ops;
+ if (pm_ops && pm_ops->pm_disk_mode)
+ pm_disk_mode = pm_ops->pm_disk_mode;
up(&pm_sem);
}