diff options
author | Jonathan Brassow <jbrassow@redhat.com> | 2012-08-24 15:34:19 -0500 |
---|---|---|
committer | Jonathan Brassow <jbrassow@redhat.com> | 2012-08-24 15:34:19 -0500 |
commit | 4047e4dfb16175daec348bf44032c02181bd4c70 (patch) | |
tree | c65d274f9d8058e77771d439652d49c7af9d4c6b /lib/metadata/mirror.c | |
parent | 99d1e264a87eb256debe2eaa02d9fc4e2b08c815 (diff) | |
download | lvm2-4047e4dfb16175daec348bf44032c02181bd4c70.tar.gz lvm2-4047e4dfb16175daec348bf44032c02181bd4c70.tar.xz lvm2-4047e4dfb16175daec348bf44032c02181bd4c70.zip |
RAID: Add support for RAID10
This patch adds support for RAID10. It is not the default at this
stage. The user needs to specify '--type raid10' if they would like
RAID10 instead of stacked mirror over stripe.
Diffstat (limited to 'lib/metadata/mirror.c')
-rw-r--r-- | lib/metadata/mirror.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/lib/metadata/mirror.c b/lib/metadata/mirror.c index ac885d6d..e3662c12 100644 --- a/lib/metadata/mirror.c +++ b/lib/metadata/mirror.c @@ -114,6 +114,10 @@ uint32_t lv_mirror_count(const struct logical_volume *lv) seg = first_seg(lv); + /* FIXME: RAID10 only supports 2 copies right now */ + if (!strcmp(seg->segtype->name, "raid10")) + return 2; + if (lv->status & PVMOVE) return seg->area_count; |