(cc'ing the Linux ARM kernel list) On 25 October 2013 05:54, T.J. Purtell <t...@mobisocial.us> wrote: > The ARM architecture reference specifies that the IT state bits in the > PSR must be all zeros in ARM mode or behavior is unspecified. On the > Qualcomm Snapdragon S4/Krait architecture CPUs the processor continues > to consider the IT state bits while in ARM mode. This makes it so > that some instructions are skipped by the CPU.
Good catch. > diff --git a/arch/arm64/kernel/signal32.c b/arch/arm64/kernel/signal32.c > index e393174..8f6c3be 100644 > --- a/arch/arm64/kernel/signal32.c > +++ b/arch/arm64/kernel/signal32.c > @@ -474,9 +474,11 @@ static void compat_setup_return(struct pt_regs > *regs, struct k_sigaction *ka, > /* Check if the handler is written for ARM or Thumb */ > thumb = handler & 1; > > + /* ARM spec requires this to be all 000s in ARM mode */ > + spsr &= ~COMPAT_PSR_IT_MASK; > + > if (thumb) { > spsr |= COMPAT_PSR_T_BIT; > - spsr &= ~COMPAT_PSR_IT_MASK; > } else { > spsr &= ~COMPAT_PSR_T_BIT; > } Please send me a separate arm64 patch, I'll push it via my tree (and cc stable as well). Catalin -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/