mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-30 11:41:38 -04:00
PM / Hibernate: allow hibernation with PAGE_POISONING_ZERO
PAGE_POISONING_ZERO disables zeroing new pages on alloc, they are poisoned (zeroed) as they become available. In the hibernate use case, free pages will appear in the system without being cleared, left there by the loading kernel. This patch will make sure free pages are cleared on resume when PAGE_POISONING_ZERO is enabled. We free the pages just after resume because we can't do it later: going through any device resume code might allocate some memory and invalidate the free pages bitmap. Thus we don't need to disable hibernation when PAGE_POISONING_ZERO is enabled. Signed-off-by: Anisse Astier <[email protected]> Reviewed-by: Kees Cook <[email protected]> Acked-by: Pavel Machek <[email protected]> Signed-off-by: Rafael J. Wysocki <[email protected]>
This commit is contained in:
parent
fa7fd6fa38
commit
1ad1410f63
4 changed files with 27 additions and 20 deletions
|
|
@ -76,8 +76,6 @@ config PAGE_POISONING_ZERO
|
|||
no longer necessary to write zeros when GFP_ZERO is used on
|
||||
allocation.
|
||||
|
||||
Enabling page poisoning with this option will disable hibernation
|
||||
|
||||
If unsure, say N
|
||||
bool
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue