Re: [Qemu-devel] [PATCH] rtl8139: flush queued packets when RxBufPtr is written

2013-05-27 Thread Peter Lieven
Hi all, I ocassionally have seen a probably related problem in the past. It mainly happend with rtl8139 under WinXP where we most likely use rtl8139 due to lack of shipped e1000 drivers. My question is if you see increasing dropped packets on the tap device if this problem occurs? tap36

Re: [Qemu-devel] [PATCH] rtl8139: flush queued packets when RxBufPtr is written

2013-05-27 Thread Peter Lieven
On 27.05.2013 10:32, Stefan Hajnoczi wrote: On Mon, May 27, 2013 at 08:15:42AM +0200, Peter Lieven wrote: I ocassionally have seen a probably related problem in the past. It mainly happend with rtl8139 under WinXP where we most likely use rtl8139 due to lack of shipped e1000 drivers. My

Re: [Qemu-devel] [PATCH] rtl8139: flush queued packets when RxBufPtr is written

2013-05-27 Thread Peter Lieven
On 27.05.2013 16:07, Oliver Francke wrote: Well, Am 27.05.2013 um 08:15 schrieb Peter Lieven lieven-li...@dlhnet.de: Hi all, I ocassionally have seen a probably related problem in the past. It mainly happend with rtl8139 under WinXP where we most likely use rtl8139 due to lack of shipped

Re: [Qemu-devel] [PATCH] rtl8139: flush queued packets when RxBufPtr is written

2013-05-28 Thread Peter Lieven
On 27.05.2013 17:29, Stefan Hajnoczi wrote: On Mon, May 27, 2013 at 04:24:59PM +0200, Peter Lieven wrote: On 27.05.2013 16:07, Oliver Francke wrote: Well, Am 27.05.2013 um 08:15 schrieb Peter Lieven lieven-li...@dlhnet.de: Hi all, I ocassionally have seen a probably related problem

Re: [Qemu-devel] broken incoming migration

2013-05-30 Thread Peter Lieven
Am 30.05.2013 10:18, schrieb Alexey Kardashevskiy: On 05/30/2013 05:49 PM, Paolo Bonzini wrote: Il 30/05/2013 09:44, Alexey Kardashevskiy ha scritto: Hi! I found the migration broken on pseries platform, specifically, this patch broke it: f1c72795af573b24a7da5eb52375c9aba8a37972

Re: [Qemu-devel] broken incoming migration

2013-05-30 Thread Peter Lieven
Am 30.05.2013 um 15:41 schrieb Paolo Bonzini pbonz...@redhat.com: Il 30/05/2013 11:08, Peter Lieven ha scritto: Am 30.05.2013 10:18, schrieb Alexey Kardashevskiy: On 05/30/2013 05:49 PM, Paolo Bonzini wrote: Il 30/05/2013 09:44, Alexey Kardashevskiy ha scritto: Hi! I found

Re: [Qemu-devel] broken incoming migration

2013-06-04 Thread Peter Lieven
On 03.06.2013 12:04, Alexey Kardashevskiy wrote: On 05/31/2013 12:38 AM, Peter Lieven wrote: Am 30.05.2013 um 15:41 schrieb Paolo Bonzini pbonz...@redhat.com: Il 30/05/2013 11:08, Peter Lieven ha scritto: Am 30.05.2013 10:18, schrieb Alexey Kardashevskiy: On 05/30/2013 05:49 PM, Paolo

Re: [Qemu-devel] broken incoming migration

2013-06-04 Thread Peter Lieven
On 30.05.2013 16:41, Paolo Bonzini wrote: Il 30/05/2013 16:38, Peter Lieven ha scritto: You could also scan the page for nonzero values before writing it. i had this in mind, but then choosed the other approach turned out to be a bad idea. alexey: i will prepare a patch later today

Re: [Qemu-devel] broken incoming migration

2013-06-04 Thread Peter Lieven
On 04.06.2013 16:14, Paolo Bonzini wrote: Il 04/06/2013 15:52, Peter Lieven ha scritto: On 30.05.2013 16:41, Paolo Bonzini wrote: Il 30/05/2013 16:38, Peter Lieven ha scritto: You could also scan the page for nonzero values before writing it. i had this in mind, but then choosed the other

Re: [Qemu-devel] broken incoming migration

2013-06-04 Thread Peter Lieven
On 04.06.2013 16:40, Paolo Bonzini wrote: Il 04/06/2013 16:38, Peter Lieven ha scritto: On 04.06.2013 16:14, Paolo Bonzini wrote: Il 04/06/2013 15:52, Peter Lieven ha scritto: On 30.05.2013 16:41, Paolo Bonzini wrote: Il 30/05/2013 16:38, Peter Lieven ha scritto: You could also scan

Re: [Qemu-devel] broken incoming migration

2013-06-04 Thread Peter Lieven
On 04.06.2013 16:40, Paolo Bonzini wrote: Il 04/06/2013 16:38, Peter Lieven ha scritto: On 04.06.2013 16:14, Paolo Bonzini wrote: Il 04/06/2013 15:52, Peter Lieven ha scritto: On 30.05.2013 16:41, Paolo Bonzini wrote: Il 30/05/2013 16:38, Peter Lieven ha scritto: You could also scan

Re: [Qemu-devel] broken incoming migration

