summaryrefslogtreecommitdiffstats
path: root/mdopen.c
diff options
context:
space:
mode:
authorNeil Brown <neilb@suse.de>2005-04-04 05:16:16 +0000
committerNeil Brown <neilb@suse.de>2005-04-04 05:16:16 +0000
commit48f7b27ab48fc3ea0fa7d965604adbb275eb1c95 (patch)
tree286104c7484d765dd6db4a00e2257117f7160f4a /mdopen.c
parent0df46c2ad8872a9d6e5832f3098d12a7e0d2eb01 (diff)
downloadmdadm-48f7b27ab48fc3ea0fa7d965604adbb275eb1c95.tar.gz
mdadm-48f7b27ab48fc3ea0fa7d965604adbb275eb1c95.tar.xz
mdadm-48f7b27ab48fc3ea0fa7d965604adbb275eb1c95.zip
Document new --auto behaviour
Signed-off-by: Neil Brown <neilb@cse.unsw.edu.au>
Diffstat (limited to 'mdopen.c')
-rw-r--r--mdopen.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/mdopen.c b/mdopen.c
index 1ba5201..98c6fdb 100644
--- a/mdopen.c
+++ b/mdopen.c
@@ -92,6 +92,10 @@ int open_mddev(char *dev, int autof)
/* autof is set, so we need to check that the name is ok,
* and possibly create one if not
*/
+ if (autof == -2 && !is_standard(dev, NULL)) {
+ fprintf(stderr, Name ": --auto=yes requires a 'standard' md device name, not %s\n", dev);
+ return -1;
+ }
stb.st_mode = 0;
if (lstat(dev, &stb)==0 && ! S_ISBLK(stb.st_mode)) {
fprintf(stderr, Name ": %s is not a block device.\n",