diff mbox series

[V3] tools/libxl: Add iothread support for COLO

Message ID 20190726154340.2950-1-chen.zhang@intel.com (mailing list archive)
State Superseded
Headers show
Series [V3] tools/libxl: Add iothread support for COLO | expand

Commit Message

Zhang Chen July 26, 2019, 3:43 p.m. UTC
From: Zhang Chen <chen.zhang@intel.com>

Xen COLO and KVM COLO shared lots of code in Qemu.
The colo-compare object in Qemu now requires an 'iothread' property since QEMU 2.11.

Detail:
https://wiki.qemu.org/Features/COLO

Signed-off-by: Zhang Chen <chen.zhang@intel.com>
---
 tools/libxl/libxl_dm.c | 5 ++++-
 1 file changed, 4 insertions(+), 1 deletion(-)

Comments

Anthony PERARD July 26, 2019, 4:19 p.m. UTC | #1
On Fri, Jul 26, 2019 at 11:43:40PM +0800, Zhang Chen wrote:
> From: Zhang Chen <chen.zhang@intel.com>
> 
> Xen COLO and KVM COLO shared lots of code in Qemu.
> The colo-compare object in Qemu now requires an 'iothread' property since QEMU 2.11.
> 
> Detail:
> https://wiki.qemu.org/Features/COLO
> 
> Signed-off-by: Zhang Chen <chen.zhang@intel.com>
> ---
>  tools/libxl/libxl_dm.c | 5 ++++-
>  1 file changed, 4 insertions(+), 1 deletion(-)
> 
> diff --git a/tools/libxl/libxl_dm.c b/tools/libxl/libxl_dm.c
> index f4fc96415d..4b029d6c8e 100644
> --- a/tools/libxl/libxl_dm.c
> +++ b/tools/libxl/libxl_dm.c
> @@ -1635,7 +1635,10 @@ static int libxl__build_device_model_args_new(libxl__gc *gc,
>                          nics[i].colo_compare_notify_dev) {
>                          flexarray_append(dm_args, "-object");
>                          flexarray_append(dm_args,
> -                           GCSPRINTF("colo-compare,id=c1,primary_in=%s,secondary_in=%s,outdev=%s,notify_dev=%s",
> +                           GCSPRINTF("iothread,id=colo-compare-iothread-1"));

You don't need GCSPRINTF here anymore ;-), in fact, it doesn't build with
it. With that fix:
Reviewed-by: Anthony PERARD <anthony.perard@citrix.com>

Thanks,
diff mbox series

Patch

diff --git a/tools/libxl/libxl_dm.c b/tools/libxl/libxl_dm.c
index f4fc96415d..4b029d6c8e 100644
--- a/tools/libxl/libxl_dm.c
+++ b/tools/libxl/libxl_dm.c
@@ -1635,7 +1635,10 @@  static int libxl__build_device_model_args_new(libxl__gc *gc,
                         nics[i].colo_compare_notify_dev) {
                         flexarray_append(dm_args, "-object");
                         flexarray_append(dm_args,
-                           GCSPRINTF("colo-compare,id=c1,primary_in=%s,secondary_in=%s,outdev=%s,notify_dev=%s",
+                           GCSPRINTF("iothread,id=colo-compare-iothread-1"));
+                        flexarray_append(dm_args, "-object");
+                        flexarray_append(dm_args,
+                           GCSPRINTF("colo-compare,id=c1,primary_in=%s,secondary_in=%s,outdev=%s,notify_dev=%s,iothread=colo-compare-iothread-1",
                                      nics[i].colo_compare_pri_in,
                                      nics[i].colo_compare_sec_in,
                                      nics[i].colo_compare_out,