Displaying 5 results from an estimated 5 matches for "mdp_major".
2006 May 08
1
create_dev and raid
...].partitioned;
@@ -231,8 +230,6 @@
snprintf(name, sizeof name,
"/dev/md%s%d", partitioned?"_d":"", dev_minor);
+ if (!stat(name,&st)) continue;
+
if (partitioned)
dev = makedev(mdp_major(), dev_minor << MdpMinorShift);
else
2006 May 10
1
[patch] skip existing md devices
...r = md_setup_args[ent].minor;
partitioned = md_setup_args[ent].partitioned;
@@ -230,6 +231,9 @@
snprintf(name, sizeof name,
"/dev/md%s%d", partitioned?"_d":"", dev_minor);
+ if (stat(name,&st) == 0)
+ continue;
+
if (partitioned)
dev = makedev(mdp_major(), dev_minor << MdpMinorShift);
else
2007 Dec 11
0
[git patch] kinit fix, header install cleanup
...d = md_setup_args[ent].partitioned;
@@ -235,6 +236,9 @@ static void md_setup_drive(void)
snprintf(name, sizeof name,
"/dev/md%s%d", partitioned ? "_d" : "", dev_minor);
+ if (stat(name, &st_chk) == 0)
+ continue;
+
if (partitioned)
dev = makedev(mdp_major(), dev_minor << MdpMinorShift);
else
2008 Mar 25
2
bunch of small fixes
...d = md_setup_args[ent].partitioned;
@@ -235,6 +236,9 @@ static void md_setup_drive(void)
snprintf(name, sizeof name,
"/dev/md%s%d", partitioned ? "_d" : "", dev_minor);
+ if (stat(name, &st_chk) == 0)
+ continue;
+
if (partitioned)
dev = makedev(mdp_major(), dev_minor << MdpMinorShift);
else
2007 Aug 24
2
[git patch] klibc bzero, mount fixes + random stuff
...m/
don't shadow major(), minor()
Signed-off-by: maximilian attems <max at stro.at>
diff --git a/usr/kinit/do_mounts_md.c b/usr/kinit/do_mounts_md.c
index 696ffbd..6d4facc 100644
--- a/usr/kinit/do_mounts_md.c
+++ b/usr/kinit/do_mounts_md.c
@@ -142,7 +142,7 @@ static int mdp_major(void)
*/
static int md_setup(char *str)
{
- int minor, level, factor, fault, partitioned = 0;
+ int minor_num, level, factor, fault, partitioned = 0;
char *pername = "";
char *str1;
int ent;
@@ -151,28 +151,28 @@ static int md_setup(char *str)
partitioned = 1;
str++;
}
-...