From: Pavel Tatashin Date: Wed, 4 Dec 2019 15:59:18 +0000 (-0500) Subject: arm64: hibernate: pass the allocated pgdp to ttbr0 X-Git-Tag: v5.10.7~3440^2~4^7~6 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=d234332c281533a46e77dceff3901ef63e546cce;p=platform%2Fkernel%2Flinux-rpi.git arm64: hibernate: pass the allocated pgdp to ttbr0 ttbr0 should be set to the beginning of pgdp, however, currently in create_safe_exec_page it is set to pgdp after pgd_offset_raw(), which works by accident. Signed-off-by: Pavel Tatashin Reviewed-by: James Morse Signed-off-by: Will Deacon --- diff --git a/arch/arm64/kernel/hibernate.c b/arch/arm64/kernel/hibernate.c index a96b292..ef46ce6 100644 --- a/arch/arm64/kernel/hibernate.c +++ b/arch/arm64/kernel/hibernate.c @@ -269,7 +269,7 @@ static int create_safe_exec_page(void *src_start, size_t length, */ cpu_set_reserved_ttbr0(); local_flush_tlb_all(); - write_sysreg(phys_to_ttbr(virt_to_phys(pgdp)), ttbr0_el1); + write_sysreg(phys_to_ttbr(virt_to_phys(trans_pgd)), ttbr0_el1); isb(); *phys_dst_addr = virt_to_phys((void *)dst);