From: Albert Herranz <albert_herranz@yahoo.es>
Date: Wed, 1 Feb 2006 11:05:57 +0000 (-0800)
Subject: [PATCH] powerpc: fix for kexec ppc32
X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=39931e41becd6abeb2014747369d8b6392f5dbac;p=GitHub%2Fexynos8895%2Fandroid_kernel_samsung_universal8895.git

[PATCH] powerpc: fix for kexec ppc32

- kexec.h is included from assembly code, thus C code must be properly
  protected.

- (embedded) ppc32 systems use machine_kexec_simple whose declaration
  vanished during a recent powerpc merge change.

Signed-off-by: Albert Herranz <albert_herranz@yahoo.es>
Cc: <fastboot@osdl.org>
Cc: Benjamin Herrenschmidt <benh@kernel.crashing.org>
Cc: Paul Mackerras <paulus@samba.org>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
---

diff --git a/include/asm-powerpc/kexec.h b/include/asm-powerpc/kexec.h
index 640a6459f2f4..bda2f217e6fe 100644
--- a/include/asm-powerpc/kexec.h
+++ b/include/asm-powerpc/kexec.h
@@ -33,6 +33,7 @@
 
 #ifdef CONFIG_KEXEC
 
+#ifndef __ASSEMBLY__
 #ifdef __powerpc64__
 /*
  * This function is responsible for capturing register states if coming
@@ -104,7 +105,6 @@ static inline void crash_setup_regs(struct pt_regs *newregs,
 					struct pt_regs *oldregs) { }
 #endif /* !__powerpc64 __ */
 
-#ifndef __ASSEMBLY__
 #define MAX_NOTE_BYTES 1024
 
 #ifdef __powerpc64__
@@ -121,6 +121,8 @@ extern void default_machine_kexec(struct kimage *image);
 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);
+
 #endif /* ! __ASSEMBLY__ */
 #endif /* CONFIG_KEXEC */
 #endif /* __KERNEL__ */