[Qemu-devel] [PATCH v3 0/6] file-posix: Add dynamic-auto-read-only QAPI feature

Kevin Wolf posted 6 patches 4 years, 10 months ago
Test s390x passed
Test checkpatch passed
Test asan failed
Test docker-mingw@fedora passed
Test docker-clang@ubuntu failed
Test FreeBSD passed
Patches applied successfully (tree, apply log)
git fetch https://github.com/patchew-project/qemu tags/patchew/20190530073205.5293-1-kwolf@redhat.com
Maintainers: Markus Armbruster <armbru@redhat.com>, Eric Blake <eblake@redhat.com>, Michael Roth <mdroth@linux.vnet.ibm.com>
There is a newer version of this series
qapi/block-core.json                          |  13 +-
qapi/introspect.json                          |   6 +-
tests/qapi-schema/features-bad-type.json      |   3 +
.../qapi-schema/features-duplicate-name.json  |   3 +
tests/qapi-schema/features-missing-name.json  |   3 +
tests/qapi-schema/features-name-bad-type.json |   3 +
tests/qapi-schema/features-no-list.json       |   3 +
tests/qapi-schema/features-unknown-key.json   |   3 +
tests/qapi-schema/qapi-schema-test.json       |  39 +++
docs/devel/qapi-code-gen.txt                  |  38 +++
scripts/qapi/common.py                        | 228 +++++++++++++++---
scripts/qapi/doc.py                           |  15 +-
scripts/qapi/introspect.py                    |   6 +-
scripts/qapi/types.py                         |   3 +-
scripts/qapi/visit.py                         |   3 +-
tests/Makefile.include                        |   6 +
tests/qapi-schema/double-type.err             |   2 +-
tests/qapi-schema/features-bad-type.err       |   1 +
tests/qapi-schema/features-bad-type.exit      |   1 +
tests/qapi-schema/features-bad-type.out       |   0
tests/qapi-schema/features-duplicate-name.err |   1 +
.../qapi-schema/features-duplicate-name.exit  |   1 +
tests/qapi-schema/features-duplicate-name.out |   0
tests/qapi-schema/features-missing-name.err   |   1 +
tests/qapi-schema/features-missing-name.exit  |   1 +
tests/qapi-schema/features-missing-name.out   |   0
tests/qapi-schema/features-name-bad-type.err  |   1 +
tests/qapi-schema/features-name-bad-type.exit |   1 +
tests/qapi-schema/features-name-bad-type.out  |   0
tests/qapi-schema/features-no-list.err        |   1 +
tests/qapi-schema/features-no-list.exit       |   1 +
tests/qapi-schema/features-no-list.out        |   0
tests/qapi-schema/features-unknown-key.err    |   2 +
tests/qapi-schema/features-unknown-key.exit   |   1 +
tests/qapi-schema/features-unknown-key.out    |   0
tests/qapi-schema/qapi-schema-test.out        |  43 ++++
tests/qapi-schema/test-qapi.py                |   7 +-
tests/qapi-schema/unknown-expr-key.err        |   2 +-
38 files changed, 395 insertions(+), 47 deletions(-)
create mode 100644 tests/qapi-schema/features-bad-type.json
create mode 100644 tests/qapi-schema/features-duplicate-name.json
create mode 100644 tests/qapi-schema/features-missing-name.json
create mode 100644 tests/qapi-schema/features-name-bad-type.json
create mode 100644 tests/qapi-schema/features-no-list.json
create mode 100644 tests/qapi-schema/features-unknown-key.json
create mode 100644 tests/qapi-schema/features-bad-type.err
create mode 100644 tests/qapi-schema/features-bad-type.exit
create mode 100644 tests/qapi-schema/features-bad-type.out
create mode 100644 tests/qapi-schema/features-duplicate-name.err
create mode 100644 tests/qapi-schema/features-duplicate-name.exit
create mode 100644 tests/qapi-schema/features-duplicate-name.out
create mode 100644 tests/qapi-schema/features-missing-name.err
create mode 100644 tests/qapi-schema/features-missing-name.exit
create mode 100644 tests/qapi-schema/features-missing-name.out
create mode 100644 tests/qapi-schema/features-name-bad-type.err
create mode 100644 tests/qapi-schema/features-name-bad-type.exit
create mode 100644 tests/qapi-schema/features-name-bad-type.out
create mode 100644 tests/qapi-schema/features-no-list.err
create mode 100644 tests/qapi-schema/features-no-list.exit
create mode 100644 tests/qapi-schema/features-no-list.out
create mode 100644 tests/qapi-schema/features-unknown-key.err
create mode 100644 tests/qapi-schema/features-unknown-key.exit
create mode 100644 tests/qapi-schema/features-unknown-key.out
[Qemu-devel] [PATCH v3 0/6] file-posix: Add dynamic-auto-read-only QAPI feature
Posted by Kevin Wolf 4 years, 10 months ago
This series adds optional feature lists to struct definitions in the
QAPI schema and makes use of them to advertise the new behaviour of
auto-read-only=on in file-posix.

