Re: [Qemu-devel] [PATCH 3/8] iscsi: add bdrv_co_write_zeroes

2013-06-24 Thread Peter Lieven
Am 24.06.2013 16:34, schrieb Paolo Bonzini: > Il 22/06/2013 22:58, Peter Lieven ha scritto: >> write zeroes is emulated by unmap if the >> target supports unmapping an unmapped blocks >> read as zero. > I think you should check BDRV_O_UNMAP in bs->open_flags, and not do this > optimization if it is

Re: [Qemu-devel] [PATCH 3/8] iscsi: add bdrv_co_write_zeroes

2013-06-24 Thread Paolo Bonzini
Il 22/06/2013 22:58, Peter Lieven ha scritto: > write zeroes is emulated by unmap if the > target supports unmapping an unmapped blocks > read as zero. I think you should check BDRV_O_UNMAP in bs->open_flags, and not do this optimization if it is not set. Paolo > Signed-off-by: Peter Lieven > -

[Qemu-devel] [PATCH 3/8] iscsi: add bdrv_co_write_zeroes

2013-06-22 Thread Peter Lieven
write zeroes is emulated by unmap if the target supports unmapping an unmapped blocks read as zero. Signed-off-by: Peter Lieven --- block/iscsi.c | 63 + 1 file changed, 63 insertions(+) diff --git a/block/iscsi.c b/block/iscsi.c index 9