From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751479Ab0FBEhA (ORCPT ); Wed, 2 Jun 2010 00:37:00 -0400 Received: from smtp1.linux-foundation.org ([140.211.169.13]:43270 "EHLO smtp1.linux-foundation.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751322Ab0FBEg6 (ORCPT ); Wed, 2 Jun 2010 00:36:58 -0400 Date: Tue, 1 Jun 2010 21:32:19 -0700 (PDT) From: Linus Torvalds To: Rusty Russell cc: Andrew Morton , Brandon Philips , "Rafael J. Wysocki" , LKML , Jon Masters , Tejun Heo , Masami Hiramatsu , Kay Sievers Subject: Re: [PATCH 2/2] module: fix bne2 "gave up waiting for init of module libcrc32c" In-Reply-To: <201006021239.42006.rusty@rustcorp.com.au> Message-ID: References: <201005252300.07739.rjw@sisk.pl> <201006011452.06843.rusty@rustcorp.com.au> <201006021239.42006.rusty@rustcorp.com.au> User-Agent: Alpine 2.00 (LFD 1167 2008-08-23) MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Wed, 2 Jun 2010, Rusty Russell wrote: > > > I would like to note that your original "fix things by dropping the lock" > > patch that I hated so much had this exact bug too. Making this a good > > example of _why_ it's basically always wrong to drop locks in the middle - > > even if you claimed you knew and understood the locking. > > And I would like to note that it didn't :) It grabbed references only on > completed modules. Right you are, I misread the patch. You re-did the whole module lookup, something that the original code didn't do. And yes, that should be safe. Linus