Replace GetLvmDiskTemplates by 'DTS_LVM'
authorHelga Velroyen <helgav@google.com>
Tue, 8 Oct 2013 12:26:47 +0000 (14:26 +0200)
committerHelga Velroyen <helgav@google.com>
Wed, 9 Oct 2013 10:40:24 +0000 (12:40 +0200)
To reach consistency by how we manage different
categorizations of disk templates, this patch
introduces the set of disk templates which are lvm-based:
'DTS_LVM'.

Signed-off-by: Helga Velroyen <helgav@google.com>
Reviewed-by: Klaus Aehlig <aehlig@google.com>

lib/constants.py

index 023f059..0752e83 100644 (file)
@@ -328,6 +328,9 @@ DRBD_B_DISK_BARRIERS = _constants.DRBD_B_DISK_BARRIERS
 DRBD_B_DISK_DRAIN = _constants.DRBD_B_DISK_DRAIN
 DRBD_B_DISK_FLUSH = _constants.DRBD_B_DISK_FLUSH
 
+# the set of lvm-based disk templates
+DTS_LVM = DISK_TEMPLATES - DTS_NOT_LVM
+
 # Valid barrier combinations: "n" or any non-null subset of "bfd"
 DRBD_VALID_BARRIER_OPT = compat.UniqueFrozenset([
   frozenset([DRBD_B_NONE]),