[PATCH 09/16] tests: bios-tables-test: Extend core count2 test to cover general topology

Zhao Liu posted 16 patches 2 years, 3 months ago
Maintainers: "Michael S. Tsirkin" <mst@redhat.com>, Igor Mammedov <imammedo@redhat.com>, Ani Sinha <anisinha@redhat.com>, Eduardo Habkost <eduardo@habkost.net>, Marcel Apfelbaum <marcel.apfelbaum@gmail.com>, "Philippe Mathieu-Daudé" <philmd@linaro.org>, Yanan Wang <wangyanan55@huawei.com>
There is a newer version of this series
[PATCH 09/16] tests: bios-tables-test: Extend core count2 test to cover general topology
Posted by Zhao Liu 2 years, 3 months ago
From: Zhao Liu <zhao1.liu@intel.com>

Currently, this case just covers the topology with only core and smt
levels, and doesn't consider more topology layers between socket and
core.

To cover the fixed case in the commit 196ea60a734c3 ("hw/smbios: Fix
core count in type4"), add the "die" level in "-smp" as the more
general topology case.

Suggested-by: Igor Mammedov <imammedo@redhat.com>
Signed-off-by: Zhao Liu <zhao1.liu@intel.com>
---
 tests/qtest/bios-tables-test.c | 6 ++++--
 1 file changed, 4 insertions(+), 2 deletions(-)

diff --git a/tests/qtest/bios-tables-test.c b/tests/qtest/bios-tables-test.c
index a35c753a3a00..8cba1d8126f2 100644
--- a/tests/qtest/bios-tables-test.c
+++ b/tests/qtest/bios-tables-test.c
@@ -1024,10 +1024,12 @@ static void test_acpi_q35_tcg_core_count2(void)
         .required_struct_types = base_required_struct_types,
         .required_struct_types_len = ARRAY_SIZE(base_required_struct_types),
         .smbios_core_count = 0xFF,
-        .smbios_core_count2 = 275,
+        .smbios_core_count2 = 260,
     };
 
-    test_acpi_one("-machine smbios-entry-point-type=64 -smp 275", &data);
+    test_acpi_one("-machine smbios-entry-point-type=64 "
+                  "-smp 260,dies=2,cores=130,threads=1",
+                  &data);
     free_test_data(&data);
 }
 
-- 
2.34.1
Re: [PATCH 09/16] tests: bios-tables-test: Extend core count2 test to cover general topology
Posted by Igor Mammedov 2 years, 3 months ago
On Fri, 25 Aug 2023 11:36:12 +0800
Zhao Liu <zhao1.liu@linux.intel.com> wrote:

> From: Zhao Liu <zhao1.liu@intel.com>
> 
> Currently, this case just covers the topology with only core and smt
> levels, and doesn't consider more topology layers between socket and
> core.
> 
> To cover the fixed case in the commit 196ea60a734c3 ("hw/smbios: Fix
> core count in type4"), add the "die" level in "-smp" as the more
> general topology case.
> 
> Suggested-by: Igor Mammedov <imammedo@redhat.com>
> Signed-off-by: Zhao Liu <zhao1.liu@intel.com>

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

PS:
I'd still explain in commit message relations between
-smp and .smbios_core_count2

> ---
>  tests/qtest/bios-tables-test.c | 6 ++++--
>  1 file changed, 4 insertions(+), 2 deletions(-)
> 
> diff --git a/tests/qtest/bios-tables-test.c b/tests/qtest/bios-tables-test.c
> index a35c753a3a00..8cba1d8126f2 100644
> --- a/tests/qtest/bios-tables-test.c
> +++ b/tests/qtest/bios-tables-test.c
> @@ -1024,10 +1024,12 @@ static void test_acpi_q35_tcg_core_count2(void)
>          .required_struct_types = base_required_struct_types,
>          .required_struct_types_len = ARRAY_SIZE(base_required_struct_types),
>          .smbios_core_count = 0xFF,
> -        .smbios_core_count2 = 275,
> +        .smbios_core_count2 = 260,
>      };
>  
> -    test_acpi_one("-machine smbios-entry-point-type=64 -smp 275", &data);
> +    test_acpi_one("-machine smbios-entry-point-type=64 "
> +                  "-smp 260,dies=2,cores=130,threads=1",
> +                  &data);
>      free_test_data(&data);
>  }
>
Re: [PATCH 09/16] tests: bios-tables-test: Extend core count2 test to cover general topology
Posted by Zhao Liu 2 years, 2 months ago
On Fri, Sep 15, 2023 at 03:11:57PM +0200, Igor Mammedov wrote:
> Date: Fri, 15 Sep 2023 15:11:57 +0200
> From: Igor Mammedov <imammedo@redhat.com>
> Subject: Re: [PATCH 09/16] tests: bios-tables-test: Extend core count2 test
>  to cover general topology
> X-Mailer: Claws Mail 4.1.1 (GTK 3.24.38; x86_64-redhat-linux-gnu)
> 
> On Fri, 25 Aug 2023 11:36:12 +0800
> Zhao Liu <zhao1.liu@linux.intel.com> wrote:
> 
> > From: Zhao Liu <zhao1.liu@intel.com>
> > 
> > Currently, this case just covers the topology with only core and smt
> > levels, and doesn't consider more topology layers between socket and
> > core.
> > 
> > To cover the fixed case in the commit 196ea60a734c3 ("hw/smbios: Fix
> > core count in type4"), add the "die" level in "-smp" as the more
> > general topology case.
> > 
> > Suggested-by: Igor Mammedov <imammedo@redhat.com>
> > Signed-off-by: Zhao Liu <zhao1.liu@intel.com>
> 
> Acked-by: Igor Mammedov <imammedo@redhat.com>

Thanks!

> 
> PS:
> I'd still explain in commit message relations between
> -smp and .smbios_core_count2

Ok.

-Zhao

> 
> > ---
> >  tests/qtest/bios-tables-test.c | 6 ++++--
> >  1 file changed, 4 insertions(+), 2 deletions(-)
> > 
> > diff --git a/tests/qtest/bios-tables-test.c b/tests/qtest/bios-tables-test.c
> > index a35c753a3a00..8cba1d8126f2 100644
> > --- a/tests/qtest/bios-tables-test.c
> > +++ b/tests/qtest/bios-tables-test.c
> > @@ -1024,10 +1024,12 @@ static void test_acpi_q35_tcg_core_count2(void)
> >          .required_struct_types = base_required_struct_types,
> >          .required_struct_types_len = ARRAY_SIZE(base_required_struct_types),
> >          .smbios_core_count = 0xFF,
> > -        .smbios_core_count2 = 275,
> > +        .smbios_core_count2 = 260,
> >      };
> >  
> > -    test_acpi_one("-machine smbios-entry-point-type=64 -smp 275", &data);
> > +    test_acpi_one("-machine smbios-entry-point-type=64 "
> > +                  "-smp 260,dies=2,cores=130,threads=1",
> > +                  &data);
> >      free_test_data(&data);
> >  }
> >  
>