Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S935041Ab0GOXnF (ORCPT ); Thu, 15 Jul 2010 19:43:05 -0400 Received: from terminus.zytor.com ([198.137.202.10]:37873 "EHLO mail.zytor.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S935022Ab0GOXnE (ORCPT ); Thu, 15 Jul 2010 19:43:04 -0400 Message-ID: <4C3F9CBB.3080300@zytor.com> Date: Thu, 15 Jul 2010 16:41:47 -0700 From: "H. Peter Anvin" User-Agent: Mozilla/5.0 (X11; U; Linux x86_64; en-US; rv:1.9.1.10) Gecko/20100621 Fedora/3.0.5-1.fc13 Thunderbird/3.0.5 MIME-Version: 1.0 To: Linus Torvalds CC: Andi Kleen , Mathieu Desnoyers , LKML , Andrew Morton , Ingo Molnar , Peter Zijlstra , Steven Rostedt , Steven Rostedt , Frederic Weisbecker , Thomas Gleixner , Christoph Hellwig , Li Zefan , Lai Jiangshan , Johannes Berg , Masami Hiramatsu , Arnaldo Carvalho de Melo , Tom Zanussi , KOSAKI Motohiro , Jeremy Fitzhardinge , "Frank Ch. Eigler" , Tejun Heo Subject: Re: [patch 1/2] x86_64 page fault NMI-safe References: <20100714222115.GA30122@Krystal> <20100715183153.GA9276@Krystal> <20100715220117.GA1499@Krystal> <20100715225844.GA25420@one.firstfloor.org> <4C3F97A5.4020107@zytor.com> In-Reply-To: Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1048 Lines: 30 On 07/15/2010 04:23 PM, Linus Torvalds wrote: > On Thu, Jul 15, 2010 at 4:20 PM, H. Peter Anvin wrote: >> On 07/15/2010 03:58 PM, Andi Kleen wrote: >>>> Why do we force IST use for NMI, btw? Maybe we shouldn't, and just use >>>> the normal kernel stack mechanisms? >>> >>> If you don't use IST the SYSCALL entry is racy during the window >>> when RSP is not set up yet (same for MCE etc.) >>> >> >> Right, the kernel stack is not ready. > > Well, it may not be ready for the _current_ NMI handler, but if we're > going to do a stack switch in sw on NMI anyway... ? > No, the problem is that without IST it'll try to drop the NMI stack frame itself *on the user stack*. -hpa -- H. Peter Anvin, Intel Open Source Technology Center I work for Intel. I don't speak on their behalf. -- 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/