Re: [PATCH 1/4] Hibernate: Call platform_begin before swsusp_shrink_memory

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi.

On Wed, 2008-10-22 at 22:50 +0200, Rafael J. Wysocki wrote:
> From: Zhang Rui <rui.zhang@xxxxxxxxx>
> 
> Hibernate: Call platform_begin before swsusp_shrink_memory
> 
> Call platform_begin() before swsusp_shrink_memory() so that we can
> always allocate enough memory to save the ACPI NVS region from
> platform_begin().
> 
> Signed-off-by: Zhang Rui <rui.zhang@xxxxxxxxx>
> Signed-off-by: Rafael J. Wysocki <rjw@xxxxxxx>
> ---
>  kernel/power/disk.c |    6 +++---
>  1 file changed, 3 insertions(+), 3 deletions(-)
> 
> Index: linux-2.6/kernel/power/disk.c
> ===================================================================
> --- linux-2.6.orig/kernel/power/disk.c
> +++ linux-2.6/kernel/power/disk.c
> @@ -267,12 +267,12 @@ int hibernation_snapshot(int platform_mo
>  {
>  	int error, ftrace_save;
>  
> -	/* Free memory before shutting down devices. */
> -	error = swsusp_shrink_memory();
> +	error = platform_begin(platform_mode);
>  	if (error)
>  		return error;
>  
> -	error = platform_begin(platform_mode);
> +	/* Free memory before shutting down devices. */
> +	error = swsusp_shrink_memory();
>  	if (error)
>  		goto Close;
>  

Acked-by: Nigel Cunningham <nigel@xxxxxxxxxxxx>

_______________________________________________
linux-pm mailing list
linux-pm@xxxxxxxxxxxxxxxxxxxxxxxxxx
https://lists.linux-foundation.org/mailman/listinfo/linux-pm

[Index of Archives]     [Linux ACPI]     [Netdev]     [Ethernet Bridging]     [Linux Wireless]     [CPU Freq]     [Kernel Newbies]     [Fedora Kernel]     [Security]     [Linux for Hams]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux RAID]     [Linux Admin]     [Samba]

  Powered by Linux