]> git.ipfire.org Git - thirdparty/mdadm.git/commit
sysfs: detect disks that are in the process of being removed
authorDan Williams <dan.j.williams@intel.com>
Tue, 16 Sep 2008 03:58:43 +0000 (20:58 -0700)
committerDan Williams <dan.j.williams@intel.com>
Tue, 16 Sep 2008 03:58:43 +0000 (20:58 -0700)
commit4795982e68f72ef44bd29c9883e5f6291088a3e1
tree6a17d7ec939a5d2c922a28c6a26c55f4fa44b9f2
parent4065aa816a64e9909ba1106640951f1dd490c4d0
sysfs: detect disks that are in the process of being removed

When removing a disk there is a window where the 'slot' attribute of
md/dev-$name will return -EBUSY to read attempts.  When this happens
look at the the 'block' link, if it is removed then we can be sure the
device has been removed, versus some other error.

Signed-off-by: Dan Williams <dan.j.williams@intel.com>
sysfs.c