[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [Xen-devel] [PATCH] Fix xc_hvm_save/restore for non-x86 builds
Tools currently won't build on non-x86 due to xc_hvm_save/restore only being built for CONFIG_HVM, but called from xcutils regardless. This patch adds stub functions for those of us that don't support HVM save/restore just yet. Thanks, Alex Signed-off-by: Alex Williamson <alex.williamson@xxxxxx> --- diff -r 1c0ca58e8c16 tools/libxc/Makefile --- a/tools/libxc/Makefile Mon Jan 22 13:38:04 2007 +0000 +++ b/tools/libxc/Makefile Mon Jan 22 12:46:45 2007 -0700 @@ -28,7 +28,11 @@ GUEST_SRCS-$(CONFIG_X86) += xc_linux_bui GUEST_SRCS-$(CONFIG_X86) += xc_linux_build.c GUEST_SRCS-$(CONFIG_IA64) += xc_linux_build.c GUEST_SRCS-$(CONFIG_MIGRATE) += xc_linux_restore.c xc_linux_save.c -GUEST_SRCS-$(CONFIG_HVM) += xc_hvm_build.c xc_hvm_restore.c xc_hvm_save.c +ifeq ($(CONFIG_HVM),y) +GUEST_SRCS-y += xc_hvm_build.c xc_hvm_restore.c xc_hvm_save.c +else +GUEST_SRCS-y += xc_hvm_stubs.c +endif -include $(XEN_TARGET_ARCH)/Makefile diff -r 1c0ca58e8c16 tools/libxc/xc_hvm_stubs.c --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/tools/libxc/xc_hvm_stubs.c Mon Jan 22 12:56:05 2007 -0700 @@ -0,0 +1,37 @@ +/****************************************************************************** + * xc_hvm_stubs.c + * + * This program is free software; you can redistribute it and/or modify it + * under the terms and conditions of the GNU General Public License, + * version 2, as published by the Free Software Foundation. + * + * This program is distributed in the hope it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for + * more details. + * + * You should have received a copy of the GNU General Public License along with + * this program; if not, write to the Free Software Foundation, Inc., 59 Temple + * Place - Suite 330, Boston, MA 02111-1307 USA. + * + */ + +#include "xg_private.h" + +int xc_hvm_save(int xc_handle, int io_fd, uint32_t dom, uint32_t max_iters, + uint32_t max_factor, uint32_t flags, int (*suspend)(int)) +{ + ERROR("HVM save is currently unsupported."); + return 1; +} + +int xc_hvm_restore(int xc_handle, int io_fd, + uint32_t dom, unsigned long nr_pfns, + unsigned int store_evtchn, unsigned long *store_mfn, + unsigned int console_evtchn, unsigned long *console_mfn, + unsigned int pae, unsigned int apic) +{ + ERROR("HVM restore is currently unsupported."); + return 1; +} + _______________________________________________ Xen-devel mailing list Xen-devel@xxxxxxxxxxxxxxxxxxx http://lists.xensource.com/xen-devel
|
Lists.xenproject.org is hosted with RackSpace, monitoring our |