[PATCH v3 00/20] migration: MigrationParameters changes

Fabiano Rosas posted 20 patches 1 week, 4 days ago
Maintainers: Pierrick Bouvier <pierrick.bouvier@oss.qualcomm.com>, Markus Armbruster <armbru@redhat.com>, Michael Roth <michael.roth@amd.com>, Peter Xu <peterx@redhat.com>, Fabiano Rosas <farosas@suse.de>, Eric Blake <eblake@redhat.com>, Chao Liu <chao.liu@processmission.com>, Kevin Wolf <kwolf@redhat.com>, Hanna Reitz <hreitz@redhat.com>, Laurent Vivier <lvivier@redhat.com>, Paolo Bonzini <pbonzini@redhat.com>
docs/about/deprecated.rst          |  13 +
include/qapi/clone-visitor.h       |   1 +
migration/migration-hmp-cmds.c     | 445 +++++-----------
migration/migration.c              |  19 +-
migration/migration.h              |   2 +-
migration/options.c                | 789 +++++++++++------------------
migration/options.h                |  29 +-
migration/savevm.c                 |   8 +-
qapi/migration.json                | 168 ++++--
qapi/qapi-clone-visitor.c          |  13 +
scripts/checkpatch.pl              |  11 +-
tests/qemu-iotests/300             |  20 +-
tests/qtest/migration/misc-tests.c | 560 ++++++++++++++++++++
13 files changed, 1173 insertions(+), 905 deletions(-)
[PATCH v3 00/20] migration: MigrationParameters changes
Posted by Fabiano Rosas 1 week, 4 days ago
since v2:

- Better handling the cpr-exec-command special case by converting the
  string input to a QList.

- New clone visitor to replace the manual setting of has_* fields. It
  now happens once at instance_init before s->parameters is even
  available to the rest of the code.

- Removed MigrationParameter.

- Added some line breaks and spacing to the block-bitmap-mapping
  output (and lists in general).

- Simplified the completion test by using g_ptr_array.

- Updated the parameters test to call query-migrate since there's no
  MigrateParameter_lookup to list the parameters names anymore.

- Rebased on master and picked-up the new 'local' parameter.

(apologies if I might have missed some r-bs, my 'b4 trailers' is
broken at the moment)

CI run: https://gitlab.com/farosas/qemu/-/pipelines/2848741815

v2:
https://lore.kernel.org/r/20260909214509.237309-1-farosas@suse.de
v1:
https://lore.kernel.org/r/20260902221547.1812481-1-farosas@suse.de

Fabiano Rosas (20):
  checkpatch: Fix checking of newlines in error messages
  migration/options.c: Don't export migrate_tls_opts_free
  migration: Rename variables in qmp_migrate_set_parameters
  migration: Use QAPI_CLONE_MEMBERS in migrate_params_apply
  migration: Merge parameter structs instead of assigning one by one
  migration: Open code migrate_params_apply
  migration: Stop freeing s->parameters members individually
  migration: Use migrate_params_free during finalize
  tests/qtest/migration: Add a test for HMP
  tests/qtest/migration: Add a test for HMP completion
  migration: HMP: Change bandwidth parameters expected input unit
  migration: Change HMP 'info migrate_parameters' output
  migration: Use keyval input visitor in HMP set command
  migration: Use output visitor in info command
  migration: Rewrite migrate_set_parameter_completion using QDict
  migration: Add capabilities into MigrationParameters
  migration: Remove s->capabilities
  qapi/migration: Deprecate capabilities commands
  migration: Set the parameters present flag with a clone visitor
  qapi: Remove MigrationParameter

 docs/about/deprecated.rst          |  13 +
 include/qapi/clone-visitor.h       |   1 +
 migration/migration-hmp-cmds.c     | 445 +++++-----------
 migration/migration.c              |  19 +-
 migration/migration.h              |   2 +-
 migration/options.c                | 789 +++++++++++------------------
 migration/options.h                |  29 +-
 migration/savevm.c                 |   8 +-
 qapi/migration.json                | 168 ++++--
 qapi/qapi-clone-visitor.c          |  13 +
 scripts/checkpatch.pl              |  11 +-
 tests/qemu-iotests/300             |  20 +-
 tests/qtest/migration/misc-tests.c | 560 ++++++++++++++++++++
 13 files changed, 1173 insertions(+), 905 deletions(-)

-- 
2.53.0
Re: [PATCH v3 00/20] migration: MigrationParameters changes
Posted by Fabiano Rosas 4 days, 7 hours ago
Fabiano Rosas <farosas@suse.de> writes:

> since v2:
>
> - Better handling the cpr-exec-command special case by converting the
>   string input to a QList.
>
> - New clone visitor to replace the manual setting of has_* fields. It
>   now happens once at instance_init before s->parameters is even
>   available to the rest of the code.
>
> - Removed MigrationParameter.
>
> - Added some line breaks and spacing to the block-bitmap-mapping
>   output (and lists in general).
>
> - Simplified the completion test by using g_ptr_array.
>
> - Updated the parameters test to call query-migrate since there's no
>   MigrateParameter_lookup to list the parameters names anymore.
>
> - Rebased on master and picked-up the new 'local' parameter.
>
> (apologies if I might have missed some r-bs, my 'b4 trailers' is
> broken at the moment)
>
> CI run: https://gitlab.com/farosas/qemu/-/pipelines/2848741815
>
> v2:
> https://lore.kernel.org/r/20260909214509.237309-1-farosas@suse.de
> v1:
> https://lore.kernel.org/r/20260902221547.1812481-1-farosas@suse.de
>
> Fabiano Rosas (20):
>   checkpatch: Fix checking of newlines in error messages
>   migration/options.c: Don't export migrate_tls_opts_free
>   migration: Rename variables in qmp_migrate_set_parameters
>   migration: Use QAPI_CLONE_MEMBERS in migrate_params_apply
>   migration: Merge parameter structs instead of assigning one by one
>   migration: Open code migrate_params_apply
>   migration: Stop freeing s->parameters members individually
>   migration: Use migrate_params_free during finalize
>   tests/qtest/migration: Add a test for HMP
>   tests/qtest/migration: Add a test for HMP completion
>   migration: HMP: Change bandwidth parameters expected input unit
>   migration: Change HMP 'info migrate_parameters' output
>   migration: Use keyval input visitor in HMP set command
>   migration: Use output visitor in info command
>   migration: Rewrite migrate_set_parameter_completion using QDict
>   migration: Add capabilities into MigrationParameters
>   migration: Remove s->capabilities
>   qapi/migration: Deprecate capabilities commands
>   migration: Set the parameters present flag with a clone visitor
>   qapi: Remove MigrationParameter
>
>  docs/about/deprecated.rst          |  13 +
>  include/qapi/clone-visitor.h       |   1 +
>  migration/migration-hmp-cmds.c     | 445 +++++-----------
>  migration/migration.c              |  19 +-
>  migration/migration.h              |   2 +-
>  migration/options.c                | 789 +++++++++++------------------
>  migration/options.h                |  29 +-
>  migration/savevm.c                 |   8 +-
>  qapi/migration.json                | 168 ++++--
>  qapi/qapi-clone-visitor.c          |  13 +
>  scripts/checkpatch.pl              |  11 +-
>  tests/qemu-iotests/300             |  20 +-
>  tests/qtest/migration/misc-tests.c | 560 ++++++++++++++++++++
>  13 files changed, 1173 insertions(+), 905 deletions(-)

I queued patches 2-8 for the next pull request. I'll leave
migration-next to marinate for a day or two. If anyone needs more time
with those patches, let me know and I can drop them no problem.

Thanks