patch-2.4.22 linux-2.4.22/include/asm-mips64/sgiarcs.h

Next file: linux-2.4.22/include/asm-mips64/sibyte/64bit.h
Previous file: linux-2.4.22/include/asm-mips64/sgi/sgint23.h
Back to the patch index
Back to the overall index

diff -urN linux-2.4.21/include/asm-mips64/sgiarcs.h linux-2.4.22/include/asm-mips64/sgiarcs.h
@@ -6,7 +6,7 @@
  * ARC firmware interface defines.
  *
  * Copyright (C) 1996 David S. Miller (dm@engr.sgi.com)
- * Copyright (C) 1999 Ralf Baechle (ralf@gnu.org)
+ * Copyright (C) 1999, 2001 Ralf Baechle (ralf@gnu.org)
  * Copyright (C) 1999 Silicon Graphics, Inc.
  */
 #ifndef _ASM_SGIARCS_H
@@ -365,9 +365,10 @@
  * Macros for calling a 32-bit ARC implementation from 64-bit code
  */
 
-#ifdef CONFIG_ARC32
+#if defined(CONFIG_MIPS64) && defined(CONFIG_ARC32)
+
 #define __arc_clobbers							\
-	"$2","$3","$4","$5","$6","$7","$8","$9","$10","$11",		\
+	"$2","$3" /* ... */, "$8","$9","$10","$11",			\
 	"$12","$13","$14","$15","$16","$24","25","$31"
 
 #define ARC_CALL0(dest)							\
@@ -380,7 +381,7 @@
 	"move\t%0, $2"							\
 	: "=r" (__res), "=r" (__vec)					\
 	: "1" (__vec)							\
-	: __arc_clobbers);						\
+	: __arc_clobbers, "$4","$5","$6","$7");				\
 	(unsigned long) __res;						\
 })
 
@@ -395,7 +396,7 @@
 	"move\t%0, $2"							\
 	: "=r" (__res), "=r" (__vec)					\
 	: "1" (__vec), "r" (__a1)					\
-	: __arc_clobbers);						\
+	: __arc_clobbers, "$5","$6","$7");				\
 	(unsigned long) __res;						\
 })
 
@@ -411,7 +412,7 @@
 	"move\t%0, $2"							\
 	: "=r" (__res), "=r" (__vec)					\
 	: "1" (__vec), "r" (__a1), "r" (__a2)				\
-	: __arc_clobbers);						\
+	: __arc_clobbers, "$6","$7");					\
 	__res;								\
 })
 
@@ -428,7 +429,7 @@
 	"move\t%0, $2"							\
 	: "=r" (__res), "=r" (__vec)					\
 	: "1" (__vec), "r" (__a1), "r" (__a2), "r" (__a3)		\
-	: __arc_clobbers);						\
+	: __arc_clobbers, "$7");					\
 	__res;								\
 })
 
@@ -472,9 +473,11 @@
 	: __arc_clobbers);						\
 	__res;								\
 })
-#endif /* CONFIG_ARC32 */
 
-#ifdef CONFIG_ARC64
+#endif /* defined(CONFIG_MIPS64) && defined(CONFIG_ARC32) */
+
+#if (defined(CONFIG_MIPS32) && defined(CONFIG_ARC32)) ||		\
+    (defined(CONFIG_MIPS64) && defined(CONFIG_ARC64))
 
 #define ARC_CALL0(dest)							\
 ({	long __res;							\
@@ -539,6 +542,6 @@
 	__res = __vec(__a1, __a2, __a3, __a4, __a5);			\
 	__res;								\
 })
-#endif /* CONFIG_ARC64 */
+#endif /* both kernel and ARC either 32-bit or 64-bit */
 
 #endif /* _ASM_SGIARCS_H */

FUNET's LINUX-ADM group, linux-adm@nic.funet.fi
TCL-scripts by Sam Shen (who was at: slshen@lbl.gov)