From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752739AbdFMGtc (ORCPT ); Tue, 13 Jun 2017 02:49:32 -0400 Received: from mail-wr0-f196.google.com ([209.85.128.196]:34155 "EHLO mail-wr0-f196.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752566AbdFMGta (ORCPT ); Tue, 13 Jun 2017 02:49:30 -0400 Date: Tue, 13 Jun 2017 08:49:26 +0200 From: Ingo Molnar To: Andy Lutomirski Cc: x86@kernel.org, linux-kernel@vger.kernel.org, Borislav Petkov , Tom Lendacky , Juergen Gross , xen-devel , Boris Ostrovsky Subject: Re: [PATCH] x86/mm: Split read_cr3() into read_cr3_pa() and __read_cr3() Message-ID: <20170613064926.pfyxhkfaauwdafqf@gmail.com> References: <883f8fb121f4616c1c1427ad87350bb2f5ffeca1.1497288170.git.luto@kernel.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <883f8fb121f4616c1c1427ad87350bb2f5ffeca1.1497288170.git.luto@kernel.org> User-Agent: NeoMutt/20170113 (1.7.2) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org * Andy Lutomirski wrote: > The kernel has several code paths that read CR3. Most of them assume that > CR3 contains the PGD's physical address, whereas some of them awkwardly > use PHYSICAL_PAGE_MASK to mask off low bits. > > Add explicit mask macros for CR3 and convert all of the CR3 readers. > This will keep them from breaking when PCID is enabled. > > Cc: Tom Lendacky > Cc: Juergen Gross > Cc: xen-devel > Cc: Boris Ostrovsky > Signed-off-by: Andy Lutomirski > --- > > Hi Ingo- > > I broke this out because Tom's SME series and my PCID series both need it. > Please consider applying it to tip:x86/mm. > > I'll send PCID v2 soon. It'll apply to x86/mm + sched/urgent + this patch. Ok, thanks - will push it out after a bit of testing. Note that I also merged sched/urgent into x86/mm, to create a better base tree for the PCID changes by picking up 252d2a4117bc that PCID depends on. Thanks, Ingo