2013-06-04 Thread Peter Lieven
Am 04.06.2013 um 17:17 schrieb Paolo Bonzini pbonz...@redhat.com: Il 04/06/2013 16:48, Peter Lieven ha scritto: Still using 3.2, but strange enough the above example is also not increasing RSS size for me. Can you try the following: qemu git master with 1G of memory (hanging in bios

Re: [Qemu-devel] broken incoming migration

2013-06-05 Thread Peter Lieven
Am 05.06.2013 um 05:37 schrieb Alexey Kardashevskiy a...@ozlabs.ru: On 06/05/2013 05:15 AM, Peter Lieven wrote: Am 04.06.2013 um 17:17 schrieb Paolo Bonzini pbonz...@redhat.com: Il 04/06/2013 16:48, Peter Lieven ha scritto: Still using 3.2, but strange enough the above example is also

[Qemu-devel] [PATCH 0/2] fix migration of zero pages

2013-06-06 Thread Peter Lieven
that does not (over)write zero pages at the destination. Peter Lieven (2): Revert migration: do not sent zero pages in bulk stage migration: do not overwrite zero pages arch_init.c | 38 -- hmp.c |2 -- include

[Qemu-devel] [PATCH 1/2] Revert migration: do not sent zero pages in bulk stage

2013-06-06 Thread Peter Lieven
f1c72795af573b24a7da5eb52375c9aba8a37972. Conflicts: arch_init.c qmp-commands.hx Signed-off-by: Peter Lieven p...@kamp.de --- arch_init.c | 24 hmp.c |2 -- include/migration/migration.h |2 -- migration.c

[Qemu-devel] [PATCH 2/2] migration: do not overwrite zero pages

2013-06-06 Thread Peter Lieven
on incoming migration do not memset pages to zero if they already read as zero. this will allocate a new zero page and consume memory unnecessarily. even if we madvise a MADV_DONTNEED later this will only deallocate the memory asynchronously. Signed-off-by: Peter Lieven p...@kamp.de

Re: [Qemu-devel] [PATCH 1/2] Revert migration: do not sent zero pages in bulk stage

2013-06-06 Thread Peter Lieven
On 06.06.2013 14:16, Eric Blake wrote: - Original Message - Not sending zero pages breaks migration if a page is zero at the source but not at the destination. This can e.g. happen if different BIOS versions are used at source and destination. It has also been reported that migration on

Re: [Qemu-devel] broken incoming migration

2013-06-09 Thread Peter Lieven
windows guests or linux with page sanitization. In these cases freed Memory is zeroed. Peter Thanks On Wed, Jun 5, 2013 at 2:09 PM, Peter Lieven p...@kamp.de wrote: Am 05.06.2013 um 05:37 schrieb Alexey Kardashevskiy a...@ozlabs.ru: On 06/05/2013 05:15 AM, Peter Lieven wrote: Am

Re: [Qemu-devel] broken incoming migration

2013-06-09 Thread Peter Lieven
: On 04.06.2013 16:40, Paolo Bonzini wrote: Il 04/06/2013 16:38, Peter Lieven ha scritto: On 04.06.2013 16:14, Paolo Bonzini wrote: Il 04/06/2013 15:52, Peter Lieven ha scritto: On 30.05.2013 16:41, Paolo Bonzini wrote: Il 30/05/2013 16:38, Peter Lieven ha scritto: You could also scan the page

Re: [Qemu-devel] broken incoming migration

2013-06-10 Thread Peter Lieven
On 10.06.2013 08:39, Alexey Kardashevskiy wrote: On 06/09/2013 05:27 PM, Peter Lieven wrote: Am 09.06.2013 um 05:09 schrieb Alexey Kardashevskiy a...@ozlabs.ru: On 06/09/2013 01:01 PM, Wenchao Xia wrote: 于 2013-6-9 10:34, Alexey Kardashevskiy 写道: On 06/09/2013 12:16 PM, Wenchao Xia wrote

[Qemu-devel] [PATCH] migration: ensure memory is zeroized at the destination

2013-06-10 Thread Peter Lieven
of all architectures to indicate that the machine is a migration target and then avoid copying ram images etc. to physical ram in this case. but this would require a lot of code to be changed and reviewed. Signed-off-by: Peter Lieven p...@kamp.de --- arch_init.c | 10 ++ 1 file changed

Re: [Qemu-devel] broken incoming migration

2013-06-10 Thread Peter Lieven
On 10.06.2013 08:55, Alexey Kardashevskiy wrote: On 06/10/2013 04:50 PM, Peter Lieven wrote: On 10.06.2013 08:39, Alexey Kardashevskiy wrote: On 06/09/2013 05:27 PM, Peter Lieven wrote: Am 09.06.2013 um 05:09 schrieb Alexey Kardashevskiy a...@ozlabs.ru: On 06/09/2013 01:01 PM, Wenchao Xia

Re: [Qemu-devel] [Qemu-ppc] broken incoming migration

2013-06-10 Thread Peter Lieven
On 10.06.2013 11:33, Benjamin Herrenschmidt wrote: On Mon, 2013-06-10 at 19:10 +1000, Alexey Kardashevskiy wrote: I would prefer not to completely drop the patch since it saves bandwidth and resources. I would like migration to do what it should do - send pages no matter what, this is exactly

Re: [Qemu-devel] [PATCH] migration: ensure memory is zeroized at the destination

2013-06-10 Thread Peter Lieven
please ignore this one. Peter On 10.06.2013 09:03, Peter Lieven wrote: migration relies on the target memory to be zeroed out since commit f1c72795 (migration: do not sent zero pages in bulk stage). however, there is a subtle case where this breaks migration. if for some reason a page is zero

[Qemu-devel] [PATCHv2 2/2] migration: do not overwrite zero pages

2013-06-10 Thread Peter Lieven
on incoming migration do not memset pages to zero if they already read as zero. this will allocate a new zero page and consume memory unnecessarily. even if we madvise a MADV_DONTNEED later this will only deallocate the memory asynchronously. Signed-off-by: Peter Lieven p...@kamp.de

[Qemu-devel] [PATCHv2 0/2] fix migration of zero pages

2013-06-10 Thread Peter Lieven
that does not (over)write zero pages at the destination. v2: - keep skipped pages fields in monitoring and qmp intact to avoid compatiblity issues. Peter Lieven (2): Revert migration: do not sent zero pages in bulk stage migration: do not overwrite zero pages arch_init.c | 27

[Qemu-devel] [PATCHv2 1/2] Revert migration: do not sent zero pages in bulk stage

2013-06-10 Thread Peter Lieven
reverts commit f1c72795af573b24a7da5eb52375c9aba8a37972. Conflicts: arch_init.c Signed-off-by: Peter Lieven p...@kamp.de --- arch_init.c | 13 - 1 file changed, 4 insertions(+), 9 deletions(-) diff --git a/arch_init.c b/arch_init.c index 5d32ecf..08fccf6 100644 --- a/arch_init.c

Re: [Qemu-devel] [PATCHv2 2/2] migration: do not overwrite zero pages

2013-06-10 Thread Peter Lieven
Am 10.06.2013 um 18:10 schrieb mdroth mdr...@linux.vnet.ibm.com: On Mon, Jun 10, 2013 at 12:14:20PM +0200, Peter Lieven wrote: on incoming migration do not memset pages to zero if they already read as zero. this will allocate a new zero page and consume memory unnecessarily. even if we

Re: [Qemu-devel] [PULL 08/11] iscsi: add .bdrv_get_block_status

2013-10-02 Thread Peter Lieven
Am 19.09.2013 15:46, schrieb Paolo Bonzini: Il 19/09/2013 09:24, Peter Lieven ha scritto: do we still need this patch? if yes I can sent one shortly. No, Stefan prepared it. I'll send a pull request shortly. The patch disables iscsi_get_block_status completely. The C preprocessor can't check

[Qemu-devel] [PATCH] block/iscsi: reenable iscsi_co_get_block_status

2013-10-02 Thread Peter Lieven
support was added to libiscsi. Signed-off-by: Peter Lieven p...@kamp.de --- block/iscsi.c |6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/block/iscsi.c b/block/iscsi.c index 6152ef1..a2a961e 100644 --- a/block/iscsi.c +++ b/block/iscsi.c @@ -811,7 +811,7

[Qemu-devel] [PATCHv4] block/get_block_status: avoid redundant callouts on raw devices

2013-10-02 Thread Peter Lieven
. Signed-off-by: Peter Lieven p...@kamp.de --- block.c |4 ++-- block/raw_bsd.c |6 +- include/block/block.h |3 +++ 3 files changed, 10 insertions(+), 3 deletions(-) diff --git a/block.c b/block.c index 93e113a..7fa2e43 100644 --- a/block.c +++ b/block.c

Re: [Qemu-devel] [PATCHv4] block/get_block_status: avoid redundant callouts on raw devices

2013-10-02 Thread Peter Lieven
Am 02.10.2013 17:13, schrieb Paolo Bonzini: Il 02/10/2013 17:06, Stefan Hajnoczi ha scritto: Sorry I didn't review this earlier but this flag looks hacky and I'm not confident about merging the patch yet. The patch makes me wonder if the raw_bsd driver should avoid calling bs-file itself:

[Qemu-devel] [PATCH] block/iscsi: introduce bdrv_co_{readv, writev, flush_to_disk}

2013-10-02 Thread Peter Lieven
this converts read, write and flush functions from aio to coroutines. Signed-off-by: Peter Lieven p...@kamp.de --- block/iscsi.c | 405 +++-- 1 file changed, 107 insertions(+), 298 deletions(-) diff --git a/block/iscsi.c b/block/iscsi.c index

Re: [Qemu-devel] [PATCH] block/iscsi: introduce bdrv_co_{readv, writev, flush_to_disk}

2013-10-02 Thread Peter Lieven
Am 02.10.2013 17:46, schrieb Paolo Bonzini: Il 02/10/2013 17:41, Peter Lieven ha scritto: this converts read, write and flush functions from aio to coroutines. I'm not sure it's already the time for this... Cancellation sucks in QEMU, and this is going to make things even worse. Ok, I

Re: [Qemu-devel] [PATCH] block/iscsi: introduce bdrv_co_{readv, writev, flush_to_disk}

2013-10-02 Thread Peter Lieven
Am 02.10.2013 17:55, schrieb Paolo Bonzini: Il 02/10/2013 17:54, Peter Lieven ha scritto: I'm not sure it's already the time for this... Cancellation sucks in QEMU, and this is going to make things even worse. Ok, I was not aware. I talked with Kevin about this some months ago and promised

Re: [Qemu-devel] [PATCHv4] block/get_block_status: avoid redundant callouts on raw devices

2013-10-02 Thread Peter Lieven
Am 02.10.2013 17:13, schrieb Paolo Bonzini: Il 02/10/2013 17:06, Stefan Hajnoczi ha scritto: Sorry I didn't review this earlier but this flag looks hacky and I'm not confident about merging the patch yet. The patch makes me wonder if the raw_bsd driver should avoid calling bs-file itself:

[Qemu-devel] [PATCHv5] block/get_block_status: avoid redundant callouts on raw devices

2013-10-07 Thread Peter Lieven
if a raw device like an iscsi target or host device is used the current implementation makes a second call out to get the block status of bs-file. Signed-off-by: Peter Lieven p...@kamp.de --- v5: add a generic get_lba_status function in the raw driver which adds the BDRV_BLOCK_RAW flag

Re: [Qemu-devel] [Bug 1100843] Re: Live Migration Causes Performance Issues

2013-10-07 Thread Peter Lieven
On 06.10.2013 15:57, Zhang Haoyu wrote: From my testing this has been fixed in the saucy version (1.5.0) of qemu. It is fixed by this patch: f1c72795af573b24a7da5eb52375c9aba8a37972 However later in the history this commit was reverted, and again broke this. The other commit that fixes this

Re: [Qemu-devel] [PATCHv3 08/20] block: honour BlockLimits in bdrv_co_discard

2013-10-07 Thread Peter Lieven
Am 07.10.2013 um 10:29 schrieb Stefan Hajnoczi stefa...@gmail.com: On Tue, Sep 24, 2013 at 03:35:02PM +0200, Peter Lieven wrote: @@ -4245,7 +4250,37 @@ int coroutine_fn bdrv_co_discard(BlockDriverState *bs, int64_t sector_num, } if (bs-drv-bdrv_co_discard) { -return bs

Re: [Qemu-devel] [PATCHv3 13/20] block: introduce bdrv_zeroize

2013-10-07 Thread Peter Lieven
Am 07.10.2013 um 10:34 schrieb Stefan Hajnoczi stefa...@gmail.com: On Tue, Sep 24, 2013 at 03:35:07PM +0200, Peter Lieven wrote: this patch adds a call to completely zero out a block device. the operation is sped up by checking the block status and only writing zeroes to the device

Re: [Qemu-devel] [PATCHv3 20/20] block/raw: copy BlockLimits on raw_open

2013-10-07 Thread Peter Lieven
Am 07.10.2013 um 10:38 schrieb Stefan Hajnoczi stefa...@gmail.com: On Wed, Oct 02, 2013 at 11:11:05AM -0600, Eric Blake wrote: On 09/24/2013 07:35 AM, Peter Lieven wrote: Signed-off-by: Peter Lieven p...@kamp.de --- block/raw_bsd.c |1 + 1 file changed, 1 insertion(+) diff --git

Re: [Qemu-devel] [PATCHv3 00/20] block: logical block provisioning enhancements

2013-10-07 Thread Peter Lieven
Am 07.10.2013 um 10:42 schrieb Stefan Hajnoczi stefa...@gmail.com: On Tue, Sep 24, 2013 at 03:34:54PM +0200, Peter Lieven wrote: this patch adds the ability for targets to stay sparse during block migration (if the zero_blocks capability is set) and qemu-img convert even if the target does

Re: [Qemu-devel] [PATCH 8/9] arch_init: make is_zero_page accept size

2013-10-07 Thread Peter Lieven
On 24.09.2013 14:03, Juan Quintela wrote: From: Isaku Yamahata yamah...@private.email.ne.jp Later is_zero_page will be used for non TARGET_PAGE_SIZE range. And rename it to is_zero_range as it isn't page size any more. Signed-off-by: Isaku Yamahata yamah...@private.email.ne.jp Signed-off-by:

[Qemu-devel] [PATCH] migration: drop MADVISE_DONT_NEED for incoming zero pages

2013-10-07 Thread Peter Lieven
and changed to zero during migration) drop it completely. Signed-off-by: Peter Lieven p...@kamp.de Reported-By: Zhang Haoyu haoyu.zh...@huawei.com --- arch_init.c |8 1 file changed, 8 deletions(-) diff --git a/arch_init.c b/arch_init.c index 7545d96..e0acbc5 100644 --- a/arch_init.c +++ b

Re: [Qemu-devel] [PATCHv5] block/get_block_status: avoid redundant callouts on raw devices

2013-10-07 Thread Peter Lieven
On 07.10.2013 10:25, Paolo Bonzini wrote: Il 07/10/2013 07:59, Peter Lieven ha scritto: if a raw device like an iscsi target or host device is used the current implementation makes a second call out to get the block status of bs-file. Signed-off-by: Peter Lieven p...@kamp.de --- v5: add

Re: [Qemu-devel] [Bug 1100843] Re: Live Migration Causes Performance Issues

2013-10-07 Thread Peter Lieven
On 07.10.2013 11:37, Paolo Bonzini wrote: Il 07/10/2013 08:38, Peter Lieven ha scritto: On 06.10.2013 15:57, Zhang Haoyu wrote: From my testing this has been fixed in the saucy version (1.5.0) of qemu. It is fixed by this patch: f1c72795af573b24a7da5eb52375c9aba8a37972 However later

Re: [Qemu-devel] [PATCHv3 00/20] block: logical block provisioning enhancements

2013-10-08 Thread Peter Lieven
On 08.10.2013 09:02, Stefan Hajnoczi wrote: On Mon, Oct 7, 2013 at 11:42 AM, Paolo Bonzini pbonz...@redhat.com wrote: Il 07/10/2013 10:42, Stefan Hajnoczi ha scritto: Could you make bdrv_co_write_zeroes() always use UNMAP, if possible, and avoid adding the new BDRV_REQ_MAY_UNMAP flag? While

Re: [Qemu-devel] [PATCHv3 00/20] block: logical block provisioning enhancements

2013-10-08 Thread Peter Lieven
On 08.10.2013 10:59, Stefan Hajnoczi wrote: On Tue, Oct 8, 2013 at 10:01 AM, Peter Lieven p...@kamp.de wrote: On 08.10.2013 09:02, Stefan Hajnoczi wrote: On Mon, Oct 7, 2013 at 11:42 AM, Paolo Bonzini pbonz...@redhat.com wrote: Il 07/10/2013 10:42, Stefan Hajnoczi ha scritto: Could you make

[Qemu-devel] [PATCHv4 03/17] block: introduce BDRV_REQ_MAY_UNMAP request flag

2013-10-08 Thread Peter Lieven
Reviewed-by: Eric Blake ebl...@redhat.com Signed-off-by: Peter Lieven p...@kamp.de --- block-migration.c |3 ++- block.c |4 block/backup.c|2 +- include/block/block.h |7 +++ 4 files changed, 14 insertions(+), 2 deletions(-) diff --git a/block

[Qemu-devel] [PATCHv4 05/17] block/raw: add bdrv_has_discard_zeroes and bdrv_has_discard_write_zeroes

2013-10-08 Thread Peter Lieven
Reviewed-by: Eric Blake ebl...@redhat.com Signed-off-by: Peter Lieven p...@kamp.de --- block/raw_bsd.c | 56 +-- 1 file changed, 34 insertions(+), 22 deletions(-) diff --git a/block/raw_bsd.c b/block/raw_bsd.c index d5ab295..8dc7bba 100644

[Qemu-devel] [PATCHv4 01/17] block: make BdrvRequestFlags public

2013-10-08 Thread Peter Lieven
Reviewed-by: Eric Blake ebl...@redhat.com Signed-off-by: Peter Lieven p...@kamp.de --- block.c |5 - include/block/block.h |5 + 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/block.c b/block.c index 93e113a..08cba1e 100644 --- a/block.c +++ b/block.c

[Qemu-devel] [PATCHv4 06/17] block: add BlockLimits structure to BlockDriverState

2013-10-08 Thread Peter Lieven
this patch adds BlockLimits which introduces discard and write_zeroes limits and alignment information to the BlockDriverState. Signed-off-by: Peter Lieven p...@kamp.de --- include/block/block_int.h | 17 + 1 file changed, 17 insertions(+) diff --git a/include/block

[Qemu-devel] [PATCHv4 14/17] block/get_block_status: fix BDRV_BLOCK_ZERO for unallocated blocks

2013-10-08 Thread Peter Lieven
-by: Eric Blake ebl...@redhat.com Signed-off-by: Peter Lieven p...@kamp.de --- block.c |4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/block.c b/block.c index fc931e3..1be4418 100644 --- a/block.c +++ b/block.c @@ -3247,8 +3247,8 @@ static int64_t coroutine_fn

[Qemu-devel] [PATCHv4 02/17] block: add flags to bdrv_*_write_zeroes

2013-10-08 Thread Peter Lieven
Reviewed-by: Eric Blake ebl...@redhat.com Signed-off-by: Peter Lieven p...@kamp.de --- block-migration.c |2 +- block.c | 20 +++- block/backup.c|3 ++- block/qcow2-cluster.c |2 +- block/qcow2.c |2 +- block

[Qemu-devel] [PATCHv4 07/17] block: honour BlockLimits in bdrv_co_do_write_zeroes

2013-10-08 Thread Peter Lieven
Reviewed-by: Eric Blake ebl...@redhat.com Signed-off-by: Peter Lieven p...@kamp.de --- block.c | 65 +++ 1 file changed, 49 insertions(+), 16 deletions(-) diff --git a/block.c b/block.c index 6a46bc2..7551751 100644 --- a/block.c

[Qemu-devel] [PATCHv4 16/17] qemu-img: conditionally zero out target on convert

2013-10-08 Thread Peter Lieven
If the target has_zero_init = 0, but supports efficiently writing zeroes by unmapping we call bdrv_zeroize to avoid fully allocating the target. This currently is designed especially for iscsi. Reviewed-by: Eric Blake ebl...@redhat.com Signed-off-by: Peter Lieven p...@kamp.de --- qemu-img.c

[Qemu-devel] [PATCHv4 00/17] block: logical block provisioning enhancements

2013-10-08 Thread Peter Lieven
() - added logic to bdrv_co_discard and bdrv_co_do_write_zeroes to honour limit and alignment info. - added support for -S 0 in qemu-img convert. Peter Lieven (17): block: make BdrvRequestFlags public block: add flags to bdrv_*_write_zeroes block: introduce BDRV_REQ_MAY_UNMAP request

[Qemu-devel] [PATCHv4 04/17] block: introduce bdrv_has_discard_zeroes and bdrv_has_discard_write_zeroes

2013-10-08 Thread Peter Lieven
Reviewed-by: Eric Blake ebl...@redhat.com Signed-off-by: Peter Lieven p...@kamp.de --- block.c | 29 + include/block/block.h |2 ++ include/block/block_int.h | 13 + 3 files changed, 44 insertions(+) diff --git a/block.c b

[Qemu-devel] [PATCHv4 11/17] iscsi: add bdrv_has_discard_zeroes and bdrv_has_discard_write_zeroes

2013-10-08 Thread Peter Lieven
Reviewed-by: Eric Blake ebl...@redhat.com Signed-off-by: Peter Lieven p...@kamp.de --- block/iscsi.c | 16 +++- 1 file changed, 15 insertions(+), 1 deletion(-) diff --git a/block/iscsi.c b/block/iscsi.c index 8ed2274..f0ac620 100644 --- a/block/iscsi.c +++ b/block/iscsi.c

[Qemu-devel] [PATCHv4 10/17] iscsi: set limits in BlockDriverState

2013-10-08 Thread Peter Lieven
Reviewed-by: Eric Blake ebl...@redhat.com Signed-off-by: Peter Lieven p...@kamp.de --- block/iscsi.c | 14 ++ 1 file changed, 14 insertions(+) diff --git a/block/iscsi.c b/block/iscsi.c index be70ced..8ed2274 100644 --- a/block/iscsi.c +++ b/block/iscsi.c @@ -1367,6 +1367,20

[Qemu-devel] [PATCHv4 08/17] block: honour BlockLimits in bdrv_co_discard

2013-10-08 Thread Peter Lieven
Reviewed-by: Eric Blake ebl...@redhat.com Signed-off-by: Peter Lieven p...@kamp.de --- block.c | 37 - 1 file changed, 36 insertions(+), 1 deletion(-) diff --git a/block.c b/block.c index 7551751..43d5f46 100644 --- a/block.c +++ b/block.c @@ -4209,6

[Qemu-devel] [PATCHv4 09/17] iscsi: simplify iscsi_co_discard

2013-10-08 Thread Peter Lieven
now that bdrv_co_discard can handle limits we do not need the request split logic here anymore. Reviewed-by: Eric Blake ebl...@redhat.com Signed-off-by: Peter Lieven p...@kamp.de --- block/iscsi.c | 67 + 1 file changed, 25 insertions

[Qemu-devel] [PATCHv4 12/17] iscsi: add bdrv_co_write_zeroes

2013-10-08 Thread Peter Lieven
Reviewed-by: Eric Blake ebl...@redhat.com Signed-off-by: Peter Lieven p...@kamp.de --- block/iscsi.c | 59 + 1 file changed, 59 insertions(+) diff --git a/block/iscsi.c b/block/iscsi.c index f0ac620..16510c2 100644 --- a/block/iscsi.c

[Qemu-devel] [PATCHv4 13/17] block: introduce bdrv_make_zero

2013-10-08 Thread Peter Lieven
write by unmapping if the driver supports it. Signed-off-by: Peter Lieven p...@kamp.de --- block.c | 37 + include/block/block.h |1 + 2 files changed, 38 insertions(+) diff --git a/block.c b/block.c index 43d5f46..fc931e3 100644 --- a/block.c

Re: [Qemu-devel] [PATCHv5] block/get_block_status: avoid redundant callouts on raw devices

2013-10-08 Thread Peter Lieven
On 07.10.2013 10:25, Paolo Bonzini wrote: Il 07/10/2013 07:59, Peter Lieven ha scritto: if a raw device like an iscsi target or host device is used the current implementation makes a second call out to get the block status of bs-file. Signed-off-by: Peter Lieven p...@kamp.de --- v5: add

[Qemu-devel] [PATCHv4 15/17] qemu-img: add support for fully allocated images

2013-10-08 Thread Peter Lieven
Signed-off-by: Peter Lieven p...@kamp.de --- qemu-img.c|8 +--- qemu-img.texi |5 + 2 files changed, 10 insertions(+), 3 deletions(-) diff --git a/qemu-img.c b/qemu-img.c index 926f0a0..c6eff15 100644 --- a/qemu-img.c +++ b/qemu-img.c @@ -100,8 +100,10 @@ static void help

[Qemu-devel] [PATCHv6] block/get_block_status: avoid redundant callouts on raw devices

2013-10-08 Thread Peter Lieven
if a raw device like an iscsi target or host device is used the current implementation makes a second call out to get the block status of bs-file. Signed-off-by: Peter Lieven p...@kamp.de --- v6: made the result of raw_co_get_block_status valid by adding BDRV_BLOCK_DATA and setting *pnum

[Qemu-devel] [PATCHv4 17/17] block/raw: copy BlockLimits on raw_open

2013-10-08 Thread Peter Lieven
Signed-off-by: Peter Lieven p...@kamp.de --- block/raw_bsd.c |1 + 1 file changed, 1 insertion(+) diff --git a/block/raw_bsd.c b/block/raw_bsd.c index 8dc7bba..2c26b79 100644 --- a/block/raw_bsd.c +++ b/block/raw_bsd.c @@ -159,6 +159,7 @@ static int raw_open(BlockDriverState *bs, QDict

Re: [Qemu-devel] [Bug 1100843] Re: Live Migration Causes Performance Issues

2013-10-10 Thread Peter Lieven
On 07.10.2013 11:55, Paolo Bonzini wrote: Il 07/10/2013 11:49, Peter Lieven ha scritto: It's in general not easy to do this if you take non-x86 targets into account. What about the dirty way to zero out all non zero pages at the beginning of ram_load? I'm not sure I follow? sth like

Re: [Qemu-devel] [PATCH] block/iscsi: introduce bdrv_co_{readv, writev, flush_to_disk}

2013-10-11 Thread Peter Lieven
On 08.10.2013 14:39, Kevin Wolf wrote: Am 08.10.2013 um 14:35 hat Paolo Bonzini geschrieben: Il 08/10/2013 14:33, Kevin Wolf ha scritto: this converts read, write and flush functions from aio to coroutines. I'm not sure it's already the time for this... Cancellation sucks in QEMU, and this

[Qemu-devel] [PATCH] block/iscsi: remove .bdrv_has_zero_init

2013-10-11 Thread Peter Lieven
since commit 3ac21627 the default value changed to 0. Signed-off-by: Peter Lieven p...@kamp.de --- block/iscsi.c |7 --- 1 file changed, 7 deletions(-) diff --git a/block/iscsi.c b/block/iscsi.c index a2a961e..a660a1c 100644 --- a/block/iscsi.c +++ b/block/iscsi.c @@ -1447,11 +1447,6

[Qemu-devel] [PATCH] block/iscsi: updated copyright

2013-10-11 Thread Peter Lieven
added myself to reflect recent work on the iscsi block driver. Signed-off-by: Peter Lieven p...@kamp.de --- block/iscsi.c |1 + 1 file changed, 1 insertion(+) diff --git a/block/iscsi.c b/block/iscsi.c index a660a1c..ee8cdd3 100644 --- a/block/iscsi.c +++ b/block/iscsi.c @@ -2,6 +2,7

Re: [Qemu-devel] [PATCHv4 14/17] block/get_block_status: fix BDRV_BLOCK_ZERO for unallocated blocks

2013-10-18 Thread Peter Lieven
On 18.10.2013 14:38, Stefan Hajnoczi wrote: On Tue, Oct 08, 2013 at 01:58:08PM +0200, Peter Lieven wrote: this patch does 2 things: a) only do additional call outs if BDRV_BLOCK_ZERO is not already set. b) use the newly introduced bdrv_has_discard_zeroes() to return the zero state

