mbox

[PULL,00/28] QAPI patches patches for 2022-10-25

Message ID 20221025080541.271547-1-armbru@redhat.com
State New
Headers show

Pull-request

git://repo.or.cz/qemu/armbru.git tags/pull-qapi-2022-10-25

Message

Markus Armbruster Oct. 25, 2022, 8:05 a.m. UTC
The following changes since commit e750a7ace492f0b450653d4ad368a77d6f660fb8:

  Merge tag 'pull-9p-20221024' of https://github.com/cschoenebeck/qemu into staging (2022-10-24 14:27:12 -0400)

are available in the Git repository at:

  git://repo.or.cz/qemu/armbru.git tags/pull-qapi-2022-10-25

for you to fetch changes up to 9e0ce16f76dc73cc17899d5c745cc23659a9ab2e:

  qapi: Drop temporary logic to support conversion step by step (2022-10-25 08:18:31 +0200)

----------------------------------------------------------------
QAPI patches patches for 2022-10-25

----------------------------------------------------------------
Markus Armbruster (28):
      docs/devel/qapi-code-gen: Update example to match current code
      qapi: Tidy up whitespace in generated code
      docs/devel/qapi-code-gen: Extend example for next commit's change
      qapi: Start to elide redundant has_FOO in generated C
      qapi tests: Elide redundant has_FOO in generated C
      qapi acpi: Elide redundant has_FOO in generated C
      qapi audio: Elide redundant has_FOO in generated C
      qapi block: Elide redundant has_FOO in generated C
      qapi chardev: Elide redundant has_FOO in generated C
      qapi crypto: Elide redundant has_FOO in generated C
      qapi dump: Elide redundant has_FOO in generated C
      qapi job: Elide redundant has_FOO in generated C
      qapi machine: Elide redundant has_FOO in generated C
      qapi migration: Elide redundant has_FOO in generated C
      qapi misc: Elide redundant has_FOO in generated C
      qapi net: Elide redundant has_FOO in generated C
      qapi pci: Elide redundant has_FOO in generated C
      qapi qdev qom: Elide redundant has_FOO in generated C
      qapi replay: Elide redundant has_FOO in generated C
      qapi rocker: Elide redundant has_FOO in generated C
      qapi run-state: Elide redundant has_FOO in generated C
      qapi stats: Elide redundant has_FOO in generated C
      qapi tpm: Elide redundant has_FOO in generated C
      qapi transaction: Elide redundant has_FOO in generated C
      qapi ui: Elide redundant has_FOO in generated C
      qapi virtio: Elide redundant has_FOO in generated C
      qapi qga: Elide redundant has_FOO in generated C
      qapi: Drop temporary logic to support conversion step by step

 docs/devel/qapi-code-gen.rst             |  29 +++++-
 docs/devel/writing-monitor-commands.rst  |  14 +--
 include/monitor/monitor.h                |   3 +-
 audio/alsaaudio.c                        |   2 +-
 audio/audio.c                            |   6 +-
 audio/audio_legacy.c                     |  17 ++-
 audio/ossaudio.c                         |   8 +-
 audio/paaudio.c                          |  12 +--
 audio/wavaudio.c                         |   2 +-
 backends/tpm/tpm_passthrough.c           |   2 -
 block/block-backend.c                    |   2 +-
 block/copy-before-write.c                |   2 +-
 block/dirty-bitmap.c                     |   1 -
 block/export/export.c                    |   2 +-
 block/export/vduse-blk.c                 |   3 +-
 block/gluster.c                          |   3 -
 block/monitor/block-hmp-cmds.c           |  48 ++++-----
 block/qapi-sysemu.c                      |  73 +++++--------
 block/qapi.c                             |  62 ++++-------
 block/qcow.c                             |  10 +-
 block/qcow2.c                            |  18 ++--
 block/qed.c                              |   2 +-
 block/quorum.c                           |   2 +-
 block/rbd.c                              |  15 +--
 block/ssh.c                              |   2 +-
 blockdev-nbd.c                           |   9 +-
 blockdev.c                               | 173 ++++++++++++-------------------
 blockjob.c                               |   2 -
 chardev/char-file.c                      |   4 +-
 chardev/char-socket.c                    |  10 +-
 chardev/char-udp.c                       |   1 -
 chardev/char.c                           |   6 +-
 crypto/block-luks.c                      |  16 +--
 dump/dump.c                              |   4 +-
 hw/acpi/core.c                           |  14 +--
 hw/acpi/cpu.c                            |   1 -
 hw/acpi/memory_hotplug.c                 |   3 +-
 hw/core/machine-hmp-cmds.c               |   2 +-
 hw/core/machine-qmp-cmds.c               |   9 +-
 hw/core/machine.c                        |  10 +-
 hw/core/numa.c                           |   8 +-
 hw/core/qdev.c                           |   2 +-
 hw/mem/pc-dimm.c                         |   1 -
 hw/net/rocker/rocker_of_dpa.c            |  13 +--
 hw/net/virtio-net.c                      |   3 +-
 hw/nvram/fw_cfg.c                        |   2 +-
 hw/pci/pci.c                             |   2 -
 hw/ppc/spapr.c                           |   2 +-
 hw/ppc/spapr_drc.c                       |   3 +-
 hw/virtio/virtio-mem-pci.c               |   4 +-
 hw/virtio/virtio-pmem-pci.c              |   1 -
 hw/virtio/virtio.c                       |   1 -
 job-qmp.c                                |   3 +-
 migration/block-dirty-bitmap.c           |   4 +-
 migration/colo.c                         |   1 -
 migration/migration.c                    |  27 ++---
 monitor/hmp-cmds.c                       |  84 +++++++--------
 monitor/misc.c                           |  21 ++--
 monitor/qmp-cmds.c                       |  11 +-
 nbd/server.c                             |   2 +-
 net/announce.c                           |   8 +-
 net/hub.c                                |   2 +-
 net/l2tpv3.c                             |   2 +-
 net/net.c                                |  25 +++--
 net/slirp.c                              |   4 +-
 net/socket.c                             |  18 ++--
 net/tap-win32.c                          |   2 +-
 net/tap.c                                |  51 +++++----
 qemu-img.c                               |  13 ++-
 qemu-nbd.c                               |   2 -
 qga/commands-posix.c                     |  33 ++----
 qga/commands-win32.c                     |  40 ++-----
 qga/commands.c                           |  11 +-
 qom/qom-qmp-cmds.c                       |   7 +-
 replay/replay-debugging.c                |   1 -
 softmmu/runstate.c                       |  18 +---
 softmmu/vl.c                             |   2 +-
 target/arm/monitor.c                     |   1 -
 target/i386/cpu-sysemu.c                 |   7 +-
 target/i386/cpu.c                        |   1 -
 target/s390x/cpu_models_sysemu.c         |   1 -
 tests/qtest/fuzz/qos_fuzz.c              |   3 +-
 tests/qtest/qmp-cmd-test.c               |   2 +-
 tests/unit/test-char.c                   |   1 -
 tests/unit/test-crypto-block.c           |   6 --
 tests/unit/test-qmp-cmds.c               |  26 +++--
 tests/unit/test-qmp-event.c              |   4 +-
 tests/unit/test-qobject-input-visitor.c  |   2 +-
 tests/unit/test-qobject-output-visitor.c |   2 -
 tests/unit/test-visitor-serialization.c  |   3 +-
 ui/console.c                             |   4 +-
 ui/input.c                               |   4 +-
 ui/spice-core.c                          |   5 -
 ui/vnc.c                                 |  10 --
 util/qemu-config.c                       |  17 +--
 scripts/qapi/commands.py                 |   9 +-
 scripts/qapi/events.py                   |   3 +-
 scripts/qapi/gen.py                      |   2 +-
 scripts/qapi/schema.py                   |  14 +++
 scripts/qapi/types.py                    |   2 +-
 scripts/qapi/visit.py                    |  17 ++-
 101 files changed, 468 insertions(+), 716 deletions(-)

