1
0
mirror of git://sourceware.org/git/lvm2.git synced 2024-12-21 13:34:40 +03:00

thin: report 'e' metadata type with higher priority

Giving volume type information about being 'metadata' type of volume
has higher priority then i.e.  'mirror' or 'thin' flag - for those
type we have 'target attr' (7th. field).
This commit is contained in:
Zdenek Kabelac 2013-06-05 13:46:38 +02:00
parent c0290489c3
commit 01ef97fcbb
2 changed files with 4 additions and 2 deletions

View File

@ -1,5 +1,6 @@
Version 2.02.99 -
===================================
Report lvs volume type 'e' with higher priority.
Report lvs volume type 'o' also for external origin volumes.
Report lvs target type 't' only for thin pools and thin volumes.
Fix test for active snapshot in cluster before resizing it.

View File

@ -536,6 +536,9 @@ char *lv_attr_dup(struct dm_pool *mem, const struct logical_volume *lv)
/* Origin takes precedence over mirror and thin volume */
else if (lv_is_origin(lv) || lv_is_external_origin(lv))
repstr[0] = (lv_is_merging_origin(lv)) ? 'O' : 'o';
else if (lv_is_thin_pool_metadata(lv) ||
(lv->status & RAID_META))
repstr[0] = 'e';
else if (lv->status & RAID)
repstr[0] = (lv->status & LV_NOTSYNCED) ? 'R' : 'r';
else if (lv->status & MIRRORED)
@ -548,8 +551,6 @@ char *lv_attr_dup(struct dm_pool *mem, const struct logical_volume *lv)
repstr[0] = 't';
else if (lv_is_thin_pool_data(lv))
repstr[0] = 'T';
else if (lv_is_thin_pool_metadata(lv) || (lv->status & RAID_META))
repstr[0] = 'e';
else if (lv->status & MIRROR_IMAGE)
repstr[0] = (_lv_mimage_in_sync(lv)) ? 'i' : 'I';
else if (lv->status & RAID_IMAGE)