Re: [Qemu-devel] [PATCHv4 14/17] block/get_block_status: fix BDRV_BLOCK_ZERO for unallocated blocks

2013-10-18 Thread Peter Lieven
On 18.10.2013 14:49, Paolo Bonzini wrote: Il 18/10/2013 14:38, Stefan Hajnoczi ha scritto: On Tue, Oct 08, 2013 at 01:58:08PM +0200, Peter Lieven wrote: this patch does 2 things: a) only do additional call outs if BDRV_BLOCK_ZERO is not already set. b) use the newly introduced

Re: [Qemu-devel] [PATCHv4 14/17] block/get_block_status: fix BDRV_BLOCK_ZERO for unallocated blocks

2013-10-18 Thread Peter Lieven
On 18.10.2013 15:24, Stefan Hajnoczi wrote: On Fri, Oct 18, 2013 at 02:49:11PM +0200, Paolo Bonzini wrote: Il 18/10/2013 14:38, Stefan Hajnoczi ha scritto: On Tue, Oct 08, 2013 at 01:58:08PM +0200, Peter Lieven wrote: this patch does 2 things: a) only do additional call outs

Re: [Qemu-devel] [PATCHv4 14/17] block/get_block_status: fix BDRV_BLOCK_ZERO for unallocated blocks

