qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: Peter Xu <zhexu@redhat.com>
To: Ivan Ren <renyime@gmail.com>
Cc: qemu-devel@nongnu.org, dgilbert@redhat.com, quintela@redhat.com
Subject: Re: [Qemu-devel] [PATCH] migration: always initial RAMBlock.bmap to 1 for new migration
Date: Mon, 15 Jul 2019 09:47:29 +0800	[thread overview]
Message-ID: <20190715014729.GA9050@xz-x1> (raw)
In-Reply-To: <1563115879-2715-1-git-send-email-ivanren@tencent.com>

On Sun, Jul 14, 2019 at 10:51:19PM +0800, Ivan Ren wrote:
> Reproduce the problem:
> migrate
> migrate_cancel
> migrate
> 
> Error happen for memory migration

Can mention "this mostly revert 0315851938 but with comments kept"
when merge...

> 
> The reason as follows:
> 1. qemu start, ram_list.dirty_memory[DIRTY_MEMORY_MIGRATION] all set to
>    1 by a series of cpu_physical_memory_set_dirty_range
> 2. migration start:ram_init_bitmaps
>    - memory_global_dirty_log_start: begin log diry
>    - memory_global_dirty_log_sync: sync dirty bitmap to
>      ram_list.dirty_memory[DIRTY_MEMORY_MIGRATION]
>    - migration_bitmap_sync_range: sync ram_list.
>      dirty_memory[DIRTY_MEMORY_MIGRATION] to RAMBlock.bmap
>      and ram_list.dirty_memory[DIRTY_MEMORY_MIGRATION] is set to zero
> 3. migration data...
> 4. migrate_cancel, will stop log dirty
> 5. migration start:ram_init_bitmaps
>    - memory_global_dirty_log_start: begin log diry
>    - memory_global_dirty_log_sync: sync dirty bitmap to
>      ram_list.dirty_memory[DIRTY_MEMORY_MIGRATION]
>    - migration_bitmap_sync_range: sync ram_list.
>      dirty_memory[DIRTY_MEMORY_MIGRATION] to RAMBlock.bmap
>      and ram_list.dirty_memory[DIRTY_MEMORY_MIGRATION] is set to zero
> 
>    Here RAMBlock.bmap only have new logged dirty pages, don't contain
>    the whole guest pages.

Fixes: 03158519384f158

> 
> Signed-off-by: Ivan Ren <ivanren@tencent.com>

Reviewed-by: Peter Xu <peterx@redhat.com>

I think this is a bit severe and should be rc2 material.  Dave/Juan?

Thanks,

-- 
Peter Xu


  reply	other threads:[~2019-07-15  1:47 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-07-14 14:51 [Qemu-devel] [PATCH] migration: always initial RAMBlock.bmap to 1 for new migration Ivan Ren
2019-07-15  1:47 ` Peter Xu [this message]
2019-07-15  9:50   ` Dr. David Alan Gilbert
2019-07-15  9:40 ` Dr. David Alan Gilbert
2019-08-01  2:55 ` Wei Yang
2019-08-01  7:58   ` Ivan Ren
2019-08-02  0:50     ` Wei Yang

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20190715014729.GA9050@xz-x1 \
    --to=zhexu@redhat.com \
    --cc=dgilbert@redhat.com \
    --cc=qemu-devel@nongnu.org \
    --cc=quintela@redhat.com \
    --cc=renyime@gmail.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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).