On Tue, Apr 22, 2025 at 04:31:57PM +0800, Xiao Ni wrote: > There is another reason that I want to put del_gendisk in the ioctl > path. Because sometimes device node can still exist after command > mdadm --stop. del_gendisk removes inode first and then removes device > node (e.g. /dev/md0). So there is a small window that device node can > be open again. Then some strange things happen. Sometimes the array is > created but device node can't be created (I guess it's removed by > devtempfs?). Sometimes the kernel message prints "block device > autoloading is deprecated and will be removed". FYI, I'm all for sorting out the md gendisk lifetime and probing mess. But let's do that separately from a regression fix as changes in the area are intricate and might cause further regressions.