]> asedeno.scripts.mit.edu Git - linux.git/commitdiff
powerpc: move ASM_CONST and stringify_in_c() into asm-const.h
authorChristophe Leroy <christophe.leroy@c-s.fr>
Thu, 5 Jul 2018 16:24:57 +0000 (16:24 +0000)
committerMichael Ellerman <mpe@ellerman.id.au>
Mon, 30 Jul 2018 12:48:16 +0000 (22:48 +1000)
This patch moves ASM_CONST() and stringify_in_c() into
dedicated asm-const.h, then cleans all related inclusions.

Signed-off-by: Christophe Leroy <christophe.leroy@c-s.fr>
[mpe: asm-compat.h should include asm-const.h]
Signed-off-by: Michael Ellerman <mpe@ellerman.id.au>
57 files changed:
arch/powerpc/crypto/md5-asm.S
arch/powerpc/crypto/sha1-powerpc-asm.S
arch/powerpc/include/asm/asm-compat.h
arch/powerpc/include/asm/asm-const.h [new file with mode: 0644]
arch/powerpc/include/asm/barrier.h
arch/powerpc/include/asm/book3s/64/hash.h
arch/powerpc/include/asm/book3s/64/mmu-hash.h
arch/powerpc/include/asm/book3s/64/radix.h
arch/powerpc/include/asm/cmpxchg.h
arch/powerpc/include/asm/code-patching.h
arch/powerpc/include/asm/cputable.h
arch/powerpc/include/asm/dt_cpu_ftrs.h
arch/powerpc/include/asm/feature-fixups.h
arch/powerpc/include/asm/firmware.h
arch/powerpc/include/asm/futex.h
arch/powerpc/include/asm/iommu.h
arch/powerpc/include/asm/jump_label.h
arch/powerpc/include/asm/mmu-44x.h
arch/powerpc/include/asm/mmu.h
arch/powerpc/include/asm/nohash/64/pgtable.h
arch/powerpc/include/asm/page.h
arch/powerpc/include/asm/page_64.h
arch/powerpc/include/asm/ppc-opcode.h
arch/powerpc/include/asm/ptrace.h
arch/powerpc/include/asm/reg.h
arch/powerpc/include/asm/reg_a2.h
arch/powerpc/include/asm/spinlock.h
arch/powerpc/include/asm/synch.h
arch/powerpc/include/asm/thread_info.h
arch/powerpc/include/asm/uaccess.h
arch/powerpc/kernel/entry_64.S
arch/powerpc/kernel/fpu.S
arch/powerpc/kernel/idle_book3s.S
arch/powerpc/kernel/kvm_emul.S
arch/powerpc/kernel/ppc_save_regs.S
arch/powerpc/kernel/vector.S
arch/powerpc/kvm/book3s_64_slb.S
arch/powerpc/kvm/book3s_hv_interrupts.S
arch/powerpc/kvm/book3s_hv_rmhandlers.S
arch/powerpc/kvm/book3s_interrupts.S
arch/powerpc/kvm/book3s_rmhandlers.S
arch/powerpc/kvm/book3s_segment.S
arch/powerpc/lib/copyuser_64.S
arch/powerpc/lib/feature-fixups-test.S
arch/powerpc/lib/ldstfp.S
arch/powerpc/lib/memcpy_64.S
arch/powerpc/mm/tlb_nohash_low.S
arch/powerpc/net/bpf_jit32.h
arch/powerpc/net/bpf_jit_asm.S
arch/powerpc/net/bpf_jit_comp.c
arch/powerpc/net/bpf_jit_comp64.c
arch/powerpc/platforms/powernv/opal-wrappers.S
arch/powerpc/platforms/pseries/setup.c
arch/powerpc/purgatory/trampoline.S
arch/powerpc/xmon/spr_access.S
tools/testing/selftests/powerpc/copyloops/asm/asm-compat.h [new file with mode: 0644]
tools/testing/selftests/powerpc/primitives/asm/asm-const.h [new symlink]

index 10cdf5bceebbaf6eb468f75b98f2144502d99efe..1834065362c72fbfd0df023224c25e6181a24ed0 100644 (file)
@@ -11,6 +11,7 @@
  */
 #include <asm/ppc_asm.h>
 #include <asm/asm-offsets.h>
+#include <asm/asm-compat.h>
 
 #define rHP    r3
 #define rWP    r4
