[Qemu-devel] [PATCH v4 00/14] block: Try to create well-typed json:{} filenames

Max Reitz posted 14 patches 4 years, 10 months ago
Test checkpatch failed
Test s390x passed
Test asan failed
Test docker-mingw@fedora passed
Test FreeBSD passed
Test docker-clang@ubuntu passed
Patches applied successfully (tree, apply log)
git fetch https://github.com/patchew-project/qemu tags/patchew/20190624173935.25747-1-mreitz@redhat.com
Maintainers: "Denis V. Lunev" <den@openvz.org>, Liu Yuan <namei.unix@gmail.com>, Jeff Cody <codyprime@gmail.com>, Kevin Wolf <kwolf@redhat.com>, Michael Roth <mdroth@linux.vnet.ibm.com>, "Dr. David Alan Gilbert" <dgilbert@redhat.com>, Stefan Hajnoczi <stefanha@redhat.com>, Markus Armbruster <armbru@redhat.com>, Eric Blake <eblake@redhat.com>, Stefan Weil <sw@weilnetz.de>, Max Reitz <mreitz@redhat.com>
docs/devel/qapi-code-gen.txt                  |  81 +++++-
tests/Makefile.include                        |  17 +-
qapi/block-core.json                          | 180 +++++++++-----
qapi/introspect.json                          |   9 +-
tests/qapi-schema/bad-type-int.json           |   1 -
tests/qapi-schema/enum-int-member.json        |   1 -
...l-discriminator-invalid-specification.json |  11 +
...on-optional-discriminator-no-default.json} |   5 +-
tests/qapi-schema/qapi-schema-test.json       |  38 +++
.../struct-member-alternate-default.json      |  10 +
...struct-member-bool-wrong-default-type.json |   3 +
.../struct-member-enum-invalid-default.json   |   4 +
...struct-member-enum-wrong-default-type.json |   4 +
.../struct-member-float-invalid-default.json  |   4 +
...truct-member-float-wrong-default-type.json |   3 +
.../struct-member-int-wrong-default-type.json |   3 +
.../struct-member-int8-erange-default.json    |   3 +
.../struct-member-list-nonempty-default.json  |   4 +
.../struct-member-non-optional-default.json   |   3 +
.../struct-member-null-default.json           |   6 +
.../struct-member-str-wrong-default-type.json |   3 +
.../struct-member-uint8-erange-default.json   |   3 +
.../struct-member-uint8-negative-default.json |   3 +
block.c                                       |  68 ++++-
block/file-posix.c                            |   9 -
block/file-win32.c                            |   8 +-
block/parallels.c                             |   6 +-
block/qcow2.c                                 |  39 +--
block/qed.c                                   |   3 -
block/sheepdog.c                              |   3 -
block/vdi.c                                   |   3 -
block/vhdx.c                                  |  28 +--
block/vpc.c                                   |   3 -
blockdev.c                                    | 182 +++-----------
monitor/hmp-cmds.c                            |  27 +-
monitor/qmp-cmds.c                            |   3 +-
scripts/qapi/commands.py                      |   2 +-
scripts/qapi/common.py                        | 232 ++++++++++++++++--
scripts/qapi/doc.py                           |  20 +-
scripts/qapi/introspect.py                    |   8 +-
scripts/qapi/types.py                         |   2 +-
scripts/qapi/visit.py                         |  38 ++-
tests/qapi-schema/bad-type-int.err            |   2 +-
tests/qapi-schema/enum-int-member.err         |   2 +-
...al-discriminator-invalid-specification.err |   1 +
...-discriminator-invalid-specification.exit} |   0
...l-discriminator-invalid-specification.out} |   0
...nion-optional-discriminator-no-default.err |   1 +
...ion-optional-discriminator-no-default.exit |   1 +
...nion-optional-discriminator-no-default.out |   0
.../flat-union-optional-discriminator.err     |   1 -
tests/qapi-schema/leading-comma-list.err      |   2 +-
tests/qapi-schema/qapi-schema-test.out        |  33 +++
.../struct-member-alternate-default.err       |   1 +
.../struct-member-alternate-default.exit      |   1 +
.../struct-member-alternate-default.out       |   0
.../struct-member-bool-wrong-default-type.err |   1 +
...struct-member-bool-wrong-default-type.exit |   1 +
.../struct-member-bool-wrong-default-type.out |   0
.../struct-member-enum-invalid-default.err    |   1 +
.../struct-member-enum-invalid-default.exit   |   1 +
.../struct-member-enum-invalid-default.out    |   0
.../struct-member-enum-wrong-default-type.err |   1 +
...struct-member-enum-wrong-default-type.exit |   1 +
.../struct-member-enum-wrong-default-type.out |   0
.../struct-member-float-invalid-default.err   |   1 +
.../struct-member-float-invalid-default.exit  |   1 +
.../struct-member-float-invalid-default.out   |   0
...struct-member-float-wrong-default-type.err |   1 +
...truct-member-float-wrong-default-type.exit |   1 +
...struct-member-float-wrong-default-type.out |   0
.../struct-member-int-wrong-default-type.err  |   1 +
.../struct-member-int-wrong-default-type.exit |   1 +
.../struct-member-int-wrong-default-type.out  |   0
.../struct-member-int8-erange-default.err     |   1 +
.../struct-member-int8-erange-default.exit    |   1 +
.../struct-member-int8-erange-default.out     |   0
.../struct-member-list-nonempty-default.err   |   1 +
.../struct-member-list-nonempty-default.exit  |   1 +
.../struct-member-list-nonempty-default.out   |   0
.../struct-member-non-optional-default.err    |   1 +
.../struct-member-non-optional-default.exit   |   1 +
.../struct-member-non-optional-default.out    |   0
.../struct-member-null-default.err            |   1 +
.../struct-member-null-default.exit           |   1 +
.../struct-member-null-default.out            |   0
.../struct-member-str-wrong-default-type.err  |   1 +
.../struct-member-str-wrong-default-type.exit |   1 +
.../struct-member-str-wrong-default-type.out  |   0
.../struct-member-uint8-erange-default.err    |   1 +
.../struct-member-uint8-erange-default.exit   |   1 +
.../struct-member-uint8-erange-default.out    |   0
.../struct-member-uint8-negative-default.err  |   1 +
.../struct-member-uint8-negative-default.exit |   1 +
.../struct-member-uint8-negative-default.out  |   0
tests/qapi-schema/test-qapi.py                |   8 +-
tests/qemu-iotests/059.out                    |   2 +-
tests/qemu-iotests/087                        |  65 +++--
tests/qemu-iotests/087.out                    |  26 +-
tests/qemu-iotests/089                        |  25 ++
tests/qemu-iotests/089.out                    |   9 +
tests/qemu-iotests/099.out                    |   4 +-
tests/qemu-iotests/110.out                    |   2 +-
tests/qemu-iotests/198.out                    |   4 +-
104 files changed, 915 insertions(+), 384 deletions(-)
create mode 100644 tests/qapi-schema/flat-union-optional-discriminator-invalid-specification.json
rename tests/qapi-schema/{flat-union-optional-discriminator.json => flat-union-optional-discriminator-no-default.json} (68%)
create mode 100644 tests/qapi-schema/struct-member-alternate-default.json
create mode 100644 tests/qapi-schema/struct-member-bool-wrong-default-type.json
create mode 100644 tests/qapi-schema/struct-member-enum-invalid-default.json
create mode 100644 tests/qapi-schema/struct-member-enum-wrong-default-type.json
create mode 100644 tests/qapi-schema/struct-member-float-invalid-default.json
create mode 100644 tests/qapi-schema/struct-member-float-wrong-default-type.json
create mode 100644 tests/qapi-schema/struct-member-int-wrong-default-type.json
create mode 100644 tests/qapi-schema/struct-member-int8-erange-default.json
create mode 100644 tests/qapi-schema/struct-member-list-nonempty-default.json
create mode 100644 tests/qapi-schema/struct-member-non-optional-default.json
create mode 100644 tests/qapi-schema/struct-member-null-default.json
create mode 100644 tests/qapi-schema/struct-member-str-wrong-default-type.json
create mode 100644 tests/qapi-schema/struct-member-uint8-erange-default.json
create mode 100644 tests/qapi-schema/struct-member-uint8-negative-default.json
create mode 100644 tests/qapi-schema/flat-union-optional-discriminator-invalid-specification.err
rename tests/qapi-schema/{flat-union-optional-discriminator.exit => flat-union-optional-discriminator-invalid-specification.exit} (100%)
rename tests/qapi-schema/{flat-union-optional-discriminator.out => flat-union-optional-discriminator-invalid-specification.out} (100%)
create mode 100644 tests/qapi-schema/flat-union-optional-discriminator-no-default.err
create mode 100644 tests/qapi-schema/flat-union-optional-discriminator-no-default.exit
create mode 100644 tests/qapi-schema/flat-union-optional-discriminator-no-default.out
delete mode 100644 tests/qapi-schema/flat-union-optional-discriminator.err
create mode 100644 tests/qapi-schema/struct-member-alternate-default.err
create mode 100644 tests/qapi-schema/struct-member-alternate-default.exit
create mode 100644 tests/qapi-schema/struct-member-alternate-default.out
create mode 100644 tests/qapi-schema/struct-member-bool-wrong-default-type.err
create mode 100644 tests/qapi-schema/struct-member-bool-wrong-default-type.exit
create mode 100644 tests/qapi-schema/struct-member-bool-wrong-default-type.out
create mode 100644 tests/qapi-schema/struct-member-enum-invalid-default.err
create mode 100644 tests/qapi-schema/struct-member-enum-invalid-default.exit
create mode 100644 tests/qapi-schema/struct-member-enum-invalid-default.out
create mode 100644 tests/qapi-schema/struct-member-enum-wrong-default-type.err
create mode 100644 tests/qapi-schema/struct-member-enum-wrong-default-type.exit
create mode 100644 tests/qapi-schema/struct-member-enum-wrong-default-type.out
create mode 100644 tests/qapi-schema/struct-member-float-invalid-default.err
create mode 100644 tests/qapi-schema/struct-member-float-invalid-default.exit
create mode 100644 tests/qapi-schema/struct-member-float-invalid-default.out
create mode 100644 tests/qapi-schema/struct-member-float-wrong-default-type.err
create mode 100644 tests/qapi-schema/struct-member-float-wrong-default-type.exit
create mode 100644 tests/qapi-schema/struct-member-float-wrong-default-type.out
create mode 100644 tests/qapi-schema/struct-member-int-wrong-default-type.err
create mode 100644 tests/qapi-schema/struct-member-int-wrong-default-type.exit
create mode 100644 tests/qapi-schema/struct-member-int-wrong-default-type.out
create mode 100644 tests/qapi-schema/struct-member-int8-erange-default.err
create mode 100644 tests/qapi-schema/struct-member-int8-erange-default.exit
create mode 100644 tests/qapi-schema/struct-member-int8-erange-default.out
create mode 100644 tests/qapi-schema/struct-member-list-nonempty-default.err
create mode 100644 tests/qapi-schema/struct-member-list-nonempty-default.exit
create mode 100644 tests/qapi-schema/struct-member-list-nonempty-default.out
create mode 100644 tests/qapi-schema/struct-member-non-optional-default.err
create mode 100644 tests/qapi-schema/struct-member-non-optional-default.exit
create mode 100644 tests/qapi-schema/struct-member-non-optional-default.out
create mode 100644 tests/qapi-schema/struct-member-null-default.err
create mode 100644 tests/qapi-schema/struct-member-null-default.exit
create mode 100644 tests/qapi-schema/struct-member-null-default.out
create mode 100644 tests/qapi-schema/struct-member-str-wrong-default-type.err
create mode 100644 tests/qapi-schema/struct-member-str-wrong-default-type.exit
create mode 100644 tests/qapi-schema/struct-member-str-wrong-default-type.out
create mode 100644 tests/qapi-schema/struct-member-uint8-erange-default.err
create mode 100644 tests/qapi-schema/struct-member-uint8-erange-default.exit
create mode 100644 tests/qapi-schema/struct-member-uint8-erange-default.out
create mode 100644 tests/qapi-schema/struct-member-uint8-negative-default.err
create mode 100644 tests/qapi-schema/struct-member-uint8-negative-default.exit
create mode 100644 tests/qapi-schema/struct-member-uint8-negative-default.out
[Qemu-devel] [PATCH v4 00/14] block: Try to create well-typed json:{} filenames
Posted by Max Reitz 4 years, 10 months ago
Hi,

There are two explanations of this cover letter, a relative one (to v3)
and an absolute one.


*** Important note ***

The final patch in this series is an example that converts most of
block-core.json to use default values where possible.  We may decide to
take it or not.  It isn’t important for the main purpose of this series,
so I’d be very much fine with chopping it off.

(It does have a nice diff stat, though.)

*** Important note end ***


Relative explanation:

The actual functional goal of this series is to allow all blockdev
options that can be represented with -drive to have an equivalent with
-blockdev (safe for rbd’s =keyvalue-pairs).

To this end, qcow(2)’s encryption needs an “auto” format which can
automatically deduce the format from the image header.  To make things
nicer, I decided (already in v1) to make this format optional so users
could just specify encrypt.secret and let the format driver figure out
the rest.

Until v3, this was implemented by letting the discriminator of flat
unions be optional, as long as a default-value is provided.  Markus
(rightfully) complained that this is very specific and would be covered
by just having default values for QAPI struct members in general.
So now this version implements this.  This is a bit more complicated
than just implementing a default-variant, mainly because the latter only
needs to accept enum values, whereas a generally usable “default” should
accept values of all QAPI types (to the extent what is reasonable).

So what was (until v3)

  { 'union': 'Foo',
    'base': { '*discr': 'SomeEnum' },
    'discriminator': 'discr',
    'default-variant': 'value1',
    'data': { 'value1': 'Bar', 'value2': 'Baz' } }

becomes

  { 'union': 'Foo',
    'base': { '*discr': { 'type': 'SomeEnum', 'default': 'value1' } },
    'discriminator': 'discr',
    'data': { 'value1': 'Bar', 'value2': 'Baz' } }



Absolute explanation:

When qemu reports json:{} filename, it just uses whatever type you gave
an option in.  With -drive, all options are strings and they do not have
to pass the test of the typing firewall of the QAPI schema, so you just
get strings thrown back at you even if that does not match the schema.
(Also, if you use json:{} yourself, you’re free to give the options as
strings as well.)

Example:

$ ./qemu-img info --image-opts driver=raw,size=512,file.driver=null-co
image: json:{"driver": "raw", "size": "512", "file": {"driver": "null-co"}}

@size is supposed to be an integer, according to the schema, so the
correct result would be (which is what you get after this series):

$ ./qemu-img info --image-opts driver=raw,size=512,file.driver=null-co
image: json:{"driver": "raw", "size": 512, "file": {"driver": "null-co"}}


This is achieved by patch 11, which makes bdrv_refresh_filename() run
the options through the flat-confused input visitor, and then through
the output visitor to get all to the correct type.  If anything fails,
the result is as before (hence the “Try” in the title).

There are cases where this cannot work.  Those are the ones where -drive
accepts something that is not allowed by the QAPI schema.  One of these
cases is rbd’s =keyvalue-pairs, which is just broken altogether, so
let’s simply ignore that.  (I don’t think anybody’s going to complain
that the json:{} filename they get is not correctly typed after they’ve
used that option.)

The other case (I know of) is qcow(2)’s encryption.  In the QAPI schema,
encrypt.format is not optional because it is the discriminator for which
kind of options to use.  However, for -drive, it is optional because the
qcow2 driver can infer the encryption format from the image header.

The solution that’s proposed by this series is to make flat union
discriminators optional and provide a default.  This is accomplished by
generally allowing default values to be provided for QAPI struct
members.

Both AES and LUKS encryption allow only a key-secret option, so we can
add a new pseudo-format “auto” that accepts exactly that option and
makes the qcow2 driver read the real format from the image header.  This
pseudo-format is made the default for encrypt.format, and thus you can
then specify encrypt.key-secret without having to specify
encrypt.format (while still adhering to the QAPI schema).


So, in this series:
- The QAPI code generator is modified to allow default values for
  optional struct members.  This in turn allows flat union
  discriminators be optional, too, but only if a default value is
  provided.
  - Accordingly, documentation, tests, and introspection are adjusted.

- This is used to make qcow’s and qcow2’s encrypt.format parameter
  optional.  It now defaults to “from-image” which is a new
  pseudo-format that allows a key-secret to be given, and otherwise
  leaves it to the format driver to determine the encryption format.

- json:{} filenames are attempted to be typed correctly when they are
  generated, by running bs->full_open_options through a healthy mix of
  qdict_flatten(), the flat-confused input visitor for BlockdevOptions,
  and the output visitor.
  This may not always work but I hope it usually will.  Fingers crossed.
  (At least it won’t make things worse.)

- Tests, tests, tests.


(Yes, I know that “In this series tests, tests, tests.” is not a
 sentence.)


v4:
- Drop the default-variant stuff and replace it by a more general
  concept of allowing default values for all QAPI struct members


git backport-diff against v3:

