summaryrefslogtreecommitdiff
path: root/arch/arm
diff options
context:
space:
mode:
authorPer Fransson <per.xx.fransson@stericsson.com>2011-09-23 14:11:24 +0200
committerLee Jones <lee.jones@linaro.org>2012-01-05 10:07:40 +0000
commit903b2d2e3cd721f5599986c3fc49ce31f0f11248 (patch)
tree41bb2c68661f6dfdfe36413f20b3ebecab727a10 /arch/arm
parent348e543b28039f9f5e4396a2cd275666d4ab5a3f (diff)
ux500: Start crash dump through SW reset
When using kexec/kdump without an crash kernel image loaded: * clean the caches and write the crash_notes * perform a restart ST-Ericsson ID: 340331 Change-Id: I1ae34ed2b5e43da4849650a8a7d2f1e453dcbe93 Signed-off-by: Per Fransson <per.xx.fransson@stericsson.com> Reviewed-on: http://gerrit.lud.stericsson.com/gerrit/32678 Reviewed-by: Jonas ABERG <jonas.aberg@stericsson.com> Reviewed-by: Srinidhi KASAGAR <srinidhi.kasagar@stericsson.com>
Diffstat (limited to 'arch/arm')
-rw-r--r--arch/arm/Kconfig7
-rw-r--r--arch/arm/kernel/machine_kexec.c10
2 files changed, 17 insertions, 0 deletions
diff --git a/arch/arm/Kconfig b/arch/arm/Kconfig
index 2218c2a3d8f..557078c2ec4 100644
--- a/arch/arm/Kconfig
+++ b/arch/arm/Kconfig
@@ -2022,6 +2022,13 @@ config KEXEC
initially work for you. It may help to enable device hotplugging
support.
+config CRASH_SWRESET
+ bool "Perform a software reset at a panic (EXPERIMENTAL)"
+ depends on EXPERIMENTAL
+ depends on KEXEC
+ help
+ If no crash kernel has been loaded, perform a SW reset as plan B.
+
config ATAGS_PROC
bool "Export atags in procfs"
depends on KEXEC
diff --git a/arch/arm/kernel/machine_kexec.c b/arch/arm/kernel/machine_kexec.c
index ae1d73a15d3..2a9c3430115 100644
--- a/arch/arm/kernel/machine_kexec.c
+++ b/arch/arm/kernel/machine_kexec.c
@@ -123,3 +123,13 @@ void machine_kexec(struct kimage *image)
flush_cache_all();
cpu_reset(reboot_code_buffer_phys);
}
+
+void machine_crash_swreset(void)
+{
+ printk(KERN_INFO "Software reset on panic!\n");
+
+ flush_cache_all();
+ outer_flush_all();
+ outer_disable();
+ arm_pm_restart(0, NULL);
+}