Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S271312AbTHIBrA (ORCPT ); Fri, 8 Aug 2003 21:47:00 -0400 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S271885AbTHIBrA (ORCPT ); Fri, 8 Aug 2003 21:47:00 -0400 Received: from mail.suse.de ([213.95.15.193]:7432 "EHLO Cantor.suse.de") by vger.kernel.org with ESMTP id S271312AbTHIBq7 (ORCPT ); Fri, 8 Aug 2003 21:46:59 -0400 Date: Sat, 9 Aug 2003 03:46:55 +0200 (CEST) From: Andreas Gruenbacher To: Herbert Xu Cc: Marcelo Tosatti , Alan Cox , Linux Kernel Mailing List Subject: Re: [PATCH] 2.4: Fix steal_locks race In-Reply-To: <20030809010736.GA10487@gondor.apana.org.au> Message-ID: References: <20030808105321.GA5096@gondor.apana.org.au> <20030809010736.GA10487@gondor.apana.org.au> 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: 1085 Lines: 33 Hello, thanks a lot for analyzing this. Please see the patch I just posted unter the subject: [PATCH] 2.4.22-rc2 steal_locks and load_elf_binary cleanups That patch fixes the bug in a slightly cleaner way. On Sat, 9 Aug 2003, Herbert Xu wrote: > On Fri, Aug 08, 2003 at 08:53:21PM +1000, herbert wrote: > > > > The steal_locks() call in binfmt_elf.c is buggy. It steals locks from > > a files entry whose reference was dropped much earlier. This allows it > > to steal other process's locks. This makes sense. > > The following patch calls steal_locks() earlier so that this does not > > happen. > > My patch is buggy too. If a file is closed by another clone between > the two steal_locks calls the lock will again be lost. Fortunately > this much harder to trigger than the previous bug. > > The following patch fixes that. > - 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/