powerpc/kernel: Use kprobe blacklist for asm functions
Rather than forcing the whole function into the ".kprobes.text" section, just add the symbol's address to the kprobe blacklist. This also lets us drop the three versions of the_KPROBE macro, in exchange for just one version of _ASM_NOKPROBE_SYMBOL - which is a good cleanup. Signed-off-by: Nicholas Piggin <npiggin@gmail.com> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au>
This commit is contained in:

committed by
Michael Ellerman

parent
03465f899b
commit
6f698df10c
@@ -328,7 +328,7 @@ END_FTR_SECTION_IFSET(CPU_FTR_UNIFIED_ID_CACHE)
|
||||
*
|
||||
* flush_icache_range(unsigned long start, unsigned long stop)
|
||||
*/
|
||||
_KPROBE(flush_icache_range)
|
||||
_GLOBAL(flush_icache_range)
|
||||
BEGIN_FTR_SECTION
|
||||
PURGE_PREFETCHED_INS
|
||||
blr /* for 601, do nothing */
|
||||
@@ -358,6 +358,8 @@ END_FTR_SECTION_IFSET(CPU_FTR_COHERENT_ICACHE)
|
||||
sync /* additional sync needed on g4 */
|
||||
isync
|
||||
blr
|
||||
_ASM_NOKPROBE_SYMBOL(flush_icache_range)
|
||||
|
||||
/*
|
||||
* Flush a particular page from the data cache to RAM.
|
||||
* Note: this is necessary because the instruction cache does *not*
|
||||
|
@@ -66,7 +66,7 @@ PPC64_CACHES:
|
||||
* flush all bytes from start through stop-1 inclusive
|
||||
*/
|
||||
|
||||
_KPROBE(flush_icache_range)
|
||||
_GLOBAL(flush_icache_range)
|
||||
BEGIN_FTR_SECTION
|
||||
PURGE_PREFETCHED_INS
|
||||
blr
|
||||
@@ -109,7 +109,8 @@ END_FTR_SECTION_IFSET(CPU_FTR_COHERENT_ICACHE)
|
||||
bdnz 2b
|
||||
isync
|
||||
blr
|
||||
.previous .text
|
||||
_ASM_NOKPROBE_SYMBOL(flush_icache_range)
|
||||
|
||||
/*
|
||||
* Like above, but only do the D-cache.
|
||||
*
|
||||
|
Reference in New Issue
Block a user