mbox series

[RFC,0/6] machine: smp parsing fixes and improvement

Message ID 20210702100739.13672-1-wangyanan55@huawei.com
Headers show
Series machine: smp parsing fixes and improvement | expand

Message

wangyanan (Y) July 2, 2021, 10:07 a.m. UTC
Hello,

Here are some smp parsing fix and improvement, most of which is about
the smp parsing helpers. This series was arranged based on the latest
QEMU code since commit d940d468e29b.

Description:
Patch #1 improves the calculation of maxcpus.
Patch #2 and #3 adds the missing zero-check for values of sockets and dies.
Patch #4 allows us to uniformly use maxcpus for all calculations.
Patch #5 reject the configuration of dies more strictly for non-PC machines.
Patch #6 makes no functional change but tweaks the order of topology parameters.

Regards,
Yanan

Yanan Wang (6):
  machine: Set the value of maxcpus to match cpus if specified as zero
  machine: Perform zero-check for the computed value of sockets
  pc/machine: Perform zero-check for the value of -smp dies
  machine: Uniformly use maxcpus to calculate the missing values
  pc/machine: Disallow any configuration of dies for non-PC machines
  machine: Tweak the order of topology members in struct CpuTopology

 hw/core/machine.c   | 49 +++++++++++++++++++++++++--------------------
 hw/i386/pc.c        | 48 +++++++++++++++++++++++++-------------------
 include/hw/boards.h |  7 ++++---
 qapi/machine.json   |  2 +-
 4 files changed, 59 insertions(+), 47 deletions(-)