On 04/14/2011 12:53 PM, Eric Blake wrote:
On 04/09/2011 09:48 AM, Stefan Berger wrote:
> This patch enables the migration of Qemu VMs between hosts of different
> endianess. I tested this by migrating a i686 VM between a x86 and ppc64
> host.
>
> I am converting the 'int's in the VM's state header to uint32_t assuming
> this doesn't break compatibility with existing deployments other than
> Linux.
>
> Signed-off-by: Stefan Berger<stefanb(a)linux.vnet.ibm.com>
>
> ---
> src/qemu/qemu_driver.c | 25 ++++++++++++++++++++-----
> 1 file changed, 20 insertions(+), 5 deletions(-)
>
> Index: libvirt-acl/src/qemu/qemu_driver.c
> ===================================================================
> --- libvirt-acl.orig/src/qemu/qemu_driver.c
> +++ libvirt-acl/src/qemu/qemu_driver.c
> @@ -43,6 +43,7 @@
> #include<sys/wait.h>
> #include<sys/ioctl.h>
> #include<sys/un.h>
> +#include<byteswap.h>
This won't work unless you also modify bootstrap.conf to include the
gnulib byteswap module.
ACK with that nit fixed.
I don't think it's necessary to include it there:
# rpm -q --whatprovides /usr/include/byteswap.h
glibc-headers-2.12.90-21.x86_64
Stefan