qemu-kvm/0030-redhat-define-pseries-rhel8.3.0-machine-type.patch

78 lines
2.3 KiB
Diff
Raw Normal View History

2020-08-12 15:53:34 +00:00
From 311a20fb12a4d0ebed840be194db8117c8eea595 Mon Sep 17 00:00:00 2001
From: Laurent Vivier <lvivier@redhat.com>
Date: Wed, 12 Aug 2020 10:58:04 +0200
Subject: redhat: define pseries-rhel8.3.0 machine type
RH-Author: Laurent Vivier <lvivier@redhat.com>
Message-id: <20200706104117.219174-3-lvivier@redhat.com>
Patchwork-id: 97904
O-Subject: [RHEL-AV-8.3.0 qemu-kvm PATCH v2 2/2] redhat: define pseries-rhel8.3.0 machine type
Bugzilla: 1853265
RH-Acked-by: Thomas Huth <thuth@redhat.com>
Note: rebase to qemu-5.1 introduces
32a354dc6c07 ("numa: forbid '-numa node, mem' for 5.1 and newer machine types")
and so '-numa node, mem' will not be available with pseries-rhel8.3.0
Signed-off-by: Laurent Vivier <lvivier@redhat.com>
Signed-off-by: Miroslav Rezanina <mrezanin@redhat.com>
Signed-off-by: Danilo C. L. de Paula <ddepaula@redhat.com>
---
hw/ppc/spapr.c | 30 ++++++++++++++++++++++++++++--
1 file changed, 28 insertions(+), 2 deletions(-)
diff --git a/hw/ppc/spapr.c b/hw/ppc/spapr.c
index 756c8667c1..ccceb6d39f 100644
--- a/hw/ppc/spapr.c
+++ b/hw/ppc/spapr.c
@@ -4995,16 +4995,42 @@ static void spapr_machine_2_1_class_options(MachineClass *mc)
DEFINE_SPAPR_MACHINE(2_1, "2.1", false);
#endif
+/*
+ * pseries-rhel8.3.0
+ * like pseries-5.1
+ */
+
+static void spapr_machine_rhel830_class_options(MachineClass *mc)
+{
+ /* Defaults for the latest behaviour inherited from the base class */
+}
+
+DEFINE_SPAPR_MACHINE(rhel830, "rhel8.3.0", true);
+
/*
* pseries-rhel8.2.0
+ * like pseries-4.2 + pseries-5.0
+ * except SPAPR_CAP_CCF_ASSIST that has been backported to pseries-rhel8.1.0
*/
static void spapr_machine_rhel820_class_options(MachineClass *mc)
{
- /* Defaults for the latest behaviour inherited from the base class */
+ SpaprMachineClass *smc = SPAPR_MACHINE_CLASS(mc);
+
+ spapr_machine_rhel830_class_options(mc);
+ compat_props_add(mc->compat_props, hw_compat_rhel_8_2,
+ hw_compat_rhel_8_2_len);
+
+ /* from pseries-4.2 */
+ smc->default_caps.caps[SPAPR_CAP_FWNMI] = SPAPR_CAP_OFF;
+ smc->rma_limit = 16 * GiB;
+ mc->nvdimm_supported = false;
+
+ /* from pseries-5.0 */
+ mc->numa_mem_supported = true;
}
-DEFINE_SPAPR_MACHINE(rhel820, "rhel8.2.0", true);
+DEFINE_SPAPR_MACHINE(rhel820, "rhel8.2.0", false);
/*
* pseries-rhel8.1.0
--
2.27.0