From: Borislav Petkov <bp@alien8.de>
To: Reinette Chatre <reinette.chatre@intel.com>
Cc: "Vitaly Kuznetsov" <vkuznets@redhat.com>,
"Babu Moger" <Babu.Moger@amd.com>,
x86@kernel.org, linux-kernel@vger.kernel.org,
"Fenghua Yu" <fenghua.yu@intel.com>,
"Thomas Gleixner" <tglx@linutronix.de>,
"Ingo Molnar" <mingo@redhat.com>,
"H. Peter Anvin" <hpa@zytor.com>,
"Jan H. Schönherr" <jschoenh@amazon.de>,
"David Duncan" <davdunc@amazon.com>
Subject: Re: [PATCH] x86/intel_rdt: use rdmsr_safe() to workaround AWS host issue
Date: Wed, 9 Jan 2019 12:39:15 +0100 [thread overview]
Message-ID: <20190109113915.GB15665@zn.tnic> (raw)
In-Reply-To: <20521afe-09af-7acf-6f32-3f6e9a971091@intel.com>
On Tue, Jan 08, 2019 at 09:39:46PM -0800, Reinette Chatre wrote:
> To clarify please the last sentence applies to real Haswell server CPUs
> (not virtualized as prompted this work, my apologies for the confusion)
> that support Intel RDT but does not have CPUID enumeration for this
> feature. With Vitaly's patch this hardware would still be detected as
> supporting CAT but if CPUID enumeration is moved earlier then from what
> I can tell this hardware would be considered as not supporting the
> feature anymore.
Ok, so hw "forgot" to add CPUID again. And CPU guys should know better
but everytime we hear "important reasons" why they dropped the ball
there.
So, assuming RDT is not going to be supported in a guest, we need a
proper fix to disable it when in a guest. So the RDT init path needs
something like this then:
---
diff --git a/arch/x86/kernel/cpu/resctrl/core.c b/arch/x86/kernel/cpu/resctrl/core.c
index c3a9dc63edf2..1e5a1cb49e9c 100644
--- a/arch/x86/kernel/cpu/resctrl/core.c
+++ b/arch/x86/kernel/cpu/resctrl/core.c
@@ -969,6 +969,9 @@ static int __init resctrl_late_init(void)
struct rdt_resource *r;
int state, ret;
+ if (boot_cpu_has(X86_FEATURE_HYPERVISOR))
+ return -ENODEV;
+
/*
* Initialize functions(or definitions) that are different
* between vendors here.
--
Regards/Gruss,
Boris.
Good mailing practices for 400: avoid top-posting and trim the reply.
next prev parent reply other threads:[~2019-01-09 11:39 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-12-20 13:40 Vitaly Kuznetsov
2018-12-20 16:17 ` Borislav Petkov
2018-12-20 17:31 ` Vitaly Kuznetsov
[not found] ` <51dcb13a-4751-47f5-1e01-f6731a2c6f3c@intel.com>
[not found] ` <20521afe-09af-7acf-6f32-3f6e9a971091@intel.com>
2019-01-09 11:39 ` Borislav Petkov [this message]
2019-01-09 12:09 ` Vitaly Kuznetsov
2019-01-09 12:14 ` Borislav Petkov
2019-01-09 18:41 ` Tony Luck
2019-01-10 10:32 ` Vitaly Kuznetsov
2019-01-10 10:53 ` Borislav Petkov
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=20190109113915.GB15665@zn.tnic \
--to=bp@alien8.de \
--cc=Babu.Moger@amd.com \
--cc=davdunc@amazon.com \
--cc=fenghua.yu@intel.com \
--cc=hpa@zytor.com \
--cc=jschoenh@amazon.de \
--cc=linux-kernel@vger.kernel.org \
--cc=mingo@redhat.com \
--cc=reinette.chatre@intel.com \
--cc=tglx@linutronix.de \
--cc=vkuznets@redhat.com \
--cc=x86@kernel.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
all inboxes | Powered by JetHome®