Merge branch 'master' of git://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux-2.6
[powerpc.git] / include / asm-powerpc / kexec.h
index bda2f21..efe8872 100644 (file)
 #define KEXEC_ARCH KEXEC_ARCH_PPC
 #endif
 
+#ifndef __ASSEMBLY__
+
 #ifdef CONFIG_KEXEC
 
-#ifndef __ASSEMBLY__
 #ifdef __powerpc64__
 /*
  * This function is responsible for capturing register states if coming
@@ -93,7 +94,8 @@ static inline void crash_setup_regs(struct pt_regs *newregs,
                        "mfxer  %0\n"
                        "std    %0, 296(%2)\n"
                        : "=&r" (tmp1), "=&r" (tmp2)
-                       : "b" (newregs));
+                       : "b" (newregs)
+                       : "memory");
        }
 }
 #else
@@ -122,8 +124,19 @@ extern int default_machine_kexec_prepare(struct kimage *image);
 extern void default_machine_crash_shutdown(struct pt_regs *regs);
 
 extern void machine_kexec_simple(struct kimage *image);
+extern int overlaps_crashkernel(unsigned long start, unsigned long size);
+extern void reserve_crashkernel(void);
+
+#else /* !CONFIG_KEXEC */
+
+static inline int overlaps_crashkernel(unsigned long start, unsigned long size)
+{
+       return 0;
+}
+
+static inline void reserve_crashkernel(void) { ; }
 
-#endif /* ! __ASSEMBLY__ */
 #endif /* CONFIG_KEXEC */
+#endif /* ! __ASSEMBLY__ */
 #endif /* __KERNEL__ */
 #endif /* _ASM_POWERPC_KEXEC_H */