diff --git a/examples/c/misc/event-test.c b/examples/c/misc/event-test.c index 347ec44682..2ce82ca9e0 100644 --- a/examples/c/misc/event-test.c +++ b/examples/c/misc/event-test.c @@ -180,6 +180,9 @@ eventDetailToString(int event, case VIR_DOMAIN_EVENT_SUSPENDED_POSTCOPY_FAILED: return "Post-copy Error"; + case VIR_DOMAIN_EVENT_SUSPENDED_GUEST_SHUTDOWN: + return "guest OS shutdown"; + case VIR_DOMAIN_EVENT_SUSPENDED_LAST: break; } diff --git a/include/libvirt/libvirt-domain.h b/include/libvirt/libvirt-domain.h index e16c1925cd..3f5bd1ff7b 100644 --- a/include/libvirt/libvirt-domain.h +++ b/include/libvirt/libvirt-domain.h @@ -5401,6 +5401,7 @@ typedef enum { VIR_DOMAIN_EVENT_SUSPENDED_API_ERROR = 6, /* Some APIs (e.g., migration, snapshot) internally need to suspend a domain. This event detail is used when resume operation at the end of such API fails. (Since: 1.0.1) */ VIR_DOMAIN_EVENT_SUSPENDED_POSTCOPY = 7, /* suspended for post-copy migration (Since: 1.3.3) */ VIR_DOMAIN_EVENT_SUSPENDED_POSTCOPY_FAILED = 8, /* suspended after failed post-copy (Since: 1.3.3) */ + VIR_DOMAIN_EVENT_SUSPENDED_GUEST_SHUTDOWN = 9, /* suspended after guest os shut-down (a long running job is preserving the VM until completion) (Since: 11.10.0) */ # ifdef VIR_ENUM_SENTINELS VIR_DOMAIN_EVENT_SUSPENDED_LAST /* (Since: 0.9.10) */ diff --git a/tools/virsh-domain-event.c b/tools/virsh-domain-event.c index a47fdfc7fd..b9d1cdf019 100644 --- a/tools/virsh-domain-event.c +++ b/tools/virsh-domain-event.c @@ -85,7 +85,8 @@ VIR_ENUM_IMPL(virshDomainEventSuspended, N_("Snapshot"), N_("API error"), N_("Post-copy"), - N_("Post-copy Error")); + N_("Post-copy Error"), + N_("guest shutdown")); VIR_ENUM_DECL(virshDomainEventResumed); VIR_ENUM_IMPL(virshDomainEventResumed,