summaryrefslogtreecommitdiff
path: root/arch/powerpc/lib/copypage_64.S
diff options
context:
space:
mode:
authorNicholas Piggin <npiggin@gmail.com>2018-02-20 22:08:26 +0300
committerMichael Ellerman <mpe@ellerman.id.au>2018-03-31 16:47:49 +0300
commit15a3204d24a3c01b116fb7c0692b7c670cac631d (patch)
treec5f46ce738a1044d00b647f0d967c336cc303c62 /arch/powerpc/lib/copypage_64.S
parentd50614fa45760f5ec1772509625e1bf4abe5d052 (diff)
downloadlinux-15a3204d24a3c01b116fb7c0692b7c670cac631d.tar.xz
powerpc/64s: Set assembler machine type to POWER4
Rather than override the machine type in .S code (which can hide wrong or ambiguous code generation for the target), set the type to power4 for all assembly. This also means we need to be careful not to build power4-only code when we're not building for Book3S, such as the "power7" versions of copyuser/page/memcpy. Signed-off-by: Nicholas Piggin <npiggin@gmail.com> [mpe: Fix Book3E build, don't build the "power7" variants for non-Book3S] Signed-off-by: Michael Ellerman <mpe@ellerman.id.au>
Diffstat (limited to 'arch/powerpc/lib/copypage_64.S')
-rw-r--r--arch/powerpc/lib/copypage_64.S2
1 files changed, 2 insertions, 0 deletions
diff --git a/arch/powerpc/lib/copypage_64.S b/arch/powerpc/lib/copypage_64.S
index 4bcc9e76fb55..8d5034f645f3 100644
--- a/arch/powerpc/lib/copypage_64.S
+++ b/arch/powerpc/lib/copypage_64.S
@@ -21,7 +21,9 @@ _GLOBAL_TOC(copy_page)
BEGIN_FTR_SECTION
lis r5,PAGE_SIZE@h
FTR_SECTION_ELSE
+#ifdef CONFIG_PPC_BOOK3S_64
b copypage_power7
+#endif
ALT_FTR_SECTION_END_IFCLR(CPU_FTR_VMX_COPY)
ori r5,r5,PAGE_SIZE@l
BEGIN_FTR_SECTION