From mboxrd@z Thu Jan 1 00:00:00 1970 From: Al Viro Subject: Re: [PATCH 1/2] do_execve() must not clear fs->in_exec if it was set by another thread Date: Fri, 24 Apr 2009 00:31:57 +0100 Message-ID: <20090423233157.GA22981@ZenIV.linux.org.uk> References: <20090401023849.GW28946@ZenIV.linux.org.uk> <20090401030339.GX28946@ZenIV.linux.org.uk> <20090406153127.GA21220@redhat.com> <20090421161006.GC5402@redhat.com> <20090421171530.GA12014@redhat.com> <20090423230156.GA31302@redhat.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Cc: Hugh Dickins , Linus Torvalds , Andrew Morton , Joe Malicki , Michael Itz , Kenneth Baker , Chris Wright , David Howells , Alexey Dobriyan , Greg Kroah-Hartman , linux-fsdevel@vger.kernel.org, linux-kernel@vger.kernel.org, Roland McGrath To: Oleg Nesterov Return-path: Received: from zeniv.linux.org.uk ([195.92.253.2]:44926 "EHLO ZenIV.linux.org.uk" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752328AbZDWXd3 (ORCPT ); Thu, 23 Apr 2009 19:33:29 -0400 Content-Disposition: inline In-Reply-To: <20090423230156.GA31302@redhat.com> Sender: linux-fsdevel-owner@vger.kernel.org List-ID: On Fri, Apr 24, 2009 at 01:01:56AM +0200, Oleg Nesterov wrote: > If do_execve() fails after check_unsafe_exec(), it clears fs->in_exec > unconditionally. This is wrong if we race with our sub-thread which > also does do_execve: [snip] Applied (both of those).