v3:
- Added a command using the structs types to the positive test case
- Renamed QAPIDoc.SymbolPart to QAPIDoc.DocPart
- Applied requested comment changes
- Style fixes to avoid adding pycodestyle-3 complaints
- More stylistic changes to match Markus' taste better

v2:
- Check that features have well-formed names instead of just checking
  that they are strings
- Use QAPISchemaFeature objects instead of dicts
- Catch duplicate feature names (and test that a feature name doesn't
  conflict with an object member)
- Added patch 4 and 5 to add rudimentary support for features to
  QAPIDoc so it doesn't complain about the documentation format
  suggested by Markus. Used that format in the documentation of
  dynamic-auto-read-only.


Kevin Wolf (6):
  qapi: Add feature flags to struct types
  tests/qapi-schema: Test for good feature lists in structs
  tests/qapi-schema: Error case tests for features in structs
  qapi: Disentangle QAPIDoc code
  qapi: Allow documentation for features
  file-posix: Add dynamic-auto-read-only QAPI feature

 qapi/block-core.json                          |  13 +-
 qapi/introspect.json                          |   6 +-
 tests/qapi-schema/features-bad-type.json      |   3 +
 .../qapi-schema/features-duplicate-name.json  |   3 +
 tests/qapi-schema/features-missing-name.json  |   3 +
 tests/qapi-schema/features-name-bad-type.json |   3 +
 tests/qapi-schema/features-no-list.json       |   3 +
 tests/qapi-schema/features-unknown-key.json   |   3 +
 tests/qapi-schema/qapi-schema-test.json       |  39 +++
 docs/devel/qapi-code-gen.txt                  |  38 +++
 scripts/qapi/common.py                        | 228 +++++++++++++++---
 scripts/qapi/doc.py                           |  15 +-
 scripts/qapi/introspect.py                    |   6 +-
 scripts/qapi/types.py                         |   3 +-
 scripts/qapi/visit.py                         |   3 +-
 tests/Makefile.include                        |   6 +
 tests/qapi-schema/double-type.err             |   2 +-
 tests/qapi-schema/features-bad-type.err       |   1 +
 tests/qapi-schema/features-bad-type.exit      |   1 +
 tests/qapi-schema/features-bad-type.out       |   0
 tests/qapi-schema/features-duplicate-name.err |   1 +
 .../qapi-schema/features-duplicate-name.exit  |   1 +
 tests/qapi-schema/features-duplicate-name.out |   0
 tests/qapi-schema/features-missing-name.err   |   1 +
 tests/qapi-schema/features-missing-name.exit  |   1 +
 tests/qapi-schema/features-missing-name.out   |   0
 tests/qapi-schema/features-name-bad-type.err  |   1 +
 tests/qapi-schema/features-name-bad-type.exit |   1 +
 tests/qapi-schema/features-name-bad-type.out  |   0
 tests/qapi-schema/features-no-list.err        |   1 +
 tests/qapi-schema/features-no-list.exit       |   1 +
 tests/qapi-schema/features-no-list.out        |   0
 tests/qapi-schema/features-unknown-key.err    |   2 +
 tests/qapi-schema/features-unknown-key.exit   |   1 +
 tests/qapi-schema/features-unknown-key.out    |   0
 tests/qapi-schema/qapi-schema-test.out        |  43 ++++
 tests/qapi-schema/test-qapi.py                |   7 +-
 tests/qapi-schema/unknown-expr-key.err        |   2 +-
 38 files changed, 395 insertions(+), 47 deletions(-)
 create mode 100644 tests/qapi-schema/features-bad-type.json
 create mode 100644 tests/qapi-schema/features-duplicate-name.json
 create mode 100644 tests/qapi-schema/features-missing-name.json
 create mode 100644 tests/qapi-schema/features-name-bad-type.json
 create mode 100644 tests/qapi-schema/features-no-list.json
 create mode 100644 tests/qapi-schema/features-unknown-key.json
 create mode 100644 tests/qapi-schema/features-bad-type.err
 create mode 100644 tests/qapi-schema/features-bad-type.exit
 create mode 100644 tests/qapi-schema/features-bad-type.out
 create mode 100644 tests/qapi-schema/features-duplicate-name.err
 create mode 100644 tests/qapi-schema/features-duplicate-name.exit
 create mode 100644 tests/qapi-schema/features-duplicate-name.out
 create mode 100644 tests/qapi-schema/features-missing-name.err
 create mode 100644 tests/qapi-schema/features-missing-name.exit
 create mode 100644 tests/qapi-schema/features-missing-name.out
 create mode 100644 tests/qapi-schema/features-name-bad-type.err
 create mode 100644 tests/qapi-schema/features-name-bad-type.exit
 create mode 100644 tests/qapi-schema/features-name-bad-type.out
 create mode 100644 tests/qapi-schema/features-no-list.err
 create mode 100644 tests/qapi-schema/features-no-list.exit
 create mode 100644 tests/qapi-schema/features-no-list.out
 create mode 100644 tests/qapi-schema/features-unknown-key.err
 create mode 100644 tests/qapi-schema/features-unknown-key.exit
 create mode 100644 tests/qapi-schema/features-unknown-key.out

