[PATCH][v3] PPC: use CURRENT_THREAD_INFO instead of open coded assembly
Benjamin Herrenschmidt
benh at kernel.crashing.org
Wed Jul 4 13:04:57 EST 2012
On Tue, 2012-07-03 at 10:11 -0500, Stuart Yoder wrote:
> From: Stuart Yoder <stuart.yoder at freescale.com>
>
> Signed-off-by: Stuart Yoder <stuart.yoder at freescale.com>
> ---
>
> -v3
> -moved CURRENT_THREAD_INFO out from under the assembly only
> #define as per comments on mailing list
> -reversed logic of 64-bit #ifdef for CURRENT_THREAD_INFO
> macro
Almost there :-)
> #define RUNLATCH_ON \
> BEGIN_FTR_SECTION \
> - clrrdi r3,r1,THREAD_SHIFT; \
> + CURRENT_THREAD_INFO(r3, r1) \
Missing semicolon (in a macro you need it)
> ld r4,TI_LOCAL_FLAGS(r3); \
> andi. r0,r4,_TLF_RUNLATCH; \
> beql ppc64_runlatch_on_trampoline; \
> @@ -332,7 +332,7 @@ label##_common: \
> #ifdef CONFIG_PPC_970_NAP
> #define FINISH_NAP \
> BEGIN_FTR_SECTION \
> - clrrdi r11,r1,THREAD_SHIFT; \
> + CURRENT_THREAD_INFO(r11, r1) \
Same
> --- a/arch/powerpc/kernel/exceptions-64e.S
> +++ b/arch/powerpc/kernel/exceptions-64e.S
> @@ -222,7 +222,7 @@ exc_##n##_bad_stack: \
> * interrupts happen before the wait instruction.
> */
> #define CHECK_NAPPING() \
> - clrrdi r11,r1,THREAD_SHIFT; \
> + CURRENT_THREAD_INFO(r11, r1)
Missing both semicolon and backslash
Cheers,
Ben.
More information about the Linuxppc-dev
mailing list