index c8951ce0dcc4ef30ea293d516ba2d4a5fc9d87fa..23e248beff7166213e95583975341247c4680233 100644 (file)
@@ -7,6 +7,7 @@
 
 #include <asm/ppc_asm.h>
 #include <asm/asm-offsets.h>
+#include <asm/asm-compat.h>
 
 #ifdef __BIG_ENDIAN__
 #define LWZ(rt, d, ra) \
index d2cf3593e98783d723bf9acd7eab286b5d60c636..19b70c5b5f18039f1ef55605b544088fa175a7d4 100644 (file)
@@ -1,21 +1,10 @@
 #ifndef _ASM_POWERPC_ASM_COMPAT_H
 #define _ASM_POWERPC_ASM_COMPAT_H
 
+#include <asm/asm-const.h>
 #include <asm/types.h>
 #include <asm/ppc-opcode.h>
 
-#ifdef __ASSEMBLY__
-#  define stringify_in_c(...)  __VA_ARGS__
-#  define ASM_CONST(x)         x
-#else
-/* This version of stringify will deal with commas... */
-#  define __stringify_in_c(...)        #__VA_ARGS__
-#  define stringify_in_c(...)  __stringify_in_c(__VA_ARGS__) " "
-#  define __ASM_CONST(x)       x##UL
-#  define ASM_CONST(x)         __ASM_CONST(x)
-#endif
-
-
 #ifdef __powerpc64__
 
 /* operations for longs and pointers */
diff --git a/arch/powerpc/include/asm/asm-const.h b/arch/powerpc/include/asm/asm-const.h
new file mode 100644 (file)
index 0000000..082c153
--- /dev/null
@@ -0,0 +1,14 @@
+#ifndef _ASM_POWERPC_ASM_CONST_H
+#define _ASM_POWERPC_ASM_CONST_H
+
+#ifdef __ASSEMBLY__
+#  define stringify_in_c(...)  __VA_ARGS__
+#  define ASM_CONST(x)         x
+#else
+/* This version of stringify will deal with commas... */
+#  define __stringify_in_c(...)        #__VA_ARGS__
+#  define stringify_in_c(...)  __stringify_in_c(__VA_ARGS__) " "
+#  define __ASM_CONST(x)       x##UL
+#  define ASM_CONST(x)         __ASM_CONST(x)
+#endif
+#endif /* _ASM_POWERPC_ASM_CONST_H */
index f67b3f6e36bebf85b69f72a913b9800daebbe3c4..de1316874e450003e98ead3cbfbf3d87ffab75a5 100644 (file)
@@ -5,6 +5,8 @@
 #ifndef _ASM_POWERPC_BARRIER_H
 #define _ASM_POWERPC_BARRIER_H
 
+#include <asm/asm-const.h>
+
 /*
  * Memory barrier.
  * The sync instruction guarantees that all memory accesses initiated
index 0387b155f13de95831937cf2bc7b777e51a7fa64..d52a51b2ce7baf170af224d2264a88f746ef58a3 100644 (file)
@@ -3,6 +3,8 @@
 #define _ASM_POWERPC_BOOK3S_64_HASH_H
 #ifdef __KERNEL__
 
+#include <asm/asm-const.h>
+
 /*
  * Common bits between 4K and 64K pages in a linux-style PTE.
  * Additional bits may be defined in pgtable-hash64-*.h
index eee0b5b8a23f30137cb4324d809687dcb4228f68..2f74bdc805e060ea6cf46adbc8426faa54d466fa 100644 (file)
@@ -12,9 +12,9 @@
  * 2 of the License, or (at your option) any later version.
  */
 
-#include <asm/asm-compat.h>
 #include <asm/page.h>
 #include <asm/bug.h>
