From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754040AbdKABIg (ORCPT ); Tue, 31 Oct 2017 21:08:36 -0400 Received: from mga02.intel.com ([134.134.136.20]:47049 "EHLO mga02.intel.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751478AbdKABIf (ORCPT ); Tue, 31 Oct 2017 21:08:35 -0400 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.44,326,1505804400"; d="scan'208";a="169717603" Subject: Re: [PATCH 01/23] x86, kaiser: prepare assembly for entry/exit CR3 switching To: Brian Gerst References: <20171031223146.6B47C861@viggo.jf.intel.com> <20171031223148.5334003A@viggo.jf.intel.com> Cc: Linux Kernel Mailing List , Linux-MM , moritz.lipp@iaik.tugraz.at, daniel.gruss@iaik.tugraz.at, michael.schwarz@iaik.tugraz.at, Andy Lutomirski , Linus Torvalds , Kees Cook , hughd@google.com, the arch/x86 maintainers From: Dave Hansen Message-ID: Date: Tue, 31 Oct 2017 18:08:33 -0700 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.4.0 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset=utf-8 Content-Language: en-US Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 10/31/2017 05:43 PM, Brian Gerst wrote: >> >> + RESTORE_CR3 save_reg=%r14 >> + >> testl %ebx, %ebx /* swapgs needed? */ >> jnz nmi_restore >> nmi_swapgs: >> _ > This all needs to be conditional on a config option. Something with > this amount of performance impact needs to be 100% optional. The 07/23 patch does just this. I should have at least called that out in the description.