[PATCH 0/8] qemu: Unify generators for commandline and monitor chardev backends

Peter Krempa posted 8 patches 2 weeks, 3 days ago
src/qemu/meson.build                          |   1 +
src/qemu/qemu_block.c                         |   9 +-
src/qemu/qemu_capabilities.h                  |   2 +-
src/qemu/qemu_chardev.c                       | 488 ++++++++++++++++++
src/qemu/qemu_chardev.h                       |  22 +
src/qemu/qemu_command.c                       | 202 +-------
src/qemu/qemu_hotplug.c                       |  51 +-
src/qemu/qemu_monitor.c                       |   8 +-
src/qemu/qemu_monitor.h                       |   4 +-
src/qemu/qemu_monitor_json.c                  | 273 +---------
src/qemu/qemu_monitor_json.h                  |   4 +-
tests/qemumonitorjsontest.c                   |  23 +-
.../chardev-backends-json.x86_64-latest.args  |  79 +++
.../chardev-backends-json.x86_64-latest.xml   |   1 +
.../qemuxmlconfdata/chardev-backends-json.xml |   1 +
.../chardev-backends.x86_64-latest.args       |  79 +++
.../chardev-backends.x86_64-latest.xml        | 149 ++++++
tests/qemuxmlconfdata/chardev-backends.xml    | 111 ++++
tests/qemuxmlconftest.c                       |   7 +
19 files changed, 1026 insertions(+), 488 deletions(-)
create mode 100644 src/qemu/qemu_chardev.c
create mode 100644 src/qemu/qemu_chardev.h
create mode 100644 tests/qemuxmlconfdata/chardev-backends-json.x86_64-latest.args
create mode 120000 tests/qemuxmlconfdata/chardev-backends-json.x86_64-latest.xml
create mode 120000 tests/qemuxmlconfdata/chardev-backends-json.xml
create mode 100644 tests/qemuxmlconfdata/chardev-backends.x86_64-latest.args
create mode 100644 tests/qemuxmlconfdata/chardev-backends.x86_64-latest.xml
create mode 100644 tests/qemuxmlconfdata/chardev-backends.xml
[PATCH 0/8] qemu: Unify generators for commandline and monitor chardev backends
Posted by Peter Krempa 2 weeks, 3 days ago
Apart from having just one place to fix when changing chardev backends
this also adds validation against the schema so we can spot deprecations
early.

Peter Krempa (8):
  qemu: capabilities: Explain that QEMU_CAPS_CHARDEV_JSON will be used
    in tests only
  qemuxmlconftest: Add 'chardev-backends' test case
  qemu: Introduce unified chardev backend config generator
  qemuxmlconftest: Add support for validating schema for 'chardev-add'
  qemuxmlconftest: Add test case for QMP schema validation of -chardev
    backends
  qemu: Move check for chardev backends which can't be hotplugged out of
    the monitor
  qemu: Use the new chardev backend JSON props generator also in the
    monitor
  qemu: monitor: Remove the old chardev backend generator

 src/qemu/meson.build                          |   1 +
 src/qemu/qemu_block.c                         |   9 +-
 src/qemu/qemu_capabilities.h                  |   2 +-
 src/qemu/qemu_chardev.c                       | 488 ++++++++++++++++++
 src/qemu/qemu_chardev.h                       |  22 +
 src/qemu/qemu_command.c                       | 202 +-------
 src/qemu/qemu_hotplug.c                       |  51 +-
 src/qemu/qemu_monitor.c                       |   8 +-
 src/qemu/qemu_monitor.h                       |   4 +-
 src/qemu/qemu_monitor_json.c                  | 273 +---------
 src/qemu/qemu_monitor_json.h                  |   4 +-
 tests/qemumonitorjsontest.c                   |  23 +-
 .../chardev-backends-json.x86_64-latest.args  |  79 +++
 .../chardev-backends-json.x86_64-latest.xml   |   1 +
 .../qemuxmlconfdata/chardev-backends-json.xml |   1 +
 .../chardev-backends.x86_64-latest.args       |  79 +++
 .../chardev-backends.x86_64-latest.xml        | 149 ++++++
 tests/qemuxmlconfdata/chardev-backends.xml    | 111 ++++
 tests/qemuxmlconftest.c                       |   7 +
 19 files changed, 1026 insertions(+), 488 deletions(-)
 create mode 100644 src/qemu/qemu_chardev.c
 create mode 100644 src/qemu/qemu_chardev.h
 create mode 100644 tests/qemuxmlconfdata/chardev-backends-json.x86_64-latest.args
 create mode 120000 tests/qemuxmlconfdata/chardev-backends-json.x86_64-latest.xml
 create mode 120000 tests/qemuxmlconfdata/chardev-backends-json.xml
 create mode 100644 tests/qemuxmlconfdata/chardev-backends.x86_64-latest.args
 create mode 100644 tests/qemuxmlconfdata/chardev-backends.x86_64-latest.xml
 create mode 100644 tests/qemuxmlconfdata/chardev-backends.xml

-- 
2.46.0