Received: by 2002:a25:ad19:0:0:0:0:0 with SMTP id y25csp1021889ybi; Fri, 12 Jul 2019 08:23:02 -0700 (PDT) X-Google-Smtp-Source: APXvYqwL2qt0prqJ0tWWPOSvcJJrEeY552K6ZrxU7h7MkzrAgNK/37TQs4ViNfXaPQIJlg8N3YCg X-Received: by 2002:a17:90a:25c8:: with SMTP id k66mr12464125pje.129.1562944982731; Fri, 12 Jul 2019 08:23:02 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1562944982; cv=none; d=google.com; s=arc-20160816; b=tPb/EyB/Yh5s/5j6VHS1WvCMkybYkLe1T1XpXUZ8qQzeKIgv9rWAUM9jgownNntzpw YLhGZn2sKiiL5zrbA6xolK8cgdsH4Q+Rf7EtwaweQvcSplfUCjNpu8at5SgYpDuGZSx+ E7oXvV61wuQocpibOVC4f7iawXTo0z8NZxIz/N7jMNN9MgVcalBL6ldl09cmw0i0zQtI e3+TQOFK6K8bjnETtnNIqNSMTxPnqtic/AnCsdFIfmEppPMR+pQymItLIJ0bpyyQAdTr PeLcVwZZiGzMwVpa9iO+ArI/C+WC2uPVT0BuaIwi879aLuMzPvWshgccDnsTReetgom+ MP2g== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:user-agent:in-reply-to :content-disposition:mime-version:references:message-id:subject:cc :to:from:date:dkim-signature; bh=uWWyW2YDtC0k6gJbqvGGDtXLIh/dygPNqHBQzuripY4=; b=uo1oz5CCqxaWei/tdV9SSp8/sffKVQsMJ//oMsXmjfCD1Jqt1jt1GzRC0vmkfkMy+R xsMftccIGxAzVpnAgWt2ty4kcH1644fUYEqsVrDP8ByWmmfs60DZb7t9zWqIrAJiHrH7 c5cUEdXUdPstiu6t+vYedo/tr5Mk7E7dtFkCVmwKIxDTOsnqbAEf07nB3QVl1XqIzKTh PCU2w7RXWlvy9Ro1AINSjh5BXMTURtQPYvWle2i0uv/3Hf1icWTvk4hpqbq1Ce6lqqXR 8TOCzCpOC3S97709zsKO7B3dVkYjWhoCUxzyBLaNaP84/9TiSrKqjai1ivbCk1bqaymD MHEQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@infradead.org header.s=bombadil.20170209 header.b=LRpvbwuy; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id u9si8040386pjn.86.2019.07.12.08.22.46; Fri, 12 Jul 2019 08:23:02 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=fail header.i=@infradead.org header.s=bombadil.20170209 header.b=LRpvbwuy; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727074AbfGLPVK (ORCPT + 99 others); Fri, 12 Jul 2019 11:21:10 -0400 Received: from bombadil.infradead.org ([198.137.202.133]:55840 "EHLO bombadil.infradead.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726254AbfGLPVJ (ORCPT ); Fri, 12 Jul 2019 11:21:09 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=infradead.org; s=bombadil.20170209; h=In-Reply-To:Content-Type:MIME-Version :References:Message-ID:Subject:Cc:To:From:Date:Sender:Reply-To: Content-Transfer-Encoding:Content-ID:Content-Description:Resent-Date: Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:List-Id: List-Help:List-Unsubscribe:List-Subscribe:List-Post:List-Owner:List-Archive; bh=uWWyW2YDtC0k6gJbqvGGDtXLIh/dygPNqHBQzuripY4=; b=LRpvbwuyvthu0RGBF/kNz9WT4 TvL6NJFgmKj1YTbH/Q1luwGXROnKib4MoSJRSv36BWnauvOLUIjs4IYaxouYot6WbBAdgj1hGzwzV Zhk33bc+ETttOzwYzdkhEDyoYIZHYI8AxkXD+O0QV2M0khTOByI/JtZazzxSVMtWSt5jBFPpm0Gyo fipS/Gh/19/eM9Uc5e6dEc11Tz1Mm+DDcAvtfQfB79lcdLherqODj9TUFRVqvOlyRCVMME2XWZ3ri RWWywWgE7IGSsa6YH1reuguPfod0XMfoiHdTp37uiPUnwGvUeKrvoUgBqlk3rEotvKmI1X2JXR4FL R/HLEg+Gw==; Received: from j217100.upc-j.chello.nl ([24.132.217.100] helo=hirez.programming.kicks-ass.net) by bombadil.infradead.org with esmtpsa (Exim 4.92 #3 (Red Hat Linux)) id 1hlxLy-0002Dw-U3; Fri, 12 Jul 2019 15:20:55 +0000 Received: by hirez.programming.kicks-ass.net (Postfix, from userid 1000) id DE70D209772EE; Fri, 12 Jul 2019 17:20:52 +0200 (CEST) Date: Fri, 12 Jul 2019 17:20:52 +0200 From: Peter Zijlstra To: Dave Hansen Cc: Alexandre Chartre , Thomas Gleixner , pbonzini@redhat.com, rkrcmar@redhat.com, mingo@redhat.com, bp@alien8.de, hpa@zytor.com, dave.hansen@linux.intel.com, luto@kernel.org, kvm@vger.kernel.org, x86@kernel.org, linux-mm@kvack.org, linux-kernel@vger.kernel.org, konrad.wilk@oracle.com, jan.setjeeilers@oracle.com, liran.alon@oracle.com, jwadams@google.com, graf@amazon.de, rppt@linux.vnet.ibm.com, Paul Turner Subject: Re: [RFC v2 00/27] Kernel Address Space Isolation Message-ID: <20190712152052.GU3419@hirez.programming.kicks-ass.net> References: <1562855138-19507-1-git-send-email-alexandre.chartre@oracle.com> <5cab2a0e-1034-8748-fcbe-a17cf4fa2cd4@intel.com> <61d5851e-a8bf-e25c-e673-b71c8b83042c@oracle.com> <20190712125059.GP3419@hirez.programming.kicks-ass.net> <3626998c-509f-b434-1f66-9db2c09c47d4@intel.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <3626998c-509f-b434-1f66-9db2c09c47d4@intel.com> User-Agent: Mutt/1.10.1 (2018-07-13) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Fri, Jul 12, 2019 at 06:54:22AM -0700, Dave Hansen wrote: > 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. Right, wherever we put the boundary, we need whatever is required to cross it. > > 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. Yes, which is why, in an earlier email, I've asked for a clear definition of 'sensitive" :-) > 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. Right.