From: Greg KH <greg@kroah.com>
To: Rusty Russell <rusty@rustcorp.com.au>
Cc: Linus Torvalds <torvalds@linux-foundation.org>,
Herbert Xu <herbert@gondor.hengli.com.au>,
linux-kernel@vger.kernel.org, Brandon Philips <brandon@ifup.org>,
stable@kernel.org
Subject: Re: [stable] [PATCH] module: drop the lock while waiting for module to complete initialization.
Date: Tue, 20 Apr 2010 06:22:11 -0700 [thread overview]
Message-ID: <20100420132211.GA27374@kroah.com> (raw)
In-Reply-To: <201004201849.04960.rusty@rustcorp.com.au>
On Tue, Apr 20, 2010 at 06:49:04PM +0930, Rusty Russell wrote:
> This fixes "gave up waiting for init of module libcrc32c." which
> happened at boot time due to multiple parallel module loads.
>
> The problem was a deadlock: we wait for a module to finish
> initializing, but we keep the module_lock mutex so it can't complete.
> In particular, this could reasonably happen if a module does a
> request_module() in its initialization routine.
>
> So we change use_module() to return an errno rather than a bool, and if
> it's -EBUSY we drop the lock and wait in the caller, then reaquire the
> lock.
>
> Reported-by: Brandon Philips <brandon@ifup.org>
> Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
> Tested-by: Brandon Philips <brandon@ifup.org>
> ---
If you wish to have patches included "automatically" in the stable
kernel releases, just add:
Cc: stable <stable@kernel.org>
to the signed-off-by area of your patch. Then, when the patch goes into
Linus's tree, I get notified of it and can trivially add it to the
proper kernel trees.
Otherwise I need to go dig through git and watch to see if/when the
patch shows up there or not, which takes a lot of time when having to do
it for a lot of patches.
thanks,
greg k-h
prev parent reply other threads:[~2010-04-20 13:22 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-04-20 9:19 [PATCH] module: drop the lock while waiting for module to complete initialization Rusty Russell
2010-04-20 13:22 ` Greg KH [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20100420132211.GA27374@kroah.com \
--to=greg@kroah.com \
--cc=brandon@ifup.org \
--cc=herbert@gondor.hengli.com.au \
--cc=linux-kernel@vger.kernel.org \
--cc=rusty@rustcorp.com.au \
--cc=stable@kernel.org \
--cc=torvalds@linux-foundation.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.