Commit 5492c46e authored by Alexey Obitotskiy's avatar Alexey Obitotskiy Committed by Shaohua Li

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: default avatarAlexey Obitotskiy <aleksey.obitotskiy@intel.com>
Signed-off-by: default avatarShaohua Li <shli@fb.com>
parent 208410b5
...@@ -4283,6 +4283,8 @@ new_dev_store(struct mddev *mddev, const char *buf, size_t len) ...@@ -4283,6 +4283,8 @@ new_dev_store(struct mddev *mddev, const char *buf, size_t len)
if (err) if (err)
export_rdev(rdev); export_rdev(rdev);
mddev_unlock(mddev); mddev_unlock(mddev);
if (!err)
md_new_event(mddev);
return err ? err : len; return err ? err : len;
} }
......
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