hw/i386/pc: Remove deprecated 3.1 machines
v2 cover hw/i386/pc: Remove deprecated 3.1 machines
1 y.o. dust Thomas asked me to rebase & post:
The versioned 'pc' and 'q35' machines up to 3.1 been marked as deprecated two releases ago, and are older than 6 years, so according to our support policy we can remove them.
v2: Remove xenfv-3.1 in patch #1
Philippe Mathieu-Daudé (10):
hw/i386/pc: Remove deprecated pc-q35/pc-i440fx/xenfv 3.1 machines hw/i386/pc: Remove PCMachineClass::pvh_enabled field hw/i386/x86: Remove @pvh_enabled argument in x86_load_linux() hw/core/boards: Remove MachineClass::smbus_no_migration_support field hw/i386/pc: Remove pc_compat_3_1[] array
hw/i386/iommu: Remove IntelIOMMUState::dma_drain field target/i386/cpu: Remove X86CPU::intel_pt_auto_level field hw/core/machine: Remove the hw_compat_3_1[] array hw/pci-bridge/pcie_rp: Remove PCIESlot::disable_acs field hw/tpm: Remove CRBState::ppi_enabled field
hw/tpm/tpm_tis.h | 1 - include/hw/core/boards.h | 4 ---- include/hw/i2c/pm_smbus.h | 7 ------- include/hw/i386/intel_iommu.h | 1 - include/hw/i386/microvm.h | 2 +- include/hw/i386/pc.h | 6 ------ include/hw/i386/x86.h | 3 +-- include/hw/pci/pcie_port.h | 3 --- target/i386/cpu.h | 3 --- hw/acpi/piix4.c | 8 +------- hw/acpi/tpm.c | 4 ---- hw/core/machine.c | 17 ----------------- hw/i2c/pm_smbus.c | 7 ------- hw/i2c/smbus_eeprom.c | 4 +--- hw/i2c/smbus_ich9.c | 10 ++-------- hw/i386/acpi-build.c | 2 +- hw/i386/intel_iommu.c | 11 +---------- hw/i386/microvm.c | 2 +- hw/i386/nitro_enclave.c | 2 +- hw/i386/pc.c | 31 ++----------------------------- hw/i386/pc_piix.c | 25 ------------------------- hw/i386/pc_q35.c | 14 -------------- hw/i386/x86-common.c | 6 ++---- hw/pci-bridge/pcie_root_port.c | 3 +-- hw/tpm/tpm_crb.c | 12 +++--------- hw/tpm/tpm_tis_common.c | 4 +--- hw/tpm/tpm_tis_isa.c | 7 ++----- target/i386/cpu.c | 10 +--------- 28 files changed, 22 insertions(+), 187 deletions(-)
Signature · 1 line
2.53.0
PATCH v2 1/10 hw/i386/pc: Remove deprecated pc-q35/pc-i440fx/xenfv 3.1 machines
These machines 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") they can now be removed.
Message-Id: <[email protected]>
--- hw/i386/pc_piix.c | 25 ------------------------- hw/i386/pc_q35.c | 14 -------------- 2 files changed, 39 deletions(-)
hw/i386/pc_piix.c +0 -25
@@ -655,19 +655,6 @@ static void pc_i440fx_machine_4_0_options(MachineClass *m)DEFINE_I440FX_MACHINE (4 ,0 ); -static void pc_i440fx_machine_3_1_options (MachineClass *m) -{ -PCMachineClass *pcmc =PC_MACHINE_CLASS (m); - -pc_i440fx_machine_4_0_options (m); - m->smbus_no_migration_support = true; - pcmc->pvh_enabled = false; -compat_props_add (m->compat_props, hw_compat_3_1, hw_compat_3_1_len); -compat_props_add (m->compat_props, pc_compat_3_1, pc_compat_3_1_len); -} - -DEFINE_I440FX_MACHINE (3 ,1 ); -#ifdef CONFIG_XEN static void xenfv_machine_4_2_options (MachineClass *m) {
@@ -679,16 +666,4 @@ static void xenfv_machine_4_2_options(MachineClass *m)DEFINE_PC_MACHINE (xenfv_4_2,"xenfv-4.2" , pc_xen_hvm_init, xenfv_machine_4_2_options); - -static void xenfv_machine_3_1_options (MachineClass *m) -{ -pc_i440fx_machine_3_1_options (m); - m->desc ="Xen Fully-virtualized PC" ; - m->alias ="xenfv" ; - m->max_cpus =HVM_MAX_VCPUS ; - m->default_machine_opts ="accel=xen,suppress-vmdesc=on" ; -} - -DEFINE_PC_MACHINE (xenfv,"xenfv-3.1" , pc_xen_hvm_init, - xenfv_machine_3_1_options);#endif
hw/i386/pc_q35.c +0 -14
@@ -600,17 +600,3 @@ static void pc_q35_machine_4_0_options(MachineClass *m) }DEFINE_Q35_MACHINE (4 ,0 ); - -static void pc_q35_machine_3_1_options (MachineClass *m) -{ -PCMachineClass *pcmc =PC_MACHINE_CLASS (m); - -pc_q35_machine_4_0_options (m); - m->default_kernel_irqchip_split = false; - m->smbus_no_migration_support = true; - pcmc->pvh_enabled = false; -compat_props_add (m->compat_props, hw_compat_3_1, hw_compat_3_1_len); -compat_props_add (m->compat_props, pc_compat_3_1, pc_compat_3_1_len); -} - -DEFINE_Q35_MACHINE (3 ,1 );
Signature · 1 line
2.53.0
Re: [PATCH v2 01/10] hw/i386/pc: Remove deprecated pc-q35/pc-i440fx/xenfv 3.1 machines
Quoted 11 lines · Philippe Mathieu-Daudé
Date: Mon, 9 Mar 2026 15:50:03 +0100
From: Philippe Mathieu-Daudé <[email protected]>
Subject: [PATCH v2 01/10] hw/i386/pc: Remove deprecated
pc-q35/pc-i440fx/xenfv 3.1 machines
X-Mailer: git-send-email 2.53.0These machines 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") they can now be removed.
Quoted 7 lines
Signed-off-by Philippe Mathieu-Daudé <[email protected]>Reviewed-by Thomas Huth <[email protected]>Message-Id: <[email protected]>
--- hw/i386/pc_piix.c | 25 ------------------------- hw/i386/pc_q35.c | 14 -------------- 2 files changed, 39 deletions(-)
PATCH v2 2/10 hw/i386/pc: Remove PCMachineClass::pvh_enabled field
In reply to Philippe Mathieu-DaudéThe PCMachineClass::pvh_enabled boolean was only used by the pc-q35-3.1 and pc-i440fx-3.1 machines, which got removed. Remove it.
Message-Id: <[email protected]>
--- include/hw/i386/pc.h | 3 --- hw/i386/pc.c | 6 ++---- hw/i386/x86-common.c | 3 +-- 3 files changed, 3 insertions(+), 9 deletions(-)
include/hw/i386/pc.h +0 -3
@@ -110,9 +110,6 @@ struct PCMachineClass {bool enforce_amd_1tb_hole;bool isa_bios_alias; -/* use PVH to load kernels that support this feature */ -bool pvh_enabled; -/* create kvmclock device even when KVM PV features are not exposed */ bool kvmclock_create_always;
hw/i386/pc.c +2 -4
@@ -588,7 +588,6 @@ void xen_load_linux(PCMachineState *pcms) {int i;FWCfgState *fw_cfg; -PCMachineClass *pcmc =PC_MACHINE_GET_CLASS (pcms);X86MachineState *x86ms =X86_MACHINE (pcms);assert (MACHINE (pcms)->kernel_filename !=NULL );
@@ -598,7 +597,7 @@ void xen_load_linux(PCMachineState *pcms)fw_cfg_add_i16 (fw_cfg,FW_CFG_NB_CPUS , x86ms->boot_cpus);rom_set_fw (fw_cfg); -x86_load_linux (x86ms, fw_cfg,PC_FW_DATA , pcmc->pvh_enabled); +x86_load_linux (x86ms, fw_cfg,PC_FW_DATA , true);for (i =0 ; i < nb_option_roms; i++) { assert(!strcmp(option_rom[i].name, "linuxboot_dma.bin") || !strcmp(option_rom[i].name, "pvh.bin") ||
@@ -932,7 +931,7 @@ void pc_memory_init(PCMachineState *pcms, }if (linux_boot) { -x86_load_linux (x86ms, fw_cfg,PC_FW_DATA , pcmc->pvh_enabled); +x86_load_linux (x86ms, fw_cfg,PC_FW_DATA , true); }for (i =0 ; i < nb_option_roms; i++) {
@@ -1673,7 +1672,6 @@ static void pc_machine_class_init(ObjectClass *oc, const void *data) pcmc->has_reserved_memory = true; pcmc->enforce_amd_1tb_hole = true; pcmc->isa_bios_alias = true; - pcmc->pvh_enabled = true; pcmc->kvmclock_create_always = true; x86mc->apic_xrupt_override = true;assert (!mc->get_hotplug_handler);
hw/i386/x86-common.c +1 -2
@@ -704,8 +704,7 @@ void x86_load_linux(X86MachineState *x86ms,* saving the PVH entry point used by the x86/HVM direct boot ABI. * If load_elfboot() is successful, populate the fw_cfg info. */ -if (pvh_enabled && -load_elfboot (kernel_filename, kernel_size, +if (load_elfboot (kernel_filename, kernel_size, header, pvh_start_addr, fw_cfg)) {fclose (f);
Signature · 1 line
2.53.0
Re: [PATCH v2 02/10] hw/i386/pc: Remove PCMachineClass::pvh_enabled field
Quoted 10 lines · Philippe Mathieu-Daudé
Date: Mon, 9 Mar 2026 15:50:04 +0100
From: Philippe Mathieu-Daudé <[email protected]>
Subject: [PATCH v2 02/10] hw/i386/pc: RemovePCMachineClass::pvh_enabled
field
X-Mailer: git-send-email 2.53.0The
PCMachineClass::pvh_enabledboolean was only used by the pc-q35-3.1 and pc-i440fx-3.1 machines, which got removed. Remove it.
Quoted 8 lines
Signed-off-by Philippe Mathieu-Daudé <[email protected]>Reviewed-by Thomas Huth <[email protected]>Message-Id: <[email protected]>
--- include/hw/i386/pc.h | 3 --- hw/i386/pc.c | 6 ++---- hw/i386/x86-common.c | 3 +-- 3 files changed, 3 insertions(+), 9 deletions(-)
PATCH v2 3/10 hw/i386/x86: Remove @pvh_enabled argument in x86_load_linux()
In reply to Philippe Mathieu-Daudéx86_load_linux()'s @pvh_enabled is now always %true: remove it.
Message-Id: <[email protected]>
--- include/hw/i386/microvm.h | 2 +- include/hw/i386/x86.h | 3 +-- hw/i386/microvm.c | 2 +- hw/i386/nitro_enclave.c | 2 +- hw/i386/pc.c | 4 ++-- hw/i386/x86-common.c | 3 +-- 6 files changed, 7 insertions(+), 9 deletions(-)
include/hw/i386/microvm.h +1 -1
@@ -79,7 +79,7 @@ struct MicrovmMachineClass { HotplugHandler *(*orig_hotplug_handler)(MachineState *machine, DeviceState *dev);void (*x86_load_linux)(X86MachineState *x86ms,FWCfgState *fw_cfg, -int acpi_data_size,bool pvh_enabled); +int acpi_data_size); };struct MicrovmMachineState {
include/hw/i386/x86.h +1 -2
@@ -129,8 +129,7 @@ void x86_bios_rom_reload(X86MachineState *x86ms);void x86_load_linux (X86MachineState *x86ms,FWCfgState *fw_cfg, -int acpi_data_size, -bool pvh_enabled); +int acpi_data_size);bool x86_machine_is_smm_enabled (const X86MachineState *x86ms);bool x86_machine_is_acpi_enabled (const X86MachineState *x86ms);
hw/i386/microvm.c +1 -1
@@ -330,7 +330,7 @@ static void microvm_memory_init(MicrovmMachineState *mms)rom_set_fw (fw_cfg);if (machine->kernel_filename !=NULL ) { - mmc->x86_load_linux (x86ms, fw_cfg,0 , true); + mmc->x86_load_linux (x86ms, fw_cfg,0 ); }if (mms->option_roms) {
hw/i386/nitro_enclave.c +1 -1
@@ -199,7 +199,7 @@ static void x86_load_eif(X86MachineState *x86ms, FWCfgState *fw_cfg, machine->kernel_cmdline = eif_cmdline; } -x86_load_linux (x86ms, fw_cfg,0 , true); +x86_load_linux (x86ms, fw_cfg,0 );unlink (machine->kernel_filename);unlink (machine->initrd_filename);
hw/i386/pc.c +2 -2
@@ -597,7 +597,7 @@ void xen_load_linux(PCMachineState *pcms)fw_cfg_add_i16 (fw_cfg,FW_CFG_NB_CPUS , x86ms->boot_cpus);rom_set_fw (fw_cfg); -x86_load_linux (x86ms, fw_cfg,PC_FW_DATA , true); +x86_load_linux (x86ms, fw_cfg,PC_FW_DATA );for (i =0 ; i < nb_option_roms; i++) { assert(!strcmp(option_rom[i].name, "linuxboot_dma.bin") || !strcmp(option_rom[i].name, "pvh.bin") ||
@@ -931,7 +931,7 @@ void pc_memory_init(PCMachineState *pcms, }if (linux_boot) { -x86_load_linux (x86ms, fw_cfg,PC_FW_DATA , true); +x86_load_linux (x86ms, fw_cfg,PC_FW_DATA ); }for (i =0 ; i < nb_option_roms; i++) {
hw/i386/x86-common.c +1 -2
@@ -642,8 +642,7 @@ static bool load_elfboot(const char *kernel_filename,void x86_load_linux (X86MachineState *x86ms,FWCfgState *fw_cfg, -int acpi_data_size, -bool pvh_enabled) +int acpi_data_size) {uint16_t protocol;int setup_size, kernel_size, cmdline_size;
Signature · 1 line
2.53.0
Re: [PATCH v2 03/10] hw/i386/x86: Remove @pvh_enabled argument in x86_load_linux()
Quoted 11 lines · Philippe Mathieu-Daudé
Date: Mon, 9 Mar 2026 15:50:05 +0100
From: Philippe Mathieu-Daudé <[email protected]>
Subject: [PATCH v2 03/10] hw/i386/x86: Remove @pvh_enabled argument in
x86_load_linux()
X-Mailer: git-send-email 2.53.0x86_load_linux()'s @pvh_enabled is now always %true: remove it.
Signed-off-by Philippe Mathieu-Daudé <[email protected]>Reviewed-by Thomas Huth <[email protected]>Message-Id: <[email protected]>
Quoted 8 lines
--- include/hw/i386/microvm.h | 2 +- include/hw/i386/x86.h | 3 +-- hw/i386/microvm.c | 2 +- hw/i386/nitro_enclave.c | 2 +- hw/i386/pc.c | 4 ++-- hw/i386/x86-common.c | 3 +-- 6 files changed, 7 insertions(+), 9 deletions(-)
PATCH v2 4/10 hw/core/boards: Remove MachineClass::smbus_no_migration_support field
In reply to Philippe Mathieu-DaudéThe MachineClass::smbus_no_migration_support boolean was only used by the pc-q35-3.1 and pc-i440fx-3.1 machines, which got removed. Remove it, along with pm_smbus_vmstate_needed().
Use the unconditional VMSTATE_BOOL() and VMSTATE_STRUCT() macros.
Message-Id: <[email protected]>
--- include/hw/core/boards.h | 1 - include/hw/i2c/pm_smbus.h | 7 ------- hw/acpi/piix4.c | 8 +------- hw/i2c/pm_smbus.c | 7 ------- hw/i2c/smbus_eeprom.c | 4 +--- hw/i2c/smbus_ich9.c | 10 ++-------- 6 files changed, 4 insertions(+), 33 deletions(-)
include/hw/core/boards.h +0 -1
@@ -314,7 +314,6 @@ struct MachineClass {bool auto_enable_numa_with_memhp;bool auto_enable_numa_with_memdev;bool ignore_boot_device_suffixes; -bool smbus_no_migration_support;bool nvdimm_supported;bool numa_mem_supported;bool auto_enable_numa;
include/hw/i2c/pm_smbus.h +0 -7
@@ -44,13 +44,6 @@ typedef struct PMSMBus {void pm_smbus_init (DeviceState *parent,PMSMBus *smb,bool force_aux_blk); -/* -* For backwards compatibility on migration, older versions don't have -* working migration for pm_smbus, this lets us ignore the migrations -* for older machine versions. -*/ -bool pm_smbus_vmstate_needed (void ); -extern const VMStateDescription pmsmb_vmstate;#endif /* PM_SMBUS_H */
hw/acpi/piix4.c +1 -7
@@ -205,11 +205,6 @@ static const VMStateDescription vmstate_cpuhp_state = { } }; -static bool piix4_vmstate_need_smbus (void *opaque,int version_id) -{ -return pm_smbus_vmstate_needed (); -} -/* * This is a fudge to turn off the acpi_index field, * whose test was always broken on piix4 with 6.2 and older machine types.
@@ -238,8 +233,7 @@ static const VMStateDescription vmstate_acpi = {VMSTATE_UINT16 (ar.pm1.evt.en, PIIX4PMState),VMSTATE_UINT16 (ar.pm1.cnt.cnt, PIIX4PMState),VMSTATE_STRUCT (apm, PIIX4PMState,0 , vmstate_apm, APMState), -VMSTATE_STRUCT_TEST (smb, PIIX4PMState, piix4_vmstate_need_smbus,3 , - pmsmb_vmstate, PMSMBus), +VMSTATE_STRUCT (smb, PIIX4PMState,3 , pmsmb_vmstate, PMSMBus),VMSTATE_TIMER_PTR (ar.tmr.timer, PIIX4PMState),VMSTATE_INT64 (ar.tmr.overflow_time, PIIX4PMState), VMSTATE_STRUCT(ar.gpe, PIIX4PMState, 2, vmstate_gpe, ACPIGPE),
hw/i2c/pm_smbus.c +0 -7
@@ -443,13 +443,6 @@ static const MemoryRegionOps pm_smbus_ops = { .endianness = DEVICE_LITTLE_ENDIAN, }; -bool pm_smbus_vmstate_needed (void ) -{ -MachineClass *mc =MACHINE_GET_CLASS (qdev_get_machine ()); - -return !mc->smbus_no_migration_support; -} -const VMStateDescription pmsmb_vmstate = { .name ="pmsmb" , .version_id =1 ,
hw/i2c/smbus_eeprom.c +1 -3
@@ -88,11 +88,9 @@ static int eeprom_write_data(SMBusDevice *dev, uint8_t *buf, uint8_t len)static bool smbus_eeprom_vmstate_needed (void *opaque) { -MachineClass *mc =MACHINE_GET_CLASS (qdev_get_machine ());SMBusEEPROMDevice *eeprom = opaque; -return (eeprom->accessed ||smbus_vmstate_needed (&eeprom->smbusdev)) && - !mc->smbus_no_migration_support; +return eeprom->accessed ||smbus_vmstate_needed (&eeprom->smbusdev); }static const VMStateDescription vmstate_smbus_eeprom = {
hw/i2c/smbus_ich9.c +2 -8
@@ -41,20 +41,14 @@ struct ICH9SMBState {PMSMBus smb; }; -static bool ich9_vmstate_need_smbus (void *opaque,int version_id) -{ -return pm_smbus_vmstate_needed (); -} -static const VMStateDescription vmstate_ich9_smbus = { .name ="ich9_smb" , .version_id =1 , .minimum_version_id =1 , .fields = (const VMStateField []) {VMSTATE_PCI_DEVICE (dev, ICH9SMBState), -VMSTATE_BOOL_TEST (irq_enabled, ICH9SMBState, ich9_vmstate_need_smbus), -VMSTATE_STRUCT_TEST (smb, ICH9SMBState, ich9_vmstate_need_smbus,1 , - pmsmb_vmstate, PMSMBus), +VMSTATE_BOOL (irq_enabled, ICH9SMBState), +VMSTATE_STRUCT (smb, ICH9SMBState,1 , pmsmb_vmstate, PMSMBus),VMSTATE_END_OF_LIST () } };
Signature · 1 line
2.53.0
Re: [PATCH v2 04/10] hw/core/boards: Remove MachineClass::smbus_no_migration_support field
Quoted 5 lines · Philippe Mathieu-Daudé
The
MachineClass::smbus_no_migration_supportboolean was only used by the pc-q35-3.1 and pc-i440fx-3.1 machines, which got removed. Remove it, along withpm_smbus_vmstate_needed().Use the unconditional
VMSTATE_BOOL()andVMSTATE_STRUCT()macros.
Nice.
or do you want me to handle it?
-corey
Quoted 134 lines
Signed-off-by Philippe Mathieu-Daudé <[email protected]>Reviewed-by Thomas Huth <[email protected]>Message-Id: <[email protected]>
--- include/hw/core/boards.h | 1 - include/hw/i2c/pm_smbus.h | 7 ------- hw/acpi/piix4.c | 8 +------- hw/i2c/pm_smbus.c | 7 ------- hw/i2c/smbus_eeprom.c | 4 +--- hw/i2c/smbus_ich9.c | 10 ++-------- 6 files changed, 4 insertions(+), 33 deletions(-)include/hw/core/boards.h +0
-1@@ -314,7 +314,6 @@ struct MachineClass {bool auto_enable_numa_with_memhp;bool auto_enable_numa_with_memdev;bool ignore_boot_device_suffixes; -bool smbus_no_migration_support;bool nvdimm_supported;bool numa_mem_supported;bool auto_enable_numa;include/hw/i2c/pm_smbus.h +0
-7@@ -44,13 +44,6 @@ typedef struct PMSMBus {void pm_smbus_init (DeviceState *parent,PMSMBus *smb,bool force_aux_blk); -/* -* For backwards compatibility on migration, older versions don't have -* working migration for pm_smbus, this lets us ignore the migrations -* for older machine versions. -*/ -bool pm_smbus_vmstate_needed (void ); -extern const VMStateDescription pmsmb_vmstate;#endif /* PM_SMBUS_H */ hw/acpi/piix4.c +1
-7@@ -205,11 +205,6 @@ static const VMStateDescription vmstate_cpuhp_state = { } }; -static bool piix4_vmstate_need_smbus (void *opaque,int version_id) -{ -return pm_smbus_vmstate_needed (); -} -/* * This is a fudge to turn off the acpi_index field, * whose test was always broken on piix4 with 6.2 and older machine types. @@ -238,8 +233,7 @@ static const VMStateDescription vmstate_acpi = {VMSTATE_UINT16 (ar.pm1.evt.en, PIIX4PMState),VMSTATE_UINT16 (ar.pm1.cnt.cnt, PIIX4PMState),VMSTATE_STRUCT (apm, PIIX4PMState,0 , vmstate_apm, APMState), -VMSTATE_STRUCT_TEST (smb, PIIX4PMState, piix4_vmstate_need_smbus,3 , - pmsmb_vmstate, PMSMBus), +VMSTATE_STRUCT (smb, PIIX4PMState,3 , pmsmb_vmstate, PMSMBus),VMSTATE_TIMER_PTR (ar.tmr.timer, PIIX4PMState),VMSTATE_INT64 (ar.tmr.overflow_time, PIIX4PMState), VMSTATE_STRUCT(ar.gpe, PIIX4PMState, 2, vmstate_gpe, ACPIGPE),hw/i2c/pm_smbus.c +0
-7@@ -443,13 +443,6 @@ static const MemoryRegionOps pm_smbus_ops = { .endianness = DEVICE_LITTLE_ENDIAN, }; -bool pm_smbus_vmstate_needed (void ) -{ -MachineClass *mc =MACHINE_GET_CLASS (qdev_get_machine ()); - -return !mc->smbus_no_migration_support; -} -const VMStateDescription pmsmb_vmstate = { .name ="pmsmb" , .version_id =1 ,hw/i2c/smbus_eeprom.c +1
-3@@ -88,11 +88,9 @@ static int eeprom_write_data(SMBusDevice *dev, uint8_t *buf, uint8_t len)static bool smbus_eeprom_vmstate_needed (void *opaque) { -MachineClass *mc =MACHINE_GET_CLASS (qdev_get_machine ());SMBusEEPROMDevice *eeprom = opaque; -return (eeprom->accessed ||smbus_vmstate_needed (&eeprom->smbusdev)) && - !mc->smbus_no_migration_support; +return eeprom->accessed ||smbus_vmstate_needed (&eeprom->smbusdev); }static const VMStateDescription vmstate_smbus_eeprom = {hw/i2c/smbus_ich9.c +2
-8@@ -41,20 +41,14 @@ struct ICH9SMBState {PMSMBus smb; }; -static bool ich9_vmstate_need_smbus (void *opaque,int version_id) -{ -return pm_smbus_vmstate_needed (); -} -static const VMStateDescription vmstate_ich9_smbus = { .name ="ich9_smb" , .version_id =1 , .minimum_version_id =1 , .fields = (const VMStateField []) {VMSTATE_PCI_DEVICE (dev, ICH9SMBState), -VMSTATE_BOOL_TEST (irq_enabled, ICH9SMBState, ich9_vmstate_need_smbus), -VMSTATE_STRUCT_TEST (smb, ICH9SMBState, ich9_vmstate_need_smbus,1 , - pmsmb_vmstate, PMSMBus), +VMSTATE_BOOL (irq_enabled, ICH9SMBState), +VMSTATE_STRUCT (smb, ICH9SMBState,1 , pmsmb_vmstate, PMSMBus),VMSTATE_END_OF_LIST () } };Signature · 1 line
2.53.0
Re: [PATCH v2 04/10] hw/core/boards: Remove MachineClass::smbus_no_migration_support field
In reply to Philippe Mathieu-DaudéQuoted 15 lines · Philippe Mathieu-Daudé
Date: Mon, 9 Mar 2026 15:50:06 +0100
From: Philippe Mathieu-Daudé <[email protected]>
Subject: [PATCH v2 04/10] hw/core/boards: Remove
MachineClass::smbus_no_migration_supportfield
X-Mailer: git-send-email 2.53.0The
MachineClass::smbus_no_migration_supportboolean was only used by the pc-q35-3.1 and pc-i440fx-3.1 machines, which got removed. Remove it, along withpm_smbus_vmstate_needed().Use the unconditional
VMSTATE_BOOL()andVMSTATE_STRUCT()macros.Signed-off-by Philippe Mathieu-Daudé <[email protected]>Reviewed-by Thomas Huth <[email protected]>Message-Id: <[email protected]>
Quoted 8 lines
--- include/hw/core/boards.h | 1 - include/hw/i2c/pm_smbus.h | 7 ------- hw/acpi/piix4.c | 8 +------- hw/i2c/pm_smbus.c | 7 ------- hw/i2c/smbus_eeprom.c | 4 +--- hw/i2c/smbus_ich9.c | 10 ++-------- 6 files changed, 4 insertions(+), 33 deletions(-)
PATCH v2 5/10 hw/i386/pc: Remove pc_compat_3_1[] array
In reply to Philippe Mathieu-DaudéThe pc_compat_3_1[] array was only used by the pc-q35-3.1 and pc-i440fx-3.1 machines, which got removed. Remove it.
Message-Id: <[email protected]>
--- include/hw/i386/pc.h | 3 --- hw/i386/pc.c | 25 ------------------------- 2 files changed, 28 deletions(-)
include/hw/i386/pc.h +0 -3
@@ -271,9 +271,6 @@ extern const size_t pc_compat_4_1_len;extern GlobalProperty pc_compat_4_0[];extern const size_t pc_compat_4_0_len; -extern GlobalProperty pc_compat_3_1[]; -extern const size_t pc_compat_3_1_len; -#define DEFINE_PC_MACHINE (suffix, namestr, initfn, optsfn) \ static void pc_machine_##suffix##_class_init(ObjectClass *oc, \ const void *data) \
hw/i386/pc.c +0 -25
@@ -180,31 +180,6 @@ const size_t pc_compat_4_1_len = G_N_ELEMENTS(pc_compat_4_1);GlobalProperty pc_compat_4_0[] = {};const size_t pc_compat_4_0_len =G_N_ELEMENTS (pc_compat_4_0); -GlobalProperty pc_compat_3_1[] = { - {"intel-iommu" ,"dma-drain" ,"off" }, - {"Opteron_G3" "-" TYPE_X86_CPU ,"rdtscp" ,"off" }, - {"Opteron_G4" "-" TYPE_X86_CPU ,"rdtscp" ,"off" }, - {"Opteron_G4" "-" TYPE_X86_CPU ,"npt" ,"off" }, - {"Opteron_G4" "-" TYPE_X86_CPU ,"nrip-save" ,"off" }, - {"Opteron_G5" "-" TYPE_X86_CPU ,"rdtscp" ,"off" }, - {"Opteron_G5" "-" TYPE_X86_CPU ,"npt" ,"off" }, - {"Opteron_G5" "-" TYPE_X86_CPU ,"nrip-save" ,"off" }, - {"EPYC" "-" TYPE_X86_CPU ,"npt" ,"off" }, - {"EPYC" "-" TYPE_X86_CPU ,"nrip-save" ,"off" }, - {"EPYC-IBPB" "-" TYPE_X86_CPU ,"npt" ,"off" }, - {"EPYC-IBPB" "-" TYPE_X86_CPU ,"nrip-save" ,"off" }, - {"Skylake-Client" "-" TYPE_X86_CPU ,"mpx" ,"on" }, - {"Skylake-Client-IBRS" "-" TYPE_X86_CPU ,"mpx" ,"on" }, - {"Skylake-Server" "-" TYPE_X86_CPU ,"mpx" ,"on" }, - {"Skylake-Server-IBRS" "-" TYPE_X86_CPU ,"mpx" ,"on" }, - {"Cascadelake-Server" "-" TYPE_X86_CPU ,"mpx" ,"on" }, - {"Icelake-Client" "-" TYPE_X86_CPU ,"mpx" ,"on" }, - {"Icelake-Server" "-" TYPE_X86_CPU ,"mpx" ,"on" }, - {"Cascadelake-Server" "-" TYPE_X86_CPU ,"stepping" ,"5" }, - {TYPE_X86_CPU ,"x-intel-pt-auto-level" ,"off" }, -}; -const size_t pc_compat_3_1_len =G_N_ELEMENTS (pc_compat_3_1); -/* * @PC_FW_DATA: * Size of the chunk of memory at the top of RAM for the BIOS ACPI tables
Signature · 1 line
2.53.0
Re: [PATCH v2 05/10] hw/i386/pc: Remove pc_compat_3_1[] array
Quoted 8 lines · Philippe Mathieu-Daudé
Date: Mon, 9 Mar 2026 15:50:07 +0100
From: Philippe Mathieu-Daudé <[email protected]>
Subject: [PATCH v2 05/10] hw/i386/pc: Remove pc_compat_3_1[] array
X-Mailer: git-send-email 2.53.0The pc_compat_3_1[] array was only used by the pc-q35-3.1 and pc-i440fx-3.1 machines, which got removed. Remove it.
Quoted 7 lines
Signed-off-by Philippe Mathieu-Daudé <[email protected]>Reviewed-by Thomas Huth <[email protected]>Message-Id: <[email protected]>
--- include/hw/i386/pc.h | 3 --- hw/i386/pc.c | 25 ------------------------- 2 files changed, 28 deletions(-)
PATCH v2 6/10 hw/i386/iommu: Remove IntelIOMMUState::dma_drain field
In reply to Philippe Mathieu-DaudéThe IntelIOMMUState::dma_drain boolean was only set in the pc_compat_3_1[] array, via the 'dma-drain=off' property. We removed all machines using that array, lets remove that property and all the code around it.
Message-Id: <[email protected]>
--- include/hw/i386/intel_iommu.h | 1 - hw/i386/intel_iommu.c | 11 +---------- 2 files changed, 1 insertion(+), 11 deletions(-)
include/hw/i386/intel_iommu.h +0 -1
@@ -314,7 +314,6 @@ struct IntelIOMMUState {bool intr_eime;/* Extended interrupt mode enabled */ OnOffAuto intr_eim;/* Toggle for EIM cabability */ uint8_t aw_bits;/* Host/IOVA address width (in bits) */ -bool dma_drain;/* Whether DMA r/w draining enabled */ bool pasid;/* Whether to support PASID */ bool fs1gp;/* First Stage 1-GByte Page Support */
hw/i386/intel_iommu.c +1 -10
@@ -4205,7 +4205,6 @@ static const Property vtd_properties[] = {DEFINE_PROP_BOOL ("snoop-control" , IntelIOMMUState, snoop_control, false),DEFINE_PROP_BOOL ("x-pasid-mode" , IntelIOMMUState, pasid, false),DEFINE_PROP_BOOL ("svm" , IntelIOMMUState, svm, false), -DEFINE_PROP_BOOL ("dma-drain" , IntelIOMMUState, dma_drain, true),DEFINE_PROP_BOOL ("stale-tm" , IntelIOMMUState, stale_tm, false), DEFINE_PROP_BOOL("fs1gp", IntelIOMMUState, fs1gp, true), };
@@ -5000,11 +4999,8 @@ static void vtd_cap_init(IntelIOMMUState *s)X86IOMMUState *x86_iommu =X86_IOMMU_DEVICE (s); s->cap =VTD_CAP_FRO |VTD_CAP_NFR |VTD_CAP_ND |VTD_ECAP_PT | -VTD_CAP_MAMV |VTD_CAP_PSI |VTD_CAP_SSLPS | +VTD_CAP_MAMV |VTD_CAP_PSI |VTD_CAP_SSLPS |VTD_CAP_DRAIN |VTD_CAP_ESRTPS |VTD_CAP_MGAW (s->aw_bits); -if (s->dma_drain) { - s->cap |=VTD_CAP_DRAIN ; - }if (x86_iommu->dma_translation) {if (s->aw_bits >=VTD_HOST_AW_39BIT ) { s->cap |= VTD_CAP_SAGAW_39bit;
@@ -5582,11 +5578,6 @@ static bool vtd_decide_config(IntelIOMMUState *s, Error **errp)return false; } -if (s->scalable_mode && !s->dma_drain) { -error_setg (errp,"Need to set dma_drain for scalable mode" ); -return false; - } -if (s->pasid && !s->scalable_mode) {error_setg (errp,"Need to set scalable mode for PASID" );return false;
Signature · 1 line
2.53.0
Re: [PATCH v2 06/10] hw/i386/iommu: Remove IntelIOMMUState::dma_drain field
Hi Phil,
Thanks for that!
Quoted 62 lines · Philippe Mathieu-Daudé
The
IntelIOMMUState::dma_drainboolean was only set in the pc_compat_3_1[] array, via the 'dma-drain=off' property. We removed all machines using that array, lets remove that property and all the code around it.Message-Id: <[[email protected]](mailto:[email protected])>
---
include/hw/i386/intel_iommu.h | 1 -
hw/i386/intel_iommu.c | 11 +----------2 files changed, 1 insertion(+), 11 deletions(-)include/hw/i386/intel_iommu.h +0
-0@@ -314,7 +314,6 @@ struct IntelIOMMUState {bool intr_eime; /* Extended interrupt mode enabled */ OnOffAuto intr_eim; /* Toggle for EIM cabability */
uint8_taw_bits; /* Host/IOVA address width (in bits) */ - bool dma_drain; /* Whether DMA r/w draining enabled */ bool pasid; /* Whether to support PASID */ bool fs1gp; /* First Stage 1-GByte Page Support */hw/i386/intel_iommu.c +0
-1@@ -4205,7 +4205,6 @@ static const Property vtd_properties[] = { DEFINE_PROP_BOOL("snoop-control", IntelIOMMUState, snoop_control, false), DEFINE_PROP_BOOL("x-pasid-mode", IntelIOMMUState, pasid, false), DEFINE_PROP_BOOL("svm", IntelIOMMUState, svm, false), - DEFINE_PROP_BOOL("dma-drain", IntelIOMMUState, dma_drain, true), DEFINE_PROP_BOOL("stale-tm", IntelIOMMUState, stale_tm, false), DEFINE_PROP_BOOL("fs1gp", IntelIOMMUState, fs1gp, true), };@@ -5000,11 +4999,8 @@ static void vtd_cap_init(IntelIOMMUState *s) X86IOMMUState *x86_iommu = X86_IOMMU_DEVICE(s);
s->cap=VTD_CAP_FRO|VTD_CAP_NFR|VTD_CAP_ND|VTD_ECAP_PT|- VTD_CAP_MAMV | VTD_CAP_PSI | VTD_CAP_SSLPS | + VTD_CAP_MAMV | VTD_CAP_PSI | VTD_CAP_SSLPS | VTD_CAP_DRAIN |
VTD_CAP_ESRTPS|VTD_CAP_MGAW(s->aw_bits); - if (s->dma_drain) {
-s->cap|=VTD_CAP_DRAIN;
- }
if (x86_iommu->dma_translation) {
if (s->aw_bits>=VTD_HOST_AW_39BIT) {s->cap|=VTD_CAP_SAGAW_39bit;hw/i386/intel_iommu.c +0
-0@@ -5582,11 +5578,6 @@ static bool vtd_decide_config(IntelIOMMUState *s, Error **errp) return false; }
- if (s->scalable_mode&& !s->dma_drain) {
-error_setg(errp, "Need to set dma_drain for scalable mode"); - return false;
- }
-
if (s->pasid&& !s->scalable_mode) {
error_setg(errp, "Need to set scalable mode for PASID"); return false;
Re: [PATCH v2 06/10] hw/i386/iommu: Remove IntelIOMMUState::dma_drain field
In reply to Philippe Mathieu-DaudéQuoted 11 lines · Philippe Mathieu-Daudé
Date: Mon, 9 Mar 2026 15:50:08 +0100
From: Philippe Mathieu-Daudé <[email protected]>
Subject: [PATCH v2 06/10] hw/i386/iommu: RemoveIntelIOMMUState::dma_drain
field
X-Mailer: git-send-email 2.53.0The
IntelIOMMUState::dma_drainboolean was only set in the pc_compat_3_1[] array, via the 'dma-drain=off' property. We removed all machines using that array, lets remove that property and all the code around it.
Quoted 7 lines
Signed-off-by Philippe Mathieu-Daudé <[email protected]>Reviewed-by Thomas Huth <[email protected]>Message-Id: <[email protected]>
--- include/hw/i386/intel_iommu.h | 1 - hw/i386/intel_iommu.c | 11 +---------- 2 files changed, 1 insertion(+), 11 deletions(-)
PATCH v2 7/10 target/i386/cpu: Remove X86CPU::intel_pt_auto_level field
In reply to Philippe Mathieu-DaudéThe X86CPU::intel_pt_auto_level boolean was only set in the pc_compat_3_1[] array, via the 'x-intel-pt-auto-level=off' property. We removed all machines using that array, let's emove that property and all the code around it.
Message-Id: <[email protected]>
--- target/i386/cpu.h | 3 --- target/i386/cpu.c | 10 +--------- 2 files changed, 1 insertion(+), 12 deletions(-)
target/i386/cpu.h +0 -3
@@ -2457,9 +2457,6 @@ struct ArchCPU {/* Only advertise TOPOEXT features that AMD defines */ bool amd_topoext_features_only; -/* Enable auto level-increase for Intel Processor Trace leave */ -bool intel_pt_auto_level; -/* if true fill the top bits of the MTRR_PHYSMASKn variable range */ bool fill_mtrr_mask;
target/i386/cpu.c +1 -9
@@ -9565,13 +9565,7 @@ void x86_cpu_expand_features(X86CPU *cpu, Error **errp)/* Intel Processor Trace requires CPUID[0x14] */ if ((env->features[FEAT_7_0_EBX ] &CPUID_7_0_EBX_INTEL_PT )) { -if (cpu->intel_pt_auto_level) { -x86_cpu_adjust_level (cpu, &cpu->env.cpuid_min_level,0x14 ); - }else if (cpu->env.cpuid_min_level <0x14 ) { -mark_unavailable_features (cpu,FEAT_7_0_EBX , -CPUID_7_0_EBX_INTEL_PT , -"Intel PT need CPUID leaf 0x14, please set by \"-cpu ...,intel-pt=on,min-level=0x14\"" ); - } +x86_cpu_adjust_level (cpu, &cpu->env.cpuid_min_level,0x14 ); }/*
@@ -10589,8 +10583,6 @@ static const Property x86_cpu_properties[] = {* to the specific Windows version being used." */ DEFINE_PROP_INT32 ("x-hv-max-vps" ,X86CPU , hv_max_vps,-1 ), -DEFINE_PROP_BOOL ("x-intel-pt-auto-level" ,X86CPU , intel_pt_auto_level, - true),DEFINE_PROP_BOOL ("x-l1-cache-per-thread" ,X86CPU , l1_cache_per_core, true), DEFINE_PROP_BOOL("x-force-cpuid-0x1f", X86CPU, force_cpuid_0x1f, false),
Signature · 1 line
2.53.0
Re: [PATCH v2 07/10] target/i386/cpu: Remove X86CPU::intel_pt_auto_level field
Quoted 11 lines · Philippe Mathieu-Daudé
Date: Mon, 9 Mar 2026 15:50:09 +0100
From: Philippe Mathieu-Daudé <[email protected]>
Subject: [PATCH v2 07/10] target/i386/cpu: Remove
X86CPU::intel_pt_auto_levelfield
X-Mailer: git-send-email 2.53.0The
X86CPU::intel_pt_auto_levelboolean was only set in the pc_compat_3_1[] array, via the 'x-intel-pt-auto-level=off' property. We removed all machines using that array, let's emove that property and all the code around it.
Quoted 7 lines
Signed-off-by Philippe Mathieu-Daudé <[email protected]>Reviewed-by Thomas Huth <[email protected]>Message-Id: <[email protected]>
--- target/i386/cpu.h | 3 --- target/i386/cpu.c | 10 +--------- 2 files changed, 1 insertion(+), 12 deletions(-)
PATCH v2 8/10 hw/core/machine: Remove the hw_compat_3_1[] array
In reply to Philippe Mathieu-DaudéThe hw_compat_3_1[] array was only used by the pc-q35-3.1 and pc-i440fx-3.1 machines, which got removed. Remove it.
Message-Id: <[email protected]>
--- include/hw/core/boards.h | 3 --- hw/core/machine.c | 17 ----------------- 2 files changed, 20 deletions(-)
include/hw/core/boards.h +0 -3
@@ -867,7 +867,4 @@ extern const size_t hw_compat_4_1_len;extern GlobalProperty hw_compat_4_0[];extern const size_t hw_compat_4_0_len; -extern GlobalProperty hw_compat_3_1[]; -extern const size_t hw_compat_3_1_len; -#endif
hw/core/machine.c +0 -17
@@ -221,23 +221,6 @@ GlobalProperty hw_compat_4_0[] = { };const size_t hw_compat_4_0_len =G_N_ELEMENTS (hw_compat_4_0); -GlobalProperty hw_compat_3_1[] = { - {"pcie-root-port" ,"x-speed" ,"2_5" }, - {"pcie-root-port" ,"x-width" ,"1" }, - {"memory-backend-file" ,"x-use-canonical-path-for-ramblock-id" ,"true" }, - {"memory-backend-memfd" ,"x-use-canonical-path-for-ramblock-id" ,"true" }, - {"tpm-crb" ,"ppi" ,"false" }, - {"tpm-tis" ,"ppi" ,"false" }, - {"usb-kbd" ,"serial" ,"42" }, - {"usb-mouse" ,"serial" ,"42" }, - {"usb-tablet" ,"serial" ,"42" }, - {"virtio-blk-device" ,"discard" ,"false" }, - {"virtio-blk-device" ,"write-zeroes" ,"false" }, - {"virtio-balloon-device" ,"qemu-4-0-config-size" ,"false" }, - {"pcie-root-port-base" ,"disable-acs" ,"true" },/* Added in 4.1 */ -}; -const size_t hw_compat_3_1_len =G_N_ELEMENTS (hw_compat_3_1); -MachineState *current_machine;static char *machine_get_kernel (Object *obj,Error **errp)
Signature · 1 line
2.53.0
Re: [PATCH v2 08/10] hw/core/machine: Remove the hw_compat_3_1[] array
Quoted 8 lines · Philippe Mathieu-Daudé
Date: Mon, 9 Mar 2026 15:50:10 +0100
From: Philippe Mathieu-Daudé <[email protected]>
Subject: [PATCH v2 08/10] hw/core/machine: Remove the hw_compat_3_1[] array
X-Mailer: git-send-email 2.53.0The hw_compat_3_1[] array was only used by the pc-q35-3.1 and pc-i440fx-3.1 machines, which got removed. Remove it.
Quoted 7 lines
Signed-off-by Philippe Mathieu-Daudé <[email protected]>Reviewed-by Thomas Huth <[email protected]>Message-Id: <[email protected]>
--- include/hw/core/boards.h | 3 --- hw/core/machine.c | 17 ----------------- 2 files changed, 20 deletions(-)
PATCH v2 9/10 hw/pci-bridge/pcie_rp: Remove PCIESlot::disable_acs field
In reply to Philippe Mathieu-DaudéThe PCIESlot::disable_acs boolean was only set in the hw_compat_3_1[] array, via the 'disable-acs=true' property. We removed all machines using that array, lets remove that property and all the code around it.
Message-Id: <[email protected]>
--- include/hw/pci/pcie_port.h | 3 --- hw/pci-bridge/pcie_root_port.c | 3 +-- 2 files changed, 1 insertion(+), 5 deletions(-)
include/hw/pci/pcie_port.h +0 -3
@@ -60,9 +60,6 @@ struct PCIESlot {PCIExpLinkWidth width;bool flitmode; -/* Disable ACS (really for a pcie_root_port) */ -bool disable_acs; -/* Indicates whether any type of hot-plug is allowed on the slot */ bool hotplug;
hw/pci-bridge/pcie_root_port.c +1 -2
@@ -117,7 +117,7 @@ static void rp_realize(PCIDevice *d, Error **errp)pcie_aer_root_init (d);rp_aer_vector_update (d); -if (rpc->acs_offset && !s->disable_acs) { +if (rpc->acs_offset) {pcie_acs_init (d, rpc->acs_offset); }return ;
@@ -151,7 +151,6 @@ static void rp_exit(PCIDevice *d)static const Property rp_props[] = {DEFINE_PROP_BIT (COMPAT_PROP_PCP , PCIDevice, cap_present,QEMU_PCIE_SLTCAP_PCP_BITNR , true), -DEFINE_PROP_BOOL ("disable-acs" , PCIESlot, disable_acs, false), };static void rp_instance_post_init (Object *obj)
Signature · 1 line
2.53.0
PATCH v2 10/10 hw/tpm: Remove CRBState::ppi_enabled field
In reply to Philippe Mathieu-DaudéThe CRBState::ppi_enabled boolean was only set in the hw_compat_3_1[] array, via the 'ppi=false' property. We removed all machines using that array, lets remove that property and all the code around it.
Message-Id: <[email protected]>
--- hw/tpm/tpm_tis.h | 1 - hw/acpi/tpm.c | 4 ---- hw/i386/acpi-build.c | 2 +- hw/tpm/tpm_crb.c | 12 +++--------- hw/tpm/tpm_tis_common.c | 4 +--- hw/tpm/tpm_tis_isa.c | 7 ++----- 6 files changed, 7 insertions(+), 23 deletions(-)
hw/tpm/tpm_tis.h +0 -1
@@ -75,7 +75,6 @@ typedef struct TPMState {size_t be_buffer_size; -bool ppi_enabled;TPMPPI ppi; } TPMState;
hw/acpi/tpm.c +0 -4
@@ -25,10 +25,6 @@ void tpm_build_ppi_acpi(TPMIf *tpm, Aml *dev)Aml *method, *field, *ifctx, *ifctx2, *ifctx3, *func_mask, *not_implemented, *pak, *tpm2, *tpm3, *pprm, *pprq, *zero, *one; -if (!object_property_get_bool (OBJECT (tpm),"ppi" , &error_abort)) { -return ; - } - zero =aml_int (0 ); one =aml_int (1 ); func_mask =aml_int (TPM_PPI_FUNC_MASK );
hw/i386/acpi-build.c +1 -1
@@ -2218,7 +2218,7 @@ void acpi_setup(void) tables.tcpalog->data, acpi_data_len(tables.tcpalog)); tpm =tpm_find (); -if (tpm &&object_property_get_bool (OBJECT (tpm),"ppi" , &error_abort)) { +if (tpm) { tpm_config = (FwCfgTPMConfig ) { .tpmppi_address =cpu_to_le32 (TPM_PPI_ADDR_BASE ), .tpm_version =tpm_get_version (tpm),
hw/tpm/tpm_crb.c +3 -9
@@ -43,7 +43,6 @@ struct CRBState {size_t be_buffer_size; -bool ppi_enabled;TPMPPI ppi; };typedef struct CRBState CRBState ;
@@ -228,16 +227,13 @@ static const VMStateDescription vmstate_tpm_crb = {static const Property tpm_crb_properties[] = {DEFINE_PROP_TPMBE ("tpmdev" , CRBState, tpmbe), -DEFINE_PROP_BOOL ("ppi" , CRBState, ppi_enabled, true), };static void tpm_crb_reset (void *dev) {CRBState *s =CRB (dev); -if (s->ppi_enabled) { -tpm_ppi_reset (&s->ppi); - } +tpm_ppi_reset (&s->ppi);tpm_backend_reset (s->tpmbe);memset (s->regs,0 ,sizeof (s->regs));
@@ -303,10 +299,8 @@ static void tpm_crb_realize(DeviceState *dev, Error **errp)memory_region_add_subregion (get_system_memory (),TPM_CRB_ADDR_BASE +sizeof (s->regs), &s->cmdmem); -if (s->ppi_enabled) { -tpm_ppi_init (&s->ppi,get_system_memory (), -TPM_PPI_ADDR_BASE ,OBJECT (s)); - } +tpm_ppi_init (&s->ppi,get_system_memory (), +TPM_PPI_ADDR_BASE ,OBJECT (s));if (xen_enabled ()) {tpm_crb_reset (dev);
hw/tpm/tpm_tis_common.c +1 -3
@@ -821,9 +821,7 @@ void tpm_tis_reset(TPMState *s) s->be_buffer_size =MIN (tpm_backend_get_buffer_size (s->be_driver),TPM_TIS_BUFFER_MAX ); -if (s->ppi_enabled) { -tpm_ppi_reset (&s->ppi); - } +tpm_ppi_reset (&s->ppi);tpm_backend_reset (s->be_driver); s->active_locty =TPM_TIS_NO_LOCALITY ;
hw/tpm/tpm_tis_isa.c +2 -5
@@ -94,7 +94,6 @@ static void tpm_tis_isa_reset(DeviceState *dev)static const Property tpm_tis_isa_properties[] = {DEFINE_PROP_UINT32 ("irq" , TPMStateISA, state.irq_num,TPM_TIS_IRQ ),DEFINE_PROP_TPMBE ("tpmdev" , TPMStateISA, state.be_driver), -DEFINE_PROP_BOOL ("ppi" , TPMStateISA, state.ppi_enabled, true), };static void tpm_tis_isa_initfn (Object *obj)
@@ -132,10 +131,8 @@ static void tpm_tis_isa_realizefn(DeviceState *dev, Error **errp)memory_region_add_subregion (isa_address_space (ISA_DEVICE (dev)),TPM_TIS_ADDR_BASE , &s->mmio); -if (s->ppi_enabled) { -tpm_ppi_init (&s->ppi,isa_address_space (ISA_DEVICE (dev)), -TPM_PPI_ADDR_BASE ,OBJECT (dev)); - } +tpm_ppi_init (&s->ppi,isa_address_space (ISA_DEVICE (dev)), +TPM_PPI_ADDR_BASE ,OBJECT (dev)); }static void build_tpm_tis_isa_aml (AcpiDevAmlIf *adev,Aml *scope)
Signature · 1 line
2.53.0
Quoted 10 lines · Philippe Mathieu-Daudé
Philippe Mathieu-Daudé (10):
hw/i386/pc: Remove deprecated pc-q35/pc-i440fx/xenfv 3.1 machines hw/i386/pc: RemovePCMachineClass::pvh_enabledfield hw/i386/x86: Remove @pvh_enabled argument inx86_load_linux()hw/core/boards: RemoveMachineClass::smbus_no_migration_supportfield hw/i386/pc: Remove pc_compat_3_1[] array
hw/i386/iommu: RemoveIntelIOMMUState::dma_drainfield target/i386/cpu: RemoveX86CPU::intel_pt_auto_levelfield hw/core/machine: Remove the hw_compat_3_1[] array hw/pci-bridge/pcie_rp: RemovePCIESlot::disable_acsfield
Series queued via hw-misc, thanks.
Quoted 13 lines · Philippe Mathieu-Daudé
Date: Mon, 9 Mar 2026 15:50:02 +0100
From: Philippe Mathieu-Daudé <[email protected]>
Subject: [PATCH v2 00/10] hw/i386/pc: Remove deprecated 3.1 machines
X-Mailer: git-send-email 2.53.01 y.o. dust Thomas asked me to rebase & post:
The versioned 'pc' and 'q35' machines up to 3.1 been marked as deprecated two releases ago, and are older than 6 years, so according to our support policy we can remove them.
v2: Remove xenfv-3.1 in patch #1
Quoted 11 lines
Philippe Mathieu-Daudé (10):
hw/i386/pc: Remove deprecated pc-q35/pc-i440fx/xenfv 3.1 machines hw/i386/pc: RemovePCMachineClass::pvh_enabledfield hw/i386/x86: Remove @pvh_enabled argument inx86_load_linux()hw/core/boards: RemoveMachineClass::smbus_no_migration_supportfield hw/i386/pc: Remove pc_compat_3_1[] array
hw/i386/iommu: RemoveIntelIOMMUState::dma_drainfield target/i386/cpu: RemoveX86CPU::intel_pt_auto_levelfield hw/core/machine: Remove the hw_compat_3_1[] array hw/pci-bridge/pcie_rp: RemovePCIESlot::disable_acsfield hw/tpm: RemoveCRBState::ppi_enabledfield
Just a rough idea - not sure whether patches 9 and 10 should be deprecated before removal. Maybe someone might still use them for emulating older systems?
If you feel it needs to be deprecated first, I could add these two properties to my series about deprecated property support (v3) - v3 will take some time.
Thanks,
Zhao