Re: [Qemu-block] [Qemu-devel] [PATCH] migration: flush the bdrv before stopping VM

2015-03-18 Thread Kevin Wolf
[ Cc: qemu-block ] Am 18.03.2015 um 04:19 hat Li, Liang Z geschrieben: This needs further review/changes on the block layer. First explanation, why I think this don't fix the full problem. Whith this patch, we fix the problem where we have a dirty block layer but basically nothing

Re: [Qemu-block] [PATCH] migration: flush the bdrv before stopping VM

2015-03-18 Thread Kevin Wolf
Am 18.03.2015 um 13:36 hat Juan Quintela geschrieben: Kevin Wolf kw...@redhat.com wrote: The problem is that the block layer really doesn't have an option to control what is getting synced once the data is cached outside of qemu. Essentially we can do an fdatasync() or we can leave

[Qemu-block] [PULL 06/17] qcow2: Respect new_block in alloc_refcount_block()

2015-03-16 Thread Kevin Wolf
...@redhat.com Reviewed-by: Kevin Wolf kw...@redhat.com Signed-off-by: Max Reitz mre...@redhat.com --- block/qcow2-refcount.c | 16 ++-- 1 file changed, 14 insertions(+), 2 deletions(-) diff --git a/block/qcow2-refcount.c b/block/qcow2-refcount.c index dc8d186..6cbae1d 100644 --- a/block/qcow2

[Qemu-block] [PULL 11/17] blockdev: Convert bdrv_find to blk_by_name

2015-03-16 Thread Kevin Wolf
From: Fam Zheng f...@redhat.com Signed-off-by: Fam Zheng f...@redhat.com Message-id: 1425296209-1476-4-git-send-email-f...@redhat.com Reviewed-by: Max Reitz mre...@redhat.com Signed-off-by: Max Reitz mre...@redhat.com --- blockdev.c | 92

Re: [Qemu-block] [Qemu-devel] block-commit dropping privs

2015-03-30 Thread Kevin Wolf
Am 27.03.2015 um 18:12 hat Eric Blake geschrieben: On 03/27/2015 09:36 AM, Michael Tokarev wrote: Wonder how to specify cache mode, or should I open these with proper O_DIRECT/O_SYNC/whatever? It looks like it's possible to change O_DIRECT at runtime but not O_SYNC. And the more

Re: [Qemu-block] block-commit dropping privs

2015-04-01 Thread Kevin Wolf
Am 01.04.2015 um 11:54 hat Michael Tokarev geschrieben: 01.04.2015 12:26, Michael Tokarev пишет: 30.03.2015 18:36, Kevin Wolf wrote: Am 27.03.2015 um 18:12 hat Eric Blake geschrieben: On 03/27/2015 09:36 AM, Michael Tokarev wrote: Wonder how to specify cache mode, or should I open

[Qemu-block] [PULL 1/3] raw-posix: Deprecate host floppy passthrough

2015-03-19 Thread Kevin Wolf
Reviewed-by: Max Reitz mre...@redhat.com Signed-off-by: Kevin Wolf kw...@redhat.com --- block/raw-posix.c| 2 ++ qapi/block-core.json | 2 ++ qemu-doc.texi| 5 +++-- qemu-options.hx | 3 +-- qmp-commands.hx | 2 +- 5 files changed, 9 insertions(+), 5 deletions(-) diff --git a/block

Re: [Qemu-block] block-commit dropping privs

2015-04-02 Thread Kevin Wolf
Am 02.04.2015 um 12:58 hat Michael Tokarev geschrieben: 01.04.2015 15:34, Kevin Wolf wrote: [] Overriding the backing file should work like this: -drive file=...,backing.file.filename=/dev/fdset/2 Oh-ok, this works. Sort of. Because after performing commit

Re: [Qemu-block] [PATCH] qcow2: do lazy allocation of the L2 cache

2015-04-24 Thread Kevin Wolf
Am 24.04.2015 um 14:50 hat Alberto Garcia geschrieben: On Fri 24 Apr 2015 02:37:21 PM CEST, Stefan Hajnoczi wrote: I think it would be nice to have a way to free unused cache entries after a while. Do you think mmap plus a periodic timer would work? I'm hesitant about changes like

Re: [Qemu-block] [PATCH COLO v3 01/14] docs: block replication's description

2015-04-23 Thread Kevin Wolf
Am 23.04.2015 um 12:44 hat Paolo Bonzini geschrieben: On 23/04/2015 12:40, Kevin Wolf wrote: The question that is still open for me is whether it would be a colo.c or an active-mirror.c, i.e. if this would be tied specifically to COLO or if it could be kept generic enough that it could

Re: [Qemu-block] [PULL 76/76] block: move I/O request processing to block/io.c

2015-04-29 Thread Kevin Wolf
Am 28.04.2015 um 19:15 hat Eric Blake geschrieben: On 04/28/2015 09:00 AM, Kevin Wolf wrote: From: Stefan Hajnoczi stefa...@redhat.com The block.c file has grown to over 6000 lines. It is time to split this file so there are fewer conflicts and the code is easier to maintain

[Qemu-block] [PULL 04/76] hw/arm/nseries: convert ffs(3) to ctz32()

2015-04-28 Thread Kevin Wolf
-send-email-stefa...@redhat.com Signed-off-by: Kevin Wolf kw...@redhat.com --- hw/arm/nseries.c | 5 - 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/hw/arm/nseries.c b/hw/arm/nseries.c index 2a5406d..d243159 100644 --- a/hw/arm/nseries.c +++ b/hw/arm/nseries.c @@ -579,7 +579,10

[Qemu-block] [PULL 02/76] MAINTAINERS: Add myself as the maintainer of the Quorum driver

2015-04-28 Thread Kevin Wolf
From: Alberto Garcia be...@igalia.com Signed-off-by: Alberto Garcia be...@igalia.com Message-id: 1426522925-1-1-git-send-email-be...@igalia.com Signed-off-by: Stefan Hajnoczi stefa...@redhat.com Signed-off-by: Kevin Wolf kw...@redhat.com --- MAINTAINERS | 6 ++ 1 file changed, 6

