diff options
author | Ilya Dryomov <idryomov@gmail.com> | 2012-01-16 15:04:49 -0500 |
---|---|---|
committer | Ilya Dryomov <idryomov@gmail.com> | 2012-01-16 15:04:49 -0500 |
commit | a7e99c691af553fc15ac46a51f130b7c59a65f76 (patch) | |
tree | 55491f285683951d509819a66e614ac6f12659dd /fs/btrfs/disk-io.c | |
parent | 837d5b6e46d1a4af5b6cc8f2fe83cb5de79a2961 (diff) |
Btrfs: allow for canceling restriper
Implement an ioctl for canceling restriper. Currently we wait until
relocation of the current block group is finished, in future this can be
done by triggering a commit. Balance item is deleted and no memory
about the interrupted balance is kept.
Signed-off-by: Ilya Dryomov <idryomov@gmail.com>
Diffstat (limited to 'fs/btrfs/disk-io.c')
-rw-r--r-- | fs/btrfs/disk-io.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/fs/btrfs/disk-io.c b/fs/btrfs/disk-io.c index 8ce837407800..c23b82d8ec08 100644 --- a/fs/btrfs/disk-io.c +++ b/fs/btrfs/disk-io.c | |||
@@ -2006,6 +2006,7 @@ struct btrfs_root *open_ctree(struct super_block *sb, | |||
2006 | mutex_init(&fs_info->balance_mutex); | 2006 | mutex_init(&fs_info->balance_mutex); |
2007 | atomic_set(&fs_info->balance_running, 0); | 2007 | atomic_set(&fs_info->balance_running, 0); |
2008 | atomic_set(&fs_info->balance_pause_req, 0); | 2008 | atomic_set(&fs_info->balance_pause_req, 0); |
2009 | atomic_set(&fs_info->balance_cancel_req, 0); | ||
2009 | fs_info->balance_ctl = NULL; | 2010 | fs_info->balance_ctl = NULL; |
2010 | init_waitqueue_head(&fs_info->balance_wait_q); | 2011 | init_waitqueue_head(&fs_info->balance_wait_q); |
2011 | 2012 | ||