提交 3fe0313e 编写于 作者: Z Zhang Rui 提交者: Len Brown

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: NZhang Rui <rui.zhang@intel.com>
Acked-by: NNigel Cunningham <nigel@tuxonice.net>
Acked-by: NPavel Machek <pavel@suse.cz>
Signed-off-by: NRafael J. Wysocki <rjw@sisk.pl>
Signed-off-by: NLen Brown <len.brown@intel.com>
上级 929096fe
......@@ -259,12 +259,12 @@ int hibernation_snapshot(int platform_mode)
{
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;
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册