On 9/5/20 5:06 PM, Zhao Heming wrote: > report LV is usable for upper layer. > > Signed-off-by: Zhao Heming <heming.zhao@xxxxxxxx> > --- > lib/activate/activate.h | 2 + > lib/activate/dev_manager.c | 67 ++++++++++++++++ > lib/metadata/metadata-exported.h | 1 + > lib/metadata/metadata.c | 130 +++++++++++++++++++++++++++++++ > lib/report/columns.h | 1 + > lib/report/properties.c | 2 + > lib/report/report.c | 13 ++++ > lib/report/values.h | 1 + > 8 files changed, 217 insertions(+) > There are some places need to improve. 1. in lib/activate/dev_manager.c, function lv_mapping_table() & dm_has_lvdev() almost same. it may merge into one function. 2. LV device-mapper name need to improve, in lib/metadata/metadata.c _lv_is_usable() I use below ugly code to construct dm name ``` /* format is right: "vgname" + '-' + "lvname" ?? */ snprintf(lvname, 50, "%s-%s", lv->vg->name, seg_lv(seg, s)->name); ... ... /* format is right: "vgname" + '-' + "lvname" ?? */ snprintf(lvname, 50, "%s-%s", lv->vg->name, lv->name); ``` Thanks _______________________________________________ linux-lvm mailing list linux-lvm@xxxxxxxxxx https://www.redhat.com/mailman/listinfo/linux-lvm read the LVM HOW-TO at http://tldp.org/HOWTO/LVM-HOWTO/