From: Sebastian Andrzej Siewior Subject: Re: [RFC PATCH 04/10 v2 ] x86/fpu: eager switch PKRU state Date: Tue, 18 Sep 2018 18:04:20 +0200 Message-ID: <20180918160419.2zeru6xnufxixcax@linutronix.de> References: <20180912133353.20595-1-bigeasy@linutronix.de> <20180912133353.20595-5-bigeasy@linutronix.de> <8e5b64e4-b3e6-f884-beb6-b7b69ab2d8c1@redhat.com> <20180914203501.qibhpmueosvkr74w@linutronix.de> <20180918142701.atfb4ul45k7tl6ew@linutronix.de> <7e9a13f3-93f5-fe4a-20d2-f4f9407bd43b@redhat.com> <83e271e1298d603c1105dd0dbea32d67da9cf1fa.camel@surriel.com> <36e8493f-f994-e885-8fe6-2f0d4a9904a1@redhat.com> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Cc: Rik van Riel , linux-kernel@vger.kernel.org, x86@kernel.org, Andy Lutomirski , Radim =?utf-8?B?S3LEjW3DocWZ?= , kvm@vger.kernel.org, "Jason A. Donenfeld" To: Paolo Bonzini Return-path: Content-Disposition: inline In-Reply-To: <36e8493f-f994-e885-8fe6-2f0d4a9904a1@redhat.com> Sender: linux-kernel-owner@vger.kernel.org List-Id: kvm.vger.kernel.org On 2018-09-18 17:29:52 [+0200], Paolo Bonzini wrote: > > I don't think it matters what the PKRU state is > > for kernel threads, since kernel PTEs should not > > be using protection keys anyway. > > What about copy_from/to_user? This doesn't work for a kernel thread, does it? I mean they share the init's MM and never do copy_{from|to}_user. > Paolo Sebastian