From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752501AbdKXOTG (ORCPT ); Fri, 24 Nov 2017 09:19:06 -0500 Received: from mail.skyhub.de ([5.9.137.197]:34648 "EHLO mail.skyhub.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1750737AbdKXOTF (ORCPT ); Fri, 24 Nov 2017 09:19:05 -0500 Date: Fri, 24 Nov 2017 15:19:00 +0100 From: Borislav Petkov To: Ingo Molnar Cc: linux-kernel@vger.kernel.org, Dave Hansen , Andy Lutomirski , Thomas Gleixner , "H . Peter Anvin" , Peter Zijlstra , Linus Torvalds Subject: Re: [PATCH 11/43] x86/entry/64: Separate cpu_current_top_of_stack from TSS.sp0 Message-ID: <20171124141900.lrxeed3qepxtiyzp@pd.tnic> References: <20171124091448.7649-1-mingo@kernel.org> <20171124091448.7649-12-mingo@kernel.org> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline In-Reply-To: <20171124091448.7649-12-mingo@kernel.org> User-Agent: NeoMutt/20170609 (1.8.3) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Fri, Nov 24, 2017 at 10:14:16AM +0100, Ingo Molnar wrote: > From: Andy Lutomirski > > On 64-bit kernels, we used to assume that TSS.sp0 was the current > top of stack. With the addition of an entry trampoline, this will > no longer be the case. Store the current top of stack in TSS.sp1, > which is otherwise unused but shares the same cacheline. > > Signed-off-by: Andy Lutomirski > Reviewed-by: Thomas Gleixner > Cc: Borislav Petkov > Cc: Borislav Petkov > Cc: Brian Gerst > Cc: Dave Hansen > Cc: Denys Vlasenko > Cc: H. Peter Anvin > Cc: Josh Poimboeuf > Cc: Linus Torvalds > Cc: Peter Zijlstra > Link: http://lkml.kernel.org/r/f56634c746a2926eb7bae61e7b80ed51a1940769.1511497875.git.luto@kernel.org > Signed-off-by: Ingo Molnar > --- > arch/x86/include/asm/processor.h | 18 +++++++++++++----- > arch/x86/include/asm/thread_info.h | 2 +- > arch/x86/kernel/asm-offsets_64.c | 1 + > arch/x86/kernel/process.c | 10 ++++++++++ > arch/x86/kernel/process_64.c | 1 + > 5 files changed, 26 insertions(+), 6 deletions(-) Reviewed-by: Borislav Petkov -- Regards/Gruss, Boris. Good mailing practices for 400: avoid top-posting and trim the reply.