Comments

Stefan Hajnoczi Oct. 25, 2022, 3:40 p.m. UTC | #1
On Tue, 25 Oct 2022 at 05:00, Markus Armbruster <armbru@redhat.com> wrote:
>
> The following changes since commit e750a7ace492f0b450653d4ad368a77d6f660fb8:
>
>   Merge tag 'pull-9p-20221024' of https://github.com/cschoenebeck/qemu into staging (2022-10-24 14:27:12 -0400)
>
> are available in the Git repository at:
>
>   git://repo.or.cz/qemu/armbru.git tags/pull-qapi-2022-10-25

Hi Markus,
Please replace this with the HTTPS URL in future pull requests:
https://repo.or.cz/qemu/armbru.git

The unencrypted git:// protocol makes me nervous.

Thanks,
Stefan
Markus Armbruster Oct. 25, 2022, 7 p.m. UTC | #2
Stefan Hajnoczi <stefanha@gmail.com> writes:

> On Tue, 25 Oct 2022 at 05:00, Markus Armbruster <armbru@redhat.com> wrote:
>>
>> The following changes since commit e750a7ace492f0b450653d4ad368a77d6f660fb8:
>>
>>   Merge tag 'pull-9p-20221024' of https://github.com/cschoenebeck/qemu into staging (2022-10-24 14:27:12 -0400)
>>
>> are available in the Git repository at:
>>
>>   git://repo.or.cz/qemu/armbru.git tags/pull-qapi-2022-10-25
>
> Hi Markus,
> Please replace this with the HTTPS URL in future pull requests:
> https://repo.or.cz/qemu/armbru.git
>
> The unencrypted git:// protocol makes me nervous.

