From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1755592AbaDWJzV (ORCPT ); Wed, 23 Apr 2014 05:55:21 -0400 Received: from lxorguk.ukuu.org.uk ([81.2.110.251]:54873 "EHLO lxorguk.ukuu.org.uk" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1750890AbaDWJzQ (ORCPT ); Wed, 23 Apr 2014 05:55:16 -0400 Date: Wed, 23 Apr 2014 10:54:11 +0100 From: One Thousand Gnomes To: "H. Peter Anvin" Cc: Andrew Lutomirski , Linus Torvalds , Borislav Petkov , "H. Peter Anvin" , Linux Kernel Mailing List , Ingo Molnar , Alexander van Heukelum , Konrad Rzeszutek Wilk , Boris Ostrovsky , Arjan van de Ven , Brian Gerst , Alexandre Julliard , Andi Kleen , Thomas Gleixner Subject: Re: [PATCH] x86-64: espfix for 64-bit mode *PROTOTYPE* Message-ID: <20140423105411.2e166dd8@alan.etchedpixels.co.uk> In-Reply-To: <5356A3B6.5050901@zytor.com> References: <20140422112312.GB15882@pd.tnic> <20140422144659.GF15882@pd.tnic> <53569467.1030809@zytor.com> <5356A3B6.5050901@zytor.com> Organization: Intel Corporation X-Mailer: Claws Mail 3.8.1 (GTK+ 2.24.20; x86_64-pc-linux-gnu) Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org > Ideally the tests should be doable such that on a normal machine the > tests can be overlapped with the other things we have to do on that > path. The exit branch will be strongly predicted in the negative > direction, so it shouldn't be a significant problem. > > Again, this is not the case in the current prototype. Or you make sure that you switch to those code paths only after software has executed syscalls that make it possible it will use a 16bit ss. The other question I have is - is there any reason we can't fix up the IRET to do a 32bit return into a vsyscall type userspace page which then does a long jump or retf to the right place ? Alan