On 01/26/2011 08:36 AM, anthony.perard@xxxxxxxxxx wrote:
From: Anthony PERARD<anthony.perard@xxxxxxxxxx>
Signed-off-by: Anthony PERARD<anthony.perard@xxxxxxxxxx>
---
hw/xen_machine_fv.c | 11 ++++++++++-
1 files changed, 10 insertions(+), 1 deletions(-)
diff --git a/hw/xen_machine_fv.c b/hw/xen_machine_fv.c
index 0a90312..f48b978 100644
--- a/hw/xen_machine_fv.c
+++ b/hw/xen_machine_fv.c
@@ -38,9 +38,18 @@
#include "xen/hvm/hvm_info_table.h"
#include "xen_platform.h"
#include "xen_common.h"
+#include "xen_backend.h"
#define MAX_IDE_BUS 2
+static void xen_cmos_set_s3_resume(void *opaque, int irq, int level)
+{
+ pc_cmos_set_s3_resume(opaque, irq, level);
+ if (level) {
+ xc_set_hvm_param(xen_xc, xen_domid, HVM_PARAM_ACPI_S_STATE, 3);
+ }
+}
+
Ack.
Regards,
Anthony Liguori
static void xen_init_fv(ram_addr_t ram_size,
const char *boot_device,
const char *kernel_filename,
@@ -132,7 +141,7 @@ static void xen_init_fv(ram_addr_t ram_size,
}
if (acpi_enabled) {
- cmos_s3 = qemu_allocate_irqs(pc_cmos_set_s3_resume, rtc_state, 1);
+ cmos_s3 = qemu_allocate_irqs(xen_cmos_set_s3_resume, rtc_state, 1);
smi_irq = qemu_allocate_irqs(pc_acpi_smi_interrupt, first_cpu, 1);
piix4_pm_init(pci_bus, piix3_devfn + 3, 0xb100,
isa_reserve_irq(9), *cmos_s3, *smi_irq, 0);
_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-devel
|