xen-devel.lists.xenproject.org archive mirror
 help / color / mirror / Atom feed
From: Andrew Cooper <andrew.cooper3@citrix.com>
To: Yang Hongyang <yanghy@cn.fujitsu.com>, xen-devel@lists.xen.org
Cc: wei.liu2@citrix.com, ian.campbell@citrix.com,
	wency@cn.fujitsu.com, ian.jackson@eu.citrix.com,
	yunhong.jiang@intel.com, eddie.dong@intel.com,
	guijianfeng@cn.fujitsu.com, rshriram@cs.ubc.ca
Subject: Re: [PATCH Remus v6 1/3] libxc/save: refactor of send_domain_memory_live()
Date: Fri, 15 May 2015 13:56:17 +0100	[thread overview]
Message-ID: <5555ECF1.1030001@citrix.com> (raw)
In-Reply-To: <1431685025-16809-2-git-send-email-yanghy@cn.fujitsu.com>

On 15/05/15 11:17, Yang Hongyang wrote:
> @@ -519,9 +533,15 @@ static int send_domain_memory_live(struct xc_sr_context *ctx)
>          goto out;
>      }
>  
> -    rc = update_progress_string(ctx, &progress_str, ctx->save.max_iterations);
> -    if ( rc )
> -        goto out;
> +    if ( ctx->save.live )
> +    {
> +        rc = update_progress_string(ctx, &progress_str,
> +                                    ctx->save.max_iterations);
> +        if ( rc )
> +            goto out;
> +    }
> +    else
> +        xc_set_progress_prefix(xch, "Checkpointed save");
>  
>      bitmap_or(dirty_bitmap, ctx->save.deferred_pages, ctx->save.p2m_size);

Sorry not to notice this before, but you want to clear the
deferred_pages map (and count) after the subsequent call to
send_dirty_pages().

deferred_pages accumulates during the live phase (for grant mapped
pages, pagetables in flux, etc), but should be empty an unused during
checkpoints.  At the moment, this is causing each checkpoint to send
more data than they need to.

For the rest of the refactoring, Reviewed-by: Andrew Cooper
<andrew.cooper3@citrix.com>

  reply	other threads:[~2015-05-15 12:56 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-05-15 10:17 [PATCH Remus v6 0/3] Remus support for Migration-v2 Yang Hongyang
2015-05-15 10:17 ` [PATCH Remus v6 1/3] libxc/save: refactor of send_domain_memory_live() Yang Hongyang
2015-05-15 12:56   ` Andrew Cooper [this message]
2015-05-18  0:53     ` Yang Hongyang
2015-05-15 10:17 ` [PATCH Remus v6 2/3] libxc/save: implement Remus checkpointed save Yang Hongyang
2015-05-15 12:59   ` Andrew Cooper
2015-05-15 10:17 ` [PATCH Remus v6 3/3] libxc/restore: implement Remus checkpointed restore Yang Hongyang
2015-05-15 13:13   ` Andrew Cooper

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=5555ECF1.1030001@citrix.com \
    --to=andrew.cooper3@citrix.com \
    --cc=eddie.dong@intel.com \
    --cc=guijianfeng@cn.fujitsu.com \
    --cc=ian.campbell@citrix.com \
    --cc=ian.jackson@eu.citrix.com \
    --cc=rshriram@cs.ubc.ca \
    --cc=wei.liu2@citrix.com \
    --cc=wency@cn.fujitsu.com \
    --cc=xen-devel@lists.xen.org \
    --cc=yanghy@cn.fujitsu.com \
    --cc=yunhong.jiang@intel.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).