From: Dave Hansen <dave.hansen@intel.com>
To: Sean Christopherson <sean.j.christopherson@intel.com>,
Thomas Gleixner <tglx@linutronix.de>,
Ingo Molnar <mingo@redhat.com>, Borislav Petkov <bp@alien8.de>,
x86@kernel.org
Cc: "H. Peter Anvin" <hpa@zytor.com>,
linux-kernel@vger.kernel.org,
Dave Hansen <dave.hansen@linux.intel.com>,
Jacob Keller <jacob.e.keller@intel.com>
Subject: Re: [PATCH] x86/pkeys: Manually set X86_FEATURE_OSPKE to preserve existing changes
Date: Wed, 26 Feb 2020 15:32:21 -0800 [thread overview]
Message-ID: <950b249a-f47d-0adc-80dd-68d397e4de4f@intel.com> (raw)
In-Reply-To: <20200226231615.13664-1-sean.j.christopherson@intel.com>
On 2/26/20 3:16 PM, Sean Christopherson wrote:
> Explicitly set X86_FEATURE_OSPKE via set_cpu_cap() instead of calling
> get_cpu_cap() to pull the feature bit from CPUID after enabling CR4.PKE.
First of all,
Acked-by: Dave Hansen <dave.hansen@linux.intel.com>
I don't remember whether it was you or someone else inside Intel, but
someone was tripping over this recently.
I do think we need a bit more care in how we deal with dynamic CPUID
bits. I think you'd agree that it's a bit haphazard. For instance, I
went looking for where we set X86_FEATURE_OSXSAVE after the
cr4_set_bits(X86_CR4_OSXSAVE);
inside fpu__init_cpu_xstate() makes it appear. I couldn't find one, not
that we would notice since we suppress it from /proc/cpuinfo.
next prev parent reply other threads:[~2020-02-26 23:32 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-02-26 23:16 [PATCH] x86/pkeys: Manually set X86_FEATURE_OSPKE to preserve existing changes Sean Christopherson
2020-02-26 23:32 ` Dave Hansen [this message]
2020-02-26 23:40 ` Jacob Keller
2020-02-27 0:16 ` Jacob Keller
2020-02-27 18:01 ` Borislav Petkov
2020-02-27 18:20 ` Jacob Keller
2020-02-27 18:07 ` [tip: x86/urgent] " tip-bot2 for Sean Christopherson
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=950b249a-f47d-0adc-80dd-68d397e4de4f@intel.com \
--to=dave.hansen@intel.com \
--cc=bp@alien8.de \
--cc=dave.hansen@linux.intel.com \
--cc=hpa@zytor.com \
--cc=jacob.e.keller@intel.com \
--cc=linux-kernel@vger.kernel.org \
--cc=mingo@redhat.com \
--cc=sean.j.christopherson@intel.com \
--cc=tglx@linutronix.de \
--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;
as well as URLs for NNTP newsgroup(s).