All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH v3 0/2] hw/i386/pc: Update max_cpus and default to SMBIOS
@ 2023-06-03  3:22 Suravee Suthikulpanit
  2023-06-03  3:22 ` [PATCH v3 1/2] hw/i386/pc: Default to use SMBIOS 3.0 for newer machine models Suravee Suthikulpanit
  2023-06-03  3:22 ` [PATCH v3 2/2] pc: q35: Bump max_cpus to 1024 Suravee Suthikulpanit
  0 siblings, 2 replies; 5+ messages in thread
From: Suravee Suthikulpanit @ 2023-06-03  3:22 UTC (permalink / raw)
  To: qemu-devel
  Cc: pbonzini, richard.henderson, eduardo, mst, marcel.apfelbaum,
	imammedo, berrange, jusual, dfaggioli, joao.m.martins, jon.grimm,
	santosh.Shukla, Suravee Suthikulpanit

In order to support large number of vcpus, a newer 64-bit SMBIOS
entry point type is needed. Therefore, upgrade the default SMBIOS version
for PC machines to SMBIOS 3.0 for newer systems. Then increase the maximum
number of vCPUs for Q35 models to 1024, which is the limit for KVM.

Changes from V2:
(https://lore.kernel.org/qemu-devel/20230531225127.331998-1-suravee.suthikulpanit@amd.com/)
* Add patch 1.

Changes from V1:
(https://lore.kernel.org/all/YnkDGsIi1vFvXmiP@redhat.com/T/)
 * Bump from 512 to KVM_MAX_VCPUS (per Igor's suggestion)

Thank you,
Suravee

Suravee Suthikulpanit (2):
  hw/i386/pc: Default to use SMBIOS 3.0 for newer machine models
  pc: q35: Bump max_cpus to 1024

 hw/i386/pc.c         |  5 ++++-
 hw/i386/pc_piix.c    | 14 ++++++++++++++
 hw/i386/pc_q35.c     | 16 +++++++++++++++-
 include/hw/i386/pc.h |  2 ++
 4 files changed, 35 insertions(+), 2 deletions(-)

-- 
2.34.1



^ permalink raw reply	[flat|nested] 5+ messages in thread

* [PATCH v3 1/2] hw/i386/pc: Default to use SMBIOS 3.0 for newer machine models
  2023-06-03  3:22 [PATCH v3 0/2] hw/i386/pc: Update max_cpus and default to SMBIOS Suravee Suthikulpanit
@ 2023-06-03  3:22 ` Suravee Suthikulpanit
  2023-06-04 12:55   ` Michael S. Tsirkin
  2023-06-03  3:22 ` [PATCH v3 2/2] pc: q35: Bump max_cpus to 1024 Suravee Suthikulpanit
  1 sibling, 1 reply; 5+ messages in thread
From: Suravee Suthikulpanit @ 2023-06-03  3:22 UTC (permalink / raw)
  To: qemu-devel
  Cc: pbonzini, richard.henderson, eduardo, mst, marcel.apfelbaum,
	imammedo, berrange, jusual, dfaggioli, joao.m.martins, jon.grimm,
	santosh.Shukla, Suravee Suthikulpanit

Currently, pc-q35 and pc-i44fx machine models are default to use SMBIOS 2.8
(32-bit entry point). Since SMBIOS 3.0 (64-bit entry point) is now fully
supported since QEMU 7.0, default to use SMBIOS 3.0 for newer machine
models. This is necessary to avoid the following message when launching
a VM with large number of vcpus.

   "SMBIOS 2.1 table length 66822 exceeds 65535"

Note that user can still override the entry point tyme w/ QEMU option
"-M ..., smbios-entry-point-type=[32|64].

Signed-off-by: Suravee Suthikulpanit <suravee.suthikulpanit@amd.com>
---
 hw/i386/pc.c         |  5 ++++-
 hw/i386/pc_piix.c    | 14 ++++++++++++++
 hw/i386/pc_q35.c     | 14 ++++++++++++++
 include/hw/i386/pc.h |  2 ++
 4 files changed, 34 insertions(+), 1 deletion(-)

diff --git a/hw/i386/pc.c b/hw/i386/pc.c
index bb62c994fa..fced0ab0eb 100644
--- a/hw/i386/pc.c
+++ b/hw/i386/pc.c
@@ -1770,7 +1770,10 @@ static void pc_machine_set_smbios_ep(Object *obj, Visitor *v, const char *name,
 {
     PCMachineState *pcms = PC_MACHINE(obj);
 
-    visit_type_SmbiosEntryPointType(v, name, &pcms->smbios_entry_point_type, errp);
+    pcms->smbios_use_cmdline_ep_type =
+        visit_type_SmbiosEntryPointType(v, name,
+                                        &pcms->smbios_entry_point_type,
+                                        errp);
 }
 
 static void pc_machine_get_max_ram_below_4g(Object *obj, Visitor *v,
diff --git a/hw/i386/pc_piix.c b/hw/i386/pc_piix.c
index d5b0dcd1fe..2905b26666 100644
--- a/hw/i386/pc_piix.c
+++ b/hw/i386/pc_piix.c
@@ -199,6 +199,14 @@ static void pc_init1(MachineState *machine,
     pc_guest_info_init(pcms);
 
     if (pcmc->smbios_defaults) {
+        /*
+         * Check if user has specified command line option to override
+         * the default SMBIOS default entry point type.
+         */
+        if (!pcms->smbios_use_cmdline_ep_type) {
+            pcms->smbios_entry_point_type = pcmc->default_smbios_ep_type;
+        }
+
         MachineClass *mc = MACHINE_GET_CLASS(machine);
         /* These values are guest ABI, do not change */
         smbios_set_defaults("QEMU", mc->desc,
@@ -453,6 +461,7 @@ static void pc_i440fx_machine_options(MachineClass *m)
     PCMachineClass *pcmc = PC_MACHINE_CLASS(m);
     pcmc->pci_root_uid = 0;
     pcmc->default_cpu_version = 1;
+    pcmc->default_smbios_ep_type = SMBIOS_ENTRY_POINT_TYPE_64;
 
     m->family = "pc_piix";
     m->desc = "Standard PC (i440FX + PIIX, 1996)";
@@ -476,11 +485,16 @@ DEFINE_I440FX_MACHINE(v8_1, "pc-i440fx-8.1", NULL,
 
 static void pc_i440fx_8_0_machine_options(MachineClass *m)
 {
+    PCMachineClass *pcmc = PC_MACHINE_CLASS(m);
+
     pc_i440fx_8_1_machine_options(m);
     m->alias = NULL;
     m->is_default = false;
     compat_props_add(m->compat_props, hw_compat_8_0, hw_compat_8_0_len);
     compat_props_add(m->compat_props, pc_compat_8_0, pc_compat_8_0_len);
+
+    /* For pc-i44fx-8.0 and older, use SMBIOS 2.8 by default */
+    pcmc->default_smbios_ep_type = SMBIOS_ENTRY_POINT_TYPE_32;
 }
 
 DEFINE_I440FX_MACHINE(v8_0, "pc-i440fx-8.0", NULL,
diff --git a/hw/i386/pc_q35.c b/hw/i386/pc_q35.c
index 6155427e48..2d1bb5fde5 100644
--- a/hw/i386/pc_q35.c
+++ b/hw/i386/pc_q35.c
@@ -199,6 +199,14 @@ static void pc_q35_init(MachineState *machine)
     pc_guest_info_init(pcms);
 
     if (pcmc->smbios_defaults) {
+        /*
+         * Check if user has specified command line option to override
+         * the default SMBIOS default entry point type.
+         */
+        if (!pcms->smbios_use_cmdline_ep_type) {
+            pcms->smbios_entry_point_type = pcmc->default_smbios_ep_type;
+        }
+
         /* These values are guest ABI, do not change */
         smbios_set_defaults("QEMU", mc->desc,
                             mc->name, pcmc->smbios_legacy_mode,
@@ -359,6 +367,7 @@ static void pc_q35_machine_options(MachineClass *m)
     PCMachineClass *pcmc = PC_MACHINE_CLASS(m);
     pcmc->pci_root_uid = 0;
     pcmc->default_cpu_version = 1;
+    pcmc->default_smbios_ep_type = SMBIOS_ENTRY_POINT_TYPE_64;
 
     m->family = "pc_q35";
     m->desc = "Standard PC (Q35 + ICH9, 2009)";
@@ -387,10 +396,15 @@ DEFINE_Q35_MACHINE(v8_1, "pc-q35-8.1", NULL,
 
 static void pc_q35_8_0_machine_options(MachineClass *m)
 {
+    PCMachineClass *pcmc = PC_MACHINE_CLASS(m);
+
     pc_q35_8_1_machine_options(m);
     m->alias = NULL;
     compat_props_add(m->compat_props, hw_compat_8_0, hw_compat_8_0_len);
     compat_props_add(m->compat_props, pc_compat_8_0, pc_compat_8_0_len);
+
+    /* For pc-q35-8.0 and older, use SMBIOS 2.8 by default */
+    pcmc->default_smbios_ep_type = SMBIOS_ENTRY_POINT_TYPE_32;
 }
 
 DEFINE_Q35_MACHINE(v8_0, "pc-q35-8.0", NULL,
diff --git a/include/hw/i386/pc.h b/include/hw/i386/pc.h
index c661e9cc80..f754da5a38 100644
--- a/include/hw/i386/pc.h
+++ b/include/hw/i386/pc.h
@@ -50,6 +50,7 @@ typedef struct PCMachineState {
     bool i8042_enabled;
     bool default_bus_bypass_iommu;
     uint64_t max_fw_size;
+    bool smbios_use_cmdline_ep_type;
 
     /* ACPI Memory hotplug IO base address */
     hwaddr memhp_io_base;
@@ -110,6 +111,7 @@ struct PCMachineClass {
     bool smbios_defaults;
     bool smbios_legacy_mode;
     bool smbios_uuid_encoded;
+    SmbiosEntryPointType default_smbios_ep_type;
 
     /* RAM / address space compat: */
     bool gigabyte_align;
-- 
2.34.1



^ permalink raw reply related	[flat|nested] 5+ messages in thread

* [PATCH v3 2/2] pc: q35: Bump max_cpus to 1024
  2023-06-03  3:22 [PATCH v3 0/2] hw/i386/pc: Update max_cpus and default to SMBIOS Suravee Suthikulpanit
  2023-06-03  3:22 ` [PATCH v3 1/2] hw/i386/pc: Default to use SMBIOS 3.0 for newer machine models Suravee Suthikulpanit
@ 2023-06-03  3:22 ` Suravee Suthikulpanit
  1 sibling, 0 replies; 5+ messages in thread
From: Suravee Suthikulpanit @ 2023-06-03  3:22 UTC (permalink / raw)
  To: qemu-devel
  Cc: pbonzini, richard.henderson, eduardo, mst, marcel.apfelbaum,
	imammedo, berrange, jusual, dfaggioli, joao.m.martins, jon.grimm,
	santosh.Shukla, Suravee Suthikulpanit

Since KVM_MAX_VCPUS is currently defined to 1024 for x86 as shown in
arch/x86/include/asm/kvm_host.h, update QEMU limits to the same number.

In case KVM could not support the specified number of vcpus, QEMU would
return the following error message:

  qemu-system-x86_64: kvm_init_vcpu: kvm_get_vcpu failed (xxx): Invalid argument

Cc: Igor Mammedov <imammedo@redhat.com>
Cc: Daniel P. Berrangé <berrange@redhat.com>
Cc: Michael S. Tsirkin <mst@redhat.com>
Cc: Julia Suvorova <jusual@redhat.com>
Signed-off-by: Suravee Suthikulpanit <suravee.suthikulpanit@amd.com>
---
 hw/i386/pc_q35.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/hw/i386/pc_q35.c b/hw/i386/pc_q35.c
index 2d1bb5fde5..2124ada58d 100644
--- a/hw/i386/pc_q35.c
+++ b/hw/i386/pc_q35.c
@@ -382,7 +382,7 @@ static void pc_q35_machine_options(MachineClass *m)
     machine_class_allow_dynamic_sysbus_dev(m, TYPE_INTEL_IOMMU_DEVICE);
     machine_class_allow_dynamic_sysbus_dev(m, TYPE_RAMFB_DEVICE);
     machine_class_allow_dynamic_sysbus_dev(m, TYPE_VMBUS_BRIDGE);
-    m->max_cpus = 288;
+    m->max_cpus = 1024;
 }
 
 static void pc_q35_8_1_machine_options(MachineClass *m)
-- 
2.34.1



^ permalink raw reply related	[flat|nested] 5+ messages in thread

* Re: [PATCH v3 1/2] hw/i386/pc: Default to use SMBIOS 3.0 for newer machine models
  2023-06-03  3:22 ` [PATCH v3 1/2] hw/i386/pc: Default to use SMBIOS 3.0 for newer machine models Suravee Suthikulpanit
@ 2023-06-04 12:55   ` Michael S. Tsirkin
  2023-06-05 21:43     ` Suthikulpanit, Suravee
  0 siblings, 1 reply; 5+ messages in thread
From: Michael S. Tsirkin @ 2023-06-04 12:55 UTC (permalink / raw)
  To: Suravee Suthikulpanit
  Cc: qemu-devel, pbonzini, richard.henderson, eduardo,
	marcel.apfelbaum, imammedo, berrange, jusual, dfaggioli,
	joao.m.martins, jon.grimm, santosh.Shukla

On Fri, Jun 02, 2023 at 10:22:54PM -0500, Suravee Suthikulpanit wrote:
> Currently, pc-q35 and pc-i44fx machine models are default to use SMBIOS 2.8
> (32-bit entry point). Since SMBIOS 3.0 (64-bit entry point) is now fully
> supported since QEMU 7.0, default to use SMBIOS 3.0 for newer machine
> models. This is necessary to avoid the following message when launching
> a VM with large number of vcpus.
> 
>    "SMBIOS 2.1 table length 66822 exceeds 65535"
> 
> Note that user can still override the entry point tyme w/ QEMU option
> "-M ..., smbios-entry-point-type=[32|64].
> 
> Signed-off-by: Suravee Suthikulpanit <suravee.suthikulpanit@amd.com>
> ---
>  hw/i386/pc.c         |  5 ++++-
>  hw/i386/pc_piix.c    | 14 ++++++++++++++
>  hw/i386/pc_q35.c     | 14 ++++++++++++++
>  include/hw/i386/pc.h |  2 ++
>  4 files changed, 34 insertions(+), 1 deletion(-)
> 
> diff --git a/hw/i386/pc.c b/hw/i386/pc.c
> index bb62c994fa..fced0ab0eb 100644
> --- a/hw/i386/pc.c
> +++ b/hw/i386/pc.c
> @@ -1770,7 +1770,10 @@ static void pc_machine_set_smbios_ep(Object *obj, Visitor *v, const char *name,
>  {
>      PCMachineState *pcms = PC_MACHINE(obj);
>  
> -    visit_type_SmbiosEntryPointType(v, name, &pcms->smbios_entry_point_type, errp);
> +    pcms->smbios_use_cmdline_ep_type =
> +        visit_type_SmbiosEntryPointType(v, name,
> +                                        &pcms->smbios_entry_point_type,
> +                                        errp);
>  }
>  
>  static void pc_machine_get_max_ram_below_4g(Object *obj, Visitor *v,
> diff --git a/hw/i386/pc_piix.c b/hw/i386/pc_piix.c
> index d5b0dcd1fe..2905b26666 100644
> --- a/hw/i386/pc_piix.c
> +++ b/hw/i386/pc_piix.c
> @@ -199,6 +199,14 @@ static void pc_init1(MachineState *machine,
>      pc_guest_info_init(pcms);
>  
>      if (pcmc->smbios_defaults) {
> +        /*
> +         * Check if user has specified command line option to override

a command line

> +         * the default SMBIOS default entry point type.

default twice

> +         */
> +        if (!pcms->smbios_use_cmdline_ep_type) {
> +            pcms->smbios_entry_point_type = pcmc->default_smbios_ep_type;
> +        }
> +
>          MachineClass *mc = MACHINE_GET_CLASS(machine);
>          /* These values are guest ABI, do not change */
>          smbios_set_defaults("QEMU", mc->desc,
> @@ -453,6 +461,7 @@ static void pc_i440fx_machine_options(MachineClass *m)
>      PCMachineClass *pcmc = PC_MACHINE_CLASS(m);
>      pcmc->pci_root_uid = 0;
>      pcmc->default_cpu_version = 1;
> +    pcmc->default_smbios_ep_type = SMBIOS_ENTRY_POINT_TYPE_64;
>  
>      m->family = "pc_piix";
>      m->desc = "Standard PC (i440FX + PIIX, 1996)";
> @@ -476,11 +485,16 @@ DEFINE_I440FX_MACHINE(v8_1, "pc-i440fx-8.1", NULL,
>  
>  static void pc_i440fx_8_0_machine_options(MachineClass *m)
>  {
> +    PCMachineClass *pcmc = PC_MACHINE_CLASS(m);
> +
>      pc_i440fx_8_1_machine_options(m);
>      m->alias = NULL;
>      m->is_default = false;
>      compat_props_add(m->compat_props, hw_compat_8_0, hw_compat_8_0_len);
>      compat_props_add(m->compat_props, pc_compat_8_0, pc_compat_8_0_len);
> +
> +    /* For pc-i44fx-8.0 and older, use SMBIOS 2.8 by default */
> +    pcmc->default_smbios_ep_type = SMBIOS_ENTRY_POINT_TYPE_32;
>  }
>  
>  DEFINE_I440FX_MACHINE(v8_0, "pc-i440fx-8.0", NULL,
> diff --git a/hw/i386/pc_q35.c b/hw/i386/pc_q35.c
> index 6155427e48..2d1bb5fde5 100644
> --- a/hw/i386/pc_q35.c
> +++ b/hw/i386/pc_q35.c
> @@ -199,6 +199,14 @@ static void pc_q35_init(MachineState *machine)
>      pc_guest_info_init(pcms);
>  
>      if (pcmc->smbios_defaults) {
> +        /*
> +         * Check if user has specified command line option to override
> +         * the default SMBIOS default entry point type.

same

> +         */
> +        if (!pcms->smbios_use_cmdline_ep_type) {
> +            pcms->smbios_entry_point_type = pcmc->default_smbios_ep_type;
> +        }
> +
>          /* These values are guest ABI, do not change */
>          smbios_set_defaults("QEMU", mc->desc,
>                              mc->name, pcmc->smbios_legacy_mode,
> @@ -359,6 +367,7 @@ static void pc_q35_machine_options(MachineClass *m)
>      PCMachineClass *pcmc = PC_MACHINE_CLASS(m);
>      pcmc->pci_root_uid = 0;
>      pcmc->default_cpu_version = 1;
> +    pcmc->default_smbios_ep_type = SMBIOS_ENTRY_POINT_TYPE_64;
>  
>      m->family = "pc_q35";
>      m->desc = "Standard PC (Q35 + ICH9, 2009)";
> @@ -387,10 +396,15 @@ DEFINE_Q35_MACHINE(v8_1, "pc-q35-8.1", NULL,
>  
>  static void pc_q35_8_0_machine_options(MachineClass *m)
>  {
> +    PCMachineClass *pcmc = PC_MACHINE_CLASS(m);
> +
>      pc_q35_8_1_machine_options(m);
>      m->alias = NULL;
>      compat_props_add(m->compat_props, hw_compat_8_0, hw_compat_8_0_len);
>      compat_props_add(m->compat_props, pc_compat_8_0, pc_compat_8_0_len);
> +
> +    /* For pc-q35-8.0 and older, use SMBIOS 2.8 by default */
> +    pcmc->default_smbios_ep_type = SMBIOS_ENTRY_POINT_TYPE_32;
>  }
>  
>  DEFINE_Q35_MACHINE(v8_0, "pc-q35-8.0", NULL,
> diff --git a/include/hw/i386/pc.h b/include/hw/i386/pc.h
> index c661e9cc80..f754da5a38 100644
> --- a/include/hw/i386/pc.h
> +++ b/include/hw/i386/pc.h
> @@ -50,6 +50,7 @@ typedef struct PCMachineState {
>      bool i8042_enabled;
>      bool default_bus_bypass_iommu;
>      uint64_t max_fw_size;
> +    bool smbios_use_cmdline_ep_type;
>  
>      /* ACPI Memory hotplug IO base address */
>      hwaddr memhp_io_base;
> @@ -110,6 +111,7 @@ struct PCMachineClass {
>      bool smbios_defaults;
>      bool smbios_legacy_mode;
>      bool smbios_uuid_encoded;
> +    SmbiosEntryPointType default_smbios_ep_type;
>  
>      /* RAM / address space compat: */
>      bool gigabyte_align;


Can't we avoid this code duplication?

E.g. can't we use the pc_compat_8_0 machinery?

> -- 
> 2.34.1



^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [PATCH v3 1/2] hw/i386/pc: Default to use SMBIOS 3.0 for newer machine models
  2023-06-04 12:55   ` Michael S. Tsirkin
@ 2023-06-05 21:43     ` Suthikulpanit, Suravee
  0 siblings, 0 replies; 5+ messages in thread
From: Suthikulpanit, Suravee @ 2023-06-05 21:43 UTC (permalink / raw)
  To: Michael S. Tsirkin
  Cc: qemu-devel, pbonzini, richard.henderson, eduardo,
	marcel.apfelbaum, imammedo, berrange, jusual, dfaggioli,
	joao.m.martins, jon.grimm, santosh.Shukla

Michael,

On 6/4/2023 7:55 PM, Michael S. Tsirkin wrote:
> On Fri, Jun 02, 2023 at 10:22:54PM -0500, Suravee Suthikulpanit wrote:
>> ....
>>
>> --- a/hw/i386/pc_q35.c
>> +++ b/hw/i386/pc_q35.c
>> @@ -199,6 +199,14 @@ static void pc_q35_init(MachineState *machine)
>>       pc_guest_info_init(pcms);
>>   
>>       if (pcmc->smbios_defaults) {
>> +        /*
>> +         * Check if user has specified command line option to override
>> +         * the default SMBIOS default entry point type.
>> +         */
>> +        if (!pcms->smbios_use_cmdline_ep_type) {
>> +            pcms->smbios_entry_point_type = pcmc->default_smbios_ep_type;
>> +        }
>> +
>>           /* These values are guest ABI, do not change */
>>           smbios_set_defaults("QEMU", mc->desc,
>>                               mc->name, pcmc->smbios_legacy_mode,
>> @@ -359,6 +367,7 @@ static void pc_q35_machine_options(MachineClass *m)
>>       PCMachineClass *pcmc = PC_MACHINE_CLASS(m);
>>       pcmc->pci_root_uid = 0;
>>       pcmc->default_cpu_version = 1;
>> +    pcmc->default_smbios_ep_type = SMBIOS_ENTRY_POINT_TYPE_64;
>>   
>>       m->family = "pc_q35";
>>       m->desc = "Standard PC (Q35 + ICH9, 2009)";
>> @@ -387,10 +396,15 @@ DEFINE_Q35_MACHINE(v8_1, "pc-q35-8.1", NULL,
>>   
>>   static void pc_q35_8_0_machine_options(MachineClass *m)
>>   {
>> +    PCMachineClass *pcmc = PC_MACHINE_CLASS(m);
>> +
>>       pc_q35_8_1_machine_options(m);
>>       m->alias = NULL;
>>       compat_props_add(m->compat_props, hw_compat_8_0, hw_compat_8_0_len);
>>       compat_props_add(m->compat_props, pc_compat_8_0, pc_compat_8_0_len);
>> +
>> +    /* For pc-q35-8.0 and older, use SMBIOS 2.8 by default */
>> +    pcmc->default_smbios_ep_type = SMBIOS_ENTRY_POINT_TYPE_32;
>>   }
>>   
>>   DEFINE_Q35_MACHINE(v8_0, "pc-q35-8.0", NULL,
>> diff --git a/include/hw/i386/pc.h b/include/hw/i386/pc.h
>> index c661e9cc80..f754da5a38 100644
>> --- a/include/hw/i386/pc.h
>> +++ b/include/hw/i386/pc.h
>> @@ -50,6 +50,7 @@ typedef struct PCMachineState {
>>       bool i8042_enabled;
>>       bool default_bus_bypass_iommu;
>>       uint64_t max_fw_size;
>> +    bool smbios_use_cmdline_ep_type;
>>   
>>       /* ACPI Memory hotplug IO base address */
>>       hwaddr memhp_io_base;
>> @@ -110,6 +111,7 @@ struct PCMachineClass {
>>       bool smbios_defaults;
>>       bool smbios_legacy_mode;
>>       bool smbios_uuid_encoded;
>> +    SmbiosEntryPointType default_smbios_ep_type;
>>   
>>       /* RAM / address space compat: */
>>       bool gigabyte_align;
> 
> 
> Can't we avoid this code duplication?
> 
> E.g. can't we use the pc_compat_8_0 machinery?

I think we can. I have just submitted v4 with some code refactoring to 
avoid duplication when set up SMBIOS defaults.

Thanks,
Suravee


^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2023-06-05 21:44 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2023-06-03  3:22 [PATCH v3 0/2] hw/i386/pc: Update max_cpus and default to SMBIOS Suravee Suthikulpanit
2023-06-03  3:22 ` [PATCH v3 1/2] hw/i386/pc: Default to use SMBIOS 3.0 for newer machine models Suravee Suthikulpanit
2023-06-04 12:55   ` Michael S. Tsirkin
2023-06-05 21:43     ` Suthikulpanit, Suravee
2023-06-03  3:22 ` [PATCH v3 2/2] pc: q35: Bump max_cpus to 1024 Suravee Suthikulpanit

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.