From 1731ec33c38ccc9b7629182e896737d2e31789c0 Mon Sep 17 00:00:00 2001 From: Philippe Mathieu-Daudé Date: Thu, 16 Jan 2025 15:59:32 +0100 Subject: hw/arm/virt: Remove deprecated virt-2.6 machine MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit This machine has been supported for a period of more than 6 years. According to our versioned machine support policy (see commit ce80c4fa6ff "docs: document special exception for machine type deprecation & removal") it can now be removed. Reviewed-by: Thomas Huth Signed-off-by: Philippe Mathieu-Daudé Reviewed-by: Richard Henderson Signed-off-by: Peter Maydell --- hw/arm/virt.c | 12 ------------ 1 file changed, 12 deletions(-) (limited to 'hw/arm/virt.c') diff --git a/hw/arm/virt.c b/hw/arm/virt.c index 177f3dd22c..17a88aa9b2 100644 --- a/hw/arm/virt.c +++ b/hw/arm/virt.c @@ -3667,15 +3667,3 @@ static void virt_machine_2_7_options(MachineClass *mc) mc->minimum_page_bits = 0; } DEFINE_VIRT_MACHINE(2, 7) - -static void virt_machine_2_6_options(MachineClass *mc) -{ - VirtMachineClass *vmc = VIRT_MACHINE_CLASS(OBJECT_CLASS(mc)); - - virt_machine_2_7_options(mc); - compat_props_add(mc->compat_props, hw_compat_2_6, hw_compat_2_6_len); - vmc->disallow_affinity_adjustment = true; - /* Disable PMU for 2.6 as PMU support was first introduced in 2.7 */ - vmc->no_pmu = true; -} -DEFINE_VIRT_MACHINE(2, 6) -- cgit 1.4.1 From 514712d5277de5237a49a4852f0f90c51696f94c Mon Sep 17 00:00:00 2001 From: Philippe Mathieu-Daudé Date: Thu, 16 Jan 2025 15:59:33 +0100 Subject: hw/arm/virt: Remove VirtMachineClass::no_pmu field MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit The VirtMachineClass::no_pmu field was only used by virt-2.6 machine, which got removed. Remove it and simplify machvirt_init(). Signed-off-by: Philippe Mathieu-Daudé Reviewed-by: Thomas Huth Reviewed-by: Richard Henderson Signed-off-by: Peter Maydell --- hw/arm/virt.c | 4 ---- include/hw/arm/virt.h | 1 - 2 files changed, 5 deletions(-) (limited to 'hw/arm/virt.c') diff --git a/hw/arm/virt.c b/hw/arm/virt.c index 17a88aa9b2..e82b8a4566 100644 --- a/hw/arm/virt.c +++ b/hw/arm/virt.c @@ -2273,10 +2273,6 @@ static void machvirt_init(MachineState *machine) object_property_set_bool(cpuobj, "kvm-steal-time", false, NULL); } - if (vmc->no_pmu && object_property_find(cpuobj, "pmu")) { - object_property_set_bool(cpuobj, "pmu", false, NULL); - } - if (vmc->no_tcg_lpa2 && object_property_find(cpuobj, "lpa2")) { object_property_set_bool(cpuobj, "lpa2", false, NULL); } diff --git a/include/hw/arm/virt.h b/include/hw/arm/virt.h index c8e94e6aed..27c5bb585c 100644 --- a/include/hw/arm/virt.h +++ b/include/hw/arm/virt.h @@ -120,7 +120,6 @@ struct VirtMachineClass { bool disallow_affinity_adjustment; bool no_its; bool no_tcg_its; - bool no_pmu; bool claim_edge_triggered_timers; bool smbios_old_sys_ver; bool no_highmem_compact; -- cgit 1.4.1 From 7f48918a372120a63f18712aa27de5e13b76bbf7 Mon Sep 17 00:00:00 2001 From: Philippe Mathieu-Daudé Date: Thu, 16 Jan 2025 15:59:34 +0100 Subject: hw/arm/virt: Remove VirtMachineClass::disallow_affinity_adjustment MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit The VirtMachineClass::disallow_affinity_adjustment field was only used by virt-2.6 machine, which got removed. Remove it and simplify virt_cpu_mp_affinity(). Signed-off-by: Philippe Mathieu-Daudé Reviewed-by: Richard Henderson Reviewed-by: Thomas Huth [PMM: Remove now-unused variable] Signed-off-by: Peter Maydell --- hw/arm/virt.c | 31 +++++++++++++++---------------- include/hw/arm/virt.h | 1 - 2 files changed, 15 insertions(+), 17 deletions(-) (limited to 'hw/arm/virt.c') diff --git a/hw/arm/virt.c b/hw/arm/virt.c index e82b8a4566..9d82cf78b0 100644 --- a/hw/arm/virt.c +++ b/hw/arm/virt.c @@ -1770,24 +1770,23 @@ void virt_machine_done(Notifier *notifier, void *data) static uint64_t virt_cpu_mp_affinity(VirtMachineState *vms, int idx) { - uint8_t clustersz = ARM_DEFAULT_CPUS_PER_CLUSTER; - VirtMachineClass *vmc = VIRT_MACHINE_GET_CLASS(vms); + uint8_t clustersz; - if (!vmc->disallow_affinity_adjustment) { - /* Adjust MPIDR like 64-bit KVM hosts, which incorporate the - * GIC's target-list limitations. 32-bit KVM hosts currently - * always create clusters of 4 CPUs, but that is expected to - * change when they gain support for gicv3. When KVM is enabled - * it will override the changes we make here, therefore our - * purposes are to make TCG consistent (with 64-bit KVM hosts) - * and to improve SGI efficiency. - */ - if (vms->gic_version == VIRT_GIC_VERSION_2) { - clustersz = GIC_TARGETLIST_BITS; - } else { - clustersz = GICV3_TARGETLIST_BITS; - } + /* + * Adjust MPIDR like 64-bit KVM hosts, which incorporate the + * GIC's target-list limitations. 32-bit KVM hosts currently + * always create clusters of 4 CPUs, but that is expected to + * change when they gain support for gicv3. When KVM is enabled + * it will override the changes we make here, therefore our + * purposes are to make TCG consistent (with 64-bit KVM hosts) + * and to improve SGI efficiency. + */ + if (vms->gic_version == VIRT_GIC_VERSION_2) { + clustersz = GIC_TARGETLIST_BITS; + } else { + clustersz = GICV3_TARGETLIST_BITS; } + return arm_build_mp_affinity(idx, clustersz); } diff --git a/include/hw/arm/virt.h b/include/hw/arm/virt.h index 27c5bb585c..5d3b25509f 100644 --- a/include/hw/arm/virt.h +++ b/include/hw/arm/virt.h @@ -117,7 +117,6 @@ typedef enum VirtGICType { struct VirtMachineClass { MachineClass parent; - bool disallow_affinity_adjustment; bool no_its; bool no_tcg_its; bool claim_edge_triggered_timers; -- cgit 1.4.1 From 390becbf7faa8e7ecb10386ec21d52e1fcb16c96 Mon Sep 17 00:00:00 2001 From: Philippe Mathieu-Daudé Date: Thu, 16 Jan 2025 15:59:35 +0100 Subject: hw/arm/virt: Remove deprecated virt-2.7 machine MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit This machine has been supported for a period of more than 6 years. According to our versioned machine support policy (see commit ce80c4fa6ff "docs: document special exception for machine type deprecation & removal") it can now be removed. Signed-off-by: Philippe Mathieu-Daudé Reviewed-by: Richard Henderson Reviewed-by: Thomas Huth Signed-off-by: Peter Maydell --- hw/arm/virt.c | 13 ------------- 1 file changed, 13 deletions(-) (limited to 'hw/arm/virt.c') diff --git a/hw/arm/virt.c b/hw/arm/virt.c index 9d82cf78b0..a2a213717c 100644 --- a/hw/arm/virt.c +++ b/hw/arm/virt.c @@ -3649,16 +3649,3 @@ static void virt_machine_2_8_options(MachineClass *mc) vmc->claim_edge_triggered_timers = true; } DEFINE_VIRT_MACHINE(2, 8) - -static void virt_machine_2_7_options(MachineClass *mc) -{ - VirtMachineClass *vmc = VIRT_MACHINE_CLASS(OBJECT_CLASS(mc)); - - virt_machine_2_8_options(mc); - compat_props_add(mc->compat_props, hw_compat_2_7, hw_compat_2_7_len); - /* ITS was introduced with 2.8 */ - vmc->no_its = true; - /* Stick with 1K pages for migration compatibility */ - mc->minimum_page_bits = 0; -} -DEFINE_VIRT_MACHINE(2, 7) -- cgit 1.4.1 From 8d23b1df72124d82441f1ca0b484b7a4cabc542e Mon Sep 17 00:00:00 2001 From: Philippe Mathieu-Daudé Date: Thu, 16 Jan 2025 15:59:36 +0100 Subject: hw/arm/virt: Remove VirtMachineClass::no_its field MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit The VirtMachineClass::no_its field was only used by virt-2.7 machine, which got removed. Remove it and simplify virt_instance_init() and virt_acpi_build(). Signed-off-by: Philippe Mathieu-Daudé Reviewed-by: Thomas Huth Reviewed-by: Richard Henderson Signed-off-by: Peter Maydell --- hw/arm/virt-acpi-build.c | 5 ++--- hw/arm/virt.c | 16 ++++++---------- include/hw/arm/virt.h | 1 - 3 files changed, 8 insertions(+), 14 deletions(-) (limited to 'hw/arm/virt.c') diff --git a/hw/arm/virt-acpi-build.c b/hw/arm/virt-acpi-build.c index 3ac8f8e178..1c8b61f9f8 100644 --- a/hw/arm/virt-acpi-build.c +++ b/hw/arm/virt-acpi-build.c @@ -670,7 +670,6 @@ static void build_madt(GArray *table_data, BIOSLinker *linker, VirtMachineState *vms) { int i; - VirtMachineClass *vmc = VIRT_MACHINE_GET_CLASS(vms); const MemMapEntry *memmap = vms->memmap; AcpiTable table = { .sig = "APIC", .rev = 4, .oem_id = vms->oem_id, .oem_table_id = vms->oem_table_id }; @@ -741,7 +740,7 @@ build_madt(GArray *table_data, BIOSLinker *linker, VirtMachineState *vms) memmap[VIRT_HIGH_GIC_REDIST2].size); } - if (its_class_name() && !vmc->no_its) { + if (its_class_name()) { /* * ACPI spec, Revision 6.0 Errata A * (original 6.0 definition has invalid Length) @@ -973,7 +972,7 @@ void virt_acpi_build(VirtMachineState *vms, AcpiBuildTables *tables) vms->oem_table_id); } - if (its_class_name() && !vmc->no_its) { + if (its_class_name()) { acpi_add_table(table_offsets, tables_blob); build_iort(tables_blob, tables->linker, vms); } diff --git a/hw/arm/virt.c b/hw/arm/virt.c index a2a213717c..9c4efcd855 100644 --- a/hw/arm/virt.c +++ b/hw/arm/virt.c @@ -3347,17 +3347,13 @@ static void virt_instance_init(Object *obj) vms->highmem_mmio = true; vms->highmem_redists = true; - if (vmc->no_its) { - vms->its = false; - } else { - /* Default allows ITS instantiation */ - vms->its = true; + /* Default allows ITS instantiation */ + vms->its = true; - if (vmc->no_tcg_its) { - vms->tcg_its = false; - } else { - vms->tcg_its = true; - } + if (vmc->no_tcg_its) { + vms->tcg_its = false; + } else { + vms->tcg_its = true; } /* Default disallows iommu instantiation */ diff --git a/include/hw/arm/virt.h b/include/hw/arm/virt.h index 5d3b25509f..463ac09615 100644 --- a/include/hw/arm/virt.h +++ b/include/hw/arm/virt.h @@ -117,7 +117,6 @@ typedef enum VirtGICType { struct VirtMachineClass { MachineClass parent; - bool no_its; bool no_tcg_its; bool claim_edge_triggered_timers; bool smbios_old_sys_ver; -- cgit 1.4.1 From f54854f98416e2da29cde1b2e4f97efec47af984 Mon Sep 17 00:00:00 2001 From: Philippe Mathieu-Daudé Date: Thu, 16 Jan 2025 15:59:37 +0100 Subject: hw/arm/virt: Remove deprecated virt-2.8 machine MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit This machine has been supported for a period of more than 6 years. According to our versioned machine support policy (see commit ce80c4fa6ff "docs: document special exception for machine type deprecation & removal") it can now be removed. Signed-off-by: Philippe Mathieu-Daudé Reviewed-by: Richard Henderson Reviewed-by: Thomas Huth Signed-off-by: Peter Maydell --- hw/arm/virt.c | 13 ------------- 1 file changed, 13 deletions(-) (limited to 'hw/arm/virt.c') diff --git a/hw/arm/virt.c b/hw/arm/virt.c index 9c4efcd855..4ef3f043a2 100644 --- a/hw/arm/virt.c +++ b/hw/arm/virt.c @@ -3632,16 +3632,3 @@ static void virt_machine_2_9_options(MachineClass *mc) compat_props_add(mc->compat_props, hw_compat_2_9, hw_compat_2_9_len); } DEFINE_VIRT_MACHINE(2, 9) - -static void virt_machine_2_8_options(MachineClass *mc) -{ - VirtMachineClass *vmc = VIRT_MACHINE_CLASS(OBJECT_CLASS(mc)); - - virt_machine_2_9_options(mc); - compat_props_add(mc->compat_props, hw_compat_2_8, hw_compat_2_8_len); - /* For 2.8 and earlier we falsely claimed in the DT that - * our timers were edge-triggered, not level-triggered. - */ - vmc->claim_edge_triggered_timers = true; -} -DEFINE_VIRT_MACHINE(2, 8) -- cgit 1.4.1 From 2d53ca0b228b403c69fe0db0339cb3d1ef0839df Mon Sep 17 00:00:00 2001 From: Philippe Mathieu-Daudé Date: Thu, 16 Jan 2025 15:59:38 +0100 Subject: hw/arm/virt: Remove VirtMachineClass::claim_edge_triggered_timers field MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit The VirtMachineClass::claim_edge_triggered_timers field was only used by virt-2.8 machine, which got removed. Remove it and simplify fdt_add_timer_nodes() and build_gtdt(). Signed-off-by: Philippe Mathieu-Daudé Reviewed-by: Thomas Huth Reviewed-by: Richard Henderson Signed-off-by: Peter Maydell --- hw/arm/virt-acpi-build.c | 5 +---- hw/arm/virt.c | 5 ----- include/hw/arm/virt.h | 1 - 3 files changed, 1 insertion(+), 10 deletions(-) (limited to 'hw/arm/virt.c') diff --git a/hw/arm/virt-acpi-build.c b/hw/arm/virt-acpi-build.c index 1c8b61f9f8..7e8e0f0298 100644 --- a/hw/arm/virt-acpi-build.c +++ b/hw/arm/virt-acpi-build.c @@ -537,15 +537,12 @@ build_srat(GArray *table_data, BIOSLinker *linker, VirtMachineState *vms) static void build_gtdt(GArray *table_data, BIOSLinker *linker, VirtMachineState *vms) { - VirtMachineClass *vmc = VIRT_MACHINE_GET_CLASS(vms); /* * Table 5-117 Flag Definitions * set only "Timer interrupt Mode" and assume "Timer Interrupt * polarity" bit as '0: Interrupt is Active high' */ - uint32_t irqflags = vmc->claim_edge_triggered_timers ? - 1 : /* Interrupt is Edge triggered */ - 0; /* Interrupt is Level triggered */ + const uint32_t irqflags = 0; /* Interrupt is Level triggered */ AcpiTable table = { .sig = "GTDT", .rev = 3, .oem_id = vms->oem_id, .oem_table_id = vms->oem_table_id }; diff --git a/hw/arm/virt.c b/hw/arm/virt.c index 4ef3f043a2..13cbd2275e 100644 --- a/hw/arm/virt.c +++ b/hw/arm/virt.c @@ -370,14 +370,9 @@ static void fdt_add_timer_nodes(const VirtMachineState *vms) * the correct information. */ ARMCPU *armcpu; - VirtMachineClass *vmc = VIRT_MACHINE_GET_CLASS(vms); uint32_t irqflags = GIC_FDT_IRQ_FLAGS_LEVEL_HI; MachineState *ms = MACHINE(vms); - if (vmc->claim_edge_triggered_timers) { - irqflags = GIC_FDT_IRQ_FLAGS_EDGE_LO_HI; - } - if (vms->gic_version == VIRT_GIC_VERSION_2) { irqflags = deposit32(irqflags, GIC_FDT_IRQ_PPI_CPU_START, GIC_FDT_IRQ_PPI_CPU_WIDTH, diff --git a/include/hw/arm/virt.h b/include/hw/arm/virt.h index 463ac09615..9c531e28d0 100644 --- a/include/hw/arm/virt.h +++ b/include/hw/arm/virt.h @@ -118,7 +118,6 @@ typedef enum VirtGICType { struct VirtMachineClass { MachineClass parent; bool no_tcg_its; - bool claim_edge_triggered_timers; bool smbios_old_sys_ver; bool no_highmem_compact; bool no_highmem_ecam; -- cgit 1.4.1 From 684dd748e0d4b14ddcedddcac5982bc36bedeb69 Mon Sep 17 00:00:00 2001 From: Philippe Mathieu-Daudé Date: Thu, 16 Jan 2025 15:59:39 +0100 Subject: hw/arm/virt: Remove deprecated virt-2.9 machine MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit This machine has been supported for a period of more than 6 years. According to our versioned machine support policy (see commit ce80c4fa6ff "docs: document special exception for machine type deprecation & removal") it can now be removed. Signed-off-by: Philippe Mathieu-Daudé Reviewed-by: Richard Henderson Reviewed-by: Thomas Huth Signed-off-by: Peter Maydell --- hw/arm/virt.c | 7 ------- 1 file changed, 7 deletions(-) (limited to 'hw/arm/virt.c') diff --git a/hw/arm/virt.c b/hw/arm/virt.c index 13cbd2275e..1c84297fab 100644 --- a/hw/arm/virt.c +++ b/hw/arm/virt.c @@ -3620,10 +3620,3 @@ static void virt_machine_2_10_options(MachineClass *mc) mc->ignore_memory_transaction_failures = true; } DEFINE_VIRT_MACHINE(2, 10) - -static void virt_machine_2_9_options(MachineClass *mc) -{ - virt_machine_2_10_options(mc); - compat_props_add(mc->compat_props, hw_compat_2_9, hw_compat_2_9_len); -} -DEFINE_VIRT_MACHINE(2, 9) -- cgit 1.4.1 From 21119f57cbd161899542f00cf6bb5087dea3c4e6 Mon Sep 17 00:00:00 2001 From: Philippe Mathieu-Daudé Date: Thu, 16 Jan 2025 15:59:40 +0100 Subject: hw/arm/virt: Remove deprecated virt-2.10 machine MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit This machine has been supported for a period of more than 6 years. According to our versioned machine support policy (see commit ce80c4fa6ff "docs: document special exception for machine type deprecation & removal") it can now be removed. Signed-off-by: Philippe Mathieu-Daudé Reviewed-by: Richard Henderson Reviewed-by: Thomas Huth Signed-off-by: Peter Maydell --- hw/arm/virt.c | 9 --------- 1 file changed, 9 deletions(-) (limited to 'hw/arm/virt.c') diff --git a/hw/arm/virt.c b/hw/arm/virt.c index 1c84297fab..6e10b2b085 100644 --- a/hw/arm/virt.c +++ b/hw/arm/virt.c @@ -3611,12 +3611,3 @@ static void virt_machine_2_11_options(MachineClass *mc) vmc->smbios_old_sys_ver = true; } DEFINE_VIRT_MACHINE(2, 11) - -static void virt_machine_2_10_options(MachineClass *mc) -{ - virt_machine_2_11_options(mc); - compat_props_add(mc->compat_props, hw_compat_2_10, hw_compat_2_10_len); - /* before 2.11 we never faulted accesses to bad addresses */ - mc->ignore_memory_transaction_failures = true; -} -DEFINE_VIRT_MACHINE(2, 10) -- cgit 1.4.1 From ea461b203833d37500ba87eb2b8c2129978dd631 Mon Sep 17 00:00:00 2001 From: Philippe Mathieu-Daudé Date: Thu, 16 Jan 2025 15:59:41 +0100 Subject: hw/arm/virt: Remove deprecated virt-2.11 machine MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit This machine has been supported for a period of more than 6 years. According to our versioned machine support policy (see commit ce80c4fa6ff "docs: document special exception for machine type deprecation & removal") it can now be removed. Signed-off-by: Philippe Mathieu-Daudé Reviewed-by: Richard Henderson Reviewed-by: Thomas Huth Signed-off-by: Peter Maydell --- hw/arm/virt.c | 10 ---------- 1 file changed, 10 deletions(-) (limited to 'hw/arm/virt.c') diff --git a/hw/arm/virt.c b/hw/arm/virt.c index 6e10b2b085..4b21f3226f 100644 --- a/hw/arm/virt.c +++ b/hw/arm/virt.c @@ -3601,13 +3601,3 @@ static void virt_machine_2_12_options(MachineClass *mc) mc->max_cpus = 255; } DEFINE_VIRT_MACHINE(2, 12) - -static void virt_machine_2_11_options(MachineClass *mc) -{ - VirtMachineClass *vmc = VIRT_MACHINE_CLASS(OBJECT_CLASS(mc)); - - virt_machine_2_12_options(mc); - compat_props_add(mc->compat_props, hw_compat_2_11, hw_compat_2_11_len); - vmc->smbios_old_sys_ver = true; -} -DEFINE_VIRT_MACHINE(2, 11) -- cgit 1.4.1 From 50e5b00067a7cf9a4770ed826b95a3add1c344a4 Mon Sep 17 00:00:00 2001 From: Philippe Mathieu-Daudé Date: Thu, 16 Jan 2025 15:59:42 +0100 Subject: hw/arm/virt: Remove VirtMachineClass::smbios_old_sys_ver field MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit The VirtMachineClass::smbios_old_sys_ver field was only used by virt-2.11 machine, which got removed. Remove it and simplify virt_build_smbios(). Signed-off-by: Philippe Mathieu-Daudé Reviewed-by: Thomas Huth Reviewed-by: Richard Henderson Signed-off-by: Peter Maydell --- hw/arm/virt.c | 4 +--- include/hw/arm/virt.h | 1 - 2 files changed, 1 insertion(+), 4 deletions(-) (limited to 'hw/arm/virt.c') diff --git a/hw/arm/virt.c b/hw/arm/virt.c index 4b21f3226f..3488bc4fb9 100644 --- a/hw/arm/virt.c +++ b/hw/arm/virt.c @@ -1699,7 +1699,6 @@ static void virt_build_smbios(VirtMachineState *vms) { MachineClass *mc = MACHINE_GET_CLASS(vms); MachineState *ms = MACHINE(vms); - VirtMachineClass *vmc = VIRT_MACHINE_GET_CLASS(vms); uint8_t *smbios_tables, *smbios_anchor; size_t smbios_tables_len, smbios_anchor_len; struct smbios_phys_mem_area mem_array; @@ -1709,8 +1708,7 @@ static void virt_build_smbios(VirtMachineState *vms) product = "KVM Virtual Machine"; } - smbios_set_defaults("QEMU", product, - vmc->smbios_old_sys_ver ? "1.0" : mc->name); + smbios_set_defaults("QEMU", product, mc->name); /* build the array of physical mem area from base_memmap */ mem_array.address = vms->memmap[VIRT_MEM].base; diff --git a/include/hw/arm/virt.h b/include/hw/arm/virt.h index 9c531e28d0..b2cc012a40 100644 --- a/include/hw/arm/virt.h +++ b/include/hw/arm/virt.h @@ -118,7 +118,6 @@ typedef enum VirtGICType { struct VirtMachineClass { MachineClass parent; bool no_tcg_its; - bool smbios_old_sys_ver; bool no_highmem_compact; bool no_highmem_ecam; bool no_ged; /* Machines < 4.2 have no support for ACPI GED device */ -- cgit 1.4.1 From c51af4e8fb024e98a794e3fc919117d0538b02c9 Mon Sep 17 00:00:00 2001 From: Philippe Mathieu-Daudé Date: Thu, 16 Jan 2025 15:59:43 +0100 Subject: hw/arm/virt: Remove deprecated virt-2.12 machine MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit This machine has been supported for a period of more than 6 years. According to our versioned machine support policy (see commit ce80c4fa6ff "docs: document special exception for machine type deprecation & removal") it can now be removed. Signed-off-by: Philippe Mathieu-Daudé Reviewed-by: Richard Henderson Reviewed-by: Thomas Huth Signed-off-by: Peter Maydell --- hw/arm/virt.c | 11 ----------- 1 file changed, 11 deletions(-) (limited to 'hw/arm/virt.c') diff --git a/hw/arm/virt.c b/hw/arm/virt.c index 3488bc4fb9..d047983c80 100644 --- a/hw/arm/virt.c +++ b/hw/arm/virt.c @@ -3588,14 +3588,3 @@ static void virt_machine_3_0_options(MachineClass *mc) compat_props_add(mc->compat_props, hw_compat_3_0, hw_compat_3_0_len); } DEFINE_VIRT_MACHINE(3, 0) - -static void virt_machine_2_12_options(MachineClass *mc) -{ - VirtMachineClass *vmc = VIRT_MACHINE_CLASS(OBJECT_CLASS(mc)); - - virt_machine_3_0_options(mc); - compat_props_add(mc->compat_props, hw_compat_2_12, hw_compat_2_12_len); - vmc->no_highmem_ecam = true; - mc->max_cpus = 255; -} -DEFINE_VIRT_MACHINE(2, 12) -- cgit 1.4.1 From 358a1bc71359f03bfb64154ed3238f7c571e7872 Mon Sep 17 00:00:00 2001 From: Philippe Mathieu-Daudé Date: Thu, 16 Jan 2025 15:59:44 +0100 Subject: hw/arm/virt: Remove VirtMachineClass::no_highmem_ecam field MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit The VirtMachineClass::no_highmem_ecam field was only used by virt-2.12 machine, which got removed. Remove it and simplify virt_instance_init(). Signed-off-by: Philippe Mathieu-Daudé Reviewed-by: Thomas Huth Reviewed-by: Richard Henderson Signed-off-by: Peter Maydell --- hw/arm/virt.c | 2 +- include/hw/arm/virt.h | 1 - 2 files changed, 1 insertion(+), 2 deletions(-) (limited to 'hw/arm/virt.c') diff --git a/hw/arm/virt.c b/hw/arm/virt.c index d047983c80..bd1a68673a 100644 --- a/hw/arm/virt.c +++ b/hw/arm/virt.c @@ -3336,7 +3336,7 @@ static void virt_instance_init(Object *obj) vms->highmem_compact = !vmc->no_highmem_compact; vms->gic_version = VIRT_GIC_VERSION_NOSEL; - vms->highmem_ecam = !vmc->no_highmem_ecam; + vms->highmem_ecam = true; vms->highmem_mmio = true; vms->highmem_redists = true; diff --git a/include/hw/arm/virt.h b/include/hw/arm/virt.h index b2cc012a40..9a1b0f53d2 100644 --- a/include/hw/arm/virt.h +++ b/include/hw/arm/virt.h @@ -119,7 +119,6 @@ struct VirtMachineClass { MachineClass parent; bool no_tcg_its; bool no_highmem_compact; - bool no_highmem_ecam; bool no_ged; /* Machines < 4.2 have no support for ACPI GED device */ bool kvm_no_adjvtime; bool no_kvm_steal_time; -- cgit 1.4.1 From ecb0cfb8a2b09fb0352b7adb83f18888be47a1cf Mon Sep 17 00:00:00 2001 From: Philippe Mathieu-Daudé Date: Tue, 29 Apr 2025 17:39:04 +0200 Subject: hw/arm/virt: Update comment about Multiprocessor Affinity Register MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Support on ARMv7 has been dropped in commit 82bf7ae84ce ("target/arm: Remove KVM support for 32-bit Arm hosts"). Update the comment in virt_cpu_mp_affinity() to avoid mentioning it. Suggested-by: Andrew Jones Signed-off-by: Philippe Mathieu-Daudé Reviewed-by: Richard Henderson Message-id: 20250429153907.31866-2-philmd@linaro.org Signed-off-by: Peter Maydell --- hw/arm/virt.c | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) (limited to 'hw/arm/virt.c') diff --git a/hw/arm/virt.c b/hw/arm/virt.c index bd1a68673a..03fef07c9d 100644 --- a/hw/arm/virt.c +++ b/hw/arm/virt.c @@ -1766,12 +1766,7 @@ static uint64_t virt_cpu_mp_affinity(VirtMachineState *vms, int idx) uint8_t clustersz; /* - * Adjust MPIDR like 64-bit KVM hosts, which incorporate the - * GIC's target-list limitations. 32-bit KVM hosts currently - * always create clusters of 4 CPUs, but that is expected to - * change when they gain support for gicv3. When KVM is enabled - * it will override the changes we make here, therefore our - * purposes are to make TCG consistent (with 64-bit KVM hosts) + * Adjust MPIDR to make TCG consistent (with 64-bit KVM hosts) * and to improve SGI efficiency. */ if (vms->gic_version == VIRT_GIC_VERSION_2) { -- cgit 1.4.1 From bac2532735d485dc3da38ece44300ad0abf5b51c Mon Sep 17 00:00:00 2001 From: Philippe Mathieu-Daudé Date: Tue, 29 Apr 2025 17:39:05 +0200 Subject: hw/arm/virt: Remove deprecated virt-3.0 machine MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit This machine has been supported for a period of more than 6 years. According to our versioned machine support policy (see commit ce80c4fa6ff "docs: document special exception for machine type deprecation & removal") it can now be removed. Signed-off-by: Philippe Mathieu-Daudé Reviewed-by: Richard Henderson Message-id: 20250429153907.31866-3-philmd@linaro.org Signed-off-by: Peter Maydell --- hw/arm/virt.c | 7 ------- 1 file changed, 7 deletions(-) (limited to 'hw/arm/virt.c') diff --git a/hw/arm/virt.c b/hw/arm/virt.c index 03fef07c9d..1e4841f036 100644 --- a/hw/arm/virt.c +++ b/hw/arm/virt.c @@ -3576,10 +3576,3 @@ static void virt_machine_3_1_options(MachineClass *mc) compat_props_add(mc->compat_props, hw_compat_3_1, hw_compat_3_1_len); } DEFINE_VIRT_MACHINE(3, 1) - -static void virt_machine_3_0_options(MachineClass *mc) -{ - virt_machine_3_1_options(mc); - compat_props_add(mc->compat_props, hw_compat_3_0, hw_compat_3_0_len); -} -DEFINE_VIRT_MACHINE(3, 0) -- cgit 1.4.1 From c4aca607c199a3706ef77e123afed377fb913b4f Mon Sep 17 00:00:00 2001 From: Philippe Mathieu-Daudé Date: Tue, 29 Apr 2025 17:39:06 +0200 Subject: hw/arm/virt: Remove deprecated virt-3.1 machine MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit This machine has been supported for a period of more than 6 years. According to our versioned machine support policy (see commit ce80c4fa6ff "docs: document special exception for machine type deprecation & removal") it can now be removed. Signed-off-by: Philippe Mathieu-Daudé Reviewed-by: Richard Henderson Message-id: 20250429153907.31866-4-philmd@linaro.org Signed-off-by: Peter Maydell --- hw/arm/virt.c | 7 ------- 1 file changed, 7 deletions(-) (limited to 'hw/arm/virt.c') diff --git a/hw/arm/virt.c b/hw/arm/virt.c index 1e4841f036..61fd855768 100644 --- a/hw/arm/virt.c +++ b/hw/arm/virt.c @@ -3569,10 +3569,3 @@ static void virt_machine_4_0_options(MachineClass *mc) compat_props_add(mc->compat_props, hw_compat_4_0, hw_compat_4_0_len); } DEFINE_VIRT_MACHINE(4, 0) - -static void virt_machine_3_1_options(MachineClass *mc) -{ - virt_machine_4_0_options(mc); - compat_props_add(mc->compat_props, hw_compat_3_1, hw_compat_3_1_len); -} -DEFINE_VIRT_MACHINE(3, 1) -- cgit 1.4.1 From 607e1208b53ac713a76d158f4abc4cd2e8870051 Mon Sep 17 00:00:00 2001 From: Philippe Mathieu-Daudé Date: Tue, 29 Apr 2025 17:39:07 +0200 Subject: hw/arm/virt: Remove deprecated virt-4.0 machine MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit This machine has been supported for a period of more than 6 years. According to our versioned machine support policy (see commit ce80c4fa6ff "docs: document special exception for machine type deprecation & removal") it can now be removed. Signed-off-by: Philippe Mathieu-Daudé Reviewed-by: Richard Henderson Message-id: 20250429153907.31866-5-philmd@linaro.org Signed-off-by: Peter Maydell --- hw/arm/virt.c | 7 ------- 1 file changed, 7 deletions(-) (limited to 'hw/arm/virt.c') diff --git a/hw/arm/virt.c b/hw/arm/virt.c index 61fd855768..9a6cd085a3 100644 --- a/hw/arm/virt.c +++ b/hw/arm/virt.c @@ -3562,10 +3562,3 @@ static void virt_machine_4_1_options(MachineClass *mc) mc->auto_enable_numa_with_memhp = false; } DEFINE_VIRT_MACHINE(4, 1) - -static void virt_machine_4_0_options(MachineClass *mc) -{ - virt_machine_4_1_options(mc); - compat_props_add(mc->compat_props, hw_compat_4_0, hw_compat_4_0_len); -} -DEFINE_VIRT_MACHINE(4, 0) -- cgit 1.4.1