From: Nicholas Piggin Date: Thu, 5 Apr 2018 06:10:00 +0000 (+1000) Subject: powerpc/64s/idle: Fix restore of AMOR on POWER9 after deep sleep X-Git-Tag: v4.14.45~154 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=be6a5ad51a53a467fe9f5abac823143483cde392;p=platform%2Fkernel%2Flinux-rpi.git powerpc/64s/idle: Fix restore of AMOR on POWER9 after deep sleep [ Upstream commit c1b25a17d24925b0961c319cfc3fd7e1dc778914 ] POWER8 restores AMOR when waking from deep sleep, but POWER9 does not, because it does not go through the subcore restore. Have POWER9 restore it in core restore. Fixes: ee97b6b99f42 ("powerpc/mm/radix: Setup AMOR in HV mode to allow key 0") Signed-off-by: Nicholas Piggin Signed-off-by: Michael Ellerman Signed-off-by: Sasha Levin Signed-off-by: Greg Kroah-Hartman --- diff --git a/arch/powerpc/kernel/idle_book3s.S b/arch/powerpc/kernel/idle_book3s.S index 1125c9b..e35cebd 100644 --- a/arch/powerpc/kernel/idle_book3s.S +++ b/arch/powerpc/kernel/idle_book3s.S @@ -838,6 +838,8 @@ BEGIN_FTR_SECTION mtspr SPRN_PTCR,r4 ld r4,_RPR(r1) mtspr SPRN_RPR,r4 + ld r4,_AMOR(r1) + mtspr SPRN_AMOR,r4 END_FTR_SECTION_IFSET(CPU_FTR_ARCH_300) ld r4,_TSCR(r1)