public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Andrew Morton <akpm@zip.com.au>
To: Hugh Dickins <hugh@veritas.com>
Cc: Marcelo Tosatti <marcelo@conectiva.com.br>,
	Andrea Arcangeli <andrea@suse.de>, Dave Jones <davej@suse.de>,
	Ben LaHaise <bcrl@redhat.com>,
	linux-kernel@vger.kernel.org
Subject: Re: [PATCH] pagecache lock ordering
Date: Wed, 09 Jan 2002 16:52:38 -0800	[thread overview]
Message-ID: <3C3CE5D6.2204BD27@zip.com.au> (raw)
In-Reply-To: <Pine.LNX.4.21.0201100007350.1080-100000@localhost.localdomain>

Hugh Dickins wrote:
> 
> There's two places, do_buffer_fdatasync

generic_buffer_fdatasync() and hence do_buffer_fdatasync()
are completely unused.  It may be simpler to just trash
them.

> and __find_lock_page_helper,

Yeah.  The code can't deadlock because:

	page_cache_get();
	spin_lock(&pagecache_lock);
	page_cache_release();

we implicitly *know* that page_cache_release won't try
to acquire pagemap_lru_lock, because the page is in the
pagecache and has count=2 or more.  Which is a bit, umm,
subtle.

I get the feeling that a lot of this would be cleaned up
if presence on an LRU contributed to page->count.  It
seems strange, kludgy and probably racy that this is not
the case.

-

  reply	other threads:[~2002-01-10  0:59 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2002-01-10  0:42 [PATCH] pagecache lock ordering Hugh Dickins
2002-01-10  0:52 ` Andrew Morton [this message]
2002-01-10 14:06   ` Hugh Dickins
2002-01-10 20:39     ` Andrew Morton
2002-01-10 23:28       ` Benjamin LaHaise
2002-01-10 23:47         ` Andrew Morton
2002-01-10 23:54           ` Benjamin LaHaise

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=3C3CE5D6.2204BD27@zip.com.au \
    --to=akpm@zip.com.au \
    --cc=andrea@suse.de \
    --cc=bcrl@redhat.com \
    --cc=davej@suse.de \
    --cc=hugh@veritas.com \
    --cc=linux-kernel@vger.kernel.org \
    --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