[Qemu-block] [PULL 39/76] qmp: fill in the image field in BlockDeviceInfo

2015-04-28 Thread Kevin Wolf
-send-email-be...@igalia.com Signed-off-by: Stefan Hajnoczi stefa...@redhat.com Signed-off-by: Kevin Wolf kw...@redhat.com --- block.c | 9 +++-- block/qapi.c | 46 +- blockdev.c| 2 +- include/block/block.h | 2

[Qemu-block] [PULL 54/76] hbitmap: cache array lengths

2015-04-28 Thread Kevin Wolf
...@redhat.com Reviewed-by: Eric Blake ebl...@redhat.com Signed-off-by: John Snow js...@redhat.com Reviewed-by: Stefan Hajnoczi stefa...@redhat.com Message-id: 1429314609-29776-7-git-send-email-js...@redhat.com Signed-off-by: Stefan Hajnoczi stefa...@redhat.com Signed-off-by: Kevin Wolf kw...@redhat.com

[Qemu-block] [PULL 57/76] block: Add bitmap successors

2015-04-28 Thread Kevin Wolf
-id: 1429314609-29776-10-git-send-email-js...@redhat.com Signed-off-by: Stefan Hajnoczi stefa...@redhat.com Signed-off-by: Kevin Wolf kw...@redhat.com --- block.c | 104 +- blockdev.c| 7 include/block/block.h | 10

[Qemu-block] [PULL 06/76] Convert (ffs(val) - 1) to ctz32(val)

2015-04-28 Thread Kevin Wolf
, asserts, etc). Therefore we don't need to worry about the fact that ctz32(0) == 32. Signed-off-by: Stefan Hajnoczi stefa...@redhat.com Message-id: 1427124571-28598-5-git-send-email-stefa...@redhat.com Signed-off-by: Kevin Wolf kw...@redhat.com --- block.c| 2 +- block/qcow2

[Qemu-block] [PULL 15/76] iothread: release iothread around aio_poll

2015-04-28 Thread Kevin Wolf
stefa...@redhat.com Signed-off-by: Kevin Wolf kw...@redhat.com --- async.c | 8 +--- iothread.c | 11 ++- tests/test-aio.c | 19 +++ 3 files changed, 14 insertions(+), 24 deletions(-) diff --git a/async.c b/async.c index 77d080d..46d9e63 100644

[Qemu-block] [PULL 27/76] block: Pause block jobs in bdrv_drain_all

2015-04-28 Thread Kevin Wolf
be...@igalia.com Message-id: 1428069921-2957-3-git-send-email-f...@redhat.com Signed-off-by: Stefan Hajnoczi stefa...@redhat.com Signed-off-by: Kevin Wolf kw...@redhat.com --- block.c | 20 1 file changed, 20 insertions(+) diff --git a/block.c b/block.c index 670d7e4..70aed80

[Qemu-block] [PULL 26/76] blockjob: Allow nested pause

2015-04-28 Thread Kevin Wolf
Reviewed-by: Alberto Garcia be...@igalia.com Message-id: 1428069921-2957-2-git-send-email-f...@redhat.com Signed-off-by: Stefan Hajnoczi stefa...@redhat.com Signed-off-by: Kevin Wolf kw...@redhat.com --- block/mirror.c | 2 +- blockdev.c | 8 +--- blockjob.c

[Qemu-block] [PULL 30/76] block: avoid unnecessary bottom halves

2015-04-28 Thread Kevin Wolf
-by: Stefan Hajnoczi stefa...@redhat.com Signed-off-by: Kevin Wolf kw...@redhat.com --- block.c | 43 ++- 1 file changed, 34 insertions(+), 9 deletions(-) diff --git a/block.c b/block.c index 70aed80..d13b2e7 100644 --- a/block.c +++ b/block.c @@ -4849,6 +4849,7

[Qemu-block] [PULL 28/76] qemu-iotests: Test that stop doesn't drain block jobs

2015-04-28 Thread Kevin Wolf
Hajnoczi stefa...@redhat.com Signed-off-by: Kevin Wolf kw...@redhat.com --- tests/qemu-iotests/129 | 86 ++ tests/qemu-iotests/129.out | 5 +++ tests/qemu-iotests/group | 1 + 3 files changed, 92 insertions(+) create mode 100644 tests/qemu

[Qemu-block] [PULL 61/76] block: add BdrvDirtyBitmap documentation

2015-04-28 Thread Kevin Wolf
-by: Kevin Wolf kw...@redhat.com --- block.c | 10 +- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/block.c b/block.c index f0157d5..4121929 100644 --- a/block.c +++ b/block.c @@ -61,11 +61,11 @@ * or enabled. A frozen bitmap can only abdicate() or reclaim(). */ struct

[Qemu-block] [PULL 29/76] blockjob: Update function name in comments

2015-04-28 Thread Kevin Wolf
Hajnoczi stefa...@redhat.com Signed-off-by: Kevin Wolf kw...@redhat.com --- block/backup.c | 2 +- block/mirror.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/block/backup.c b/block/backup.c index 1c535b1..3312476 100644 --- a/block/backup.c +++ b/block/backup.c @@ -287,7

[Qemu-block] [PULL 47/76] block/iscsi: bump year in copyright notice

2015-04-28 Thread Kevin Wolf
From: Peter Lieven p...@kamp.de Signed-off-by: Peter Lieven p...@kamp.de Message-id: 1429193313-4263-9-git-send-email...@kamp.de Signed-off-by: Stefan Hajnoczi stefa...@redhat.com Signed-off-by: Kevin Wolf kw...@redhat.com --- block/iscsi.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion

[Qemu-block] [PULL 60/76] qmp: Add dirty bitmap status field in query-block