+#include <asm/asm-const.h>
 
 /*
  * This is necessary to get the definition of PGTABLE_RANGE which we
index 3ab3f7aef0229e584ee89237eb78539498cb3729..77440e8378694eea89d8fb976bcd9bebabe342a2 100644 (file)
@@ -2,6 +2,8 @@
 #ifndef _ASM_POWERPC_PGTABLE_RADIX_H
 #define _ASM_POWERPC_PGTABLE_RADIX_H
 
+#include <asm/asm-const.h>
+
 #ifndef __ASSEMBLY__
 #include <asm/cmpxchg.h>
 #endif
index 67ec1073ac97d297e380b08333b3dab39b4d578a..27183871eb3bf667a625b6cbb987070802132f80 100644 (file)
@@ -5,7 +5,6 @@
 #ifdef __KERNEL__
 #include <linux/compiler.h>
 #include <asm/synch.h>
-#include <asm/asm-compat.h>
 #include <linux/bug.h>
 #include <asm/asm-405.h>
 
index 812535f40124efddf601c6f53e3b74a52199715d..9ecc7bfc8ae7bd678c66167f0bf61b9b63ac49c4 100644 (file)
@@ -14,6 +14,7 @@
 #include <asm/ppc-opcode.h>
 #include <linux/string.h>
 #include <linux/kallsyms.h>
+#include <asm/asm-compat.h>
 
 /* Flags for create_branch:
  * "b"   == create_branch(addr, target, 0);
index 82816a2043b9f530d17edbf437f66fcd8c749380..751126c22ed950623702030e9dfb465224e1da43 100644 (file)
@@ -4,9 +4,9 @@
 
 
 #include <linux/types.h>
-#include <asm/asm-compat.h>
 #include <asm/feature-fixups.h>
 #include <uapi/asm/cputable.h>
+#include <asm/asm-const.h>
 
 #ifndef __ASSEMBLY__
 
index 71515d909ed121912d4542b83abe17b988f15df8..55113432fc917f0640a60f7e303f257064018f93 100644 (file)
@@ -10,7 +10,6 @@
  */
 
 #include <linux/types.h>
-#include <asm/asm-compat.h>
 #include <asm/feature-fixups.h>
 #include <uapi/asm/cputable.h>
 
index fcfd05672b1b82b3ac6f94b23e6b14b3ec431918..33b6f9c892c819c62fa6bbbd503d8f1e66cafb21 100644 (file)
@@ -1,6 +1,8 @@
 #ifndef __ASM_POWERPC_FEATURE_FIXUPS_H
 #define __ASM_POWERPC_FEATURE_FIXUPS_H
 
+#include <asm/asm-const.h>
+
 /*
  * This program is free software; you can redistribute it and/or
  * modify it under the terms of the GNU General Public License
index 535add3f779133fefcb1422616d0fc3fef23588b..ce8aab72c21bb3225f922a4fa1cd79069fd4ad26 100644 (file)
@@ -14,8 +14,8 @@
 
 #ifdef __KERNEL__
 
-#include <asm/asm-compat.h>
 #include <asm/feature-fixups.h>
+#include <asm/asm-const.h>
 
 /* firmware feature bitmask values */
 
index 76c8648d0fa828ce550ff49030f66be7ac3dcb0c..94542776a62d630f6c9037e28264fc371d839245 100644 (file)
@@ -8,7 +8,6 @@
 #include <linux/uaccess.h>
 #include <asm/errno.h>
 #include <asm/synch.h>
-#include <asm/asm-compat.h>
 #include <asm/asm-405.h>
 
 #define __futex_atomic_op(insn, ret, oldval, uaddr, oparg) \
index daa3ee5d7ad2b3ea1ed804ac8730054adceaf67f..ab3a4fba38e397ca7240eadacd98fa1e8beee73f 100644 (file)
@@ -30,6 +30,7 @@
 #include <asm/machdep.h>
 #include <asm/types.h>
 #include <asm/pci-bridge.h>
+#include <asm/asm-const.h>
 
 #define IOMMU_PAGE_SHIFT_4K      12
 #define IOMMU_PAGE_SIZE_4K       (ASM_CONST(1) << IOMMU_PAGE_SHIFT_4K)
index 9a287e0ac8b16343e61ab9cc146957bfc4fb85b1..a3b2cf940b4ea076fd4e4d389c7e03beb54d074f 100644 (file)
@@ -14,7 +14,7 @@
 #include <linux/types.h>
 
 #include <asm/feature-fixups.h>
-#include <asm/asm-compat.h>
+#include <asm/asm-const.h>
 
 #define JUMP_ENTRY_TYPE                stringify_in_c(FTR_ENTRY_LONG)
 #define JUMP_LABEL_NOP_SIZE    4
index cb57f29f531ded91f9b786e9be48015e882c082f..9bdbe1d1c9b926d234eef6b1a9a2941d40041f08 100644 (file)
@@ -6,6 +6,7 @@
  */
 
 #include <asm/page.h>
