[PATCH 0/2] ppc/pnv: Improve command line experience with multi-chip

Greg Kurz posted 2 patches 6 years, 1 month ago
Test checkpatch failed
Test FreeBSD failed
Test docker-mingw@fedora failed
Test docker-clang@ubuntu failed
Test docker-quick@centos7 failed
Test asan failed
Patches applied successfully (tree, apply log)
git fetch https://github.com/patchew-project/qemu tags/patchew/157686069624.97184.12603452056634667288.stgit@bahia.lan
Maintainers: "Cédric Le Goater" <clg@kaod.org>, David Gibson <david@gibson.dropbear.id.au>
hw/ppc/pnv.c |   33 +++++++++++++++++++++++++--------
1 file changed, 25 insertions(+), 8 deletions(-)
[PATCH 0/2] ppc/pnv: Improve command line experience with multi-chip
Posted by Greg Kurz 6 years, 1 month ago
Patch 1 adds a sanity check of the CPU topology to avoid an assertion in
the multi TCG code that can be easily triggered with the "num-chips" property
of the powernv machine.

This still leaves us with the fact that the number of chips must be specified
twice on the command line: once for the "num-chips" property and once for the
CPU topology with '-smp sockets'. Patch 2 tries to tackle that by changing the
default value of "num-chips" (currently 1) to the number of "sockets" of the
CPU topology, computed at startup time as:

           smp.max_cpus / (smp.cores * smp.threads)

This allow to indirectly configure the number of chips and have a valid
CPU topology with a single '-smp sockets'.

--
Greg

---

Greg Kurz (2):
      ppc/pnv: Exit gracefully if CPU topology doesn't match the machine capacities
      ppc/pnv: Use the CPU topology to compute the default number of chips


 hw/ppc/pnv.c |   33 +++++++++++++++++++++++++--------
 1 file changed, 25 insertions(+), 8 deletions(-)