diff options
author | Zdenek Kabelac <zkabelac@redhat.com> | 2011-02-18 14:11:22 +0000 |
---|---|---|
committer | Zdenek Kabelac <zkabelac@redhat.com> | 2011-02-18 14:11:22 +0000 |
commit | 794e94fe163a9f1ce0974a4a76e96927222f909c (patch) | |
tree | e7129650cc2efab5e27fa0e65924c2bd59ea4bbb /lib/filters/filter.c | |
parent | 9dd091e4f4cfa577bf6ee69089a7dfaea1cd2dc4 (diff) | |
download | lvm2-794e94fe163a9f1ce0974a4a76e96927222f909c.tar.gz lvm2-794e94fe163a9f1ce0974a4a76e96927222f909c.tar.xz lvm2-794e94fe163a9f1ce0974a4a76e96927222f909c.zip |
Replace PV_MIN_SIZE with function pv_min_size()
Add configurable option to define minimal size of
of block device usable as a PV.
pv_min_size() is added to lvm-globals and it's being
initialized through _process_config.
Macro PV_MIN_SIZE is unused and removed.
New define DEFAULT_PV_MIN_SIZE_KB is added to lvm-global
and unlike PV_MIN_SIZE it uses KB units.
Should help users with various slow devices attached to the system,
which cannot be easily filtered out (like FDD on /dev/sdX):
https://bugzilla.redhat.com/show_bug.cgi?id=644578
Diffstat (limited to 'lib/filters/filter.c')
-rw-r--r-- | lib/filters/filter.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/filters/filter.c b/lib/filters/filter.c index 6f775eeb..1c043fcd 100644 --- a/lib/filters/filter.c +++ b/lib/filters/filter.c @@ -158,7 +158,7 @@ static int _passes_lvm_type_device_filter(struct dev_filter *f __attribute__((un goto out; } - if (size < PV_MIN_SIZE) { + if (size < pv_min_size()) { log_debug("%s: Skipping: Too small to hold a PV", name); goto out; } |