From: Benjamin Herrenschmidt <benh@kernel.crashing.org>
To: Alan Cox <alan@lxorguk.ukuu.org.uk>
Cc: <linux-kernel@vger.kernel.org>
Subject: Re: VFS locking & HFS problems (2.4.6pre6)
Date: Fri, 29 Jun 2001 18:10:52 +0200 [thread overview]
Message-ID: <20010629161052.15124@smtp.adsl.oleane.com> (raw)
In-Reply-To: <E15G08g-0000UO-00@the-village.bc.nu>
In-Reply-To: <E15G08g-0000UO-00@the-village.bc.nu>
Alan Cox wrote:
>Holding a spinlock while sleeping is an offence punishable by deadlock..
Right, and it's indeed the problem. But I'm still concerned about
locking since by using that spinlock, the guy who wrote it did
not expect beeing re-entered at this point, and just "cleaning" it
may not be enough.
>You might also look for memory allocations that are not GFP_ATOMIC made with
>the lock held
Yup. It's the problem. It locks, then calls some alloc routines, which
fills a cache and uses kmalloc with GFP_KERNEL.
Turning it into GFP_ATOMIC might not be the best idea as the HFS
filesystem currently shares a single hfs_malloc() for everybody and
turning it into GFP_ATOMIC would cause all of HFS allocs to be atomic.
I can change this single routine (and any other doing the same thing),
but I'd rather fix it by making sure HFS can safely sleep at this
point and still use GFP_KERNEL.
I just found Documentations/filesystems/Locking document, I bet I'll
find all the infos I need there. It's amazing how long it took me
to look for the info where it logically should be ;)
Ben.
next parent reply other threads:[~2001-06-29 16:11 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <E15G08g-0000UO-00@the-village.bc.nu>
2001-06-29 16:10 ` Benjamin Herrenschmidt [this message]
2001-06-29 16:29 ` Alan Cox
2001-06-29 15:09 Benjamin Herrenschmidt
2001-06-29 15:52 ` Andrew Morton
2001-06-29 19:53 ` 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=20010629161052.15124@smtp.adsl.oleane.com \
--to=benh@kernel.crashing.org \
--cc=alan@lxorguk.ukuu.org.uk \
--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®