2015-04-28 Thread Kevin Wolf
Reviewed-by: Eric Blake ebl...@redhat.com Message-id: 1429314609-29776-13-git-send-email-js...@redhat.com Signed-off-by: Stefan Hajnoczi stefa...@redhat.com Signed-off-by: Kevin Wolf kw...@redhat.com --- block.c | 1 + qapi/block-core.json | 5 - 2 files changed, 5 insertions(+), 1

[Qemu-block] [PULL 65/76] iotests: add invalid input incremental backup tests

2015-04-28 Thread Kevin Wolf
-by: Kevin Wolf kw...@redhat.com --- tests/qemu-iotests/124 | 104 + tests/qemu-iotests/124.out | 5 +++ tests/qemu-iotests/group | 1 + 3 files changed, 110 insertions(+) create mode 100644 tests/qemu-iotests/124 create mode 100644 tests/qemu

[Qemu-block] [PULL 43/76] block/iscsi: store DPOFUA bit from the modesense command

2015-04-28 Thread Kevin Wolf
From: Peter Lieven p...@kamp.de Signed-off-by: Peter Lieven p...@kamp.de Message-id: 1429193313-4263-5-git-send-email...@kamp.de Signed-off-by: Stefan Hajnoczi stefa...@redhat.com Signed-off-by: Kevin Wolf kw...@redhat.com --- block/iscsi.c | 3 +++ 1 file changed, 3 insertions(+) diff --git

[Qemu-block] [PULL 46/76] block/iscsi: handle SCSI_STATUS_TASK_SET_FULL

2015-04-28 Thread Kevin Wolf
-off-by: Kevin Wolf kw...@redhat.com --- block/iscsi.c | 7 +-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/block/iscsi.c b/block/iscsi.c index 5999f74..328907b 100644 --- a/block/iscsi.c +++ b/block/iscsi.c @@ -186,10 +186,13 @@ iscsi_co_generic_cb(struct iscsi_context *iscsi

[Qemu-block] [PULL 75/76] block: extract bdrv_setup_io_funcs()

2015-04-28 Thread Kevin Wolf
From: Stefan Hajnoczi stefa...@redhat.com Move the code to install coroutine and aio emulation function pointers in a BlockDriver to its own function. Signed-off-by: Stefan Hajnoczi stefa...@redhat.com Signed-off-by: Kevin Wolf kw...@redhat.com --- block.c | 7 ++- include

[Qemu-block] [PULL 66/76] iotests: add QMP event waiting queue

2015-04-28 Thread Kevin Wolf
but no events have occurred. Signed-off-by: John Snow js...@redhat.com Reviewed-by: Max Reitz mre...@redhat.com Reviewed-by: Stefan Hajnoczi stefa...@redhat.com Message-id: 1429314609-29776-19-git-send-email-js...@redhat.com Signed-off-by: Stefan Hajnoczi stefa...@redhat.com Signed-off-by: Kevin Wolf

[Qemu-block] [PULL 17/76] qemu-img convert: Rewrite copying logic

2015-04-28 Thread Kevin Wolf
-by: Kevin Wolf kw...@redhat.com Reviewed-by: Max Reitz mre...@redhat.com --- qemu-img.c | 516 + 1 file changed, 310 insertions(+), 206 deletions(-) diff --git a/qemu-img.c b/qemu-img.c index 9dddfbe..8d30e43 100644 --- a/qemu-img.c +++ b/qemu

[Qemu-block] [PULL 19/76] blkdebug: Add bdrv_truncate()

2015-04-28 Thread Kevin Wolf
This is, amongst others, required for qemu-iotests 033 to run as intended on VHDX, which uses explicit bdrv_truncate() calls to bs-file when allocating new blocks. Signed-off-by: Kevin Wolf kw...@redhat.com Reviewed-by: Jeff Cody jc...@redhat.com --- block/blkdebug.c | 6 ++ 1 file changed

[Qemu-block] [PULL 09/76] omap_intc: convert ffs(3) to ctz32() in omap_inth_sir_update()

2015-04-28 Thread Kevin Wolf
...@redhat.com Signed-off-by: Stefan Hajnoczi stefa...@redhat.com Message-id: 1427124571-28598-8-git-send-email-stefa...@redhat.com Signed-off-by: Kevin Wolf kw...@redhat.com --- hw/intc/omap_intc.c | 9 + 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/hw/intc/omap_intc.c b/hw

[Qemu-block] [PULL 48/76] block/iscsi: use the allocationmap also if cache.direct=on

2015-04-28 Thread Kevin Wolf
with cache.direct=on. Signed-off-by: Peter Lieven p...@kamp.de Message-id: 1429193313-4263-10-git-send-email...@kamp.de Signed-off-by: Stefan Hajnoczi stefa...@redhat.com Signed-off-by: Kevin Wolf kw...@redhat.com --- block/iscsi.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git

[Qemu-block] [PULL 05/76] uninorth: convert ffs(3) to ctz32()

2015-04-28 Thread Kevin Wolf
-email-stefa...@redhat.com Signed-off-by: Kevin Wolf kw...@redhat.com --- hw/pci-host/uninorth.c | 5 - 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/hw/pci-host/uninorth.c b/hw/pci-host/uninorth.c index 53f2b59..f0144eb 100644 --- a/hw/pci-host/uninorth.c +++ b/hw/pci-host

[Qemu-block] [PULL 20/76] vhdx: Fix zero-fill iov length

2015-04-28 Thread Kevin Wolf
-by: Kevin Wolf kw...@redhat.com Acked-by: Jeff Cody jc...@redhat.com --- block/vhdx.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/block/vhdx.c b/block/vhdx.c index bb3ed45..e24062f 100644 --- a/block/vhdx.c +++ b/block/vhdx.c @@ -1269,7 +1269,7 @@ static coroutine_fn int

[Qemu-block] [PULL 21/76] thread-pool: clean up thread_pool_completion_bh()

2015-04-28 Thread Kevin Wolf
. The QLIST_REMOVE() is duplicated down both branches of an if-else statement so that can be lifted out as well. Signed-off-by: Stefan Hajnoczi stefa...@redhat.com Reviewed-by: Paolo Bonzini pbonz...@redhat.com Message-id: 1427992762-10126-1-git-send-email-stefa...@redhat.com Signed-off-by: Kevin Wolf kw

[Qemu-block] [PULL 22/76] scripts: add 'qemu coroutine' command to qemu-gdb.py

2015-04-28 Thread Kevin Wolf
) at coroutine-ucontext.c:80 #3 0x708de000 in __start_context () at /lib64/libc.so.6 Signed-off-by: Stefan Hajnoczi stefa...@redhat.com Message-id: 1427409754-8556-1-git-send-email-stefa...@redhat.com Signed-off-by: Kevin Wolf kw...@redhat.com --- scripts/qemu-gdb.py | 75

