From: Chris Lalancette <clalance@redhat.com>
To: "Daniel P. Berrange" <berrange@redhat.com>
Cc: kvm-devel <kvm@vger.kernel.org>
Subject: Re: [PATCH]: Add a "migrate_incoming" monitor option
Date: Fri, 01 Aug 2008 11:09:42 +0200 [thread overview]
Message-ID: <4892D2D6.8090703@redhat.com> (raw)
In-Reply-To: <20080731151149.GH18548@redhat.com>
Daniel P. Berrange wrote:
>> @@ -9673,11 +9675,16 @@ int main(int argc, char **argv)
>> if (incoming) {
>> int rc;
>>
>> - rc = migrate_incoming(incoming);
>> - if (rc != 0) {
>> - fprintf(stderr, "Migration failed rc=%d\n", rc);
>> - exit(rc);
>> - }
>> + if (strncmp(incoming, "monitor", 7) == 0) {
>> + incoming_monitor = 1;
>> + }
>> + else {
>> + rc = migrate_incoming(incoming);
>> + if (rc != 0) {
>> + fprintf(stderr, "Migration failed rc=%d\n", rc);
>> + exit(rc);
>> + }
>> + }
>
> Rather than putting the strncmp("monitor") into vl.c, I'd just leave
> this part as is. Put the logic into the 'migrate_incoming()' method
> so that it just sets the 'incoming_monitor' flag and then returns
> immediately. That would allwo the 'incoming_Monitor' flag to be declared
> static to the migrate.c file, instead of polluting vl.c
Actually, that won't quite work. We still need to share the incoming_monitor
flag between migration.c and monitor.c. However, your suggestion is better in
that this is a "migration-specific" flag, so I'll move it over like you suggest.
Chris Lalancette
next prev parent reply other threads:[~2008-08-01 9:11 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2008-07-31 14:50 [PATCH]: Add a "migrate_incoming" monitor option Chris Lalancette
2008-07-31 15:11 ` Daniel P. Berrange
2008-08-01 9:09 ` Chris Lalancette [this message]
2008-07-31 17:27 ` Anthony Liguori
2008-08-01 8:42 ` Daniel P. Berrange
2008-08-01 9:04 ` Chris Lalancette
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=4892D2D6.8090703@redhat.com \
--to=clalance@redhat.com \
--cc=berrange@redhat.com \
--cc=kvm@vger.kernel.org \
/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.