Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/torvalds/linux.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorChristoph Hellwig <hch@lst.de>2020-06-06 16:00:24 +0300
committerChristoph Hellwig <hch@lst.de>2020-07-16 16:35:03 +0300
commitd82fa81c2364a464ae585eed523496aa00909c17 (patch)
tree2277803922ee5d0e12aa68ea40909ae90a96efbc /drivers/md/md-autodetect.c
parent4f5b246b37e024955c0fcca0c7f5952089052d1d (diff)
md: replace the RAID_AUTORUN ioctl with a direct function call
Instead of using a spcial RAID_AUTORUN ioctl that only exists for non-modular builds and is only called from the early init code, just call the actual function directly. Signed-off-by: Christoph Hellwig <hch@lst.de> Reviewed-by: NeilBrown <neilb@suse.de> Acked-by: Song Liu <song@kernel.org> Acked-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'drivers/md/md-autodetect.c')
-rw-r--r--drivers/md/md-autodetect.c10
1 files changed, 2 insertions, 8 deletions
diff --git a/drivers/md/md-autodetect.c b/drivers/md/md-autodetect.c
index fe806f7b9759..0eb746211ed5 100644
--- a/drivers/md/md-autodetect.c
+++ b/drivers/md/md-autodetect.c
@@ -9,6 +9,7 @@
#include <linux/raid/detect.h>
#include <linux/raid/md_u.h>
#include <linux/raid/md_p.h>
+#include "md.h"
/*
* When md (and any require personalities) are compiled into the kernel
@@ -285,8 +286,6 @@ __setup("md=", md_setup);
static void __init autodetect_raid(void)
{
- int fd;
-
/*
* Since we don't want to detect and use half a raid array, we need to
* wait for the known devices to complete their probing
@@ -295,12 +294,7 @@ static void __init autodetect_raid(void)
printk(KERN_INFO "md: If you don't use raid, use raid=noautodetect\n");
wait_for_device_probe();
-
- fd = ksys_open("/dev/md0", 0, 0);
- if (fd >= 0) {
- ksys_ioctl(fd, RAID_AUTORUN, raid_autopart);
- ksys_close(fd);
- }
+ md_autostart_arrays(raid_autopart);
}
void __init md_run_setup(void)