[Qemu-block] [PULL 50/76] qapi: Add optional field name to block dirty bitmap

2015-04-28 Thread Kevin Wolf
...@redhat.com Reviewed-by: Max Reitz mre...@redhat.com Reviewed-by: Eric Blake ebl...@redhat.com Reviewed-by: Stefan Hajnoczi stefa...@redhat.com Message-id: 1429314609-29776-3-git-send-email-js...@redhat.com Signed-off-by: Stefan Hajnoczi stefa...@redhat.com Signed-off-by: Kevin Wolf kw...@redhat.com

[Qemu-block] [PULL 44/76] block/iscsi: optimize WRITE10/16 if cache.writeback is not set

2015-04-28 Thread Kevin Wolf
by a FLUSH. This is 2 round trip times. If we set the FUA bit we can ignore the following FLUSH. Signed-off-by: Peter Lieven p...@kamp.de Message-id: 1429193313-4263-6-git-send-email...@kamp.de Signed-off-by: Stefan Hajnoczi stefa...@redhat.com Signed-off-by: Kevin Wolf kw...@redhat.com --- block

[Qemu-block] [PULL 72/76] vmdk: Widen before shifting 32 bit header field

2015-04-28 Thread Kevin Wolf
From: Fam Zheng f...@redhat.com Coverity spotted this. The field is 32 bits, but if it's possible to overflow in 32 bit left shift. Signed-off-by: Fam Zheng f...@redhat.com Reviewed-by: John Snow js...@redhat.com Signed-off-by: Kevin Wolf kw...@redhat.com --- block/vmdk.c | 2 +- 1 file

[Qemu-block] [PULL 71/76] block/dmg: make it modular

2015-04-28 Thread Kevin Wolf
From: Michael Tokarev m...@tls.msk.ru dmg can optionally utilize libbz2, make it modular Signed-off-by: Michael Tokarev m...@tls.msk.ru Reviewed-by: Paolo Bonzini pbonz...@redhat.com Signed-off-by: Kevin Wolf kw...@redhat.com --- block/Makefile.objs | 3 ++- 1 file changed, 2 insertions(+), 1

[Qemu-block] [PULL 74/76] block: add bdrv_set_dirty()/bdrv_reset_dirty() to block_int.h

2015-04-28 Thread Kevin Wolf
From: Stefan Hajnoczi stefa...@redhat.com The dirty bitmap functions are called from the block I/O processing code. Make them visible to block_int.h users so they can be used outside block.c. Signed-off-by: Stefan Hajnoczi stefa...@redhat.com Signed-off-by: Kevin Wolf kw...@redhat.com

[Qemu-block] [PULL 14/76] AioContext: acquire/release AioContext during aio_poll

2015-04-28 Thread Kevin Wolf
-email-pbonz...@redhat.com Signed-off-by: Stefan Hajnoczi stefa...@redhat.com Signed-off-by: Kevin Wolf kw...@redhat.com --- aio-posix.c | 9 + aio-win32.c | 8 include/block/aio.h | 13 +++-- 3 files changed, 24 insertions(+), 6 deletions(-) diff --git

[Qemu-block] [PULL 10/76] os-win32: drop ffs(3) prototype

2015-04-28 Thread Kevin Wolf
to ctz32() there is no need for ffs(3). Signed-off-by: Stefan Hajnoczi stefa...@redhat.com Message-id: 1427124571-28598-9-git-send-email-stefa...@redhat.com Signed-off-by: Kevin Wolf kw...@redhat.com --- include/sysemu/os-win32.h | 3 --- 1 file changed, 3 deletions(-) diff --git a/include/sysemu

[Qemu-block] [PULL 25/76] MAINTAINERS: Add Fam Zheng as Null block driver maintainer

2015-04-28 Thread Kevin Wolf
From: Fam Zheng f...@redhat.com Signed-off-by: Fam Zheng f...@redhat.com Reviewed-by: Eric Blake ebl...@redhat.com Reviewed-by: Stefan Hajnoczi stefa...@redhat.com Message-id: 1427852740-24315-4-git-send-email-f...@redhat.com Signed-off-by: Stefan Hajnoczi stefa...@redhat.com Signed-off-by: Kevin

[Qemu-block] [PULL 35/76] block: add bdrv_get_device_or_node_name()

2015-04-28 Thread Kevin Wolf
: 4fa30aa8d61d9052ce266fd5429a59a14e941255.1428485266.git.be...@igalia.com Signed-off-by: Stefan Hajnoczi stefa...@redhat.com Signed-off-by: Kevin Wolf kw...@redhat.com --- block.c | 9 + block/quorum.c| 5 + include/block/block.h | 1 + 3 files changed, 11

[Qemu-block] [PULL 24/76] block/null: Support reopen

2015-04-28 Thread Kevin Wolf
-by: Eric Blake ebl...@redhat.com Reviewed-by: Stefan Hajnoczi stefa...@redhat.com Message-id: 1427852740-24315-3-git-send-email-f...@redhat.com Signed-off-by: Stefan Hajnoczi stefa...@redhat.com Signed-off-by: Kevin Wolf kw...@redhat.com --- block/null.c | 8 1 file changed, 8 insertions

[Qemu-block] [PULL 34/76] block: document block-stream in qmp-commands.hx

