mirror of
git://sourceware.org/git/lvm2.git
synced 2025-01-21 22:04:19 +03:00
writecache: fix lv_on_pmem
dev_is_pmem on pv->dev requires a pv segment or it could segfault. (cherry picked from commit 247f69f9aafe731ef85268da1e6ce817295b265d)
This commit is contained in:
parent
5d195b2041
commit
4d5f3207fd
@ -4402,6 +4402,9 @@ int lv_on_pmem(struct logical_volume *lv)
|
||||
|
||||
dm_list_iterate_items(seg, &lv->segments) {
|
||||
for (s = 0; s < seg->area_count; s++) {
|
||||
if (seg_type(seg, s) != AREA_PV)
|
||||
continue;
|
||||
|
||||
pv = seg_pv(seg, s);
|
||||
|
||||
if (dev_is_pmem(lv->vg->cmd->dev_types, pv->dev)) {
|
||||
|
Loading…
x
Reference in New Issue
Block a user