summaryrefslogtreecommitdiffstats
path: root/drivers/md/md.c
diff options
context:
space:
mode:
authorAlexey Obitotskiy <aleksey.obitotskiy@intel.com>2017-07-28 15:49:25 +0200
committerShaohua Li <shli@fb.com>2017-08-25 19:21:45 +0200
commit5492c46e94b57b5137e3ba2c9ae22b2dcc3fc2cc (patch)
treed73aaf51ac021ec18e5b24b270500f66a11411bc /drivers/md/md.c
parentmd/raid1/10: reset bio allocated from mempool (diff)
downloadlinux-5492c46e94b57b5137e3ba2c9ae22b2dcc3fc2cc.tar.xz
linux-5492c46e94b57b5137e3ba2c9ae22b2dcc3fc2cc.zip
md: notify about new spare disk in the container
In case of external metadata arrays spare disks are added to containers first. mdadm keeps monitoring /proc/mdstat output and when spare disk is available, it moves it from the container to the array. The problem is there is no notification of new spare disk in the container and mdadm waits a long time (until timeout) before it takes the action. Signed-off-by: Alexey Obitotskiy <aleksey.obitotskiy@intel.com> Signed-off-by: Shaohua Li <shli@fb.com>
Diffstat (limited to '')
-rw-r--r--drivers/md/md.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/drivers/md/md.c b/drivers/md/md.c
index b01e458d31e9..95c0b644a5b9 100644
--- a/drivers/md/md.c
+++ b/drivers/md/md.c
@@ -4283,6 +4283,8 @@ new_dev_store(struct mddev *mddev, const char *buf, size_t len)
if (err)
export_rdev(rdev);
mddev_unlock(mddev);
+ if (!err)
+ md_new_event(mddev);
return err ? err : len;
}