From: Ingo Molnar <mingo@elte.hu>
To: Andrew Morton <akpm@linux-foundation.org>
Cc: linux-kernel@vger.kernel.org
Subject: circular locking: /proc/sys/vm/drop_caches
Date: Fri, 23 Feb 2007 07:35:38 +0100 [thread overview]
Message-ID: <20070223063538.GA13679@elte.hu> (raw)
Andrew,
i just got the lockdep warning below when doing:
echo 3 > /proc/sys/vm/drop_caches
is this a known quirk in the drop_caches code?
Ingo
=======================================================
[ INFO: possible circular locking dependency detected ]
2.6.20-syslet #434
-------------------------------------------------------
bash/12166 is trying to acquire lock:
(&journal->j_list_lock){--..}, at: [<c01c82f5>] journal_try_to_free_buffers+0xd5/0x18f
but task is already holding lock:
(inode_lock){--..}, at: [<c01947a3>] drop_pagecache+0x45/0xc8
which lock already depends on the new lock.
the existing dependency chain (in reverse order) is:
-> #1 (inode_lock){--..}:
[<c0144940>] __lock_acquire+0x984/0xa94
[<c0144d6f>] lock_acquire+0x67/0x8c
[<c0424a9f>] _spin_lock+0x35/0x42
[<c0193ccb>] __mark_inode_dirty+0xe3/0x15e
[<c016253b>] __set_page_dirty_nobuffers+0xb4/0xbf
[<c0197361>] mark_buffer_dirty+0x1e/0x20
[<c01c7af2>] __journal_temp_unlink_buffer+0x176/0x17d
[<c01c7d23>] __journal_unfile_buffer+0xb/0x15
[<c01c7d97>] __journal_refile_buffer+0x6a/0xe3
[<c01cac34>] journal_commit_transaction+0xf46/0x11da
[<c01cd32c>] kjournald+0xab/0x1e8
[<c013b935>] kthread+0xb2/0xd7
[<c0104e5f>] kernel_thread_helper+0x7/0x10
[<ffffffff>] 0xffffffff
-> #0 (&journal->j_list_lock){--..}:
[<c014483b>] __lock_acquire+0x87f/0xa94
[<c0144d6f>] lock_acquire+0x67/0x8c
[<c0424a9f>] _spin_lock+0x35/0x42
[<c01c82f5>] journal_try_to_free_buffers+0xd5/0x18f
[<c01b944e>] ext3_releasepage+0x68/0x74
[<c015d027>] try_to_release_page+0x33/0x44
[<c016406e>] invalidate_mapping_pages+0x69/0xca
[<c01640dc>] invalidate_inode_pages+0xd/0x11
[<c01947bf>] drop_pagecache+0x61/0xc8
[<c019485c>] drop_caches_sysctl_handler+0x36/0x4e
[<c012efdc>] do_rw_proc+0xaf/0xf1
[<c012f078>] proc_writesys+0x20/0x25
[<c017b3de>] vfs_write+0xb1/0x165
[<c017bbc6>] sys_write+0x3d/0x61
[<c01041a8>] syscall_call+0x7/0xb
[<ffffffff>] 0xffffffff
other info that might help us debug this:
2 locks held by bash/12166:
#0: (&type->s_umount_key#17){----}, at: [<c0194793>] drop_pagecache+0x35/0xc8
#1: (inode_lock){--..}, at: [<c01947a3>] drop_pagecache+0x45/0xc8
stack backtrace:
[<c010510d>] show_trace_log_lvl+0x19/0x2e
[<c0105206>] show_trace+0x12/0x14
[<c010521c>] dump_stack+0x14/0x16
[<c01433ff>] print_circular_bug_tail+0x5f/0x68
[<c014483b>] __lock_acquire+0x87f/0xa94
[<c0144d6f>] lock_acquire+0x67/0x8c
[<c0424a9f>] _spin_lock+0x35/0x42
[<c01c82f5>] journal_try_to_free_buffers+0xd5/0x18f
[<c01b944e>] ext3_releasepage+0x68/0x74
[<c015d027>] try_to_release_page+0x33/0x44
[<c016406e>] invalidate_mapping_pages+0x69/0xca
[<c01640dc>] invalidate_inode_pages+0xd/0x11
[<c01947bf>] drop_pagecache+0x61/0xc8
[<c019485c>] drop_caches_sysctl_handler+0x36/0x4e
[<c012efdc>] do_rw_proc+0xaf/0xf1
[<c012f078>] proc_writesys+0x20/0x25
[<c017b3de>] vfs_write+0xb1/0x165
[<c017bbc6>] sys_write+0x3d/0x61
[<c01041a8>] syscall_call+0x7/0xb
=======================
next reply other threads:[~2007-02-23 6:40 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2007-02-23 6:35 Ingo Molnar [this message]
2007-02-23 9:40 ` Frederik Deweerdt
2007-02-23 10:07 ` Andrew Morton
2007-02-23 11:36 ` Ingo Molnar
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=20070223063538.GA13679@elte.hu \
--to=mingo@elte.hu \
--cc=akpm@linux-foundation.org \
--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®