From mboxrd@z Thu Jan 1 00:00:00 1970 From: Josef Bacik Subject: Re: [PATCH V3 3/6] btrfs: fix wrong calculation of stripe size Date: Wed, 12 Jan 2011 08:51:07 -0500 Message-ID: <20110112135107.GC2645@localhost.localdomain> References: <4D2442DC.1060109@cn.fujitsu.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Cc: Chris Mason , Josef Bacik , Mitch Harder , Linux Btrfs To: Miao Xie Return-path: In-Reply-To: <4D2442DC.1060109@cn.fujitsu.com> List-ID: On Wed, Jan 05, 2011 at 06:07:24PM +0800, Miao Xie wrote: > There are two tiny problem: > - One is When we check the chunk size is greater than the max chunk size or not, > we should take mirrors into account, but the original code didn't. > - The other is btrfs shouldn't use the size of the residual free space as the > length of of a dup chunk when doing chunk allocation. It is because the device > space that a dup chunk needs is twice as large as the chunk size, if we use > the size of the residual free space as the length of a dup chunk, we can not > get enough free space. Fix it. > > Signed-off-by: Miao Xie Reviewed-by: Josef Bacik Thanks, Josef