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.
 -----BEGIN PGP SIGNATURE-----
 Version: GnuPG v2
 
 iQIcBAABCAAGBQJY4h7CAAoJEGw4ysog2bOS+1kP/2UOGjENwY1TimZi4q+QFJMN
 0mabeb1GDwDaJt7xLrMcnlXtTjmerzsN7L9cNRiJA9P48HHO5zRaB+zlLNrxzrTe
 3YU3d7Q1DTH2YJSzBu1/u9Re3SciEEuRXLR5ZmvTXZ0eYsxX2gIUTwv+JEG/k4+7
 GpAoc5YcCabsVPMXyEk7ASZ0iaaKayh3YcWlUVi329y9DBv/ug2J2fa17xrbp8AC
 iJAgDp1h3+RuIz55TskgEL80e23Gb1edPlK6mLCGDs7h6+6liJlPUqKHHnq12dr8
 r+vlUqZI+mtgnGMDbaea/sOM8aUTvantvUowe6zkZwUvsYvsBztMATRJs1/XxRp5
 CJ+yGkH8W9S7NJ5Ih1VHrPEKi4PA3Ftqyy4IE6WqcKMhJlPH57ncd6YU6N2ncXAg
 xov/aI7fvhgShPkfYqDYXH0tCXsddXFLJmZ2l6T4aqoz4vXxExrXXaLozEcypgNo
 yJgXPQD3oGZY/rnhAP67DPPLYXk6XZobdlqqBudpkySDDXoxy/61inJ1i0ltUbaE
 AxfniGulORuAHNuUrK1c2FSAiDgysYe93AskXlR99ZnwOgQBg8fmrC2+JIJsiQZb
 BT4Ku5U8O/4yrjdJI15d11yFs4AvAwmWIZdX/h3bU7vjkOUglgP4MyphuHtLje/I
 G+Z+0P7pYx2pDGwCmHRM
 =yK0M
 -----END PGP SIGNATURE-----

Merge remote-tracking branch 'remotes/dgibson/tags/ppc-for-2.9-20170403' into staging

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.

# gpg: Signature made Mon 03 Apr 2017 11:06:58 BST
# gpg:                using RSA key 0x6C38CACA20D9B392
# gpg: Good signature from "David Gibson <david@gibson.dropbear.id.au>"
# gpg:                 aka "David Gibson (Red Hat) <dgibson@redhat.com>"
# gpg:                 aka "David Gibson (ozlabs.org) <dgibson@ozlabs.org>"
# gpg:                 aka "David Gibson (kernel.org) <dwg@kernel.org>"
# Primary key fingerprint: 75F4 6586 AE61 A66C C44E  87DC 6C38 CACA 20D9 B392

* remotes/dgibson/tags/ppc-for-2.9-20170403:
  pseries: Enforce homogeneous threads-per-core

Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
This commit is contained in:
Peter Maydell 2017-04-03 11:15:33 +01:00
commit 9eb5adae26

View File

@ -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);