qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
* [Qemu-devel] [PULL 0/5] Migration pull request
@ 2015-11-04 12:48 Juan Quintela
  2015-11-05 10:48 ` Peter Maydell
  0 siblings, 1 reply; 20+ messages in thread
From: Juan Quintela @ 2015-11-04 12:48 UTC (permalink / raw)
  To: qemu-devel; +Cc: amit.shah, dgilbert

Hi

This is the pull request for migration, it includes:

- Liang Li series for improving migration downtime
- Mark Cave-Ayland fix to analyze-migration script

Please, apply

The following changes since commit 79cf9fad341e6e7bd6b55395b71d5c5727d7f5b0:

  Merge remote-tracking branch 'remotes/pmaydell/tags/pull-target-arm-20151103' into staging (2015-11-03 14:54:40 +0000)

are available in the git repository at:

  git://github.com/juanquintela/qemu.git tags/migration/20151104

for you to fetch changes up to 96e5c9bc77acef8b7b56cbe23a8a2611feff9e34:

  migration: fix analyze-migration.py script (2015-11-04 13:40:13 +0100)

----------------------------------------------------------------
migration/next for 20151104

----------------------------------------------------------------
Liang Li (4):
      migration: defer migration_end & blk_mig_cleanup
      migration: rename qemu_savevm_state_cancel
      migration: rename cancel to cleanup in SaveVMHandles
      migration: code clean up

Mark Cave-Ayland (1):
      migration: fix analyze-migration.py script

 include/migration/vmstate.h  |  2 +-
 include/sysemu/sysemu.h      |  2 +-
 migration/block.c            | 10 ++--------
 migration/migration.c        | 13 ++++++-------
 migration/ram.c              | 10 ++--------
 migration/savevm.c           | 10 +++++-----
 scripts/analyze-migration.py | 13 +++++++++++++
 trace-events                 |  2 +-
 8 files changed, 31 insertions(+), 31 deletions(-)

^ permalink raw reply	[flat|nested] 20+ messages in thread

* Re: [Qemu-devel] [PULL 0/5] Migration pull request
  2015-11-04 12:48 Juan Quintela
@ 2015-11-05 10:48 ` Peter Maydell
  0 siblings, 0 replies; 20+ messages in thread
From: Peter Maydell @ 2015-11-05 10:48 UTC (permalink / raw)
  To: Juan Quintela; +Cc: Amit Shah, QEMU Developers, Dr. David Alan Gilbert

On 4 November 2015 at 12:48, Juan Quintela <quintela@redhat.com> wrote:
> Hi
>
> This is the pull request for migration, it includes:
>
> - Liang Li series for improving migration downtime
> - Mark Cave-Ayland fix to analyze-migration script
>
> Please, apply
>
> The following changes since commit 79cf9fad341e6e7bd6b55395b71d5c5727d7f5b0:
>
>   Merge remote-tracking branch 'remotes/pmaydell/tags/pull-target-arm-20151103' into staging (2015-11-03 14:54:40 +0000)
>
> are available in the git repository at:
>
>   git://github.com/juanquintela/qemu.git tags/migration/20151104
>
> for you to fetch changes up to 96e5c9bc77acef8b7b56cbe23a8a2611feff9e34:
>
>   migration: fix analyze-migration.py script (2015-11-04 13:40:13 +0100)
>
> ----------------------------------------------------------------
> migration/next for 20151104
>
> ----------------------------------------------------------------

Applied, thanks.

-- PMM

^ permalink raw reply	[flat|nested] 20+ messages in thread

* [Qemu-devel] [PULL 0/5] Migration pull request
@ 2017-05-12 15:52 Juan Quintela
  2017-05-15 13:58 ` Stefan Hajnoczi
  2017-05-16 14:35 ` Stefan Hajnoczi
  0 siblings, 2 replies; 20+ messages in thread
From: Juan Quintela @ 2017-05-12 15:52 UTC (permalink / raw)
  To: qemu-devel; +Cc: dgilbert, lvivier, peterx

Hi

This pull contains:
- Fix regression with compression threads (mea culpa)
- start of includes migration (creating of blocker.h header)
- Use Error** correctly after several iterations
- Rename of RAM_SAVE_FLAG_COMPRESS
- Create block capabilities for shared and enable

Please, apply.



The following changes since commit ecc1f5adeec4e3324d1b695a7c54e3967c526949:

  maintainers: Add myself as linux-user reviewer (2017-05-11 13:31:11 -0400)

are available in the git repository at:

  git://github.com/juanquintela/qemu.git tags/migration/20170512

for you to fetch changes up to f15e5850905dea6a09e29ef14df508ec236321d9:

  migration: Create migration/blocker.h (2017-05-12 17:10:57 +0200)

----------------------------------------------------------------
migration/next for 20170512

----------------------------------------------------------------
Juan Quintela (5):
      migration: Fix regression with compression threads
      migration: Pass Error ** argument to {save,load}_vmstate
      ram: Rename RAM_SAVE_FLAG_COMPRESS to RAM_SAVE_FLAG_ZERO
      migration: Create block capabilities for shared and enable
      migration: Create migration/blocker.h

 block/qcow.c                  |  2 +-
 block/vdi.c                   |  2 +-
 block/vhdx.c                  |  2 +-
 block/vmdk.c                  |  2 +-
 block/vpc.c                   |  2 +-
 block/vvfat.c                 |  2 +-
 hmp.c                         |  9 ++++++--
 hw/9pfs/9p.c                  |  2 +-
 hw/display/qxl.c              |  2 +-
 hw/display/virtio-gpu.c       |  2 +-
 hw/intc/arm_gic_kvm.c         |  2 +-
 hw/intc/arm_gicv3_its_kvm.c   |  2 +-
 hw/intc/arm_gicv3_kvm.c       |  2 +-
 hw/misc/ivshmem.c             |  2 +-
 hw/scsi/vhost-scsi.c          |  2 +-
 hw/virtio/vhost.c             |  2 +-
 include/migration/block.h     |  3 +++
 include/migration/blocker.h   | 35 +++++++++++++++++++++++++++++
 include/migration/migration.h | 21 +++---------------
 include/sysemu/sysemu.h       |  4 ++--
 migration/migration.c         | 37 +++++++++++++++++++++++++++++++
 migration/ram.c               | 35 +++++++++++++++++------------
 migration/savevm.c            | 51 +++++++++++++++++++++----------------------
 qapi-schema.json              |  7 +++++-
 replay/replay-snapshot.c      |  8 +++++--
 stubs/migr-blocker.c          |  2 +-
 target/i386/kvm.c             |  2 +-
 vl.c                          |  4 +++-
 28 files changed, 165 insertions(+), 83 deletions(-)
 create mode 100644 include/migration/blocker.h

^ permalink raw reply	[flat|nested] 20+ messages in thread

* Re: [Qemu-devel] [PULL 0/5] Migration pull request
  2017-05-12 15:52 [Qemu-devel] [PULL 0/5] Migration pull request Juan Quintela
@ 2017-05-15 13:58 ` Stefan Hajnoczi
  2017-05-15 14:52   ` Eric Blake
  2017-05-15 17:17   ` Juan Quintela
  2017-05-16 14:35 ` Stefan Hajnoczi
  1 sibling, 2 replies; 20+ messages in thread
