All of lore.kernel.org
 help / color / mirror / Atom feed
* [Qemu-devel] [PULL 2.7 0/4] migration: fixes
@ 2016-08-11 11:39 Amit Shah
  2016-08-11 11:39 ` [Qemu-devel] [PULL 2.7 1/4] migration/ram: fix typo Amit Shah
                   ` (4 more replies)
  0 siblings, 5 replies; 6+ messages in thread
From: Amit Shah @ 2016-08-11 11:39 UTC (permalink / raw)
  To: Peter Maydell
  Cc: qemu list, caoj.fnst, eyakovlev, den, liang.z.li,
	Dr. David Alan Gilbert, Juan Quintela, Amit Shah

The following changes since commit d08306dc42ea599ffcf8aad056fa9c23acfbe230:

  Merge remote-tracking branch 'remotes/mst/tags/for_upstream' into staging (2016-08-10 17:14:35 +0100)

are available in the git repository at:

  http://git.kernel.org/pub/scm/virt/qemu/amit/migration.git tags/migration-for-2.7-7

for you to fetch changes up to 474c624ddf0d390b850526a01026ef8737e67ca7:

  migration/socket: fix typo in file header (2016-08-11 17:03:51 +0530)

----------------------------------------------------------------
Migration:
 - couple of bug fixes
 - couple of typo fixes

----------------------------------------------------------------

Cao jin (2):
  migration/ram: fix typo
  migration/socket: fix typo in file header

Evgeny Yakovlev (1):
  migration: mmap error check fix

Liang Li (1):
  migration: fix live migration failure with compression

 migration/postcopy-ram.c | 3 ++-
 migration/qemu-file.c    | 1 +
 migration/ram.c          | 4 ++--
 migration/socket.c       | 4 +++-
 4 files changed, 8 insertions(+), 4 deletions(-)

-- 
2.7.4

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

* [Qemu-devel] [PULL 2.7 1/4] migration/ram: fix typo
  2016-08-11 11:39 [Qemu-devel] [PULL 2.7 0/4] migration: fixes Amit Shah
@ 2016-08-11 11:39 ` Amit Shah
  2016-08-11 11:39 ` [Qemu-devel] [PULL 2.7 2/4] migration: mmap error check fix Amit Shah
                   ` (3 subsequent siblings)
  4 siblings, 0 replies; 6+ messages in thread
From: Amit Shah @ 2016-08-11 11:39 UTC (permalink / raw)
  To: Peter Maydell
  Cc: qemu list, caoj.fnst, eyakovlev, den, liang.z.li,
	Dr. David Alan Gilbert, Juan Quintela, Amit Shah

From: Cao jin <caoj.fnst@cn.fujitsu.com>

Signed-off-by: Cao jin <caoj.fnst@cn.fujitsu.com>
Message-Id: <1469776231-23820-1-git-send-email-caoj.fnst@cn.fujitsu.com>
Signed-off-by: Amit Shah <amit.shah@redhat.com>
---
 migration/ram.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/migration/ram.c b/migration/ram.c
index 815bc0e..a3d70c4 100644
--- a/migration/ram.c
+++ b/migration/ram.c
@@ -375,8 +375,8 @@ void migrate_compress_threads_create(void)
     qemu_cond_init(&comp_done_cond);
     qemu_mutex_init(&comp_done_lock);
     for (i = 0; i < thread_count; i++) {
-        /* com_param[i].file is just used as a dummy buffer to save data, set
-         * it's ops to empty.
+        /* comp_param[i].file is just used as a dummy buffer to save data,
+         * set its ops to empty.
          */
         comp_param[i].file = qemu_fopen_ops(NULL, &empty_ops);
         comp_param[i].done = true;
-- 
2.7.4

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

* [Qemu-devel] [PULL 2.7 2/4] migration: mmap error check fix
  2016-08-11 11:39 [Qemu-devel] [PULL 2.7 0/4] migration: fixes Amit Shah
  2016-08-11 11:39 ` [Qemu-devel] [PULL 2.7 1/4] migration/ram: fix typo Amit Shah
