[PATCH v2 03/34] docs: generated: enums: libvirt: append 'Since version' metadata

Peter Krempa pkrempa at redhat.com
Tue Apr 19 12:40:05 UTC 2022


On Thu, Apr 14, 2022 at 22:47:14 +0200, Victor Toso wrote:
> Minor hand adjustments around syntax, not the metadata per se.
> 
> Signed-off-by: Victor Toso <victortoso at redhat.com>
> ---
>  include/libvirt/libvirt-domain-checkpoint.h |  28 +-
>  include/libvirt/libvirt-domain-snapshot.h   |  60 +-
>  include/libvirt/libvirt-domain.h            | 877 +++++++++++---------
>  include/libvirt/libvirt-host.h              |  36 +-
>  include/libvirt/libvirt-interface.h         |   4 +-
>  include/libvirt/libvirt-network.h           |  50 +-
>  include/libvirt/libvirt-nodedev.h           |  54 +-
>  include/libvirt/libvirt-nwfilter.h          |   4 +-
>  include/libvirt/libvirt-secret.h            |  10 +-
>  include/libvirt/libvirt-storage.h           |  96 ++-
>  include/libvirt/virterror.h                 | 394 ++++-----
>  11 files changed, 877 insertions(+), 736 deletions(-)

[...]

>  
>  typedef enum {
>      VIR_DOMAIN_RUNNING_UNKNOWN = 0,
> -    VIR_DOMAIN_RUNNING_BOOTED = 1,          /* normal startup from boot */
> -    VIR_DOMAIN_RUNNING_MIGRATED = 2,        /* migrated from another host */
> -    VIR_DOMAIN_RUNNING_RESTORED = 3,        /* restored from a state file */
> -    VIR_DOMAIN_RUNNING_FROM_SNAPSHOT = 4,   /* restored from snapshot */
> -    VIR_DOMAIN_RUNNING_UNPAUSED = 5,        /* returned from paused state */
> -    VIR_DOMAIN_RUNNING_MIGRATION_CANCELED = 6,  /* returned from migration */
> -    VIR_DOMAIN_RUNNING_SAVE_CANCELED = 7,   /* returned from failed save process */
> +    VIR_DOMAIN_RUNNING_BOOTED = 1,          /* normal startup from boot (Since: v1.0.0) */
> +    VIR_DOMAIN_RUNNING_MIGRATED = 2,        /* migrated from another host (Since: v1.0.0) */

Your script doesn't seem to handle well versions prior to v1.0.0. This
specific constant was added in commit v0.9.1-133-gd65a924b34 thus it
should be 'Since v0.9.2'.

I understand that we might not want to deal with too old releases, but
in such case we should rather pick a different marker meaning that the
symbol was added too long ago.

Note that this is definitely not an exhaustive search, just something
I've noticed randomly because there were just simply too many symbols
refering to v1.0.0 and the particular release was not special in any
way, we simply bumped the major version on the 7th anniversary of
libvirt.


More information about the libvir-list mailing list