mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-30 11:41:38 -04:00
x86-32, hibernate: Use temp_pgt as the temporary page table
This is to reuse the temp_pgt for both 32bit and 64bit system. No intentional behavior change. Signed-off-by: Zhimin Gu <[email protected]> Acked-by: Pavel Machek <[email protected]> Signed-off-by: Chen Yu <[email protected]> Acked-by: Thomas Gleixner <[email protected]> Signed-off-by: Rafael J. Wysocki <[email protected]>
This commit is contained in:
parent
72adf47764
commit
7c0a982750
2 changed files with 3 additions and 2 deletions
|
|
@ -156,6 +156,8 @@ asmlinkage int swsusp_arch_resume(void)
|
|||
if (error)
|
||||
return error;
|
||||
|
||||
temp_pgt = __pa(resume_pg_dir);
|
||||
|
||||
/* We have got enough memory and from now on we cannot recover */
|
||||
restore_image();
|
||||
return 0;
|
||||
|
|
|
|||
|
|
@ -33,8 +33,7 @@ ENDPROC(swsusp_arch_suspend)
|
|||
|
||||
ENTRY(restore_image)
|
||||
movl mmu_cr4_features, %ecx
|
||||
movl resume_pg_dir, %eax
|
||||
subl $__PAGE_OFFSET, %eax
|
||||
movl temp_pgt, %eax
|
||||
movl %eax, %cr3
|
||||
|
||||
jecxz 1f # cr4 Pentium and higher, skip if zero
|
||||
|
|
|
|||
Loading…
Reference in a new issue