+#include <asm/asm-const.h>
 
 #define PPC44x_MMUCR_TID       0x000000ff
 #define PPC44x_MMUCR_STS       0x00010000
index 61d15ce92278dcb434482639b5fb5ecbc17de353..8418d83b5eb00dbfa6188d7d06df0d4a678e00c0 100644 (file)
@@ -5,8 +5,8 @@
 
 #include <linux/types.h>
 
-#include <asm/asm-compat.h>
 #include <asm/feature-fixups.h>
+#include <asm/asm-const.h>
 
 /*
  * MMU features bit definitions
index dd0c7236208f243d7f4503dec5dd4391844d1c46..fe05b3e03cf1d04bf101cf8e03a0aeb0001ebe67 100644 (file)
@@ -8,6 +8,7 @@
 
 #include <asm/nohash/64/pgtable-4k.h>
 #include <asm/barrier.h>
+#include <asm/asm-const.h>
 
 #ifdef CONFIG_PPC_64K_PAGES
 #error "Page size not supported"
index a9fbefaacf1024313c7723aebefd09c9ebd75c6c..f6a1265face297f6b2cfe9d563dc04fbad93dcc3 100644 (file)
@@ -16,7 +16,7 @@
 #else
 #include <asm/types.h>
 #endif
-#include <asm/asm-compat.h>
+#include <asm/asm-const.h>
 
 /*
  * On regular PPC32 page size is 4K (but we support 4K/16K/64K/256K pages
index af04acdb873fcc41bd3e45611de2f5b72119cc81..c0ce17e909efbd00af1c842843e6b17476aba3ab 100644 (file)
@@ -10,6 +10,8 @@
  * 2 of the License, or (at your option) any later version.
  */
 
+#include <asm/asm-const.h>
+
 /*
  * We always define HW_PAGE_SHIFT to 12 as use of 64K pages remains Linux
  * specific, every notion of page number shared with the firmware, TCEs,
index c103caf99897fcd94daaee281b6dd8818e755cf6..954edf93515841da490a3d42647283476729227b 100644 (file)
@@ -13,7 +13,7 @@
 #define _ASM_POWERPC_PPC_OPCODE_H
 
 #include <linux/stringify.h>
-#include <asm/asm-compat.h>
+#include <asm/asm-const.h>
 
 #define        __REG_R0        0
 #define        __REG_R1        1
index e4923686e43a1c40ded9cd7a9b4f513fdfc08da6..447cbd1bee99fff38a29e4946c99f6b3e4896990 100644 (file)
@@ -24,6 +24,7 @@
 #define _ASM_POWERPC_PTRACE_H
 
 #include <uapi/asm/ptrace.h>
+#include <asm/asm-const.h>
 
 
 #ifdef __powerpc64__
index 562568414cf42ace1e40a012ced84d17abff7295..d4a8dc71a0572af4460b149666e77abe6866930c 100644 (file)
@@ -13,6 +13,7 @@
 
 #include <linux/stringify.h>
 #include <asm/cputable.h>
+#include <asm/asm-const.h>
 
 /* Pickup Book E specific registers. */
 #if defined(CONFIG_BOOKE) || defined(CONFIG_40x)
index 3ba9c6f096fcfd38c517a0a2c7882994894268bb..74c2c57c492a33d18f45f5552a146a289fd1a55a 100644 (file)
@@ -12,6 +12,8 @@
 #ifndef __ASM_POWERPC_REG_A2_H__
 #define __ASM_POWERPC_REG_A2_H__
 
+#include <asm/asm-const.h>
+
 #define SPRN_TENSR     0x1b5
 #define SPRN_TENS      0x1b6   /* Thread ENable Set */
 #define SPRN_TENC      0x1b7   /* Thread ENable Clear */
index 7ec38f4ee927ba0566249c2ab456c72428ee2b7a..685c72310f5d0e5506d5973d6250449376b7ef46 100644 (file)
@@ -24,7 +24,6 @@
 #include <asm/paca.h>
 #include <asm/hvcall.h>
 #endif
-#include <asm/asm-compat.h>
 #include <asm/synch.h>
 #include <asm/ppc-opcode.h>
 #include <asm/asm-405.h>
