linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Linus Torvalds <torvalds@transmeta.com>
To: Steve Lord <lord@sgi.com>
Cc: Marcelo Tosatti <marcelo@conectiva.com.br>,
	lkml <linux-kernel@vger.kernel.org>
Subject: Re: Bounce buffer deadlock
Date: Sat, 30 Jun 2001 10:39:59 -0700 (PDT)	[thread overview]
Message-ID: <Pine.LNX.4.33.0106301032170.1470-100000@penguin.transmeta.com> (raw)
In-Reply-To: <200106301734.f5UHYML03030@jen.americas.sgi.com>


On Sat, 30 Jun 2001, Steve Lord wrote:
>
> It looks to me as if all memory allocations of type GFP_BUFFER which happen
> in generic_make_request downwards can hit the same type of deadlock, so
> bounce buffers, the request functions of the raid and lvm paths can all
> end up in try_to_free_buffers on a buffer they themselves hold the lock on.

.. which is why GFP_BUFFER doesn't exist any more in the most recent
pre-kernels (oops, this is pre8 only, not pre7 like I said in the previous
email)

The problem is that GFP_BUFFER used to mean two things: "don't call
low-level filesystem" and "don't do IO". Some of the pre-kernels starting
to make it mean "don't call low-level FS" only. The later ones split up
the semantics, so that the cases which care about FS deadlocks use
"GFP_NOFS", and the cases that care about IO recursion use "GFP_NOIO", so
that we don't overload the meaning of GFP_BUFFER.

That allows us to do the best we can - still flushing out dirty buffers
when that's ok (like when a filesystem wants more memory), and giving the
allocator better control over exactly _what_ he objects to.

		Linus


  parent reply	other threads:[~2001-06-30 17:42 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2001-06-29 20:33 Bounce buffer deadlock Steve Lord
2001-06-29 20:42 ` Alan Cox
2001-06-30 15:30 ` Marcelo Tosatti
2001-06-30 15:46   ` Marcelo Tosatti
2001-06-30 17:32   ` Linus Torvalds
2001-06-30 17:34   ` Steve Lord
2001-06-30 16:07     ` Marcelo Tosatti
2001-06-30 18:07       ` Steve Lord
2001-06-30 18:29         ` Marcelo Tosatti
2001-06-30 17:39     ` Linus Torvalds [this message]
2001-06-30 17:48       ` Steve Lord
2001-06-30 17:50         ` Linus Torvalds
2001-06-30 18:23           ` Steve Lord

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=Pine.LNX.4.33.0106301032170.1470-100000@penguin.transmeta.com \
    --to=torvalds@transmeta.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=lord@sgi.com \
    --cc=marcelo@conectiva.com.br \
    /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;
as well as URLs for NNTP newsgroup(s).