2013-10-18 Thread Peter Lieven
Am 18.10.2013 um 15:50 schrieb Paolo Bonzini pbonz...@redhat.com: Il 18/10/2013 15:26, Peter Lieven ha scritto: - bdrv_discard_zeroes for bdrv_has_discard_write_zeroes This would conform to the linux ioctl BLKDISCARDZEROES. However, we need the write_zeroes operation for a guarantee

[Qemu-devel] [PATCHv5 02/17] block: add flags to bdrv_*_write_zeroes

2013-10-20 Thread Peter Lieven
Reviewed-by: Eric Blake ebl...@redhat.com Signed-off-by: Peter Lieven p...@kamp.de --- block-migration.c |2 +- block.c | 20 +++- block/backup.c|3 ++- block/qcow2-cluster.c |2 +- block/qcow2.c |2 +- block

[Qemu-devel] [PATCHv5 01/17] block: make BdrvRequestFlags public

2013-10-20 Thread Peter Lieven
Reviewed-by: Eric Blake ebl...@redhat.com Signed-off-by: Peter Lieven p...@kamp.de --- block.c |5 - include/block/block.h |5 + 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/block.c b/block.c index fd05a80..eb11a07 100644 --- a/block.c +++ b/block.c

[Qemu-devel] [PATCHv5 03/17] block: introduce BDRV_REQ_MAY_UNMAP request flag

