thebeanogamer / rpms / qemu-kvm

Forked from rpms/qemu-kvm 5 months ago
Clone
8b0a28
From 914d9f9eea5d0a944aa93682b03d3189ad37ec9b Mon Sep 17 00:00:00 2001
8b0a28
From: Eric Auger <eric.auger@redhat.com>
8b0a28
Date: Mon, 20 Dec 2021 15:34:22 +0100
8b0a28
Subject: [PATCH 4/6] hw/arm/virt: Expose the 'RAS' option
8b0a28
8b0a28
RH-Author: Eric Auger <eric.auger@redhat.com>
8b0a28
RH-MergeRequest: 57: hw/arm/virt: Add 9.0 machine type and remove 8.5 one
8b0a28
RH-Commit: [4/6] c8704564d31b23a0f08a6ced946c9a81e2e72c11 (eauger1/centos-qemu-kvm)
8b0a28
RH-Bugzilla: 2031044
8b0a28
RH-Acked-by: Gavin Shan <gshan@redhat.com>
8b0a28
RH-Acked-by: Andrew Jones <drjones@redhat.com>
8b0a28
RH-Acked-by: Miroslav Rezanina <mrezanin@redhat.com>
8b0a28
8b0a28
branch: c9s
8b0a28
Brew: 42213566
8b0a28
Upstream: no
8b0a28
8b0a28
In RHEL9.0 we want to expose the 'RAS' option.
8b0a28
8b0a28
Signed-off-by: Eric Auger <eric.auger@redhat.com>
8b0a28
---
8b0a28
 hw/arm/virt.c | 8 +++++++-
8b0a28
 1 file changed, 7 insertions(+), 1 deletion(-)
8b0a28
8b0a28
diff --git a/hw/arm/virt.c b/hw/arm/virt.c
8b0a28
index c99ca93e75..d433139479 100644
8b0a28
--- a/hw/arm/virt.c
8b0a28
+++ b/hw/arm/virt.c
8b0a28
@@ -2348,7 +2348,6 @@ static void virt_set_acpi(Object *obj, Visitor *v, const char *name,
8b0a28
     visit_type_OnOffAuto(v, name, &vms->acpi, errp);
8b0a28
 }
8b0a28
 
8b0a28
-#if 0 /* Disabled for Red Hat Enterprise Linux */
8b0a28
 static bool virt_get_ras(Object *obj, Error **errp)
8b0a28
 {
8b0a28
     VirtMachineState *vms = VIRT_MACHINE(obj);
8b0a28
@@ -2363,6 +2362,7 @@ static void virt_set_ras(Object *obj, bool value, Error **errp)
8b0a28
     vms->ras = value;
8b0a28
 }
8b0a28
 
8b0a28
+#if 0 /* Disabled for Red Hat Enterprise Linux */
8b0a28
 static bool virt_get_mte(Object *obj, Error **errp)
8b0a28
 {
8b0a28
     VirtMachineState *vms = VIRT_MACHINE(obj);
8b0a28
@@ -3143,6 +3143,12 @@ static void rhel_machine_class_init(ObjectClass *oc, void *data)
8b0a28
                                           "Set on/off to enable/disable "
8b0a28
                                           "bypass_iommu for default root bus");
8b0a28
 
8b0a28
+    object_class_property_add_bool(oc, "ras", virt_get_ras,
8b0a28
+                                   virt_set_ras);
8b0a28
+    object_class_property_set_description(oc, "ras",
8b0a28
+                                          "Set on/off to enable/disable reporting host memory errors "
8b0a28
+                                          "to a KVM guest using ACPI and guest external abort exceptions");
8b0a28
+
8b0a28
     object_class_property_add_bool(oc, "its", virt_get_its,
8b0a28
                                    virt_set_its);
8b0a28
     object_class_property_set_description(oc, "its",
8b0a28
-- 
8b0a28
2.27.0
8b0a28