2015-04-28 Thread Kevin Wolf
-by: Stefan Hajnoczi stefa...@redhat.com Reviewed-by: Eric Blake ebl...@redhat.com Reviewed-by: Max Reitz mre...@redhat.com Message-id: 1429094622-26218-1-git-send-email-stefa...@redhat.com Signed-off-by: Kevin Wolf kw...@redhat.com --- qmp-commands.hx | 37 + 1 file

[Qemu-block] [PULL 68/76] iotests: add incremental backup failure recovery test

2015-04-28 Thread Kevin Wolf
-by: Stefan Hajnoczi stefa...@redhat.com Signed-off-by: Kevin Wolf kw...@redhat.com --- tests/qemu-iotests/124 | 57 ++ tests/qemu-iotests/124.out | 4 ++-- 2 files changed, 59 insertions(+), 2 deletions(-) diff --git a/tests/qemu-iotests/124 b/tests/qemu

[Qemu-block] [PULL 73/76] block: replace bdrv_states iteration with bdrv_next()

2015-04-28 Thread Kevin Wolf
to the public bdrv_next() interface. Reviewed-by: Alberto Garcia be...@igalia.com Signed-off-by: Stefan Hajnoczi stefa...@redhat.com Signed-off-by: Kevin Wolf kw...@redhat.com --- block.c | 14 -- 1 file changed, 8 insertions(+), 6 deletions(-) diff --git a/block.c b/block.c index ec23594

[Qemu-block] [PULL 63/76] block: Resize bitmaps on bdrv_truncate

2015-04-28 Thread Kevin Wolf
-by: Kevin Wolf kw...@redhat.com --- block.c| 18 ++ include/qemu/hbitmap.h | 10 ++ util/hbitmap.c | 48 3 files changed, 76 insertions(+) diff --git a/block.c b/block.c index b7d6df5..ec23594 100644

[Qemu-block] [PULL 70/76] block/mirror: Always call block_job_sleep_ns()

2015-04-28 Thread Kevin Wolf
-by: Max Reitz mre...@redhat.com Reviewed-by: Fam Zheng f...@redhat.com Reviewed-by: Paolo Bonzini pbonz...@redhat.com Signed-off-by: Kevin Wolf kw...@redhat.com --- block/mirror.c | 3 --- 1 file changed, 3 deletions(-) diff --git a/block/mirror.c b/block/mirror.c index d53e60e..58f391a 100644

[Qemu-block] [PULL 62/76] block: Ensure consistent bitmap function prototypes

2015-04-28 Thread Kevin Wolf
-email-js...@redhat.com Signed-off-by: Stefan Hajnoczi stefa...@redhat.com Signed-off-by: Kevin Wolf kw...@redhat.com --- block.c | 13 ++--- block/backup.c| 2 +- block/mirror.c| 26 ++ blockdev.c| 2 +- include/block

[Qemu-block] [PULL 69/76] iotests: add incremental backup granularity tests

2015-04-28 Thread Kevin Wolf
-by: Stefan Hajnoczi stefa...@redhat.com Signed-off-by: Kevin Wolf kw...@redhat.com --- tests/qemu-iotests/124 | 58 +- tests/qemu-iotests/124.out | 4 ++-- 2 files changed, 49 insertions(+), 13 deletions(-) diff --git a/tests/qemu-iotests/124 b/tests

Re: [Qemu-block] [Qemu-devel] Question about block driver

2015-04-30 Thread Kevin Wolf
Am 30.04.2015 um 11:43 hat Wen Congyang geschrieben: On 04/30/2015 05:33 PM, Kevin Wolf wrote: [Cc: qemu-block] Am 30.04.2015 um 11:11 hat Wen Congyang geschrieben: Some drivers use bdrv_open, while the other dirvers use bdrv_file_open(). What is the difference between bdrv_open

Re: [Qemu-block] [Qemu-devel] Question about block driver

2015-04-30 Thread Kevin Wolf
[Cc: qemu-block] Am 30.04.2015 um 11:11 hat Wen Congyang geschrieben: Some drivers use bdrv_open, while the other dirvers use bdrv_file_open(). What is the difference between bdrv_open() and bdrv_file_open()? bdrv_file_open() is used by protocol drivers that don't need any other driver to work

Re: [Qemu-block] [PATCH] Enable NVMe start controller for Windows guest.

2015-04-30 Thread Kevin Wolf
[Cc: qemu-block] Am 24.04.2015 um 21:19 hat Keith Busch geschrieben: On Fri, 24 Apr 2015, Daniel Stekloff wrote: Windows seems to send two separate calls to NVMe controller configuration. The first sends configuration info and the second the enable bit. I couldn't enable the Windows 8.1

[Qemu-block] [PULL 6/7] MAINTAINERS: Add qemu-block list where missing

2015-04-30 Thread Kevin Wolf
Signed-off-by: Kevin Wolf kw...@redhat.com --- MAINTAINERS | 6 ++ 1 file changed, 6 insertions(+) diff --git a/MAINTAINERS b/MAINTAINERS index 25fd2b5..0b67c48 100644 --- a/MAINTAINERS +++ b/MAINTAINERS @@ -735,12 +735,14 @@ F: backends/rng*.c nvme M: Keith Busch keith.bu...@intel.com

[Qemu-block] [PULL 5/7] MAINTAINERS: make block layer core Kevin Wolf's responsibility

2015-04-30 Thread Kevin Wolf
From: Stefan Hajnoczi stefa...@redhat.com Kevin is now sole maintainer of the core block layer, including BlockDriverState graphs and monitor commands. Signed-off-by: Stefan Hajnoczi stefa...@redhat.com Signed-off-by: Kevin Wolf kw...@redhat.com --- MAINTAINERS | 4 +--- 1 file changed, 1

[Qemu-block] [PULL 7/7] Enable NVMe start controller for Windows guest.