index 6ec546090ba1b186625d0effb5e1f4af64422d4f..f6f8c75bbb248d0b5522a924341dc45f1d55b310 100644 (file)
@@ -5,6 +5,7 @@
 
 #include <linux/stringify.h>
 #include <asm/feature-fixups.h>
+#include <asm/asm-const.h>
 
 #ifndef __ASSEMBLY__
 extern unsigned int __start___lwsync_fixup, __stop___lwsync_fixup;
index f308dfeb274652abc21f3a3cdd9e16f657e7c2e9..ae554b6fe6b98e1c42f974061bc33fc66ec1a3b2 100644 (file)
@@ -9,6 +9,8 @@
 #ifndef _ASM_POWERPC_THREAD_INFO_H
 #define _ASM_POWERPC_THREAD_INFO_H
 
+#include <asm/asm-const.h>
+
 #ifdef __KERNEL__
 
 #define THREAD_SHIFT           CONFIG_THREAD_SHIFT
index 468653ce844ce094b3cea1c7f44a55f4fce22a49..643cfbd5bcb51f4d495c25caff51d928fc6e8300 100644 (file)
@@ -2,7 +2,6 @@
 #ifndef _ARCH_POWERPC_UACCESS_H
 #define _ARCH_POWERPC_UACCESS_H
 
-#include <asm/asm-compat.h>
 #include <asm/ppc_asm.h>
 #include <asm/processor.h>
 #include <asm/page.h>
index 0357f87a013c3ee16567dd9d9b734fdc2cd7b6ec..f62d9ddc03122988f0cf6463b8b98d4f285d18fa 100644 (file)
@@ -38,6 +38,7 @@
 #include <asm/ppc-opcode.h>
 #include <asm/barrier.h>
 #include <asm/export.h>
+#include <asm/asm-compat.h>
 #ifdef CONFIG_PPC_BOOK3S
 #include <asm/exception-64s.h>
 #else
index 6c509f39bbdeb97c7c18a28e4479792a1d0fb7bf..07c913fd5abad8af733095c0e4d46a0da5ca77f2 100644 (file)
@@ -25,6 +25,7 @@
 #include <asm/asm-offsets.h>
 #include <asm/ptrace.h>
 #include <asm/export.h>
+#include <asm/asm-compat.h>
 
 #ifdef CONFIG_VSX
 #define __REST_32FPVSRS(n,c,base)                                      \
index d85d5515a091b6d197bafc8f9e67a9a585b8b837..436caa9d6eec8c6f8e516acec2be1253c9f33b5f 100644 (file)
@@ -23,6 +23,7 @@
 #include <asm/exception-64s.h>
 #include <asm/book3s/64/mmu-hash.h>
 #include <asm/mmu.h>
+#include <asm/asm-compat.h>
 
 #undef DEBUG
 
index e100ff324a85c46449ec78044e6aafadc96201a6..c005088f6c9c1fb1d8800432d9c40ffac39d510f 100644 (file)
@@ -23,6 +23,7 @@
 #include <asm/reg.h>
 #include <asm/page.h>
 #include <asm/asm-offsets.h>
+#include <asm/asm-compat.h>
 
 #define KVM_MAGIC_PAGE         (-4096)
 
index 8afbe213d729b2a48dd33deb37e5e21bf0db0a07..6d1b42ee797cfd101e264c034ee97f9099339ba5 100644 (file)
@@ -12,6 +12,7 @@
 #include <asm/ppc_asm.h>
 #include <asm/asm-offsets.h>
 #include <asm/ptrace.h>
+#include <asm/asm-compat.h>
 
 /*
  * Grab the register values as they are now.
index f314fd475491c35437da4ae392aed93ca7274d7f..21165da0052d0f86ea7604715f668015563e0af2 100644 (file)
@@ -8,6 +8,7 @@
 #include <asm/page.h>
 #include <asm/ptrace.h>
 #include <asm/export.h>
+#include <asm/asm-compat.h>
 
 /*
  * Load state from memory into VMX registers including VSCR.
index 688722acd692a63f61a0575cb8b7ce9bca591a66..d293485c1a6002595434284bfbaebd92e49767ce 100644 (file)
@@ -17,6 +17,8 @@
  * Authors: Alexander Graf <agraf@suse.de>
  */
 
