diff options
author | NeilBrown <neilb@suse.de> | 2011-12-20 05:01:53 +0100 |
---|---|---|
committer | NeilBrown <neilb@suse.de> | 2011-12-20 05:01:53 +0100 |
commit | cb0997242cd617c2c78295693af386add40b6ce2 (patch) | |
tree | 3483c4a7c5615b3ac17bfbd4d6c11259963a0a86 | |
parent | imsm: make messages more understandable (diff) | |
download | mdadm-cb0997242cd617c2c78295693af386add40b6ce2.tar.xz mdadm-cb0997242cd617c2c78295693af386add40b6ce2.zip |
super1: getinfo_super should set write-mostly flag.
Otherwise it is not preserved when you re-add a device to
an array.
Signed-off-by: NeilBrown <neilb@suse.de>
-rw-r--r-- | super1.c | 2 |
1 files changed, 2 insertions, 0 deletions
@@ -600,6 +600,8 @@ static void getinfo_super1(struct supertype *st, struct mdinfo *info, char *map) info->disk.state = 6; /* active and in sync */ info->disk.raid_disk = role; } + if (sb->devflags & WriteMostly1) + info->disk.state |= (1 << MD_DISK_WRITEMOSTLY); info->events = __le64_to_cpu(sb->events); sprintf(info->text_version, "1.%d", st->minor_version); info->safe_mode_delay = 200; |