|
|
|
|
|
|
|
|
|
|
xen-ia64-devel
[Xen-ia64-devel] Re: [Crash-utility] crash version 4.0-3.15 is available
On Fri, Dec 22, 2006 at 10:06:01AM -0500, Dave Anderson wrote:
> Not quite -- it leaves out the most important part. Your
> patch will cause a switch_stack register dump to be laid down,
> but the address of the switch_stack needs to be stored in the
> task_struct->thread.ksp of the panicking task:
Ouch. attached the updated patch.
# HG changeset patch
# User yamahata@xxxxxxxxxxxxx
# Date 1167010270 -32400
# Node ID 1f2ea340120cfc05caabb4b0c5cb2c24d8c6431b
# Parent 80c5b5914b795b28249c8f7251ecd24b53186339
As Dave requested, call unw_init_running() and save ksp before SHUTDOWN_crash.
This makes crash command happy.
PATCHNAME: unw_init_running_before_shutdown_crash
Signed-off-by: Dave Anderson <anderson@xxxxxxxxxx>
Signed-off-by: Isaku Yamahata <yamahata@xxxxxxxxxxxxx>
diff -r 80c5b5914b79 -r 1f2ea340120c
linux-2.6-xen-sparse/arch/ia64/kernel/setup.c
--- a/linux-2.6-xen-sparse/arch/ia64/kernel/setup.c Wed Dec 20 14:55:02
2006 -0700
+++ b/linux-2.6-xen-sparse/arch/ia64/kernel/setup.c Mon Dec 25 10:31:10
2006 +0900
@@ -77,10 +77,18 @@ EXPORT_SYMBOL(__per_cpu_offset);
#endif
#ifdef CONFIG_XEN
+static void
+xen_panic_hypercall(struct unw_frame_info *info, void *arg)
+{
+ current->thread.ksp = (__u64)info->sw - 16;
+ HYPERVISOR_shutdown(SHUTDOWN_crash);
+ /* we're never actually going to get here... */
+}
+
static int
xen_panic_event(struct notifier_block *this, unsigned long event, void *ptr)
{
- HYPERVISOR_shutdown(SHUTDOWN_crash);
+ unw_init_running(xen_panic_hypercall, NULL);
/* we're never actually going to get here... */
return NOTIFY_DONE;
}
--
yamahata
_______________________________________________
Xen-ia64-devel mailing list
Xen-ia64-devel@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-ia64-devel
|
|
|
|
|