All of lore.kernel.org
 help / color / mirror / Atom feed
From: Orit Wasserman <owasserm@redhat.com>
To: Juan Quintela <quintela@redhat.com>
Cc: qemu-devel@nongnu.org
Subject: Re: [Qemu-devel] [PATCH 6/8] migration: rename expected_time to expected_downtime
Date: Tue, 21 Aug 2012 13:57:59 +0300	[thread overview]
Message-ID: <503369B7.50007@redhat.com> (raw)
In-Reply-To: <1345288635-1369-7-git-send-email-quintela@redhat.com>

On 08/18/2012 02:17 PM, Juan Quintela wrote:
> Signed-off-by: Juan Quintela <quintela@redhat.com>
> ---
>  arch_init.c | 17 +++++++++--------
>  1 file changed, 9 insertions(+), 8 deletions(-)
> 
> diff --git a/arch_init.c b/arch_init.c
> index 0a9ca85..7eb6e86 100644
> --- a/arch_init.c
> +++ b/arch_init.c
> @@ -538,7 +538,7 @@ static int ram_save_iterate(QEMUFile *f, void *opaque)
>      double bwidth = 0;
>      int ret;
>      int i;
> -    uint64_t expected_time;
> +    uint64_t expected_downtime;
> 
>      bytes_transferred_last = bytes_transferred;
>      bwidth = qemu_get_clock_ns(rt_clock);
> @@ -577,24 +577,25 @@ static int ram_save_iterate(QEMUFile *f, void *opaque)
>      bwidth = qemu_get_clock_ns(rt_clock) - bwidth;
>      bwidth = (bytes_transferred - bytes_transferred_last) / bwidth;
> 
> -    /* if we haven't transferred anything this round, force expected_time to a
> -     * a very high value, but without crashing */
> +    /* if we haven't transferred anything this round, force
> +     * expected_downtime to a very high value, but without
> +     * crashing */
>      if (bwidth == 0) {
>          bwidth = 0.000001;
>      }
> 
>      qemu_put_be64(f, RAM_SAVE_FLAG_EOS);
> 
> -    expected_time = ram_save_remaining() * TARGET_PAGE_SIZE / bwidth;
> +    expected_downtime = ram_save_remaining() * TARGET_PAGE_SIZE / bwidth;
> 
>      DPRINTF("ram_save_live: expected(" PRIu64 ") <= max(" PRIu64 ")?\n",
> -            expected_time, migrate_max_downtime());
> +            expected_downtime, migrate_max_downtime());
> 
> -    if (expected_time <= migrate_max_downtime()) {
> +    if (expected_downtime <= migrate_max_downtime()) {
>          memory_global_sync_dirty_bitmap(get_system_memory());
> -        expected_time = ram_save_remaining() * TARGET_PAGE_SIZE / bwidth;
> +        expected_downtime = ram_save_remaining() * TARGET_PAGE_SIZE / bwidth;
> 
> -        return expected_time <= migrate_max_downtime();
> +        return expected_downtime <= migrate_max_downtime();
>      }
>      return 0;
>  }
> 
Reviewed-by: Orit Wasserman <owasserm@redhat.com>

  reply	other threads:[~2012-08-21 10:57 UTC|newest]

Thread overview: 23+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-08-18 11:17 [Qemu-devel] [PATCH v2 0/8] Migration stats Juan Quintela
2012-08-18 11:17 ` [Qemu-devel] [PATCH 1/8] buffered_file: g_realloc() can't fail Juan Quintela
2012-08-21 10:40   ` Orit Wasserman
2012-08-18 11:17 ` [Qemu-devel] [PATCH 2/8] fix migration sync Juan Quintela
2012-08-21 10:52   ` Orit Wasserman
2012-08-18 11:17 ` [Qemu-devel] [PATCH 3/8] migration: move total_time from ram stats to migration info Juan Quintela
2012-08-18 13:02   ` [Qemu-devel] For 1.2: " Eric Blake
2012-08-21 14:42     ` Luiz Capitulino
2012-08-21 15:00       ` Juan Quintela
2012-08-21 18:24         ` Luiz Capitulino
2012-08-22 13:22     ` Anthony Liguori
2012-08-22 14:48       ` Eric Blake
2012-08-21 10:53   ` [Qemu-devel] " Orit Wasserman
2012-08-18 11:17 ` [Qemu-devel] [PATCH 4/8] migration: store end_time in a local variable Juan Quintela
2012-08-18 11:17 ` [Qemu-devel] [PATCH 5/8] migration: print total downtime for final phase of migration Juan Quintela
2012-08-18 13:04   ` Eric Blake
2012-08-21 10:57   ` Orit Wasserman
2012-08-18 11:17 ` [Qemu-devel] [PATCH 6/8] migration: rename expected_time to expected_downtime Juan Quintela
2012-08-21 10:57   ` Orit Wasserman [this message]
2012-08-18 11:17 ` [Qemu-devel] [PATCH 7/8] migration: export migrate_get_current() Juan Quintela
2012-08-21 10:58   ` Orit Wasserman
2012-08-18 11:17 ` [Qemu-devel] [PATCH 8/8] migration: print expected downtime in info migrate Juan Quintela
2012-08-18 13:05   ` Eric Blake

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=503369B7.50007@redhat.com \
    --to=owasserm@redhat.com \
    --cc=qemu-devel@nongnu.org \
    --cc=quintela@redhat.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 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.