Subject: Re: [PATCH] powerpc/32bit, PREEMPT:Load TI_FLAGS to check NEED_RESCHED

From: "tiejun.chen" <[email-masked]>
Date: Mon, 27 May 2013 15:18:42 +0800

On 05/27/2013 02:55 PM, Jain Priyanka-B32167 wrote:
>
> If we go some more lines up in the same file, the code is
>
> resume_kernel:
>          /* check current_thread_info, _TIF_EMULATE_STACK_STORE */
>          CURRENT_THREAD_INFO(r9, r1)
>          lwz     r8,TI_FLAGS(r9)
>          andis.  r8,r8,_TIF_EMULATE_STACK_STORE@h

Okay, but could you fix this directly like:

diff --git a/arch/powerpc/kernel/entry_32.S b/arch/powerpc/kernel/entry_32.S
index e514de5..4498467 100644
--- a/arch/powerpc/kernel/entry_32.S
+++ b/arch/powerpc/kernel/entry_32.S
@@ -851,7 +851,7 @@ resume_kernel:
         /* check current_thread_info, _TIF_EMULATE_STACK_STORE */
         CURRENT_THREAD_INFO(r9, r1)
         lwz     r8,TI_FLAGS(r9)
-       andis.  r8,r8,_TIF_EMULATE_STACK_STORE@h
+       andis.  r0,r8,_TIF_EMULATE_STACK_STORE@h
         beq+    1f

         addi    r8,r1,INT_FRAME_SIZE    /* Get the kprobed function entry */

Tiejun