Blame SOURCES/0069-v2v-change-QXL-ResourceType-in-OVirt-flavour-RHBZ-15.patch

97ae69
From 21e2f8ea59a87da9daee239cea26873b51ad2f79 Mon Sep 17 00:00:00 2001
97ae69
From: Pino Toscano <ptoscano@redhat.com>
97ae69
Date: Fri, 13 Jul 2018 13:24:07 +0200
97ae69
Subject: [PATCH] v2v: change QXL ResourceType in OVirt flavour (RHBZ#1598715)
97ae69
97ae69
Due to a conflict with the IDs of the OVF standard, and the existing
97ae69
implementation in ovirt-engine, the ID of QXL devices changed to a
97ae69
different value.
97ae69
97ae69
As a consequence, change the ResourceType of QXL devices, but only in
97ae69
OVirt flavour to avoid breaking vdsm mode.
97ae69
97ae69
See: https://bugzilla.redhat.com/show_bug.cgi?id=1598715#c5
97ae69
(cherry picked from commit aa9e18f6d1fd503822dfd2124b92a2c67704c4c1)
97ae69
---
97ae69
 v2v/create_ovf.ml | 6 +++++-
97ae69
 1 file changed, 5 insertions(+), 1 deletion(-)
97ae69
97ae69
diff --git a/v2v/create_ovf.ml b/v2v/create_ovf.ml
97ae69
index 9e0c772fd..5db239d66 100644
97ae69
--- a/v2v/create_ovf.ml
97ae69
+++ b/v2v/create_ovf.ml
97ae69
@@ -643,10 +643,14 @@ let rec create_ovf source targets guestcaps inspect
97ae69
          * See RHBZ#1213701 and RHBZ#1211231 for the reasoning
97ae69
          * behind that.
97ae69
          *)
97ae69
+        let qxl_resourcetype =
97ae69
+          match ovf_flavour with
97ae69
+          | OVirt -> 32768 (* RHBZ#1598715 *)
97ae69
+          | RHVExportStorageDomain -> 20 in
97ae69
         e "Item" [] [
97ae69
           e "rasd:Caption" [] [PCData "Graphical Controller"];
97ae69
           e "rasd:InstanceId" [] [PCData (uuidgen ())];
97ae69
-          e "rasd:ResourceType" [] [PCData "20"];
97ae69
+          e "rasd:ResourceType" [] [PCData (string_of_int qxl_resourcetype)];
97ae69
           e "Type" [] [PCData "video"];
97ae69
           e "rasd:VirtualQuantity" [] [PCData "1"];
97ae69
           e "rasd:Device" [] [PCData "qxl"];
97ae69
-- 
97ae69
2.17.1
97ae69