在 2025/06/10 15:20, Xiao Ni 写道:
UNTIL_STOP is used to avoid mddev is freed on the last close before adding disks to mddev. And it should be cleared when stopping an array which is mentioned in commit efeb53c0e572 ("md: Allow md devices to be created by name."). So reset ->hold_active to 0 in md_clean. And MD_CLOSING should be kept until mddev is freed to avoid reopen. Signed-off-by: Xiao Ni<xni@xxxxxxxxxx> --- drivers/md/md.c | 16 ++++------------ 1 file changed, 4 insertions(+), 12 deletions(-)
Reviewed-by: Yu Kuai <yukuai3@xxxxxxxxxx>