Fedora kernel-2.6.17-1.2142_FC4 patched with stable patch-2.6.17.4-vs2.0.2-rc26.diff
[linux-2.6.git] / include / asm-mips / sim.h
index a88c337..9c2af1b 100644 (file)
 
 #include <linux/config.h>
 
-#include <asm/offset.h>
-
-/* Used in declaration of save_static functions.  */
-#define static_unused static __attribute__((unused))
+#include <asm/asm-offsets.h>
 
 #define __str2(x) #x
 #define __str(x) __str2(x)
 
-#ifdef CONFIG_MIPS32
+#ifdef CONFIG_32BIT
 
 #define save_static_function(symbol)                                   \
 __asm__ (                                                              \
@@ -39,14 +36,15 @@ __asm__ (                                                           \
        "sw\t$22,"__str(PT_R22)"($29)\n\t"                              \
        "sw\t$23,"__str(PT_R23)"($29)\n\t"                              \
        "sw\t$30,"__str(PT_R30)"($29)\n\t"                              \
+       "j\t_" #symbol "\n\t"                                           \
        ".end\t" #symbol "\n\t"                                         \
        ".size\t" #symbol",. - " #symbol)
 
 #define nabi_no_regargs
 
-#endif /* CONFIG_MIPS32 */
+#endif /* CONFIG_32BIT */
 
-#ifdef CONFIG_MIPS64
+#ifdef CONFIG_64BIT
 
 #define save_static_function(symbol)                                   \
 __asm__ (                                                              \
@@ -66,6 +64,7 @@ __asm__ (                                                             \
        "sd\t$22,"__str(PT_R22)"($29)\n\t"                              \
        "sd\t$23,"__str(PT_R23)"($29)\n\t"                              \
        "sd\t$30,"__str(PT_R30)"($29)\n\t"                              \
+       "j\t_" #symbol "\n\t"                                           \
        ".end\t" #symbol "\n\t"                                         \
        ".size\t" #symbol",. - " #symbol)
 
@@ -79,6 +78,6 @@ __asm__ (                                                             \
        unsigned long __dummy6,                                         \
        unsigned long __dummy7,
 
-#endif /* CONFIG_MIPS64 */
+#endif /* CONFIG_64BIT */
 
 #endif /* _ASM_SIM_H */