@ 2016-08-11 11:39 ` Amit Shah
  2016-08-11 11:39 ` [Qemu-devel] [PULL 2.7 3/4] migration: fix live migration failure with compression Amit Shah
                   ` (2 subsequent siblings)
  4 siblings, 0 replies; 6+ messages in thread
From: Amit Shah @ 2016-08-11 11:39 UTC (permalink / raw)
  To: Peter Maydell
  Cc: qemu list, caoj.fnst, eyakovlev, den, liang.z.li,
	Dr. David Alan Gilbert, Juan Quintela, Amit Shah

From: Evgeny Yakovlev <eyakovlev@virtuozzo.com>

mmap man page:
"On success, mmap() returns a pointer to the mapped area. On error, the
value MAP_FAILED (that is, (void *) -1) is returned, and errno  is  set
to indicate the cause of the error."

The check in postcopy_get_tmp_page is definitely wrong and should be
fixed.

Signed-off-by: Evgeny Yakovlev <eyakovlev@virtuozzo.com>
Signed-off-by: Denis V. Lunev <den@openvz.org>
Reviewed-by: Amit Shah <amit.shah@redhat.com>
Reviewed-by: Dr. David Alan Gilbert <dgilbert@redhat.com>
CC: Juan Quintela <quintela@redhat.com>
CC: Amit Shah <amit.shah@redhat.com>
Message-Id: <1469785705-16670-1-git-send-email-den@openvz.org>
Signed-off-by: Amit Shah <amit.shah@redhat.com>
---
 migration/postcopy-ram.c | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/migration/postcopy-ram.c b/migration/postcopy-ram.c
index abe8c60..9b04778 100644
--- a/migration/postcopy-ram.c
+++ b/migration/postcopy-ram.c
@@ -604,7 +604,8 @@ void *postcopy_get_tmp_page(MigrationIncomingState *mis)
         mis->postcopy_tmp_page = mmap(NULL, getpagesize(),
                              PROT_READ | PROT_WRITE, MAP_PRIVATE |
                              MAP_ANONYMOUS, -1, 0);
-        if (!mis->postcopy_tmp_page) {
+        if (mis->postcopy_tmp_page == MAP_FAILED) {
+            mis->postcopy_tmp_page = NULL;
             error_report("%s: %s", __func__, strerror(errno));
             return NULL;
         }
-- 
2.7.4

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

* [Qemu-devel] [PULL 2.7 3/4] migration: fix live migration failure with compression
  2016-08-11 11:39 [Qemu-devel] [PULL 2.7 0/4] migration: fixes Amit Shah
  2016-08-11 11:39 ` [Qemu-devel] [PULL 2.7 1/4] migration/ram: fix typo Amit Shah
  2016-08-11 11:39 ` [Qemu-devel] [PULL 2.7 2/4] migration: mmap error check fix Amit Shah
@ 2016-08-11 11:39 ` Amit Shah
  2016-08-11 11:39 ` [Qemu-devel] [PULL 2.7 4/4] migration/socket: fix typo in file header Amit Shah
  2016-08-11 17:54 ` [Qemu-devel] [PULL 2.7 0/4] migration: fixes Peter Maydell
  4 siblings, 0 replies; 6+ messages in thread
From: Amit Shah @ 2016-08-11 11:39 UTC (permalink / raw)
  To: Peter Maydell
  Cc: qemu list, caoj.fnst, eyakovlev, den, liang.z.li,
	Dr. David Alan Gilbert, Juan Quintela, Amit Shah

From: Liang Li <liang.z.li@intel.com>

Because of commit 11808bb0c422, which remove some condition checks
of 'f->ops->writev_buffer', 'qemu_put_qemu_file' should be enhanced
to clear the 'f_src->iovcnt', or 'f_src->iovcnt' may exceed the
MAX_IOV_SIZE which will break live migration. This should be fixed.

Signed-off-by: Liang Li <liang.z.li@intel.com>
Reported-by: Jinshi Zhang <jinshi.c.zhang@intel.com>
Reviewed-by: Dr. David Alan Gilbert <dgilbert@redhat.com>
Message-Id: <1470702146-24399-1-git-send-email-liang.z.li@intel.com>
Signed-off-by: Amit Shah <amit.shah@redhat.com>
---
 migration/qemu-file.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/migration/qemu-file.c b/migration/qemu-file.c
index bbc565e..e9fae31 100644
--- a/migration/qemu-file.c
+++ b/migration/qemu-file.c
@@ -668,6 +668,7 @@ int qemu_put_qemu_file(QEMUFile *f_des, QEMUFile *f_src)
         len = f_src->buf_index;
         qemu_put_buffer(f_des, f_src->buf, f_src->buf_index);
         f_src->buf_index = 0;
+        f_src->iovcnt = 0;
     }
     return len;
 }
-- 
2.7.4

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

* [Qemu-devel] [PULL 2.7 4/4] migration/socket: fix typo in file header
  2016-08-11 11:39 [Qemu-devel] [PULL 2.7 0/4] migration: fixes Amit Shah
                   ` (2 preceding siblings ...)
  2016-08-11 11:39 ` [Qemu-devel] [PULL 2.7 3/4] migration: fix live migration failure with compression Amit Shah
