diff options
author | Ilya Dryomov <idryomov@gmail.com> | 2012-06-22 14:24:13 -0400 |
---|---|---|
committer | Chris Mason <chris.mason@fusionio.com> | 2012-07-02 15:39:17 -0400 |
commit | 2b6ba629b5aac51e7099efbb43e2b403213aa7fb (patch) | |
tree | 0a36f4adb14a57fdf4ee1dafa957927b6a6f9203 /fs/btrfs/super.c | |
parent | 68310a5e42f93c2242ec1836c3b18d531e0065e2 (diff) |
Btrfs: resume balance on rw (re)mounts properly
This introduces btrfs_resume_balance_async(), which, given that
restriper state was recovered earlier by btrfs_recover_balance(),
resumes balance in btrfs-balance kthread.
Signed-off-by: Ilya Dryomov <idryomov@gmail.com>
Diffstat (limited to 'fs/btrfs/super.c')
-rw-r--r-- | fs/btrfs/super.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/fs/btrfs/super.c b/fs/btrfs/super.c index 0eb9a4da069e..e23991574fdf 100644 --- a/fs/btrfs/super.c +++ b/fs/btrfs/super.c | |||
@@ -1187,6 +1187,10 @@ static int btrfs_remount(struct super_block *sb, int *flags, char *data) | |||
1187 | if (ret) | 1187 | if (ret) |
1188 | goto restore; | 1188 | goto restore; |
1189 | 1189 | ||
1190 | ret = btrfs_resume_balance_async(fs_info); | ||
1191 | if (ret) | ||
1192 | goto restore; | ||
1193 | |||
1190 | sb->s_flags &= ~MS_RDONLY; | 1194 | sb->s_flags &= ~MS_RDONLY; |
1191 | } | 1195 | } |
1192 | 1196 | ||