From: Ryan Cumming <bodnar42@phalynx.dhs.org>
To: "David C. Hansen" <haveblue@us.ibm.com>
Cc: linux-kernel@vger.kernel.org
Subject: Re: [RFC] Change locking in block_dev.c:do_open()
Date: Wed, 12 Dec 2001 17:01:43 -0800 [thread overview]
Message-ID: <E16EKFr-000305-00@phalynx> (raw)
In-Reply-To: <3C17F8B2.6080700@us.ibm.com>
In-Reply-To: <3C17F8B2.6080700@us.ibm.com>
On December 12, 2001 16:39, David C. Hansen wrote:
> Let's assume that the BKL is not held here, at least over the whole
> thing. First, what do we need to do to keep the module from getting
> unloaded after the request_module() in get_blkfops()?
>
> We can add a semaphore which must be acquired before a module can be
> unloaded, and hold it over the area where the module must not be
> unloaded. We could replace the unload_lock spinlock with a semaphore,
> which I'll call it unload_sem here. It would look something like this:
Why not use a read-write semaphore? The sections that require the module to
stay resident use a read lock, and module unloading aquires a write lock. In
addition to containing the evil, evil BKL, you might actually get a tangiable
scalability gain out of it.
-Ryan
next prev parent reply other threads:[~2001-12-13 1:02 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2001-12-13 0:39 [RFC] Change locking in block_dev.c:do_open() David C. Hansen
2001-12-13 1:01 ` Ryan Cumming [this message]
2001-12-13 2:33 ` David C. Hansen
2001-12-13 2:16 ` Alexander Viro
2001-12-13 15:42 ` Roman Zippel
2001-12-13 17:24 ` Richard Gooch
2001-12-13 17:47 ` Alexander Viro
2001-12-13 18:26 ` Richard Gooch
[not found] ` <Pine.GSO.4.21.0112140318290.22724-100000@weyl.math.psu.edu>
2001-12-14 17:07 ` Richard Gooch
-- strict thread matches above, loose matches on Subject: below --
2001-12-13 2:40 Torrey Hoffman
2001-12-13 2:49 ` Ryan Cumming
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=E16EKFr-000305-00@phalynx \
--to=bodnar42@phalynx.dhs.org \
--cc=haveblue@us.ibm.com \
--cc=linux-kernel@vger.kernel.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox