Commit db767672 authored by Guoqing Jiang's avatar Guoqing Jiang Committed by Shaohua Li

md: simplify the code with md_kick_rdev_from_array

Signed-off-by: default avatarGuoqing Jiang <gqjiang@suse.com>
Signed-off-by: default avatarShaohua Li <shli@fb.com>
parent bb8bf15b
...@@ -2478,8 +2478,7 @@ static int add_bound_rdev(struct md_rdev *rdev) ...@@ -2478,8 +2478,7 @@ static int add_bound_rdev(struct md_rdev *rdev)
if (add_journal) if (add_journal)
mddev_resume(mddev); mddev_resume(mddev);
if (err) { if (err) {
unbind_rdev_from_array(rdev); md_kick_rdev_from_array(rdev);
export_rdev(rdev);
return err; return err;
} }
} }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment