summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPetr Rockai <prockai@redhat.com>2013-02-18 16:20:20 +0100
committerPetr Rockai <prockai@redhat.com>2013-04-11 15:25:40 +0200
commit474709fae13aa3b2a6d8280b23b5b1b9208aa405 (patch)
tree62462016e79e3888eea9f979d96945e188aadbc0
parent2b5b913d2b806f7af05f2ae5b96186addd9863cd (diff)
downloadlvm2-474709fae13aa3b2a6d8280b23b5b1b9208aa405.tar.gz
lvm1: Do not call into lvmcache from low-level code.
This path is not performance-sensitive anyway (LVM1 is long deprecated) and disk-rep is very low-level code that has no business talking to lvmcache.
-rw-r--r--lib/format1/disk-rep.c18
1 files changed, 0 insertions, 18 deletions
diff --git a/lib/format1/disk-rep.c b/lib/format1/disk-rep.c
index 19776e068..adc38ba80 100644
--- a/lib/format1/disk-rep.c
+++ b/lib/format1/disk-rep.c
@@ -493,24 +493,6 @@ int read_pvs_in_vg(const struct format_type *fmt, const char *vg_name,
baton.mem = mem;
baton.vg_name = vg_name;
- /* Fast path if we already saw this VG and cached the list of PVs */
- if (vg_name && (vginfo = lvmcache_vginfo_from_vgname(vg_name, NULL))) {
-
- lvmcache_foreach_pv(vginfo, _read_pv_in_vg, &baton);
-
- if (!baton.empty) {
- /* Did we find the whole VG? */
- if (!vg_name || is_orphan_vg(vg_name) ||
- (baton.data && *baton.data->pvd.vg_name &&
- dm_list_size(head) == baton.data->vgd.pv_cur))
- return 1;
-
- /* Failed */
- dm_list_init(head);
- /* vgcache_del(vg_name); */
- }
- }
-
if (!(iter = dev_iter_create(filter, 1))) {
log_error("read_pvs_in_vg: dev_iter_create failed");
return 0;