+#include <asm/asm-compat.h>
+
 #define SHADOW_SLB_ENTRY_LEN   0x10
 #define OFFSET_ESID(x)         (SHADOW_SLB_ENTRY_LEN * x)
 #define OFFSET_VSID(x)         ((SHADOW_SLB_ENTRY_LEN * x) + 8)
index 82f2ff9410b6a3d398a290f2703a30b38b93ea10..4218073eea1fc81b0ac20db89e1bb3ecd69f430f 100644 (file)
@@ -27,6 +27,7 @@
 #include <asm/asm-offsets.h>
 #include <asm/exception-64s.h>
 #include <asm/ppc-opcode.h>
+#include <asm/asm-compat.h>
 
 /*****************************************************************************
  *                                                                           *
index 6e4554b273f1ab0c8b8463c5dd7e95cbc0c730fa..7405222a4e28a86b1724dd0ae23c56fe14288d12 100644 (file)
@@ -32,6 +32,7 @@
 #include <asm/opal.h>
 #include <asm/xive-regs.h>
 #include <asm/thread_info.h>
+#include <asm/asm-compat.h>
 
 /* Sign-extend HDEC if not on POWER9 */
 #define EXTEND_HDEC(reg)                       \
index c18e845019ec52a9b6255e60796bb3df0db424ed..d71dab16dc6f5acae28d574e2a8a11176739e9fb 100644 (file)
@@ -23,6 +23,7 @@
 #include <asm/page.h>
 #include <asm/asm-offsets.h>
 #include <asm/exception-64s.h>
+#include <asm/asm-compat.h>
 
 #if defined(CONFIG_PPC_BOOK3S_64)
 #ifdef PPC64_ELF_ABI_v2
index 34a5adeff0840662e8eae4553b008069bfd9426d..b0089e04c8c89ef5f1055cd3da6d0ab47156fbc8 100644 (file)
@@ -23,6 +23,7 @@
 #include <asm/mmu.h>
 #include <asm/page.h>
 #include <asm/asm-offsets.h>
+#include <asm/asm-compat.h>
 
 #ifdef CONFIG_PPC_BOOK3S_64
 #include <asm/exception-64s.h>
index 98ccc7ec5d488c18c99f452d32ca22770ebf6b8d..7fec258bb0725608f189943e60900b835925b5bd 100644 (file)
@@ -19,6 +19,8 @@
 
 /* Real mode helpers */
 
+#include <asm/asm-compat.h>
+
 #if defined(CONFIG_PPC_BOOK3S_64)
 
 #define GET_SHADOW_VCPU(reg)    \
index 506677395681a9a25d304378b1602c75bb980cbc..65244263b6a34971da3fdd9bf7af92b1e2680881 100644 (file)
@@ -9,6 +9,7 @@
 #include <asm/processor.h>
 #include <asm/ppc_asm.h>
 #include <asm/export.h>
+#include <asm/asm-compat.h>
 
 #ifdef __BIG_ENDIAN__
 #define sLd sld                /* Shift towards low-numbered address. */
index f16cec98950602afc4e4de88dbf6582133ec0694..ee7c5fd5fc64577a9dcd00321cdb80115fbc8253 100644 (file)
@@ -11,6 +11,7 @@
 #include <asm/feature-fixups.h>
 #include <asm/ppc_asm.h>
 #include <asm/synch.h>
+#include <asm/asm-compat.h>
 
        .text
 
index ae15eba49c1fcd89b61eba5c76ad91774555cbf6..32e91994b6b259440e64c97886219e0a04258557 100644 (file)
@@ -15,6 +15,7 @@
 #include <asm/ppc-opcode.h>
 #include <asm/reg.h>
 #include <asm/asm-offsets.h>
+#include <asm/asm-compat.h>
 #include <linux/errno.h>
 
 #ifdef CONFIG_PPC_FPU
index 8d8265be1a5941745eedd80edc26c01826eccba9..26ea02b7311fd0c1560825d4584027af63948c95 100644 (file)
@@ -9,6 +9,7 @@
 #include <asm/processor.h>
 #include <asm/ppc_asm.h>
 #include <asm/export.h>
+#include <asm/asm-compat.h>
 
        .align  7
 _GLOBAL_TOC(memcpy)
index 048b8e9f44928ebbe3d9892ae8f7154d56ff1954..505a3d010c479561f3d10cc8c2a3b02ef2cd1288 100644 (file)
@@ -34,6 +34,7 @@
 #include <asm/asm-offsets.h>
 #include <asm/processor.h>
 #include <asm/bug.h>
