diff options
author | kfraser@localhost.localdomain <kfraser@localhost.localdomain> | 2007-09-07 10:18:54 +0100 |
---|---|---|
committer | kfraser@localhost.localdomain <kfraser@localhost.localdomain> | 2007-09-07 10:18:54 +0100 |
commit | 05bc962b373f5f41c5659d0287e3cf0d2973cc89 (patch) | |
tree | 50045b7e46c70ee916846a26c08b47dab9e11ed3 /unmodified_drivers | |
parent | 787dcb588baf05031b52d567cdf56a9a465b5435 (diff) | |
download | xen-05bc962b373f5f41c5659d0287e3cf0d2973cc89.tar.gz xen-05bc962b373f5f41c5659d0287e3cf0d2973cc89.tar.bz2 xen-05bc962b373f5f41c5659d0287e3cf0d2973cc89.zip |
PV-on-HVM: Fix non-SMP build warning for PV-on-HVM drivers.
smp_call_function() compiles to nothing on non-SMP, so we had a
defined-but-not-used static function.
Based on an original patch by:
Signed-off-by: Ben Guthro <bguthro@virtualiron.com>
Signed-off-by: Robert Phillips <rphillips@virtualiron.com>
Signed-off-by: Keir Fraser <keir@xensource.com>
Diffstat (limited to 'unmodified_drivers')
-rw-r--r-- | unmodified_drivers/linux-2.6/platform-pci/machine_reboot.c | 12 |
1 files changed, 11 insertions, 1 deletions
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 33c468d594..2c225b76ac 100644 --- a/unmodified_drivers/linux-2.6/platform-pci/machine_reboot.c +++ b/unmodified_drivers/linux-2.6/platform-pci/machine_reboot.c @@ -18,6 +18,8 @@ struct ap_suspend_info { */ static DEFINE_RWLOCK(suspend_lock); +#ifdef CONFIG_SMP + /* * Spinning prevents, for example, APs touching grant table entries while * the shared grant table is not mapped into the address space imemdiately @@ -43,6 +45,14 @@ static void ap_suspend(void *_info) atomic_dec(&info->nr_spinning); } +#define initiate_ap_suspend(i) smp_call_function(ap_suspend, i, 0, 0) + +#else /* !defined(CONFIG_SMP) */ + +#define initiate_ap_suspend(i) 0 + +#endif + static int bp_suspend(void) { int suspend_cancelled; @@ -80,7 +90,7 @@ int __xen_suspend(int fast_suspend) nr_cpus = num_online_cpus() - 1; - err = smp_call_function(ap_suspend, &info, 0, 0); + err = initiate_ap_suspend(&info); if (err < 0) { preempt_enable(); xenbus_suspend_cancel(); |