From: Stefan Hajnoczi @ 2017-05-15 13:58 UTC (permalink / raw)
  To: Juan Quintela; +Cc: qemu-devel, lvivier, dgilbert, peterx

[-- Attachment #1: Type: text/plain, Size: 2888 bytes --]

On Fri, May 12, 2017 at 05:52:44PM +0200, Juan Quintela wrote:
> Hi
> 
> This pull contains:
> - Fix regression with compression threads (mea culpa)
> - start of includes migration (creating of blocker.h header)
> - Use Error** correctly after several iterations
> - Rename of RAM_SAVE_FLAG_COMPRESS
> - Create block capabilities for shared and enable
> 
> Please, apply.
> 
> 
> 
> The following changes since commit ecc1f5adeec4e3324d1b695a7c54e3967c526949:
> 
>   maintainers: Add myself as linux-user reviewer (2017-05-11 13:31:11 -0400)
> 
> are available in the git repository at:
> 
>   git://github.com/juanquintela/qemu.git tags/migration/20170512
> 
> for you to fetch changes up to f15e5850905dea6a09e29ef14df508ec236321d9:
> 
>   migration: Create migration/blocker.h (2017-05-12 17:10:57 +0200)
> 
> ----------------------------------------------------------------
> migration/next for 20170512
> 
> ----------------------------------------------------------------
> Juan Quintela (5):
>       migration: Fix regression with compression threads
>       migration: Pass Error ** argument to {save,load}_vmstate
>       ram: Rename RAM_SAVE_FLAG_COMPRESS to RAM_SAVE_FLAG_ZERO
>       migration: Create block capabilities for shared and enable
>       migration: Create migration/blocker.h
> 
>  block/qcow.c                  |  2 +-
>  block/vdi.c                   |  2 +-
>  block/vhdx.c                  |  2 +-
>  block/vmdk.c                  |  2 +-
>  block/vpc.c                   |  2 +-
>  block/vvfat.c                 |  2 +-
>  hmp.c                         |  9 ++++++--
>  hw/9pfs/9p.c                  |  2 +-
>  hw/display/qxl.c              |  2 +-
>  hw/display/virtio-gpu.c       |  2 +-
>  hw/intc/arm_gic_kvm.c         |  2 +-
>  hw/intc/arm_gicv3_its_kvm.c   |  2 +-
>  hw/intc/arm_gicv3_kvm.c       |  2 +-
>  hw/misc/ivshmem.c             |  2 +-
>  hw/scsi/vhost-scsi.c          |  2 +-
>  hw/virtio/vhost.c             |  2 +-
>  include/migration/block.h     |  3 +++
>  include/migration/blocker.h   | 35 +++++++++++++++++++++++++++++
>  include/migration/migration.h | 21 +++---------------
>  include/sysemu/sysemu.h       |  4 ++--
>  migration/migration.c         | 37 +++++++++++++++++++++++++++++++
>  migration/ram.c               | 35 +++++++++++++++++------------
>  migration/savevm.c            | 51 +++++++++++++++++++++----------------------
>  qapi-schema.json              |  7 +++++-
>  replay/replay-snapshot.c      |  8 +++++--
>  stubs/migr-blocker.c          |  2 +-
>  target/i386/kvm.c             |  2 +-
>  vl.c                          |  4 +++-
>  28 files changed, 165 insertions(+), 83 deletions(-)
>  create mode 100644 include/migration/blocker.h
> 

Thanks, applied to my staging tree:
https://github.com/stefanha/qemu/commits/staging

Stefan

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 455 bytes --]

^ permalink raw reply	[flat|nested] 20+ messages in thread

* Re: [Qemu-devel] [PULL 0/5] Migration pull request
  2017-05-15 13:58 ` Stefan Hajnoczi
@ 2017-05-15 14:52   ` Eric Blake
  2017-05-15 17:17   ` Juan Quintela
  1 sibling, 0 replies; 20+ messages in thread
From: Eric Blake @ 2017-05-15 14:52 UTC (permalink / raw)
  To: Stefan Hajnoczi, Juan Quintela; +Cc: lvivier, qemu-devel, peterx, dgilbert

[-- Attachment #1: Type: text/plain, Size: 769 bytes --]

On 05/15/2017 08:58 AM, Stefan Hajnoczi wrote:

>> ----------------------------------------------------------------
>> Juan Quintela (5):
>>       migration: Fix regression with compression threads
>>       migration: Pass Error ** argument to {save,load}_vmstate
>>       ram: Rename RAM_SAVE_FLAG_COMPRESS to RAM_SAVE_FLAG_ZERO
>>       migration: Create block capabilities for shared and enable

We may still end up changing our representation of these capabilities (I
don't think the design discussion has completed) - but as long as we get
it done before 2.10, I don't see a reason to have to unstage the pull
request.

-- 
Eric Blake, Principal Software Engineer
Red Hat, Inc.           +1-919-301-3266
Virtualization:  qemu.org | libvirt.org


[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 604 bytes --]

^ permalink raw reply	[flat|nested] 20+ messages in thread

* Re: [Qemu-devel] [PULL 0/5] Migration pull request
  2017-05-15 13:58 ` Stefan Hajnoczi
  2017-05-15 14:52   ` Eric Blake
@ 2017-05-15 17:17   ` Juan Quintela
  1 sibling, 0 replies; 20+ messages in thread
From: Juan Quintela @ 2017-05-15 17:17 UTC (permalink / raw)
  To: Stefan Hajnoczi; +Cc: qemu-devel, lvivier, dgilbert, peterx

Stefan Hajnoczi <stefanha@gmail.com> wrote:
> On Fri, May 12, 2017 at 05:52:44PM +0200, Juan Quintela wrote:
>> Hi
>> 
>> 
>
> Thanks, applied to my staging tree:
> https://github.com/stefanha/qemu/commits/staging

Hi

As fast as I sent the PULL request, more comments appeared.

What do you preffer?
- drop the whole PULL request?
- drop the patch:  migration: Create block capabilities for shared and enable
  it has zero conflicts with the other patches
- let the PULL alone and I will sent fixes on top of that?

I would preffer option two, but that is up to you.

Sorry for the inconvenience.

Later, Juan.

^ permalink raw reply	[flat|nested] 20+ messages in thread

* Re: [Qemu-devel] [PULL 0/5] Migration pull request
  2017-05-12 15:52 [Qemu-devel] [PULL 0/5] Migration pull request Juan Quintela
  2017-05-15 13:58 ` Stefan Hajnoczi
@ 2017-05-16 14:35 ` Stefan Hajnoczi
  1 sibling, 0 replies; 20+ messages in thread
From: Stefan Hajnoczi @ 2017-05-16 14:35 UTC (permalink / raw)
  To: Juan Quintela; +Cc: qemu-devel, Laurent Vivier, Dave Gilbert, peterx

On Fri, May 12, 2017 at 4:52 PM, Juan Quintela <quintela@redhat.com> wrote:
> Hi
>
> This pull contains:
> - Fix regression with compression threads (mea culpa)
> - start of includes migration (creating of blocker.h header)
> - Use Error** correctly after several iterations
> - Rename of RAM_SAVE_FLAG_COMPRESS
> - Create block capabilities for shared and enable
>
> Please, apply.

I have reverted the pull request at Juan's request.

