pc: disable acpi info for isapc and old pc machine
PATCH 1/1 pc: disable acpi info for isapc and old pc machine
Disable acpi build for isapc and no_kvmclock machine types (used by xen), since acpi build currently expects pci.
--- hw/i386/pc_piix.c | 2 ++ 1 file changed, 2 insertions(+)
hw/i386/pc_piix.c +2 -0
@@ -309,6 +309,7 @@ static void pc_init_pci_1_2(QEMUMachineInitArgs *args)static void pc_init_pci_no_kvmclock (QEMUMachineInitArgs *args) { has_pci_info = false; + has_acpi_build = false;disable_kvm_pv_eoi ();enable_compat_apic_id_mode ();pc_init1 (args,1 ,0 );
@@ -317,6 +318,7 @@ static void pc_init_pci_no_kvmclock(QEMUMachineInitArgs *args)static void pc_init_isa (QEMUMachineInitArgs *args) { has_pci_info = false; + has_acpi_build = false;if (!args->cpu_model) { args->cpu_model ="486" ; }
Signature · 1 line
MST
Il 04/11/2013 11:46, Michael S. Tsirkin ha scritto:
Quoted 2 lines
Disable acpi build for isapc and
no_kvmclockmachine types (used by xen), since acpi build currently expects pci.
Xen is now using "-M pc", so it's okay to remove it from the legacy "-M xenfv".
Quoted 20 lines
Reported-by Andreas Färber <[email protected]>Signed-off-by Michael S. Tsirkin <[email protected]>--- hw/i386/pc_piix.c | 2 ++ 1 file changed, 2 insertions(+)hw/i386/pc_piix.c +1
-0@@ -309,6 +309,7 @@ static void pc_init_pci_1_2(QEMUMachineInitArgs *args)static void pc_init_pci_no_kvmclock (QEMUMachineInitArgs *args) { has_pci_info = false; + has_acpi_build = false;disable_kvm_pv_eoi ();enable_compat_apic_id_mode ();pc_init1 (args,1 ,0 );
hw/i386/pc_piix.c static void pc_init_pci_no_kvmclock(QEMUMachineInitArgs *args) · line 324
Quoted 7 lines
hw/i386/pc_piix.c +1
-0@@ -317,6 +318,7 @@ static void pc_init_pci_no_kvmclock(QEMUMachineInitArgs *args)static void pc_init_isa (QEMUMachineInitArgs *args) { has_pci_info = false; + has_acpi_build = false;if (!args->cpu_model) { args->cpu_model ="486" ; }
Quoted 6 lines · Paolo Bonzini
Il 04/11/2013 11:46, Michael S. Tsirkin ha scritto:
Quoted 2 lines
Disable acpi build for isapc and
no_kvmclockmachine types (used by xen), since acpi build currently expects pci.Xen is now using "-M pc", so it's okay to remove it from the legacy "-M xenfv".
that is correct
Quoted 30 lines
Quoted 20 lines
Reported-by Andreas Färber <[email protected]>Signed-off-by Michael S. Tsirkin <[email protected]>--- hw/i386/pc_piix.c | 2 ++ 1 file changed, 2 insertions(+)hw/i386/pc_piix.c +1
-0@@ -309,6 +309,7 @@ static void pc_init_pci_1_2(QEMUMachineInitArgs *args)static void pc_init_pci_no_kvmclock (QEMUMachineInitArgs *args) { has_pci_info = false; + has_acpi_build = false;disable_kvm_pv_eoi ();enable_compat_apic_id_mode ();pc_init1 (args,1 ,0 );hw/i386/pc_piix.c static void pc_init_pci_no_kvmclock(QEMUMachineInitArgs *args) · line 324
Quoted 7 lines
hw/i386/pc_piix.c +1
-0@@ -317,6 +318,7 @@ static void pc_init_pci_no_kvmclock(QEMUMachineInitArgs *args)static void pc_init_isa (QEMUMachineInitArgs *args) { has_pci_info = false; + has_acpi_build = false;if (!args->cpu_model) { args->cpu_model ="486" ; }Reviewed-by Paolo Bonzini <[email protected]>
Quoted 9 lines · Stefano Stabellini
Quoted 6 lines · Paolo Bonzini
Il 04/11/2013 11:46, Michael S. Tsirkin ha scritto:
Quoted 2 lines
Disable acpi build for isapc and
no_kvmclockmachine types (used by xen), since acpi build currently expects pci.Xen is now using "-M pc", so it's okay to remove it from the legacy "-M xenfv".
that is correct
Partially correct: even xenfv is not using the no_kvmclock init function anymore. So it is certainly OK from Xen POV to remove acpi builds for it, but the commit message is wrong.
Quoted 30 lines
Quoted 30 lines
Quoted 20 lines
Reported-by Andreas Färber <[email protected]>Signed-off-by Michael S. Tsirkin <[email protected]>--- hw/i386/pc_piix.c | 2 ++ 1 file changed, 2 insertions(+)hw/i386/pc_piix.c +1
-0@@ -309,6 +309,7 @@ static void pc_init_pci_1_2(QEMUMachineInitArgs *args)static void pc_init_pci_no_kvmclock (QEMUMachineInitArgs *args) { has_pci_info = false; + has_acpi_build = false;disable_kvm_pv_eoi ();enable_compat_apic_id_mode ();pc_init1 (args,1 ,0 );hw/i386/pc_piix.c static void pc_init_pci_no_kvmclock(QEMUMachineInitArgs *args) · line 324
Quoted 7 lines
hw/i386/pc_piix.c +1
-0@@ -317,6 +318,7 @@ static void pc_init_pci_no_kvmclock(QEMUMachineInitArgs *args)static void pc_init_isa (QEMUMachineInitArgs *args) { has_pci_info = false; + has_acpi_build = false;if (!args->cpu_model) { args->cpu_model ="486" ; }Reviewed-by Paolo Bonzini <[email protected]>
Il 04/11/2013 11:46, Michael S. Tsirkin ha scritto:
Quoted 5 lines
Disable acpi build for isapc and
no_kvmclockmachine types (used by xen), since acpi build currently expects pci.Reported-by Andreas Färber <[email protected]>Signed-off-by Michael S. Tsirkin <[email protected]>
Wait, Xen is not using pc_init_pci_no_kvmclock. But that's not a problem, we can expose ACPI info via fw_cfg and then Xen hvmloader can decide whether to use it or not. Right now it doesn't, maybe later on it should.
If Xen is broken, we need to patch pc_xen_hvm_init, but Andreas only tested isapc not xenfv. So unless someone reports otherwise, there is no need to exclude ACPI info from "-M xenpv".
So my first review was wrong, but I still agree with the patch.
Paolo
Quoted 12 lines · Paolo Bonzini
Il 04/11/2013 11:46, Michael S. Tsirkin ha scritto:
Quoted 5 lines
Disable acpi build for isapc and
no_kvmclockmachine types (used by xen), since acpi build currently expects pci.Reported-by Andreas Färber <[email protected]>Signed-off-by Michael S. Tsirkin <[email protected]>Wait, Xen is not using
pc_init_pci_no_kvmclock. But that's not a problem, we can expose ACPI info viafw_cfgand then Xen hvmloader can decide whether to use it or not. Right now it doesn't, maybe later on it should.
Quoted 7 lines
If Xen is broken, we need to patch
pc_xen_hvm_init, but Andreas only tested isapc not xenfv. So unless someone reports otherwise, there is no need to exclude ACPI info from "-M xenpv".So my first review was wrong, but I still agree with the patch.
Paolo
I really went by the comment
/* PC init function for pc-0.10 to pc-0.13, and reused by xenfv */ static void pc_init_pci_no_kvmclock(QEMUMachineInitArgs *args)
Clearly pc-0.13 and older should not have acpi :)
Signature · 1 line
MST
Quoted 19 lines · Michael S. Tsirkin
Quoted 18 lines · Paolo Bonzini
Il 04/11/2013 11:46, Michael S. Tsirkin ha scritto:
Quoted 5 lines
Disable acpi build for isapc and
no_kvmclockmachine types (used by xen), since acpi build currently expects pci.Reported-by Andreas Färber <[email protected]>Signed-off-by Michael S. Tsirkin <[email protected]>Wait, Xen is not using
pc_init_pci_no_kvmclock. But that's not a problem, we can expose ACPI info viafw_cfgand then Xen hvmloader can decide whether to use it or not. Right now it doesn't, maybe later on it should.If Xen is broken, we need to patch
pc_xen_hvm_init, but Andreas only tested isapc not xenfv. So unless someone reports otherwise, there is no need to exclude ACPI info from "-M xenpv".So my first review was wrong, but I still agree with the patch.
Quoted 7 lines
Quoted 1 line
Paolo
I really went by the comment
/* PC init function for pc-0.10 to pc-0.13, and reused by xenfv */ static voidpc_init_pci_no_kvmclock(QEMUMachineInitArgs *args)Clearly pc-0.13 and older should not have acpi :)
That's fine, it's just that the comment is outdated. Since you are at it you could remove the "and reused by xenfv" :-)
Am 04.11.2013 11:46, schrieb Michael S. Tsirkin:
Quoted 23 lines
Disable acpi build for isapc and
no_kvmclockmachine types (used by xen), since acpi build currently expects pci.Reported-by Andreas Färber <[email protected]>Signed-off-by Michael S. Tsirkin <[email protected]>--- hw/i386/pc_piix.c | 2 ++ 1 file changed, 2 insertions(+)hw/i386/pc_piix.c +1
-0@@ -309,6 +309,7 @@ static void pc_init_pci_1_2(QEMUMachineInitArgs *args)static void pc_init_pci_no_kvmclock (QEMUMachineInitArgs *args) { has_pci_info = false; + has_acpi_build = false;disable_kvm_pv_eoi ();enable_compat_apic_id_mode ();pc_init1 (args,1 ,0 );
hw/i386/pc_piix.c static void pc_init_pci_no_kvmclock(QEMUMachineInitArgs *args) · line 324
Quoted 7 lines
hw/i386/pc_piix.c +1
-0@@ -317,6 +318,7 @@ static void pc_init_pci_no_kvmclock(QEMUMachineInitArgs *args)static void pc_init_isa (QEMUMachineInitArgs *args) { has_pci_info = false; + has_acpi_build = false;if (!args->cpu_model) { args->cpu_model ="486" ; }
FWIW I forgot to reply yesterday that it solves my isapc qom-test failure, too
Thanks!
Andreas
Signature · 2 lines
SUSE LINUX Products GmbH, Maxfeldstr. 5, 90409 Nürnberg, Germany GF: Jeff Hawn, Jennifer Guild, Felix Imendörffer; HRB 16746 AG Nürnberg