Key:
[----] : patches are identical
[####] : number of functional differences between upstream/downstream patch
[down] : patch is downstream-only
The flags [FC] indicate (F)unctional and (C)ontextual differences, respectively

001/14:[down] 'qapi: Parse numeric values'
002/14:[down] 'qapi: Move to_c_string() to common.py'
003/14:[down] 'qapi: Introduce default values for struct members'
004/14:[down] 'qapi: Allow optional discriminators'
005/14:[down] 'qapi: Document default values for struct members'
006/14:[down] 'test-qapi: Print struct members' default values'
007/14:[down] 'tests: Test QAPI default values for struct members'
008/14:[0044] [FC] 'tests: Add QAPI optional discriminator tests'
009/14:[0009] [FC] 'qapi: Formalize qcow2 encryption probing'
010/14:[0005] [FC] 'qapi: Formalize qcow encryption probing'
011/14:[0014] [FC] 'block: Try to create well typed json:{} filenames'
012/14:[----] [--] 'iotests: Test internal option typing'
013/14:[----] [--] 'iotests: qcow2's encrypt.format is now optional'
014/14:[down] 'block: Make use of QAPI defaults'


Max Reitz (14):
  qapi: Parse numeric values
  qapi: Move to_c_string() to common.py
  qapi: Introduce default values for struct members
  qapi: Allow optional discriminators
  qapi: Document default values for struct members
  test-qapi: Print struct members' default values
  tests: Test QAPI default values for struct members
  tests: Add QAPI optional discriminator tests
  qapi: Formalize qcow2 encryption probing
  qapi: Formalize qcow encryption probing
  block: Try to create well typed json:{} filenames
  iotests: Test internal option typing
  iotests: qcow2's encrypt.format is now optional
  block: Make use of QAPI defaults

 docs/devel/qapi-code-gen.txt                  |  81 +++++-
 tests/Makefile.include                        |  17 +-
 qapi/block-core.json                          | 180 +++++++++-----
 qapi/introspect.json                          |   9 +-
 tests/qapi-schema/bad-type-int.json           |   1 -
 tests/qapi-schema/enum-int-member.json        |   1 -
 ...l-discriminator-invalid-specification.json |  11 +
 ...on-optional-discriminator-no-default.json} |   5 +-
 tests/qapi-schema/qapi-schema-test.json       |  38 +++
 .../struct-member-alternate-default.json      |  10 +
 ...struct-member-bool-wrong-default-type.json |   3 +
 .../struct-member-enum-invalid-default.json   |   4 +
 ...struct-member-enum-wrong-default-type.json |   4 +
 .../struct-member-float-invalid-default.json  |   4 +
 ...truct-member-float-wrong-default-type.json |   3 +
 .../struct-member-int-wrong-default-type.json |   3 +
 .../struct-member-int8-erange-default.json    |   3 +
 .../struct-member-list-nonempty-default.json  |   4 +
 .../struct-member-non-optional-default.json   |   3 +
 .../struct-member-null-default.json           |   6 +
 .../struct-member-str-wrong-default-type.json |   3 +
 .../struct-member-uint8-erange-default.json   |   3 +
 .../struct-member-uint8-negative-default.json |   3 +
 block.c                                       |  68 ++++-
 block/file-posix.c                            |   9 -
 block/file-win32.c                            |   8 +-
 block/parallels.c                             |   6 +-
 block/qcow2.c                                 |  39 +--
 block/qed.c                                   |   3 -
 block/sheepdog.c                              |   3 -
 block/vdi.c                                   |   3 -
 block/vhdx.c                                  |  28 +--
 block/vpc.c                                   |   3 -
 blockdev.c                                    | 182 +++-----------
 monitor/hmp-cmds.c                            |  27 +-
 monitor/qmp-cmds.c                            |   3 +-
 scripts/qapi/commands.py                      |   2 +-
 scripts/qapi/common.py                        | 232 ++++++++++++++++--
 scripts/qapi/doc.py                           |  20 +-
 scripts/qapi/introspect.py                    |   8 +-
 scripts/qapi/types.py                         |   2 +-
 scripts/qapi/visit.py                         |  38 ++-
 tests/qapi-schema/bad-type-int.err            |   2 +-
 tests/qapi-schema/enum-int-member.err         |   2 +-
 ...al-discriminator-invalid-specification.err |   1 +
 ...-discriminator-invalid-specification.exit} |   0
 ...l-discriminator-invalid-specification.out} |   0
 ...nion-optional-discriminator-no-default.err |   1 +
 ...ion-optional-discriminator-no-default.exit |   1 +
 ...nion-optional-discriminator-no-default.out |   0
 .../flat-union-optional-discriminator.err     |   1 -
 tests/qapi-schema/leading-comma-list.err      |   2 +-
 tests/qapi-schema/qapi-schema-test.out        |  33 +++
 .../struct-member-alternate-default.err       |   1 +
 .../struct-member-alternate-default.exit      |   1 +
 .../struct-member-alternate-default.out       |   0
 .../struct-member-bool-wrong-default-type.err |   1 +
 ...struct-member-bool-wrong-default-type.exit |   1 +
 .../struct-member-bool-wrong-default-type.out |   0
 .../struct-member-enum-invalid-default.err    |   1 +
 .../struct-member-enum-invalid-default.exit   |   1 +
 .../struct-member-enum-invalid-default.out    |   0
 .../struct-member-enum-wrong-default-type.err |   1 +
 ...struct-member-enum-wrong-default-type.exit |   1 +
 .../struct-member-enum-wrong-default-type.out |   0
 .../struct-member-float-invalid-default.err   |   1 +
 .../struct-member-float-invalid-default.exit  |   1 +
 .../struct-member-float-invalid-default.out   |   0
 ...struct-member-float-wrong-default-type.err |   1 +
 ...truct-member-float-wrong-default-type.exit |   1 +
 ...struct-member-float-wrong-default-type.out |   0
 .../struct-member-int-wrong-default-type.err  |   1 +
 .../struct-member-int-wrong-default-type.exit |   1 +
 .../struct-member-int-wrong-default-type.out  |   0
 .../struct-member-int8-erange-default.err     |   1 +
 .../struct-member-int8-erange-default.exit    |   1 +
 .../struct-member-int8-erange-default.out     |   0
 .../struct-member-list-nonempty-default.err   |   1 +
 .../struct-member-list-nonempty-default.exit  |   1 +
 .../struct-member-list-nonempty-default.out   |   0
 .../struct-member-non-optional-default.err    |   1 +
 .../struct-member-non-optional-default.exit   |   1 +
 .../struct-member-non-optional-default.out    |   0
 .../struct-member-null-default.err            |   1 +
 .../struct-member-null-default.exit           |   1 +
 .../struct-member-null-default.out            |   0
 .../struct-member-str-wrong-default-type.err  |   1 +
 .../struct-member-str-wrong-default-type.exit |   1 +
 .../struct-member-str-wrong-default-type.out  |   0
 .../struct-member-uint8-erange-default.err    |   1 +
 .../struct-member-uint8-erange-default.exit   |   1 +
 .../struct-member-uint8-erange-default.out    |   0
 .../struct-member-uint8-negative-default.err  |   1 +
 .../struct-member-uint8-negative-default.exit |   1 +
 .../struct-member-uint8-negative-default.out  |   0
 tests/qapi-schema/test-qapi.py                |   8 +-
 tests/qemu-iotests/059.out                    |   2 +-
 tests/qemu-iotests/087                        |  65 +++--
 tests/qemu-iotests/087.out                    |  26 +-
 tests/qemu-iotests/089                        |  25 ++
 tests/qemu-iotests/089.out                    |   9 +
 tests/qemu-iotests/099.out                    |   4 +-
 tests/qemu-iotests/110.out                    |   2 +-
 tests/qemu-iotests/198.out                    |   4 +-
 104 files changed, 915 insertions(+), 384 deletions(-)
 create mode 100644 tests/qapi-schema/flat-union-optional-discriminator-invalid-specification.json
 rename tests/qapi-schema/{flat-union-optional-discriminator.json => flat-union-optional-discriminator-no-default.json} (68%)
 create mode 100644 tests/qapi-schema/struct-member-alternate-default.json
 create mode 100644 tests/qapi-schema/struct-member-bool-wrong-default-type.json
 create mode 100644 tests/qapi-schema/struct-member-enum-invalid-default.json
 create mode 100644 tests/qapi-schema/struct-member-enum-wrong-default-type.json
 create mode 100644 tests/qapi-schema/struct-member-float-invalid-default.json
 create mode 100644 tests/qapi-schema/struct-member-float-wrong-default-type.json
 create mode 100644 tests/qapi-schema/struct-member-int-wrong-default-type.json
 create mode 100644 tests/qapi-schema/struct-member-int8-erange-default.json
 create mode 100644 tests/qapi-schema/struct-member-list-nonempty-default.json
 create mode 100644 tests/qapi-schema/struct-member-non-optional-default.json
 create mode 100644 tests/qapi-schema/struct-member-null-default.json
 create mode 100644 tests/qapi-schema/struct-member-str-wrong-default-type.json
 create mode 100644 tests/qapi-schema/struct-member-uint8-erange-default.json
 create mode 100644 tests/qapi-schema/struct-member-uint8-negative-default.json
 create mode 100644 tests/qapi-schema/flat-union-optional-discriminator-invalid-specification.err
 rename tests/qapi-schema/{flat-union-optional-discriminator.exit => flat-union-optional-discriminator-invalid-specification.exit} (100%)
 rename tests/qapi-schema/{flat-union-optional-discriminator.out => flat-union-optional-discriminator-invalid-specification.out} (100%)
 create mode 100644 tests/qapi-schema/flat-union-optional-discriminator-no-default.err
 create mode 100644 tests/qapi-schema/flat-union-optional-discriminator-no-default.exit
 create mode 100644 tests/qapi-schema/flat-union-optional-discriminator-no-default.out
 delete mode 100644 tests/qapi-schema/flat-union-optional-discriminator.err
 create mode 100644 tests/qapi-schema/struct-member-alternate-default.err
 create mode 100644 tests/qapi-schema/struct-member-alternate-default.exit
 create mode 100644 tests/qapi-schema/struct-member-alternate-default.out
 create mode 100644 tests/qapi-schema/struct-member-bool-wrong-default-type.err
 create mode 100644 tests/qapi-schema/struct-member-bool-wrong-default-type.exit
 create mode 100644 tests/qapi-schema/struct-member-bool-wrong-default-type.out
 create mode 100644 tests/qapi-schema/struct-member-enum-invalid-default.err
 create mode 100644 tests/qapi-schema/struct-member-enum-invalid-default.exit
 create mode 100644 tests/qapi-schema/struct-member-enum-invalid-default.out
 create mode 100644 tests/qapi-schema/struct-member-enum-wrong-default-type.err
 create mode 100644 tests/qapi-schema/struct-member-enum-wrong-default-type.exit
 create mode 100644 tests/qapi-schema/struct-member-enum-wrong-default-type.out
 create mode 100644 tests/qapi-schema/struct-member-float-invalid-default.err
 create mode 100644 tests/qapi-schema/struct-member-float-invalid-default.exit
 create mode 100644 tests/qapi-schema/struct-member-float-invalid-default.out
 create mode 100644 tests/qapi-schema/struct-member-float-wrong-default-type.err
 create mode 100644 tests/qapi-schema/struct-member-float-wrong-default-type.exit
 create mode 100644 tests/qapi-schema/struct-member-float-wrong-default-type.out
 create mode 100644 tests/qapi-schema/struct-member-int-wrong-default-type.err
 create mode 100644 tests/qapi-schema/struct-member-int-wrong-default-type.exit
 create mode 100644 tests/qapi-schema/struct-member-int-wrong-default-type.out
 create mode 100644 tests/qapi-schema/struct-member-int8-erange-default.err
 create mode 100644 tests/qapi-schema/struct-member-int8-erange-default.exit
 create mode 100644 tests/qapi-schema/struct-member-int8-erange-default.out
 create mode 100644 tests/qapi-schema/struct-member-list-nonempty-default.err
 create mode 100644 tests/qapi-schema/struct-member-list-nonempty-default.exit
 create mode 100644 tests/qapi-schema/struct-member-list-nonempty-default.out
 create mode 100644 tests/qapi-schema/struct-member-non-optional-default.err
 create mode 100644 tests/qapi-schema/struct-member-non-optional-default.exit
 create mode 100644 tests/qapi-schema/struct-member-non-optional-default.out
 create mode 100644 tests/qapi-schema/struct-member-null-default.err
 create mode 100644 tests/qapi-schema/struct-member-null-default.exit
 create mode 100644 tests/qapi-schema/struct-member-null-default.out
 create mode 100644 tests/qapi-schema/struct-member-str-wrong-default-type.err
 create mode 100644 tests/qapi-schema/struct-member-str-wrong-default-type.exit
 create mode 100644 tests/qapi-schema/struct-member-str-wrong-default-type.out
 create mode 100644 tests/qapi-schema/struct-member-uint8-erange-default.err
 create mode 100644 tests/qapi-schema/struct-member-uint8-erange-default.exit
 create mode 100644 tests/qapi-schema/struct-member-uint8-erange-default.out
 create mode 100644 tests/qapi-schema/struct-member-uint8-negative-default.err
 create mode 100644 tests/qapi-schema/struct-member-uint8-negative-default.exit
 create mode 100644 tests/qapi-schema/struct-member-uint8-negative-default.out

-- 
2.21.0


Re: [Qemu-devel] [PATCH v4 00/14] block: Try to create well-typed json:{} filenames
Posted by no-reply@patchew.org 4 years, 10 months ago
Patchew URL: https://patchew.org/QEMU/20190624173935.25747-1-mreitz@redhat.com/



Hi,

This series seems to have some coding style problems. See output below for
more information:

Message-id: 20190624173935.25747-1-mreitz@redhat.com
Type: series
Subject: [Qemu-devel] [PATCH v4 00/14] block: Try to create well-typed json:{} filenames

=== TEST SCRIPT BEGIN ===
#!/bin/bash
git rev-parse base > /dev/null || exit 0
git config --local diff.renamelimit 0
git config --local diff.renames True
git config --local diff.algorithm histogram
./scripts/checkpatch.pl --mailback base..
=== TEST SCRIPT END ===

Switched to a new branch 'test'
ddd669a block: Make use of QAPI defaults
3bcf922 iotests: qcow2's encrypt.format is now optional
155c1db iotests: Test internal option typing
364eac1 block: Try to create well typed json:{} filenames
11726d2 qapi: Formalize qcow encryption probing
567644f qapi: Formalize qcow2 encryption probing
4eb3ca4 tests: Add QAPI optional discriminator tests
f3d9f53 tests: Test QAPI default values for struct members
2862824 test-qapi: Print struct members' default values
ff7a7c5 qapi: Document default values for struct members
faef37f qapi: Allow optional discriminators
64ae73c qapi: Introduce default values for struct members
f485950 qapi: Move to_c_string() to common.py
8711bb4 qapi: Parse numeric values

