[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <x49k3xl8jeu.fsf@segfault.boston.devel.redhat.com>
Date: Mon, 30 Jul 2012 09:31:37 -0400
From: Jeff Moyer <jmoyer@...hat.com>
To: majianpeng <majianpeng@...il.com>
Cc: viro <viro@...IV.linux.org.uk>, "Neil Brown" <neilb@...e.de>,
linux-fsdevel <linux-fsdevel@...r.kernel.org>,
linux-kernel <linux-kernel@...r.kernel.org>,
linux-raid <linux-raid@...r.kernel.org>
Subject: Re: [RFC PATCH] fs/direct-io.c: Set bi_rw when alloc bio.
majianpeng <majianpeng@...il.com> writes:
> On 2012-07-27 22:21 Jeff Moyer <jmoyer@...hat.com> Wrote:
>>majianpeng <majianpeng@...il.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@...il.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@...hat.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
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists