qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: "Jason J. Herne" <jjherne@linux.vnet.ibm.com>
To: "Dr. David Alan Gilbert" <dgilbert@redhat.com>
Cc: amit.shah@redhat.com, borntraeger@de.ibm.com,
	qemu-devel@nongnu.org, afaerber@suse.de, quintela@redhat.com
Subject: Re: [Qemu-devel] [PATCH v3 3/5] migration: Dynamic cpu throttling for auto-converge
Date: Fri, 26 Jun 2015 15:07:18 -0400	[thread overview]
Message-ID: <558DA2E6.5020504@linux.vnet.ibm.com> (raw)
In-Reply-To: <20150626175441.GJ2186@work-vm>

On 06/26/2015 01:54 PM, Dr. David Alan Gilbert wrote:
> * Jason J. Herne (jjherne@linux.vnet.ibm.com) wrote:
...
>> diff --git a/migration/migration.c b/migration/migration.c
>> index 05790e9..7708c54 100644
>> --- a/migration/migration.c
>> +++ b/migration/migration.c
>> @@ -25,6 +25,7 @@
>>   #include "qemu/thread.h"
>>   #include "qmp-commands.h"
>>   #include "trace.h"
>> +#include "qom/cpu.h"
>>
>>   #define MAX_THROTTLE  (32 << 20)      /* Migration speed throttling */
>>
>> @@ -858,6 +859,9 @@ static void *migration_thread(void *opaque)
>>           }
>>       }
>>
>> +    /* If we enabled cpu throttling for auto-converge, turn it off. */
>> +    cpu_throttle_stop();
>> +
>>       qemu_mutex_lock_iothread();
>>       if (s->state == MIGRATION_STATUS_COMPLETED) {
>>           int64_t end_time = qemu_clock_get_ms(QEMU_CLOCK_REALTIME);
>
> Is that cpu_throttle_stop() sufficient if I use 'migration cancel'
> so that next time through it's all reset so that there's no throttling
> at the beginning?
>

It will be reset when cpu_throttle_set is called again when auto-converge
re-enables throttling for the next migration. This happens in patch 3,
mig_throttle_guest_down():

Basically, cpu_throttle_set requires the user to provide a throttling
percentage. So starting a new throttling operation will overwrite the
previous value.

-- 
-- Jason J. Herne (jjherne@linux.vnet.ibm.com)

  parent reply	other threads:[~2015-06-26 19:07 UTC|newest]

Thread overview: 22+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-06-25 17:46 [Qemu-devel] [PATCH v3 0/5] migration: Dynamic cpu throttling for auto-converge Jason J. Herne
2015-06-25 17:46 ` [Qemu-devel] [PATCH v3 1/5] cpu: Provide vcpu throttling interface Jason J. Herne
2015-06-26 18:07   ` Dr. David Alan Gilbert
2015-06-26 19:02     ` Jason J. Herne
2015-06-29  9:27       ` Dr. David Alan Gilbert
2015-06-29 14:42       ` Jason J. Herne
2015-07-01 14:03     ` Paolo Bonzini
2015-07-02 14:25       ` Jason J. Herne
2015-07-02 14:27         ` Paolo Bonzini
2015-07-02 16:33       ` Jason J. Herne
2015-07-02 16:34         ` Paolo Bonzini
2015-07-01 13:57   ` Paolo Bonzini
2015-06-25 17:46 ` [Qemu-devel] [PATCH v3 2/5] migration: Parameters for auto-converge cpu throttling Jason J. Herne
2015-06-26 17:20   ` Dr. David Alan Gilbert
2015-06-25 17:46 ` [Qemu-devel] [PATCH v3 3/5] migration: Dynamic cpu throttling for auto-converge Jason J. Herne
2015-06-26 17:54   ` Dr. David Alan Gilbert
2015-06-26 18:42     ` Jason J. Herne
2015-06-26 19:07     ` Jason J. Herne [this message]
2015-06-25 17:46 ` [Qemu-devel] [PATCH v3 4/5] qmp/hmp: Add throttle ratio to query-migrate and info migrate Jason J. Herne
2015-06-26 18:32   ` Dr. David Alan Gilbert
2015-06-25 17:46 ` [Qemu-devel] [PATCH v3 5/5] migration: Disambiguate MAX_THROTTLE Jason J. Herne
2015-06-26 18:36   ` Dr. David Alan Gilbert

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=558DA2E6.5020504@linux.vnet.ibm.com \
    --to=jjherne@linux.vnet.ibm.com \
    --cc=afaerber@suse.de \
    --cc=amit.shah@redhat.com \
    --cc=borntraeger@de.ibm.com \
    --cc=dgilbert@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 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).