Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754792AbbGPCj2 (ORCPT ); Wed, 15 Jul 2015 22:39:28 -0400 Received: from mail-ig0-f173.google.com ([209.85.213.173]:34438 "EHLO mail-ig0-f173.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752754AbbGPCj0 (ORCPT ); Wed, 15 Jul 2015 22:39:26 -0400 MIME-Version: 1.0 In-Reply-To: <55A6FC31.5010102@linux.intel.com> References: <1430848300-27877-1-git-send-email-mingo@kernel.org> <1430848300-27877-19-git-send-email-mingo@kernel.org> <55A56709.6020201@linux.intel.com> <20150715110726.GA26611@gmail.com> <55A6FC31.5010102@linux.intel.com> Date: Wed, 15 Jul 2015 19:39:26 -0700 X-Google-Sender-Auth: 1pXZ5-nypHrp3x9-Mt891W7SJjs Message-ID: Subject: Re: [REGRESSION] 4.2-rc2: early boot memory corruption from FPU rework From: Linus Torvalds To: Dave Hansen Cc: Ingo Molnar , Linux Kernel Mailing List , Andy Lutomirski , Borislav Petkov , Fenghua Yu , "H. Peter Anvin" , Oleg Nesterov , Thomas Gleixner , Ross Zwisler Content-Type: text/plain; charset=UTF-8 Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1203 Lines: 27 On Wed, Jul 15, 2015 at 5:34 PM, Dave Hansen wrote: > > The old code sized the buffer in a fully architectural way and it > worked. The CPU *tells* you how much memory the 'xsave' instruction is > going to scribble on. The new code just merrily calls it and let it > scribble away. This is as clear-cut a regression as I've ever seen. Yes, I think we'll need to revert it, or do something else drastic like make that initial fp state allocation *much* bigger and then have a "disable xsaves if if it's still not big enough". setup_xstate_features() should be able to easily just say "this was the maximum offset+size we saw", and we can take that to either do a proper allocation, or verify that the static allocation is indeed big enough. Apparently a straight revert doesn't work, if only because things in that area have been renamed very aggressively (both files and functions and variables). Ingo? Linus -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/