=== OUTPUT BEGIN ===
1/14 Checking commit 8711bb4c30f3 (qapi: Parse numeric values)
2/14 Checking commit f485950c4595 (qapi: Move to_c_string() to common.py)
3/14 Checking commit 64ae73cfedd6 (qapi: Introduce default values for struct members)
4/14 Checking commit faef37f6cd45 (qapi: Allow optional discriminators)
5/14 Checking commit ff7a7c5b6024 (qapi: Document default values for struct members)
6/14 Checking commit 28628249dcf1 (test-qapi: Print struct members' default values)
7/14 Checking commit f3d9f5343a99 (tests: Test QAPI default values for struct members)
ERROR: Invalid UTF-8, patch and commit message should be encoded in UTF-8
#106: FILE: tests/qapi-schema/qapi-schema-test.out:420:
+    member str: str optional=True default=foo \鹿""'
                                                    ^

WARNING: added, moved or deleted file(s), does MAINTAINERS need updating?
#111: 
new file mode 100644

total: 1 errors, 1 warnings, 162 lines checked

Patch 7/14 has style problems, please review.  If any of these errors
are false positives report them to the maintainer, see
CHECKPATCH in MAINTAINERS.

8/14 Checking commit 4eb3ca457ca3 (tests: Add QAPI optional discriminator tests)
WARNING: added, moved or deleted file(s), does MAINTAINERS need updating?
#33: 
new file mode 100644

total: 0 errors, 1 warnings, 67 lines checked

Patch 8/14 has style problems, please review.  If any of these errors
are false positives report them to the maintainer, see
CHECKPATCH in MAINTAINERS.
9/14 Checking commit 567644f6aaa8 (qapi: Formalize qcow2 encryption probing)
10/14 Checking commit 11726d25c367 (qapi: Formalize qcow encryption probing)
11/14 Checking commit 364eac1f31fc (block: Try to create well typed json:{} filenames)
12/14 Checking commit 155c1dbdf3f0 (iotests: Test internal option typing)
13/14 Checking commit 3bcf92270e86 (iotests: qcow2's encrypt.format is now optional)
14/14 Checking commit ddd669ad96a0 (block: Make use of QAPI defaults)
=== OUTPUT END ===

Test command exited with code: 1


The full log is available at
http://patchew.org/logs/20190624173935.25747-1-mreitz@redhat.com/testing.checkpatch/?type=message.
---
Email generated automatically by Patchew [https://patchew.org/].
Please send your feedback to patchew-devel@redhat.com
Re: [Qemu-devel] [PATCH v4 00/14] block: Try to create well-typed json:{} filenames
Posted by Max Reitz 4 years, 10 months ago
On 24.06.19 20:35, no-reply@patchew.org wrote:
> Patchew URL: https://patchew.org/QEMU/20190624173935.25747-1-mreitz@redhat.com/
> 
> 
> 
> Hi,
> 
> This series seems to have some coding style problems. See output below for
> more information:
> 
> Message-id: 20190624173935.25747-1-mreitz@redhat.com
> Type: series
> Subject: [Qemu-devel] [PATCH v4 00/14] block: Try to create well-typed json:{} filenames
> 
> === TEST SCRIPT BEGIN ===
> #!/bin/bash
> git rev-parse base > /dev/null || exit 0
> git config --local diff.renamelimit 0
> git config --local diff.renames True
> git config --local diff.algorithm histogram
> ./scripts/checkpatch.pl --mailback base..
> === TEST SCRIPT END ===
> 
> Switched to a new branch 'test'
> ddd669a block: Make use of QAPI defaults
> 3bcf922 iotests: qcow2's encrypt.format is now optional
> 155c1db iotests: Test internal option typing
> 364eac1 block: Try to create well typed json:{} filenames
> 11726d2 qapi: Formalize qcow encryption probing
> 567644f qapi: Formalize qcow2 encryption probing
> 4eb3ca4 tests: Add QAPI optional discriminator tests
> f3d9f53 tests: Test QAPI default values for struct members
> 2862824 test-qapi: Print struct members' default values
> ff7a7c5 qapi: Document default values for struct members
> faef37f qapi: Allow optional discriminators
> 64ae73c qapi: Introduce default values for struct members
> f485950 qapi: Move to_c_string() to common.py
> 8711bb4 qapi: Parse numeric values
> 
> === OUTPUT BEGIN ===
> 1/14 Checking commit 8711bb4c30f3 (qapi: Parse numeric values)
> 2/14 Checking commit f485950c4595 (qapi: Move to_c_string() to common.py)
> 3/14 Checking commit 64ae73cfedd6 (qapi: Introduce default values for struct members)
> 4/14 Checking commit faef37f6cd45 (qapi: Allow optional discriminators)
> 5/14 Checking commit ff7a7c5b6024 (qapi: Document default values for struct members)
> 6/14 Checking commit 28628249dcf1 (test-qapi: Print struct members' default values)
> 7/14 Checking commit f3d9f5343a99 (tests: Test QAPI default values for struct members)
> ERROR: Invalid UTF-8, patch and commit message should be encoded in UTF-8
> #106: FILE: tests/qapi-schema/qapi-schema-test.out:420:
> +    member str: str optional=True default=foo \鹿""'
>                                                     ^

Already noted in patch 7.

Max

Re: [Qemu-devel] [PATCH v4 00/14] block: Try to create well-typed json:{} filenames
Posted by Max Reitz 4 years, 10 months ago
On 24.06.19 21:04, Max Reitz wrote:
> On 24.06.19 20:35, no-reply@patchew.org wrote:
>> Patchew URL: https://patchew.org/QEMU/20190624173935.25747-1-mreitz@redhat.com/
>>
>>
>>
>> Hi,
>>
>> This series seems to have some coding style problems. See output below for
>> more information:
>>
>> Message-id: 20190624173935.25747-1-mreitz@redhat.com
>> Type: series
>> Subject: [Qemu-devel] [PATCH v4 00/14] block: Try to create well-typed json:{} filenames
>>
>> === TEST SCRIPT BEGIN ===
>> #!/bin/bash
>> git rev-parse base > /dev/null || exit 0
>> git config --local diff.renamelimit 0
>> git config --local diff.renames True
>> git config --local diff.algorithm histogram
>> ./scripts/checkpatch.pl --mailback base..
>> === TEST SCRIPT END ===
>>
>> Switched to a new branch 'test'
>> ddd669a block: Make use of QAPI defaults
>> 3bcf922 iotests: qcow2's encrypt.format is now optional
>> 155c1db iotests: Test internal option typing
>> 364eac1 block: Try to create well typed json:{} filenames
>> 11726d2 qapi: Formalize qcow encryption probing
>> 567644f qapi: Formalize qcow2 encryption probing
>> 4eb3ca4 tests: Add QAPI optional discriminator tests
>> f3d9f53 tests: Test QAPI default values for struct members
>> 2862824 test-qapi: Print struct members' default values
>> ff7a7c5 qapi: Document default values for struct members
>> faef37f qapi: Allow optional discriminators
>> 64ae73c qapi: Introduce default values for struct members
>> f485950 qapi: Move to_c_string() to common.py
>> 8711bb4 qapi: Parse numeric values
>>
>> === OUTPUT BEGIN ===
>> 1/14 Checking commit 8711bb4c30f3 (qapi: Parse numeric values)
>> 2/14 Checking commit f485950c4595 (qapi: Move to_c_string() to common.py)
>> 3/14 Checking commit 64ae73cfedd6 (qapi: Introduce default values for struct members)
>> 4/14 Checking commit faef37f6cd45 (qapi: Allow optional discriminators)
>> 5/14 Checking commit ff7a7c5b6024 (qapi: Document default values for struct members)
>> 6/14 Checking commit 28628249dcf1 (test-qapi: Print struct members' default values)
>> 7/14 Checking commit f3d9f5343a99 (tests: Test QAPI default values for struct members)
>> ERROR: Invalid UTF-8, patch and commit message should be encoded in UTF-8
>> #106: FILE: tests/qapi-schema/qapi-schema-test.out:420:
>> +    member str: str optional=True default=foo \鹿""'
>>                                                     ^
> 
> Already noted in patch 7.

Oops.  Didn’t note it in patch 7 because I reformatted the patches
afterwards and thus deleted my note. m(

Yes, it’s a test output and I’d like to test weird control characters,
mostly that the generated C code doesn’t break.  Any ideas how to fix
this?  I could just use \t instead of \b\x7f, but that would be boring.

Max

Re: [Qemu-devel] [PATCH v4 00/14] block: Try to create well-typed json:{} filenames
Posted by Max Reitz 4 years, 7 months ago
Another gentle ping.

Max


On 24.06.19 19:39, Max Reitz wrote:
> Hi,
> 
> There are two explanations of this cover letter, a relative one (to v3)
> and an absolute one.
> 
> 
> *** Important note ***
> 
> The final patch in this series is an example that converts most of
> block-core.json to use default values where possible.  We may decide to
> take it or not.  It isn’t important for the main purpose of this series,
> so I’d be very much fine with chopping it off.
> 
> (It does have a nice diff stat, though.)
> 
> *** Important note end ***
> 
> 
> Relative explanation:
> 
> The actual functional goal of this series is to allow all blockdev
> options that can be represented with -drive to have an equivalent with
> -blockdev (safe for rbd’s =keyvalue-pairs).
> 
> To this end, qcow(2)’s encryption needs an “auto” format which can
> automatically deduce the format from the image header.  To make things
> nicer, I decided (already in v1) to make this format optional so users
> could just specify encrypt.secret and let the format driver figure out
> the rest.
> 
> Until v3, this was implemented by letting the discriminator of flat
> unions be optional, as long as a default-value is provided.  Markus
> (rightfully) complained that this is very specific and would be covered
> by just having default values for QAPI struct members in general.
> So now this version implements this.  This is a bit more complicated
> than just implementing a default-variant, mainly because the latter only
> needs to accept enum values, whereas a generally usable “default” should
> accept values of all QAPI types (to the extent what is reasonable).
> 
> So what was (until v3)
> 
>   { 'union': 'Foo',
>     'base': { '*discr': 'SomeEnum' },
>     'discriminator': 'discr',
>     'default-variant': 'value1',
>     'data': { 'value1': 'Bar', 'value2': 'Baz' } }
> 
> becomes
> 
>   { 'union': 'Foo',
>     'base': { '*discr': { 'type': 'SomeEnum', 'default': 'value1' } },
>     'discriminator': 'discr',
>     'data': { 'value1': 'Bar', 'value2': 'Baz' } }
> 
> 
> 
> Absolute explanation:
> 
> When qemu reports json:{} filename, it just uses whatever type you gave
> an option in.  With -drive, all options are strings and they do not have
> to pass the test of the typing firewall of the QAPI schema, so you just
> get strings thrown back at you even if that does not match the schema.
> (Also, if you use json:{} yourself, you’re free to give the options as
> strings as well.)
> 
> Example:
> 
> $ ./qemu-img info --image-opts driver=raw,size=512,file.driver=null-co
> image: json:{"driver": "raw", "size": "512", "file": {"driver": "null-co"}}
> 
> @size is supposed to be an integer, according to the schema, so the
> correct result would be (which is what you get after this series):
> 
> $ ./qemu-img info --image-opts driver=raw,size=512,file.driver=null-co
> image: json:{"driver": "raw", "size": 512, "file": {"driver": "null-co"}}
> 
> 
> This is achieved by patch 11, which makes bdrv_refresh_filename() run
> the options through the flat-confused input visitor, and then through
> the output visitor to get all to the correct type.  If anything fails,
> the result is as before (hence the “Try” in the title).
> 
> There are cases where this cannot work.  Those are the ones where -drive
> accepts something that is not allowed by the QAPI schema.  One of these
> cases is rbd’s =keyvalue-pairs, which is just broken altogether, so
> let’s simply ignore that.  (I don’t think anybody’s going to complain
> that the json:{} filename they get is not correctly typed after they’ve
> used that option.)
> 
> The other case (I know of) is qcow(2)’s encryption.  In the QAPI schema,
> encrypt.format is not optional because it is the discriminator for which
> kind of options to use.  However, for -drive, it is optional because the
> qcow2 driver can infer the encryption format from the image header.
> 
> The solution that’s proposed by this series is to make flat union
> discriminators optional and provide a default.  This is accomplished by
> generally allowing default values to be provided for QAPI struct
> members.
> 
> Both AES and LUKS encryption allow only a key-secret option, so we can
> add a new pseudo-format “auto” that accepts exactly that option and
> makes the qcow2 driver read the real format from the image header.  This
> pseudo-format is made the default for encrypt.format, and thus you can
> then specify encrypt.key-secret without having to specify
> encrypt.format (while still adhering to the QAPI schema).
> 
> 
> So, in this series:
> - The QAPI code generator is modified to allow default values for
>   optional struct members.  This in turn allows flat union
>   discriminators be optional, too, but only if a default value is
>   provided.
>   - Accordingly, documentation, tests, and introspection are adjusted.
> 
> - This is used to make qcow’s and qcow2’s encrypt.format parameter
>   optional.  It now defaults to “from-image” which is a new
>   pseudo-format that allows a key-secret to be given, and otherwise
>   leaves it to the format driver to determine the encryption format.
> 
> - json:{} filenames are attempted to be typed correctly when they are
>   generated, by running bs->full_open_options through a healthy mix of
>   qdict_flatten(), the flat-confused input visitor for BlockdevOptions,
>   and the output visitor.
>   This may not always work but I hope it usually will.  Fingers crossed.
>   (At least it won’t make things worse.)
> 
> - Tests, tests, tests.
> 
> 
> (Yes, I know that “In this series tests, tests, tests.” is not a
>  sentence.)
> 
> 
> v4:
> - Drop the default-variant stuff and replace it by a more general
>   concept of allowing default values for all QAPI struct members
> 
> 
> git backport-diff against v3:
> 
> Key:
> [----] : patches are identical
> [####] : number of functional differences between upstream/downstream patch
> [down] : patch is downstream-only
> The flags [FC] indicate (F)unctional and (C)ontextual differences, respectively
> 
> 001/14:[down] 'qapi: Parse numeric values'
> 002/14:[down] 'qapi: Move to_c_string() to common.py'
> 003/14:[down] 'qapi: Introduce default values for struct members'
> 004/14:[down] 'qapi: Allow optional discriminators'
> 005/14:[down] 'qapi: Document default values for struct members'
> 006/14:[down] 'test-qapi: Print struct members' default values'
> 007/14:[down] 'tests: Test QAPI default values for struct members'
> 008/14:[0044] [FC] 'tests: Add QAPI optional discriminator tests'
> 009/14:[0009] [FC] 'qapi: Formalize qcow2 encryption probing'
> 010/14:[0005] [FC] 'qapi: Formalize qcow encryption probing'
> 011/14:[0014] [FC] 'block: Try to create well typed json:{} filenames'
> 012/14:[----] [--] 'iotests: Test internal option typing'
> 013/14:[----] [--] 'iotests: qcow2's encrypt.format is now optional'
> 014/14:[down] 'block: Make use of QAPI defaults'
> 
> 
> Max Reitz (14):
>   qapi: Parse numeric values
>   qapi: Move to_c_string() to common.py
>   qapi: Introduce default values for struct members
>   qapi: Allow optional discriminators
>   qapi: Document default values for struct members
>   test-qapi: Print struct members' default values
>   tests: Test QAPI default values for struct members
>   tests: Add QAPI optional discriminator tests
>   qapi: Formalize qcow2 encryption probing
>   qapi: Formalize qcow encryption probing
>   block: Try to create well typed json:{} filenames
>   iotests: Test internal option typing
>   iotests: qcow2's encrypt.format is now optional
>   block: Make use of QAPI defaults
> 
>  docs/devel/qapi-code-gen.txt                  |  81 +++++-
>  tests/Makefile.include                        |  17 +-
>  qapi/block-core.json                          | 180 +++++++++-----
>  qapi/introspect.json                          |   9 +-
>  tests/qapi-schema/bad-type-int.json           |   1 -
>  tests/qapi-schema/enum-int-member.json        |   1 -
>  ...l-discriminator-invalid-specification.json |  11 +
>  ...on-optional-discriminator-no-default.json} |   5 +-
>  tests/qapi-schema/qapi-schema-test.json       |  38 +++
>  .../struct-member-alternate-default.json      |  10 +
>  ...struct-member-bool-wrong-default-type.json |   3 +
>  .../struct-member-enum-invalid-default.json   |   4 +
>  ...struct-member-enum-wrong-default-type.json |   4 +
>  .../struct-member-float-invalid-default.json  |   4 +
>  ...truct-member-float-wrong-default-type.json |   3 +
>  .../struct-member-int-wrong-default-type.json |   3 +
>  .../struct-member-int8-erange-default.json    |   3 +
>  .../struct-member-list-nonempty-default.json  |   4 +
>  .../struct-member-non-optional-default.json   |   3 +
>  .../struct-member-null-default.json           |   6 +
>  .../struct-member-str-wrong-default-type.json |   3 +
>  .../struct-member-uint8-erange-default.json   |   3 +
>  .../struct-member-uint8-negative-default.json |   3 +
>  block.c                                       |  68 ++++-
>  block/file-posix.c                            |   9 -
>  block/file-win32.c                            |   8 +-
>  block/parallels.c                             |   6 +-
>  block/qcow2.c                                 |  39 +--
>  block/qed.c                                   |   3 -
>  block/sheepdog.c                              |   3 -
>  block/vdi.c                                   |   3 -
>  block/vhdx.c                                  |  28 +--
>  block/vpc.c                                   |   3 -
>  blockdev.c                                    | 182 +++-----------
>  monitor/hmp-cmds.c                            |  27 +-
>  monitor/qmp-cmds.c                            |   3 +-
>  scripts/qapi/commands.py                      |   2 +-
>  scripts/qapi/common.py                        | 232 ++++++++++++++++--
>  scripts/qapi/doc.py                           |  20 +-
>  scripts/qapi/introspect.py                    |   8 +-
>  scripts/qapi/types.py                         |   2 +-
>  scripts/qapi/visit.py                         |  38 ++-
>  tests/qapi-schema/bad-type-int.err            |   2 +-
>  tests/qapi-schema/enum-int-member.err         |   2 +-
>  ...al-discriminator-invalid-specification.err |   1 +
>  ...-discriminator-invalid-specification.exit} |   0
>  ...l-discriminator-invalid-specification.out} |   0
>  ...nion-optional-discriminator-no-default.err |   1 +
>  ...ion-optional-discriminator-no-default.exit |   1 +
>  ...nion-optional-discriminator-no-default.out |   0
>  .../flat-union-optional-discriminator.err     |   1 -
>  tests/qapi-schema/leading-comma-list.err      |   2 +-
>  tests/qapi-schema/qapi-schema-test.out        |  33 +++
>  .../struct-member-alternate-default.err       |   1 +
>  .../struct-member-alternate-default.exit      |   1 +
>  .../struct-member-alternate-default.out       |   0
>  .../struct-member-bool-wrong-default-type.err |   1 +
>  ...struct-member-bool-wrong-default-type.exit |   1 +
>  .../struct-member-bool-wrong-default-type.out |   0
>  .../struct-member-enum-invalid-default.err    |   1 +
>  .../struct-member-enum-invalid-default.exit   |   1 +
>  .../struct-member-enum-invalid-default.out    |   0
>  .../struct-member-enum-wrong-default-type.err |   1 +
>  ...struct-member-enum-wrong-default-type.exit |   1 +
>  .../struct-member-enum-wrong-default-type.out |   0
>  .../struct-member-float-invalid-default.err   |   1 +
>  .../struct-member-float-invalid-default.exit  |   1 +
>  .../struct-member-float-invalid-default.out   |   0
>  ...struct-member-float-wrong-default-type.err |   1 +
>  ...truct-member-float-wrong-default-type.exit |   1 +
>  ...struct-member-float-wrong-default-type.out |   0
>  .../struct-member-int-wrong-default-type.err  |   1 +
>  .../struct-member-int-wrong-default-type.exit |   1 +
>  .../struct-member-int-wrong-default-type.out  |   0
>  .../struct-member-int8-erange-default.err     |   1 +
>  .../struct-member-int8-erange-default.exit    |   1 +
>  .../struct-member-int8-erange-default.out     |   0
>  .../struct-member-list-nonempty-default.err   |   1 +
>  .../struct-member-list-nonempty-default.exit  |   1 +
>  .../struct-member-list-nonempty-default.out   |   0
>  .../struct-member-non-optional-default.err    |   1 +
>  .../struct-member-non-optional-default.exit   |   1 +
>  .../struct-member-non-optional-default.out    |   0
>  .../struct-member-null-default.err            |   1 +
>  .../struct-member-null-default.exit           |   1 +
>  .../struct-member-null-default.out            |   0
>  .../struct-member-str-wrong-default-type.err  |   1 +
>  .../struct-member-str-wrong-default-type.exit |   1 +
>  .../struct-member-str-wrong-default-type.out  |   0
>  .../struct-member-uint8-erange-default.err    |   1 +
>  .../struct-member-uint8-erange-default.exit   |   1 +
>  .../struct-member-uint8-erange-default.out    |   0
>  .../struct-member-uint8-negative-default.err  |   1 +
>  .../struct-member-uint8-negative-default.exit |   1 +
>  .../struct-member-uint8-negative-default.out  |   0
>  tests/qapi-schema/test-qapi.py                |   8 +-
>  tests/qemu-iotests/059.out                    |   2 +-
>  tests/qemu-iotests/087                        |  65 +++--
>  tests/qemu-iotests/087.out                    |  26 +-
>  tests/qemu-iotests/089                        |  25 ++
>  tests/qemu-iotests/089.out                    |   9 +
>  tests/qemu-iotests/099.out                    |   4 +-
>  tests/qemu-iotests/110.out                    |   2 +-
>  tests/qemu-iotests/198.out                    |   4 +-
>  104 files changed, 915 insertions(+), 384 deletions(-)
>  create mode 100644 tests/qapi-schema/flat-union-optional-discriminator-invalid-specification.json
>  rename tests/qapi-schema/{flat-union-optional-discriminator.json => flat-union-optional-discriminator-no-default.json} (68%)
>  create mode 100644 tests/qapi-schema/struct-member-alternate-default.json
>  create mode 100644 tests/qapi-schema/struct-member-bool-wrong-default-type.json
>  create mode 100644 tests/qapi-schema/struct-member-enum-invalid-default.json
>  create mode 100644 tests/qapi-schema/struct-member-enum-wrong-default-type.json
>  create mode 100644 tests/qapi-schema/struct-member-float-invalid-default.json
>  create mode 100644 tests/qapi-schema/struct-member-float-wrong-default-type.json
>  create mode 100644 tests/qapi-schema/struct-member-int-wrong-default-type.json
>  create mode 100644 tests/qapi-schema/struct-member-int8-erange-default.json
>  create mode 100644 tests/qapi-schema/struct-member-list-nonempty-default.json
>  create mode 100644 tests/qapi-schema/struct-member-non-optional-default.json
>  create mode 100644 tests/qapi-schema/struct-member-null-default.json
>  create mode 100644 tests/qapi-schema/struct-member-str-wrong-default-type.json
>  create mode 100644 tests/qapi-schema/struct-member-uint8-erange-default.json
>  create mode 100644 tests/qapi-schema/struct-member-uint8-negative-default.json
>  create mode 100644 tests/qapi-schema/flat-union-optional-discriminator-invalid-specification.err
>  rename tests/qapi-schema/{flat-union-optional-discriminator.exit => flat-union-optional-discriminator-invalid-specification.exit} (100%)
>  rename tests/qapi-schema/{flat-union-optional-discriminator.out => flat-union-optional-discriminator-invalid-specification.out} (100%)
>  create mode 100644 tests/qapi-schema/flat-union-optional-discriminator-no-default.err
>  create mode 100644 tests/qapi-schema/flat-union-optional-discriminator-no-default.exit
>  create mode 100644 tests/qapi-schema/flat-union-optional-discriminator-no-default.out
>  delete mode 100644 tests/qapi-schema/flat-union-optional-discriminator.err
>  create mode 100644 tests/qapi-schema/struct-member-alternate-default.err
>  create mode 100644 tests/qapi-schema/struct-member-alternate-default.exit
>  create mode 100644 tests/qapi-schema/struct-member-alternate-default.out
>  create mode 100644 tests/qapi-schema/struct-member-bool-wrong-default-type.err
>  create mode 100644 tests/qapi-schema/struct-member-bool-wrong-default-type.exit
>  create mode 100644 tests/qapi-schema/struct-member-bool-wrong-default-type.out
>  create mode 100644 tests/qapi-schema/struct-member-enum-invalid-default.err
>  create mode 100644 tests/qapi-schema/struct-member-enum-invalid-default.exit
>  create mode 100644 tests/qapi-schema/struct-member-enum-invalid-default.out
>  create mode 100644 tests/qapi-schema/struct-member-enum-wrong-default-type.err
>  create mode 100644 tests/qapi-schema/struct-member-enum-wrong-default-type.exit
>  create mode 100644 tests/qapi-schema/struct-member-enum-wrong-default-type.out
>  create mode 100644 tests/qapi-schema/struct-member-float-invalid-default.err
>  create mode 100644 tests/qapi-schema/struct-member-float-invalid-default.exit
>  create mode 100644 tests/qapi-schema/struct-member-float-invalid-default.out
>  create mode 100644 tests/qapi-schema/struct-member-float-wrong-default-type.err
>  create mode 100644 tests/qapi-schema/struct-member-float-wrong-default-type.exit
>  create mode 100644 tests/qapi-schema/struct-member-float-wrong-default-type.out
>  create mode 100644 tests/qapi-schema/struct-member-int-wrong-default-type.err
>  create mode 100644 tests/qapi-schema/struct-member-int-wrong-default-type.exit
>  create mode 100644 tests/qapi-schema/struct-member-int-wrong-default-type.out
>  create mode 100644 tests/qapi-schema/struct-member-int8-erange-default.err
>  create mode 100644 tests/qapi-schema/struct-member-int8-erange-default.exit
>  create mode 100644 tests/qapi-schema/struct-member-int8-erange-default.out
>  create mode 100644 tests/qapi-schema/struct-member-list-nonempty-default.err
>  create mode 100644 tests/qapi-schema/struct-member-list-nonempty-default.exit
>  create mode 100644 tests/qapi-schema/struct-member-list-nonempty-default.out
>  create mode 100644 tests/qapi-schema/struct-member-non-optional-default.err
>  create mode 100644 tests/qapi-schema/struct-member-non-optional-default.exit
>  create mode 100644 tests/qapi-schema/struct-member-non-optional-default.out
>  create mode 100644 tests/qapi-schema/struct-member-null-default.err
>  create mode 100644 tests/qapi-schema/struct-member-null-default.exit
>  create mode 100644 tests/qapi-schema/struct-member-null-default.out
>  create mode 100644 tests/qapi-schema/struct-member-str-wrong-default-type.err
>  create mode 100644 tests/qapi-schema/struct-member-str-wrong-default-type.exit
>  create mode 100644 tests/qapi-schema/struct-member-str-wrong-default-type.out
>  create mode 100644 tests/qapi-schema/struct-member-uint8-erange-default.err
>  create mode 100644 tests/qapi-schema/struct-member-uint8-erange-default.exit
>  create mode 100644 tests/qapi-schema/struct-member-uint8-erange-default.out
>  create mode 100644 tests/qapi-schema/struct-member-uint8-negative-default.err
>  create mode 100644 tests/qapi-schema/struct-member-uint8-negative-default.exit
>  create mode 100644 tests/qapi-schema/struct-member-uint8-negative-default.out
> 


Re: [PATCH v4 00/14] block: Try to create well-typed json:{} filenames
Posted by Max Reitz 4 years, 5 months ago
On 13.09.19 13:49, Max Reitz wrote:
> Another gentle ping.

And another.

Max

Re: [PATCH v4 00/14] block: Try to create well-typed json:{} filenames
Posted by Markus Armbruster 4 years, 5 months ago
Max Reitz <mreitz@redhat.com> writes:

> On 13.09.19 13:49, Max Reitz wrote:
>> Another gentle ping.
>
> And another.

Conflicts with the refactoring merged in commit 69717d0f890.  Please
accept my apologies for the inconvenience caused by the excessive delay.

I'll try to review anyway.


Re: [PATCH v4 00/14] block: Try to create well-typed json:{} filenames
Posted by Markus Armbruster 4 years, 5 months ago
Markus Armbruster <armbru@redhat.com> writes:

> Max Reitz <mreitz@redhat.com> writes:
>
>> On 13.09.19 13:49, Max Reitz wrote:
>>> Another gentle ping.
>>
>> And another.
>
> Conflicts with the refactoring merged in commit 69717d0f890.  Please
> accept my apologies for the inconvenience caused by the excessive delay.
>
> I'll try to review anyway.

I reviewed the proposed changes to the QAPI schema language, and they
look reasonable enough to justify a rebase.

Thanks!


Re: [Qemu-devel] [PATCH v4 00/14] block: Try to create well-typed json:{} filenames
Posted by Max Reitz 4 years, 8 months ago
Ping

On 24.06.19 19:39, Max Reitz wrote:
> Hi,
> 
> There are two explanations of this cover letter, a relative one (to v3)
> and an absolute one.
> 
> 
> *** Important note ***
> 
> The final patch in this series is an example that converts most of
> block-core.json to use default values where possible.  We may decide to
> take it or not.  It isn’t important for the main purpose of this series,
> so I’d be very much fine with chopping it off.
> 
> (It does have a nice diff stat, though.)
> 
> *** Important note end ***
> 
> 
> Relative explanation:
> 
> The actual functional goal of this series is to allow all blockdev
> options that can be represented with -drive to have an equivalent with
> -blockdev (safe for rbd’s =keyvalue-pairs).
> 
> To this end, qcow(2)’s encryption needs an “auto” format which can
> automatically deduce the format from the image header.  To make things
> nicer, I decided (already in v1) to make this format optional so users
> could just specify encrypt.secret and let the format driver figure out
> the rest.
> 
> Until v3, this was implemented by letting the discriminator of flat
> unions be optional, as long as a default-value is provided.  Markus
> (rightfully) complained that this is very specific and would be covered
> by just having default values for QAPI struct members in general.
> So now this version implements this.  This is a bit more complicated
> than just implementing a default-variant, mainly because the latter only
> needs to accept enum values, whereas a generally usable “default” should
> accept values of all QAPI types (to the extent what is reasonable).
> 
> So what was (until v3)
> 
>   { 'union': 'Foo',
>     'base': { '*discr': 'SomeEnum' },
>     'discriminator': 'discr',
>     'default-variant': 'value1',
>     'data': { 'value1': 'Bar', 'value2': 'Baz' } }
> 
> becomes
> 
>   { 'union': 'Foo',
>     'base': { '*discr': { 'type': 'SomeEnum', 'default': 'value1' } },
>     'discriminator': 'discr',
>     'data': { 'value1': 'Bar', 'value2': 'Baz' } }
> 
> 
> 
> Absolute explanation:
> 
> When qemu reports json:{} filename, it just uses whatever type you gave
> an option in.  With -drive, all options are strings and they do not have
> to pass the test of the typing firewall of the QAPI schema, so you just
> get strings thrown back at you even if that does not match the schema.
> (Also, if you use json:{} yourself, you’re free to give the options as
> strings as well.)
> 
> Example:
> 
> $ ./qemu-img info --image-opts driver=raw,size=512,file.driver=null-co
> image: json:{"driver": "raw", "size": "512", "file": {"driver": "null-co"}}
> 
> @size is supposed to be an integer, according to the schema, so the
> correct result would be (which is what you get after this series):
> 
> $ ./qemu-img info --image-opts driver=raw,size=512,file.driver=null-co
> image: json:{"driver": "raw", "size": 512, "file": {"driver": "null-co"}}
> 
> 
> This is achieved by patch 11, which makes bdrv_refresh_filename() run
> the options through the flat-confused input visitor, and then through
> the output visitor to get all to the correct type.  If anything fails,
> the result is as before (hence the “Try” in the title).
> 
> There are cases where this cannot work.  Those are the ones where -drive
> accepts something that is not allowed by the QAPI schema.  One of these
> cases is rbd’s =keyvalue-pairs, which is just broken altogether, so
> let’s simply ignore that.  (I don’t think anybody’s going to complain
> that the json:{} filename they get is not correctly typed after they’ve
> used that option.)
> 
> The other case (I know of) is qcow(2)’s encryption.  In the QAPI schema,
> encrypt.format is not optional because it is the discriminator for which
> kind of options to use.  However, for -drive, it is optional because the
> qcow2 driver can infer the encryption format from the image header.
> 
> The solution that’s proposed by this series is to make flat union
> discriminators optional and provide a default.  This is accomplished by
> generally allowing default values to be provided for QAPI struct
> members.
> 
> Both AES and LUKS encryption allow only a key-secret option, so we can
> add a new pseudo-format “auto” that accepts exactly that option and
> makes the qcow2 driver read the real format from the image header.  This
> pseudo-format is made the default for encrypt.format, and thus you can
> then specify encrypt.key-secret without having to specify
> encrypt.format (while still adhering to the QAPI schema).
> 
> 
> So, in this series:
> - The QAPI code generator is modified to allow default values for
>   optional struct members.  This in turn allows flat union
>   discriminators be optional, too, but only if a default value is
>   provided.
>   - Accordingly, documentation, tests, and introspection are adjusted.
> 
> - This is used to make qcow’s and qcow2’s encrypt.format parameter
>   optional.  It now defaults to “from-image” which is a new
>   pseudo-format that allows a key-secret to be given, and otherwise
>   leaves it to the format driver to determine the encryption format.
> 
> - json:{} filenames are attempted to be typed correctly when they are
>   generated, by running bs->full_open_options through a healthy mix of
>   qdict_flatten(), the flat-confused input visitor for BlockdevOptions,
>   and the output visitor.
>   This may not always work but I hope it usually will.  Fingers crossed.
>   (At least it won’t make things worse.)
> 
> - Tests, tests, tests.
> 
> 
> (Yes, I know that “In this series tests, tests, tests.” is not a
>  sentence.)
> 
> 
> v4:
> - Drop the default-variant stuff and replace it by a more general
>   concept of allowing default values for all QAPI struct members
> 
> 
> git backport-diff against v3:
> 
> Key:
> [----] : patches are identical
> [####] : number of functional differences between upstream/downstream patch
> [down] : patch is downstream-only
> The flags [FC] indicate (F)unctional and (C)ontextual differences, respectively
> 
> 001/14:[down] 'qapi: Parse numeric values'
> 002/14:[down] 'qapi: Move to_c_string() to common.py'
> 003/14:[down] 'qapi: Introduce default values for struct members'
> 004/14:[down] 'qapi: Allow optional discriminators'
> 005/14:[down] 'qapi: Document default values for struct members'
> 006/14:[down] 'test-qapi: Print struct members' default values'
> 007/14:[down] 'tests: Test QAPI default values for struct members'
> 008/14:[0044] [FC] 'tests: Add QAPI optional discriminator tests'
> 009/14:[0009] [FC] 'qapi: Formalize qcow2 encryption probing'
> 010/14:[0005] [FC] 'qapi: Formalize qcow encryption probing'
> 011/14:[0014] [FC] 'block: Try to create well typed json:{} filenames'
> 012/14:[----] [--] 'iotests: Test internal option typing'
> 013/14:[----] [--] 'iotests: qcow2's encrypt.format is now optional'
> 014/14:[down] 'block: Make use of QAPI defaults'
> 
> 
> Max Reitz (14):
>   qapi: Parse numeric values
>   qapi: Move to_c_string() to common.py
>   qapi: Introduce default values for struct members
>   qapi: Allow optional discriminators
>   qapi: Document default values for struct members
>   test-qapi: Print struct members' default values
>   tests: Test QAPI default values for struct members
>   tests: Add QAPI optional discriminator tests
>   qapi: Formalize qcow2 encryption probing
>   qapi: Formalize qcow encryption probing
>   block: Try to create well typed json:{} filenames
>   iotests: Test internal option typing
>   iotests: qcow2's encrypt.format is now optional
>   block: Make use of QAPI defaults
> 
>  docs/devel/qapi-code-gen.txt                  |  81 +++++-
>  tests/Makefile.include                        |  17 +-
>  qapi/block-core.json                          | 180 +++++++++-----
>  qapi/introspect.json                          |   9 +-
>  tests/qapi-schema/bad-type-int.json           |   1 -
>  tests/qapi-schema/enum-int-member.json        |   1 -
>  ...l-discriminator-invalid-specification.json |  11 +
>  ...on-optional-discriminator-no-default.json} |   5 +-
>  tests/qapi-schema/qapi-schema-test.json       |  38 +++
>  .../struct-member-alternate-default.json      |  10 +
>  ...struct-member-bool-wrong-default-type.json |   3 +
>  .../struct-member-enum-invalid-default.json   |   4 +
>  ...struct-member-enum-wrong-default-type.json |   4 +
>  .../struct-member-float-invalid-default.json  |   4 +
>  ...truct-member-float-wrong-default-type.json |   3 +
>  .../struct-member-int-wrong-default-type.json |   3 +
>  .../struct-member-int8-erange-default.json    |   3 +
>  .../struct-member-list-nonempty-default.json  |   4 +
>  .../struct-member-non-optional-default.json   |   3 +
>  .../struct-member-null-default.json           |   6 +
>  .../struct-member-str-wrong-default-type.json |   3 +
>  .../struct-member-uint8-erange-default.json   |   3 +
>  .../struct-member-uint8-negative-default.json |   3 +
>  block.c                                       |  68 ++++-
>  block/file-posix.c                            |   9 -
>  block/file-win32.c                            |   8 +-
>  block/parallels.c                             |   6 +-
>  block/qcow2.c                                 |  39 +--
>  block/qed.c                                   |   3 -
>  block/sheepdog.c                              |   3 -
>  block/vdi.c                                   |   3 -
>  block/vhdx.c                                  |  28 +--
>  block/vpc.c                                   |   3 -
>  blockdev.c                                    | 182 +++-----------
>  monitor/hmp-cmds.c                            |  27 +-
>  monitor/qmp-cmds.c                            |   3 +-
>  scripts/qapi/commands.py                      |   2 +-
>  scripts/qapi/common.py                        | 232 ++++++++++++++++--
>  scripts/qapi/doc.py                           |  20 +-
>  scripts/qapi/introspect.py                    |   8 +-
>  scripts/qapi/types.py                         |   2 +-
>  scripts/qapi/visit.py                         |  38 ++-
>  tests/qapi-schema/bad-type-int.err            |   2 +-
>  tests/qapi-schema/enum-int-member.err         |   2 +-
>  ...al-discriminator-invalid-specification.err |   1 +
>  ...-discriminator-invalid-specification.exit} |   0
>  ...l-discriminator-invalid-specification.out} |   0
>  ...nion-optional-discriminator-no-default.err |   1 +
>  ...ion-optional-discriminator-no-default.exit |   1 +
>  ...nion-optional-discriminator-no-default.out |   0
>  .../flat-union-optional-discriminator.err     |   1 -
>  tests/qapi-schema/leading-comma-list.err      |   2 +-
>  tests/qapi-schema/qapi-schema-test.out        |  33 +++
>  .../struct-member-alternate-default.err       |   1 +
>  .../struct-member-alternate-default.exit      |   1 +
>  .../struct-member-alternate-default.out       |   0
>  .../struct-member-bool-wrong-default-type.err |   1 +
>  ...struct-member-bool-wrong-default-type.exit |   1 +
>  .../struct-member-bool-wrong-default-type.out |   0
>  .../struct-member-enum-invalid-default.err    |   1 +
>  .../struct-member-enum-invalid-default.exit   |   1 +
>  .../struct-member-enum-invalid-default.out    |   0
>  .../struct-member-enum-wrong-default-type.err |   1 +
>  ...struct-member-enum-wrong-default-type.exit |   1 +
>  .../struct-member-enum-wrong-default-type.out |   0
>  .../struct-member-float-invalid-default.err   |   1 +
>  .../struct-member-float-invalid-default.exit  |   1 +
>  .../struct-member-float-invalid-default.out   |   0
>  ...struct-member-float-wrong-default-type.err |   1 +
>  ...truct-member-float-wrong-default-type.exit |   1 +
>  ...struct-member-float-wrong-default-type.out |   0
>  .../struct-member-int-wrong-default-type.err  |   1 +
>  .../struct-member-int-wrong-default-type.exit |   1 +
>  .../struct-member-int-wrong-default-type.out  |   0
>  .../struct-member-int8-erange-default.err     |   1 +
>  .../struct-member-int8-erange-default.exit    |   1 +
>  .../struct-member-int8-erange-default.out     |   0
>  .../struct-member-list-nonempty-default.err   |   1 +
>  .../struct-member-list-nonempty-default.exit  |   1 +
>  .../struct-member-list-nonempty-default.out   |   0
>  .../struct-member-non-optional-default.err    |   1 +
>  .../struct-member-non-optional-default.exit   |   1 +
>  .../struct-member-non-optional-default.out    |   0
>  .../struct-member-null-default.err            |   1 +
>  .../struct-member-null-default.exit           |   1 +
>  .../struct-member-null-default.out            |   0
>  .../struct-member-str-wrong-default-type.err  |   1 +
>  .../struct-member-str-wrong-default-type.exit |   1 +
>  .../struct-member-str-wrong-default-type.out  |   0
>  .../struct-member-uint8-erange-default.err    |   1 +
>  .../struct-member-uint8-erange-default.exit   |   1 +
>  .../struct-member-uint8-erange-default.out    |   0
>  .../struct-member-uint8-negative-default.err  |   1 +
>  .../struct-member-uint8-negative-default.exit |   1 +
>  .../struct-member-uint8-negative-default.out  |   0
>  tests/qapi-schema/test-qapi.py                |   8 +-
>  tests/qemu-iotests/059.out                    |   2 +-
>  tests/qemu-iotests/087                        |  65 +++--
>  tests/qemu-iotests/087.out                    |  26 +-
>  tests/qemu-iotests/089                        |  25 ++
>  tests/qemu-iotests/089.out                    |   9 +
>  tests/qemu-iotests/099.out                    |   4 +-
>  tests/qemu-iotests/110.out                    |   2 +-
>  tests/qemu-iotests/198.out                    |   4 +-
>  104 files changed, 915 insertions(+), 384 deletions(-)
>  create mode 100644 tests/qapi-schema/flat-union-optional-discriminator-invalid-specification.json
>  rename tests/qapi-schema/{flat-union-optional-discriminator.json => flat-union-optional-discriminator-no-default.json} (68%)
>  create mode 100644 tests/qapi-schema/struct-member-alternate-default.json
>  create mode 100644 tests/qapi-schema/struct-member-bool-wrong-default-type.json
>  create mode 100644 tests/qapi-schema/struct-member-enum-invalid-default.json
>  create mode 100644 tests/qapi-schema/struct-member-enum-wrong-default-type.json
>  create mode 100644 tests/qapi-schema/struct-member-float-invalid-default.json
>  create mode 100644 tests/qapi-schema/struct-member-float-wrong-default-type.json
>  create mode 100644 tests/qapi-schema/struct-member-int-wrong-default-type.json
>  create mode 100644 tests/qapi-schema/struct-member-int8-erange-default.json
>  create mode 100644 tests/qapi-schema/struct-member-list-nonempty-default.json
>  create mode 100644 tests/qapi-schema/struct-member-non-optional-default.json
>  create mode 100644 tests/qapi-schema/struct-member-null-default.json
>  create mode 100644 tests/qapi-schema/struct-member-str-wrong-default-type.json
>  create mode 100644 tests/qapi-schema/struct-member-uint8-erange-default.json
>  create mode 100644 tests/qapi-schema/struct-member-uint8-negative-default.json
>  create mode 100644 tests/qapi-schema/flat-union-optional-discriminator-invalid-specification.err
>  rename tests/qapi-schema/{flat-union-optional-discriminator.exit => flat-union-optional-discriminator-invalid-specification.exit} (100%)
>  rename tests/qapi-schema/{flat-union-optional-discriminator.out => flat-union-optional-discriminator-invalid-specification.out} (100%)
>  create mode 100644 tests/qapi-schema/flat-union-optional-discriminator-no-default.err
>  create mode 100644 tests/qapi-schema/flat-union-optional-discriminator-no-default.exit
>  create mode 100644 tests/qapi-schema/flat-union-optional-discriminator-no-default.out
>  delete mode 100644 tests/qapi-schema/flat-union-optional-discriminator.err
>  create mode 100644 tests/qapi-schema/struct-member-alternate-default.err
>  create mode 100644 tests/qapi-schema/struct-member-alternate-default.exit
>  create mode 100644 tests/qapi-schema/struct-member-alternate-default.out
>  create mode 100644 tests/qapi-schema/struct-member-bool-wrong-default-type.err
>  create mode 100644 tests/qapi-schema/struct-member-bool-wrong-default-type.exit
>  create mode 100644 tests/qapi-schema/struct-member-bool-wrong-default-type.out
>  create mode 100644 tests/qapi-schema/struct-member-enum-invalid-default.err
>  create mode 100644 tests/qapi-schema/struct-member-enum-invalid-default.exit
>  create mode 100644 tests/qapi-schema/struct-member-enum-invalid-default.out
>  create mode 100644 tests/qapi-schema/struct-member-enum-wrong-default-type.err
>  create mode 100644 tests/qapi-schema/struct-member-enum-wrong-default-type.exit
>  create mode 100644 tests/qapi-schema/struct-member-enum-wrong-default-type.out
>  create mode 100644 tests/qapi-schema/struct-member-float-invalid-default.err
>  create mode 100644 tests/qapi-schema/struct-member-float-invalid-default.exit
>  create mode 100644 tests/qapi-schema/struct-member-float-invalid-default.out
>  create mode 100644 tests/qapi-schema/struct-member-float-wrong-default-type.err
>  create mode 100644 tests/qapi-schema/struct-member-float-wrong-default-type.exit
>  create mode 100644 tests/qapi-schema/struct-member-float-wrong-default-type.out
>  create mode 100644 tests/qapi-schema/struct-member-int-wrong-default-type.err
>  create mode 100644 tests/qapi-schema/struct-member-int-wrong-default-type.exit
>  create mode 100644 tests/qapi-schema/struct-member-int-wrong-default-type.out
>  create mode 100644 tests/qapi-schema/struct-member-int8-erange-default.err
>  create mode 100644 tests/qapi-schema/struct-member-int8-erange-default.exit
>  create mode 100644 tests/qapi-schema/struct-member-int8-erange-default.out
>  create mode 100644 tests/qapi-schema/struct-member-list-nonempty-default.err
>  create mode 100644 tests/qapi-schema/struct-member-list-nonempty-default.exit
>  create mode 100644 tests/qapi-schema/struct-member-list-nonempty-default.out
>  create mode 100644 tests/qapi-schema/struct-member-non-optional-default.err
>  create mode 100644 tests/qapi-schema/struct-member-non-optional-default.exit
>  create mode 100644 tests/qapi-schema/struct-member-non-optional-default.out
>  create mode 100644 tests/qapi-schema/struct-member-null-default.err
>  create mode 100644 tests/qapi-schema/struct-member-null-default.exit
>  create mode 100644 tests/qapi-schema/struct-member-null-default.out
>  create mode 100644 tests/qapi-schema/struct-member-str-wrong-default-type.err
>  create mode 100644 tests/qapi-schema/struct-member-str-wrong-default-type.exit
>  create mode 100644 tests/qapi-schema/struct-member-str-wrong-default-type.out
>  create mode 100644 tests/qapi-schema/struct-member-uint8-erange-default.err
>  create mode 100644 tests/qapi-schema/struct-member-uint8-erange-default.exit
>  create mode 100644 tests/qapi-schema/struct-member-uint8-erange-default.out
>  create mode 100644 tests/qapi-schema/struct-member-uint8-negative-default.err
>  create mode 100644 tests/qapi-schema/struct-member-uint8-negative-default.exit
>  create mode 100644 tests/qapi-schema/struct-member-uint8-negative-default.out
> 


Re: [Qemu-devel] [PATCH v4 00/14] block: Try to create well-typed json:{} filenames
Posted by no-reply@patchew.org 4 years, 10 months ago
Patchew URL: https://patchew.org/QEMU/20190624173935.25747-1-mreitz@redhat.com/



Hi,

This series failed the asan 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-fedora V=1 NETWORK=1
time make docker-test-debug@fedora TARGET_LIST=x86_64-softmmu J=14 NETWORK=1
=== TEST SCRIPT END ===

PASS 1 fdc-test /x86_64/fdc/cmos
PASS 2 fdc-test /x86_64/fdc/no_media_on_start
PASS 3 fdc-test /x86_64/fdc/read_without_media
==11234==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 4 fdc-test /x86_64/fdc/media_change
PASS 5 fdc-test /x86_64/fdc/sense_interrupt
PASS 6 fdc-test /x86_64/fdc/relative_seek
---
PASS 32 test-opts-visitor /visitor/opts/range/beyond
PASS 33 test-opts-visitor /visitor/opts/dict/unvisited
MALLOC_PERTURB_=${MALLOC_PERTURB_:-$(( ${RANDOM:-0} % 255 + 1))}  tests/test-coroutine -m=quick -k --tap < /dev/null | ./scripts/tap-driver.pl --test-name="test-coroutine" 
==11269==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 1 test-coroutine /basic/no-dangling-access
==11269==WARNING: ASan is ignoring requested __asan_handle_no_return: stack top: 0x7ffd309dc000; bottom 0x7f41b90f8000; size: 0x00bb778e4000 (805164695552)
False positive error reports may follow
For details see https://github.com/google/sanitizers/issues/189
PASS 2 test-coroutine /basic/lifecycle
---
PASS 11 test-aio /aio/event/wait
PASS 12 test-aio /aio/event/flush
PASS 13 test-aio /aio/event/wait/no-flush-cb
==11284==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 14 test-aio /aio/timer/schedule
PASS 15 test-aio /aio/coroutine/queue-chaining
PASS 16 test-aio /aio-gsource/flush
---
MALLOC_PERTURB_=${MALLOC_PERTURB_:-$(( ${RANDOM:-0} % 255 + 1))}  tests/test-aio-multithread -m=quick -k --tap < /dev/null | ./scripts/tap-driver.pl --test-name="test-aio-multithread" 
PASS 12 fdc-test /x86_64/fdc/read_no_dma_19
PASS 13 fdc-test /x86_64/fdc/fuzz-registers
==11290==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 1 test-aio-multithread /aio/multi/lifecycle
MALLOC_PERTURB_=${MALLOC_PERTURB_:-$(( ${RANDOM:-0} % 255 + 1))}  QTEST_QEMU_BINARY=x86_64-softmmu/qemu-system-x86_64 QTEST_QEMU_IMG=qemu-img tests/ide-test -m=quick -k --tap < /dev/null | ./scripts/tap-driver.pl --test-name="ide-test" 
PASS 2 test-aio-multithread /aio/multi/schedule
==11308==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 3 test-aio-multithread /aio/multi/mutex/contended
PASS 1 ide-test /x86_64/ide/identify
==11324==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 2 ide-test /x86_64/ide/flush
==11330==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 3 ide-test /x86_64/ide/bmdma/simple_rw
PASS 4 test-aio-multithread /aio/multi/mutex/handoff
==11336==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 4 ide-test /x86_64/ide/bmdma/trim
PASS 5 test-aio-multithread /aio/multi/mutex/mcs
==11347==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 5 ide-test /x86_64/ide/bmdma/short_prdt
PASS 6 test-aio-multithread /aio/multi/mutex/pthread
MALLOC_PERTURB_=${MALLOC_PERTURB_:-$(( ${RANDOM:-0} % 255 + 1))}  tests/test-throttle -m=quick -k --tap < /dev/null | ./scripts/tap-driver.pl --test-name="test-throttle" 
==11358==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
==11362==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 1 test-throttle /throttle/leak_bucket
PASS 2 test-throttle /throttle/compute_wait
PASS 3 test-throttle /throttle/init
---
PASS 15 test-throttle /throttle/config/iops_size
MALLOC_PERTURB_=${MALLOC_PERTURB_:-$(( ${RANDOM:-0} % 255 + 1))}  tests/test-thread-pool -m=quick -k --tap < /dev/null | ./scripts/tap-driver.pl --test-name="test-thread-pool" 
PASS 6 ide-test /x86_64/ide/bmdma/one_sector_short_prdt
==11371==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 1 test-thread-pool /thread-pool/submit
PASS 2 test-thread-pool /thread-pool/submit-aio
PASS 3 test-thread-pool /thread-pool/submit-co
PASS 4 test-thread-pool /thread-pool/submit-many
==11373==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 7 ide-test /x86_64/ide/bmdma/long_prdt
==11445==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 5 test-thread-pool /thread-pool/cancel
==11445==WARNING: ASan is ignoring requested __asan_handle_no_return: stack top: 0x7ffe141a1000; bottom 0x7fd799ffe000; size: 0x00267a1a3000 (165257293824)
False positive error reports may follow
For details see https://github.com/google/sanitizers/issues/189
PASS 8 ide-test /x86_64/ide/bmdma/no_busmaster
PASS 9 ide-test /x86_64/ide/flush/nodev
PASS 6 test-thread-pool /thread-pool/cancel-async
==11456==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
MALLOC_PERTURB_=${MALLOC_PERTURB_:-$(( ${RANDOM:-0} % 255 + 1))}  tests/test-hbitmap -m=quick -k --tap < /dev/null | ./scripts/tap-driver.pl --test-name="test-hbitmap" 
PASS 10 ide-test /x86_64/ide/flush/empty_drive
PASS 1 test-hbitmap /hbitmap/granularity
PASS 2 test-hbitmap /hbitmap/size/0
PASS 3 test-hbitmap /hbitmap/size/unaligned
PASS 4 test-hbitmap /hbitmap/iter/empty
==11466==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 5 test-hbitmap /hbitmap/iter/partial
PASS 11 ide-test /x86_64/ide/flush/retry_pci
PASS 6 test-hbitmap /hbitmap/iter/granularity
---
PASS 10 test-hbitmap /hbitmap/set/all
PASS 11 test-hbitmap /hbitmap/set/one
PASS 12 test-hbitmap /hbitmap/set/two-elem
==11472==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 13 test-hbitmap /hbitmap/set/general
PASS 14 test-hbitmap /hbitmap/set/twice
PASS 12 ide-test /x86_64/ide/flush/retry_isa
PASS 15 test-hbitmap /hbitmap/set/overlap
PASS 16 test-hbitmap /hbitmap/reset/empty
==11478==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 17 test-hbitmap /hbitmap/reset/general
PASS 13 ide-test /x86_64/ide/cdrom/pio
PASS 18 test-hbitmap /hbitmap/reset/all
---
PASS 28 test-hbitmap /hbitmap/truncate/shrink/medium
PASS 29 test-hbitmap /hbitmap/truncate/shrink/large
PASS 30 test-hbitmap /hbitmap/meta/zero
==11484==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 14 ide-test /x86_64/ide/cdrom/pio_large
==11490==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 15 ide-test /x86_64/ide/cdrom/dma
MALLOC_PERTURB_=${MALLOC_PERTURB_:-$(( ${RANDOM:-0} % 255 + 1))}  QTEST_QEMU_BINARY=x86_64-softmmu/qemu-system-x86_64 QTEST_QEMU_IMG=qemu-img tests/ahci-test -m=quick -k --tap < /dev/null | ./scripts/tap-driver.pl --test-name="ahci-test" 
==11504==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 1 ahci-test /x86_64/ahci/sanity
==11510==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 31 test-hbitmap /hbitmap/meta/one
PASS 32 test-hbitmap /hbitmap/meta/byte
PASS 33 test-hbitmap /hbitmap/meta/word
PASS 2 ahci-test /x86_64/ahci/pci_spec
==11516==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 34 test-hbitmap /hbitmap/meta/sector
PASS 35 test-hbitmap /hbitmap/serialize/align
PASS 3 ahci-test /x86_64/ahci/pci_enable
==11522==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 4 ahci-test /x86_64/ahci/hba_spec
==11528==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 36 test-hbitmap /hbitmap/serialize/basic
PASS 37 test-hbitmap /hbitmap/serialize/part
PASS 38 test-hbitmap /hbitmap/serialize/zeroes
---
PASS 43 test-hbitmap /hbitmap/next_dirty_area/next_dirty_area_4
MALLOC_PERTURB_=${MALLOC_PERTURB_:-$(( ${RANDOM:-0} % 255 + 1))}  tests/test-bdrv-drain -m=quick -k --tap < /dev/null | ./scripts/tap-driver.pl --test-name="test-bdrv-drain" 
PASS 5 ahci-test /x86_64/ahci/hba_enable
==11536==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 1 test-bdrv-drain /bdrv-drain/nested
PASS 2 test-bdrv-drain /bdrv-drain/multiparent
PASS 3 test-bdrv-drain /bdrv-drain/set_aio_context
---
PASS 29 test-bdrv-drain /bdrv-drain/blockjob/iothread/drain_subtree
PASS 30 test-bdrv-drain /bdrv-drain/blockjob/iothread/error/drain_all
PASS 31 test-bdrv-drain /bdrv-drain/blockjob/iothread/error/drain
==11539==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 32 test-bdrv-drain /bdrv-drain/blockjob/iothread/error/drain_subtree
PASS 33 test-bdrv-drain /bdrv-drain/deletion/drain
PASS 34 test-bdrv-drain /bdrv-drain/detach/drain_all
---
PASS 38 test-bdrv-drain /bdrv-drain/detach/driver_cb
PASS 39 test-bdrv-drain /bdrv-drain/attach/drain
PASS 6 ahci-test /x86_64/ahci/identify
==11582==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!

=================================================================
==11536==ERROR: LeakSanitizer: detected memory leaks

Indirect leak of 4120 byte(s) in 1 object(s) allocated from:
    #0 0x56245fee9d3e in calloc (/tmp/qemu-test/build/tests/test-bdrv-drain+0x52fd3e)
---

SUMMARY: AddressSanitizer: 441420 byte(s) leaked in 525 allocation(s).
MALLOC_PERTURB_=${MALLOC_PERTURB_:-$(( ${RANDOM:-0} % 255 + 1))}  tests/test-bdrv-graph-mod -m=quick -k --tap < /dev/null | ./scripts/tap-driver.pl --test-name="test-bdrv-graph-mod" 
==11590==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 1 test-bdrv-graph-mod /bdrv-graph-mod/update-perm-tree
PASS 2 test-bdrv-graph-mod /bdrv-graph-mod/should-update-child
==11588==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!

=================================================================
==11590==ERROR: LeakSanitizer: detected memory leaks

Indirect leak of 4120 byte(s) in 1 object(s) allocated from:
    #0 0x562c894fdd2e in calloc (/tmp/qemu-test/build/tests/test-bdrv-graph-mod+0x523d2e)
---
SUMMARY: AddressSanitizer: 12621 byte(s) leaked in 15 allocation(s).
MALLOC_PERTURB_=${MALLOC_PERTURB_:-$(( ${RANDOM:-0} % 255 + 1))}  tests/test-blockjob -m=quick -k --tap < /dev/null | ./scripts/tap-driver.pl --test-name="test-blockjob" 
PASS 8 ahci-test /x86_64/ahci/reset
==11601==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 1 test-blockjob /blockjob/ids
PASS 2 test-blockjob /blockjob/cancel/created
PASS 3 test-blockjob /blockjob/cancel/running
---
PASS 7 test-blockjob /blockjob/cancel/pending
PASS 8 test-blockjob /blockjob/cancel/concluded
MALLOC_PERTURB_=${MALLOC_PERTURB_:-$(( ${RANDOM:-0} % 255 + 1))}  tests/test-blockjob-txn -m=quick -k --tap < /dev/null | ./scripts/tap-driver.pl --test-name="test-blockjob-txn" 
==11603==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
==11607==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 1 test-blockjob-txn /single/success
PASS 2 test-blockjob-txn /single/failure
PASS 3 test-blockjob-txn /single/cancel
---
PASS 5 test-blockjob-txn /pair/failure
PASS 6 test-blockjob-txn /pair/cancel
PASS 7 test-blockjob-txn /pair/fail-cancel-race
==11603==WARNING: ASan is ignoring requested __asan_handle_no_return: stack top: 0x7ffc1625a000; bottom 0x7f3ddf3fe000; size: 0x00be36e5c000 (816964812800)
False positive error reports may follow
For details see https://github.com/google/sanitizers/issues/189
MALLOC_PERTURB_=${MALLOC_PERTURB_:-$(( ${RANDOM:-0} % 255 + 1))}  tests/test-block-backend -m=quick -k --tap < /dev/null | ./scripts/tap-driver.pl --test-name="test-block-backend" 
==11617==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 1 test-block-backend /block-backend/drain_aio_error
PASS 2 test-block-backend /block-backend/drain_all_aio_error
MALLOC_PERTURB_=${MALLOC_PERTURB_:-$(( ${RANDOM:-0} % 255 + 1))}  tests/test-block-iothread -m=quick -k --tap < /dev/null | ./scripts/tap-driver.pl --test-name="test-block-iothread" 
PASS 9 ahci-test /x86_64/ahci/io/pio/lba28/simple/zero
==11622==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 1 test-block-iothread /sync-op/pread
PASS 2 test-block-iothread /sync-op/pwrite
PASS 3 test-block-iothread /sync-op/load_vmstate
---
PASS 14 test-block-iothread /propagate/basic
PASS 15 test-block-iothread /propagate/diamond
PASS 16 test-block-iothread /propagate/mirror
==11624==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
==11624==WARNING: ASan is ignoring requested __asan_handle_no_return: stack top: 0x7ffe39ac7000; bottom 0x7f35d1bfe000; size: 0x00c867ec9000 (860737015808)
False positive error reports may follow
For details see https://github.com/google/sanitizers/issues/189

=================================================================
==11622==ERROR: LeakSanitizer: detected memory leaks

Indirect leak of 4120 byte(s) in 1 object(s) allocated from:
    #0 0x5649ccc53d3e in calloc (/tmp/qemu-test/build/tests/test-block-iothread+0x527d3e)
---
SUMMARY: AddressSanitizer: 16816 byte(s) leaked in 20 allocation(s).
MALLOC_PERTURB_=${MALLOC_PERTURB_:-$(( ${RANDOM:-0} % 255 + 1))}  tests/test-image-locking -m=quick -k --tap < /dev/null | ./scripts/tap-driver.pl --test-name="test-image-locking" 
PASS 10 ahci-test /x86_64/ahci/io/pio/lba28/simple/low
==11650==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 1 test-image-locking /image-locking/basic
PASS 2 test-image-locking /image-locking/set-perm-abort
MALLOC_PERTURB_=${MALLOC_PERTURB_:-$(( ${RANDOM:-0} % 255 + 1))}  tests/test-x86-cpuid -m=quick -k --tap < /dev/null | ./scripts/tap-driver.pl --test-name="test-x86-cpuid" 
==11652==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 1 test-x86-cpuid /cpuid/topology/basic
MALLOC_PERTURB_=${MALLOC_PERTURB_:-$(( ${RANDOM:-0} % 255 + 1))}  tests/test-xbzrle -m=quick -k --tap < /dev/null | ./scripts/tap-driver.pl --test-name="test-xbzrle" 
==11652==WARNING: ASan is ignoring requested __asan_handle_no_return: stack top: 0x7ffe6cc1c000; bottom 0x7f6e0c3fe000; size: 0x00906081e000 (620094414848)
False positive error reports may follow
For details see https://github.com/google/sanitizers/issues/189
PASS 1 test-xbzrle /xbzrle/uleb
---
PASS 11 ahci-test /x86_64/ahci/io/pio/lba28/simple/high
PASS 6 test-xbzrle /xbzrle/encode_decode
MALLOC_PERTURB_=${MALLOC_PERTURB_:-$(( ${RANDOM:-0} % 255 + 1))}  tests/test-vmstate -m=quick -k --tap < /dev/null | ./scripts/tap-driver.pl --test-name="test-vmstate" 
==11667==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 1 test-vmstate /vmstate/tmp_struct
PASS 2 test-vmstate /vmstate/simple/primitive
PASS 3 test-vmstate /vmstate/simple/array
---
PASS 133 test-cutils /cutils/strtosz/erange
PASS 134 test-cutils /cutils/strtosz/metric
MALLOC_PERTURB_=${MALLOC_PERTURB_:-$(( ${RANDOM:-0} % 255 + 1))}  tests/test-shift128 -m=quick -k --tap < /dev/null | ./scripts/tap-driver.pl --test-name="test-shift128" 
==11667==WARNING: ASan is ignoring requested __asan_handle_no_return: stack top: 0x7ffe963dc000; bottom 0x7f2d855fe000; size: 0x00d110dde000 (897931141120)
False positive error reports may follow
For details see https://github.com/google/sanitizers/issues/189
PASS 1 test-shift128 /host-utils/test_lshift
---
PASS 9 test-int128 /int128/int128_gt
PASS 10 test-int128 /int128/int128_rshift
MALLOC_PERTURB_=${MALLOC_PERTURB_:-$(( ${RANDOM:-0} % 255 + 1))}  tests/rcutorture -m=quick -k --tap < /dev/null | ./scripts/tap-driver.pl --test-name="rcutorture" 
==11694==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
==11694==WARNING: ASan is ignoring requested __asan_handle_no_return: stack top: 0x7ffd4dbc6000; bottom 0x7f00be1fe000; size: 0x00fc8f9c8000 (1084741156864)
False positive error reports may follow
For details see https://github.com/google/sanitizers/issues/189
PASS 13 ahci-test /x86_64/ahci/io/pio/lba28/double/low
PASS 1 rcutorture /rcu/torture/1reader
==11712==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
==11712==WARNING: ASan is ignoring requested __asan_handle_no_return: stack top: 0x7fffcfbce000; bottom 0x7f5020ffe000; size: 0x00afaebd0000 (754550898688)
False positive error reports may follow
For details see https://github.com/google/sanitizers/issues/189
PASS 14 ahci-test /x86_64/ahci/io/pio/lba28/double/high
PASS 2 rcutorture /rcu/torture/10readers
MALLOC_PERTURB_=${MALLOC_PERTURB_:-$(( ${RANDOM:-0} % 255 + 1))}  tests/test-rcu-list -m=quick -k --tap < /dev/null | ./scripts/tap-driver.pl --test-name="test-rcu-list" 
==11734==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
==11734==WARNING: ASan is ignoring requested __asan_handle_no_return: stack top: 0x7fffbd688000; bottom 0x7f6508d7c000; size: 0x009ab490c000 (664454348800)
False positive error reports may follow
For details see https://github.com/google/sanitizers/issues/189
PASS 1 test-rcu-list /rcu/qlist/single-threaded
PASS 15 ahci-test /x86_64/ahci/io/pio/lba28/long/zero
==11753==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
==11753==WARNING: ASan is ignoring requested __asan_handle_no_return: stack top: 0x7fffcf618000; bottom 0x7fcc7ed7c000; size: 0x00335089c000 (220394536960)
False positive error reports may follow
For details see https://github.com/google/sanitizers/issues/189
PASS 2 test-rcu-list /rcu/qlist/short-few
PASS 16 ahci-test /x86_64/ahci/io/pio/lba28/long/low
==11780==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
==11780==WARNING: ASan is ignoring requested __asan_handle_no_return: stack top: 0x7ffd38611000; bottom 0x7eff7297c000; size: 0x00fdc5c95000 (1089945030656)
False positive error reports may follow
For details see https://github.com/google/sanitizers/issues/189
PASS 3 test-rcu-list /rcu/qlist/long-many
PASS 17 ahci-test /x86_64/ahci/io/pio/lba28/long/high
MALLOC_PERTURB_=${MALLOC_PERTURB_:-$(( ${RANDOM:-0} % 255 + 1))}  tests/test-rcu-simpleq -m=quick -k --tap < /dev/null | ./scripts/tap-driver.pl --test-name="test-rcu-simpleq" 
==11787==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 1 test-rcu-simpleq /rcu/qsimpleq/single-threaded
PASS 18 ahci-test /x86_64/ahci/io/pio/lba28/short/zero
==11805==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 2 test-rcu-simpleq /rcu/qsimpleq/short-few
PASS 19 ahci-test /x86_64/ahci/io/pio/lba28/short/low
==11832==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 20 ahci-test /x86_64/ahci/io/pio/lba28/short/high
==11838==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 3 test-rcu-simpleq /rcu/qsimpleq/long-many
MALLOC_PERTURB_=${MALLOC_PERTURB_:-$(( ${RANDOM:-0} % 255 + 1))}  tests/test-rcu-tailq -m=quick -k --tap < /dev/null | ./scripts/tap-driver.pl --test-name="test-rcu-tailq" 
==11838==WARNING: ASan is ignoring requested __asan_handle_no_return: stack top: 0x7ffe89f51000; bottom 0x7f7e405fe000; size: 0x008049953000 (550990327808)
False positive error reports may follow
For details see https://github.com/google/sanitizers/issues/189
PASS 21 ahci-test /x86_64/ahci/io/pio/lba48/simple/zero
==11851==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 1 test-rcu-tailq /rcu/qtailq/single-threaded
==11851==WARNING: ASan is ignoring requested __asan_handle_no_return: stack top: 0x7ffebaf5b000; bottom 0x7fc9cc5fe000; size: 0x0034ee95d000 (227341094912)
False positive error reports may follow
For details see https://github.com/google/sanitizers/issues/189
PASS 22 ahci-test /x86_64/ahci/io/pio/lba48/simple/low
PASS 2 test-rcu-tailq /rcu/qtailq/short-few
==11863==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
==11863==WARNING: ASan is ignoring requested __asan_handle_no_return: stack top: 0x7fffda879000; bottom 0x7f6de61fe000; size: 0x0091f467b000 (626870693888)
False positive error reports may follow
For details see https://github.com/google/sanitizers/issues/189
PASS 23 ahci-test /x86_64/ahci/io/pio/lba48/simple/high
==11890==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
==11890==WARNING: ASan is ignoring requested __asan_handle_no_return: stack top: 0x7fffe52e2000; bottom 0x7f895effe000; size: 0x0076862e4000 (509057318912)
False positive error reports may follow
For details see https://github.com/google/sanitizers/issues/189
PASS 3 test-rcu-tailq /rcu/qtailq/long-many
---
PASS 7 test-qdist /qdist/binning/expand
PASS 8 test-qdist /qdist/binning/shrink
MALLOC_PERTURB_=${MALLOC_PERTURB_:-$(( ${RANDOM:-0} % 255 + 1))}  tests/test-qht -m=quick -k --tap < /dev/null | ./scripts/tap-driver.pl --test-name="test-qht" 
==11901==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
==11901==WARNING: ASan is ignoring requested __asan_handle_no_return: stack top: 0x7ffc41b31000; bottom 0x7f420dffe000; size: 0x00ba33b33000 (799731298304)
False positive error reports may follow
For details see https://github.com/google/sanitizers/issues/189
PASS 25 ahci-test /x86_64/ahci/io/pio/lba48/double/low
==11911==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
==11911==WARNING: ASan is ignoring requested __asan_handle_no_return: stack top: 0x7ffd2c1a6000; bottom 0x7f4a5c1fe000; size: 0x00b2cffa8000 (767993479168)
False positive error reports may follow
For details see https://github.com/google/sanitizers/issues/189
PASS 26 ahci-test /x86_64/ahci/io/pio/lba48/double/high
==11917==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
==11917==WARNING: ASan is ignoring requested __asan_handle_no_return: stack top: 0x7ffd08cef000; bottom 0x7f6550ffe000; size: 0x0097b7cf1000 (651623862272)
False positive error reports may follow
For details see https://github.com/google/sanitizers/issues/189
PASS 27 ahci-test /x86_64/ahci/io/pio/lba48/long/zero
==11923==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
==11923==WARNING: ASan is ignoring requested __asan_handle_no_return: stack top: 0x7ffdc8a16000; bottom 0x7f61e9dfe000; size: 0x009bdec18000 (669457154048)
False positive error reports may follow
For details see https://github.com/google/sanitizers/issues/189
PASS 28 ahci-test /x86_64/ahci/io/pio/lba48/long/low
==11929==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
==11929==WARNING: ASan is ignoring requested __asan_handle_no_return: stack top: 0x7fff8e660000; bottom 0x7f3c131fe000; size: 0x00c37b462000 (839586816000)
False positive error reports may follow
For details see https://github.com/google/sanitizers/issues/189
PASS 29 ahci-test /x86_64/ahci/io/pio/lba48/long/high
==11935==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 30 ahci-test /x86_64/ahci/io/pio/lba48/short/zero
==11941==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 31 ahci-test /x86_64/ahci/io/pio/lba48/short/low
==11947==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 32 ahci-test /x86_64/ahci/io/pio/lba48/short/high
==11953==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 33 ahci-test /x86_64/ahci/io/dma/lba28/fragmented
==11959==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 1 test-qht /qht/mode/default
PASS 34 ahci-test /x86_64/ahci/io/dma/lba28/retry
PASS 2 test-qht /qht/mode/resize
MALLOC_PERTURB_=${MALLOC_PERTURB_:-$(( ${RANDOM:-0} % 255 + 1))}  tests/test-qht-par -m=quick -k --tap < /dev/null | ./scripts/tap-driver.pl --test-name="test-qht-par" 
==11965==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 35 ahci-test /x86_64/ahci/io/dma/lba28/simple/zero
PASS 1 test-qht-par /qht/parallel/2threads-0%updates-1s
==11981==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 36 ahci-test /x86_64/ahci/io/dma/lba28/simple/low
PASS 2 test-qht-par /qht/parallel/2threads-20%updates-1s
MALLOC_PERTURB_=${MALLOC_PERTURB_:-$(( ${RANDOM:-0} % 255 + 1))}  tests/test-bitops -m=quick -k --tap < /dev/null | ./scripts/tap-driver.pl --test-name="test-bitops" 
---
PASS 5 test-bitops /bitops/half_unshuffle32
PASS 6 test-bitops /bitops/half_unshuffle64
MALLOC_PERTURB_=${MALLOC_PERTURB_:-$(( ${RANDOM:-0} % 255 + 1))}  tests/test-bitcnt -m=quick -k --tap < /dev/null | ./scripts/tap-driver.pl --test-name="test-bitcnt" 
==11994==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 1 test-bitcnt /bitcnt/ctpop8
PASS 2 test-bitcnt /bitcnt/ctpop16
PASS 3 test-bitcnt /bitcnt/ctpop32
---
PASS 18 test-qemu-opts /qemu-opts/to_qdict/filtered
PASS 19 test-qemu-opts /qemu-opts/to_qdict/duplicates
MALLOC_PERTURB_=${MALLOC_PERTURB_:-$(( ${RANDOM:-0} % 255 + 1))}  tests/test-keyval -m=quick -k --tap < /dev/null | ./scripts/tap-driver.pl --test-name="test-keyval" 
==12025==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 1 test-keyval /keyval/keyval_parse
PASS 2 test-keyval /keyval/keyval_parse/list
PASS 3 test-keyval /keyval/visit/bool
---
PASS 4 test-crypto-hash /crypto/hash/digest
PASS 5 test-crypto-hash /crypto/hash/base64
MALLOC_PERTURB_=${MALLOC_PERTURB_:-$(( ${RANDOM:-0} % 255 + 1))}  tests/test-crypto-hmac -m=quick -k --tap < /dev/null | ./scripts/tap-driver.pl --test-name="test-crypto-hmac" 
==12048==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 1 test-crypto-hmac /crypto/hmac/iov
PASS 2 test-crypto-hmac /crypto/hmac/alloc
PASS 3 test-crypto-hmac /crypto/hmac/prealloc
---
PASS 16 test-crypto-secret /crypto/secret/crypt/badiv
MALLOC_PERTURB_=${MALLOC_PERTURB_:-$(( ${RANDOM:-0} % 255 + 1))}  tests/test-crypto-tlscredsx509 -m=quick -k --tap < /dev/null | ./scripts/tap-driver.pl --test-name="test-crypto-tlscredsx509" 
PASS 39 ahci-test /x86_64/ahci/io/dma/lba28/double/low
==12077==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 1 test-crypto-tlscredsx509 /qcrypto/tlscredsx509/perfectserver
PASS 2 test-crypto-tlscredsx509 /qcrypto/tlscredsx509/perfectclient
PASS 3 test-crypto-tlscredsx509 /qcrypto/tlscredsx509/goodca1
PASS 40 ahci-test /x86_64/ahci/io/dma/lba28/double/high
PASS 4 test-crypto-tlscredsx509 /qcrypto/tlscredsx509/goodca2
==12084==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 5 test-crypto-tlscredsx509 /qcrypto/tlscredsx509/goodca3
PASS 6 test-crypto-tlscredsx509 /qcrypto/tlscredsx509/badca1
PASS 7 test-crypto-tlscredsx509 /qcrypto/tlscredsx509/badca2
PASS 8 test-crypto-tlscredsx509 /qcrypto/tlscredsx509/badca3
PASS 41 ahci-test /x86_64/ahci/io/dma/lba28/long/zero
==12090==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 9 test-crypto-tlscredsx509 /qcrypto/tlscredsx509/goodserver1
PASS 10 test-crypto-tlscredsx509 /qcrypto/tlscredsx509/goodserver2
PASS 42 ahci-test /x86_64/ahci/io/dma/lba28/long/low
PASS 11 test-crypto-tlscredsx509 /qcrypto/tlscredsx509/goodserver3
PASS 12 test-crypto-tlscredsx509 /qcrypto/tlscredsx509/goodserver4
==12096==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 13 test-crypto-tlscredsx509 /qcrypto/tlscredsx509/goodserver5
PASS 14 test-crypto-tlscredsx509 /qcrypto/tlscredsx509/goodserver6
PASS 15 test-crypto-tlscredsx509 /qcrypto/tlscredsx509/goodserver7
---
PASS 37 test-crypto-tlscredsx509 /qcrypto/tlscredsx509/missingca
PASS 38 test-crypto-tlscredsx509 /qcrypto/tlscredsx509/missingserver
PASS 39 test-crypto-tlscredsx509 /qcrypto/tlscredsx509/missingclient
==12102==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
MALLOC_PERTURB_=${MALLOC_PERTURB_:-$(( ${RANDOM:-0} % 255 + 1))}  tests/test-crypto-tlssession -m=quick -k --tap < /dev/null | ./scripts/tap-driver.pl --test-name="test-crypto-tlssession" 
PASS 44 ahci-test /x86_64/ahci/io/dma/lba28/short/zero
==12113==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 1 test-crypto-tlssession /qcrypto/tlssession/psk
PASS 2 test-crypto-tlssession /qcrypto/tlssession/basicca
PASS 45 ahci-test /x86_64/ahci/io/dma/lba28/short/low
PASS 3 test-crypto-tlssession /qcrypto/tlssession/differentca
==12119==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 46 ahci-test /x86_64/ahci/io/dma/lba28/short/high
PASS 4 test-crypto-tlssession /qcrypto/tlssession/altname1
PASS 5 test-crypto-tlssession /qcrypto/tlssession/altname2
==12125==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 47 ahci-test /x86_64/ahci/io/dma/lba48/simple/zero
==12131==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 6 test-crypto-tlssession /qcrypto/tlssession/altname3
PASS 7 test-crypto-tlssession /qcrypto/tlssession/altname4
PASS 48 ahci-test /x86_64/ahci/io/dma/lba48/simple/low
PASS 8 test-crypto-tlssession /qcrypto/tlssession/altname5
==12137==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 9 test-crypto-tlssession /qcrypto/tlssession/altname6
PASS 49 ahci-test /x86_64/ahci/io/dma/lba48/simple/high
==12143==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 50 ahci-test /x86_64/ahci/io/dma/lba48/double/zero
PASS 10 test-crypto-tlssession /qcrypto/tlssession/wildcard1
==12149==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 11 test-crypto-tlssession /qcrypto/tlssession/wildcard2
PASS 51 ahci-test /x86_64/ahci/io/dma/lba48/double/low
PASS 12 test-crypto-tlssession /qcrypto/tlssession/wildcard3
==12155==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 13 test-crypto-tlssession /qcrypto/tlssession/wildcard4
PASS 14 test-crypto-tlssession /qcrypto/tlssession/wildcard5
PASS 52 ahci-test /x86_64/ahci/io/dma/lba48/double/high
PASS 15 test-crypto-tlssession /qcrypto/tlssession/wildcard6
PASS 16 test-crypto-tlssession /qcrypto/tlssession/cachain
==12162==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
MALLOC_PERTURB_=${MALLOC_PERTURB_:-$(( ${RANDOM:-0} % 255 + 1))}  tests/test-qga -m=quick -k --tap < /dev/null | ./scripts/tap-driver.pl --test-name="test-qga" 
PASS 53 ahci-test /x86_64/ahci/io/dma/lba48/long/zero
PASS 1 test-qga /qga/sync-delimited
---
PASS 15 test-qga /qga/invalid-cmd
PASS 16 test-qga /qga/invalid-args
PASS 17 test-qga /qga/fsfreeze-status
==12174==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 54 ahci-test /x86_64/ahci/io/dma/lba48/long/low
PASS 18 test-qga /qga/blacklist
PASS 19 test-qga /qga/config
PASS 20 test-qga /qga/guest-exec
PASS 21 test-qga /qga/guest-exec-invalid
==12181==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 55 ahci-test /x86_64/ahci/io/dma/lba48/long/high
PASS 22 test-qga /qga/guest-get-osinfo
PASS 23 test-qga /qga/guest-get-host-name
PASS 24 test-qga /qga/guest-get-timezone
PASS 25 test-qga /qga/guest-get-users
MALLOC_PERTURB_=${MALLOC_PERTURB_:-$(( ${RANDOM:-0} % 255 + 1))}  tests/test-timed-average -m=quick -k --tap < /dev/null | ./scripts/tap-driver.pl --test-name="test-timed-average" 
==12194==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 1 test-timed-average /timed-average/average
MALLOC_PERTURB_=${MALLOC_PERTURB_:-$(( ${RANDOM:-0} % 255 + 1))}  tests/test-util-filemonitor -m=quick -k --tap < /dev/null | ./scripts/tap-driver.pl --test-name="test-util-filemonitor" 
PASS 1 test-util-filemonitor /util/filemonitor
---
PASS 4 test-io-task /crypto/task/thread_complete
PASS 5 test-io-task /crypto/task/thread_failure
MALLOC_PERTURB_=${MALLOC_PERTURB_:-$(( ${RANDOM:-0} % 255 + 1))}  tests/test-io-channel-socket -m=quick -k --tap < /dev/null | ./scripts/tap-driver.pl --test-name="test-io-channel-socket" 
==12228==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 1 test-io-channel-socket /io/channel/socket/ipv4-sync
PASS 2 test-io-channel-socket /io/channel/socket/ipv4-async
PASS 3 test-io-channel-socket /io/channel/socket/ipv4-fd
---
PASS 57 ahci-test /x86_64/ahci/io/dma/lba48/short/low
PASS 1 test-io-channel-tls /qio/channel/tls/basic
MALLOC_PERTURB_=${MALLOC_PERTURB_:-$(( ${RANDOM:-0} % 255 + 1))}  tests/test-io-channel-command -m=quick -k --tap < /dev/null | ./scripts/tap-driver.pl --test-name="test-io-channel-command" 
==12300==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 1 test-io-channel-command /io/channel/command/fifo/sync
PASS 2 test-io-channel-command /io/channel/command/fifo/async
PASS 3 test-io-channel-command /io/channel/command/echo/sync
---
PASS 8 test-crypto-ivgen /crypto/ivgen/essiv/1f2e3d4c
PASS 9 test-crypto-ivgen /crypto/ivgen/essiv/1f2e3d4c5b6a7988
MALLOC_PERTURB_=${MALLOC_PERTURB_:-$(( ${RANDOM:-0} % 255 + 1))}  tests/test-crypto-afsplit -m=quick -k --tap < /dev/null | ./scripts/tap-driver.pl --test-name="test-crypto-afsplit" 
==12328==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 1 test-crypto-afsplit /crypto/afsplit/sha256/5
PASS 2 test-crypto-afsplit /crypto/afsplit/sha256/5000
PASS 3 test-crypto-afsplit /crypto/afsplit/sha256/big
---
PASS 1 test-logging /logging/parse_range
PASS 2 test-logging /logging/parse_path
MALLOC_PERTURB_=${MALLOC_PERTURB_:-$(( ${RANDOM:-0} % 255 + 1))}  tests/test-replication -m=quick -k --tap < /dev/null | ./scripts/tap-driver.pl --test-name="test-replication" 
==12356==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
==12362==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 1 test-replication /replication/primary/read
PASS 2 test-replication /replication/primary/write
PASS 60 ahci-test /x86_64/ahci/io/ncq/retry
==12371==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 3 test-replication /replication/primary/start
PASS 4 test-replication /replication/primary/stop
PASS 5 test-replication /replication/primary/do_checkpoint
PASS 6 test-replication /replication/primary/get_error_all
PASS 61 ahci-test /x86_64/ahci/flush/simple
==12377==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 7 test-replication /replication/secondary/read
PASS 62 ahci-test /x86_64/ahci/flush/retry
==12383==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 8 test-replication /replication/secondary/write
==12388==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
==12362==WARNING: ASan is ignoring requested __asan_handle_no_return: stack top: 0x7ffd4139e000; bottom 0x7f9bdfffc000; size: 0x0061613a2000 (418243026944)
False positive error reports may follow
For details see https://github.com/google/sanitizers/issues/189
PASS 63 ahci-test /x86_64/ahci/flush/migrate
PASS 9 test-replication /replication/secondary/start
==12417==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
==12422==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 64 ahci-test /x86_64/ahci/migrate/sanity
==12431==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 10 test-replication /replication/secondary/stop
==12436==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 11 test-replication /replication/secondary/do_checkpoint
PASS 12 test-replication /replication/secondary/get_error_all
PASS 65 ahci-test /x86_64/ahci/migrate/dma/simple
==12447==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!

=================================================================
==12362==ERROR: LeakSanitizer: detected memory leaks

Indirect leak of 4120 byte(s) in 1 object(s) allocated from:
    #0 0x55dccc091d1e in calloc (/tmp/qemu-test/build/tests/test-replication+0x525d1e)
---
    #12 0x7f9bedfdef9d  (/lib64/libglib-2.0.so.0+0x77f9d)

SUMMARY: AddressSanitizer: 119042 byte(s) leaked in 506 allocation(s).
==12453==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
MALLOC_PERTURB_=${MALLOC_PERTURB_:-$(( ${RANDOM:-0} % 255 + 1))}  tests/test-bufferiszero -m=quick -k --tap < /dev/null | ./scripts/tap-driver.pl --test-name="test-bufferiszero" 
PASS 66 ahci-test /x86_64/ahci/migrate/dma/halted
==12465==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
==12470==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 67 ahci-test /x86_64/ahci/migrate/ncq/simple
==12479==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
==12484==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 68 ahci-test /x86_64/ahci/migrate/ncq/halted
==12493==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 69 ahci-test /x86_64/ahci/cdrom/eject
==12498==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 70 ahci-test /x86_64/ahci/cdrom/dma/single
==12504==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 71 ahci-test /x86_64/ahci/cdrom/dma/multi
==12510==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 72 ahci-test /x86_64/ahci/cdrom/pio/single
==12516==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
==12516==WARNING: ASan is ignoring requested __asan_handle_no_return: stack top: 0x7ffe47d5a000; bottom 0x7f68275dc000; size: 0x00962077e000 (644789821440)
False positive error reports may follow
For details see https://github.com/google/sanitizers/issues/189
PASS 73 ahci-test /x86_64/ahci/cdrom/pio/multi
==12522==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 74 ahci-test /x86_64/ahci/cdrom/pio/bcl
MALLOC_PERTURB_=${MALLOC_PERTURB_:-$(( ${RANDOM:-0} % 255 + 1))}  QTEST_QEMU_BINARY=x86_64-softmmu/qemu-system-x86_64 QTEST_QEMU_IMG=qemu-img tests/hd-geo-test -m=quick -k --tap < /dev/null | ./scripts/tap-driver.pl --test-name="hd-geo-test" 
PASS 1 hd-geo-test /x86_64/hd-geo/ide/none
==12536==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 2 hd-geo-test /x86_64/hd-geo/ide/drive/cd_0
==12542==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 3 hd-geo-test /x86_64/hd-geo/ide/drive/mbr/blank
==12548==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 4 hd-geo-test /x86_64/hd-geo/ide/drive/mbr/lba
==12554==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 5 hd-geo-test /x86_64/hd-geo/ide/drive/mbr/chs
==12560==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 6 hd-geo-test /x86_64/hd-geo/ide/device/mbr/blank
==12566==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 7 hd-geo-test /x86_64/hd-geo/ide/device/mbr/lba
==12572==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 8 hd-geo-test /x86_64/hd-geo/ide/device/mbr/chs
==12578==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 9 hd-geo-test /x86_64/hd-geo/ide/device/user/chs
==12583==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 10 hd-geo-test /x86_64/hd-geo/ide/device/user/chst
MALLOC_PERTURB_=${MALLOC_PERTURB_:-$(( ${RANDOM:-0} % 255 + 1))}  QTEST_QEMU_BINARY=x86_64-softmmu/qemu-system-x86_64 QTEST_QEMU_IMG=qemu-img tests/boot-order-test -m=quick -k --tap < /dev/null | ./scripts/tap-driver.pl --test-name="boot-order-test" 
PASS 1 test-bufferiszero /cutils/bufferiszero
---
Could not access KVM kernel module: No such file or directory
qemu-system-x86_64: failed to initialize KVM: No such file or directory
qemu-system-x86_64: Back to tcg accelerator
==12668==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 1 bios-tables-test /x86_64/acpi/piix4
Could not access KVM kernel module: No such file or directory
qemu-system-x86_64: failed to initialize KVM: No such file or directory
qemu-system-x86_64: Back to tcg accelerator
==12674==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 2 bios-tables-test /x86_64/acpi/q35
Could not access KVM kernel module: No such file or directory
qemu-system-x86_64: failed to initialize KVM: No such file or directory
qemu-system-x86_64: Back to tcg accelerator
==12680==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 3 bios-tables-test /x86_64/acpi/piix4/bridge
Could not access KVM kernel module: No such file or directory
qemu-system-x86_64: failed to initialize KVM: No such file or directory
qemu-system-x86_64: Back to tcg accelerator
==12686==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 4 bios-tables-test /x86_64/acpi/piix4/ipmi
Could not access KVM kernel module: No such file or directory
qemu-system-x86_64: failed to initialize KVM: No such file or directory
qemu-system-x86_64: Back to tcg accelerator
==12692==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 5 bios-tables-test /x86_64/acpi/piix4/cpuhp
Could not access KVM kernel module: No such file or directory
qemu-system-x86_64: failed to initialize KVM: No such file or directory
qemu-system-x86_64: Back to tcg accelerator
==12699==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 6 bios-tables-test /x86_64/acpi/piix4/memhp
Could not access KVM kernel module: No such file or directory
qemu-system-x86_64: failed to initialize KVM: No such file or directory
qemu-system-x86_64: Back to tcg accelerator
==12705==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 7 bios-tables-test /x86_64/acpi/piix4/numamem
Could not access KVM kernel module: No such file or directory
qemu-system-x86_64: failed to initialize KVM: No such file or directory
qemu-system-x86_64: Back to tcg accelerator
==12711==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 8 bios-tables-test /x86_64/acpi/piix4/dimmpxm
Could not access KVM kernel module: No such file or directory
qemu-system-x86_64: failed to initialize KVM: No such file or directory
qemu-system-x86_64: Back to tcg accelerator
==12720==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 9 bios-tables-test /x86_64/acpi/q35/bridge
Could not access KVM kernel module: No such file or directory
qemu-system-x86_64: failed to initialize KVM: No such file or directory
qemu-system-x86_64: Back to tcg accelerator
==12726==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 10 bios-tables-test /x86_64/acpi/q35/mmio64
Could not access KVM kernel module: No such file or directory
qemu-system-x86_64: failed to initialize KVM: No such file or directory
qemu-system-x86_64: Back to tcg accelerator
==12732==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 11 bios-tables-test /x86_64/acpi/q35/ipmi
Could not access KVM kernel module: No such file or directory
qemu-system-x86_64: failed to initialize KVM: No such file or directory
qemu-system-x86_64: Back to tcg accelerator
==12738==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 12 bios-tables-test /x86_64/acpi/q35/cpuhp
Could not access KVM kernel module: No such file or directory
qemu-system-x86_64: failed to initialize KVM: No such file or directory
qemu-system-x86_64: Back to tcg accelerator
==12745==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 13 bios-tables-test /x86_64/acpi/q35/memhp
Could not access KVM kernel module: No such file or directory
qemu-system-x86_64: failed to initialize KVM: No such file or directory
qemu-system-x86_64: Back to tcg accelerator
==12751==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 14 bios-tables-test /x86_64/acpi/q35/numamem
Could not access KVM kernel module: No such file or directory
qemu-system-x86_64: failed to initialize KVM: No such file or directory
qemu-system-x86_64: Back to tcg accelerator
==12757==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 15 bios-tables-test /x86_64/acpi/q35/dimmpxm
MALLOC_PERTURB_=${MALLOC_PERTURB_:-$(( ${RANDOM:-0} % 255 + 1))}  QTEST_QEMU_BINARY=x86_64-softmmu/qemu-system-x86_64 QTEST_QEMU_IMG=qemu-img tests/boot-serial-test -m=quick -k --tap < /dev/null | ./scripts/tap-driver.pl --test-name="boot-serial-test" 
PASS 1 boot-serial-test /x86_64/boot-serial/isapc
---
PASS 1 i440fx-test /x86_64/i440fx/defaults
PASS 2 i440fx-test /x86_64/i440fx/pam
PASS 3 i440fx-test /x86_64/i440fx/firmware/bios
==12841==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 4 i440fx-test /x86_64/i440fx/firmware/pflash
MALLOC_PERTURB_=${MALLOC_PERTURB_:-$(( ${RANDOM:-0} % 255 + 1))}  QTEST_QEMU_BINARY=x86_64-softmmu/qemu-system-x86_64 QTEST_QEMU_IMG=qemu-img tests/fw_cfg-test -m=quick -k --tap < /dev/null | ./scripts/tap-driver.pl --test-name="fw_cfg-test" 
PASS 1 fw_cfg-test /x86_64/fw_cfg/signature
---
MALLOC_PERTURB_=${MALLOC_PERTURB_:-$(( ${RANDOM:-0} % 255 + 1))}  QTEST_QEMU_BINARY=x86_64-softmmu/qemu-system-x86_64 QTEST_QEMU_IMG=qemu-img tests/drive_del-test -m=quick -k --tap < /dev/null | ./scripts/tap-driver.pl --test-name="drive_del-test" 
PASS 1 drive_del-test /x86_64/drive_del/without-dev
PASS 2 drive_del-test /x86_64/drive_del/after_failed_device_add
==12929==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 3 drive_del-test /x86_64/blockdev/drive_del_device_del
MALLOC_PERTURB_=${MALLOC_PERTURB_:-$(( ${RANDOM:-0} % 255 + 1))}  QTEST_QEMU_BINARY=x86_64-softmmu/qemu-system-x86_64 QTEST_QEMU_IMG=qemu-img tests/wdt_ib700-test -m=quick -k --tap < /dev/null | ./scripts/tap-driver.pl --test-name="wdt_ib700-test" 
PASS 1 wdt_ib700-test /x86_64/wdt_ib700/pause
---
PASS 1 usb-hcd-uhci-test /x86_64/uhci/pci/init
PASS 2 usb-hcd-uhci-test /x86_64/uhci/pci/port1
PASS 3 usb-hcd-uhci-test /x86_64/uhci/pci/hotplug
==13124==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 4 usb-hcd-uhci-test /x86_64/uhci/pci/hotplug/usb-storage
MALLOC_PERTURB_=${MALLOC_PERTURB_:-$(( ${RANDOM:-0} % 255 + 1))}  QTEST_QEMU_BINARY=x86_64-softmmu/qemu-system-x86_64 QTEST_QEMU_IMG=qemu-img tests/usb-hcd-xhci-test -m=quick -k --tap < /dev/null | ./scripts/tap-driver.pl --test-name="usb-hcd-xhci-test" 
PASS 1 usb-hcd-xhci-test /x86_64/xhci/pci/init
PASS 2 usb-hcd-xhci-test /x86_64/xhci/pci/hotplug
==13133==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 3 usb-hcd-xhci-test /x86_64/xhci/pci/hotplug/usb-uas
PASS 4 usb-hcd-xhci-test /x86_64/xhci/pci/hotplug/usb-ccid
MALLOC_PERTURB_=${MALLOC_PERTURB_:-$(( ${RANDOM:-0} % 255 + 1))}  QTEST_QEMU_BINARY=x86_64-softmmu/qemu-system-x86_64 QTEST_QEMU_IMG=qemu-img tests/cpu-plug-test -m=quick -k --tap < /dev/null | ./scripts/tap-driver.pl --test-name="cpu-plug-test" 
---
Could not access KVM kernel module: No such file or directory
qemu-system-x86_64: failed to initialize KVM: No such file or directory
qemu-system-x86_64: Back to tcg accelerator
==13239==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 1 vmgenid-test /x86_64/vmgenid/vmgenid/set-guid
Could not access KVM kernel module: No such file or directory
qemu-system-x86_64: failed to initialize KVM: No such file or directory
qemu-system-x86_64: Back to tcg accelerator
==13245==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 2 vmgenid-test /x86_64/vmgenid/vmgenid/set-guid-auto
Could not access KVM kernel module: No such file or directory
qemu-system-x86_64: failed to initialize KVM: No such file or directory
qemu-system-x86_64: Back to tcg accelerator
==13251==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 3 vmgenid-test /x86_64/vmgenid/vmgenid/query-monitor
MALLOC_PERTURB_=${MALLOC_PERTURB_:-$(( ${RANDOM:-0} % 255 + 1))}  QTEST_QEMU_BINARY=x86_64-softmmu/qemu-system-x86_64 QTEST_QEMU_IMG=qemu-img tests/tpm-crb-swtpm-test -m=quick -k --tap < /dev/null | ./scripts/tap-driver.pl --test-name="tpm-crb-swtpm-test" 
SKIP 1 tpm-crb-swtpm-test /x86_64/tpm/crb-swtpm/test # SKIP swtpm not in PATH or missing --tpm2 support
---
Could not access KVM kernel module: No such file or directory
qemu-system-x86_64: failed to initialize KVM: No such file or directory
qemu-system-x86_64: Back to tcg accelerator
==13356==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
Could not access KVM kernel module: No such file or directory
qemu-system-x86_64: failed to initialize KVM: No such file or directory
qemu-system-x86_64: Back to tcg accelerator
==13361==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 3 migration-test /x86_64/migration/fd_proto
Could not access KVM kernel module: No such file or directory
qemu-system-x86_64: failed to initialize KVM: No such file or directory
qemu-system-x86_64: Back to tcg accelerator
==13369==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
Could not access KVM kernel module: No such file or directory
qemu-system-x86_64: failed to initialize KVM: No such file or directory
qemu-system-x86_64: Back to tcg accelerator
==13374==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 4 migration-test /x86_64/migration/postcopy/unix
PASS 5 migration-test /x86_64/migration/postcopy/recovery
Could not access KVM kernel module: No such file or directory
qemu-system-x86_64: failed to initialize KVM: No such file or directory
qemu-system-x86_64: Back to tcg accelerator
==13404==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
Could not access KVM kernel module: No such file or directory
qemu-system-x86_64: failed to initialize KVM: No such file or directory
qemu-system-x86_64: Back to tcg accelerator
==13409==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 6 migration-test /x86_64/migration/precopy/unix
Could not access KVM kernel module: No such file or directory
qemu-system-x86_64: failed to initialize KVM: No such file or directory
qemu-system-x86_64: Back to tcg accelerator
==13418==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
Could not access KVM kernel module: No such file or directory
qemu-system-x86_64: failed to initialize KVM: No such file or directory
qemu-system-x86_64: Back to tcg accelerator
==13423==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 7 migration-test /x86_64/migration/precopy/tcp
Could not access KVM kernel module: No such file or directory
qemu-system-x86_64: failed to initialize KVM: No such file or directory
qemu-system-x86_64: Back to tcg accelerator
==13432==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
Could not access KVM kernel module: No such file or directory
qemu-system-x86_64: failed to initialize KVM: No such file or directory
qemu-system-x86_64: Back to tcg accelerator
==13437==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 8 migration-test /x86_64/migration/xbzrle/unix
MALLOC_PERTURB_=${MALLOC_PERTURB_:-$(( ${RANDOM:-0} % 255 + 1))}  QTEST_QEMU_BINARY=x86_64-softmmu/qemu-system-x86_64 QTEST_QEMU_IMG=qemu-img tests/test-x86-cpuid-compat -m=quick -k --tap < /dev/null | ./scripts/tap-driver.pl --test-name="test-x86-cpuid-compat" 
PASS 1 test-x86-cpuid-compat /x86/cpuid/parsing-plus-minus
---
PASS 6 numa-test /x86_64/numa/pc/dynamic/cpu
MALLOC_PERTURB_=${MALLOC_PERTURB_:-$(( ${RANDOM:-0} % 255 + 1))}  QTEST_QEMU_BINARY=x86_64-softmmu/qemu-system-x86_64 QTEST_QEMU_IMG=qemu-img tests/qmp-test -m=quick -k --tap < /dev/null | ./scripts/tap-driver.pl --test-name="qmp-test" 
PASS 1 qmp-test /x86_64/qmp/protocol
==13766==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 2 qmp-test /x86_64/qmp/oob
PASS 3 qmp-test /x86_64/qmp/preconfig
PASS 4 qmp-test /x86_64/qmp/missing-any-arg
---
PASS 6 qos-test /x86_64/pc/i440FX-pcihost/pci-bus-pc/pci-bus/sdhci-pci/sdhci/sdhci-tests/registers
PASS 7 qos-test /x86_64/pc/i440FX-pcihost/pci-bus-pc/pci-bus/tpci200/ipack/ipoctal232/ipoctal232-tests/nop
PASS 8 qos-test /x86_64/pc/i440FX-pcihost/pci-bus-pc/pci-bus/tpci200/pci-device/pci-device-tests/nop
==14175==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 9 qos-test /x86_64/pc/i440FX-pcihost/pci-bus-pc/pci-bus/virtio-9p-pci/pci-device/pci-device-tests/nop
PASS 10 qos-test /x86_64/pc/i440FX-pcihost/pci-bus-pc/pci-bus/virtio-9p-pci/virtio/virtio-tests/nop
PASS 11 qos-test /x86_64/pc/i440FX-pcihost/pci-bus-pc/pci-bus/virtio-9p-pci/virtio-9p/virtio-9p-tests/config
---
PASS 20 qos-test /x86_64/pc/i440FX-pcihost/pci-bus-pc/pci-bus/virtio-9p-pci/virtio-9p/virtio-9p-tests/fs/flush/ignored
PASS 21 qos-test /x86_64/pc/i440FX-pcihost/pci-bus-pc/pci-bus/virtio-balloon-pci/pci-device/pci-device-tests/nop
PASS 22 qos-test /x86_64/pc/i440FX-pcihost/pci-bus-pc/pci-bus/virtio-balloon-pci/virtio/virtio-tests/nop
==14188==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 23 qos-test /x86_64/pc/i440FX-pcihost/pci-bus-pc/pci-bus/virtio-blk-pci/virtio-blk/virtio-blk-tests/indirect
==14195==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 24 qos-test /x86_64/pc/i440FX-pcihost/pci-bus-pc/pci-bus/virtio-blk-pci/virtio-blk/virtio-blk-tests/config
==14202==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 25 qos-test /x86_64/pc/i440FX-pcihost/pci-bus-pc/pci-bus/virtio-blk-pci/virtio-blk/virtio-blk-tests/basic
==14209==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 26 qos-test /x86_64/pc/i440FX-pcihost/pci-bus-pc/pci-bus/virtio-blk-pci/virtio-blk/virtio-blk-tests/resize
==14216==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 27 qos-test /x86_64/pc/i440FX-pcihost/pci-bus-pc/pci-bus/virtio-blk-pci/virtio-blk-pci-tests/msix
==14223==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 28 qos-test /x86_64/pc/i440FX-pcihost/pci-bus-pc/pci-bus/virtio-blk-pci/virtio-blk-pci-tests/idx
==14230==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 29 qos-test /x86_64/pc/i440FX-pcihost/pci-bus-pc/pci-bus/virtio-blk-pci/virtio-blk-pci-tests/nxvirtq
==14237==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 30 qos-test /x86_64/pc/i440FX-pcihost/pci-bus-pc/pci-bus/virtio-blk-pci/virtio-blk-pci-tests/hotplug
PASS 31 qos-test /x86_64/pc/i440FX-pcihost/pci-bus-pc/pci-bus/virtio-net-pci/virtio-net/virtio-net-tests/basic
PASS 32 qos-test /x86_64/pc/i440FX-pcihost/pci-bus-pc/pci-bus/virtio-net-pci/virtio-net/virtio-net-tests/rx_stop_cont
---
PASS 40 qos-test /x86_64/pc/i440FX-pcihost/pci-bus-pc/pci-bus/virtio-rng-pci/pci-device/pci-device-tests/nop
PASS 41 qos-test /x86_64/pc/i440FX-pcihost/pci-bus-pc/pci-bus/virtio-rng-pci/virtio/virtio-tests/nop
PASS 42 qos-test /x86_64/pc/i440FX-pcihost/pci-bus-pc/pci-bus/virtio-rng-pci/virtio-rng-pci-tests/hotplug
==14348==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 43 qos-test /x86_64/pc/i440FX-pcihost/pci-bus-pc/pci-bus/virtio-scsi-pci/pci-device/pci-device-tests/nop
==14354==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 44 qos-test /x86_64/pc/i440FX-pcihost/pci-bus-pc/pci-bus/virtio-scsi-pci/virtio-scsi/virtio-scsi-tests/hotplug
==14360==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 45 qos-test /x86_64/pc/i440FX-pcihost/pci-bus-pc/pci-bus/virtio-scsi-pci/virtio-scsi/virtio-scsi-tests/unaligned-write-same

=================================================================
==14360==ERROR: LeakSanitizer: detected memory leaks

Indirect leak of 4120 byte(s) in 1 object(s) allocated from:
    #0 0x55a747851abe in calloc (/tmp/qemu-test/build/x86_64-softmmu/qemu-system-x86_64+0x19e9abe)
---

SUMMARY: AddressSanitizer: 4382 byte(s) leaked in 13 allocation(s).
/tmp/qemu-test/src/tests/libqtest.c:137: kill_qemu() tried to terminate QEMU process but encountered exit status 1
ERROR - too few tests run (expected 78, got 45)
make: *** [/tmp/qemu-test/src/tests/Makefile.include:909: check-qtest-x86_64] Error 1
make: *** Waiting for unfinished jobs....
Traceback (most recent call last):


The full log is available at
http://patchew.org/logs/20190624173935.25747-1-mreitz@redhat.com/testing.asan/?type=message.
---
Email generated automatically by Patchew [https://patchew.org/].
Please send your feedback to patchew-devel@redhat.com
Re: [Qemu-devel] [PATCH v4 00/14] block: Try to create well-typed json:{} filenames
Posted by Max Reitz 4 years, 10 months ago
On 24.06.19 21:00, no-reply@patchew.org wrote:
> Patchew URL: https://patchew.org/QEMU/20190624173935.25747-1-mreitz@redhat.com/
> 
> 
> 
> Hi,
> 
> This series failed the asan build test. Please find the testing commands and
> their output below. If you have Docker installed, you can probably reproduce it
> locally.

Many ASan leaks of the form:

> Indirect leak of 4120 byte(s) in 1 object(s) allocated from:
>     #0 0x56245fee9d3e in calloc (/tmp/qemu-test/build/tests/test-bdrv-drain+0x52fd3e)
>     #1 0x7f285054bcf0 in g_malloc0 (/lib64/libglib-2.0.so.0+0x55cf0)
>     #2 0x562460610cf3 in qdict_clone_shallow /tmp/qemu-test/src/qobject/qdict.c:367:12
>     #3 0x56245ff8487b in bdrv_type_blockdev_opts /tmp/qemu-test/src/block.c:6305:22

Oops, I forgot to free string_options in bdrv_type_blockdev_opts().
Thanks, Patchew!

Max