[v2,0/2] Fixes to the hibernate_preallocate_memory()

Message ID 20221104054119.1946073-1-tgsp002@gmail.com
Headers
Series Fixes to the hibernate_preallocate_memory() |

Message

TGSP Nov. 4, 2022, 5:41 a.m. UTC
  Changes in v2:
- Optimize code to resolve compilation warnings;
- Add comments, add debug data, easy to view and modify.

v1:
hibernate_preallocate_memory() function is still quite obscure, can
anyone add a little more description?

It seems that the max_size calculation formula is wrong in the comment
part, correct it;

It is also found that when mem preallocate is not enough, it goes
directly down without checking.

xiongxin (2):
  PM: hibernate: fix spelling mistake for annotation
  PM: hibernate: add check of preallocate mem for image size pages

 kernel/power/snapshot.c | 15 +++++++++++----
 1 file changed, 11 insertions(+), 4 deletions(-)