[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <alpine.DEB.2.21.1811230000590.1665@nanos.tec.linutronix.de>
Date: Fri, 23 Nov 2018 00:04:22 +0100 (CET)
From: Thomas Gleixner <tglx@...utronix.de>
To: Ingo Molnar <mingo@...nel.org>
cc: LKML <linux-kernel@...r.kernel.org>, x86@...nel.org,
Peter Zijlstra <peterz@...radead.org>,
Andy Lutomirski <luto@...nel.org>,
Linus Torvalds <torvalds@...ux-foundation.org>,
Jiri Kosina <jkosina@...e.cz>,
Tom Lendacky <thomas.lendacky@....com>,
Josh Poimboeuf <jpoimboe@...hat.com>,
Andrea Arcangeli <aarcange@...hat.com>,
David Woodhouse <dwmw@...zon.co.uk>,
Andi Kleen <ak@...ux.intel.com>,
Dave Hansen <dave.hansen@...el.com>,
Casey Schaufler <casey.schaufler@...el.com>,
Asit Mallick <asit.k.mallick@...el.com>,
Arjan van de Ven <arjan@...ux.intel.com>,
Jon Masters <jcm@...hat.com>,
Waiman Long <longman9394@...il.com>,
Greg KH <gregkh@...uxfoundation.org>,
Dave Stewart <david.c.stewart@...el.com>,
Kees Cook <keescook@...omium.org>
Subject: Re: [patch 20/24] x86/speculation: Split out TIF update
On Thu, 22 Nov 2018, Ingo Molnar wrote:
> * Thomas Gleixner <tglx@...utronix.de> wrote:
>
> Had to read this twice, because the comment and the code are both correct
> but deal with the inverse case. This might have helped:
>
> /*
> * Immediately update the speculation MSRs on the current task,
> * but for non-current tasks delay setting the CPU mitigation
> * until it is scheduled next.
> */
> if (tsk == current && update)
> speculation_ctrl_update_current();
>
> But can the target task ever be non-current here? I don't think so: the
> two callers are prctl and seccomp, and both are passing in the current
> task pointer.
See te other mail. Yes, seccomp passes non current task pointers. Will
update the comment.
Thanks,
tglx
Powered by blists - more mailing lists