* [PULL 0/4] Block patches
@ 2019-10-08 14:55 Stefan Hajnoczi
2019-10-08 17:21 ` Peter Maydell
0 siblings, 1 reply; 12+ messages in thread
From: Stefan Hajnoczi @ 2019-10-08 14:55 UTC (permalink / raw)
To: qemu-devel
Cc: Fam Zheng, Kevin Wolf, qemu-block, Peter Maydell,
Michael S. Tsirkin, Max Reitz, Stefan Hajnoczi
The following changes since commit 560009f2c8b57b7cdd31a5693ea86ab369382f49:
Merge remote-tracking branch 'remotes/kevin/tags/for-upstream' into staging (2019-10-07 15:40:53 +0100)
are available in the Git repository at:
https://github.com/stefanha/qemu.git tags/block-pull-request
for you to fetch changes up to 4d804b5305ffb4d5fa414c38d4f1bdfb987c8d0b:
iotests/262: Switch source/dest VM launch order (2019-10-08 14:28:25 +0100)
----------------------------------------------------------------
Pull request
This pull request also contains the two commits from the previous pull request
that was dropped due to a mingw compilation error. The compilation should now
be fixed.
----------------------------------------------------------------
Max Reitz (2):
block: Skip COR for inactive nodes
iotests/262: Switch source/dest VM launch order
Sergio Lopez (1):
virtio-blk: schedule virtio_notify_config to run on main context
Vladimir Sementsov-Ogievskiy (1):
util/ioc.c: try to reassure Coverity about qemu_iovec_init_extended
block/io.c | 41 +++++++++++++++++++++++++-------------
hw/block/virtio-blk.c | 16 ++++++++++++++-
util/iov.c | 5 +++--
tests/qemu-iotests/262 | 12 +++++------
tests/qemu-iotests/262.out | 6 +++---
5 files changed, 54 insertions(+), 26 deletions(-)
--
2.21.0
^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: [PULL 0/4] Block patches
2019-10-08 14:55 Stefan Hajnoczi
@ 2019-10-08 17:21 ` Peter Maydell
0 siblings, 0 replies; 12+ messages in thread
From: Peter Maydell @ 2019-10-08 17:21 UTC (permalink / raw)
To: Stefan Hajnoczi
Cc: Fam Zheng, Kevin Wolf, Qemu-block, Michael S. Tsirkin,
QEMU Developers, Max Reitz
On Tue, 8 Oct 2019 at 15:55, Stefan Hajnoczi <stefanha@redhat.com> wrote:
>
> The following changes since commit 560009f2c8b57b7cdd31a5693ea86ab369382f49:
>
> Merge remote-tracking branch 'remotes/kevin/tags/for-upstream' into staging (2019-10-07 15:40:53 +0100)
>
> are available in the Git repository at:
>
> https://github.com/stefanha/qemu.git tags/block-pull-request
>
> for you to fetch changes up to 4d804b5305ffb4d5fa414c38d4f1bdfb987c8d0b:
>
> iotests/262: Switch source/dest VM launch order (2019-10-08 14:28:25 +0100)
>
> ----------------------------------------------------------------
> Pull request
>
> This pull request also contains the two commits from the previous pull request
> that was dropped due to a mingw compilation error. The compilation should now
> be fixed.
>
> ----------------------------------------------------------------
>
Applied, thanks.
Please update the changelog at https://wiki.qemu.org/ChangeLog/4.2
for any user-visible changes.
-- PMM
^ permalink raw reply [flat|nested] 12+ messages in thread
* [PULL 0/4] Block patches
@ 2020-05-01 8:28 Stefan Hajnoczi
2020-05-01 9:02 ` no-reply
2020-05-01 9:32 ` Peter Maydell
0 siblings, 2 replies; 12+ messages in thread
From: Stefan Hajnoczi @ 2020-05-01 8:28 UTC (permalink / raw)
To: qemu-devel
Cc: Kevin Wolf, Laurent Vivier, Thomas Huth, qemu-block,
Peter Maydell, Bandan Das, Markus Armbruster, Juan Quintela,
Peter Lieven, Yuval Shaia, Max Reitz, Alexander Bulekov,
Alex Williamson, Gerd Hoffmann, Stefan Hajnoczi, Paolo Bonzini,
Ronnie Sahlberg, Dr. David Alan Gilbert
The following changes since commit 27c94566379069fb8930bb1433dcffbf7df3203d:
Merge remote-tracking branch 'remotes/edgar/tags/edgar/xilinx-next-2020-04-30.for-upstream' into staging (2020-04-30 16:47:23 +0100)
are available in the Git repository at:
https://github.com/stefanha/qemu.git tags/block-pull-request
for you to fetch changes up to cc1adc4488059ac16d4d2772a7aa7cd1323deeca:
lockable: Replace locks with lock guard macros (2020-05-01 09:19:25 +0100)
----------------------------------------------------------------
Pull request
Fix the QEMU_LOCK_GUARD() macros, use them more widely, and allow the fuzzer
target to be selected from argv[0].
----------------------------------------------------------------
Alexander Bulekov (1):
fuzz: select fuzz target using executable name
Daniel Brodsky (2):
lockable: fix __COUNTER__ macro to be referenced properly
lockable: replaced locks with lock guard macros where appropriate
Simran Singhal (1):
lockable: Replace locks with lock guard macros
include/qemu/lockable.h | 7 +++---
include/qemu/rcu.h | 2 +-
block/iscsi.c | 7 ++----
block/nfs.c | 51 +++++++++++++++++++----------------------
cpus-common.c | 14 ++++-------
hw/display/qxl.c | 43 ++++++++++++++++------------------
hw/hyperv/hyperv.c | 15 ++++++------
hw/rdma/rdma_backend.c | 50 ++++++++++++++++++++--------------------
hw/rdma/rdma_rm.c | 3 +--
hw/vfio/platform.c | 5 ++--
migration/migration.c | 3 +--
migration/multifd.c | 8 +++----
migration/ram.c | 3 +--
monitor/misc.c | 4 +---
tests/qtest/fuzz/fuzz.c | 19 ++++++++-------
ui/spice-display.c | 14 +++++------
util/log.c | 4 ++--
util/qemu-timer.c | 17 +++++++-------
util/rcu.c | 8 +++----
util/thread-pool.c | 3 +--
util/vfio-helpers.c | 5 ++--
slirp | 2 +-
22 files changed, 133 insertions(+), 154 deletions(-)
--
2.25.3
^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: [PULL 0/4] Block patches
2020-05-01 8:28 Stefan Hajnoczi
@ 2020-05-01 9:02 ` no-reply
2020-05-01 9:32 ` Peter Maydell
1 sibling, 0 replies; 12+ messages in thread
From: no-reply @ 2020-05-01 9:02 UTC (permalink / raw)
To: stefanha
Cc: kwolf, lvivier, thuth, alex.williamson, stefanha, qemu-block,
peter.maydell, quintela, pl, qemu-devel, armbru, alxndr, bsd,
kraxel, yuval.shaia.ml, pbonzini, mreitz, ronniesahlberg,
dgilbert
Patchew URL: https://patchew.org/QEMU/20200501082806.205696-1-stefanha@redhat.com/
Hi,
This series failed the docker-quick@centos7 build test. Please find the testing commands and
their output below. If you have Docker installed, you can probably reproduce it
locally.
=== TEST SCRIPT BEGIN ===
#!/bin/bash
make docker-image-centos7 V=1 NETWORK=1
time make docker-test-quick@centos7 SHOW_ENV=1 J=14 NETWORK=1
=== TEST SCRIPT END ===
TEST iotest-qcow2: 074
socket_accept failed: Resource temporarily unavailable
**
ERROR:/tmp/qemu-test/src/tests/qtest/libqtest.c:301:qtest_init_without_qmp_handshake: assertion failed: (s->fd >= 0 && s->qmp_fd >= 0)
/tmp/qemu-test/src/tests/qtest/libqtest.c:166: kill_qemu() tried to terminate QEMU process but encountered exit status 1 (expected 0)
ERROR - Bail out! ERROR:/tmp/qemu-test/src/tests/qtest/libqtest.c:301:qtest_init_without_qmp_handshake: assertion failed: (s->fd >= 0 && s->qmp_fd >= 0)
make: *** [check-qtest-aarch64] Error 1
make: *** Waiting for unfinished jobs....
TEST iotest-qcow2: 079
TEST iotest-qcow2: 080
---
Not run: 259
Failures: 249
Failed 1 of 117 iotests
make: *** [check-tests/check-block.sh] Error 1
Traceback (most recent call last):
File "./tests/docker/docker.py", line 664, in <module>
sys.exit(main())
---
raise CalledProcessError(retcode, cmd)
subprocess.CalledProcessError: Command '['sudo', '-n', 'docker', 'run', '--label', 'com.qemu.instance.uuid=57718c949eb54215807b45721021e7ee', '-u', '1003', '--security-opt', 'seccomp=unconfined', '--rm', '-e', 'TARGET_LIST=', '-e', 'EXTRA_CONFIGURE_OPTS=', '-e', 'V=', '-e', 'J=14', '-e', 'DEBUG=', '-e', 'SHOW_ENV=1', '-e', 'CCACHE_DIR=/var/tmp/ccache', '-v', '/home/patchew2/.cache/qemu-docker-ccache:/var/tmp/ccache:z', '-v', '/var/tmp/patchew-tester-tmp-kc_n7mcq/src/docker-src.2020-05-01-04.40.40.25959:/var/tmp/qemu:z,ro', 'qemu:centos7', '/var/tmp/qemu/run', 'test-quick']' returned non-zero exit status 2.
filter=--filter=label=com.qemu.instance.uuid=57718c949eb54215807b45721021e7ee
make[1]: *** [docker-run] Error 1
make[1]: Leaving directory `/var/tmp/patchew-tester-tmp-kc_n7mcq/src'
make: *** [docker-run-test-quick@centos7] Error 2
real 21m18.481s
user 0m10.757s
The full log is available at
http://patchew.org/logs/20200501082806.205696-1-stefanha@redhat.com/testing.docker-quick@centos7/?type=message.
---
Email generated automatically by Patchew [https://patchew.org/].
Please send your feedback to patchew-devel@redhat.com
^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: [PULL 0/4] Block patches
2020-05-01 8:28 Stefan Hajnoczi
2020-05-01 9:02 ` no-reply
@ 2020-05-01 9:32 ` Peter Maydell
2020-05-01 15:23 ` Stefan Hajnoczi
1 sibling, 1 reply; 12+ messages in thread
From: Peter Maydell @ 2020-05-01 9:32 UTC (permalink / raw)
To: Stefan Hajnoczi
Cc: Kevin Wolf, Laurent Vivier, Thomas Huth, Qemu-block,
Juan Quintela, Bandan Das, Markus Armbruster, Peter Lieven,
QEMU Developers, Max Reitz, Alexander Bulekov, Alex Williamson,
Gerd Hoffmann, Yuval Shaia, Paolo Bonzini, Ronnie Sahlberg,
Dr. David Alan Gilbert
On Fri, 1 May 2020 at 09:28, Stefan Hajnoczi <stefanha@redhat.com> wrote:
>
> The following changes since commit 27c94566379069fb8930bb1433dcffbf7df3203d:
>
> Merge remote-tracking branch 'remotes/edgar/tags/edgar/xilinx-next-2020-04-30.for-upstream' into staging (2020-04-30 16:47:23 +0100)
>
> are available in the Git repository at:
>
> https://github.com/stefanha/qemu.git tags/block-pull-request
>
> for you to fetch changes up to cc1adc4488059ac16d4d2772a7aa7cd1323deeca:
>
> lockable: Replace locks with lock guard macros (2020-05-01 09:19:25 +0100)
>
> ----------------------------------------------------------------
> Pull request
>
> Fix the QEMU_LOCK_GUARD() macros, use them more widely, and allow the fuzzer
> target to be selected from argv[0].
>
> ----------------------------------------------------------------
Hi; this pullreq seems to include a stray change to the slirp
submodule in the "fuzz: select fuzz target using executable name"
commit. Could you fix that and resend, please?
(You might like to include a molly-guard in your pullreq
creation scripts; on my end I catch this sort of thing
when applying with a test like
if git diff master..staging | grep -q 'Subproject commit'; then
# complain and exit unless I used an explicit command
# line option to say I intended to include a submodule update
fi
though I haven't yet put the same test in the script I use
to send pullreqs, for some reason. I guess my workflow now
means I don't tend to accidentally commit submodule changes.)
thanks
-- PMM
^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: [PULL 0/4] Block patches
2020-05-01 9:32 ` Peter Maydell
@ 2020-05-01 15:23 ` Stefan Hajnoczi
0 siblings, 0 replies; 12+ messages in thread
From: Stefan Hajnoczi @ 2020-05-01 15:23 UTC (permalink / raw)
To: Peter Maydell
Cc: Kevin Wolf, Laurent Vivier, Thomas Huth, Qemu-block,
Juan Quintela, Bandan Das, Markus Armbruster, Peter Lieven,
QEMU Developers, Max Reitz, Alexander Bulekov, Alex Williamson,
Gerd Hoffmann, Yuval Shaia, Paolo Bonzini, Ronnie Sahlberg,
Dr. David Alan Gilbert
[-- Attachment #1: Type: text/plain, Size: 1763 bytes --]
On Fri, May 01, 2020 at 10:32:02AM +0100, Peter Maydell wrote:
> On Fri, 1 May 2020 at 09:28, Stefan Hajnoczi <stefanha@redhat.com> wrote:
> >
> > The following changes since commit 27c94566379069fb8930bb1433dcffbf7df3203d:
> >
> > Merge remote-tracking branch 'remotes/edgar/tags/edgar/xilinx-next-2020-04-30.for-upstream' into staging (2020-04-30 16:47:23 +0100)
> >
> > are available in the Git repository at:
> >
> > https://github.com/stefanha/qemu.git tags/block-pull-request
> >
> > for you to fetch changes up to cc1adc4488059ac16d4d2772a7aa7cd1323deeca:
> >
> > lockable: Replace locks with lock guard macros (2020-05-01 09:19:25 +0100)
> >
> > ----------------------------------------------------------------
> > Pull request
> >
> > Fix the QEMU_LOCK_GUARD() macros, use them more widely, and allow the fuzzer
> > target to be selected from argv[0].
> >
> > ----------------------------------------------------------------
>
> Hi; this pullreq seems to include a stray change to the slirp
> submodule in the "fuzz: select fuzz target using executable name"
> commit. Could you fix that and resend, please?
>
> (You might like to include a molly-guard in your pullreq
> creation scripts; on my end I catch this sort of thing
> when applying with a test like
> if git diff master..staging | grep -q 'Subproject commit'; then
> # complain and exit unless I used an explicit command
> # line option to say I intended to include a submodule update
> fi
>
> though I haven't yet put the same test in the script I use
> to send pullreqs, for some reason. I guess my workflow now
> means I don't tend to accidentally commit submodule changes.)
Sorry for the spurious change. Will send a v2!
Stefan
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 488 bytes --]
^ permalink raw reply [flat|nested] 12+ messages in thread
* [PULL 0/4] Block patches
@ 2021-11-02 14:22 Hanna Reitz
2021-11-02 14:22 ` [PULL 1/4] qemu-img: Consistent docs for convert -F Hanna Reitz
` (4 more replies)
0 siblings, 5 replies; 12+ messages in thread
From: Hanna Reitz @ 2021-11-02 14:22 UTC (permalink / raw)
To: qemu-block; +Cc: Kevin Wolf, Peter Maydell, Hanna Reitz, qemu-devel
The following changes since commit 8cb41fda78c7ebde0dd248c6afe1d336efb0de50:
Merge remote-tracking branch 'remotes/philmd/tags/machine-20211101' into staging (2021-11-02 05:53:45 -0400)
are available in the Git repository at:
https://github.com/XanClic/qemu.git tags/pull-block-2021-11-02
for you to fetch changes up to 7da9623cc078229caf07c290e16401ccdb9408d2:
block/vpc: Add a sanity check that fixed-size images have the right type (2021-11-02 12:47:51 +0100)
----------------------------------------------------------------
Emanuele Giuseppe Esposito (1):
pylint: fix errors and warnings generated by tests/qemu-iotests/297
Eric Blake (1):
qemu-img: Consistent docs for convert -F
Thomas Huth (1):
block/vpc: Add a sanity check that fixed-size images have the right
type
Thomas Weißschuh (1):
vmdk: allow specification of tools version
docs/tools/qemu-img.rst | 2 +-
qapi/block-core.json | 3 +++
block/vmdk.c | 24 ++++++++++++++++++++----
block/vpc.c | 3 ++-
qemu-img-cmds.hx | 2 +-
tests/qemu-iotests/129 | 18 +++++++++---------
tests/qemu-iotests/310 | 16 ++++++++--------
tests/qemu-iotests/check | 11 ++++++-----
tests/qemu-iotests/iotests.py | 7 ++++---
tests/qemu-iotests/tests/image-fleecing | 4 ++--
10 files changed, 56 insertions(+), 34 deletions(-)
--
2.31.1
^ permalink raw reply [flat|nested] 12+ messages in thread
* [PULL 1/4] qemu-img: Consistent docs for convert -F
2021-11-02 14:22 [PULL 0/4] Block patches Hanna Reitz
@ 2021-11-02 14:22 ` Hanna Reitz
2021-11-02 14:22 ` [PULL 2/4] pylint: fix errors and warnings generated by tests/qemu-iotests/297 Hanna Reitz
` (3 subsequent siblings)
4 siblings, 0 replies; 12+ messages in thread
From: Hanna Reitz @ 2021-11-02 14:22 UTC (permalink / raw)
To: qemu-block; +Cc: Kevin Wolf, Peter Maydell, Hanna Reitz, qemu-devel
From: Eric Blake <eblake@redhat.com>
Use consistent capitalization, and fix a missed line (we duplicate the
qemu-img synopses in too many places).
Fixes: 1899bf4737 (qemu-img: Add -F shorthand to convert)
Signed-off-by: Eric Blake <eblake@redhat.com>
Message-Id: <20210921142812.2631605-1-eblake@redhat.com>
Reviewed-by: Vladimir Sementsov-Ogievskiy <vsementsov@virtuozzo.com>
Signed-off-by: Hanna Reitz <hreitz@redhat.com>
---
docs/tools/qemu-img.rst | 2 +-
qemu-img-cmds.hx | 2 +-
2 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/docs/tools/qemu-img.rst b/docs/tools/qemu-img.rst
index d58980aef8..c0a4443146 100644
--- a/docs/tools/qemu-img.rst
+++ b/docs/tools/qemu-img.rst
@@ -415,7 +415,7 @@ Command description:
4
Error on reading data
-.. option:: convert [--object OBJECTDEF] [--image-opts] [--target-image-opts] [--target-is-zero] [--bitmaps [--skip-broken-bitmaps]] [-U] [-C] [-c] [-p] [-q] [-n] [-f FMT] [-t CACHE] [-T SRC_CACHE] [-O OUTPUT_FMT] [-B BACKING_FILE [-F backing_fmt]] [-o OPTIONS] [-l SNAPSHOT_PARAM] [-S SPARSE_SIZE] [-r RATE_LIMIT] [-m NUM_COROUTINES] [-W] FILENAME [FILENAME2 [...]] OUTPUT_FILENAME
+.. option:: convert [--object OBJECTDEF] [--image-opts] [--target-image-opts] [--target-is-zero] [--bitmaps [--skip-broken-bitmaps]] [-U] [-C] [-c] [-p] [-q] [-n] [-f FMT] [-t CACHE] [-T SRC_CACHE] [-O OUTPUT_FMT] [-B BACKING_FILE [-F BACKING_FMT]] [-o OPTIONS] [-l SNAPSHOT_PARAM] [-S SPARSE_SIZE] [-r RATE_LIMIT] [-m NUM_COROUTINES] [-W] FILENAME [FILENAME2 [...]] OUTPUT_FILENAME
Convert the disk image *FILENAME* or a snapshot *SNAPSHOT_PARAM*
to disk image *OUTPUT_FILENAME* using format *OUTPUT_FMT*. It can
diff --git a/qemu-img-cmds.hx b/qemu-img-cmds.hx
index 4c4d94ab22..72bcdcfbfa 100644
--- a/qemu-img-cmds.hx
+++ b/qemu-img-cmds.hx
@@ -48,7 +48,7 @@ ERST
DEF("convert", img_convert,
"convert [--object objectdef] [--image-opts] [--target-image-opts] [--target-is-zero] [--bitmaps] [-U] [-C] [-c] [-p] [-q] [-n] [-f fmt] [-t cache] [-T src_cache] [-O output_fmt] [-B backing_file [-F backing_fmt]] [-o options] [-l snapshot_param] [-S sparse_size] [-r rate_limit] [-m num_coroutines] [-W] [--salvage] filename [filename2 [...]] output_filename")
SRST
-.. option:: convert [--object OBJECTDEF] [--image-opts] [--target-image-opts] [--target-is-zero] [--bitmaps] [-U] [-C] [-c] [-p] [-q] [-n] [-f FMT] [-t CACHE] [-T SRC_CACHE] [-O OUTPUT_FMT] [-B BACKING_FILE] [-o OPTIONS] [-l SNAPSHOT_PARAM] [-S SPARSE_SIZE] [-r RATE_LIMIT] [-m NUM_COROUTINES] [-W] [--salvage] FILENAME [FILENAME2 [...]] OUTPUT_FILENAME
+.. option:: convert [--object OBJECTDEF] [--image-opts] [--target-image-opts] [--target-is-zero] [--bitmaps] [-U] [-C] [-c] [-p] [-q] [-n] [-f FMT] [-t CACHE] [-T SRC_CACHE] [-O OUTPUT_FMT] [-B BACKING_FILE [-F BACKING_FMT]] [-o OPTIONS] [-l SNAPSHOT_PARAM] [-S SPARSE_SIZE] [-r RATE_LIMIT] [-m NUM_COROUTINES] [-W] [--salvage] FILENAME [FILENAME2 [...]] OUTPUT_FILENAME
ERST
DEF("create", img_create,
--
2.31.1
^ permalink raw reply related [flat|nested] 12+ messages in thread
* [PULL 2/4] pylint: fix errors and warnings generated by tests/qemu-iotests/297
2021-11-02 14:22 [PULL 0/4] Block patches Hanna Reitz
2021-11-02 14:22 ` [PULL 1/4] qemu-img: Consistent docs for convert -F Hanna Reitz
@ 2021-11-02 14:22 ` Hanna Reitz
2021-11-02 14:22 ` [PULL 3/4] vmdk: allow specification of tools version Hanna Reitz
` (2 subsequent siblings)
4 siblings, 0 replies; 12+ messages in thread
From: Hanna Reitz @ 2021-11-02 14:22 UTC (permalink / raw)
To: qemu-block; +Cc: Kevin Wolf, Peter Maydell, Hanna Reitz, qemu-devel
From: Emanuele Giuseppe Esposito <eesposit@redhat.com>
Test 297 in tests/qemu-iotests currently fails: pylint has
learned new things to check, or we simply missed them.
All fixes in this patch are related to additional spaces used
or wrong indentation. No functional change intended.
Signed-off-by: Emanuele Giuseppe Esposito <eesposit@redhat.com>
Message-Id: <20211008062821.1010967-2-eesposit@redhat.com>
Signed-off-by: Hanna Reitz <hreitz@redhat.com>
---
tests/qemu-iotests/129 | 18 +++++++++---------
tests/qemu-iotests/310 | 16 ++++++++--------
tests/qemu-iotests/check | 11 ++++++-----
tests/qemu-iotests/iotests.py | 7 ++++---
tests/qemu-iotests/tests/image-fleecing | 4 ++--
5 files changed, 29 insertions(+), 27 deletions(-)
diff --git a/tests/qemu-iotests/129 b/tests/qemu-iotests/129
index 5251e2669e..c75ec62ecf 100755
--- a/tests/qemu-iotests/129
+++ b/tests/qemu-iotests/129
@@ -77,8 +77,8 @@ class TestStopWithBlockJob(iotests.QMPTestCase):
self.do_test_stop("drive-backup", device="drive0",
target=self.target_img, format=iotests.imgfmt,
sync="full",
- x_perf={ 'max-chunk': 65536,
- 'max-workers': 8 })
+ x_perf={'max-chunk': 65536,
+ 'max-workers': 8})
def test_block_commit(self):
# Add overlay above the source node so that we actually use a
@@ -88,13 +88,13 @@ class TestStopWithBlockJob(iotests.QMPTestCase):
'1G')
result = self.vm.qmp('blockdev-add', **{
- 'node-name': 'overlay',
- 'driver': iotests.imgfmt,
- 'file': {
- 'driver': 'file',
- 'filename': self.overlay_img
- }
- })
+ 'node-name': 'overlay',
+ 'driver': iotests.imgfmt,
+ 'file': {
+ 'driver': 'file',
+ 'filename': self.overlay_img
+ }
+ })
self.assert_qmp(result, 'return', {})
result = self.vm.qmp('blockdev-snapshot',
diff --git a/tests/qemu-iotests/310 b/tests/qemu-iotests/310
index 9d9c928c4b..33c3411869 100755
--- a/tests/qemu-iotests/310
+++ b/tests/qemu-iotests/310
@@ -48,11 +48,11 @@ with iotests.FilePath('base.img') as base_img_path, \
assert qemu_io_silent(base_img_path, '-c', 'write -P 1 3M 1M') == 0
assert qemu_img('create', '-f', iotests.imgfmt, '-b', base_img_path,
'-F', iotests.imgfmt, mid_img_path) == 0
- assert qemu_io_silent(mid_img_path, '-c', 'write -P 3 2M 1M') == 0
- assert qemu_io_silent(mid_img_path, '-c', 'write -P 3 4M 1M') == 0
+ assert qemu_io_silent(mid_img_path, '-c', 'write -P 3 2M 1M') == 0
+ assert qemu_io_silent(mid_img_path, '-c', 'write -P 3 4M 1M') == 0
assert qemu_img('create', '-f', iotests.imgfmt, '-b', mid_img_path,
'-F', iotests.imgfmt, top_img_path) == 0
- assert qemu_io_silent(top_img_path, '-c', 'write -P 2 1M 1M') == 0
+ assert qemu_io_silent(top_img_path, '-c', 'write -P 2 1M 1M') == 0
# 0 1 2 3 4
# top 2
@@ -108,10 +108,10 @@ with iotests.FilePath('base.img') as base_img_path, \
assert qemu_img('rebase', '-u', '-b', '', '-f', iotests.imgfmt,
top_img_path) == 0
- assert qemu_io_silent(top_img_path, '-c', 'read -P 0 0 1M') == 0
- assert qemu_io_silent(top_img_path, '-c', 'read -P 2 1M 1M') == 0
- assert qemu_io_silent(top_img_path, '-c', 'read -P 3 2M 1M') == 0
- assert qemu_io_silent(top_img_path, '-c', 'read -P 0 3M 1M') == 0
- assert qemu_io_silent(top_img_path, '-c', 'read -P 3 4M 1M') == 0
+ assert qemu_io_silent(top_img_path, '-c', 'read -P 0 0 1M') == 0
+ assert qemu_io_silent(top_img_path, '-c', 'read -P 2 1M 1M') == 0
+ assert qemu_io_silent(top_img_path, '-c', 'read -P 3 2M 1M') == 0
+ assert qemu_io_silent(top_img_path, '-c', 'read -P 0 3M 1M') == 0
+ assert qemu_io_silent(top_img_path, '-c', 'read -P 3 4M 1M') == 0
log('Done')
diff --git a/tests/qemu-iotests/check b/tests/qemu-iotests/check
index da1bfb839e..43a4b694cc 100755
--- a/tests/qemu-iotests/check
+++ b/tests/qemu-iotests/check
@@ -37,13 +37,14 @@ def make_argparser() -> argparse.ArgumentParser:
p.add_argument('-d', dest='debug', action='store_true', help='debug')
p.add_argument('-p', dest='print', action='store_true',
- help='redirects qemu\'s stdout and stderr to the test output')
+ help='redirects qemu\'s stdout and stderr to '
+ 'the test output')
p.add_argument('-gdb', action='store_true',
- help="start gdbserver with $GDB_OPTIONS options \
- ('localhost:12345' if $GDB_OPTIONS is empty)")
+ help="start gdbserver with $GDB_OPTIONS options "
+ "('localhost:12345' if $GDB_OPTIONS is empty)")
p.add_argument('-valgrind', action='store_true',
- help='use valgrind, sets VALGRIND_QEMU environment '
- 'variable')
+ help='use valgrind, sets VALGRIND_QEMU environment '
+ 'variable')
p.add_argument('-misalign', action='store_true',
help='misalign memory allocations')
diff --git a/tests/qemu-iotests/iotests.py b/tests/qemu-iotests/iotests.py
index e2f9d873ad..83bfedb902 100644
--- a/tests/qemu-iotests/iotests.py
+++ b/tests/qemu-iotests/iotests.py
@@ -621,7 +621,7 @@ def _post_shutdown(self) -> None:
super()._post_shutdown()
if not qemu_valgrind or not self._popen:
return
- valgrind_filename = f"{test_dir}/{self._popen.pid}.valgrind"
+ valgrind_filename = f"{test_dir}/{self._popen.pid}.valgrind"
if self.exitcode() == 99:
with open(valgrind_filename, encoding='utf-8') as f:
print(f.read())
@@ -1363,8 +1363,9 @@ def write(self, arg=None):
class ReproducibleTestRunner(unittest.TextTestRunner):
def __init__(self, stream: Optional[TextIO] = None,
- resultclass: Type[unittest.TestResult] = ReproducibleTestResult,
- **kwargs: Any) -> None:
+ resultclass: Type[unittest.TestResult] =
+ ReproducibleTestResult,
+ **kwargs: Any) -> None:
rstream = ReproducibleStreamWrapper(stream or sys.stdout)
super().__init__(stream=rstream, # type: ignore
descriptions=True,
diff --git a/tests/qemu-iotests/tests/image-fleecing b/tests/qemu-iotests/tests/image-fleecing
index 35164e9036..a58b5a1781 100755
--- a/tests/qemu-iotests/tests/image-fleecing
+++ b/tests/qemu-iotests/tests/image-fleecing
@@ -115,8 +115,8 @@ def do_test(use_cbw, base_img_path, fleece_img_path, nbd_sock_path, vm):
nbd_uri = 'nbd+unix:///%s?socket=%s' % (tmp_node, nbd_sock_path)
log(vm.qmp('nbd-server-start',
- {'addr': { 'type': 'unix',
- 'data': { 'path': nbd_sock_path } } }))
+ {'addr': {'type': 'unix',
+ 'data': {'path': nbd_sock_path}}}))
log(vm.qmp('nbd-server-add', device=tmp_node))
--
2.31.1
^ permalink raw reply related [flat|nested] 12+ messages in thread
* [PULL 3/4] vmdk: allow specification of tools version
2021-11-02 14:22 [PULL 0/4] Block patches Hanna Reitz
2021-11-02 14:22 ` [PULL 1/4] qemu-img: Consistent docs for convert -F Hanna Reitz
2021-11-02 14:22 ` [PULL 2/4] pylint: fix errors and warnings generated by tests/qemu-iotests/297 Hanna Reitz
@ 2021-11-02 14:22 ` Hanna Reitz
2021-11-02 14:22 ` [PULL 4/4] block/vpc: Add a sanity check that fixed-size images have the right type Hanna Reitz
2021-11-03 4:31 ` [PULL 0/4] Block patches Richard Henderson
4 siblings, 0 replies; 12+ messages in thread
From: Hanna Reitz @ 2021-11-02 14:22 UTC (permalink / raw)
To: qemu-block; +Cc: Kevin Wolf, Peter Maydell, Hanna Reitz, qemu-devel
From: Thomas Weißschuh <thomas.weissschuh.ext@zeiss.com>
VMDK files support an attribute that represents the version of the guest
tools that are installed on the disk.
This attribute is used by vSphere before a machine has been started to
determine if the VM has the guest tools installed.
This is important when configuring "Operating system customizations" in
vSphere, as it checks for the presence of the guest tools before
allowing those customizations.
Thus when the VM has not yet booted normally it would be impossible to
customize it, therefore preventing a customized first-boot.
The attribute should not hurt on disks that do not have the guest tools
installed and indeed the VMware tools also unconditionally add this
attribute.
(Defaulting to the value "2147483647", as is done in this patch)
Signed-off-by: Thomas Weißschuh <thomas.weissschuh.ext@zeiss.com>
Message-Id: <20210913130419.13241-1-thomas.weissschuh.ext@zeiss.com>
[hreitz: Added missing '#' in block-core.json]
Signed-off-by: Hanna Reitz <hreitz@redhat.com>
---
qapi/block-core.json | 3 +++
block/vmdk.c | 24 ++++++++++++++++++++----
2 files changed, 23 insertions(+), 4 deletions(-)
diff --git a/qapi/block-core.json b/qapi/block-core.json
index ce2c1352cb..69698a4ffe 100644
--- a/qapi/block-core.json
+++ b/qapi/block-core.json
@@ -4691,6 +4691,8 @@
# @adapter-type: The adapter type used to fill in the descriptor. Default: ide.
# @hwversion: Hardware version. The meaningful options are "4" or "6".
# Default: "4".
+# @toolsversion: VMware guest tools version.
+# Default: "2147483647" (Since 6.2)
# @zeroed-grain: Whether to enable zeroed-grain feature for sparse subformats.
# Default: false.
#
@@ -4704,6 +4706,7 @@
'*backing-file': 'str',
'*adapter-type': 'BlockdevVmdkAdapterType',
'*hwversion': 'str',
+ '*toolsversion': 'str',
'*zeroed-grain': 'bool' } }
diff --git a/block/vmdk.c b/block/vmdk.c
index fb4cc9da90..0dfab6e941 100644
--- a/block/vmdk.c
+++ b/block/vmdk.c
@@ -60,6 +60,7 @@
#define VMDK_ZEROED (-3)
#define BLOCK_OPT_ZEROED_GRAIN "zeroed_grain"
+#define BLOCK_OPT_TOOLSVERSION "toolsversion"
typedef struct {
uint32_t version;
@@ -2344,6 +2345,7 @@ static int coroutine_fn vmdk_co_do_create(int64_t size,
BlockdevVmdkAdapterType adapter_type,
const char *backing_file,
const char *hw_version,
+ const char *toolsversion,
bool compat6,
bool zeroed_grain,
vmdk_create_extent_fn extent_fn,
@@ -2384,7 +2386,8 @@ static int coroutine_fn vmdk_co_do_create(int64_t size,
"ddb.geometry.cylinders = \"%" PRId64 "\"\n"
"ddb.geometry.heads = \"%" PRIu32 "\"\n"
"ddb.geometry.sectors = \"63\"\n"
- "ddb.adapterType = \"%s\"\n";
+ "ddb.adapterType = \"%s\"\n"
+ "ddb.toolsVersion = \"%s\"\n";
ext_desc_lines = g_string_new(NULL);
@@ -2401,6 +2404,9 @@ static int coroutine_fn vmdk_co_do_create(int64_t size,
if (!hw_version) {
hw_version = "4";
}
+ if (!toolsversion) {
+ toolsversion = "2147483647";
+ }
if (adapter_type != BLOCKDEV_VMDK_ADAPTER_TYPE_IDE) {
/* that's the number of heads with which vmware operates when
@@ -2525,7 +2531,8 @@ static int coroutine_fn vmdk_co_do_create(int64_t size,
size /
(int64_t)(63 * number_heads * BDRV_SECTOR_SIZE),
number_heads,
- BlockdevVmdkAdapterType_str(adapter_type));
+ BlockdevVmdkAdapterType_str(adapter_type),
+ toolsversion);
desc_len = strlen(desc);
/* the descriptor offset = 0x200 */
if (!split && !flat) {
@@ -2617,6 +2624,7 @@ static int coroutine_fn vmdk_co_create_opts(BlockDriver *drv,
BlockdevVmdkAdapterType adapter_type_enum;
char *backing_file = NULL;
char *hw_version = NULL;
+ char *toolsversion = NULL;
char *fmt = NULL;
BlockdevVmdkSubformat subformat;
int ret = 0;
@@ -2649,6 +2657,7 @@ static int coroutine_fn vmdk_co_create_opts(BlockDriver *drv,
adapter_type = qemu_opt_get_del(opts, BLOCK_OPT_ADAPTER_TYPE);
backing_file = qemu_opt_get_del(opts, BLOCK_OPT_BACKING_FILE);
hw_version = qemu_opt_get_del(opts, BLOCK_OPT_HWVERSION);
+ toolsversion = qemu_opt_get_del(opts, BLOCK_OPT_TOOLSVERSION);
compat6 = qemu_opt_get_bool_del(opts, BLOCK_OPT_COMPAT6, false);
if (strcmp(hw_version, "undefined") == 0) {
g_free(hw_version);
@@ -2692,14 +2701,15 @@ static int coroutine_fn vmdk_co_create_opts(BlockDriver *drv,
.opts = opts,
};
ret = vmdk_co_do_create(total_size, subformat, adapter_type_enum,
- backing_file, hw_version, compat6, zeroed_grain,
- vmdk_co_create_opts_cb, &data, errp);
+ backing_file, hw_version, toolsversion, compat6,
+ zeroed_grain, vmdk_co_create_opts_cb, &data, errp);
exit:
g_free(backing_fmt);
g_free(adapter_type);
g_free(backing_file);
g_free(hw_version);
+ g_free(toolsversion);
g_free(fmt);
g_free(desc);
g_free(path);
@@ -2782,6 +2792,7 @@ static int coroutine_fn vmdk_co_create(BlockdevCreateOptions *create_options,
opts->adapter_type,
opts->backing_file,
opts->hwversion,
+ opts->toolsversion,
false,
opts->zeroed_grain,
vmdk_co_create_cb,
@@ -3031,6 +3042,11 @@ static QemuOptsList vmdk_create_opts = {
.help = "VMDK hardware version",
.def_value_str = "undefined"
},
+ {
+ .name = BLOCK_OPT_TOOLSVERSION,
+ .type = QEMU_OPT_STRING,
+ .help = "VMware guest tools version",
+ },
{
.name = BLOCK_OPT_SUBFMT,
.type = QEMU_OPT_STRING,
--
2.31.1
^ permalink raw reply related [flat|nested] 12+ messages in thread
* [PULL 4/4] block/vpc: Add a sanity check that fixed-size images have the right type
2021-11-02 14:22 [PULL 0/4] Block patches Hanna Reitz
` (2 preceding siblings ...)
2021-11-02 14:22 ` [PULL 3/4] vmdk: allow specification of tools version Hanna Reitz
@ 2021-11-02 14:22 ` Hanna Reitz
2021-11-03 4:31 ` [PULL 0/4] Block patches Richard Henderson
4 siblings, 0 replies; 12+ messages in thread
From: Hanna Reitz @ 2021-11-02 14:22 UTC (permalink / raw)
To: qemu-block; +Cc: Kevin Wolf, Peter Maydell, Hanna Reitz, qemu-devel
From: Thomas Huth <thuth@redhat.com>
The code in vpc.c uses BDRVVPCState->footer.type in various places
to decide whether the image is a fixed-size (VHD_FIXED) or a dynamic
(VHD_DYNAMIC) image. However, we never check that this field really
contains VHD_FIXED if we detected a fixed size image in vpc_open(),
so a wrong value here could cause quite some trouble during runtime.
Suggested-by: Kevin Wolf <kwolf@redhat.com>
Signed-off-by: Thomas Huth <thuth@redhat.com>
Message-Id: <20211012082702.792259-1-thuth@redhat.com>
Signed-off-by: Hanna Reitz <hreitz@redhat.com>
---
block/vpc.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/block/vpc.c b/block/vpc.c
index 1b4c7333af..297a26262a 100644
--- a/block/vpc.c
+++ b/block/vpc.c
@@ -276,7 +276,8 @@ static int vpc_open(BlockDriverState *bs, QDict *options, int flags,
if (ret < 0) {
goto fail;
}
- if (strncmp(footer->creator, "conectix", 8)) {
+ if (strncmp(footer->creator, "conectix", 8) ||
+ be32_to_cpu(footer->type) != VHD_FIXED) {
error_setg(errp, "invalid VPC image");
ret = -EINVAL;
goto fail;
--
2.31.1
^ permalink raw reply related [flat|nested] 12+ messages in thread
* Re: [PULL 0/4] Block patches
2021-11-02 14:22 [PULL 0/4] Block patches Hanna Reitz
` (3 preceding siblings ...)
2021-11-02 14:22 ` [PULL 4/4] block/vpc: Add a sanity check that fixed-size images have the right type Hanna Reitz
@ 2021-11-03 4:31 ` Richard Henderson
4 siblings, 0 replies; 12+ messages in thread
From: Richard Henderson @ 2021-11-03 4:31 UTC (permalink / raw)
To: Hanna Reitz, qemu-block; +Cc: Kevin Wolf, Peter Maydell, qemu-devel
On 11/2/21 10:22 AM, Hanna Reitz wrote:
> The following changes since commit 8cb41fda78c7ebde0dd248c6afe1d336efb0de50:
>
> Merge remote-tracking branch 'remotes/philmd/tags/machine-20211101' into staging (2021-11-02 05:53:45 -0400)
>
> are available in the Git repository at:
>
> https://github.com/XanClic/qemu.git tags/pull-block-2021-11-02
>
> for you to fetch changes up to 7da9623cc078229caf07c290e16401ccdb9408d2:
>
> block/vpc: Add a sanity check that fixed-size images have the right type (2021-11-02 12:47:51 +0100)
>
> ----------------------------------------------------------------
> Emanuele Giuseppe Esposito (1):
> pylint: fix errors and warnings generated by tests/qemu-iotests/297
>
> Eric Blake (1):
> qemu-img: Consistent docs for convert -F
>
> Thomas Huth (1):
> block/vpc: Add a sanity check that fixed-size images have the right
> type
>
> Thomas Weißschuh (1):
> vmdk: allow specification of tools version
>
> docs/tools/qemu-img.rst | 2 +-
> qapi/block-core.json | 3 +++
> block/vmdk.c | 24 ++++++++++++++++++++----
> block/vpc.c | 3 ++-
> qemu-img-cmds.hx | 2 +-
> tests/qemu-iotests/129 | 18 +++++++++---------
> tests/qemu-iotests/310 | 16 ++++++++--------
> tests/qemu-iotests/check | 11 ++++++-----
> tests/qemu-iotests/iotests.py | 7 ++++---
> tests/qemu-iotests/tests/image-fleecing | 4 ++--
> 10 files changed, 56 insertions(+), 34 deletions(-)
Applied, thanks.
r~
^ permalink raw reply [flat|nested] 12+ messages in thread
end of thread, other threads:[~2021-11-03 4:32 UTC | newest]
Thread overview: 12+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2021-11-02 14:22 [PULL 0/4] Block patches Hanna Reitz
2021-11-02 14:22 ` [PULL 1/4] qemu-img: Consistent docs for convert -F Hanna Reitz
2021-11-02 14:22 ` [PULL 2/4] pylint: fix errors and warnings generated by tests/qemu-iotests/297 Hanna Reitz
2021-11-02 14:22 ` [PULL 3/4] vmdk: allow specification of tools version Hanna Reitz
2021-11-02 14:22 ` [PULL 4/4] block/vpc: Add a sanity check that fixed-size images have the right type Hanna Reitz
2021-11-03 4:31 ` [PULL 0/4] Block patches Richard Henderson
-- strict thread matches above, loose matches on Subject: below --
2020-05-01 8:28 Stefan Hajnoczi
2020-05-01 9:02 ` no-reply
2020-05-01 9:32 ` Peter Maydell
2020-05-01 15:23 ` Stefan Hajnoczi
2019-10-08 14:55 Stefan Hajnoczi
2019-10-08 17:21 ` Peter Maydell
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).