lkml.org 
[lkml]   [2022]   [Jan]   [28]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
SubjectRe: [PATCH V8 09/44] x86/pkeys: Enable PKS on cpus which support it
From
On 1/28/22 15:41, Ira Weiny wrote:
> On Fri, Jan 28, 2022 at 03:18:29PM -0800, Dave Hansen wrote:
>> On 1/27/22 09:54, ira.weiny@intel.com wrote:
>>> Initially, pks_setup() initializes the per-cpu MSR with 0 to enable all
>>> access on all pkeys.
>>
>> Why not just make it restrictive to start out? That's what we do for PKU.
>
> This maintains compatibility with the code prior to this patch. Ie no
> restrictions on kernel mappings.

But, compatibility with what? At this point, there are no non-pkey-0
kernel mappings. So, PKRS can be set to anything as long as the two low
bits are clear.

\
 
 \ /
  Last update: 2022-01-29 00:54    [W:0.896 / U:1.116 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site