2013-10-20 Thread Peter Lieven
Reviewed-by: Eric Blake ebl...@redhat.com Signed-off-by: Peter Lieven p...@kamp.de --- block-migration.c |3 ++- block.c |4 block/backup.c|2 +- include/block/block.h |7 +++ 4 files changed, 14 insertions(+), 2 deletions(-) diff --git a/block

[Qemu-devel] [PATCHv5 00/17] block: logical block provisioning enhancements

2013-10-20 Thread Peter Lieven
and write_zeroes_alignment to BlockDriverState - added bdrv_has_discard_zeroes() and bdrv_has_discard_write_zeroes() - added logic to bdrv_co_discard and bdrv_co_do_write_zeroes to honour limit and alignment info. - added support for -S 0 in qemu-img convert. Peter Lieven (17): block: make

[Qemu-devel] [PATCHv5 06/17] block/iscsi: add .bdrv_get_info

2013-10-20 Thread Peter Lieven
Signed-off-by: Peter Lieven p...@kamp.de --- block/iscsi.c |9 + 1 file changed, 9 insertions(+) diff --git a/block/iscsi.c b/block/iscsi.c index a2a961e..1dbbcad 100644 --- a/block/iscsi.c +++ b/block/iscsi.c @@ -1506,6 +1506,14 @@ out: return ret; } +static int