Stefan

^ permalink raw reply	[flat|nested] 20+ messages in thread

* [Qemu-devel] [PULL 0/5] Migration pull request
@ 2017-05-31  9:15 Juan Quintela
  2017-05-31  9:15 ` [Qemu-devel] [PULL 1/5] migration: Create savevm.h for functions exported from savevm.c Juan Quintela
                   ` (5 more replies)
  0 siblings, 6 replies; 20+ messages in thread
From: Juan Quintela @ 2017-05-31  9:15 UTC (permalink / raw)
  To: qemu-devel; +Cc: dgilbert, lvivier, peterx

Hi

This are the migration patches ready for inclusion:
- autoconverge improvements: (felipe franciosi)
- create savem.h

Please, Apply.

The following changes since commit 0748b3526e8cb78b9cd64208426bfc3d54a72b04:

  Merge remote-tracking branch 'kwolf/tags/for-upstream' into staging (2017-05-30 14:15:15 +0100)

are available in the git repository at:

  git://github.com/juanquintela/qemu.git tags/migration/20170531

for you to fetch changes up to b4a3c64b16856a018869bfd4a9ed3b2a74554541:

  migration: use dirty_rate_high_cnt more aggressively (2017-05-31 09:39:20 +0200)

----------------------------------------------------------------
migration/next for 20170531

----------------------------------------------------------------
Felipe Franciosi (4):
      migration: keep bytes_xfer_prev init'd to zero
      migration: set dirty_pages_rate before autoconverge logic
      migration: set bytes_xfer_* outside of autoconverge logic
      migration: use dirty_rate_high_cnt more aggressively

Juan Quintela (1):
      migration: Create savevm.h for functions exported from savevm.c

 include/sysemu/sysemu.h  | 47 -----------------------------------------------
 migration/colo.c         |  1 +
 migration/migration.c    |  1 +
 migration/postcopy-ram.c |  1 +
 migration/ram.c          | 23 +++++++++++------------
 migration/savevm.c       | 29 +++++++++++++++++++++++++----
 migration/savevm.h       | 41 +++++++++++++++++++++++++++++++++++++++++
 7 files changed, 80 insertions(+), 63 deletions(-)
 create mode 100644 migration/savevm.h

^ permalink raw reply	[flat|nested] 20+ messages in thread

* [Qemu-devel] [PULL 1/5] migration: Create savevm.h for functions exported from savevm.c
  2017-05-31  9:15 [Qemu-devel] [PULL 0/5] Migration pull request Juan Quintela