@ 2016-08-11 11:39 ` Amit Shah
  2016-08-11 17:54 ` [Qemu-devel] [PULL 2.7 0/4] migration: fixes Peter Maydell
  4 siblings, 0 replies; 6+ messages in thread
From: Amit Shah @ 2016-08-11 11:39 UTC (permalink / raw)
  To: Peter Maydell
  Cc: qemu list, caoj.fnst, eyakovlev, den, liang.z.li,
	Dr. David Alan Gilbert, Juan Quintela, Daniel P . Berrange,
	Amit Shah

From: Cao jin <caoj.fnst@cn.fujitsu.com>

Code of inet socket & unix socket is merged together.
Also add some newlines, make code block well separated.

Cc: Daniel P. Berrange <berrange@redhat.com>
Cc: Juan Quintela <quintela@redhat.com>
Cc: Amit Shah <amit.shah@redhat.com>

Reviewed-by: Daniel P. Berrange <berrange@redhat.com>
Signed-off-by: Cao jin <caoj.fnst@cn.fujitsu.com>
Message-Id: <1469696074-12744-4-git-send-email-caoj.fnst@cn.fujitsu.com>
Signed-off-by: Amit Shah <amit.shah@redhat.com>
---
 migration/socket.c | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

diff --git a/migration/socket.c b/migration/socket.c
index 5c0a38f..00de1fe 100644
--- a/migration/socket.c
+++ b/migration/socket.c
@@ -1,5 +1,5 @@
 /*
- * QEMU live migration via Unix Domain Sockets
+ * QEMU live migration via socket
  *
  * Copyright Red Hat, Inc. 2009-2016
  *
@@ -94,10 +94,12 @@ static void socket_start_outgoing_migration(MigrationState *s,
 {
     QIOChannelSocket *sioc = qio_channel_socket_new();
     struct SocketConnectData *data = g_new0(struct SocketConnectData, 1);
+
     data->s = s;
     if (saddr->type == SOCKET_ADDRESS_KIND_INET) {
         data->hostname = g_strdup(saddr->u.inet.data->host);
     }
+
     qio_channel_socket_connect_async(sioc,
                                      saddr,
                                      socket_outgoing_migration,
-- 
2.7.4

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

* Re: [Qemu-devel] [PULL 2.7 0/4] migration: fixes
  2016-08-11 11:39 [Qemu-devel] [PULL 2.7 0/4] migration: fixes Amit Shah
                   ` (3 preceding siblings ...)
  2016-08-11 11:39 ` [Qemu-devel] [PULL 2.7 4/4] migration/socket: fix typo in file header Amit Shah
@ 2016-08-11 17:54 ` Peter Maydell
  4 siblings, 0 replies; 6+ messages in thread
From: Peter Maydell @ 2016-08-11 17:54 UTC (permalink / raw)
  To: Amit Shah
  Cc: qemu list, Cao jin, eyakovlev, Denis V. Lunev, Liang Li,
	Dr. David Alan Gilbert, Juan Quintela

On 11 August 2016 at 12:39, Amit Shah <amit.shah@redhat.com> wrote:
> The following changes since commit d08306dc42ea599ffcf8aad056fa9c23acfbe230:
>
>   Merge remote-tracking branch 'remotes/mst/tags/for_upstream' into staging (2016-08-10 17:14:35 +0100)
>
> are available in the git repository at:
>
>   http://git.kernel.org/pub/scm/virt/qemu/amit/migration.git tags/migration-for-2.7-7
>
> for you to fetch changes up to 474c624ddf0d390b850526a01026ef8737e67ca7:
>
>   migration/socket: fix typo in file header (2016-08-11 17:03:51 +0530)
>
> ----------------------------------------------------------------
> Migration:
>  - couple of bug fixes
>  - couple of typo fixes
>
> ----------------------------------------------------------------

Applied, thanks.

-- PMM

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

end of thread, other threads:[~2016-08-11 17:54 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2016-08-11 11:39 [Qemu-devel] [PULL 2.7 0/4] migration: fixes Amit Shah
2016-08-11 11:39 ` [Qemu-devel] [PULL 2.7 1/4] migration/ram: fix typo Amit Shah
2016-08-11 11:39 ` [Qemu-devel] [PULL 2.7 2/4] migration: mmap error check fix Amit Shah
2016-08-11 11:39 ` [Qemu-devel] [PULL 2.7 3/4] migration: fix live migration failure with compression Amit Shah
2016-08-11 11:39 ` [Qemu-devel] [PULL 2.7 4/4] migration/socket: fix typo in file header Amit Shah
2016-08-11 17:54 ` [Qemu-devel] [PULL 2.7 0/4] migration: fixes Peter Maydell

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.