mirror of
https://github.com/Fishwaldo/Star64_linux.git
synced 2025-07-23 07:12:09 +00:00
powerpc: Rewrite 4xx flush_cache_instruction() in C
Nothing prevents flush_cache_instruction() from being writen in C. Do it to improve readability and maintainability. This function is very small and isn't called from assembly, make it static inline in asm/cacheflush.h Signed-off-by: Christophe Leroy <christophe.leroy@csgroup.eu> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> Link: https://lore.kernel.org/r/93d93fc69b4b3ad3ceba2fc0756333c0c0245bb7.1597384512.git.christophe.leroy@csgroup.eu
This commit is contained in:
parent
f663f33120
commit
de39b19452
2 changed files with 9 additions and 6 deletions
|
@ -98,7 +98,15 @@ static inline void invalidate_dcache_range(unsigned long start,
|
|||
mb(); /* sync */
|
||||
}
|
||||
|
||||
#ifdef CONFIG_4xx
|
||||
static inline void flush_instruction_cache(void)
|
||||
{
|
||||
iccci((void *)KERNELBASE);
|
||||
isync();
|
||||
}
|
||||
#else
|
||||
void flush_instruction_cache(void);
|
||||
#endif
|
||||
|
||||
#include <asm-generic/cacheflush.h>
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue