|
|
8be556 |
From 1c88ffac9ddc09b6d81111071e8be722ac43665f Mon Sep 17 00:00:00 2001
|
|
|
8be556 |
From: "Dr. David Alan Gilbert" <dgilbert@redhat.com>
|
|
|
8be556 |
Date: Fri, 10 Apr 2015 16:43:19 +0200
|
|
|
8be556 |
Subject: Add pc-q35-rhel7.2.0 machine type
|
|
|
8be556 |
|
|
|
8be556 |
Message-id: <1428684199-19029-3-git-send-email-dgilbert@redhat.com>
|
|
|
8be556 |
Patchwork-id: 64795
|
|
|
8be556 |
O-Subject: [RHEL-7.2 qemu-kvm-rhev PATCH 2/2] Add pc-q35-rhel7.2.0 machine type
|
|
|
8be556 |
Bugzilla: 1210050
|
|
|
8be556 |
RH-Acked-by: Bandan Das <bsd@redhat.com>
|
|
|
8be556 |
RH-Acked-by: John Snow <jsnow@redhat.com>
|
|
|
8be556 |
RH-Acked-by: Paolo Bonzini <pbonzini@redhat.com>
|
|
|
8be556 |
|
|
|
8be556 |
From: "Dr. David Alan Gilbert" <dgilbert@redhat.com>
|
|
|
8be556 |
|
|
|
8be556 |
Signed-off-by: Dr. David Alan Gilbert <dgilbert@redhat.com>
|
|
|
8be556 |
Signed-off-by: Miroslav Rezanina <mrezanin@redhat.com>
|
|
|
8be556 |
|
|
|
8be556 |
diff --git a/hw/i386/pc_q35.c b/hw/i386/pc_q35.c
|
|
|
8be556 |
index f2f99d9..44d5138 100644
|
|
|
8be556 |
--- a/hw/i386/pc_q35.c
|
|
|
8be556 |
+++ b/hw/i386/pc_q35.c
|
|
|
8be556 |
@@ -523,7 +523,7 @@ machine_init(pc_q35_machine_init);
|
|
|
8be556 |
|
|
|
8be556 |
/* Red Hat Enterprise Linux machine types */
|
|
|
8be556 |
|
|
|
8be556 |
-static void pc_q35_compat_rhel710(MachineState *machine)
|
|
|
8be556 |
+static void pc_q35_compat_rhel720(MachineState *machine)
|
|
|
8be556 |
{
|
|
|
8be556 |
/* KVM can't expose RDTSCP on AMD CPUs, so there's no point in enabling it
|
|
|
8be556 |
* on AMD CPU models.
|
|
|
8be556 |
@@ -540,6 +540,63 @@ static void pc_q35_compat_rhel710(MachineState *machine)
|
|
|
8be556 |
CPUID_EXT2_RDTSCP);
|
|
|
8be556 |
}
|
|
|
8be556 |
|
|
|
8be556 |
+static void pc_q35_init_rhel720(MachineState *machine)
|
|
|
8be556 |
+{
|
|
|
8be556 |
+ pc_q35_compat_rhel720(machine);
|
|
|
8be556 |
+ pc_q35_init(machine);
|
|
|
8be556 |
+}
|
|
|
8be556 |
+
|
|
|
8be556 |
+static QEMUMachine pc_q35_machine_rhel720 = {
|
|
|
8be556 |
+ PC_DEFAULT_MACHINE_OPTIONS,
|
|
|
8be556 |
+ .family = "pc_q35_Z",
|
|
|
8be556 |
+ .name = "pc-q35-rhel7.2.0",
|
|
|
8be556 |
+ .alias = "q35",
|
|
|
8be556 |
+ .desc = "RHEL-7.2.0 PC (Q35 + ICH9, 2009)",
|
|
|
8be556 |
+ .init = pc_q35_init_rhel720,
|
|
|
8be556 |
+ .default_machine_opts = "firmware=bios-256k.bin",
|
|
|
8be556 |
+ .default_display = "std",
|
|
|
8be556 |
+ .compat_props = (GlobalProperty[]) {
|
|
|
8be556 |
+ { /* end of list */ }
|
|
|
8be556 |
+ },
|
|
|
8be556 |
+};
|
|
|
8be556 |
+
|
|
|
8be556 |
+static void pc_q35_compat_rhel710(MachineState *machine)
|
|
|
8be556 |
+{
|
|
|
8be556 |
+ PCMachineState *pcms = PC_MACHINE(machine);
|
|
|
8be556 |
+
|
|
|
8be556 |
+ /* 7.1.0 is based on 2.1.2, 7.2.0 is based on 2.3 */
|
|
|
8be556 |
+ pc_q35_compat_rhel720(machine);
|
|
|
8be556 |
+
|
|
|
8be556 |
+ /* From pc_compat_2_2 */
|
|
|
8be556 |
+ rsdp_in_ram = false;
|
|
|
8be556 |
+ x86_cpu_compat_set_features("kvm64", FEAT_1_EDX, 0, CPUID_VME);
|
|
|
8be556 |
+ x86_cpu_compat_set_features("kvm32", FEAT_1_EDX, 0, CPUID_VME);
|
|
|
8be556 |
+ x86_cpu_compat_set_features("Conroe", FEAT_1_EDX, 0, CPUID_VME);
|
|
|
8be556 |
+ x86_cpu_compat_set_features("Penryn", FEAT_1_EDX, 0, CPUID_VME);
|
|
|
8be556 |
+ x86_cpu_compat_set_features("Nehalem", FEAT_1_EDX, 0, CPUID_VME);
|
|
|
8be556 |
+ x86_cpu_compat_set_features("Westmere", FEAT_1_EDX, 0, CPUID_VME);
|
|
|
8be556 |
+ x86_cpu_compat_set_features("SandyBridge", FEAT_1_EDX, 0, CPUID_VME);
|
|
|
8be556 |
+ x86_cpu_compat_set_features("Haswell", FEAT_1_EDX, 0, CPUID_VME);
|
|
|
8be556 |
+ x86_cpu_compat_set_features("Broadwell", FEAT_1_EDX, 0, CPUID_VME);
|
|
|
8be556 |
+ x86_cpu_compat_set_features("Opteron_G1", FEAT_1_EDX, 0, CPUID_VME);
|
|
|
8be556 |
+ x86_cpu_compat_set_features("Opteron_G2", FEAT_1_EDX, 0, CPUID_VME);
|
|
|
8be556 |
+ x86_cpu_compat_set_features("Opteron_G3", FEAT_1_EDX, 0, CPUID_VME);
|
|
|
8be556 |
+ x86_cpu_compat_set_features("Opteron_G4", FEAT_1_EDX, 0, CPUID_VME);
|
|
|
8be556 |
+ x86_cpu_compat_set_features("Opteron_G5", FEAT_1_EDX, 0, CPUID_VME);
|
|
|
8be556 |
+ x86_cpu_compat_set_features("Haswell", FEAT_1_ECX, 0, CPUID_EXT_F16C);
|
|
|
8be556 |
+ x86_cpu_compat_set_features("Haswell", FEAT_1_ECX, 0, CPUID_EXT_RDRAND);
|
|
|
8be556 |
+ x86_cpu_compat_set_features("Broadwell", FEAT_1_ECX, 0, CPUID_EXT_F16C);
|
|
|
8be556 |
+ x86_cpu_compat_set_features("Broadwell", FEAT_1_ECX, 0, CPUID_EXT_RDRAND);
|
|
|
8be556 |
+ machine->suppress_vmdesc = true;
|
|
|
8be556 |
+
|
|
|
8be556 |
+ /* From pc_compat_2_1 */
|
|
|
8be556 |
+ pcms->enforce_aligned_dimm = false;
|
|
|
8be556 |
+ smbios_uuid_encoded = false;
|
|
|
8be556 |
+ x86_cpu_compat_set_features("coreduo", FEAT_1_ECX, CPUID_EXT_VMX, 0);
|
|
|
8be556 |
+ x86_cpu_compat_set_features("core2duo", FEAT_1_ECX, CPUID_EXT_VMX, 0);
|
|
|
8be556 |
+ x86_cpu_compat_kvm_no_autodisable(FEAT_8000_0001_ECX, CPUID_EXT3_SVM);
|
|
|
8be556 |
+}
|
|
|
8be556 |
+
|
|
|
8be556 |
static void pc_q35_init_rhel710(MachineState *machine)
|
|
|
8be556 |
{
|
|
|
8be556 |
pc_q35_compat_rhel710(machine);
|
|
|
8be556 |
@@ -550,11 +607,11 @@ static QEMUMachine pc_q35_machine_rhel710 = {
|
|
|
8be556 |
PC_DEFAULT_MACHINE_OPTIONS,
|
|
|
8be556 |
.family = "pc_q35_Z",
|
|
|
8be556 |
.name = "pc-q35-rhel7.1.0",
|
|
|
8be556 |
- .alias = "q35",
|
|
|
8be556 |
.desc = "RHEL-7.1.0 PC (Q35 + ICH9, 2009)",
|
|
|
8be556 |
.init = pc_q35_init_rhel710,
|
|
|
8be556 |
.default_machine_opts = "firmware=bios-256k.bin",
|
|
|
8be556 |
.compat_props = (GlobalProperty[]) {
|
|
|
8be556 |
+ HW_COMPAT_RHEL7_1,
|
|
|
8be556 |
{ /* end of list */ }
|
|
|
8be556 |
},
|
|
|
8be556 |
};
|
|
|
8be556 |
@@ -603,6 +660,7 @@ static QEMUMachine pc_q35_machine_rhel700 = {
|
|
|
8be556 |
|
|
|
8be556 |
static void rhel_pc_q35_machine_init(void)
|
|
|
8be556 |
{
|
|
|
8be556 |
+ qemu_register_pc_machine(&pc_q35_machine_rhel720);
|
|
|
8be556 |
qemu_register_pc_machine(&pc_q35_machine_rhel710);
|
|
|
8be556 |
qemu_register_pc_machine(&pc_q35_machine_rhel700);
|
|
|
8be556 |
}
|