@ 2017-05-31  9:15 ` Juan Quintela
  2017-05-31  9:15 ` [Qemu-devel] [PULL 2/5] migration: keep bytes_xfer_prev init'd to zero Juan Quintela
                   ` (4 subsequent siblings)
  5 siblings, 0 replies; 20+ messages in thread
From: Juan Quintela @ 2017-05-31  9:15 UTC (permalink / raw)
  To: qemu-devel; +Cc: dgilbert, lvivier, peterx

This removes last trace of migration functions from sysemu/sysemu.h.

Signed-off-by: Juan Quintela <quintela@redhat.com>
Reviewed-by: Laurent Vivier <lvivier@redhat.com>
---
 include/sysemu/sysemu.h  | 47 -----------------------------------------------
 migration/colo.c         |  1 +
 migration/migration.c    |  1 +
 migration/postcopy-ram.c |  1 +
 migration/savevm.c       | 29 +++++++++++++++++++++++++----
 migration/savevm.h       | 41 +++++++++++++++++++++++++++++++++++++++++
 6 files changed, 69 insertions(+), 51 deletions(-)
 create mode 100644 migration/savevm.h

diff --git a/include/sysemu/sysemu.h b/include/sysemu/sysemu.h
index 69046eb..723c8dc 100644
--- a/include/sysemu/sysemu.h
+++ b/include/sysemu/sysemu.h
@@ -97,53 +97,6 @@ int load_vmstate(const char *name, Error **errp);
 
 void qemu_announce_self(void);
 
-/* Subcommands for QEMU_VM_COMMAND */
-enum qemu_vm_cmd {
-    MIG_CMD_INVALID = 0,   /* Must be 0 */
-    MIG_CMD_OPEN_RETURN_PATH,  /* Tell the dest to open the Return path */
-    MIG_CMD_PING,              /* Request a PONG on the RP */
-
-    MIG_CMD_POSTCOPY_ADVISE,       /* Prior to any page transfers, just
-                                      warn we might want to do PC */
-    MIG_CMD_POSTCOPY_LISTEN,       /* Start listening for incoming
-                                      pages as it's running. */
-    MIG_CMD_POSTCOPY_RUN,          /* Start execution */
-
-    MIG_CMD_POSTCOPY_RAM_DISCARD,  /* A list of pages to discard that
-                                      were previously sent during
-                                      precopy but are dirty. */
-    MIG_CMD_PACKAGED,          /* Send a wrapped stream within this stream */
-    MIG_CMD_MAX
-};
-
-#define MAX_VM_CMD_PACKAGED_SIZE (1ul << 24)
-
-bool qemu_savevm_state_blocked(Error **errp);
-void qemu_savevm_state_begin(QEMUFile *f);
-void qemu_savevm_state_header(QEMUFile *f);
-int qemu_savevm_state_iterate(QEMUFile *f, bool postcopy);
-void qemu_savevm_state_cleanup(void);
-void qemu_savevm_state_complete_postcopy(QEMUFile *f);
-void qemu_savevm_state_complete_precopy(QEMUFile *f, bool iterable_only);
-void qemu_savevm_state_pending(QEMUFile *f, uint64_t max_size,
-                               uint64_t *res_non_postcopiable,
-                               uint64_t *res_postcopiable);
-void qemu_savevm_command_send(QEMUFile *f, enum qemu_vm_cmd command,
-                              uint16_t len, uint8_t *data);
-void qemu_savevm_send_ping(QEMUFile *f, uint32_t value);
-void qemu_savevm_send_open_return_path(QEMUFile *f);
-int qemu_savevm_send_packaged(QEMUFile *f, const uint8_t *buf, size_t len);
-void qemu_savevm_send_postcopy_advise(QEMUFile *f);
-void qemu_savevm_send_postcopy_listen(QEMUFile *f);
-void qemu_savevm_send_postcopy_run(QEMUFile *f);
-
-void qemu_savevm_send_postcopy_ram_discard(QEMUFile *f, const char *name,
-                                           uint16_t len,
-                                           uint64_t *start_list,
-                                           uint64_t *length_list);
-
-int qemu_loadvm_state(QEMUFile *f);
-
 extern int autostart;
 
 typedef enum {
diff --git a/migration/colo.c b/migration/colo.c
index 8c13a3c..3dd1390 100644
--- a/migration/colo.c
+++ b/migration/colo.c
@@ -16,6 +16,7 @@
 #include "qemu-file-channel.h"
 #include "migration/migration.h"
 #include "migration/qemu-file.h"
+#include "savevm.h"
 #include "migration/colo.h"
 #include "migration/block.h"
 #include "io/channel-buffer.h"
diff --git a/migration/migration.c b/migration/migration.c
index ad29e53..7087d1a 100644
--- a/migration/migration.c
+++ b/migration/migration.c
@@ -19,6 +19,7 @@
 #include "qemu/main-loop.h"
 #include "migration/blocker.h"
 #include "migration/migration.h"
+#include "savevm.h"
 #include "qemu-file-channel.h"
 #include "migration/qemu-file.h"
 #include "migration/vmstate.h"
diff --git a/migration/postcopy-ram.c b/migration/postcopy-ram.c
index a37620d..3f9ae1b 100644
--- a/migration/postcopy-ram.c
+++ b/migration/postcopy-ram.c
@@ -22,6 +22,7 @@
 #include "exec/target_page.h"
 #include "migration/migration.h"
 #include "migration/qemu-file.h"
+#include "savevm.h"
 #include "postcopy-ram.h"
 #include "sysemu/sysemu.h"
 #include "sysemu/balloon.h"
diff --git a/migration/savevm.c b/migration/savevm.c
index a4532b6..a2d4f9c 100644
--- a/migration/savevm.c
+++ b/migration/savevm.c
@@ -36,6 +36,7 @@
 #include "qemu/timer.h"
 #include "migration/migration.h"
 #include "qemu-file-channel.h"
+#include "savevm.h"
 #include "postcopy-ram.h"
 #include "qapi/qmp/qerror.h"
 #include "qemu/error-report.h"
@@ -63,6 +64,26 @@ const unsigned int postcopy_ram_discard_version = 0;
 
 static bool skip_section_footers;
 
+/* Subcommands for QEMU_VM_COMMAND */
+enum qemu_vm_cmd {
+    MIG_CMD_INVALID = 0,   /* Must be 0 */
+    MIG_CMD_OPEN_RETURN_PATH,  /* Tell the dest to open the Return path */
+    MIG_CMD_PING,              /* Request a PONG on the RP */
+
+    MIG_CMD_POSTCOPY_ADVISE,       /* Prior to any page transfers, just
+                                      warn we might want to do PC */
+    MIG_CMD_POSTCOPY_LISTEN,       /* Start listening for incoming
+                                      pages as it's running. */
+    MIG_CMD_POSTCOPY_RUN,          /* Start execution */
+
+    MIG_CMD_POSTCOPY_RAM_DISCARD,  /* A list of pages to discard that
+                                      were previously sent during
+                                      precopy but are dirty. */
+    MIG_CMD_PACKAGED,          /* Send a wrapped stream within this stream */
+    MIG_CMD_MAX
+};
+
+#define MAX_VM_CMD_PACKAGED_SIZE (1ul << 24)
 static struct mig_cmd_args {
     ssize_t     len; /* -1 = variable */
     const char *name;
@@ -807,10 +828,10 @@ static void save_section_footer(QEMUFile *f, SaveStateEntry *se)
  * @len: Length of associated data
  * @data: Data associated with command.
  */
-void qemu_savevm_command_send(QEMUFile *f,
-                              enum qemu_vm_cmd command,
-                              uint16_t len,
-                              uint8_t *data)
+static void qemu_savevm_command_send(QEMUFile *f,
+                                     enum qemu_vm_cmd command,
+                                     uint16_t len,
+                                     uint8_t *data)
 {
     trace_savevm_command_send(command, len);
     qemu_put_byte(f, QEMU_VM_COMMAND);
diff --git a/migration/savevm.h b/migration/savevm.h
new file mode 100644
index 0000000..eb44877
--- /dev/null
+++ b/migration/savevm.h
@@ -0,0 +1,41 @@
+/*
+ * QEMU save vm functions
+ *
+ * Copyright (c) 2003-2008 Fabrice Bellard
+ * Copyright (c) 2009-2017 Red Hat Inc
+ *
+ * Authors:
+ *  Juan Quintela <quintela@redhat.com>
+ *
+ * This work is licensed under the terms of the GNU GPL, version 2 or later.
+ * See the COPYING file in the top-level directory.
+ */
+
+#ifndef MIGRATION_SAVEVM_H
+#define MIGRATION_SAVEVM_H
+
+bool qemu_savevm_state_blocked(Error **errp);
+void qemu_savevm_state_begin(QEMUFile *f);
+void qemu_savevm_state_header(QEMUFile *f);
+int qemu_savevm_state_iterate(QEMUFile *f, bool postcopy);
+void qemu_savevm_state_cleanup(void);
+void qemu_savevm_state_complete_postcopy(QEMUFile *f);
+void qemu_savevm_state_complete_precopy(QEMUFile *f, bool iterable_only);
+void qemu_savevm_state_pending(QEMUFile *f, uint64_t max_size,
+                               uint64_t *res_non_postcopiable,
+                               uint64_t *res_postcopiable);
+void qemu_savevm_send_ping(QEMUFile *f, uint32_t value);
+void qemu_savevm_send_open_return_path(QEMUFile *f);
+int qemu_savevm_send_packaged(QEMUFile *f, const uint8_t *buf, size_t len);
+void qemu_savevm_send_postcopy_advise(QEMUFile *f);
+void qemu_savevm_send_postcopy_listen(QEMUFile *f);
+void qemu_savevm_send_postcopy_run(QEMUFile *f);
+
+void qemu_savevm_send_postcopy_ram_discard(QEMUFile *f, const char *name,
+                                           uint16_t len,
+                                           uint64_t *start_list,
+                                           uint64_t *length_list);
+
+int qemu_loadvm_state(QEMUFile *f);
+
+#endif
-- 
2.9.4

^ permalink raw reply related	[flat|nested] 20+ messages in thread

* [Qemu-devel] [PULL 2/5] migration: keep bytes_xfer_prev init'd to zero
  2017-05-31  9:15 [Qemu-devel] [PULL 0/5] Migration pull request Juan Quintela
  2017-05-31  9:15 ` [Qemu-devel] [PULL 1/5] migration: Create savevm.h for functions exported from savevm.c Juan Quintela
