# HG changeset patch
# User awilliam@xxxxxxxxxxxx
# Date 1170614172 25200
# Node ID 1502ba048b731d782be2d47de14f3fca97565258
# Parent a1017acc857858dc2226bc7420ae9337943ca41e
[IA64] Fix PAL_HALT for paravirtualized domains
machine_halt() stops the vcpus, but no longer destroys the domain.
This should be more in-line with the behavior on native hardware.
Signed-off-by: Akio Takebe <takebe_akio@xxxxxxxxxxxxxx>
---
linux-2.6-xen-sparse/arch/ia64/kernel/setup.c | 8 ++++++++
xen/arch/ia64/xen/fw_emul.c | 8 +++++---
2 files changed, 13 insertions(+), 3 deletions(-)
diff -r a1017acc8578 -r 1502ba048b73
linux-2.6-xen-sparse/arch/ia64/kernel/setup.c
--- a/linux-2.6-xen-sparse/arch/ia64/kernel/setup.c Sun Feb 04 11:28:54
2007 -0700
+++ b/linux-2.6-xen-sparse/arch/ia64/kernel/setup.c Sun Feb 04 11:36:12
2007 -0700
@@ -95,6 +95,13 @@ static struct notifier_block xen_panic_b
static struct notifier_block xen_panic_block = {
xen_panic_event, NULL, 0 /* try to go last */
};
+
+void xen_pm_power_off(void)
+{
+ printk("%s called\n", __FUNCTION__);
+ local_irq_disable();
+ HYPERVISOR_shutdown(SHUTDOWN_poweroff);
+}
#endif
extern void ia64_setup_printk_clock(void);
@@ -456,6 +463,7 @@ setup_arch (char **cmdline_p)
/* Register a call for panic conditions. */
atomic_notifier_chain_register(&panic_notifier_list,
&xen_panic_block);
+ pm_power_off = xen_pm_power_off;
}
#endif
diff -r a1017acc8578 -r 1502ba048b73 xen/arch/ia64/xen/fw_emul.c
--- a/xen/arch/ia64/xen/fw_emul.c Sun Feb 04 11:28:54 2007 -0700
+++ b/xen/arch/ia64/xen/fw_emul.c Sun Feb 04 11:36:12 2007 -0700
@@ -605,9 +605,11 @@ xen_pal_emulator(unsigned long index, u6
printk ("Domain0 halts the machine\n");
console_start_sync();
(*efi.reset_system)(EFI_RESET_SHUTDOWN,0,0,NULL);
- }
- else
- domain_shutdown(current->domain, SHUTDOWN_poweroff);
+ } else {
+ set_bit(_VCPUF_down, ¤t->vcpu_flags);
+ vcpu_sleep_nosync(current);
+ status = PAL_STATUS_SUCCESS;
+ }
break;
case PAL_HALT_LIGHT:
if (VMX_DOMAIN(current)) {
_______________________________________________
Xen-changelog mailing list
Xen-changelog@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-changelog
|