From mboxrd@z Thu Jan 1 00:00:00 1970 From: Arjan van de Ven Subject: Re: [RFC 04/10] x86/mm: Only flush indirect branches when switching into non dumpable process Date: Sun, 21 Jan 2018 08:25:36 -0800 Message-ID: References: <1516476182-5153-1-git-send-email-karahmed@amazon.de> <1516476182-5153-5-git-send-email-karahmed@amazon.de> <20180121112224.GH2269@hirez.programming.kicks-ass.net> <20180121162142.yh366un2blsyiud4@gmail.com> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 7bit Cc: KarimAllah Ahmed , linux-kernel@vger.kernel.org, Andi Kleen , Andrea Arcangeli , Andy Lutomirski , Ashok Raj , Asit Mallick , Borislav Petkov , Dan Williams , Dave Hansen , David Woodhouse , Greg Kroah-Hartman , "H . Peter Anvin" , Ingo Molnar , Janakarajan Natarajan , Joerg Roedel , Jun Nakajima , Laura Abbott , Linus Torvalds , Masami Hiramatsu , To: Ingo Molnar , Peter Zijlstra Return-path: In-Reply-To: <20180121162142.yh366un2blsyiud4@gmail.com> Content-Language: en-US Sender: linux-kernel-owner@vger.kernel.org List-Id: kvm.vger.kernel.org On 1/21/2018 8:21 AM, Ingo Molnar wrote: > > > So if it's only about the scheduler barrier, what cycle cost are we talking about > here? > in the order of 5000 to 10000 cycles. (depends a bit on the cpu generation but this range is a reasonable approximation) > Because putting something like this into an ELF flag raises the question of who is > allowed to set the flag - does a user-compiled binary count? If yes then it would > be a trivial thing for local exploits to set the flag and turn off the barrier. the barrier is about who you go TO, e.g. the thing under attack. as you say, depending on the thing that would be the evil one does not work.