From: Juergen Gross <jgross@suse.com>
To: Peter Zijlstra <peterz@infradead.org>,
Boris Ostrovsky <boris.ostrovsky@oracle.com>
Cc: linux-kernel@vger.kernel.org, xen-devel@lists.xenproject.org,
tglx@linutronix.de, bp@alien8.de, dave.hansen@linux.intel.com,
x86@kernel.org, hpa@zytor.com
Subject: Re: [PATCH] x86/smp: Factor out parts of native_smp_prepare_cpus()
Date: Tue, 9 Nov 2021 16:21:02 +0100 [thread overview]
Message-ID: <c8412f70-2968-a581-50ec-afe91e492fb2@suse.com> (raw)
In-Reply-To: <YYqPd1c9HIQH9k/9@hirez.programming.kicks-ass.net>
[-- Attachment #1.1.1: Type: text/plain, Size: 1872 bytes --]
On 09.11.21 16:10, Peter Zijlstra wrote:
> On Mon, Nov 08, 2021 at 12:20:26PM -0500, Boris Ostrovsky wrote:
>>
>> On 11/8/21 10:11 AM, Peter Zijlstra wrote:
>>> On Tue, Nov 02, 2021 at 07:36:36PM -0400, Boris Ostrovsky wrote:
>>>> Commit 66558b730f25 ("sched: Add cluster scheduler level for x86")
>>>> introduced cpu_l2c_shared_map mask which is expected to be initialized
>>>> by smp_op.smp_prepare_cpus(). That commit only updated
>>>> native_smp_prepare_cpus() version but not xen_pv_smp_prepare_cpus().
>>>> As result Xen PV guests crash in set_cpu_sibling_map().
>>>>
>>>> While the new mask can be allocated in xen_pv_smp_prepare_cpus() one can
>>>> see that both versions of smp_prepare_cpus ops share a number of common
>>>> operations that can be factored out. So do that instead.
>>>>
>>>> Fixes: 66558b730f25 ("sched: Add cluster scheduler level for x86")
>>>> Signed-off-by: Boris Ostrovsky <boris.ostrovsky@oracle.com>
>>> Thanks! I'll go stick that somewhere /urgent (I've had another report on
>>> that here:
>>>
>>> https://lkml.kernel.org/r/20211105074139.GE174703@worktop.programming.kicks-ass.net
>>> )
>>
>>
>> Thank you. (I don't see this message btw)
>
> Urgh, that thread never went to lkml :/
>
>>> But looking at those functions; there seems to be more spurious
>>> differences. For example, the whole sched_topology thing.
>>
>>
>> I did look at that and thought this should be benign given that Xen PV
>> is not really topology-aware. I didn't see anything that would be a
>> cause for concern but perhaps you can point me to things I missed.
>
> And me not being Xen aware... What does Xen-PV guests see of the CPUID
> topology fields? Does it fully sanitize the CPUID data, or is it a clean
> pass-through from whatever CPU the vCPU happens to run on at the time?
The latter. :-(
Juergen
[-- Attachment #1.1.2: OpenPGP public key --]
[-- Type: application/pgp-keys, Size: 3135 bytes --]
[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 495 bytes --]
next prev parent reply other threads:[~2021-11-09 15:21 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-11-02 23:36 [PATCH] x86/smp: Factor out parts of native_smp_prepare_cpus() Boris Ostrovsky
2021-11-03 5:45 ` Juergen Gross
2021-11-08 15:11 ` Peter Zijlstra
2021-11-08 17:20 ` Boris Ostrovsky
2021-11-09 15:10 ` Peter Zijlstra
2021-11-09 15:21 ` Juergen Gross [this message]
2021-11-09 15:28 ` Andrew Cooper
2021-11-10 21:52 ` Josef Johansson
2021-11-11 10:15 ` Peter Zijlstra
2021-11-11 12:39 ` Josef Johansson
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=c8412f70-2968-a581-50ec-afe91e492fb2@suse.com \
--to=jgross@suse.com \
--cc=boris.ostrovsky@oracle.com \
--cc=bp@alien8.de \
--cc=dave.hansen@linux.intel.com \
--cc=hpa@zytor.com \
--cc=linux-kernel@vger.kernel.org \
--cc=peterz@infradead.org \
--cc=tglx@linutronix.de \
--cc=x86@kernel.org \
--cc=xen-devel@lists.xenproject.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).