[Qemu-devel] [PATCHv5 08/17] block: honour BlockLimits in bdrv_co_do_write_zeroes

2013-10-20 Thread Peter Lieven
Reviewed-by: Eric Blake ebl...@redhat.com Signed-off-by: Peter Lieven p...@kamp.de --- block.c | 65 +++ 1 file changed, 49 insertions(+), 16 deletions(-) diff --git a/block.c b/block.c index 0601b02..0c0b0ac 100644 --- a/block.c

[Qemu-devel] [PATCHv5 04/17] block: add logical block provisioning info to BlockDriverInfo

2013-10-20 Thread Peter Lieven
Signed-off-by: Peter Lieven p...@kamp.de --- include/block/block.h | 16 1 file changed, 16 insertions(+) diff --git a/include/block/block.h b/include/block/block.h index 1f30a56..5fbab01 100644 --- a/include/block/block.h +++ b/include/block/block.h @@ -18,6 +18,22 @@ typedef

[Qemu-devel] [PATCHv5 07/17] block: add BlockLimits structure to BlockDriverState

2013-10-20 Thread Peter Lieven
this patch adds BlockLimits which introduces discard and write_zeroes limits and alignment information to the BlockDriverState. Signed-off-by: Peter Lieven p...@kamp.de --- include/block/block_int.h | 17 + 1 file changed, 17 insertions(+) diff --git a/include/block