2015-04-30 Thread Kevin Wolf
devices. Signed-off-by: Daniel Stekloff d...@wendan.org Acked-by: Keith Busch keith.bu...@intel.com Signed-off-by: Kevin Wolf kw...@redhat.com --- hw/block/nvme.c | 7 +++ 1 file changed, 7 insertions(+) diff --git a/hw/block/nvme.c b/hw/block/nvme.c index 1e07166..ad988d7 100644 --- a/hw

[Qemu-block] [PULL 0/7] Block patches

2015-04-30 Thread Kevin Wolf
(1): Enable NVMe start controller for Windows guest. Kevin Wolf (1): MAINTAINERS: Add qemu-block list where missing Stefan Hajnoczi (5): MAINTAINERS: make virtio-blk Stefan Hajnoczi's responsibility MAINTAINERS: split out image formats MAINTAINERS: make block I/O path

[Qemu-block] [PULL 2/7] MAINTAINERS: split out image formats

2015-04-30 Thread Kevin Wolf
From: Stefan Hajnoczi stefa...@redhat.com Block driver submaintainers has proven to be a good model. Kevin and Stefan are splitting up the unclaimed block drivers so each has a dedicated maintainer. Signed-off-by: Stefan Hajnoczi stefa...@redhat.com Signed-off-by: Kevin Wolf kw...@redhat.com

[Qemu-block] [PULL 3/7] MAINTAINERS: make block I/O path Stefan Hajnoczi's responsibility

2015-04-30 Thread Kevin Wolf
...@redhat.com Signed-off-by: Kevin Wolf kw...@redhat.com --- MAINTAINERS | 13 ++--- 1 file changed, 10 insertions(+), 3 deletions(-) diff --git a/MAINTAINERS b/MAINTAINERS index 9cd8761..9e1413e 100644 --- a/MAINTAINERS +++ b/MAINTAINERS @@ -774,12 +774,9 @@ Block M: Kevin Wolf kw

[Qemu-block] [PULL 1/7] MAINTAINERS: make virtio-blk Stefan Hajnoczi's responsibility

2015-04-30 Thread Kevin Wolf
From: Stefan Hajnoczi stefa...@redhat.com Cc: Kevin Wolf kw...@redhat.com Signed-off-by: Stefan Hajnoczi stefa...@redhat.com Signed-off-by: Kevin Wolf kw...@redhat.com --- MAINTAINERS | 5 - 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/MAINTAINERS b/MAINTAINERS index b5ab755

[Qemu-block] [PULL 4/7] MAINTAINERS: make image fuzzer Stefan Hajnoczi's responsibility

2015-04-30 Thread Kevin Wolf
From: Stefan Hajnoczi stefa...@redhat.com Signed-off-by: Stefan Hajnoczi stefa...@redhat.com Signed-off-by: Kevin Wolf kw...@redhat.com --- MAINTAINERS | 7 ++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/MAINTAINERS b/MAINTAINERS index 9e1413e..65a5cc5 100644

Re: [Qemu-block] [Qemu-devel] [PATCH 1/1] vl.c: Since the help says that 'disk_image' is a raw hard disk image, pass format=raw

2015-05-04 Thread Kevin Wolf
Am 01.05.2015 um 01:28 hat Don Slutz geschrieben: On 04/30/15 16:15, Kevin Wolf wrote: Am 30.04.2015 um 21:15 hat Eric Blake geschrieben: [adding qemu-block] On 04/30/2015 12:23 PM, Don Slutz wrote: ~/qemu/out/master/x86_64-softmmu/qemu-system-x86_64 -h | head QEMU emulator version

Re: [Qemu-block] [PATCH v3 3/9] libqos: Add migration helpers

2015-05-04 Thread Kevin Wolf
Am 30.04.2015 um 20:07 hat John Snow geschrieben: libqos.c: -set_context for addressing which commands go where -migrate performs the actual migration malloc.c: - Structure of the allocator is adjusted slightly with a second-tier malloc to make swapping around the

Re: [Qemu-block] [PATCH v3 0/9] ahci: enable migration

2015-05-04 Thread Kevin Wolf
of migration tests to ahci-test Reviewed-by: Kevin Wolf kw...@redhat.com I think besides the NCQ tests, we'll definitely also want to test migration with READ DMA in flight (this series tests only WRITE DMA and FLUSH CACHE). Probably also discard. Nice to have, but less important, would

Re: [Qemu-block] [Qemu-devel] [PATCH 1/1] vl.c: Since the help says that 'disk_image' is a raw hard disk image, pass format=raw

2015-05-04 Thread Kevin Wolf
Am 04.05.2015 um 15:39 hat Markus Armbruster geschrieben: Kevin Wolf kw...@redhat.com writes: Am 01.05.2015 um 01:28 hat Don Slutz geschrieben: [...] So do you want a more complex patch that allows the format to be specified? Only for 'disk_image'? Include -hd* ? I'm afraid

[Qemu-block] [PULL 16/76] block-backend: Expose bdrv_write_zeroes()

2015-04-28 Thread Kevin Wolf
Signed-off-by: Kevin Wolf kw...@redhat.com Reviewed-by: Max Reitz mre...@redhat.com --- block/block-backend.c | 11 +++ include/sysemu/block-backend.h | 2 ++ 2 files changed, 13 insertions(+) diff --git a/block/block-backend.c b/block/block-backend.c index 48b6e4c..93e46f3

[Qemu-block] [PULL 08/76] sd: convert sd_normal_command() ffs(3) call to ctz32()

2015-04-28 Thread Kevin Wolf
: 1427124571-28598-7-git-send-email-stefa...@redhat.com Signed-off-by: Kevin Wolf kw...@redhat.com --- hw/sd/sd.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/hw/sd/sd.c b/hw/sd/sd.c index f955265..8abf0c9 100644 --- a/hw/sd/sd.c +++ b/hw/sd/sd.c @@ -796,8 +796,9 @@ static

[Qemu-block] [PULL 12/76] block: Switch to host monotonic clock for IO throttling

