summaryrefslogtreecommitdiff
path: root/arch/arm64
diff options
context:
space:
mode:
authorAndrey Konovalov <andrey.konovalov@linaro.org>2015-08-28 01:51:03 +0300
committerAndrey Konovalov <andrey.konovalov@linaro.org>2015-08-28 01:51:03 +0300
commitd4d9228040516280b5e09d3e495797d757a5bd91 (patch)
treed2bdb7d81ec9feae10f3e1283f86dc6fe3964c83 /arch/arm64
parenta4504697879fede7d961004556536fc8e51c1255 (diff)
parent230b22d72454f0b9ed2cf1410771bbba7830f89e (diff)
Automatically merging tracking-llvm into merge-linux-linaro
Conflicting files:
Diffstat (limited to 'arch/arm64')
-rw-r--r--arch/arm64/crypto/Makefile2
-rw-r--r--arch/arm64/include/asm/futex.h3
-rw-r--r--arch/arm64/include/asm/processor.h4
3 files changed, 5 insertions, 4 deletions
diff --git a/arch/arm64/crypto/Makefile b/arch/arm64/crypto/Makefile
index abb79b3cfcfe..574851096072 100644
--- a/arch/arm64/crypto/Makefile
+++ b/arch/arm64/crypto/Makefile
@@ -18,7 +18,7 @@ obj-$(CONFIG_CRYPTO_GHASH_ARM64_CE) += ghash-ce.o
ghash-ce-y := ghash-ce-glue.o ghash-ce-core.o
obj-$(CONFIG_CRYPTO_AES_ARM64_CE) += aes-ce-cipher.o
-CFLAGS_aes-ce-cipher.o += -march=armv8-a+crypto
+CFLAGS_aes-ce-cipher.o += -march=armv8-a+crypto -Wa,-march=armv8-a+crypto
obj-$(CONFIG_CRYPTO_AES_ARM64_CE_CCM) += aes-ce-ccm.o
aes-ce-ccm-y := aes-ce-ccm-glue.o aes-ce-ccm-core.o
diff --git a/arch/arm64/include/asm/futex.h b/arch/arm64/include/asm/futex.h
index 74069b3bd919..2716d3a83787 100644
--- a/arch/arm64/include/asm/futex.h
+++ b/arch/arm64/include/asm/futex.h
@@ -108,7 +108,8 @@ futex_atomic_cmpxchg_inatomic(u32 *uval, u32 __user *uaddr,
int ret = 0;
u32 val, tmp;
- if (!access_ok(VERIFY_WRITE, uaddr, sizeof(u32)))
+ /* compiler may optimize uaddr to xzr if all uses are 0 which fails */
+ if (uaddr == 0 || !access_ok(VERIFY_WRITE, uaddr, sizeof(u32)))
return -EFAULT;
asm volatile("// futex_atomic_cmpxchg_inatomic\n"
diff --git a/arch/arm64/include/asm/processor.h b/arch/arm64/include/asm/processor.h
index e4c893e54f01..0eac06e3a5e3 100644
--- a/arch/arm64/include/asm/processor.h
+++ b/arch/arm64/include/asm/processor.h
@@ -167,13 +167,13 @@ extern struct task_struct *cpu_switch_to(struct task_struct *prev,
#define ARCH_HAS_PREFETCH
static inline void prefetch(const void *ptr)
{
- asm volatile("prfm pldl1keep, %a0\n" : : "p" (ptr));
+ asm volatile("prfm pldl1keep, [%x0]\n" : : "r" (ptr));
}
#define ARCH_HAS_PREFETCHW
static inline void prefetchw(const void *ptr)
{
- asm volatile("prfm pstl1keep, %a0\n" : : "p" (ptr));
+ asm volatile("prfm pstl1keep, [%x0]\n" : : "r" (ptr));
}
#define ARCH_HAS_SPINLOCK_PREFETCH