+#include <asm/asm-compat.h>
 
 #if defined(CONFIG_40x)
 
index a8cd7e289ecd71366293b0f3cfba53d7fed27a48..6f4daacad296240c1892e30af7456391541f2659 100644 (file)
@@ -13,6 +13,7 @@
 #ifndef _BPF_JIT32_H
 #define _BPF_JIT32_H
 
+#include <asm/asm-compat.h>
 #include "bpf_jit.h"
 
 #ifdef CONFIG_PPC64
index 3dd9c43d40c971f003b9621dfe135412839be3b3..c80280dc2e045bca0a67f7cebaf728a3d2ab19b5 100644 (file)
@@ -10,6 +10,7 @@
  */
 
 #include <asm/ppc_asm.h>
+#include <asm/asm-compat.h>
 #include "bpf_jit32.h"
 
 /*
index 5b061fc81df30a2c0d6065518b05d46ce568f290..d5bfe24bb3b598f7fd390908bc0b7355a9dfe8db 100644 (file)
@@ -12,6 +12,7 @@
  */
 #include <linux/moduleloader.h>
 #include <asm/cacheflush.h>
+#include <asm/asm-compat.h>
 #include <linux/netdevice.h>
 #include <linux/filter.h>
 #include <linux/if_vlan.h>
index 380cbf9a40d98f76718f22d6e6b5ffa6c1cd25bc..b8de5244a58c62e9aee43b3e909e4c1be713a506 100644 (file)
@@ -13,6 +13,7 @@
  */
 #include <linux/moduleloader.h>
 #include <asm/cacheflush.h>
+#include <asm/asm-compat.h>
 #include <linux/netdevice.h>
 #include <linux/filter.h>
 #include <linux/if_vlan.h>
index a8d9b4089c3157b65417d4af69ee9e4815a958ca..4016e3c3d18b4de00891a9944277089534169a1b 100644 (file)
@@ -14,6 +14,7 @@
 #include <asm/hvcall.h>
 #include <asm/asm-offsets.h>
 #include <asm/opal.h>
+#include <asm/asm-compat.h>
 
        .section        ".text"
 
index 139f0af6c3d9126f6c766f0958429fba721a018e..e14ccf32a97da9fb2767590825153cb4654db024 100644 (file)
@@ -69,6 +69,7 @@
 #include <asm/kexec.h>
 #include <asm/isa-bridge.h>
 #include <asm/security_features.h>
+#include <asm/asm-const.h>
 
 #include "pseries.h"
 
index 4aad9dd10ace93fe9632a344595df9e42a8e9912..1e1129553fd76d3afbff9859ec6e17966e0feb29 100644 (file)
  * Software Foundation (version 2 of the License).
  */
 
-#if defined(__LITTLE_ENDIAN__)
-#define STWX_BE        stwbrx
-#define LWZX_BE        lwbrx
-#elif defined(__BIG_ENDIAN__)
-#define STWX_BE        stwx
-#define LWZX_BE        lwzx
-#else
-#error no endianness defined!
-#endif
+#include <asm/asm-compat.h>
 
        .machine ppc64
        .balign 256
index 4099cbcddaaa2a2937f0fa65d2fe002e1f686c76..720a52afdd5813849c473abcdc91cb5667b7fac6 100644 (file)
@@ -1,5 +1,6 @@
 /* SPDX-License-Identifier: GPL-2.0 */
 #include <asm/ppc_asm.h>
+#include <asm/asm-compat.h>
 
 /* unsigned long xmon_mfspr(sprn, default_value) */
 _GLOBAL(xmon_mfspr)
diff --git a/tools/testing/selftests/powerpc/copyloops/asm/asm-compat.h b/tools/testing/selftests/powerpc/copyloops/asm/asm-compat.h
new file mode 100644 (file)
index 0000000..e69de29
diff --git a/tools/testing/selftests/powerpc/primitives/asm/asm-const.h b/tools/testing/selftests/powerpc/primitives/asm/asm-const.h
new file mode 120000 (symlink)
index 0000000..18d8be1
--- /dev/null
@@ -0,0 +1 @@
+../../../../../../arch/powerpc/include/asm/asm-const.h
\ No newline at end of file