[PATCH v1 00/25] migration code cleanups + kbase document

Daniel Henrique Barboza danielhb413 at gmail.com
Mon Jul 13 09:49:32 UTC 2020


My intention was to better understand how Libvirt migration works
in the code level, aside from the documentation we already have in
migration.html.in. During my reading I ended up doing some trivial
cleanups use g_auto* functions here and there.

Last patch is a new kbase document with a summary of what I've learned.
Figured it might be a good complement for migration.html for

Daniel Henrique Barboza (25):
  libvirt-domain.c: modernize virDomainMigrateCheckNotLocal()
  libvirt-domain.c: modernize virDomainMigrateVersion1
  libvirt-domain.c: use g_autofree in virDomainMigrateVersion* functions
  qemu_driver.c: modernize qemuDomainMigrateBegin3Params()
  qemu_driver.c: modernize qemuDomainMigratePrepare3()
  qemu_driver.c: modernize qemuDomainMigratePrepare3Params()
  qemu_migration.c: modernize qemuMigrationDstPrepare()
  qemu_migration.c: use g_auto* in qemuMigrationDstPrepareAny()
  qemu_migration_params.c: modernize qemuMigrationParamsFetch()
  qemu_migration_params.c: modernize qemuMigrationParamsEnableTLS()
  qemu_migration_params.c: use g_autofree in qemuMigrationParamsApply()
  qemu_monitor_json.c: modernize qemuMonitorJSONMigrateIncoming()
  qemu_migration.c: use g_auto* in qemuMigrationDstPrepareDirect()
  qemu_migration_cookie.h: register AUTOPTR_CLEANUP_FUNC for
  qemu_migration.c: modernize qemuMigrationSrcBeginPhase()
  qemu_migration_cookie.c: modernize qemuMigrationEatCookie()
  qemu_driver.c: use g_auto* in qemuDomainMigratePerform3* functions
  qemu_migration.c: modernize qemuMigrationSrcPerformNative()
  qemu_migration.c: use auto* in qemuMigrationSrcRun()
  qemu_migration.c: use g_auto* in qemuMigrationSrcPerformJob and
  qemu_migration.c: modernize qemuMigrationDstPersist()
  qemu_migration.c: use g_auto* in qemuMigrationDstFinish()
  libvirt-domain.c: g_autofree in virDomainMigrate() and
  qemu_migration.c: modernize qemuMigrationSrcConfirmPhase()
  docs/kbase: introduce migrationinternals.rst

 docs/kbase/migrationinternals.rst | 174 ++++++++++++++++++++++++++++++
 src/libvirt-domain.c              |  68 ++++--------
 src/qemu/qemu_driver.c            | 105 ++++++++----------
 src/qemu/qemu_migration.c         | 158 ++++++++++-----------------
 src/qemu/qemu_migration_cookie.c  |  16 ++-
 src/qemu/qemu_migration_cookie.h  |   1 +
 src/qemu/qemu_migration_params.c  |  56 ++++------
 src/qemu/qemu_monitor_json.c      |  14 +--
 8 files changed, 323 insertions(+), 269 deletions(-)
 create mode 100644 docs/kbase/migrationinternals.rst


More information about the libvir-list mailing list