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

Cope with missing format1 PVs again.

This commit is contained in:
Alasdair Kergon 2005-05-11 15:04:06 +00:00
parent 7f2def9e6d
commit 17ae61cce5
2 changed files with 10 additions and 0 deletions

View File

@ -1,5 +1,6 @@
Version 2.01.11 -
==============================
Cope with missing format1 PVs again.
Remove lists of free PV segments.
Simplify pv_maps code and remove slow bitset algorithm.
Red-Hat-ify the clvmd rhel4 initscript.

View File

@ -131,6 +131,11 @@ int pv_split_segment(struct physical_volume *pv, uint32_t pe)
return 1;
}
static struct pv_segment null_pv_segment = {
pv: NULL,
pe: 0
};
struct pv_segment *assign_peg_to_lvseg(struct physical_volume *pv,
uint32_t pe, uint32_t area_len,
struct lv_segment *seg,
@ -138,6 +143,10 @@ struct pv_segment *assign_peg_to_lvseg(struct physical_volume *pv,
{
struct pv_segment *peg;
/* Missing format1 PV */
if (!pv)
return &null_pv_segment;
if (!pv_split_segment(pv, pe) ||
!pv_split_segment(pv, pe + area_len)) {
stack;