2015-04-28 Thread Kevin Wolf
...@redhat.com Reviewed-by: Alberto Garcia be...@igalia.com Signed-off-by: Fam Zheng f...@redhat.com Message-id: 1427268446-6426-1-git-send-email-f...@redhat.com Signed-off-by: Stefan Hajnoczi stefa...@redhat.com Signed-off-by: Kevin Wolf kw...@redhat.com --- block.c | 9 - 1 file changed, 8

[Qemu-block] [PULL 36/76] block: use bdrv_get_device_or_node_name() in error messages

2015-04-28 Thread Kevin Wolf
: 9823a1f0514fdb0692e92868661c38a9e00a12d6.1428485266.git.be...@igalia.com Signed-off-by: Stefan Hajnoczi stefa...@redhat.com Signed-off-by: Kevin Wolf kw...@redhat.com --- block.c | 24 block/qcow.c | 8 block/qcow2.c | 2 +- block/qed.c

[Qemu-block] [PULL 49/76] docs: incremental backup documentation

2015-04-28 Thread Kevin Wolf
From: John Snow js...@redhat.com Signed-off-by: John Snow js...@redhat.com Reviewed-by: Max Reitz mre...@redhat.com Reviewed-by: Eric Blake ebl...@redhat.com Message-id: 1429314609-29776-2-git-send-email-js...@redhat.com Signed-off-by: Stefan Hajnoczi stefa...@redhat.com Signed-off-by: Kevin Wolf

[Qemu-block] [PULL 37/76] block: add 'node-name' field to BLOCK_IMAGE_CORRUPTED

2015-04-28 Thread Kevin Wolf
-id: 147cec5b3594f4bec0cb41c98afe5fcbfb67567c.1428485266.git.be...@igalia.com Signed-off-by: Stefan Hajnoczi stefa...@redhat.com Signed-off-by: Kevin Wolf kw...@redhat.com --- block/qcow2.c | 8 ++-- docs/qmp/qmp-events.txt | 21 + qapi/block-core.json| 17

[Qemu-block] [PULL 67/76] iotests: add simple incremental backup case

2015-04-28 Thread Kevin Wolf
-by: Kevin Wolf kw...@redhat.com --- tests/qemu-iotests/124 | 174 +++-- tests/qemu-iotests/124.out | 4 +- 2 files changed, 172 insertions(+), 6 deletions(-) diff --git a/tests/qemu-iotests/124 b/tests/qemu-iotests/124 index 85675ec..5c3b434 100644

Re: [Qemu-block] [Qemu-devel] qemu-img convert (vmdk)

2015-05-06 Thread Kevin Wolf
Am 05.05.2015 um 19:01 hat Antoni Villalonga geschrieben: Hi, Is my first email to that list ;) I can reproduce this bug with v2.2 and v2.3. I'm not sure about the results after testing with v2.1 (doesn't show errors but seems to be still broken). % qemu-img convert -f raw -O vmdk -o

[Qemu-block] [PATCH] qcow2: Flush pending discards before allocating cluster

2015-05-06 Thread Kevin Wolf
allocations. However, the discard/write zeroes operation itself can allocate a new L2 table (and it has to in order to put zero flags there), so make sure we can cope with the situation. This fixes https://bugs.launchpad.net/bugs/1349972. Signed-off-by: Kevin Wolf kw...@redhat.com --- block

Re: [Qemu-block] [Qemu-devel] [PATCH v2 0/3] block: Warn about usage of growing formats over non-growable protocols

2015-05-07 Thread Kevin Wolf
Am 07.05.2015 um 14:47 hat Paolo Bonzini geschrieben: On 07/05/2015 14:29, Kevin Wolf wrote: No, it shouldn't indeed. Could alloc_clusters_noref do bdrv_truncate and return ENOSPC if it fails? That's how for example qcow and vhdx work. vdi has the same problem. If you

Re: [Qemu-block] [Qemu-devel] [PATCH] nvme: support NVME_VOLATILE_WRITE_CACHE feature

2015-05-07 Thread Kevin Wolf
[ Cc: qemu-block ] Am 30.04.2015 um 16:03 hat Keith Busch geschrieben: On Thu, 30 Apr 2015, Christoph Hellwig wrote: The SCSI emulation in the Linux NVMe driver really wants to know if a device has a volatile write cache. Given that qemu has moved away from a model where we report the

Re: [Qemu-block] [PATCH] qcow2: Flush pending discards before allocating cluster

2015-05-08 Thread Kevin Wolf
Am 06.05.2015 um 13:29 hat Kevin Wolf geschrieben: Before a freed cluster can be reused, pending discards for this cluster must be processed. The original assumption was that this was not a problem because discards are only cached during discard/write zeroes operations, which

Re: [Qemu-block] [PATCH] qcow2: do lazy allocation of the L2 cache

2015-05-08 Thread Kevin Wolf
Am 08.05.2015 um 11:00 hat Alberto Garcia geschrieben: On Fri 24 Apr 2015 03:04:06 PM CEST, Kevin Wolf kw...@redhat.com wrote: I think it would be nice to have a way to free unused cache entries after a while. Do you think mmap plus a periodic timer would work? I'm hesitant

Re: [Qemu-block] [PATCH] vmdk: Fix next_cluster_sector for compressed write

2015-05-08 Thread Kevin Wolf
Am 06.05.2015 um 20:01 hat Max Reitz geschrieben: On 06.05.2015 14:23, Fam Zheng wrote: This fixes the bug introduced by commit c6ac36e (vmdk: Optimize cluster allocation). Sometimes, write_len could be larger than cluster size, because it contains both data and marker. We must advance

[Qemu-block] [PATCH 25/34] block: Allow specifying child options in reopen

2015-05-08 Thread Kevin Wolf
If the child was defined in the same context (-drive argument or blockdev-add QMP command) as its parent, a reopen of the parent should work the same and allow changing options of the child. Signed-off-by: Kevin Wolf kw...@redhat.com --- block.c | 12 ++-- 1 file changed, 10 insertions

