summaryrefslogtreecommitdiffstats
path: root/arch/arm64/lib/copy_in_user.S
diff options
context:
space:
mode:
authorMark Rutland <mark.rutland@arm.com>2018-04-12 12:11:05 +0100
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2018-04-20 08:20:43 +0200
commit4504c5ccef54070bdc09f26a7fcb41a3f053ded0 (patch)
tree3b0f384c92d322231f66d59ee45c0f56f0b41137 /arch/arm64/lib/copy_in_user.S
parent4c03928fd68a710ec55b7a07a4e65d2f438a1256 (diff)
downloadlinux-stable-4504c5ccef54070bdc09f26a7fcb41a3f053ded0.tar.gz
linux-stable-4504c5ccef54070bdc09f26a7fcb41a3f053ded0.tar.bz2
linux-stable-4504c5ccef54070bdc09f26a7fcb41a3f053ded0.zip
arm64: uaccess: Mask __user pointers for __arch_{clear, copy_*}_user
From: Will Deacon <will.deacon@arm.com> commit f71c2ffcb20dd8626880747557014bb9a61eb90e upstream. Like we've done for get_user and put_user, ensure that user pointers are masked before invoking the underlying __arch_{clear,copy_*}_user operations. Signed-off-by: Will Deacon <will.deacon@arm.com> Signed-off-by: Catalin Marinas <catalin.marinas@arm.com> [v4.9: fixup for v4.9-style uaccess primitives] Signed-off-by: Mark Rutland <mark.rutland@arm.com> [v4.9 backport] Tested-by: Greg Hackmann <ghackmann@google.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'arch/arm64/lib/copy_in_user.S')
-rw-r--r--arch/arm64/lib/copy_in_user.S4
1 files changed, 2 insertions, 2 deletions
diff --git a/arch/arm64/lib/copy_in_user.S b/arch/arm64/lib/copy_in_user.S
index f7292dd08c84..841bf8f7fab7 100644
--- a/arch/arm64/lib/copy_in_user.S
+++ b/arch/arm64/lib/copy_in_user.S
@@ -67,7 +67,7 @@
.endm
end .req x5
-ENTRY(__copy_in_user)
+ENTRY(__arch_copy_in_user)
ALTERNATIVE("nop", __stringify(SET_PSTATE_PAN(0)), ARM64_ALT_PAN_NOT_UAO, \
CONFIG_ARM64_PAN)
add end, x0, x2
@@ -76,7 +76,7 @@ ALTERNATIVE("nop", __stringify(SET_PSTATE_PAN(1)), ARM64_ALT_PAN_NOT_UAO, \
CONFIG_ARM64_PAN)
mov x0, #0
ret
-ENDPROC(__copy_in_user)
+ENDPROC(__arch_copy_in_user)
.section .fixup,"ax"
.align 2