diff options
author | NeilBrown <neilb@suse.de> | 2014-07-31 13:54:54 +1000 |
---|---|---|
committer | NeilBrown <neilb@suse.de> | 2014-07-31 13:54:54 +1000 |
commit | af5628f05db62c656f994b2346897939b5110d6a (patch) | |
tree | d3157495b181dbb830fc44375130bde365037a25 /arch/frv/mm | |
parent | 2446dba03f9dabe0b477a126cbeb377854785b47 (diff) | |
download | linux-af5628f05db62c656f994b2346897939b5110d6a.tar.bz2 |
md: disable probing for md devices 512 and over.
The way md devices are traditionally created in the kernel
is simply to open the device with the desired major/minor number.
This can be problematic as some support tools, notably udev and
programs run by udev, can open a device just to see what is there, and
find that it has created something. It is easy for a race to cause
udev to open an md device just after it was destroy, causing it to
suddenly re-appear.
For some time we have had an alternate way to create md devices
echo md_somename > /sys/modules/md_mod/paramaters/new_array
This will always use a minor number of 512 or higher, which mdadm
normally avoids.
Using this makes the creation-by-opening unnecessary, but does
not disable it, so it is still there to cause problems.
This patch disable probing for devices with a major of 9 (MD_MAJOR)
and a minor of 512 and up. This devices created by writing to
new_array cannot be re-created by opening the node in /dev.
Signed-off-by: NeilBrown <neilb@suse.de>
Diffstat (limited to 'arch/frv/mm')
0 files changed, 0 insertions, 0 deletions