From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752345AbdKZPle (ORCPT ); Sun, 26 Nov 2017 10:41:34 -0500 Received: from mail.kernel.org ([198.145.29.99]:49810 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752213AbdKZPlc (ORCPT ); Sun, 26 Nov 2017 10:41:32 -0500 DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 617422197C Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=kernel.org Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=luto@kernel.org X-Google-Smtp-Source: AGs4zMZX9M2i5RTnn6IUFr6KO4BGEvFPDZbvvxVv1JXoGp8oXNMPZkAGa71EjZIGP5nMvuGNRzSjNY497L4P82bulY4= MIME-Version: 1.0 In-Reply-To: <20171126134844.o4nz6kuuzsflxrw6@gmail.com> References: <03fb20a8639aeecfeda3ba18a520ce646267eb9a.1510371795.git.luto@kernel.org> <2fdf9cf9-ec48-e63f-2ec8-44160c206c9a@intel.com> <20171126134844.o4nz6kuuzsflxrw6@gmail.com> From: Andy Lutomirski Date: Sun, 26 Nov 2017 07:41:11 -0800 X-Gmail-Original-Message-ID: Message-ID: Subject: Re: [PATCH v2] x86/entry: Fix assumptions that the HW TSS is at the beginning of cpu_tss To: Ingo Molnar Cc: Dave Hansen , Andy Lutomirski , X86 ML , Borislav Petkov , "linux-kernel@vger.kernel.org" , Brian Gerst , Linus Torvalds Content-Type: text/plain; charset="UTF-8" Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Sun, Nov 26, 2017 at 5:48 AM, Ingo Molnar wrote: > > * Dave Hansen wrote: > >> On 11/10/2017 08:05 PM, Andy Lutomirski wrote: >> > -struct tss_struct doublefault_tss __cacheline_aligned = { >> > - .x86_tss = { >> > - .sp0 = STACK_START, >> > - .ss0 = __KERNEL_DS, >> > - .ldt = 0, >> ... >> > +struct x86_hw_tss doublefault_tss __cacheline_aligned = { >> > + .sp0 = STACK_START, >> > + .ss0 = __KERNEL_DS, >> > + .ldt = 0, >> > + .io_bitmap_base = INVALID_IO_BITMAP_OFFSET, >> >> FWIW, I really like the trend of renaming the hardware structures in >> such a way that it's clear that they *are* hardware structures. >> >> It might also be nice to reference the relevant SDM sections on the >> topic, or even to include a comment along the lines of how it get used. >> This chunk from the SDM is particularly relevant: >> >> "The TSS holds information important to 64-bit mode and that is not >> directly related to the task-switch mechanism." > > That makes sense - I've updated this patch with the following description added to > struct x86_hw_tss: I've folded this in along with all the reviews so far, and a few misc fixes from Boris' review. I was planning to resend the whole series today after I track down the kbuild error. Does that sound good?