]> git.karo-electronics.de Git - karo-tx-linux.git/commitdiff
MIPS: allow msa.h to be included in assembly files
authorPaul Burton <paul.burton@imgtec.com>
Fri, 11 Jul 2014 15:44:27 +0000 (16:44 +0100)
committerRalf Baechle <ralf@linux-mips.org>
Fri, 1 Aug 2014 22:06:43 +0000 (00:06 +0200)
Just #ifdef away the C functions when included from an assembly file,
as will be done in a following commit.

Signed-off-by: Paul Burton <paul.burton@imgtec.com>
Cc: linux-mips@linux-mips.org
Patchwork: https://patchwork.linux-mips.org/patch/7299/
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
arch/mips/include/asm/msa.h

index 538f6d482db87e13b2e11feaf70b82987976a6a8..e80e85c1334f56250ab2b78e69bba6611ae508b3 100644 (file)
@@ -12,6 +12,8 @@
 
 #include <asm/mipsregs.h>
 
+#ifndef __ASSEMBLY__
+
 extern void _save_msa(struct task_struct *);
 extern void _restore_msa(struct task_struct *);
 
@@ -133,15 +135,6 @@ static inline void write_msa_##name(unsigned int val)              \
 
 #endif /* !TOOLCHAIN_SUPPORTS_MSA */
 
-#define MSA_IR         0
-#define MSA_CSR                1
-#define MSA_ACCESS     2
-#define MSA_SAVE       3
-#define MSA_MODIFY     4
-#define MSA_REQUEST    5
-#define MSA_MAP                6
-#define MSA_UNMAP      7
-
 __BUILD_MSA_CTL_REG(ir, 0)
 __BUILD_MSA_CTL_REG(csr, 1)
 __BUILD_MSA_CTL_REG(access, 2)
@@ -151,6 +144,17 @@ __BUILD_MSA_CTL_REG(request, 5)
 __BUILD_MSA_CTL_REG(map, 6)
 __BUILD_MSA_CTL_REG(unmap, 7)
 
+#endif /* !__ASSEMBLY__ */
+
+#define MSA_IR         0
+#define MSA_CSR                1
+#define MSA_ACCESS     2
+#define MSA_SAVE       3
+#define MSA_MODIFY     4
+#define MSA_REQUEST    5
+#define MSA_MAP                6
+#define MSA_UNMAP      7
+
 /* MSA Implementation Register (MSAIR) */
 #define MSA_IR_REVB            0
 #define MSA_IR_REVF            (_ULCAST_(0xff) << MSA_IR_REVB)