summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMax Filippov <jcmvbkbc@gmail.com>2019-08-12 15:01:30 -0700
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2019-08-25 10:51:43 +0200
commitc6a46c615274da0cfb4090140ceea0427ae13e22 (patch)
tree0b31dbde2ec92f65f314c55c479eb61edf38f341
parent1922476beeeea46bebbe577215078736dd4231dc (diff)
downloadlinux-stable-c6a46c615274da0cfb4090140ceea0427ae13e22.tar.gz
linux-stable-c6a46c615274da0cfb4090140ceea0427ae13e22.tar.bz2
linux-stable-c6a46c615274da0cfb4090140ceea0427ae13e22.zip
xtensa: add missing isync to the cpu_reset TLB code
commit cd8869f4cb257f22b89495ca40f5281e58ba359c upstream. ITLB entry modifications must be followed by the isync instruction before the new entries are possibly used. cpu_reset lacks one isync between ITLB way 6 initialization and jump to the identity mapping. Add missing isync to xtensa cpu_reset. Cc: stable@vger.kernel.org Signed-off-by: Max Filippov <jcmvbkbc@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
-rw-r--r--arch/xtensa/kernel/setup.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/arch/xtensa/kernel/setup.c b/arch/xtensa/kernel/setup.c
index a45d32abea26..b9beae798d72 100644
--- a/arch/xtensa/kernel/setup.c
+++ b/arch/xtensa/kernel/setup.c
@@ -626,6 +626,7 @@ void cpu_reset(void)
"add %2, %2, %7\n\t"
"addi %0, %0, -1\n\t"
"bnez %0, 1b\n\t"
+ "isync\n\t"
/* Jump to identity mapping */
"jx %3\n"
"2:\n\t"