md: use new apis to suspend array for adding/removing rdev from state_store()
authorYu Kuai <yukuai3@huawei.com>
Tue, 10 Oct 2023 15:19:50 +0000 (23:19 +0800)
committerSong Liu <song@kernel.org>
Wed, 11 Oct 2023 01:49:50 +0000 (18:49 -0700)
commitcfa078c8b80d0daf8f2fd4a2ab8e26fa8c33bca1
tree6340aaca669b9cd4f4c0798e01137a36528eda9c
parent205669f37770772c1ae8c2dac1eba6da521a8b77
md: use new apis to suspend array for adding/removing rdev from state_store()

User can write 'remove' and 're-add' to trigger array reconfiguration
through sysfs, suspend array in this case so that io won't concurrent
with array reconfiguration.

And now that all the caller of add_bound_rdev() alread suspend the
array, remove mddev_suspend/resume() from add_bound_rdev() as well.

Signed-off-by: Yu Kuai <yukuai3@huawei.com>
Signed-off-by: Song Liu <song@kernel.org>
Link: https://lore.kernel.org/r/20231010151958.145896-12-yukuai1@huaweicloud.com
drivers/md/md.c