Merge tag 'pinctrl-v4.3-1' of git://git.kernel.org/pub/scm/linux/kernel/git/linusw...
[firefly-linux-kernel-4.4.55.git] / arch / arm / mm / abort-macro.S
index 2cbf68ef0e8321121e5ecabb55f50f95083beb1d..4509bee4e081ce78f95bcd99cd890468d97a5d8c 100644 (file)
@@ -13,6 +13,7 @@
        tst     \psr, #PSR_T_BIT
        beq     not_thumb
        ldrh    \tmp, [\pc]                     @ Read aborted Thumb instruction
+       uaccess_disable ip                      @ disable userspace access
        and     \tmp, \tmp, # 0xfe00            @ Mask opcode field
        cmp     \tmp, # 0x5600                  @ Is it ldrsb?
        orreq   \tmp, \tmp, #1 << 11            @ Set L-bit if yes
@@ -29,12 +30,9 @@ not_thumb:
  *   [7:4] == 1101
  *    [20] == 0
  */
-       .macro  do_ldrd_abort, tmp, insn
-       tst     \insn, #0x0e100000              @ [27:25,20] == 0
-       bne     not_ldrd
-       and     \tmp, \insn, #0x000000f0        @ [7:4] == 1101
-       cmp     \tmp, #0x000000d0
-       beq     do_DataAbort
-not_ldrd:
+       .macro  teq_ldrd, tmp, insn
+       mov     \tmp, #0x0e100000
+       orr     \tmp, #0x000000f0
+       and     \tmp, \insn, \tmp
+       teq     \tmp, #0x000000d0
        .endm
-