mirror of
git://sourceware.org/git/lvm2.git
synced 2025-03-08 08:58:50 +03:00
Cope with missing format1 PVs again.
This commit is contained in:
parent
7f2def9e6d
commit
17ae61cce5
@ -1,5 +1,6 @@
|
|||||||
Version 2.01.11 -
|
Version 2.01.11 -
|
||||||
==============================
|
==============================
|
||||||
|
Cope with missing format1 PVs again.
|
||||||
Remove lists of free PV segments.
|
Remove lists of free PV segments.
|
||||||
Simplify pv_maps code and remove slow bitset algorithm.
|
Simplify pv_maps code and remove slow bitset algorithm.
|
||||||
Red-Hat-ify the clvmd rhel4 initscript.
|
Red-Hat-ify the clvmd rhel4 initscript.
|
||||||
|
@ -131,6 +131,11 @@ int pv_split_segment(struct physical_volume *pv, uint32_t pe)
|
|||||||
return 1;
|
return 1;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
static struct pv_segment null_pv_segment = {
|
||||||
|
pv: NULL,
|
||||||
|
pe: 0
|
||||||
|
};
|
||||||
|
|
||||||
struct pv_segment *assign_peg_to_lvseg(struct physical_volume *pv,
|
struct pv_segment *assign_peg_to_lvseg(struct physical_volume *pv,
|
||||||
uint32_t pe, uint32_t area_len,
|
uint32_t pe, uint32_t area_len,
|
||||||
struct lv_segment *seg,
|
struct lv_segment *seg,
|
||||||
@ -138,6 +143,10 @@ struct pv_segment *assign_peg_to_lvseg(struct physical_volume *pv,
|
|||||||
{
|
{
|
||||||
struct pv_segment *peg;
|
struct pv_segment *peg;
|
||||||
|
|
||||||
|
/* Missing format1 PV */
|
||||||
|
if (!pv)
|
||||||
|
return &null_pv_segment;
|
||||||
|
|
||||||
if (!pv_split_segment(pv, pe) ||
|
if (!pv_split_segment(pv, pe) ||
|
||||||
!pv_split_segment(pv, pe + area_len)) {
|
!pv_split_segment(pv, pe + area_len)) {
|
||||||
stack;
|
stack;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user