linux-fsdevel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Jeff Moyer <jmoyer@redhat.com>
To: majianpeng <majianpeng@gmail.com>
Cc: viro <viro@ZenIV.linux.org.uk>, "Neil Brown" <neilb@suse.de>,
	linux-fsdevel <linux-fsdevel@vger.kernel.org>,
	linux-kernel <linux-kernel@vger.kernel.org>,
	linux-raid <linux-raid@vger.kernel.org>
Subject: Re: [RFC PATCH] fs/direct-io.c: Set bi_rw when alloc bio.
Date: Mon, 30 Jul 2012 09:31:37 -0400	[thread overview]
Message-ID: <x49k3xl8jeu.fsf@segfault.boston.devel.redhat.com> (raw)
In-Reply-To: <201207300840005466080@gmail.com> (majianpeng@gmail.com's message of "Mon, 30 Jul 2012 08:40:11 +0800")

majianpeng <majianpeng@gmail.com> writes:

> On 2012-07-27 22:21 Jeff Moyer <jmoyer@redhat.com> Wrote:
>>majianpeng <majianpeng@gmail.com> writes:
>>
>>> When exec bio_alloc, the bi_rw is zero.But after calling bio_add_page,
>>> it will use bi_rw.
>>> Fox example, in functiion __bio_add_page,it will call merge_bvec_fn().
>>> The merge_bvec_fn of raid456 will use the bi_rw to judge the merge.
>>>>> if ((bvm->bi_rw & 1) == WRITE)
>>>>>		return biovec->bv_len; /* always allow writes to be mergeable */
>>>
>>> Signed-off-by: Jianpeng Ma <majianpeng@gmail.com>
>>
>>Good catch.  How did you find this?  Did you experience data corruption
>>as a result of this oversight, reduced performance due to missed merge
>>opportunities, or did you just notice it in reviewing the code?
>>
>>Reviewed-by: Jeff Moyer <jmoyer@redhat.com>
>>
> Sorry for late to reply. When i analysed the performance of raid5, i found this bug.

OK, thanks.  In the future, it would be good to include that information
in the patch description.

Cheers,
Jeff

      reply	other threads:[~2012-07-30 13:31 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-07-27  8:02 [RFC PATCH] fs/direct-io.c: Set bi_rw when alloc bio majianpeng
2012-07-27 14:21 ` Jeff Moyer
2012-07-30  0:40   ` majianpeng
2012-07-30 13:31     ` Jeff Moyer [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=x49k3xl8jeu.fsf@segfault.boston.devel.redhat.com \
    --to=jmoyer@redhat.com \
    --cc=linux-fsdevel@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-raid@vger.kernel.org \
    --cc=majianpeng@gmail.com \
    --cc=neilb@suse.de \
    --cc=viro@ZenIV.linux.org.uk \
    /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).