[PATCH v1] hw: fix using 4.2 compat in 5.0 machine types for i440fx/q35

Denis Plotnikov posted 1 patch 4 years, 3 months ago
Test asan failed
Test checkpatch failed
Test FreeBSD failed
Test docker-mingw@fedora failed
Test docker-clang@ubuntu failed
Test docker-quick@centos7 failed
Patches applied successfully (tree, apply log)
git fetch https://github.com/patchew-project/qemu tags/patchew/20191223072856.5369-1-dplotnikov@virtuozzo.com
Maintainers: Richard Henderson <rth@twiddle.net>, Paolo Bonzini <pbonzini@redhat.com>, "Michael S. Tsirkin" <mst@redhat.com>, Marcel Apfelbaum <marcel.apfelbaum@gmail.com>, Eduardo Habkost <ehabkost@redhat.com>
hw/i386/pc_piix.c | 1 -
hw/i386/pc_q35.c  | 1 -
2 files changed, 2 deletions(-)
[PATCH v1] hw: fix using 4.2 compat in 5.0 machine types for i440fx/q35
Posted by Denis Plotnikov 4 years, 3 months ago
5.0 machine type uses 4.2 compats. This seems to be incorrect, since
the latests machine type by now is 5.0 and it should use its own
compat or shouldn't use any relying on the defaults.
Seems, like this appeared because of some problems on merge/rebase.

Signed-off-by: Denis Plotnikov <dplotnikov@virtuozzo.com>
---
 hw/i386/pc_piix.c | 1 -
 hw/i386/pc_q35.c  | 1 -
 2 files changed, 2 deletions(-)

diff --git a/hw/i386/pc_piix.c b/hw/i386/pc_piix.c
index ffb30c32ce..846e70bc55 100644
--- a/hw/i386/pc_piix.c
+++ b/hw/i386/pc_piix.c
@@ -431,7 +431,6 @@ static void pc_i440fx_5_0_machine_options(MachineClass *m)
     m->alias = "pc";
     m->is_default = 1;
     pcmc->default_cpu_version = 1;
-    compat_props_add(m->compat_props, hw_compat_4_2, hw_compat_4_2_len);
 }
 
 DEFINE_I440FX_MACHINE(v5_0, "pc-i440fx-5.0", NULL,
diff --git a/hw/i386/pc_q35.c b/hw/i386/pc_q35.c
index 7398d7baa2..ddd485d608 100644
--- a/hw/i386/pc_q35.c
+++ b/hw/i386/pc_q35.c
@@ -354,7 +354,6 @@ static void pc_q35_5_0_machine_options(MachineClass *m)
     pc_q35_machine_options(m);
     m->alias = "q35";
     pcmc->default_cpu_version = 1;
-    compat_props_add(m->compat_props, hw_compat_4_2, hw_compat_4_2_len);
 }
 
 DEFINE_Q35_MACHINE(v5_0, "pc-q35-5.0", NULL,
-- 
2.17.0


Re: [PATCH v1] hw: fix using 4.2 compat in 5.0 machine types for i440fx/q35
Posted by Igor Mammedov 4 years, 3 months ago
On Mon, 23 Dec 2019 10:28:56 +0300
Denis Plotnikov <dplotnikov@virtuozzo.com> wrote:

> 5.0 machine type uses 4.2 compats. This seems to be incorrect, since
> the latests machine type by now is 5.0 and it should use its own
> compat or shouldn't use any relying on the defaults.
> Seems, like this appeared because of some problems on merge/rebase.
> 
> Signed-off-by: Denis Plotnikov <dplotnikov@virtuozzo.com>

Reviewed-by: Igor Mammedov <imammedo@redhat.com>

> ---
>  hw/i386/pc_piix.c | 1 -
>  hw/i386/pc_q35.c  | 1 -
>  2 files changed, 2 deletions(-)
> 
> diff --git a/hw/i386/pc_piix.c b/hw/i386/pc_piix.c
> index ffb30c32ce..846e70bc55 100644
> --- a/hw/i386/pc_piix.c
> +++ b/hw/i386/pc_piix.c
> @@ -431,7 +431,6 @@ static void pc_i440fx_5_0_machine_options(MachineClass *m)
>      m->alias = "pc";
>      m->is_default = 1;
>      pcmc->default_cpu_version = 1;
> -    compat_props_add(m->compat_props, hw_compat_4_2, hw_compat_4_2_len);
>  }
>  
>  DEFINE_I440FX_MACHINE(v5_0, "pc-i440fx-5.0", NULL,
> diff --git a/hw/i386/pc_q35.c b/hw/i386/pc_q35.c
> index 7398d7baa2..ddd485d608 100644
> --- a/hw/i386/pc_q35.c
> +++ b/hw/i386/pc_q35.c
> @@ -354,7 +354,6 @@ static void pc_q35_5_0_machine_options(MachineClass *m)
>      pc_q35_machine_options(m);
>      m->alias = "q35";
>      pcmc->default_cpu_version = 1;
> -    compat_props_add(m->compat_props, hw_compat_4_2, hw_compat_4_2_len);
>  }
>  
>  DEFINE_Q35_MACHINE(v5_0, "pc-q35-5.0", NULL,


Re: [PATCH v1] hw: fix using 4.2 compat in 5.0 machine types for i440fx/q35
Posted by Cornelia Huck 4 years, 2 months ago
On Mon, 23 Dec 2019 10:28:56 +0300
Denis Plotnikov <dplotnikov@virtuozzo.com> wrote:

> 5.0 machine type uses 4.2 compats. This seems to be incorrect, since
> the latests machine type by now is 5.0 and it should use its own
> compat or shouldn't use any relying on the defaults.
> Seems, like this appeared because of some problems on merge/rebase.

Yes, I seem to have fat-fingered that while rebasing.

> 
> Signed-off-by: Denis Plotnikov <dplotnikov@virtuozzo.com>
> ---
>  hw/i386/pc_piix.c | 1 -
>  hw/i386/pc_q35.c  | 1 -
>  2 files changed, 2 deletions(-)

I double checked that the other compat machines seem fine.

Reviewed-by: Cornelia Huck <cohuck@redhat.com>


Re: [PATCH v1] hw: fix using 4.2 compat in 5.0 machine types for i440fx/q35
Posted by Paolo Bonzini 4 years, 2 months ago
On 07/01/20 10:24, Cornelia Huck wrote:
> On Mon, 23 Dec 2019 10:28:56 +0300
> Denis Plotnikov <dplotnikov@virtuozzo.com> wrote:
> 
>> 5.0 machine type uses 4.2 compats. This seems to be incorrect, since
>> the latests machine type by now is 5.0 and it should use its own
>> compat or shouldn't use any relying on the defaults.
>> Seems, like this appeared because of some problems on merge/rebase.
> 
> Yes, I seem to have fat-fingered that while rebasing.
> 
>>
>> Signed-off-by: Denis Plotnikov <dplotnikov@virtuozzo.com>
>> ---
>>  hw/i386/pc_piix.c | 1 -
>>  hw/i386/pc_q35.c  | 1 -
>>  2 files changed, 2 deletions(-)
> 
> I double checked that the other compat machines seem fine.
> 
> Reviewed-by: Cornelia Huck <cohuck@redhat.com>
> 

Queued, thanks.

Paolo