From 44a4d5301519c12f77b9eefe1b8060f28983f2d0 Mon Sep 17 00:00:00 2001 From: Keir Fraser Date: Wed, 23 Jan 2008 15:42:52 +0000 Subject: pv-on-hvm: Fix up linux code after hypercall-type-checking changes. Signed-off-by: Jan Beulich --- unmodified_drivers/linux-2.6/platform-pci/evtchn.c | 9 +++++---- unmodified_drivers/linux-2.6/platform-pci/machine_reboot.c | 2 +- 2 files changed, 6 insertions(+), 5 deletions(-) (limited to 'unmodified_drivers') diff --git a/unmodified_drivers/linux-2.6/platform-pci/evtchn.c b/unmodified_drivers/linux-2.6/platform-pci/evtchn.c index 39a930e217..a22342277c 100644 --- a/unmodified_drivers/linux-2.6/platform-pci/evtchn.c +++ b/unmodified_drivers/linux-2.6/platform-pci/evtchn.c @@ -118,8 +118,8 @@ void unmask_evtchn(int port) ever bind event channels to vcpu 0 in HVM guests. */ if (unlikely(cpu != 0)) { evtchn_unmask_t op = { .port = port }; - (void)HYPERVISOR_event_channel_op(EVTCHNOP_unmask, - &op); + VOID(HYPERVISOR_event_channel_op(EVTCHNOP_unmask, + &op)); put_cpu(); return; } @@ -227,7 +227,8 @@ void unbind_from_irqhandler(unsigned int irq, void *dev_id) mask_evtchn(evtchn); if (irq_evtchn[irq].close) { struct evtchn_close close = { .port = evtchn }; - HYPERVISOR_event_channel_op(EVTCHNOP_close, &close); + if (HYPERVISOR_event_channel_op(EVTCHNOP_close, &close)) + BUG(); } } @@ -310,7 +311,7 @@ static irqreturn_t evtchn_interrupt(int irq, void *dev_id void force_evtchn_callback(void) { - (void)HYPERVISOR_xen_version(0, NULL); + VOID(HYPERVISOR_xen_version(0, NULL)); } EXPORT_SYMBOL(force_evtchn_callback); diff --git a/unmodified_drivers/linux-2.6/platform-pci/machine_reboot.c b/unmodified_drivers/linux-2.6/platform-pci/machine_reboot.c index cb8cded198..f1f5a4558d 100644 --- a/unmodified_drivers/linux-2.6/platform-pci/machine_reboot.c +++ b/unmodified_drivers/linux-2.6/platform-pci/machine_reboot.c @@ -58,7 +58,7 @@ static int bp_suspend(void) BUG_ON(!irqs_disabled()); - suspend_cancelled = HYPERVISOR_shutdown(SHUTDOWN_suspend); + suspend_cancelled = HYPERVISOR_suspend(0); if (!suspend_cancelled) { write_lock(&suspend_lock); -- cgit v1.2.3