-- 
2.20.1


Re: [Qemu-devel] [PATCH v3 0/6] file-posix: Add dynamic-auto-read-only QAPI feature
Posted by no-reply@patchew.org 4 years, 10 months ago
Patchew URL: https://patchew.org/QEMU/20190530073205.5293-1-kwolf@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
time make docker-test-debug@fedora TARGET_LIST=x86_64-softmmu J=14 NETWORK=1
=== TEST SCRIPT END ===

clang++ -L/tmp/qemu-test/build/dtc/libfdt  -I/usr/include/pixman-1  -I/tmp/qemu-test/src/dtc/libfdt -Werror -DHAS_LIBSSH2_SFTP_FSYNC  -pthread -I/usr/include/glib-2.0 -I/usr/lib64/glib-2.0/include  -fPIE -DPIE -m64 -mcx16 -D_GNU_SOURCE -D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE -Wstrict-prototypes -Wredundant-decls -Wall -Wundef -Wwrite-strings -Wmissing-prototypes -fno-strict-aliasing -fno-common -fwrapv -std=gnu99  -Wno-string-plus-int -Wno-typedef-redefinition -Wno-initializer-overrides -Wexpansion-to-defined -Wendif-labels -Wno-shift-negative-value -Wno-missing-include-dirs -Wempty-body -Wnested-externs -Wformat-security -Wformat-y2k -Winit-self -Wignored-qualifiers -Wold-style-definition -Wtype-limits -fstack-protector-strong  -I/usr/include/p11-kit-1     -I/usr/include/libpng16  -I/usr/include/spice-1 -I/usr/include/spice-server -I/usr/include/cacard -I/usr/include/glib-2.0 -I/usr/lib64/glib-2.0/include -I/usr/include/nss3 -I/usr/include/nspr4 -pthread -I/usr/include/libmount -I/usr/include/blkid -I/usr/include/uuid -I/usr/include/pixman-1   -I/tmp/qemu-test/src/tests -fsanitize=undefined -fsanitize=address -g  -Wl,--warn-common -Wl,-z,relro -Wl,-z,now -pie -m64 -g  -o tests/test-opts-visitor tests/test-opts-visitor.o tests/test-qapi-types.o tests/include/test-qapi-types-sub-module.o tests/test-qapi-types-sub-sub-module.o tests/test-qapi-visit.o tests/include/test-qapi-visit-sub-module.o tests/test-qapi-visit-sub-sub-module.o tests/test-qapi-introspect.o qom/object.o qom/container.o qom/qom-qobject.o qom/object_interfaces.o  libqemuutil.a   -lm -lz  -lgthread-2.0 -pthread -lglib-2.0  -lnettle  -lgnutls   -lrt -lz -lutil -lcap-ng 
/usr/bin/ld: tests/test-qapi-commands.o: in function `qmp_marshal_test_features':
/tmp/qemu-test/build/tests/test-qapi-commands.c:693: undefined reference to `qmp_test_features'
clang-7: error: linker command failed with exit code 1 (use -v to see invocation)
make: *** [/tmp/qemu-test/src/rules.mak:124: tests/test-qmp-cmds] Error 1
make: *** Waiting for unfinished jobs....
make[1]: Leaving directory '/tmp/qemu-test/build/tests/fp'


