[linux-lvm] Problem using lvreduce

Goetz Bock bock at blacknet.de
Fri Aug 17 13:05:40 UTC 2001


On Fri, Aug 17 '01 at 11:43, Joe Thornber wrote:
> > --- pv_release_pe.c.old Thu Aug 16 09:23:35 2001
> > +++ pv_release_pe.c     Wed Aug 15 09:09:06 2001
> > @@ -85,7 +85,7 @@
> >           }
> >           pe_index = ( vg->lv[l]->lv_current_pe[p].pe - 
> >                        LVM_VGDA_SIZE ( vg->pv[pv_num]) / SECTOR_SIZE) /
> > -                      vg->pe_size;
> > +                      vg->pe_size - 1;
> >           debug ( "pv_release_pe -- pv_name: %s  pe: %lu  sector: %lu\n",
> >                    vg->pv[pv_num]->pv_name,
> >                    pe_index,
> 
> This patch looks wrong, I cant see why anyone would want to divide by
> pe_size - 1, if it's working it's by accident.
Disclamer: I did not lok at the code, and don't know what IŠm talking
           about ...

But, what this patch does, is devide by pe_size and substract 1 from the
result.
-- 
Goetz Bock                                              IT Consultant
Dipl.-Inf. Univ.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 232 bytes
Desc: not available
URL: <http://listman.redhat.com/archives/linux-lvm/attachments/20010817/1e35f146/attachment.sig>


More information about the linux-lvm mailing list