mirror of
git://sourceware.org/git/lvm2.git
synced 2025-01-02 01:18:26 +03:00
When scanning, also record whether or not VG is exported.
This commit is contained in:
parent
f9c232c2ee
commit
f084e627cc
@ -1,6 +1,6 @@
|
|||||||
Version 2.02.03 -
|
Version 2.02.03 -
|
||||||
===================================
|
===================================
|
||||||
Whenever vgname is captured, also capture vgid.
|
Whenever vgname is captured, also capture vgid and whether exported.
|
||||||
Remove an incorrect unlock_vg() from process_each_lv().
|
Remove an incorrect unlock_vg() from process_each_lv().
|
||||||
Update extent size information in vgchange and vgcreate man pages.
|
Update extent size information in vgchange and vgcreate man pages.
|
||||||
Introduce origin_from_cow() and lv_is_visible().
|
Introduce origin_from_cow() and lv_is_visible().
|
||||||
|
30
lib/cache/lvmcache.c
vendored
30
lib/cache/lvmcache.c
vendored
@ -435,10 +435,28 @@ static int _lvmcache_update_vgname(struct lvmcache_info *info,
|
|||||||
return 1;
|
return 1;
|
||||||
}
|
}
|
||||||
|
|
||||||
int lvmcache_update_vgname_and_id(struct lvmcache_info *info, const char *vgname, const char *vgid)
|
static int _lvmcache_update_vgstatus(struct lvmcache_info *info, uint32_t vgstatus)
|
||||||
|
{
|
||||||
|
if (!info || !info->vginfo)
|
||||||
|
return 1;
|
||||||
|
|
||||||
|
if ((info->vginfo->status & EXPORTED_VG) != (vgstatus & EXPORTED_VG))
|
||||||
|
log_debug("lvmcache: %s: VG %s exported",
|
||||||
|
dev_name(info->dev),
|
||||||
|
vgstatus & EXPORTED_VG ? "now" : "no longer");
|
||||||
|
|
||||||
|
info->vginfo->status = vgstatus;
|
||||||
|
|
||||||
|
return 1;
|
||||||
|
}
|
||||||
|
|
||||||
|
int lvmcache_update_vgname_and_id(struct lvmcache_info *info,
|
||||||
|
const char *vgname, const char *vgid,
|
||||||
|
uint32_t vgstatus)
|
||||||
{
|
{
|
||||||
if (!_lvmcache_update_vgname(info, vgname) ||
|
if (!_lvmcache_update_vgname(info, vgname) ||
|
||||||
!_lvmcache_update_vgid(info, vgid))
|
!_lvmcache_update_vgid(info, vgid) ||
|
||||||
|
!_lvmcache_update_vgstatus(info, vgstatus))
|
||||||
return_0;
|
return_0;
|
||||||
|
|
||||||
return 1;
|
return 1;
|
||||||
@ -457,7 +475,8 @@ int lvmcache_update_vg(struct volume_group *vg)
|
|||||||
/* FIXME Could pvl->pv->dev->pvid ever be different? */
|
/* FIXME Could pvl->pv->dev->pvid ever be different? */
|
||||||
if ((info = info_from_pvid(pvid_s)) &&
|
if ((info = info_from_pvid(pvid_s)) &&
|
||||||
!lvmcache_update_vgname_and_id(info, vg->name,
|
!lvmcache_update_vgname_and_id(info, vg->name,
|
||||||
(char *) &vg->id))
|
(char *) &vg->id,
|
||||||
|
vg->status))
|
||||||
return_0;
|
return_0;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -466,7 +485,8 @@ int lvmcache_update_vg(struct volume_group *vg)
|
|||||||
|
|
||||||
struct lvmcache_info *lvmcache_add(struct labeller *labeller, const char *pvid,
|
struct lvmcache_info *lvmcache_add(struct labeller *labeller, const char *pvid,
|
||||||
struct device *dev,
|
struct device *dev,
|
||||||
const char *vgname, const char *vgid)
|
const char *vgname, const char *vgid,
|
||||||
|
uint32_t vgstatus)
|
||||||
{
|
{
|
||||||
struct label *label;
|
struct label *label;
|
||||||
struct lvmcache_info *existing, *info;
|
struct lvmcache_info *existing, *info;
|
||||||
@ -562,7 +582,7 @@ struct lvmcache_info *lvmcache_add(struct labeller *labeller, const char *pvid,
|
|||||||
return NULL;
|
return NULL;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (!lvmcache_update_vgname_and_id(info, vgname, vgid)) {
|
if (!lvmcache_update_vgname_and_id(info, vgname, vgid, vgstatus)) {
|
||||||
if (!existing) {
|
if (!existing) {
|
||||||
dm_hash_remove(_pvid_hash, pvid_s);
|
dm_hash_remove(_pvid_hash, pvid_s);
|
||||||
strcpy(info->dev->pvid, "");
|
strcpy(info->dev->pvid, "");
|
||||||
|
10
lib/cache/lvmcache.h
vendored
10
lib/cache/lvmcache.h
vendored
@ -33,15 +33,18 @@ struct cmd_context;
|
|||||||
struct format_type;
|
struct format_type;
|
||||||
struct volume_group;
|
struct volume_group;
|
||||||
|
|
||||||
|
/* One per VG */
|
||||||
struct lvmcache_vginfo {
|
struct lvmcache_vginfo {
|
||||||
struct list list; /* Join these vginfos together */
|
struct list list; /* Join these vginfos together */
|
||||||
struct list infos; /* List head for lvmcache_infos */
|
struct list infos; /* List head for lvmcache_infos */
|
||||||
const struct format_type *fmt;
|
const struct format_type *fmt;
|
||||||
char *vgname; /* "" == orphan */
|
char *vgname; /* "" == orphan */
|
||||||
|
uint32_t status;
|
||||||
char vgid[ID_LEN + 1];
|
char vgid[ID_LEN + 1];
|
||||||
char _padding[7];
|
char _padding[7];
|
||||||
};
|
};
|
||||||
|
|
||||||
|
/* One per device */
|
||||||
struct lvmcache_info {
|
struct lvmcache_info {
|
||||||
struct list list; /* Join VG members together */
|
struct list list; /* Join VG members together */
|
||||||
struct list mdas; /* list head for metadata areas */
|
struct list mdas; /* list head for metadata areas */
|
||||||
@ -64,11 +67,14 @@ int lvmcache_label_scan(struct cmd_context *cmd, int full_scan);
|
|||||||
/* Add/delete a device */
|
/* Add/delete a device */
|
||||||
struct lvmcache_info *lvmcache_add(struct labeller *labeller, const char *pvid,
|
struct lvmcache_info *lvmcache_add(struct labeller *labeller, const char *pvid,
|
||||||
struct device *dev,
|
struct device *dev,
|
||||||
const char *vgname, const char *vgid);
|
const char *vgname, const char *vgid,
|
||||||
|
uint32_t vgstatus);
|
||||||
void lvmcache_del(struct lvmcache_info *info);
|
void lvmcache_del(struct lvmcache_info *info);
|
||||||
|
|
||||||
/* Update things */
|
/* Update things */
|
||||||
int lvmcache_update_vgname_and_id(struct lvmcache_info *info, const char *vgname, const char *vgid);
|
int lvmcache_update_vgname_and_id(struct lvmcache_info *info,
|
||||||
|
const char *vgname, const char *vgid,
|
||||||
|
uint32_t vgstatus);
|
||||||
int lvmcache_update_vg(struct volume_group *vg);
|
int lvmcache_update_vg(struct volume_group *vg);
|
||||||
|
|
||||||
void lvmcache_lock_vgname(const char *vgname, int read_only);
|
void lvmcache_lock_vgname(const char *vgname, int read_only);
|
||||||
|
@ -321,12 +321,14 @@ static int _read_extents(struct disk_list *data)
|
|||||||
|
|
||||||
static void __update_lvmcache(const struct format_type *fmt,
|
static void __update_lvmcache(const struct format_type *fmt,
|
||||||
struct disk_list *dl,
|
struct disk_list *dl,
|
||||||
struct device *dev, const char *vgid)
|
struct device *dev, const char *vgid,
|
||||||
|
int exported)
|
||||||
{
|
{
|
||||||
struct lvmcache_info *info;
|
struct lvmcache_info *info;
|
||||||
|
|
||||||
if (!(info = lvmcache_add(fmt->labeller, dl->pvd.pv_uuid, dev,
|
if (!(info = lvmcache_add(fmt->labeller, dl->pvd.pv_uuid, dev,
|
||||||
dl->pvd.vg_name, vgid))) {
|
dl->pvd.vg_name, vgid,
|
||||||
|
exported ? EXPORTED_VG : 0))) {
|
||||||
stack;
|
stack;
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
@ -364,24 +366,25 @@ static struct disk_list *__read_disk(const struct format_type *fmt,
|
|||||||
if (!*dl->pvd.vg_name) {
|
if (!*dl->pvd.vg_name) {
|
||||||
log_very_verbose("%s is not a member of any format1 VG", name);
|
log_very_verbose("%s is not a member of any format1 VG", name);
|
||||||
|
|
||||||
__update_lvmcache(fmt, dl, dev, NULL);
|
__update_lvmcache(fmt, dl, dev, NULL, 0);
|
||||||
return (vg_name) ? NULL : dl;
|
return (vg_name) ? NULL : dl;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (!read_vgd(dl->dev, &dl->vgd, &dl->pvd)) {
|
if (!read_vgd(dl->dev, &dl->vgd, &dl->pvd)) {
|
||||||
log_error("Failed to read VG data from PV (%s)", name);
|
log_error("Failed to read VG data from PV (%s)", name);
|
||||||
__update_lvmcache(fmt, dl, dev, NULL);
|
__update_lvmcache(fmt, dl, dev, NULL, 0);
|
||||||
goto bad;
|
goto bad;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (vg_name && strcmp(vg_name, dl->pvd.vg_name)) {
|
if (vg_name && strcmp(vg_name, dl->pvd.vg_name)) {
|
||||||
log_very_verbose("%s is not a member of the VG %s",
|
log_very_verbose("%s is not a member of the VG %s",
|
||||||
name, vg_name);
|
name, vg_name);
|
||||||
__update_lvmcache(fmt, dl, dev, NULL);
|
__update_lvmcache(fmt, dl, dev, NULL, 0);
|
||||||
goto bad;
|
goto bad;
|
||||||
}
|
}
|
||||||
|
|
||||||
__update_lvmcache(fmt, dl, dev, dl->vgd.vg_uuid);
|
__update_lvmcache(fmt, dl, dev, dl->vgd.vg_uuid,
|
||||||
|
dl->vgd.vg_status & VG_EXPORTED);
|
||||||
|
|
||||||
if (!_read_uuids(dl)) {
|
if (!_read_uuids(dl)) {
|
||||||
log_error("Failed to read PV uuid list from %s", name);
|
log_error("Failed to read PV uuid list from %s", name);
|
||||||
|
@ -396,7 +396,7 @@ static int _pv_write(const struct format_type *fmt, struct physical_volume *pv,
|
|||||||
struct lvmcache_info *info;
|
struct lvmcache_info *info;
|
||||||
|
|
||||||
if (!(info = lvmcache_add(fmt->labeller, (char *) &pv->id, pv->dev,
|
if (!(info = lvmcache_add(fmt->labeller, (char *) &pv->id, pv->dev,
|
||||||
pv->vg_name, NULL))) {
|
pv->vg_name, NULL, 0))) {
|
||||||
stack;
|
stack;
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
@ -61,13 +61,17 @@ static int _read(struct labeller *l, struct device *dev, char *buf,
|
|||||||
struct vg_disk vgd;
|
struct vg_disk vgd;
|
||||||
struct lvmcache_info *info;
|
struct lvmcache_info *info;
|
||||||
const char *vgid = NULL;
|
const char *vgid = NULL;
|
||||||
|
int exported = 0;
|
||||||
|
|
||||||
munge_pvd(dev, pvd);
|
munge_pvd(dev, pvd);
|
||||||
|
|
||||||
if (*pvd->vg_name && read_vgd(dev, &vgd, pvd))
|
if (*pvd->vg_name && read_vgd(dev, &vgd, pvd)) {
|
||||||
vgid = vgd.vg_uuid;
|
vgid = vgd.vg_uuid;
|
||||||
|
exported = pvd->pv_status & VG_EXPORTED;
|
||||||
|
}
|
||||||
|
|
||||||
if (!(info = lvmcache_add(l, pvd->pv_uuid, dev, pvd->vg_name, vgid))) {
|
if (!(info = lvmcache_add(l, pvd->pv_uuid, dev, pvd->vg_name, vgid,
|
||||||
|
exported))) {
|
||||||
stack;
|
stack;
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
@ -98,7 +98,7 @@ int read_pool_label(struct pool_list *pl, struct labeller *l,
|
|||||||
log_debug("Calculated uuid %s for %s", uuid, pd->pl_pool_name);
|
log_debug("Calculated uuid %s for %s", uuid, pd->pl_pool_name);
|
||||||
|
|
||||||
if (!(info = lvmcache_add(l, (char *) &pvid, dev, pd->pl_pool_name,
|
if (!(info = lvmcache_add(l, (char *) &pvid, dev, pd->pl_pool_name,
|
||||||
(char *) &vgid))) {
|
(char *) &vgid, 0))) {
|
||||||
stack;
|
stack;
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
@ -219,7 +219,7 @@ static struct raw_locn *_find_vg_rlocn(struct device_area *dev_area,
|
|||||||
|
|
||||||
error:
|
error:
|
||||||
if ((info = info_from_pvid(dev_area->dev->pvid)))
|
if ((info = info_from_pvid(dev_area->dev->pvid)))
|
||||||
lvmcache_update_vgname_and_id(info, ORPHAN, NULL);
|
lvmcache_update_vgname_and_id(info, ORPHAN, NULL, 0);
|
||||||
|
|
||||||
return NULL;
|
return NULL;
|
||||||
}
|
}
|
||||||
@ -872,7 +872,8 @@ static int _scan_file(const struct format_type *fmt)
|
|||||||
}
|
}
|
||||||
|
|
||||||
const char *vgname_from_mda(const struct format_type *fmt,
|
const char *vgname_from_mda(const struct format_type *fmt,
|
||||||
struct device_area *dev_area, struct id *vgid)
|
struct device_area *dev_area, struct id *vgid,
|
||||||
|
uint32_t *vgstatus)
|
||||||
{
|
{
|
||||||
struct raw_locn *rlocn;
|
struct raw_locn *rlocn;
|
||||||
struct mda_header *mdah;
|
struct mda_header *mdah;
|
||||||
@ -907,7 +908,7 @@ const char *vgname_from_mda(const struct format_type *fmt,
|
|||||||
(off_t) (dev_area->start +
|
(off_t) (dev_area->start +
|
||||||
MDA_HEADER_SIZE),
|
MDA_HEADER_SIZE),
|
||||||
wrap, calc_crc, rlocn->checksum,
|
wrap, calc_crc, rlocn->checksum,
|
||||||
vgid)))
|
vgid, vgstatus)))
|
||||||
goto_out;
|
goto_out;
|
||||||
|
|
||||||
/* Ignore this entry if the characters aren't permissible */
|
/* Ignore this entry if the characters aren't permissible */
|
||||||
@ -937,6 +938,7 @@ static int _scan_raw(const struct format_type *fmt)
|
|||||||
struct volume_group *vg;
|
struct volume_group *vg;
|
||||||
struct format_instance fid;
|
struct format_instance fid;
|
||||||
struct id vgid;
|
struct id vgid;
|
||||||
|
uint32_t vgstatus;
|
||||||
|
|
||||||
raw_list = &((struct mda_lists *) fmt->private)->raws;
|
raw_list = &((struct mda_lists *) fmt->private)->raws;
|
||||||
|
|
||||||
@ -945,7 +947,7 @@ static int _scan_raw(const struct format_type *fmt)
|
|||||||
|
|
||||||
list_iterate_items(rl, raw_list) {
|
list_iterate_items(rl, raw_list) {
|
||||||
/* FIXME We're reading mdah twice here... */
|
/* FIXME We're reading mdah twice here... */
|
||||||
if ((vgname = vgname_from_mda(fmt, &rl->dev_area, &vgid))) {
|
if ((vgname = vgname_from_mda(fmt, &rl->dev_area, &vgid, &vgstatus))) {
|
||||||
if ((vg = _vg_read_raw_area(&fid, vgname,
|
if ((vg = _vg_read_raw_area(&fid, vgname,
|
||||||
&rl->dev_area, 0)))
|
&rl->dev_area, 0)))
|
||||||
lvmcache_update_vg(vg);
|
lvmcache_update_vg(vg);
|
||||||
@ -1115,7 +1117,7 @@ static int _pv_write(const struct format_type *fmt, struct physical_volume *pv,
|
|||||||
/* FIXME Test mode don't update cache? */
|
/* FIXME Test mode don't update cache? */
|
||||||
|
|
||||||
if (!(info = lvmcache_add(fmt->labeller, (char *) &pv->id, pv->dev,
|
if (!(info = lvmcache_add(fmt->labeller, (char *) &pv->id, pv->dev,
|
||||||
ORPHAN, NULL))) {
|
ORPHAN, NULL, 0))) {
|
||||||
stack;
|
stack;
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
@ -55,6 +55,7 @@ int add_mda(const struct format_type *fmt, struct dm_pool *mem, struct list *mda
|
|||||||
void del_mdas(struct list *mdas);
|
void del_mdas(struct list *mdas);
|
||||||
|
|
||||||
const char *vgname_from_mda(const struct format_type *fmt,
|
const char *vgname_from_mda(const struct format_type *fmt,
|
||||||
struct device_area *dev_area, struct id *vgid);
|
struct device_area *dev_area, struct id *vgid,
|
||||||
|
uint32_t *vgstatus);
|
||||||
|
|
||||||
#endif
|
#endif
|
||||||
|
@ -49,7 +49,7 @@ struct text_vg_version_ops {
|
|||||||
time_t *when, char **desc);
|
time_t *when, char **desc);
|
||||||
const char *(*read_vgname) (const struct format_type *fmt,
|
const char *(*read_vgname) (const struct format_type *fmt,
|
||||||
struct config_tree *cft,
|
struct config_tree *cft,
|
||||||
struct id *vgid);
|
struct id *vgid, uint32_t *vgstatus);
|
||||||
};
|
};
|
||||||
|
|
||||||
struct text_vg_version_ops *text_vg_vsn1_init(void);
|
struct text_vg_version_ops *text_vg_vsn1_init(void);
|
||||||
@ -78,6 +78,6 @@ const char *text_vgname_import(const struct format_type *fmt,
|
|||||||
off_t offset, uint32_t size,
|
off_t offset, uint32_t size,
|
||||||
off_t offset2, uint32_t size2,
|
off_t offset2, uint32_t size2,
|
||||||
checksum_fn_t checksum_fn, uint32_t checksum,
|
checksum_fn_t checksum_fn, uint32_t checksum,
|
||||||
struct id *vgid);
|
struct id *vgid, uint32_t *vgstatus);
|
||||||
|
|
||||||
#endif
|
#endif
|
||||||
|
@ -28,7 +28,7 @@ const char *text_vgname_import(const struct format_type *fmt,
|
|||||||
off_t offset, uint32_t size,
|
off_t offset, uint32_t size,
|
||||||
off_t offset2, uint32_t size2,
|
off_t offset2, uint32_t size2,
|
||||||
checksum_fn_t checksum_fn, uint32_t checksum,
|
checksum_fn_t checksum_fn, uint32_t checksum,
|
||||||
struct id *vgid)
|
struct id *vgid, uint32_t *vgstatus)
|
||||||
{
|
{
|
||||||
struct config_tree *cft;
|
struct config_tree *cft;
|
||||||
struct text_vg_version_ops **vsn;
|
struct text_vg_version_ops **vsn;
|
||||||
@ -57,7 +57,7 @@ const char *text_vgname_import(const struct format_type *fmt,
|
|||||||
if (!(*vsn)->check_version(cft))
|
if (!(*vsn)->check_version(cft))
|
||||||
continue;
|
continue;
|
||||||
|
|
||||||
if (!(vgname = (*vsn)->read_vgname(fmt, cft, vgid)))
|
if (!(vgname = (*vsn)->read_vgname(fmt, cft, vgid, vgstatus)))
|
||||||
goto_out;
|
goto_out;
|
||||||
|
|
||||||
break;
|
break;
|
||||||
|
@ -799,9 +799,10 @@ static void _read_desc(struct dm_pool *mem,
|
|||||||
}
|
}
|
||||||
|
|
||||||
static const char *_read_vgname(const struct format_type *fmt,
|
static const char *_read_vgname(const struct format_type *fmt,
|
||||||
struct config_tree *cft, struct id *vgid)
|
struct config_tree *cft, struct id *vgid,
|
||||||
|
uint32_t *vgstatus)
|
||||||
{
|
{
|
||||||
struct config_node *vgn;
|
struct config_node *vgn, *cn;
|
||||||
struct dm_pool *mem = fmt->cmd->mem;
|
struct dm_pool *mem = fmt->cmd->mem;
|
||||||
char *vgname;
|
char *vgname;
|
||||||
|
|
||||||
@ -823,6 +824,18 @@ static const char *_read_vgname(const struct format_type *fmt,
|
|||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (!(cn = find_config_node(vgn, "status"))) {
|
||||||
|
log_error("Couldn't find status flags for volume group %s.",
|
||||||
|
vgname);
|
||||||
|
return 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
if (!(read_flags(vgstatus, VG_FLAGS, cn->v))) {
|
||||||
|
log_error("Couldn't read status flags for volume group %s.",
|
||||||
|
vgname);
|
||||||
|
return 0;
|
||||||
|
}
|
||||||
|
|
||||||
return vgname;
|
return vgname;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -198,10 +198,11 @@ static int _read(struct labeller *l, struct device *dev, char *buf,
|
|||||||
struct id vgid;
|
struct id vgid;
|
||||||
struct mda_context *mdac;
|
struct mda_context *mdac;
|
||||||
const char *vgname;
|
const char *vgname;
|
||||||
|
uint32_t vgstatus;
|
||||||
|
|
||||||
pvhdr = (struct pv_header *) ((void *) buf + xlate32(lh->offset_xl));
|
pvhdr = (struct pv_header *) ((void *) buf + xlate32(lh->offset_xl));
|
||||||
|
|
||||||
if (!(info = lvmcache_add(l, pvhdr->pv_uuid, dev, NULL, NULL)))
|
if (!(info = lvmcache_add(l, pvhdr->pv_uuid, dev, NULL, NULL, 0)))
|
||||||
return_0;
|
return_0;
|
||||||
*label = info->label;
|
*label = info->label;
|
||||||
|
|
||||||
@ -234,8 +235,9 @@ static int _read(struct labeller *l, struct device *dev, char *buf,
|
|||||||
list_iterate_items(mda, &info->mdas) {
|
list_iterate_items(mda, &info->mdas) {
|
||||||
mdac = (struct mda_context *) mda->metadata_locn;
|
mdac = (struct mda_context *) mda->metadata_locn;
|
||||||
if ((vgname = vgname_from_mda(info->fmt, &mdac->area,
|
if ((vgname = vgname_from_mda(info->fmt, &mdac->area,
|
||||||
&vgid)) &&
|
&vgid, &vgstatus)) &&
|
||||||
!lvmcache_update_vgname_and_id(info, vgname, (char *) &vgid))
|
!lvmcache_update_vgname_and_id(info, vgname,
|
||||||
|
(char *) &vgid, vgstatus))
|
||||||
return_0;
|
return_0;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -175,7 +175,7 @@ static struct labeller *_find_labeller(struct device *dev, char *buf,
|
|||||||
out:
|
out:
|
||||||
if (!found) {
|
if (!found) {
|
||||||
if ((info = info_from_pvid(dev->pvid)))
|
if ((info = info_from_pvid(dev->pvid)))
|
||||||
lvmcache_update_vgname_and_id(info, ORPHAN, NULL);
|
lvmcache_update_vgname_and_id(info, ORPHAN, NULL, 0);
|
||||||
log_very_verbose("%s: No label detected", dev_name(dev));
|
log_very_verbose("%s: No label detected", dev_name(dev));
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -267,7 +267,7 @@ int label_read(struct device *dev, struct label **result)
|
|||||||
stack;
|
stack;
|
||||||
|
|
||||||
if ((info = info_from_pvid(dev->pvid)))
|
if ((info = info_from_pvid(dev->pvid)))
|
||||||
lvmcache_update_vgname_and_id(info, ORPHAN, NULL);
|
lvmcache_update_vgname_and_id(info, ORPHAN, NULL, 0);
|
||||||
|
|
||||||
goto out;
|
goto out;
|
||||||
}
|
}
|
||||||
@ -348,7 +348,7 @@ int label_verify(struct device *dev)
|
|||||||
stack;
|
stack;
|
||||||
|
|
||||||
if ((info = info_from_pvid(dev->pvid)))
|
if ((info = info_from_pvid(dev->pvid)))
|
||||||
lvmcache_update_vgname_and_id(info, ORPHAN, NULL);
|
lvmcache_update_vgname_and_id(info, ORPHAN, NULL, 0);
|
||||||
|
|
||||||
goto out;
|
goto out;
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user