The signature on the tag should suffice to keep us safe.  But I made the
switch anyway, it can't hurt.
Stefan Hajnoczi Oct. 25, 2022, 8:07 p.m. UTC | #3
The following CI failures were reported. I think they may be related
to this pull request:

cc -m64 -mcx16 -Ilibblock.fa.p -I. -I.. -Iqapi -Itrace -Iui
-Iui/shader -Iblock -I/usr/include/p11-kit-1
-I/usr/include/x86_64-linux-gnu -I/usr/include/uuid
-I/usr/include/glib-2.0 -I/usr/lib/x86_64-linux-gnu/glib-2.0/include
-fdiagnostics-color=auto -Wall -Winvalid-pch -Werror -std=gnu11 -O2 -g
-isystem /builds/qemu-project/qemu/linux-headers -isystem
linux-headers -iquote . -iquote /builds/qemu-project/qemu -iquote
/builds/qemu-project/qemu/include -pthread -U_FORTIFY_SOURCE
-D_FORTIFY_SOURCE=2 -D_GNU_SOURCE -D_LARGEFILE_SOURCE
-Wstrict-prototypes -Wredundant-decls -Wundef -Wwrite-strings
-Wmissing-prototypes -fno-strict-aliasing -fno-common -fwrapv
-Wold-style-declaration -Wold-style-definition -Wtype-limits
-Wformat-security -Wformat-y2k -Winit-self -Wignored-qualifiers
-Wempty-body -Wnested-externs -Wendif-labels -Wexpansion-to-defined
-Wimplicit-fallthrough=2 -Wno-missing-include-dirs
-Wno-shift-negative-value -Wno-psabi -fstack-protector-strong -fPIE
-D_FILE_OFFSET_BITS=64 -D__USE_FILE_OFFSET64 -D__USE_LARGEFILE64
-DUSE_POSIX_ACLS=1 -MD -MQ libblock.fa.p/block_rbd.c.o -MF
libblock.fa.p/block_rbd.c.o.d -o libblock.fa.p/block_rbd.c.o -c
../block/rbd.c
../block/rbd.c: In function ‘qemu_rbd_do_create’:
../block/rbd.c:545:15: error: ‘BlockdevCreateOptionsRbd’ {aka ‘struct
BlockdevCreateOptionsRbd’} has no member named ‘has_encrypt’; did you
mean ‘encrypt’?
545 | if (opts->has_encrypt) {
| ^~~~~~~~~~~
| encrypt

https://gitlab.com/qemu-project/qemu/-/jobs/3225215747

I think this will solve it:
diff --cc block/rbd.c
index f826410f40,d809b8e0a3..3aa6aae0e0
--- a/block/rbd.c
+++ b/block/rbd.c
@@@ -542,7 -542,7 +542,7 @@@ static int qemu_rbd_do_create(BlockdevC
      }

  #ifndef LIBRBD_SUPPORTS_ENCRYPTION
--    if (opts->has_encrypt) {
++    if (opts->encrypt) {
          error_setg(errp, "RBD library does not support image encryption");
          return -ENOTSUP;
      }

cc -m64 -mcx16 -Ilibqemuutil.a.p -I. -I.. -Iqapi -Itrace -Iui/shader
-I/usr/include/glib-2.0 -I/usr/lib/x86_64-linux-gnu/glib-2.0/include
-fdiagnostics-color=auto -Wall -Winvalid-pch -Werror -std=gnu11 -O2 -g
-isystem /builds/qemu-project/qemu/linux-headers -isystem
linux-headers -iquote . -iquote /builds/qemu-project/qemu -iquote
/builds/qemu-project/qemu/include -iquote
/builds/qemu-project/qemu/tcg/i386 -pthread -U_FORTIFY_SOURCE
-D_FORTIFY_SOURCE=2 -D_GNU_SOURCE -D_FILE_OFFSET_BITS=64
-D_LARGEFILE_SOURCE -Wstrict-prototypes -Wredundant-decls -Wundef
-Wwrite-strings -Wmissing-prototypes -fno-strict-aliasing -fno-common
-fwrapv -Wold-style-declaration -Wold-style-definition -Wtype-limits
-Wformat-security -Wformat-y2k -Winit-self -Wignored-qualifiers
-Wempty-body -Wnested-externs -Wendif-labels -Wexpansion-to-defined
-Wimplicit-fallthrough=2 -Wno-missing-include-dirs
-Wno-shift-negative-value -Wno-psabi -fstack-protector-strong -fPIE
-MD -MQ libqemuutil.a.p/stubs_qdev.c.o -MF
libqemuutil.a.p/stubs_qdev.c.o.d -o libqemuutil.a.p/stubs_qdev.c.o -c
../stubs/qdev.c
../stubs/qdev.c:18:6: error: conflicting types for
'qapi_event_send_device_deleted'
18 | void qapi_event_send_device_deleted(bool has_device,
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
In file included from ../stubs/qdev.c:16:
./qapi/qapi-events-qdev.h:20:6: note: previous declaration of
'qapi_event_send_device_deleted' was here
20 | void qapi_event_send_device_deleted(const char *device, const char *path);
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
../stubs/qdev.c:25:6: error: conflicting types for
'qapi_event_send_device_unplug_guest_error'
25 | void qapi_event_send_device_unplug_guest_error(bool has_device,
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
In file included from ../stubs/qdev.c:16:
./qapi/qapi-events-qdev.h:22:6: note: previous declaration of
'qapi_event_send_device_unplug_guest_error' was here
22 | void qapi_event_send_device_unplug_guest_error(const char
*device, const char *path);
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

https://gitlab.com/qemu-project/qemu/-/jobs/3225215726
Markus Armbruster Oct. 26, 2022, 6:43 p.m. UTC | #4
Stefan Hajnoczi <stefanha@gmail.com> writes:

> The following CI failures were reported. I think they may be related
> to this pull request:
[...]

They are.  v2 sent & fingers crossed.  Thanks!