Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S261467AbVBWPxk (ORCPT ); Wed, 23 Feb 2005 10:53:40 -0500 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S261445AbVBWPxj (ORCPT ); Wed, 23 Feb 2005 10:53:39 -0500 Received: from fire.osdl.org ([65.172.181.4]:36517 "EHLO smtp.osdl.org") by vger.kernel.org with ESMTP id S261486AbVBWPxg (ORCPT ); Wed, 23 Feb 2005 10:53:36 -0500 Date: Wed, 23 Feb 2005 07:54:06 -0800 (PST) From: Linus Torvalds To: Joe Korty cc: Jamie Lokier , Andrew Morton , Olof Johansson , linux-kernel@vger.kernel.org, rusty@rustcorp.com.au Subject: Re: [PATCH/RFC] Futex mmap_sem deadlock In-Reply-To: <20050223144940.GA880@tsunami.ccur.com> Message-ID: References: <20050222190646.GA7079@austin.ibm.com> <20050222115503.729cd17b.akpm@osdl.org> <20050222210752.GG22555@mail.shareable.org> <20050223144940.GA880@tsunami.ccur.com> MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Sender: linux-kernel-owner@vger.kernel.org X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 804 Lines: 23 On Wed, 23 Feb 2005, Joe Korty wrote: > > Perhaps this should be preempt_disable .... preempt_enable. No, the problem with preempt_disable/enable is that they go away if preemption is not enabled. So you really do have to do it by hand with the "inc_preempt_count". > Otherwise, a preempt attempt in get_user would not be seen > until some future preempt_enable was executed. True. I guess we should have a "preempt_check_resched()" there too. That's what "kunmap_atomic()" does too (which is what we rely on in the other case we do this..) 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/