From: Fengguang Wu <fengguang.wu@gmail.com>
To: Andrew Morton <akpm@osdl.org>
Cc: Ingo Molnar <mingo@elte.hu>, linux-kernel@vger.kernel.org
Subject: Re: drop_pagecache: Possible circular locking dependency
Date: Mon, 4 Dec 2006 17:37:18 +0800 [thread overview]
Message-ID: <365225031.05635@ustc.edu.cn> (raw)
Message-ID: <20061204093718.GA7243@mail.ustc.edu.cn> (raw)
In-Reply-To: <20061204003217.c0f05e00.akpm@osdl.org>
On Mon, Dec 04, 2006 at 12:32:17AM -0800, Andrew Morton wrote:
> On Mon, 4 Dec 2006 16:09:02 +0800
> Fengguang Wu <fengguang.wu@gmail.com> wrote:
>
> > Got the following message when doing some benchmarks.
> > I guess we should not hold inode_lock on calling invalidate_inode_pages().
> > Any ideas?
> >
> > Fengguang Wu
> >
> > =======================================================
> > [ INFO: possible circular locking dependency detected ]
> > 2.6.19-rc6-mm2 #3
> > -------------------------------------------------------
> > rabench.sh/7467 is trying to acquire lock:
> > (&journal->j_list_lock){--..}, at: [<ffffffff8113bdbc>] journal_try_to_free_buffers+0xdc/0x1c0
> >
> > but task is already holding lock:
> > (inode_lock){--..}, at: [<ffffffff810fe857>] drop_pagecache+0x67/0x120
> >
> > which lock already depends on the new lock.
> >
>
> drat, I was afraid someone would notice.
>
> It's Hard To Fix. Removing /proc/sys/vm/drop_pagecache would in fact be
> my preferred fix.
Or fix drop_pagecache_sb():
Repeat until all possible pages freed:
grab and save some inodes to a buffer
zip their pages outside of inode_lock
Takes much more code though.
I'd like to move this sysctl interface to the upcoming /proc/filecache.
Being a module, it helps reduce the kernel size :)
Fengguang Wu
next prev parent reply other threads:[~2006-12-04 9:37 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2006-12-04 8:09 drop_pagecache: Possible circular locking dependency Fengguang Wu
2006-12-04 8:09 ` Fengguang Wu
2006-12-04 8:32 ` Andrew Morton
2006-12-04 9:37 ` Fengguang Wu [this message]
2006-12-04 9:37 ` Fengguang Wu
2006-12-04 10:20 ` Nick Piggin
2006-12-04 10:49 ` Fengguang Wu
2006-12-04 10:49 ` Fengguang Wu
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=365225031.05635@ustc.edu.cn \
--to=fengguang.wu@gmail.com \
--cc=akpm@osdl.org \
--cc=linux-kernel@vger.kernel.org \
--cc=mingo@elte.hu \
/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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.