[Qemu-devel] [PATCHv5 12/17] iscsi: add bdrv_co_write_zeroes

2013-10-20 Thread Peter Lieven
Reviewed-by: Eric Blake ebl...@redhat.com Signed-off-by: Peter Lieven p...@kamp.de --- block/iscsi.c | 59 + 1 file changed, 59 insertions(+) diff --git a/block/iscsi.c b/block/iscsi.c index c0465aa..1845fc8 100644 --- a/block/iscsi.c

[Qemu-devel] [PATCHv5 05/17] block: add wrappers for logical block provisioning information

2013-10-20 Thread Peter Lieven
This adds 2 wrappers to read the unallocated_blocks_are_zero and can_write_zeroes_with_unmap info from the BDI. The wrappers are required to check for the existence of a backing_hd and if the devices are opened with the correct flags. Signed-off-by: Peter Lieven p...@kamp.de --- block.c

[Qemu-devel] [PATCHv5 09/17] block: honour BlockLimits in bdrv_co_discard

2013-10-20 Thread Peter Lieven
Reviewed-by: Eric Blake ebl...@redhat.com Signed-off-by: Peter Lieven p...@kamp.de --- block.c | 37 - 1 file changed, 36 insertions(+), 1 deletion(-) diff --git a/block.c b/block.c index 0c0b0ac..b28dd42 100644 --- a/block.c +++ b/block.c @@ -4234,6

[Qemu-devel] [PATCHv5 16/17] qemu-img: conditionally zero out target on convert

2013-10-20 Thread Peter Lieven
If the target has_zero_init = 0, but supports efficiently writing zeroes by unmapping we call bdrv_make_zero to avoid fully allocating the target. This currently is designed especially for iscsi. Reviewed-by: Eric Blake ebl...@redhat.com Signed-off-by: Peter Lieven p...@kamp.de --- qemu-img.c

