Re: [Qemu-devel] [PATCHv3 1.8 7/9] qemu-img: round down request length to an aligned sector

2013-12-05 Thread Stefan Hajnoczi
On Wed, Dec 04, 2013 at 04:56:19PM +0100, Peter Lieven wrote: > Am 04.12.2013 16:49, schrieb Stefan Hajnoczi: > > On Wed, Nov 27, 2013 at 11:07:07AM +0100, Peter Lieven wrote: > >> @@ -1397,19 +1396,21 @@ static int img_convert(int argc, char **argv) > >> } > >> } > >> > >> +clu

Re: [Qemu-devel] [PATCHv3 1.8 7/9] qemu-img: round down request length to an aligned sector

2013-12-04 Thread Peter Lieven
Am 04.12.2013 16:49, schrieb Stefan Hajnoczi: > On Wed, Nov 27, 2013 at 11:07:07AM +0100, Peter Lieven wrote: >> @@ -1397,19 +1396,21 @@ static int img_convert(int argc, char **argv) >> } >> } >> >> +cluster_sectors = 0; >> +ret = bdrv_get_info(out_bs, &bdi); >> +if (ret

Re: [Qemu-devel] [PATCHv3 1.8 7/9] qemu-img: round down request length to an aligned sector

2013-12-04 Thread Stefan Hajnoczi
On Wed, Nov 27, 2013 at 11:07:07AM +0100, Peter Lieven wrote: > @@ -1397,19 +1396,21 @@ static int img_convert(int argc, char **argv) > } > } > > +cluster_sectors = 0; > +ret = bdrv_get_info(out_bs, &bdi); > +if (ret < 0 && compress) { > +error_report("could not

[Qemu-devel] [PATCHv3 1.8 7/9] qemu-img: round down request length to an aligned sector

2013-11-27 Thread Peter Lieven
this patch shortens requests to end at an aligned sector so that the next request starts aligned. Reviewed-by: Paolo Bonzini Signed-off-by: Peter Lieven --- qemu-img.c | 34 -- 1 file changed, 24 insertions(+), 10 deletions(-) diff --git a/qemu-img.c b/qemu-im