Re: [PATCH 2/5] btrfs: use a separate variable to store the num_bytes of the qgroup_reserve

2018-08-08 Thread Lu Fengqi
David Sterba 于2018年8月8日周三 下午9:57写道: > > On Wed, Aug 08, 2018 at 11:04:37AM +0800, Lu Fengqi wrote: > > On Tue, Aug 07, 2018 at 06:19:12PM +0200, David Sterba wrote: > > >On Sat, Aug 04, 2018 at 09:10:54PM +0800, Lu Fengqi wrote: > > >> After btrfs_qgroup_reserve_meta_prealloc(), num_bytes will be

Re: [PATCH 2/5] btrfs: use a separate variable to store the num_bytes of the qgroup_reserve

2018-08-08 Thread David Sterba
On Wed, Aug 08, 2018 at 11:04:37AM +0800, Lu Fengqi wrote: > On Tue, Aug 07, 2018 at 06:19:12PM +0200, David Sterba wrote: > >On Sat, Aug 04, 2018 at 09:10:54PM +0800, Lu Fengqi wrote: > >> After btrfs_qgroup_reserve_meta_prealloc(), num_bytes will be assigned > >> again by

RE: [PATCH 2/5] btrfs: use a separate variable to store the num_bytes of the qgroup_reserve

2018-08-07 Thread Gu, Jinxiang
> -Original Message- > From: David Sterba [mailto:dste...@suse.cz] > Sent: Wednesday, August 08, 2018 12:19 AM > To: Lu, Fengqi/陆 丰麒 > Cc: linux-btrfs@vger.kernel.org; Gu, Jinxiang/顾 金香 > Subject: Re: [PATCH 2/5] btrfs: use a separate variable to store the > num_bytes of the

Re: [PATCH 2/5] btrfs: use a separate variable to store the num_bytes of the qgroup_reserve

2018-08-07 Thread Lu Fengqi
On Tue, Aug 07, 2018 at 06:19:12PM +0200, David Sterba wrote: >On Sat, Aug 04, 2018 at 09:10:54PM +0800, Lu Fengqi wrote: >> After btrfs_qgroup_reserve_meta_prealloc(), num_bytes will be assigned >> again by btrfs_calc_trans_metadata_size(). Therefore, once block_rsv >> fails, we cannot properly

Re: [PATCH 2/5] btrfs: use a separate variable to store the num_bytes of the qgroup_reserve

2018-08-07 Thread David Sterba
On Sat, Aug 04, 2018 at 09:10:54PM +0800, Lu Fengqi wrote: > After btrfs_qgroup_reserve_meta_prealloc(), num_bytes will be assigned > again by btrfs_calc_trans_metadata_size(). Therefore, once block_rsv > fails, we cannot properly free the num_bytes of the previous > qgroup_reserve. This does not