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

Improve filter debug msgs.

This commit is contained in:
Alasdair Kergon 2004-11-24 20:36:52 +00:00
parent a614641aeb
commit 7f1e8db796
4 changed files with 12 additions and 7 deletions

View File

@ -1,5 +1,6 @@
Version 2.00.27 -
====================================
Improve filter debug mesgs.
Version 2.00.26 - 23rd November 2004
====================================

View File

@ -212,13 +212,10 @@ static int _lookup_p(struct dev_filter *f, struct device *dev)
sl = list_item(ah, struct str_list);
hash_insert(pf->devices, sl->str, l);
}
}
} else if (l == PF_BAD_DEVICE)
log_debug("%s: Skipping (cached)", dev_name(dev));
if (l == PF_BAD_DEVICE) {
log_debug("%s: Skipping (cached)", dev_name(dev));
return 0;
} else
return 1;
return (l == PF_BAD_DEVICE) ? 0 : 1;
}
static void _destroy(struct dev_filter *f)

View File

@ -186,6 +186,9 @@ static int _accept_p(struct dev_filter *f, struct device *dev)
first = 0;
}
if (rejected)
log_debug("%s: Skipping (regex)", dev_name(dev));
/*
* pass everything that doesn't match
* anything.

View File

@ -246,7 +246,11 @@ static int _accept_p(struct dev_filter *f, struct device *dev)
if (ds->initialised != 1)
return 1;
return _set_lookup(ds, dev->dev);
if (!_set_lookup(ds, dev->dev)) {
log_debug("%s: Skipping (sysfs)", dev_name(dev));
return 0;
} else
return 1;
}
static void _destroy(struct dev_filter *f)