All of lore.kernel.org
 help / color / mirror / Atom feed
From: Changlong Xie <xiecl.fnst@cn.fujitsu.com>
To: Alberto Garcia <berto@igalia.com>,
	qemu devel <qemu-devel@nongnu.org>,
	Eric Blake <eblake@redhat.com>, Kevin Wolf <kwolf@redhat.com>,
	Max Reitz <mreitz@redhat.com>
Cc: "Dr. David Alan Gilbert" <dgilbert@redhat.com>
Subject: Re: [Qemu-devel] [PATCH v3 1/1] quorum: modify vote rules for flush operation
Date: Tue, 23 Feb 2016 13:57:35 +0800	[thread overview]
Message-ID: <56CBF4CF.6030401@cn.fujitsu.com> (raw)
In-Reply-To: <w51egc4erws.fsf@maestria.local.igalia.com>

On 02/22/2016 10:33 PM, Alberto Garcia wrote:
> On Mon 22 Feb 2016 10:50:37 AM CET, Changlong Xie wrote:
>> -    winner = quorum_get_vote_winner(&error_votes);
>> -    result = winner->value.l;
>> -
>> +    if (success_count >= s->threshold)
>> +        result = 0;
>> +    else {
>> +        winner = quorum_get_vote_winner(&error_votes);
>> +        result = winner->value.l;
>> +    }
>
> Please use braces in both branches of the if. scripts/checkpatch.pl
> should report that.

Surely.

>
> Other than that I think the patch is correct, but I still wonder if we
> should emit QUORUM_REPORT_BAD (or a new event) for the operations that

To me QUORUM_REPORT_BAD is not a good choice.

> fail. Or why wouldn't the user want to be notified of a flush failure?
>

I'll introduce a new event in next series.

Thanks
	-Xie

> Berto
>
>
> .
>

      reply	other threads:[~2016-02-23  5:56 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-02-22  9:50 [Qemu-devel] [PATCH v3 0/1] modify vote rules for flush operation Changlong Xie
2016-02-22  9:50 ` [Qemu-devel] [PATCH v3 1/1] quorum: " Changlong Xie
2016-02-22 14:33   ` Alberto Garcia
2016-02-23  5:57     ` Changlong Xie [this message]

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=56CBF4CF.6030401@cn.fujitsu.com \
    --to=xiecl.fnst@cn.fujitsu.com \
    --cc=berto@igalia.com \
    --cc=dgilbert@redhat.com \
    --cc=eblake@redhat.com \
    --cc=kwolf@redhat.com \
    --cc=mreitz@redhat.com \
    --cc=qemu-devel@nongnu.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.