* [Qemu-devel] [PULL 0/1] ppc-for-2.9 queue 20170403 @ 2017-04-03 10:08 David Gibson 2017-04-03 10:08 ` [Qemu-devel] [PULL 1/1] pseries: Enforce homogeneous threads-per-core David Gibson 2017-04-03 11:24 ` [Qemu-devel] [PULL 0/1] ppc-for-2.9 queue 20170403 Peter Maydell 0 siblings, 2 replies; 3+ messages in thread From: David Gibson @ 2017-04-03 10:08 UTC (permalink / raw) To: peter.maydell Cc: agraf, imammedo, bharata, qemu-devel, qemu-ppc, David Gibson The following changes since commit 95b31d709ba343ad237c3630047ee7438bac4065: Merge remote-tracking branch 'remotes/awilliam/tags/vfio-updates-20170331.0' into staging (2017-03-31 18:06:13 +0100) are available in the git repository at: git://github.com/dgibson/qemu.git tags/ppc-for-2.9-20170403 for you to fetch changes up to 8149e2992f7811355cc34721b79d69d1a3a667dd: pseries: Enforce homogeneous threads-per-core (2017-04-03 13:46:18 +1000) ---------------------------------------------------------------- ppc patch queue 2017-04-03 A single bugfix in this pull request, for an ugly assert() failure, if the user ignores the information in query-hotpluggable-cpus and tries to hot add CPUs to pseries with bad parameters. ---------------------------------------------------------------- David Gibson (1): pseries: Enforce homogeneous threads-per-core hw/ppc/spapr.c | 6 ++++++ 1 file changed, 6 insertions(+) ^ permalink raw reply [flat|nested] 3+ messages in thread
* [Qemu-devel] [PULL 1/1] pseries: Enforce homogeneous threads-per-core 2017-04-03 10:08 [Qemu-devel] [PULL 0/1] ppc-for-2.9 queue 20170403 David Gibson @ 2017-04-03 10:08 ` David Gibson 2017-04-03 11:24 ` [Qemu-devel] [PULL 0/1] ppc-for-2.9 queue 20170403 Peter Maydell 1 sibling, 0 replies; 3+ messages in thread From: David Gibson @ 2017-04-03 10:08 UTC (permalink / raw) To: peter.maydell Cc: agraf, imammedo, bharata, qemu-devel, qemu-ppc, David Gibson For reasons that may be useful in future, CPU core objects, as used on the pseries machine type have their own nr-threads property, potentially allowing cores with different numbers of threads in the same system. If the user/management uses the values specified in query-hotpluggable-cpus as they're expected to do, this will never matter in pratice. But that's not actually enforced - it's possible to manually specify a core with a different number of threads from that in -smp. That will confuse the platform - most immediately, this can be used to create a CPU thread with index above max_cpus which leads to an assertion failure in spapr_cpu_core_realize(). For now, enforce that all cores must have the same, standard, number of threads. Signed-off-by: David Gibson <david@gibson.dropbear.id.au> Reviewed-by: Bharata B Rao <bharata@linux.vnet.ibm.com> --- hw/ppc/spapr.c | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/hw/ppc/spapr.c b/hw/ppc/spapr.c index 44c26e4..35db949 100644 --- a/hw/ppc/spapr.c +++ b/hw/ppc/spapr.c @@ -2790,6 +2790,12 @@ static void spapr_core_pre_plug(HotplugHandler *hotplug_dev, DeviceState *dev, goto out; } + if (cc->nr_threads != smp_threads) { + error_setg(errp, "invalid nr-threads %d, must be %d", + cc->nr_threads, smp_threads); + return; + } + core_slot = spapr_find_cpu_slot(MACHINE(hotplug_dev), cc->core_id, &index); if (!core_slot) { error_setg(&local_err, "core id %d out of range", cc->core_id); -- 2.9.3 ^ permalink raw reply related [flat|nested] 3+ messages in thread
* Re: [Qemu-devel] [PULL 0/1] ppc-for-2.9 queue 20170403 2017-04-03 10:08 [Qemu-devel] [PULL 0/1] ppc-for-2.9 queue 20170403 David Gibson 2017-04-03 10:08 ` [Qemu-devel] [PULL 1/1] pseries: Enforce homogeneous threads-per-core David Gibson @ 2017-04-03 11:24 ` Peter Maydell 1 sibling, 0 replies; 3+ messages in thread From: Peter Maydell @ 2017-04-03 11:24 UTC (permalink / raw) To: David Gibson Cc: Alexander Graf, Igor Mammedov, bharata@linux.vnet.ibm.com, QEMU Developers, qemu-ppc@nongnu.org On 3 April 2017 at 11:08, David Gibson <david@gibson.dropbear.id.au> wrote: > The following changes since commit 95b31d709ba343ad237c3630047ee7438bac4065: > > Merge remote-tracking branch 'remotes/awilliam/tags/vfio-updates-20170331.0' into staging (2017-03-31 18:06:13 +0100) > > are available in the git repository at: > > git://github.com/dgibson/qemu.git tags/ppc-for-2.9-20170403 > > for you to fetch changes up to 8149e2992f7811355cc34721b79d69d1a3a667dd: > > pseries: Enforce homogeneous threads-per-core (2017-04-03 13:46:18 +1000) > > ---------------------------------------------------------------- > ppc patch queue 2017-04-03 > > A single bugfix in this pull request, for an ugly assert() failure, if > the user ignores the information in query-hotpluggable-cpus and tries > to hot add CPUs to pseries with bad parameters. > > ---------------------------------------------------------------- > David Gibson (1): > pseries: Enforce homogeneous threads-per-core Applied, thanks. -- PMM ^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2017-04-03 11:24 UTC | newest] Thread overview: 3+ messages (download: mbox.gz follow: Atom feed -- links below jump to the message on this page -- 2017-04-03 10:08 [Qemu-devel] [PULL 0/1] ppc-for-2.9 queue 20170403 David Gibson 2017-04-03 10:08 ` [Qemu-devel] [PULL 1/1] pseries: Enforce homogeneous threads-per-core David Gibson 2017-04-03 11:24 ` [Qemu-devel] [PULL 0/1] ppc-for-2.9 queue 20170403 Peter Maydell
This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox; as well as URLs for NNTP newsgroup(s).