From 26f467a9548dcebe07d576deb6ceb02b947eaecc Mon Sep 17 00:00:00 2001 From: "martin f. krafft" Date: Fri, 28 May 2010 14:12:41 +0200 Subject: Compile-time switch to enable 0.9 metadata as default This commit introduces DEFAULT_OLD_METADATA as a preprocessor definition. If defined, it causes mdadm to assume metadata version 0.9 as default. If not defined, version 1.x (currently 1.2) is used as default. The man page mdadm.8 is also modified to reflect the chosen default. The selftests will not work if the old default is chosen. This patch was requested by Debian so they could distribute a current mdadm together with boot loaders that only understand 0.90 metadata for md-raid. Preferred usage is simply make DEFAULT_OLD_METADATA=yes Signed-off-by: martin f. krafft Signed-off-by: NeilBrown --- super1.c | 2 ++ 1 file changed, 2 insertions(+) (limited to 'super1.c') diff --git a/super1.c b/super1.c index 8fa0745..216690d 100644 --- a/super1.c +++ b/super1.c @@ -1381,7 +1381,9 @@ static struct supertype *match_metadata_desc1(char *arg) return st; } if (strcmp(arg, "1.2") == 0 || +#ifndef DEFAULT_OLD_METADATA /* ifdef in super0.c */ strcmp(arg, "default") == 0 || +#endif /* DEFAULT_OLD_METADATA */ strcmp(arg, "1.02") == 0) { st->minor_version = 2; return st; -- cgit