summaryrefslogtreecommitdiff
path: root/super1.c
diff options
context:
space:
mode:
authorNeilBrown <neilb@suse.com>2015-09-28 11:49:53 +1000
committerNeilBrown <neilb@suse.com>2015-09-28 12:27:37 +1000
commit86a406c2262e1db3309623413992eecbb9ee1ce3 (patch)
tree9164d2c947335499c6b6320707a7ff99e5ca202d /super1.c
parent6d9c7c2551ca31a800f61e36192ee12be20974b1 (diff)
downloadmdadm-86a406c2262e1db3309623413992eecbb9ee1ce3.tar.gz
super1: Do not create bad block log for clustered devices.
We currently have no synchronization techniques for the bad block log, so disable it for the cluster. Reported-by: Goldwyn Rodrigues <rgoldwyn@suse.com> Signed-off-by: NeilBrown <neilb@suse.com>
Diffstat (limited to 'super1.c')
-rw-r--r--super1.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/super1.c b/super1.c
index 52952eb..6f42291 100644
--- a/super1.c
+++ b/super1.c
@@ -1701,7 +1701,8 @@ static int write_init_super1(struct supertype *st)
rv = -EINVAL;
goto out;
}
- if (conf_get_create_info()->bblist == 0) {
+ /* Disable badblock log on clusters, or when explicitly requested */
+ if (st->nodes > 0 || conf_get_create_info()->bblist == 0) {
sb->bblog_size = 0;
sb->bblog_offset = 0;
}