From: "Andreas Färber" <afaerber@suse.de>
To: Michael Tokarev <mjt@tls.msk.ru>, Alexey Kardashevskiy <aik@ozlabs.ru>
Cc: qemu-trivial@nongnu.org, Igor Mammedov <imammedo@redhat.com>,
qemu-devel@nongnu.org, Eduardo Habkost <ehabkost@redhat.com>
Subject: Re: [Qemu-devel] [Qemu-trivial] [PATCH] vl: remove (max_cpus > 255) check from smp_parse
Date: Mon, 02 Dec 2013 23:09:55 +0100 [thread overview]
Message-ID: <529D0533.7090402@suse.de> (raw)
In-Reply-To: <529CBE15.8010206@msgid.tls.msk.ru>
Am 02.12.2013 18:06, schrieb Michael Tokarev:
> 25.11.2013 07:39, Alexey Kardashevskiy wrote:
>> Since modern POWER7/POWER8 chips can have more that 256 CPU threads
>> (>2000 actually), remove this check from smp_parse.
>>
>> The CPUs number is still checked against machine->max_cpus and this check
>> should be enough not to break other archs.
"should be" is not exactly the highest level of confidence for a
"trivial" patch... :/
> []
>> - if (max_cpus > 255) {
>> - fprintf(stderr, "Unsupported number of maxcpus\n");
>> - exit(1);
>> - }
I believe Eduardo touched that code last for NUMA, so let's CC him.
> I don't know whenever this is actually safe. Do we have any static arrays
> of size 255 somewhere, which will be overflowed without this check? :)
s390 has the ipi_states[] array, but not fixed to that size.
x86 APIC IDs I think have or had a limitation to 255 rather than 16-bit?
Igor?
Alexey, did you actually check that, e.g., x86 machines don't break with
256 or 257 CPUs now?
Adding a qtest would be one way to prove that at least the QEMU code of
all other architectures doesn't break with the ppc change.
Regards,
Andreas
--
SUSE LINUX Products GmbH, Maxfeldstr. 5, 90409 Nürnberg, Germany
GF: Jeff Hawn, Jennifer Guild, Felix Imendörffer; HRB 16746 AG Nürnberg
next prev parent reply other threads:[~2013-12-02 22:10 UTC|newest]
Thread overview: 13+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-11-25 3:39 [Qemu-devel] [PATCH] vl: remove (max_cpus > 255) check from smp_parse Alexey Kardashevskiy
2013-12-02 17:06 ` [Qemu-devel] [Qemu-trivial] " Michael Tokarev
2013-12-02 22:09 ` Andreas Färber [this message]
2013-12-02 23:03 ` Alexey Kardashevskiy
2013-12-03 9:00 ` Markus Armbruster
2013-12-03 13:30 ` Andreas Färber
2013-12-03 14:47 ` Eduardo Habkost
2013-12-04 5:50 ` Alexey Kardashevskiy
2013-12-04 12:48 ` Eduardo Habkost
2014-02-14 6:56 ` Alexey Kardashevskiy
2014-02-14 7:34 ` Paolo Bonzini
2013-12-03 10:44 ` Igor Mammedov
2013-12-03 14:33 ` Eduardo Habkost
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=529D0533.7090402@suse.de \
--to=afaerber@suse.de \
--cc=aik@ozlabs.ru \
--cc=ehabkost@redhat.com \
--cc=imammedo@redhat.com \
--cc=mjt@tls.msk.ru \
--cc=qemu-devel@nongnu.org \
--cc=qemu-trivial@nongnu.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
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).