@ 2017-05-31  9:15 ` Juan Quintela
  2017-05-31  9:15 ` [Qemu-devel] [PULL 3/5] migration: set dirty_pages_rate before autoconverge logic Juan Quintela
                   ` (3 subsequent siblings)
  5 siblings, 0 replies; 20+ messages in thread
From: Juan Quintela @ 2017-05-31  9:15 UTC (permalink / raw)
  To: qemu-devel; +Cc: dgilbert, lvivier, peterx, Felipe Franciosi

From: Felipe Franciosi <felipe@nutanix.com>

The first time migration_bitmap_sync() is called, bytes_xfer_prev is set
to ram_state.bytes_transferred which is, at this point, zero. The next
time migration_bitmap_sync() is called, an iteration has happened and
bytes_xfer_prev is set to 'x' bytes. Most likely, more than one second
has passed, so the auto converge logic will be triggered and
bytes_xfer_now will also be set to 'x' bytes.

This condition is currently masked by dirty_rate_high_cnt, which will
wait for a few iterations before throttling. It would otherwise always
assume zero bytes have been copied and therefore throttle the guest
(possibly) prematurely.

Given bytes_xfer_prev is only used by the auto convergence logic, it
makes sense to only set its value after a check has been made against
bytes_xfer_now.

Signed-off-by: Felipe Franciosi <felipe@nutanix.com>
Reviewed-by: Peter Xu <peterx@redhat.com>
Reviewed-by: Juan Quintela <quintela@redhat.com>
Signed-off-by: Juan Quintela <quintela@redhat.com>
---
 migration/ram.c | 4 ----
 1 file changed, 4 deletions(-)

diff --git a/migration/ram.c b/migration/ram.c
index c07a9c0..36bf720 100644
--- a/migration/ram.c
+++ b/migration/ram.c
@@ -673,10 +673,6 @@ static void migration_bitmap_sync(RAMState *rs)
 
     rs->bitmap_sync_count++;
 
-    if (!rs->bytes_xfer_prev) {
-        rs->bytes_xfer_prev = ram_bytes_transferred();
-    }
-
     if (!rs->time_last_bitmap_sync) {
         rs->time_last_bitmap_sync = qemu_clock_get_ms(QEMU_CLOCK_REALTIME);
     }
-- 
2.9.4

^ permalink raw reply related	[flat|nested] 20+ messages in thread

* [Qemu-devel] [PULL 3/5] migration: set dirty_pages_rate before autoconverge logic
  2017-05-31  9:15 [Qemu-devel] [PULL 0/5] Migration pull request Juan Quintela
  2017-05-31  9:15 ` [Qemu-devel] [PULL 1/5] migration: Create savevm.h for functions exported from savevm.c Juan Quintela
  2017-05-31  9:15 ` [Qemu-devel] [PULL 2/5] migration: keep bytes_xfer_prev init'd to zero Juan Quintela
@ 2017-05-31  9:15 ` Juan Quintela
  2017-05-31  9:15 ` [Qemu-devel] [PULL 4/5] migration: set bytes_xfer_* outside of " Juan Quintela
                   ` (2 subsequent siblings)
  5 siblings, 0 replies; 20+ messages in thread
From: Juan Quintela @ 2017-05-31  9:15 UTC (permalink / raw)
  To: qemu-devel; +Cc: dgilbert, lvivier, peterx, Felipe Franciosi

From: Felipe Franciosi <felipe@nutanix.com>

Currently, a "period" in the RAM migration logic is at least a second
long and accounts for what happened since the last period (or the
beginning of the migration). The dirty_pages_rate counter is calculated
at the end this logic.

If the auto convergence capability is enabled from the start of the
migration, it won't be able to use this counter the first time around.
This calculates dirty_pages_rate as soon as a period is deemed over,
which allows for it to be used immediately.

Signed-off-by: Felipe Franciosi <felipe@nutanix.com>
Reviewed-by: Peter Xu <peterx@redhat.com>
Reviewed-by: Juan Quintela <quintela@redhat.com>
Signed-off-by: Juan Quintela <quintela@redhat.com>
---
 migration/ram.c | 17 ++++++++++-------
 1 file changed, 10 insertions(+), 7 deletions(-)

