aboutsummaryrefslogtreecommitdiffstats
path: root/arch/powerpc/kernel/misc_64.S
diff options
context:
space:
mode:
authorKevin Hao <haokexin@gmail.com>2013-08-06 18:23:30 +0800
committerBenjamin Herrenschmidt <benh@kernel.crashing.org>2013-08-14 14:56:06 +1000
commitabb29c3bb13c7b747fae18b9c63b660529ccc612 (patch)
tree7db47abfcb4fd1ed18fc8942aeffed6ce176e0e5 /arch/powerpc/kernel/misc_64.S
parentpowerpc: Stop using non-architected shared_proc field in lppaca (diff)
downloadlinux-dev-abb29c3bb13c7b747fae18b9c63b660529ccc612.tar.xz
linux-dev-abb29c3bb13c7b747fae18b9c63b660529ccc612.zip
powerpc: Move the testing of CPU_FTR_COHERENT_ICACHE into __flush_icache_range
In function flush_icache_range(), we use cpu_has_feature() to test the feature bit of CPU_FTR_COHERENT_ICACHE. But this seems not optimal for two reasons: a) For ppc32, the function __flush_icache_range() already do this check with the macro END_FTR_SECTION_IFSET. b) Compare with the cpu_has_feature(), the method of using macro END_FTR_SECTION_IFSET will not introduce any runtime overhead. [And while at it, add the missing required isync] -- BenH Signed-off-by: Kevin Hao <haokexin@gmail.com> Signed-off-by: Benjamin Herrenschmidt <benh@kernel.crashing.org>
Diffstat (limited to 'arch/powerpc/kernel/misc_64.S')
-rw-r--r--arch/powerpc/kernel/misc_64.S4
1 files changed, 3 insertions, 1 deletions
diff --git a/arch/powerpc/kernel/misc_64.S b/arch/powerpc/kernel/misc_64.S
index 6820e45f557b..74d87f117566 100644
--- a/arch/powerpc/kernel/misc_64.S
+++ b/arch/powerpc/kernel/misc_64.S
@@ -68,7 +68,9 @@ PPC64_CACHES:
*/
_KPROBE(__flush_icache_range)
-
+BEGIN_FTR_SECTION
+ blr
+END_FTR_SECTION_IFSET(CPU_FTR_COHERENT_ICACHE)
/*
* Flush the data cache to memory
*