diff options
Diffstat (limited to 'arch/powerpc/kernel/machine_kexec.c')
-rw-r--r-- | arch/powerpc/kernel/machine_kexec.c | 14 |
1 files changed, 8 insertions, 6 deletions
diff --git a/arch/powerpc/kernel/machine_kexec.c b/arch/powerpc/kernel/machine_kexec.c index df7e20c191c..a5f8672eeff 100644 --- a/arch/powerpc/kernel/machine_kexec.c +++ b/arch/powerpc/kernel/machine_kexec.c | |||
@@ -15,6 +15,7 @@ | |||
15 | #include <linux/memblock.h> | 15 | #include <linux/memblock.h> |
16 | #include <linux/of.h> | 16 | #include <linux/of.h> |
17 | #include <linux/irq.h> | 17 | #include <linux/irq.h> |
18 | #include <linux/ftrace.h> | ||
18 | 19 | ||
19 | #include <asm/machdep.h> | 20 | #include <asm/machdep.h> |
20 | #include <asm/prom.h> | 21 | #include <asm/prom.h> |
@@ -44,10 +45,7 @@ void machine_kexec_mask_interrupts(void) { | |||
44 | 45 | ||
45 | void machine_crash_shutdown(struct pt_regs *regs) | 46 | void machine_crash_shutdown(struct pt_regs *regs) |
46 | { | 47 | { |
47 | if (ppc_md.machine_crash_shutdown) | 48 | default_machine_crash_shutdown(regs); |
48 | ppc_md.machine_crash_shutdown(regs); | ||
49 | else | ||
50 | default_machine_crash_shutdown(regs); | ||
51 | } | 49 | } |
52 | 50 | ||
53 | /* | 51 | /* |
@@ -65,8 +63,6 @@ int machine_kexec_prepare(struct kimage *image) | |||
65 | 63 | ||
66 | void machine_kexec_cleanup(struct kimage *image) | 64 | void machine_kexec_cleanup(struct kimage *image) |
67 | { | 65 | { |
68 | if (ppc_md.machine_kexec_cleanup) | ||
69 | ppc_md.machine_kexec_cleanup(image); | ||
70 | } | 66 | } |
71 | 67 | ||
72 | void arch_crash_save_vmcoreinfo(void) | 68 | void arch_crash_save_vmcoreinfo(void) |
@@ -87,11 +83,17 @@ void arch_crash_save_vmcoreinfo(void) | |||
87 | */ | 83 | */ |
88 | void machine_kexec(struct kimage *image) | 84 | void machine_kexec(struct kimage *image) |
89 | { | 85 | { |
86 | int save_ftrace_enabled; | ||
87 | |||
88 | save_ftrace_enabled = __ftrace_enabled_save(); | ||
89 | |||
90 | if (ppc_md.machine_kexec) | 90 | if (ppc_md.machine_kexec) |
91 | ppc_md.machine_kexec(image); | 91 | ppc_md.machine_kexec(image); |
92 | else | 92 | else |
93 | default_machine_kexec(image); | 93 | default_machine_kexec(image); |
94 | 94 | ||
95 | __ftrace_enabled_restore(save_ftrace_enabled); | ||
96 | |||
95 | /* Fall back to normal restart if we're still alive. */ | 97 | /* Fall back to normal restart if we're still alive. */ |
96 | machine_restart(NULL); | 98 | machine_restart(NULL); |
97 | for(;;); | 99 | for(;;); |