From: torvalds@transmeta.com (Linus Torvalds)
To: linux-kernel@vger.kernel.org
Subject: Re: lock_kernel() usage and sync_*() functions
Date: 21 Mar 2001 19:42:44 -0800 [thread overview]
Message-ID: <99bsbk$a6n$1@penguin.transmeta.com> (raw)
In-Reply-To: <Pine.LNX.4.05.10103211901070.705-100000@cosmic.nrg.org>
In article <Pine.LNX.4.05.10103211901070.705-100000@cosmic.nrg.org>,
Nigel Gamble <nigel@nrg.org> wrote:
>
>Why is the kernel lock held around sync_supers() and sync_inodes() in
>sync_old_buffers() and fsync_dev(), but not in sync_dev()? Is it just
>to serialize calls to these functions, or is there some other reason?
A lot of the FS locks need the kernel lock and are not SMP-safe on their
own. Look at "lock_super()" for the worst offender (I think most of the
other ones have been converted to properly lock on SMP).
sync_inodes() _shouldn't_ need it. sync_supers() definitely does.
The fact that sync_dev() doesn't get the kernel lock looks worrisome.
Of course, I don't think much of anything actually _uses_ "sync_dev()"
anyway (quick grep shows it up in revalidate, which gets the kernel lock
earlier)
But it might be a good idea to try to (a) remove the bkl from the
functions, and push it down into sync_supers() that definitely needs it
now (and remove it when it doesn't any more).
The long-term plan (ie 2.5.x) is to basically remove the bkl from all
the VFS interfaces. For 2.4.x, only the truly performance-critical stuff
was done (ie mainly name lookup and read/write page).
Linus
next prev parent reply other threads:[~2001-03-22 3:43 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2001-03-22 3:11 Nigel Gamble
2001-03-22 3:42 ` Linus Torvalds [this message]
2001-03-22 5:18 ` Alexander Viro
2001-03-22 14:45 ` Ingo Oeser
2001-03-22 17:20 ` Alexander Viro
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='99bsbk$a6n$1@penguin.transmeta.com' \
--to=torvalds@transmeta.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
all inboxes | Powered by JetHome®