* [Qemu-devel] [PULL 0/2] Migration pull
@ 2018-05-25 13:32 Juan Quintela
2018-05-25 13:32 ` [Qemu-devel] [PULL 1/2] migration: fix exec/fd migrations Juan Quintela
` (2 more replies)
0 siblings, 3 replies; 4+ messages in thread
From: Juan Quintela @ 2018-05-25 13:32 UTC (permalink / raw)
To: qemu-devel; +Cc: dgilbert, lvivier, peterx
Hi
this pull:
- fix iotests problems
- add a fix for coverity.
Apply, please.
The following changes since commit 5a5c383b1373aeb6c87a0d6060f6c3dc7c53082b:
Merge remote-tracking branch 'remotes/vivier2/tags/linux-user-for-2.13-pull-request' into staging (2018-05-25 10:04:36 +0100)
are available in the Git repository at:
git://github.com/juanquintela/qemu.git tags/migration/20180525
for you to fetch changes up to bf269906f5b225a04825b2bce4364bfe1d509999:
migration: use g_free for ram load bitmap (2018-05-25 15:29:48 +0200)
----------------------------------------------------------------
migration/next for 20180525
----------------------------------------------------------------
Juan Quintela (1):
migration: fix exec/fd migrations
Peter Xu (1):
migration: use g_free for ram load bitmap
migration/exec.c | 4 ++++
migration/fd.c | 4 ++++
migration/ram.c | 4 ++--
3 files changed, 10 insertions(+), 2 deletions(-)
^ permalink raw reply [flat|nested] 4+ messages in thread
* [Qemu-devel] [PULL 1/2] migration: fix exec/fd migrations
2018-05-25 13:32 [Qemu-devel] [PULL 0/2] Migration pull Juan Quintela
@ 2018-05-25 13:32 ` Juan Quintela
2018-05-25 13:32 ` [Qemu-devel] [PULL 2/2] migration: use g_free for ram load bitmap Juan Quintela
2018-05-29 8:56 ` [Qemu-devel] [PULL 0/2] Migration pull Peter Maydell
2 siblings, 0 replies; 4+ messages in thread
From: Juan Quintela @ 2018-05-25 13:32 UTC (permalink / raw)
To: qemu-devel; +Cc: dgilbert, lvivier, peterx
Commit:
commit 36c2f8be2c4eb0003ac77a14910842b7ddd7337e
Author: Juan Quintela <quintela@redhat.com>
Date: Wed Mar 7 08:40:52 2018 +0100
migration: Delay start of migration main routines
Missed tcp and fd transports. This fix its.
Reported-by: Kevin Wolf <kwolf@redhat.com>
Signed-off-by: Juan Quintela <quintela@redhat.com>
Tested-by: Kevin Wolf <kwolf@redhat.com>
Message-Id: <20180523091411.1073-1-quintela@redhat.com>
Signed-off-by: Juan Quintela <quintela@redhat.com>
---
migration/exec.c | 4 ++++
migration/fd.c | 4 ++++
2 files changed, 8 insertions(+)
diff --git a/migration/exec.c b/migration/exec.c
index 9d0f82f1f0..0bbeb63c97 100644
--- a/migration/exec.c
+++ b/migration/exec.c
@@ -20,6 +20,7 @@
#include "qemu/osdep.h"
#include "channel.h"
#include "exec.h"
+#include "migration.h"
#include "io/channel-command.h"
#include "trace.h"
@@ -48,6 +49,9 @@ static gboolean exec_accept_incoming_migration(QIOChannel *ioc,
{
migration_channel_process_incoming(ioc);
object_unref(OBJECT(ioc));
+ if (!migrate_use_multifd()) {
+ migration_incoming_process();
+ }
return G_SOURCE_REMOVE;
}
diff --git a/migration/fd.c b/migration/fd.c
index 9a380bbbc4..fee34ffdc0 100644
--- a/migration/fd.c
+++ b/migration/fd.c
@@ -17,6 +17,7 @@
#include "qemu/osdep.h"
#include "channel.h"
#include "fd.h"
+#include "migration.h"
#include "monitor/monitor.h"
#include "io/channel-util.h"
#include "trace.h"
@@ -48,6 +49,9 @@ static gboolean fd_accept_incoming_migration(QIOChannel *ioc,
{
migration_channel_process_incoming(ioc);
object_unref(OBJECT(ioc));
+ if (!migrate_use_multifd()) {
+ migration_incoming_process();
+ }
return G_SOURCE_REMOVE;
}
--
2.17.0
^ permalink raw reply related [flat|nested] 4+ messages in thread
* [Qemu-devel] [PULL 2/2] migration: use g_free for ram load bitmap
2018-05-25 13:32 [Qemu-devel] [PULL 0/2] Migration pull Juan Quintela
2018-05-25 13:32 ` [Qemu-devel] [PULL 1/2] migration: fix exec/fd migrations Juan Quintela
@ 2018-05-25 13:32 ` Juan Quintela
2018-05-29 8:56 ` [Qemu-devel] [PULL 0/2] Migration pull Peter Maydell
2 siblings, 0 replies; 4+ messages in thread
From: Juan Quintela @ 2018-05-25 13:32 UTC (permalink / raw)
To: qemu-devel; +Cc: dgilbert, lvivier, peterx
From: Peter Xu <peterx@redhat.com>
Buffers allocated with bitmap_new() should be freed with g_free().
Both reported by Coverity:
*** CID 1391300: API usage errors (ALLOC_FREE_MISMATCH)
/migration/ram.c: 3517 in ram_dirty_bitmap_reload()
3511 * the last one to sync, we need to notify the main send thread.
3512 */
3513 ram_dirty_bitmap_reload_notify(s);
3514
3515 ret = 0;
3516 out:
>>> CID 1391300: API usage errors (ALLOC_FREE_MISMATCH)
>>> Calling "free" frees "le_bitmap" using "free" but it should have been freed using "g_free".
3517 free(le_bitmap);
3518 return ret;
3519 }
3520
3521 static int ram_resume_prepare(MigrationState *s, void *opaque)
3522 {
*** CID 1391292: API usage errors (ALLOC_FREE_MISMATCH)
/migration/ram.c: 249 in ramblock_recv_bitmap_send()
243 * Mark as an end, in case the middle part is screwed up due to
244 * some "misterious" reason.
245 */
246 qemu_put_be64(file, RAMBLOCK_RECV_BITMAP_ENDING);
247 qemu_fflush(file);
248
>>> CID 1391292: API usage errors (ALLOC_FREE_MISMATCH)
>>> Calling "free" frees "le_bitmap" using "free" but it should have been freed using "g_free".
249 free(le_bitmap);
250
251 if (qemu_file_get_error(file)) {
252 return qemu_file_get_error(file);
253 }
254
Signed-off-by: Peter Xu <peterx@redhat.com>
Reviewed-by: Juan Quintela <quintela@redhat.com>
Message-Id: <20180525015042.31778-1-peterx@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 5bcbf7a9f9..c53e8369a3 100644
--- a/migration/ram.c
+++ b/migration/ram.c
@@ -246,7 +246,7 @@ int64_t ramblock_recv_bitmap_send(QEMUFile *file,
qemu_put_be64(file, RAMBLOCK_RECV_BITMAP_ENDING);
qemu_fflush(file);
- free(le_bitmap);
+ g_free(le_bitmap);
if (qemu_file_get_error(file)) {
return qemu_file_get_error(file);
@@ -3514,7 +3514,7 @@ int ram_dirty_bitmap_reload(MigrationState *s, RAMBlock *block)
ret = 0;
out:
- free(le_bitmap);
+ g_free(le_bitmap);
return ret;
}
--
2.17.0
^ permalink raw reply related [flat|nested] 4+ messages in thread
* Re: [Qemu-devel] [PULL 0/2] Migration pull
2018-05-25 13:32 [Qemu-devel] [PULL 0/2] Migration pull Juan Quintela
2018-05-25 13:32 ` [Qemu-devel] [PULL 1/2] migration: fix exec/fd migrations Juan Quintela
2018-05-25 13:32 ` [Qemu-devel] [PULL 2/2] migration: use g_free for ram load bitmap Juan Quintela
@ 2018-05-29 8:56 ` Peter Maydell
2 siblings, 0 replies; 4+ messages in thread
From: Peter Maydell @ 2018-05-29 8:56 UTC (permalink / raw)
To: Juan Quintela
Cc: QEMU Developers, Laurent Vivier, Dr. David Alan Gilbert, Peter Xu
On 25 May 2018 at 14:32, Juan Quintela <quintela@redhat.com> wrote:
> Hi
>
> this pull:
> - fix iotests problems
> - add a fix for coverity.
>
> Apply, please.
>
> The following changes since commit 5a5c383b1373aeb6c87a0d6060f6c3dc7c53082b:
>
> Merge remote-tracking branch 'remotes/vivier2/tags/linux-user-for-2.13-pull-request' into staging (2018-05-25 10:04:36 +0100)
>
> are available in the Git repository at:
>
> git://github.com/juanquintela/qemu.git tags/migration/20180525
>
> for you to fetch changes up to bf269906f5b225a04825b2bce4364bfe1d509999:
>
> migration: use g_free for ram load bitmap (2018-05-25 15:29:48 +0200)
>
> ----------------------------------------------------------------
> migration/next for 20180525
>
> ----------------------------------------------------------------
> Juan Quintela (1):
> migration: fix exec/fd migrations
>
> Peter Xu (1):
> migration: use g_free for ram load bitmap
>
> migration/exec.c | 4 ++++
> migration/fd.c | 4 ++++
> migration/ram.c | 4 ++--
> 3 files changed, 10 insertions(+), 2 deletions(-)
Applied, thanks.
-- PMM
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2018-05-29 8:57 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2018-05-25 13:32 [Qemu-devel] [PULL 0/2] Migration pull Juan Quintela
2018-05-25 13:32 ` [Qemu-devel] [PULL 1/2] migration: fix exec/fd migrations Juan Quintela
2018-05-25 13:32 ` [Qemu-devel] [PULL 2/2] migration: use g_free for ram load bitmap Juan Quintela
2018-05-29 8:56 ` [Qemu-devel] [PULL 0/2] Migration pull 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).