Re: [PATCH v4 1/5] libvirt: Define domain crash event types

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Applied and tested successfully on s390x platform (as expected by me).

Eric mentioned already the few points that should be corrected (indentation of comments).


Mit freundlichen Grüßen / Kind regards
Daniel Hansel

IBM Deutschland Research & Development GmbH
Vorsitzende des Aufsichtsrats: Martina Koederitz
Geschäftsführung: Dirk Wittkopp
Sitz der Gesellschaft: Böblingen
Registergericht: Amtsgericht Stuttgart, HRB 243294

On 05.06.2013 05:03, Eric Blake wrote:
On 06/02/2013 09:58 PM, Chen Fan wrote:
This patch introduces domain crashed types and crashed reasons which
will be used while guest panicked.
---
  examples/domain-events/events-c/event-test.c | 10 ++++++++++
  include/libvirt/libvirt.h.in                 | 16 ++++++++++++++++
  src/conf/domain_conf.c                       | 12 ++++++++----
  3 files changed, 34 insertions(+), 4 deletions(-)


+++ b/include/libvirt/libvirt.h.in
@@ -155,6 +155,7 @@ typedef enum {
      VIR_DOMAIN_RUNNING_SAVE_CANCELED = 7,   /* returned from failed save process */
      VIR_DOMAIN_RUNNING_WAKEUP = 8,          /* returned from pmsuspended due to
                                                 wakeup event */
+    VIR_DOMAIN_RUNNING_CRASHED = 9,          /* resumed from crashed */

Indentation looks odd, but that's a trivial fix.


@@ -212,6 +215,7 @@ typedef enum {

  typedef enum {
      VIR_DOMAIN_CRASHED_UNKNOWN = 0,     /* crashed for unknown reason */
+    VIR_DOMAIN_CRASHED_PANICKED = 1,     /* domain panicked */

and again


+++ b/src/conf/domain_conf.c
@@ -642,7 +642,8 @@ VIR_ENUM_IMPL(virDomainRunningReason, VIR_DOMAIN_RUNNING_LAST,
                "unpaused",
                "migration canceled",
                "save canceled",
-              "wakeup")
+              "wakeup",
+              "from crashed")

Might be better as merely "crashed"


  VIR_ENUM_IMPL(virDomainBlockedReason, VIR_DOMAIN_BLOCKED_LAST,
                "unknown")
@@ -657,11 +658,13 @@ VIR_ENUM_IMPL(virDomainPausedReason, VIR_DOMAIN_PAUSED_LAST,
                "watchdog",
                "from snapshot",
                "shutdown",
-              "snapshot")
+              "snapshot",
+              "guest panicked")

Might be better as merely "panicked"

Overall, looks like a reasonable set of additions in isolation, but I'm
still trying to figure out if support for xen panic detection already
had existing events that we should be reusing, instead of adding new
events just for qemu.



--
libvir-list mailing list
libvir-list@xxxxxxxxxx
https://www.redhat.com/mailman/listinfo/libvir-list


--
libvir-list mailing list
libvir-list@xxxxxxxxxx
https://www.redhat.com/mailman/listinfo/libvir-list





[Index of Archives]     [Virt Tools]     [Libvirt Users]     [Lib OS Info]     [Fedora Users]     [Fedora Desktop]     [Fedora SELinux]     [Big List of Linux Books]     [Yosemite News]     [KDE Users]     [Fedora Tools]