[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <3626998c-509f-b434-1f66-9db2c09c47d4@intel.com>
Date: Fri, 12 Jul 2019 06:54:22 -0700
From: Dave Hansen <dave.hansen@...el.com>
To: Peter Zijlstra <peterz@...radead.org>,
Alexandre Chartre <alexandre.chartre@...cle.com>
Cc: Thomas Gleixner <tglx@...utronix.de>, pbonzini@...hat.com,
rkrcmar@...hat.com, mingo@...hat.com, bp@...en8.de, hpa@...or.com,
dave.hansen@...ux.intel.com, luto@...nel.org, kvm@...r.kernel.org,
x86@...nel.org, linux-mm@...ck.org, linux-kernel@...r.kernel.org,
konrad.wilk@...cle.com, jan.setjeeilers@...cle.com,
liran.alon@...cle.com, jwadams@...gle.com, graf@...zon.de,
rppt@...ux.vnet.ibm.com, Paul Turner <pjt@...gle.com>
Subject: Re: [RFC v2 00/27] Kernel Address Space Isolation
On 7/12/19 5:50 AM, Peter Zijlstra wrote:
> PTI is not mapping kernel space to avoid speculation crap (meltdown).
> ASI is not mapping part of kernel space to avoid (different) speculation crap (MDS).
>
> See how very similar they are?
That's an interesting point.
I'd add that PTI maps a part of kernel space that partially overlaps
with what ASI wants.
> But looking at it that way, it makes no sense to retain 3 address
> spaces, namely:
>
> user / kernel exposed / kernel private.
>
> Specifically, it makes no sense to expose part of the kernel through MDS
> but not through Meltdown. Therefore we can merge the user and kernel
> exposed address spaces.
>
> And then we've fully replaced PTI.
So, in one address space (PTI/user or ASI), we say, "screw it" and all
the data mapped is exposed to speculation attacks. We have to be very
careful about what we map and expose here.
The other (full kernel) address space we are more careful about what we
*do* instead of what we map. We map everything but have to add
mitigations to ensure that we don't leak anything back to the exposed
address space.
So, maybe we're not replacing PTI as much as we're growing PTI so that
we can run more kernel code with the (now inappropriately named) user
page tables.
Powered by blists - more mailing lists