diff --git a/migration/ram.c b/migration/ram.c
index 36bf720..495ecbe 100644
--- a/migration/ram.c
+++ b/migration/ram.c
@@ -694,6 +694,10 @@ static void migration_bitmap_sync(RAMState *rs)
 
     /* more than 1 second = 1000 millisecons */
     if (end_time > rs->time_last_bitmap_sync + 1000) {
+        /* calculate period counters */
+        rs->dirty_pages_rate = rs->num_dirty_pages_period * 1000
+            / (end_time - rs->time_last_bitmap_sync);
+
         if (migrate_auto_converge()) {
             /* The following detection logic can be refined later. For now:
                Check to see if the dirtied bytes is 50% more than the approx.
@@ -702,15 +706,14 @@ static void migration_bitmap_sync(RAMState *rs)
                throttling */
             bytes_xfer_now = ram_bytes_transferred();
 
-            if (rs->dirty_pages_rate &&
-               (rs->num_dirty_pages_period * TARGET_PAGE_SIZE >
+            if ((rs->num_dirty_pages_period * TARGET_PAGE_SIZE >
                    (bytes_xfer_now - rs->bytes_xfer_prev) / 2) &&
-               (rs->dirty_rate_high_cnt++ >= 2)) {
+                (rs->dirty_rate_high_cnt++ >= 2)) {
                     trace_migration_throttle();
                     rs->dirty_rate_high_cnt = 0;
                     mig_throttle_guest_down();
-             }
-             rs->bytes_xfer_prev = bytes_xfer_now;
+            }
+            rs->bytes_xfer_prev = bytes_xfer_now;
         }
 
         if (migrate_use_xbzrle()) {
@@ -723,8 +726,8 @@ static void migration_bitmap_sync(RAMState *rs)
             rs->iterations_prev = rs->iterations;
             rs->xbzrle_cache_miss_prev = rs->xbzrle_cache_miss;
         }
-        rs->dirty_pages_rate = rs->num_dirty_pages_period * 1000
-            / (end_time - rs->time_last_bitmap_sync);
+
+        /* reset period counters */
         rs->time_last_bitmap_sync = end_time;
         rs->num_dirty_pages_period = 0;
     }
-- 
2.9.4

^ permalink raw reply related	[flat|nested] 20+ messages in thread

* [Qemu-devel] [PULL 4/5] migration: set bytes_xfer_* outside of autoconverge logic
  2017-05-31  9:15 [Qemu-devel] [PULL 0/5] Migration pull request Juan Quintela
                   ` (2 preceding siblings ...)
  2017-05-31  9:15 ` [Qemu-devel] [PULL 3/5] migration: set dirty_pages_rate before autoconverge logic Juan Quintela
@ 2017-05-31  9:15 ` Juan Quintela
  2017-05-31  9:15 ` [Qemu-devel] [PULL 5/5] migration: use dirty_rate_high_cnt more aggressively Juan Quintela
  2017-06-01 14:50 ` [Qemu-devel] [PULL 0/5] Migration pull request Peter Maydell
  5 siblings, 0 replies; 20+ messages in thread
From: Juan Quintela @ 2017-05-31  9:15 UTC (permalink / raw)
  To: qemu-devel; +Cc: dgilbert, lvivier, peterx, Felipe Franciosi

From: Felipe Franciosi <felipe@nutanix.com>

The bytes_xfer_now/prev counters are only used by the auto convergence
logic. However, they are used alongside the dirty_pages_rate counter,
which is calculated (and required) outside of this logic. The problem
with this approach is that if the auto convergence capability is changed
while a migration is ongoing, the relationship of the counters will be
broken.

This moves the management of bytes_xfer_now/prev counters outside of the
auto convergence logic to address this issue.

Signed-off-by: Felipe Franciosi <felipe@nutanix.com>
Reviewed-by: Peter Xu <peterx@redhat.com>
Reviewed-by: Juan Quintela <quintela@redhat.com>
Signed-off-by: Juan Quintela <quintela@redhat.com>
---
 migration/ram.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/migration/ram.c b/migration/ram.c
index 495ecbe..1a3d9e6 100644
--- a/migration/ram.c
+++ b/migration/ram.c
@@ -697,6 +697,7 @@ static void migration_bitmap_sync(RAMState *rs)
         /* calculate period counters */
         rs->dirty_pages_rate = rs->num_dirty_pages_period * 1000
             / (end_time - rs->time_last_bitmap_sync);
+        bytes_xfer_now = ram_bytes_transferred();
 
         if (migrate_auto_converge()) {
             /* The following detection logic can be refined later. For now:
@@ -704,7 +705,6 @@ static void migration_bitmap_sync(RAMState *rs)
                amount of bytes that just got transferred since the last time we
                were in this routine. If that happens twice, start or increase
                throttling */
-            bytes_xfer_now = ram_bytes_transferred();
 
             if ((rs->num_dirty_pages_period * TARGET_PAGE_SIZE >
                    (bytes_xfer_now - rs->bytes_xfer_prev) / 2) &&
@@ -713,7 +713,6 @@ static void migration_bitmap_sync(RAMState *rs)
                     rs->dirty_rate_high_cnt = 0;
                     mig_throttle_guest_down();
             }
-            rs->bytes_xfer_prev = bytes_xfer_now;
         }
 
         if (migrate_use_xbzrle()) {
@@ -730,6 +729,7 @@ static void migration_bitmap_sync(RAMState *rs)
         /* reset period counters */
         rs->time_last_bitmap_sync = end_time;
         rs->num_dirty_pages_period = 0;
+        rs->bytes_xfer_prev = bytes_xfer_now;
     }
     if (migrate_use_events()) {
         qapi_event_send_migration_pass(rs->bitmap_sync_count, NULL);
-- 
2.9.4

^ permalink raw reply related	[flat|nested] 20+ messages in thread

* [Qemu-devel] [PULL 5/5] migration: use dirty_rate_high_cnt more aggressively
  2017-05-31  9:15 [Qemu-devel] [PULL 0/5] Migration pull request Juan Quintela
                   ` (3 preceding siblings ...)
  2017-05-31  9:15 ` [Qemu-devel] [PULL 4/5] migration: set bytes_xfer_* outside of " Juan Quintela
@ 2017-05-31  9:15 ` Juan Quintela
  2017-06-01 14:50 ` [Qemu-devel] [PULL 0/5] Migration pull request Peter Maydell
  5 siblings, 0 replies; 20+ messages in thread
From: Juan Quintela @ 2017-05-31  9:15 UTC (permalink / raw)
  To: qemu-devel; +Cc: dgilbert, lvivier, peterx, Felipe Franciosi

From: Felipe Franciosi <felipe@nutanix.com>

The commit message from 070afca25 suggests that dirty_rate_high_cnt
should be used more aggressively to start throttling after two
iterations instead of four. The code, however, only changes the auto
convergence behaviour to throttle after three iterations. This makes the
behaviour more aggressive by kicking off throttling after two iterations
as originally intended.

Signed-off-by: Felipe Franciosi <felipe@nutanix.com>
Reviewed-by: Peter Xu <peterx@redhat.com>
Reviewed-by: Juan Quintela <quintela@redhat.com>
Signed-off-by: Juan Quintela <quintela@redhat.com>
---
 migration/ram.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/migration/ram.c b/migration/ram.c
index 1a3d9e6..26e03a5 100644
--- a/migration/ram.c
+++ b/migration/ram.c
@@ -708,7 +708,7 @@ static void migration_bitmap_sync(RAMState *rs)
 
             if ((rs->num_dirty_pages_period * TARGET_PAGE_SIZE >
                    (bytes_xfer_now - rs->bytes_xfer_prev) / 2) &&
-                (rs->dirty_rate_high_cnt++ >= 2)) {
+                (++rs->dirty_rate_high_cnt >= 2)) {
                     trace_migration_throttle();
                     rs->dirty_rate_high_cnt = 0;
                     mig_throttle_guest_down();
-- 
2.9.4

^ permalink raw reply related	[flat|nested] 20+ messages in thread

* Re: [Qemu-devel] [PULL 0/5] Migration pull request
  2017-05-31  9:15 [Qemu-devel] [PULL 0/5] Migration pull request Juan Quintela
                   ` (4 preceding siblings ...)
  2017-05-31  9:15 ` [Qemu-devel] [PULL 5/5] migration: use dirty_rate_high_cnt more aggressively Juan Quintela
@ 2017-06-01 14:50 ` Peter Maydell
  5 siblings, 0 replies; 20+ messages in thread
From: Peter Maydell @ 2017-06-01 14:50 UTC (permalink / raw)
  To: Juan Quintela
  Cc: QEMU Developers, Laurent Vivier, Dr. David Alan Gilbert, Peter Xu

On 31 May 2017 at 10:15, Juan Quintela <quintela@redhat.com> wrote:
> Hi
>
> This are the migration patches ready for inclusion:
> - autoconverge improvements: (felipe franciosi)
> - create savem.h
>
> Please, Apply.
>
> The following changes since commit 0748b3526e8cb78b9cd64208426bfc3d54a72b04:
>
>   Merge remote-tracking branch 'kwolf/tags/for-upstream' into staging (2017-05-30 14:15:15 +0100)
>
> are available in the git repository at:
>
>   git://github.com/juanquintela/qemu.git tags/migration/20170531
>
> for you to fetch changes up to b4a3c64b16856a018869bfd4a9ed3b2a74554541:
>
>   migration: use dirty_rate_high_cnt more aggressively (2017-05-31 09:39:20 +0200)
>
> ----------------------------------------------------------------
> migration/next for 20170531
>
> ----------------------------------------------------------------
> Felipe Franciosi (4):
>       migration: keep bytes_xfer_prev init'd to zero
>       migration: set dirty_pages_rate before autoconverge logic
>       migration: set bytes_xfer_* outside of autoconverge logic
>       migration: use dirty_rate_high_cnt more aggressively
>
> Juan Quintela (1):
>       migration: Create savevm.h for functions exported from savevm.c

Applied, thanks.

-- PMM

^ permalink raw reply	[flat|nested] 20+ messages in thread

* [Qemu-devel] [PULL 0/5] Migration PULL request
@ 2017-06-14 11:51 Juan Quintela
  2017-06-15 11:56 ` Peter Maydell
  0 siblings, 1 reply; 20+ messages in thread
From: Juan Quintela @ 2017-06-14 11:51 UTC (permalink / raw)
  To: qemu-devel; +Cc: dgilbert, lvivier, peterx

Hi

In this pull requset:
- I included the v1 of peter return path, fix it
- fix the compliation with older compilers (new compliers don't
   complain about a repeated typedef, so I didn't noticed)
- Add test for disabled features
- Last bit of misc cleanup, remove of not needed includes

Please, apply.

Thanks, Juan.

The following changes since commit 3f0602927b120a480b35dcf58cf6f95435b3ae91:

  Merge remote-tracking branch 'remotes/pmaydell/tags/pull-target-arm-20170613' into staging (2017-06-13 15:49:07 +0100)

are available in the git repository at:

  git://github.com/juanquintela/qemu.git tags/migration/20170614

for you to fetch changes up to 3416ab5bb452f1b6cea58aed8983ffb9a455b7c4:

  migration: Don't create decompression threads if not enabled (2017-06-14 11:11:06 +0200)

----------------------------------------------------------------
migration/next for 20170614

----------------------------------------------------------------
Juan Quintela (4):
      migration: Fix compilation with older compilers
      migration: Remove unneeded includes
      migration: Test for disabled features on reception
      migration: Don't create decompression threads if not enabled

Peter Xu (1):
      migration: fix incorrect enable return path

 include/migration/colo.h     |  3 ---
 include/migration/misc.h     |  2 ++
 include/migration/register.h |  3 ---
 include/migration/vmstate.h  |  1 -
 include/qemu/typedefs.h      |  2 ++
 migration/block.c            |  6 ------
 migration/colo-failover.c    |  2 ++
 migration/colo.c             |  2 --
 migration/exec.c             |  2 --
 migration/fd.c               |  2 --
 migration/global_state.c     |  1 -
 migration/migration.c        | 12 +++++-------
 migration/migration.h        |  2 --
 migration/postcopy-ram.c     |  2 --
 migration/qemu-file.c        |  2 --
 migration/ram.c              | 24 +++++++++++++++++++-----
 migration/savevm.c           |  6 ------
 17 files changed, 30 insertions(+), 44 deletions(-)

^ permalink raw reply	[flat|nested] 20+ messages in thread

* Re: [Qemu-devel] [PULL 0/5] Migration PULL request
  2017-06-14 11:51 [Qemu-devel] [PULL 0/5] Migration PULL request Juan Quintela
@ 2017-06-15 11:56 ` Peter Maydell
  0 siblings, 0 replies; 20+ messages in thread
From: Peter Maydell @ 2017-06-15 11:56 UTC (permalink / raw)
  To: Juan Quintela
  Cc: QEMU Developers, Laurent Vivier, Dr. David Alan Gilbert, Peter Xu

On 14 June 2017 at 12:51, Juan Quintela <quintela@redhat.com> wrote:
> Hi
>
> In this pull requset:
> - I included the v1 of peter return path, fix it
> - fix the compliation with older compilers (new compliers don't
>    complain about a repeated typedef, so I didn't noticed)
> - Add test for disabled features
> - Last bit of misc cleanup, remove of not needed includes
>
> Please, apply.
>
> Thanks, Juan.
>
> The following changes since commit 3f0602927b120a480b35dcf58cf6f95435b3ae91:
>
>   Merge remote-tracking branch 'remotes/pmaydell/tags/pull-target-arm-20170613' into staging (2017-06-13 15:49:07 +0100)
>
> are available in the git repository at:
>
>   git://github.com/juanquintela/qemu.git tags/migration/20170614
>
> for you to fetch changes up to 3416ab5bb452f1b6cea58aed8983ffb9a455b7c4:
>
>   migration: Don't create decompression threads if not enabled (2017-06-14 11:11:06 +0200)
>
> ----------------------------------------------------------------
> migration/next for 20170614
>

Applied, thanks.

-- PMM

^ permalink raw reply	[flat|nested] 20+ messages in thread

* [Qemu-devel] [PULL 0/5] Migration pull request
@ 2018-06-04  4:21 Juan Quintela
  2018-06-04  4:29 ` no-reply
  2018-06-04 13:24 ` Peter Maydell
  0 siblings, 2 replies; 20+ messages in thread
From: Juan Quintela @ 2018-06-04  4:21 UTC (permalink / raw)
  To: qemu-devel; +Cc: dgilbert, lvivier, peterx

The following changes since commit 392fba9f583223786f844dce9b2e7f9a0ce0147a:

  Merge remote-tracking branch 'remotes/stsquad/tags/pull-travis-updates-010618-1' into staging (2018-06-01 17:32:30 +0100)

are available in the Git repository at:

  git://github.com/juanquintela/qemu.git tags/migration/20180604

for you to fetch changes up to c5e76115ccb4979cec795a8ae38becd07c2fde9f:

  migration: not wait RDMA_CM_EVENT_DISCONNECTED event after rdma_disconnect (2018-06-04 05:46:15 +0200)

----------------------------------------------------------------
migration/next for 20180604

- RDMA fixes from (lidong)
- Fix docempress-error-check (Xiao)
- make -S and block work better (dave)
- don't migrate "bad" ramblocks (Cédric)

Please apply, Juan.

----------------------------------------------------------------
Cédric Le Goater (1):
      migration: discard non-migratable RAMBlocks

Dr. David Alan Gilbert (1):
      migration: Don't activate block devices if using -S

Lidong Chen (2):
      migration: remove unnecessary variables len in QIOChannelRDMA
      migration: not wait RDMA_CM_EVENT_DISCONNECTED event after rdma_disconnect

Xiao Guangrong (1):
      migration: introduce decompress-error-check

 exec.c                    | 38 +++++++++++++++++++++++++++++++++++++
 hw/arm/virt.c             |  4 ++++
 hw/i386/pc_piix.c         |  1 +
 hw/i386/pc_q35.c          |  1 +
 include/exec/cpu-common.h |  4 ++++
 include/hw/compat.h       |  7 ++++++-
 migration/migration.c     | 38 ++++++++++++++++++++++++++++++-------
 migration/migration.h     |  7 +++++++
 migration/postcopy-ram.c  | 12 ++++++------
 migration/ram.c           | 48 ++++++++++++++++++++++++++++++++++-------------
 migration/rdma.c          | 27 +++++++++-----------------
 migration/savevm.c        |  2 ++
 migration/trace-events    |  1 -
 qapi/migration.json       |  6 +++++-
 14 files changed, 149 insertions(+), 47 deletions(-)

^ permalink raw reply	[flat|nested] 20+ messages in thread

* Re: [Qemu-devel] [PULL 0/5] Migration pull request
  2018-06-04  4:21 Juan Quintela
@ 2018-06-04  4:29 ` no-reply
  2018-06-04  7:30   ` Juan Quintela
  2018-06-04 13:24 ` Peter Maydell
  1 sibling, 1 reply; 20+ messages in thread
From: no-reply @ 2018-06-04  4:29 UTC (permalink / raw)
  To: quintela; +Cc: famz, qemu-devel, lvivier, dgilbert, peterx

Hi,

This series seems to have some coding style problems. See output below for
more information:

Type: series
Message-id: 20180604042156.13812-1-quintela@redhat.com
Subject: [Qemu-devel] [PULL 0/5] Migration pull request

=== TEST SCRIPT BEGIN ===
#!/bin/bash

BASE=base
n=1
total=$(git log --oneline $BASE.. | wc -l)
failed=0

git config --local diff.renamelimit 0
git config --local diff.renames True
git config --local diff.algorithm histogram

commits="$(git log --format=%H --reverse $BASE..)"
for c in $commits; do
    echo "Checking PATCH $n/$total: $(git log -n 1 --format=%s $c)..."
    if ! git show $c --format=email | ./scripts/checkpatch.pl --mailback -; then
        failed=1
        echo
    fi
    n=$((n+1))
done

exit $failed
=== TEST SCRIPT END ===

Updating 3c8cf5a9c21ff8782164d1def7f44bd888713384
From https://github.com/patchew-project/qemu
 t [tag update]            patchew/20180514065700.22202-1-clg@kaod.org -> patchew/20180514065700.22202-1-clg@kaod.org
 * [new tag]               patchew/20180604042156.13812-1-quintela@redhat.com -> patchew/20180604042156.13812-1-quintela@redhat.com
Switched to a new branch 'test'
99ac0fb20d migration: not wait RDMA_CM_EVENT_DISCONNECTED event after rdma_disconnect
7c902253bb migration: remove unnecessary variables len in QIOChannelRDMA
3c1203cb38 migration: Don't activate block devices if using -S
2ecc458546 migration: discard non-migratable RAMBlocks
718b388d4e migration: introduce decompress-error-check

=== OUTPUT BEGIN ===
Checking PATCH 1/5: migration: introduce decompress-error-check...
Checking PATCH 2/5: migration: discard non-migratable RAMBlocks...
ERROR: Macros with multiple statements should be enclosed in a do - while loop
#191: FILE: migration/ram.c:161:
+#define RAMBLOCK_FOREACH_MIGRATABLE(block)             \
+    RAMBLOCK_FOREACH(block)                            \
+        if (!qemu_ram_is_migratable(block)) {} else

ERROR: trailing statements should be on next line
#193: FILE: migration/ram.c:163:
+        if (!qemu_ram_is_migratable(block)) {} else

total: 2 errors, 0 warnings, 273 lines checked

Your patch has style problems, please review.  If any of these errors
are false positives report them to the maintainer, see
CHECKPATCH in MAINTAINERS.

Checking PATCH 3/5: migration: Don't activate block devices if using -S...
Checking PATCH 4/5: migration: remove unnecessary variables len in QIOChannelRDMA...
Checking PATCH 5/5: migration: not wait RDMA_CM_EVENT_DISCONNECTED event after rdma_disconnect...
=== OUTPUT END ===

Test command exited with code: 1


---
Email generated automatically by Patchew [http://patchew.org/].
Please send your feedback to patchew-devel@redhat.com

^ permalink raw reply	[flat|nested] 20+ messages in thread

* Re: [Qemu-devel] [PULL 0/5] Migration pull request
  2018-06-04  4:29 ` no-reply
@ 2018-06-04  7:30   ` Juan Quintela
  0 siblings, 0 replies; 20+ messages in thread
From: Juan Quintela @ 2018-06-04  7:30 UTC (permalink / raw)
  To: no-reply; +Cc: qemu-devel, famz, lvivier, dgilbert, peterx

no-reply@patchew.org wrote:
> Hi,
>
> This series seems to have some coding style problems. See output below for
> more information:
>
> Type: series
> Message-id: 20180604042156.13812-1-quintela@redhat.com
> Subject: [Qemu-devel] [PULL 0/5] Migration pull request

> Updating 3c8cf5a9c21ff8782164d1def7f44bd888713384
> From https://github.com/patchew-project/qemu
>  t [tag update]            patchew/20180514065700.22202-1-clg@kaod.org -> patchew/20180514065700.22202-1-clg@kaod.org
>  * [new tag]               patchew/20180604042156.13812-1-quintela@redhat.com -> patchew/20180604042156.13812-1-quintela@redhat.com
> Switched to a new branch 'test'
> 99ac0fb20d migration: not wait RDMA_CM_EVENT_DISCONNECTED event after rdma_disconnect
> 7c902253bb migration: remove unnecessary variables len in QIOChannelRDMA
> 3c1203cb38 migration: Don't activate block devices if using -S
> 2ecc458546 migration: discard non-migratable RAMBlocks
> 718b388d4e migration: introduce decompress-error-check
>
> === OUTPUT BEGIN ===
> Checking PATCH 1/5: migration: introduce decompress-error-check...
> Checking PATCH 2/5: migration: discard non-migratable RAMBlocks...
> ERROR: Macros with multiple statements should be enclosed in a do - while loop
> #191: FILE: migration/ram.c:161:
> +#define RAMBLOCK_FOREACH_MIGRATABLE(block)             \
> +    RAMBLOCK_FOREACH(block)                            \
> +        if (!qemu_ram_is_migratable(block)) {} else
>
> ERROR: trailing statements should be on next line
> #193: FILE: migration/ram.c:163:
> +        if (!qemu_ram_is_migratable(block)) {} else

We know. it is on purpose.  There is no good solution.  Changing
checkpatch don't make sense either, it is an one-off case.

Later, Juan.

^ permalink raw reply	[flat|nested] 20+ messages in thread

* Re: [Qemu-devel] [PULL 0/5] Migration pull request
  2018-06-04  4:21 Juan Quintela
  2018-06-04  4:29 ` no-reply
@ 2018-06-04 13:24 ` Peter Maydell
  1 sibling, 0 replies; 20+ messages in thread
From: Peter Maydell @ 2018-06-04 13:24 UTC (permalink / raw)
  To: Juan Quintela
  Cc: QEMU Developers, Laurent Vivier, Dr. David Alan Gilbert, Peter Xu

On 4 June 2018 at 05:21, Juan Quintela <quintela@redhat.com> wrote:
> The following changes since commit 392fba9f583223786f844dce9b2e7f9a0ce0147a:
>
>   Merge remote-tracking branch 'remotes/stsquad/tags/pull-travis-updates-010618-1' into staging (2018-06-01 17:32:30 +0100)
>
> are available in the Git repository at:
>
>   git://github.com/juanquintela/qemu.git tags/migration/20180604
>
> for you to fetch changes up to c5e76115ccb4979cec795a8ae38becd07c2fde9f:
>
>   migration: not wait RDMA_CM_EVENT_DISCONNECTED event after rdma_disconnect (2018-06-04 05:46:15 +0200)
>
> ----------------------------------------------------------------
> migration/next for 20180604
>
> - RDMA fixes from (lidong)
> - Fix docempress-error-check (Xiao)
> - make -S and block work better (dave)
> - don't migrate "bad" ramblocks (Cédric)
>
> Please apply, Juan.
>
> ----------------------------------------------------------------

Applied, thanks.

-- PMM

^ permalink raw reply	[flat|nested] 20+ messages in thread

end of thread, other threads:[~2018-06-04 13:24 UTC | newest]

Thread overview: 20+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2017-05-31  9:15 [Qemu-devel] [PULL 0/5] Migration pull request Juan Quintela
2017-05-31  9:15 ` [Qemu-devel] [PULL 1/5] migration: Create savevm.h for functions exported from savevm.c Juan Quintela
2017-05-31  9:15 ` [Qemu-devel] [PULL 2/5] migration: keep bytes_xfer_prev init'd to zero Juan Quintela
2017-05-31  9:15 ` [Qemu-devel] [PULL 3/5] migration: set dirty_pages_rate before autoconverge logic Juan Quintela
2017-05-31  9:15 ` [Qemu-devel] [PULL 4/5] migration: set bytes_xfer_* outside of " Juan Quintela
2017-05-31  9:15 ` [Qemu-devel] [PULL 5/5] migration: use dirty_rate_high_cnt more aggressively Juan Quintela
2017-06-01 14:50 ` [Qemu-devel] [PULL 0/5] Migration pull request Peter Maydell
  -- strict thread matches above, loose matches on Subject: below --
2018-06-04  4:21 Juan Quintela
2018-06-04  4:29 ` no-reply
2018-06-04  7:30   ` Juan Quintela
2018-06-04 13:24 ` Peter Maydell
2017-06-14 11:51 [Qemu-devel] [PULL 0/5] Migration PULL request Juan Quintela
2017-06-15 11:56 ` Peter Maydell
2017-05-12 15:52 [Qemu-devel] [PULL 0/5] Migration pull request Juan Quintela
2017-05-15 13:58 ` Stefan Hajnoczi
2017-05-15 14:52   ` Eric Blake
2017-05-15 17:17   ` Juan Quintela
2017-05-16 14:35 ` Stefan Hajnoczi
2015-11-04 12:48 Juan Quintela
2015-11-05 10:48 ` Peter Maydell

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).