Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751988AbdFUNkG (ORCPT ); Wed, 21 Jun 2017 09:40:06 -0400 Received: from Galois.linutronix.de ([146.0.238.70]:50067 "EHLO Galois.linutronix.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1750992AbdFUNkF (ORCPT ); Wed, 21 Jun 2017 09:40:05 -0400 Date: Wed, 21 Jun 2017 15:40:01 +0200 (CEST) From: Thomas Gleixner To: Andy Lutomirski cc: x86@kernel.org, linux-kernel@vger.kernel.org, Borislav Petkov , Linus Torvalds , Andrew Morton , Mel Gorman , "linux-mm@kvack.org" , Nadav Amit , Rik van Riel , Dave Hansen , Arjan van de Ven , Peter Zijlstra , Juergen Gross , Boris Ostrovsky Subject: Re: [PATCH v3 10/11] x86/mm: Enable CR4.PCIDE on supported systems In-Reply-To: Message-ID: References: <57c1d18b1c11f9bc9a3bcf8bdee38033415e1a13.1498022414.git.luto@kernel.org> User-Agent: Alpine 2.20 (DEB 67 2015-01-07) MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 470 Lines: 16 On Wed, 21 Jun 2017, Thomas Gleixner wrote: > On Tue, 20 Jun 2017, Andy Lutomirski wrote: > > + /* Set up PCID */ > > + if (cpu_has(c, X86_FEATURE_PCID)) { > > + if (cpu_has(c, X86_FEATURE_PGE)) { > > + cr4_set_bits(X86_CR4_PCIDE); > > So I assume that you made sure that the PCID bits in CR3 are zero under all > circumstances as setting PCIDE would cause a #GP if not. And what happens on kexec etc? We need to reset the asid and PCIDE I assume. Thanks, tglx