Blame SOURCES/libvirt-RHEL-Switch-to-private-redhat-namespace-for-QMP-I-O-error-reason.patch

9119d9
From 8d2d15ec73393f360a1bf7b88ee2cb491efad037 Mon Sep 17 00:00:00 2001
9119d9
Message-Id: <8d2d15ec73393f360a1bf7b88ee2cb491efad037@dist-git>
c401cc
From: "Daniel P. Berrange" <berrange@redhat.com>
c401cc
Date: Fri, 17 Dec 2010 14:55:35 +0100
9119d9
Subject: [PATCH] RHEL: Switch to private redhat namespace for QMP I/O error
9119d9
 reason
c401cc
c401cc
RHEL only, no upstream
c401cc
c401cc
For
c401cc
  https://bugzilla.redhat.com/show_bug.cgi?id=1026966
c401cc
  https://bugzilla.redhat.com/show_bug.cgi?id=586353
c401cc
c401cc
The I/O error reason support is not yet available in QEMU, so RHEL6
c401cc
is using the redhat private namespace for it
c401cc
c401cc
* src/qemu/qemu_monitor_json.c: Replace 'reason' with '__com.redhat_reason'
c401cc
c401cc
(cherry picked from commit 369186c3f1555fa66b084bdf1f1d3f21f041256d in
c401cc
rhel-6.5 branch)
c401cc
c401cc
Signed-off-by: Jiri Denemark <jdenemar@redhat.com>
c401cc
---
c401cc
 src/qemu/qemu_monitor_json.c | 8 ++------
c401cc
 1 file changed, 2 insertions(+), 6 deletions(-)
c401cc
c401cc
diff --git a/src/qemu/qemu_monitor_json.c b/src/qemu/qemu_monitor_json.c
9119d9
index 6e8834f..e88068c 100644
c401cc
--- a/src/qemu/qemu_monitor_json.c
c401cc
+++ b/src/qemu/qemu_monitor_json.c
9119d9
@@ -737,14 +737,10 @@ static void qemuMonitorJSONHandleIOError(qemuMonitorPtr mon, virJSONValuePtr dat
c401cc
         VIR_WARN("missing device in disk io error event");
c401cc
     }
c401cc
 
c401cc
-#if 0
c401cc
-    if ((reason = virJSONValueObjectGetString(data, "reason")) == NULL) {
c401cc
-        VIR_WARN("missing reason in disk io error event");
c401cc
+    if ((reason = virJSONValueObjectGetString(data, "__com.redhat_reason")) == NULL) {
c401cc
+        VIR_WARN("missing __com.redhat_reason in disk io error event");
c401cc
         reason = "";
c401cc
     }
c401cc
-#else
c401cc
-    reason = "";
c401cc
-#endif
c401cc
 
c401cc
     if ((actionID = qemuMonitorIOErrorActionTypeFromString(action)) < 0) {
c401cc
         VIR_WARN("unknown disk io error action '%s'", action);
c401cc
-- 
9119d9
2.1.0
c401cc