[Qemu-devel] [PATCHv5 17/17] block/raw: copy BlockLimits on raw_open

2013-10-20 Thread Peter Lieven
Signed-off-by: Peter Lieven p...@kamp.de --- block/raw_bsd.c |1 + 1 file changed, 1 insertion(+) diff --git a/block/raw_bsd.c b/block/raw_bsd.c index b0dd23f..49ac18c 100644 --- a/block/raw_bsd.c +++ b/block/raw_bsd.c @@ -150,6 +150,7 @@ static int raw_open(BlockDriverState *bs, QDict

[Qemu-devel] [PATCHv5 13/17] block: introduce bdrv_make_zero

2013-10-20 Thread Peter Lieven
write by unmapping if the driver supports it. Signed-off-by: Peter Lieven p...@kamp.de --- block.c | 37 + include/block/block.h |1 + 2 files changed, 38 insertions(+) diff --git a/block.c b/block.c index b28dd42..21a992a 100644 --- a/block.c

[Qemu-devel] [PATCHv5 14/17] block/get_block_status: fix BDRV_BLOCK_ZERO for unallocated blocks

2013-10-20 Thread Peter Lieven
-by: Eric Blake ebl...@redhat.com Signed-off-by: Peter Lieven p...@kamp.de --- block.c |4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/block.c b/block.c index 21a992a..69a2d2b 100644 --- a/block.c +++ b/block.c @@ -3263,8 +3263,8 @@ static int64_t coroutine_fn

[Qemu-devel] [PATCHv5 15/17] qemu-img: add support for fully allocated images

2013-10-20 Thread Peter Lieven
Signed-off-by: Peter Lieven p...@kamp.de --- qemu-img.c|8 +--- qemu-img.texi |5 + 2 files changed, 10 insertions(+), 3 deletions(-) diff --git a/qemu-img.c b/qemu-img.c index 926f0a0..c6eff15 100644 --- a/qemu-img.c +++ b/qemu-img.c @@ -100,8 +100,10 @@ static void help

[Qemu-devel] [PATCHv5 10/17] iscsi: simplify iscsi_co_discard

2013-10-20 Thread Peter Lieven
now that bdrv_co_discard can handle limits we do not need the request split logic here anymore. Reviewed-by: Eric Blake ebl...@redhat.com Signed-off-by: Peter Lieven p...@kamp.de --- block/iscsi.c | 67 + 1 file changed, 25 insertions

[Qemu-devel] [PATCHv5 11/17] iscsi: set limits in BlockDriverState

2013-10-20 Thread Peter Lieven
Reviewed-by: Eric Blake ebl...@redhat.com Signed-off-by: Peter Lieven p...@kamp.de --- block/iscsi.c | 14 ++ 1 file changed, 14 insertions(+) diff --git a/block/iscsi.c b/block/iscsi.c index 47b9cc9..c0465aa 100644 --- a/block/iscsi.c +++ b/block/iscsi.c @@ -1367,6 +1367,20

[Qemu-devel] [PATCH] block/vpc: fix virtual size for images created with disk2vhd

2013-10-21 Thread Peter Lieven
Signed-off-by: Peter Lieven p...@kamp.de --- block/vpc.c |9 + 1 file changed, 9 insertions(+) diff --git a/block/vpc.c b/block/vpc.c index b5dca39..1acc1d4 100644 --- a/block/vpc.c +++ b/block/vpc.c @@ -211,6 +211,15 @@ static int vpc_open(BlockDriverState *bs, QDict *options, int

[Qemu-devel] [PATCH] block/vpc: check that the image has not been truncated

2013-10-22 Thread Peter Lieven
this adds a check that a dynamic VHD file has not been accidently truncated (e.g. during transfer or upload). Signed-off-by: Peter Lieven p...@kamp.de --- block/vpc.c |7 +++ 1 file changed, 7 insertions(+) diff --git a/block/vpc.c b/block/vpc.c index 1acc1d4..921364e 100644 --- a/block

Re: [Qemu-devel] [PATCH] block/vpc: check that the image has not been truncated

2013-10-22 Thread Peter Lieven
On 22.10.2013 08:59, Eric Blake wrote: On 10/22/2013 07:43 AM, Peter Lieven wrote: this adds a check that a dynamic VHD file has not been accidently truncated (e.g. during transfer or upload). Signed-off-by: Peter Lieven p...@kamp.de --- block/vpc.c |7 +++ 1 file changed, 7

[Qemu-devel] [PATCH] qemu-img: add special exit code if bdrv_check is not supported

2013-10-22 Thread Peter Lieven
currently it is not possible to distinguish by exitcode if there has been an error or if bdrv_check is not supported by the image format. Change the exitcode from 1 to 255 for the latter case. Signed-off-by: Peter Lieven p...@kamp.de --- qemu-img.c |2 +- 1 file changed, 1 insertion(+), 1

Re: [Qemu-devel] [PATCH] qemu-img: add special exit code if bdrv_check is not supported

2013-10-22 Thread Peter Lieven
On 22.10.2013 10:34, Eric Blake wrote: On 10/22/2013 09:26 AM, Peter Lieven wrote: currently it is not possible to distinguish by exitcode if there has been an error or if bdrv_check is not supported by the image format. Change the exitcode from 1 to 255 for the latter case. Why 255? Sure

[Qemu-devel] [PATCHv2] qemu-img: add special exit code if bdrv_check is not supported

2013-10-24 Thread Peter Lieven
currently it is not possible to distinguish by exitcode if there has been an error or if bdrv_check is not supported by the image format. Change the exitcode from 1 to 63 for the latter case. Signed-off-by: Peter Lieven p...@kamp.de --- v1-v2: As Eric suggested changed the exitcode from 255 to 63

  1   2   3   4   5   6   7   8   9   10   >