powerpc/32s: get rid of CPU_FTR_601 feature
Now that 601 is exclusive from other 6xx, CPU_FTR_601 and associated fixups are useless. Drop this feature and use #ifdefs instead. Signed-off-by: Christophe Leroy <christophe.leroy@c-s.fr> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> Link: https://lore.kernel.org/r/ecdb7194a17dbfa01865df6a82979533adc2c70b.1566834712.git.christophe.leroy@c-s.fr
This commit is contained in:

committed by
Michael Ellerman

parent
f7a0bf7d90
commit
12c3f1fd87
@@ -17,38 +17,10 @@ typedef unsigned long cycles_t;
|
||||
|
||||
static inline cycles_t get_cycles(void)
|
||||
{
|
||||
#ifdef __powerpc64__
|
||||
if (IS_ENABLED(CONFIG_BOOK3S_601))
|
||||
return 0;
|
||||
|
||||
return mftb();
|
||||
#else
|
||||
cycles_t ret;
|
||||
|
||||
/*
|
||||
* For the "cycle" counter we use the timebase lower half.
|
||||
* Currently only used on SMP.
|
||||
*/
|
||||
|
||||
ret = 0;
|
||||
|
||||
__asm__ __volatile__(
|
||||
#ifdef CONFIG_PPC_8xx
|
||||
"97: mftb %0\n"
|
||||
#else
|
||||
"97: mfspr %0, %2\n"
|
||||
#endif
|
||||
"99:\n"
|
||||
".section __ftr_fixup,\"a\"\n"
|
||||
".align 2\n"
|
||||
"98:\n"
|
||||
" .long %1\n"
|
||||
" .long 0\n"
|
||||
" .long 97b-98b\n"
|
||||
" .long 99b-98b\n"
|
||||
" .long 0\n"
|
||||
" .long 0\n"
|
||||
".previous"
|
||||
: "=r" (ret) : "i" (CPU_FTR_601), "i" (SPRN_TBRL));
|
||||
return ret;
|
||||
#endif
|
||||
}
|
||||
|
||||
#endif /* __KERNEL__ */
|
||||
|
Reference in New Issue
Block a user