[Qemu-block] [PATCH 33/34] qemu-iotests: Test cache mode option inheritance

2015-05-08 Thread Kevin Wolf
. Signed-off-by: Kevin Wolf kw...@redhat.com --- tests/qemu-iotests/132 | 336 tests/qemu-iotests/132.out | 767 + tests/qemu-iotests/group | 1 + 3 files changed, 1104 insertions(+) create mode 100755 tests/qemu-iotests/132

[Qemu-block] [PATCH 09/34] block: Add BlockDriverState.inherits_from

2015-05-08 Thread Kevin Wolf
be created separately and not inherit flags from any parent. To handle reopens correctly, a node must know from which parent it inherited options. This patch adds the information to BlockDriverState. Signed-off-by: Kevin Wolf kw...@redhat.com --- block.c | 17 + include

[Qemu-block] [PATCH 31/34] block: Move cache options into options QDict

2015-05-08 Thread Kevin Wolf
precedence. Child node inherit cache modes as options now, they don't use flags any more. Signed-off-by: Kevin Wolf kw...@redhat.com --- block.c| 85 +++--- blockdev.c | 27 +--- 2 files changed, 88 insertions(+), 24

[Qemu-block] [PATCH 12/34] block: Allow specifying driver-specific options to reopen

2015-05-08 Thread Kevin Wolf
Signed-off-by: Kevin Wolf kw...@redhat.com --- block.c | 42 +++--- block/commit.c| 4 ++-- include/block/block.h | 4 +++- 3 files changed, 44 insertions(+), 6 deletions(-) diff --git a/block.c b/block.c index 95dc51e..561cefd 100644

[Qemu-block] [PATCH 00/34] block: Cache mode for children, reopen overhaul and more

2015-05-08 Thread Kevin Wolf
of it) - And finally you can set cache mode options for backing files and other children now (and the reopen behaviour even makes sense) Kevin Wolf (34): qdict: Add qdict_array_entries() qdict: Add qdict_{set,copy}_default() quorum: Use bdrv_open_image() vmdk: Use bdrv_open_image() block: Use macro

[Qemu-block] [PATCH 01/34] qdict: Add qdict_array_entries()

2015-05-08 Thread Kevin Wolf
Signed-off-by: Kevin Wolf kw...@redhat.com --- include/qapi/qmp/qdict.h | 1 + qobject/qdict.c | 68 +--- 2 files changed, 65 insertions(+), 4 deletions(-) diff --git a/include/qapi/qmp/qdict.h b/include/qapi/qmp/qdict.h index d68f4eb

[Qemu-block] [PATCH 02/34] qdict: Add qdict_{set,copy}_default()

2015-05-08 Thread Kevin Wolf
for each option. Signed-off-by: Kevin Wolf kw...@redhat.com --- include/qapi/qmp/qdict.h | 3 +++ qobject/qdict.c | 34 ++ 2 files changed, 37 insertions(+) diff --git a/include/qapi/qmp/qdict.h b/include/qapi/qmp/qdict.h index d20db94..9fbf68e 100644

[Qemu-block] [PATCH 21/34] block: Consider all block layer options in append_open_options

2015-05-08 Thread Kevin Wolf
The code already special-cased node-name, which is currently the only option passed in the QDict that isn't driver-specific. Generalise the code to take all general block layer options into consideration. Signed-off-by: Kevin Wolf kw...@redhat.com --- block.c | 26 ++ 1

[Qemu-block] [PATCH 18/34] qcow2: Fix memory leak in qcow2_update_options() error path

2015-05-08 Thread Kevin Wolf
Signed-off-by: Kevin Wolf kw...@redhat.com --- block/qcow2.c | 12 ++-- 1 file changed, 10 insertions(+), 2 deletions(-) diff --git a/block/qcow2.c b/block/qcow2.c index abe22f3..84d6e0f 100644 --- a/block/qcow2.c +++ b/block/qcow2.c @@ -546,8 +546,8 @@ static int qcow2_update_options

[Qemu-block] [PATCH 20/34] qcow2: Support updating driver-specific options in reopen

2015-05-08 Thread Kevin Wolf
For updating the cache sizes or disabling lazy refcounts there is a bit more to do than just changing the variables, but otherwise we're all set for changing options during bdrv_reopen(). Just implement the missing pieces and hook the functions up in bdrv_reopen(). Signed-off-by: Kevin Wolf kw

[Qemu-block] [PATCH 19/34] qcow2: Make qcow2_update_options() suitable for transactions

2015-05-08 Thread Kevin Wolf
Before we can allow updating options at runtime with bdrv_reopen(), we need to split the function into prepare/commit/abort parts. Signed-off-by: Kevin Wolf kw...@redhat.com --- block/qcow2.c | 101 ++ 1 file changed, 67 insertions(+), 34

[Qemu-block] [PATCH 27/34] block: Add infrastructure for option inheritance

2015-05-08 Thread Kevin Wolf
Options are not actually inherited from the parent node yet, but this commit lays the grounds for doing so. Signed-off-by: Kevin Wolf kw...@redhat.com --- block.c | 51 ++- include/block/block_int.h | 3 ++- 2 files changed, 30

[Qemu-block] [PATCH 23/34] block: Pass driver-specific options to .bdrv_refresh_filename()

2015-05-08 Thread Kevin Wolf
. This patch passes an option QDict to the driver that contains only driver-specific options, i.e. the options for the general block layer as well as child nodes are already filtered out. Works much better this way. Signed-off-by: Kevin Wolf kw...@redhat.com --- block.c | 5 - block

[Qemu-block] [PATCH 29/34] qemu-iotests: Remove cache mode test without medium

2015-05-08 Thread Kevin Wolf
. Later patches will make it an error to specify the cache mode for an empty drive. Remove the corresponding test case. Signed-off-by: Kevin Wolf kw...@redhat.com --- tests/qemu-iotests/051 | 14 -- tests/qemu-iotests/051.out | 26 -- 2 files changed, 40

  1   2   3   4   5   6   7   8   9   10   >