From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1756876Ab3GQS5P (ORCPT ); Wed, 17 Jul 2013 14:57:15 -0400 Received: from mail-ie0-f178.google.com ([209.85.223.178]:41083 "EHLO mail-ie0-f178.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1756066Ab3GQS5N (ORCPT ); Wed, 17 Jul 2013 14:57:13 -0400 MIME-Version: 1.0 In-Reply-To: References: <20130716183441.GA14232@www.outflux.net> Date: Wed, 17 Jul 2013 11:57:13 -0700 X-Google-Sender-Auth: zb0eHmArJ-SW5x3_THd3TnP7VGw Message-ID: Subject: Re: [tip:x86/urgent] x86: Make sure IDT is page aligned From: Yinghai Lu To: Ingo Molnar , "H. Peter Anvin" , Linux Kernel Mailing List , Kees Cook , PaX Team , Thomas Gleixner , "H. Peter Anvin" Cc: "linux-tip-commits@vger.kernel.org" Content-Type: text/plain; charset=ISO-8859-1 Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Tue, Jul 16, 2013 at 3:33 PM, tip-bot for Kees Cook wrote: > Commit-ID: 4df05f361937ee86e5a8c9ead8aeb6a19ea9b7d7 > Gitweb: http://git.kernel.org/tip/4df05f361937ee86e5a8c9ead8aeb6a19ea9b7d7 > Author: Kees Cook > AuthorDate: Tue, 16 Jul 2013 11:34:41 -0700 > Committer: H. Peter Anvin > CommitDate: Tue, 16 Jul 2013 15:14:48 -0700 > > x86: Make sure IDT is page aligned > > Since the IDT is referenced from a fixmap, make sure it is page aligned. > Merge with 32-bit one, since it was already aligned to deal with F00F > bug. Since bss is cleared before IDT setup, it can live there. This also > moves the other *_idt_table variables into common locations. > > This avoids the risk of the IDT ever being moved in the bss and having > the mapping be offset, resulting in calling incorrect handlers. In the > current upstream kernel this is not a manifested bug, but heavily patched > kernels (such as those using the PaX patch series) did encounter this bug. > > The tables other than idt_table technically do not need to be page > aligned, at least not at the current time, but using a common > declaration avoids mistakes. On 64 bits the table is exactly one page > long, anyway. > > Signed-off-by: Kees Cook > Link: http://lkml.kernel.org/r/20130716183441.GA14232@www.outflux.net > Reported-by: PaX Team > Signed-off-by: H. Peter Anvin Hi, Peter, Any reason for why following changelog get dropped? --- v5: - add comments to all IDTs about alignment reasoning, suggested by Linus v4: - rework using __page_aligned_bss, suggested by Yinghai LU - move all the other IDT variables as well, suggested by HPA v3: - merge 32-bit and 64-bit idt_table definition v2: - 32-bit was already aligned --- That at least would help us to check if you apply the right version. Yinghai