This replaces all remaining instances in the qcow2 code.
Signed-off-by: Alberto Garcia
---
block/qcow2-cluster.c | 2 +-
block/qcow2.c | 10 ++
2 files changed, 7 insertions(+), 5 deletions(-)
diff --git a/block/qcow2-cluster.c b/block/qcow2-cluster.c
index
The qcow2 header specifies the virtual size of the image in bytes, but
BlockDriverState stores it as a number of 512-byte sectors.
If the user tries to create an image with a size that is not a
multiple of the sector size then this is fixed on creation by
silently rounding the image size up (see
This small series gets rid of all the remaining instances of hardcoded
sector sizes in the qcow2 code and adds a check for images whose
virtual size is not a multiple of the sector size.
See the individual patches for details.
Berto
v2:
- Modify output of iotest 080 to make it easier to
The L1 table is read from disk using the byte-based bdrv_pread() and
is never accessed beyond its last element, so there's no need to
allocate more memory than that.
Signed-off-by: Alberto Garcia
---
block/qcow2-cluster.c | 5 ++---
block/qcow2-refcount.c | 2 +-
block/qcow2-snapshot.c | 3 +--
qcow2_alloc_cluster_offset() and qcow2_get_cluster_offset() always
return offsets that are cluster-aligned so don't just check that they
are sector-aligned.
The check in qcow2_co_preadv_task() is also replaced by an assertion
for the same reason.
Signed-off-by: Alberto Garcia
---
block/qcow2.c
This patch adds a new 'coroutine' flag to QMP command definitions that
tells the QMP dispatcher than the command handler is safe to be run in a
coroutine.
Signed-off-by: Kevin Wolf
---
tests/qapi-schema/qapi-schema-test.json | 1 +
docs/devel/qapi-code-gen.txt| 4
This moves the QMP dispatcher to a coroutine and runs all QMP command
handlers that declare 'coroutine': true in coroutine context so they
can avoid blocking the main loop while doing I/O or waiting for other
events.
For commands that are not declared safe to run in a coroutine, the
dispatcher
block_resize is safe to run in a coroutine, so use it as an example for
the new 'coroutine': true annotation in the QAPI schema.
Signed-off-by: Kevin Wolf
---
qapi/block-core.json | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/qapi/block-core.json b/qapi/block-core.json
Some QMP command handlers can block the main loop for a relatively long
time, for example because they perform some I/O. This is quite nasty.
Allowing such handlers to run in a coroutine where they can yield (and
therefore release the BQL) while waiting for an event such as I/O
completion solves
We want to be able to use qemu_aio_context in the monitor
initialisation.
Signed-off-by: Kevin Wolf
---
vl.c | 10 +-
1 file changed, 5 insertions(+), 5 deletions(-)
diff --git a/vl.c b/vl.c
index 86474a55c9..4c79a00857 100644
--- a/vl.c
+++ b/vl.c
@@ -2903,6 +2903,11 @@ int main(int
On 09/01/2020 16.03, Vladimir Sementsov-Ogievskiy wrote:
> 06.01.2020 20:15, Max Reitz wrote:
>> Misc
>>
>>
>> The Wiki’s TODO list is horribly outdated. What should we do about
>> it? Maybe archive it and start a new one? (Most of the things on the
>> current list are either done or we
06.01.2020 20:15, Max Reitz wrote:
> Misc
>
>
> The Wiki’s TODO list is horribly outdated. What should we do about
> it? Maybe archive it and start a new one? (Most of the things on the
> current list are either done or we don’t want to do anymore.)
May be, create block/TODO.txt
Am 09.01.2020 um 13:30 hat Alberto Garcia geschrieben:
> On Thu 09 Jan 2020 01:19:00 PM CET, Kevin Wolf wrote:
> >> diff --git a/block/qcow2.c b/block/qcow2.c
> >> index e8ce966f7f..6427c75409 100644
> >> --- a/block/qcow2.c
> >> +++ b/block/qcow2.c
> >> @@ -2175,7 +2175,7 @@ static coroutine_fn
On Wed 08 Jan 2020 08:46:11 PM CET, Nir Soffer wrote:
>> However when an image is opened the virtual size is rounded down,
>> which means that trying to access the last few advertised bytes will
>> result in an error. As seen above QEMU cannot create such images and
>> there's no good use case
On Thu 09 Jan 2020 01:19:00 PM CET, Kevin Wolf wrote:
>> diff --git a/block/qcow2.c b/block/qcow2.c
>> index e8ce966f7f..6427c75409 100644
>> --- a/block/qcow2.c
>> +++ b/block/qcow2.c
>> @@ -2175,7 +2175,7 @@ static coroutine_fn int
>> qcow2_co_preadv_task(BlockDriverState *bs,
>>
Am 08.01.2020 um 18:49 hat Alberto Garcia geschrieben:
> This replaces all remaining instances in the qcow2 code.
>
> Signed-off-by: Alberto Garcia
> diff --git a/block/qcow2.c b/block/qcow2.c
> index e8ce966f7f..6427c75409 100644
> --- a/block/qcow2.c
> +++ b/block/qcow2.c
> @@ -2175,7 +2175,7
Am 08.01.2020 um 20:46 hat Nir Soffer geschrieben:
> On Wed, Jan 8, 2020 at 7:52 PM Alberto Garcia wrote:
> >
> > The qcow2 header specifies the virtual size of the image in bytes, but
> > BlockDriverState stores it as a number of 512-byte sectors.
> >
> > If the user tries to create an image
Hi Klaus,
On Thu, 19 Dec 2019 at 13:09, Klaus Jensen wrote:
>
> For now, support the Data Block, Segment and Last Segment descriptor
> types.
>
> See NVM Express 1.3d, Section 4.4 ("Scatter Gather List (SGL)").
>
> Signed-off-by: Klaus Jensen
> Acked-by: Fam Zheng
> ---
> block/nvme.c
Hi Klaus,
On Thu, 19 Dec 2019 at 13:09, Klaus Jensen wrote:
>
> This refactors how the device issues asynchronous block backend
> requests. The NvmeRequest now holds a queue of NvmeAIOs that are
> associated with the command. This allows multiple aios to be issued for
> a command. Only when all
Hi Klaus,
On Thu, 19 Dec 2019 at 13:09, Klaus Jensen wrote:
>
> Handling DMA errors gracefully is required for the device to pass the
> block/011 test ("disable PCI device while doing I/O") in the blktests
> suite.
>
> With this patch the device passes the test by retrying "critical"
> transfers
08.01.2020 1:01, Eric Blake wrote:
> On 12/26/19 2:15 AM, Vladimir Sementsov-Ogievskiy wrote:
>> Don't try to write zero-lenght strings.
>
> length
>
>>
>> Signed-off-by: Vladimir Sementsov-Ogievskiy
>> ---
>> nbd/server.c | 16 ++--
>> 1 file changed, 10 insertions(+), 6
In most qemu-img sub-commands the --object option only makes sense when
there is a filename. qemu-img measure is an exception because objects
may be referenced from the image creation options instead of an existing
image file. Allow --object without a filename.
Signed-off-by: Stefan Hajnoczi
Add qemu-img measure support in the "luks" block driver.
Signed-off-by: Stefan Hajnoczi
---
block/crypto.c | 82 ++
1 file changed, 82 insertions(+)
diff --git a/block/crypto.c b/block/crypto.c
index ed32202fa2..51f37bb1f6 100644
---
This test exercises the block/crypto.c "luks" block driver
.bdrv_measure() code.
Signed-off-by: Stefan Hajnoczi
---
tests/qemu-iotests/282 | 93 ++
tests/qemu-iotests/282.out | 30
tests/qemu-iotests/group | 1 +
3 files changed, 124
The qcow2 .bdrv_measure() code calculates the crypto payload offset.
This logic really belongs in block/crypto.c where it can be reused by
other image formats.
The "luks" block driver will need this same logic in order to implement
.bdrv_measure(), so extract the
v2:
* Fix uint64_t <-> size_t type mismatch in block_crypto_measure() so that
32-bit builds pass
This patch series adds qemu-img measure support to the "luks" block driver. We
just need to take into account the LUKS header when sizing the image.
Stefan Hajnoczi (4):
luks: extract
On Wed, Jan 08, 2020 at 04:16:09AM -0800, no-re...@patchew.org wrote:
> === TEST SCRIPT BEGIN ===
> #! /bin/bash
> export ARCH=x86_64
> make docker-image-fedora V=1 NETWORK=1
> time make docker-test-mingw@fedora J=14 NETWORK=1
> === TEST SCRIPT END ===
>
> CC io/channel-websock.o
> CC
27 matches
Mail list logo