[PATCH 4/6] Btrfs: fix race between fs trimming and block group remove/allocation

2014-11-26 Thread Filipe Manana
Our fs trim operation, which is completely transactionless (doesn't start or joins an existing transaction) consists of visiting all block groups and then for each one to iterate its free space entries and perform a discard operation against the space range represented by the free space entries.

Re: [PATCH 4/6] Btrfs: fix race between fs trimming and block group remove/allocation

2014-11-26 Thread Josef Bacik
On 11/26/2014 10:28 AM, Filipe Manana wrote: Our fs trim operation, which is completely transactionless (doesn't start or joins an existing transaction) consists of visiting all block groups and then for each one to iterate its free space entries and perform a discard operation against the space

Re: [PATCH 4/6] Btrfs: fix race between fs trimming and block group remove/allocation

2014-11-26 Thread Filipe David Manana
On Wed, Nov 26, 2014 at 4:15 PM, Josef Bacik jba...@fb.com wrote: On 11/26/2014 10:28 AM, Filipe Manana wrote: Our fs trim operation, which is completely transactionless (doesn't start or joins an existing transaction) consists of visiting all block groups and then for each one to iterate its

Re: [PATCH 4/6] Btrfs: fix race between fs trimming and block group remove/allocation

2014-11-26 Thread Josef Bacik
On 11/26/2014 11:25 AM, Filipe David Manana wrote: On Wed, Nov 26, 2014 at 4:15 PM, Josef Bacik jba...@fb.com wrote: On 11/26/2014 10:28 AM, Filipe Manana wrote: Our fs trim operation, which is completely transactionless (doesn't start or joins an existing transaction) consists of visiting