Re: [PATCH 06/16] btrfs: move clearing of EXCL_OP out of __cancel_balance

2018-04-05 Thread David Sterba
On Thu, Apr 05, 2018 at 05:42:14PM +0800, Anand Jain wrote: > > > > @@ -3926,11 +3925,11 @@ int btrfs_balance(struct btrfs_balance_control > > *bctl, > > return ret; > > out: > > if (bctl->flags & BTRFS_BALANCE_RESUME) > > - __cancel_balance(fs_info); > > - else { > > +

Re: [PATCH 06/16] btrfs: move clearing of EXCL_OP out of __cancel_balance

2018-04-05 Thread Anand Jain
@@ -3926,11 +3925,11 @@ int btrfs_balance(struct btrfs_balance_control *bctl, return ret; out: if (bctl->flags & BTRFS_BALANCE_RESUME) - __cancel_balance(fs_info); - else { + reset_balance_state(fs_info); reset_balance_state() is something

[PATCH 06/16] btrfs: move clearing of EXCL_OP out of __cancel_balance

2018-04-03 Thread David Sterba
Make the clearning visible in the callers so we can pair it with the test_and_set part. Signed-off-by: David Sterba --- fs/btrfs/ioctl.c | 2 +- fs/btrfs/volumes.c | 15 --- 2 files changed, 9 insertions(+), 8 deletions(-) diff --git a/fs/btrfs/ioctl.c