The full log is available at
http://patchew.org/logs/20190530073205.5293-1-kwolf@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 v3 0/6] file-posix: Add dynamic-auto-read-only QAPI feature
Posted by Kevin Wolf 4 years, 10 months ago
Am 30.05.2019 um 09:54 hat no-reply@patchew.org geschrieben:
> Patchew URL: https://patchew.org/QEMU/20190530073205.5293-1-kwolf@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
> time make docker-test-debug@fedora TARGET_LIST=x86_64-softmmu J=14 NETWORK=1
> === TEST SCRIPT END ===
> 
> clang++ -L/tmp/qemu-test/build/dtc/libfdt  -I/usr/include/pixman-1  -I/tmp/qemu-test/src/dtc/libfdt -Werror -DHAS_LIBSSH2_SFTP_FSYNC  -pthread -I/usr/include/glib-2.0 -I/usr/lib64/glib-2.0/include  -fPIE -DPIE -m64 -mcx16 -D_GNU_SOURCE -D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE -Wstrict-prototypes -Wredundant-decls -Wall -Wundef -Wwrite-strings -Wmissing-prototypes -fno-strict-aliasing -fno-common -fwrapv -std=gnu99  -Wno-string-plus-int -Wno-typedef-redefinition -Wno-initializer-overrides -Wexpansion-to-defined -Wendif-labels -Wno-shift-negative-value -Wno-missing-include-dirs -Wempty-body -Wnested-externs -Wformat-security -Wformat-y2k -Winit-self -Wignored-qualifiers -Wold-style-definition -Wtype-limits -fstack-protector-strong  -I/usr/include/p11-kit-1     -I/usr/include/libpng16  -I/usr/include/spice-1 -I/usr/include/spice-server -I/usr/include/cacard -I/usr/include/glib-2.0 -I/usr/lib64/glib-2.0/include -I/usr/include/nss3 -I/usr/include/nspr4 -pthread -I/usr/include/libmount -I/usr/include/blkid -I/usr/include/uuid -I/usr/include/pixman-1   -I/tmp/qemu-test/src/tests -fsanitize=undefined -fsanitize=address -g  -Wl,--warn-common -Wl,-z,relro -Wl,-z,now -pie -m64 -g  -o tests/test-opts-visitor tests/test-opts-visitor.o tests/test-qapi-types.o tests/include/test-qapi-types-sub-module.o tests/test-qapi-types-sub-sub-module.o tests/test-qapi-visit.o tests/include/test-qapi-visit-sub-module.o tests/test-qapi-visit-sub-sub-module.o tests/test-qapi-introspect.o qom/object.o qom/container.o qom/qom-qobject.o qom/object_interfaces.o  libqemuutil.a   -lm -lz  -lgthread-2.0 -pthread -lglib-2.0  -lnettle  -lgnutls   -lrt -lz -lutil -lcap-ng 
> /usr/bin/ld: tests/test-qapi-commands.o: in function `qmp_marshal_test_features':
> /tmp/qemu-test/build/tests/test-qapi-commands.c:693: undefined reference to `qmp_test_features'
> clang-7: error: linker command failed with exit code 1 (use -v to see invocation)
> make: *** [/tmp/qemu-test/src/rules.mak:124: tests/test-qmp-cmds] Error 1
> make: *** Waiting for unfinished jobs....
> make[1]: Leaving directory '/tmp/qemu-test/build/tests/fp'

*sigh*

Not sure how this happened, I thought I had run a full 'make check'...
Anyway, v4 incoming.

Kevin