diff mbox series

[12/12,RFC,v3] x86-32, hibernate: Adjust in_suspend after resumed on 32bit system

Message ID e2b157a14ddadb557c07ed2e081637c0e1dbff5e.1537275915.git.yu.c.chen@intel.com (mailing list archive)
State Changes Requested, archived
Headers show
Series Backport several fixes from 64bits to 32bits hibernation | expand

Commit Message

Chen Yu Sept. 19, 2018, 7:43 a.m. UTC
From: Zhimin Gu <kookoo.gu@intel.com>

Update the in_suspend variable to reflect the actual hibernation
status. Back-port from 64bit system.

Cc: "Rafael J. Wysocki" <rjw@rjwysocki.net>
Signed-off-by: Zhimin Gu <kookoo.gu@intel.com>
Signed-off-by: Chen Yu <yu.c.chen@intel.com>
---
 arch/x86/power/hibernate_asm_32.S | 3 +++
 1 file changed, 3 insertions(+)

Comments

Pavel Machek Sept. 20, 2018, 10:06 p.m. UTC | #1
On Wed 2018-09-19 15:43:42, Chen Yu wrote:
> From: Zhimin Gu <kookoo.gu@intel.com>
> 
> Update the in_suspend variable to reflect the actual hibernation
> status. Back-port from 64bit system.
> 
> Cc: "Rafael J. Wysocki" <rjw@rjwysocki.net>
> Signed-off-by: Zhimin Gu <kookoo.gu@intel.com>
> Signed-off-by: Chen Yu <yu.c.chen@intel.com>

Acked-by: Pavel Machek <pavel@ucw.cz>
diff mbox series

Patch

diff --git a/arch/x86/power/hibernate_asm_32.S b/arch/x86/power/hibernate_asm_32.S
index 01f653fae7bd..6fe383002125 100644
--- a/arch/x86/power/hibernate_asm_32.S
+++ b/arch/x86/power/hibernate_asm_32.S
@@ -103,5 +103,8 @@  ENTRY(restore_registers)
 
 	xorl	%eax, %eax
 
+	/* tell the hibernation core that we've just restored the memory */
+	movl	%eax, in_suspend
+
 	ret
 ENDPROC(restore_registers)