[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20180130174850.bwypk4r5yn2344jb@treble>
Date: Tue, 30 Jan 2018 11:48:50 -0600
From: Josh Poimboeuf <jpoimboe@...hat.com>
To: David Woodhouse <dwmw@...zon.co.uk>
Cc: arjan@...ux.intel.com, tglx@...utronix.de, karahmed@...zon.de,
x86@...nel.org, linux-kernel@...r.kernel.org,
tim.c.chen@...ux.intel.com, bp@...en8.de, peterz@...radead.org,
pbonzini@...hat.com, ak@...ux.intel.com,
torvalds@...ux-foundation.org, gregkh@...ux-foundation.org,
mingo@...nel.org, luto@...nel.org, linux@...inikbrodowski.net
Subject: Re: [PATCH] x86/speculation: Use Indirect Branch Prediction Barrier
in context switch
On Mon, Jan 29, 2018 at 10:04:47PM +0000, David Woodhouse wrote:
> From: Tim Chen <tim.c.chen@...ux.intel.com>
>
> Flush indirect branches when switching into a process that marked itself
> non dumpable. This protects high value processes like gpg better,
> without having too high performance overhead.
I wonder what the point of this patch is. An audit of my laptop shows
only a single user of PR_SET_DUMPABLE: systemd-coredump.
[ And yes, I have gpg-agent running. Also, a grep of the gnupg source
doesn't show any evidence of it being used there. So the gpg thing
seems to be a myth. ]
But also, I much preferred the original version of the patch which only
skipped IBPB when 'prev' could ptrace 'next'.
If performance is a concern, let's look at that in more detail. But I
don't see how the solution to a performance issue could possibly be
"leave (almost) all tasks vulnerable by default."
If the argument is that everyone should "rebuild the world" with
retpolines, then this patch would still be pointless, as we wouldn't
even need IBPB.
--
Josh
Powered by blists - more mailing lists