All of lore.kernel.org
 help / color / mirror / Atom feed
From: Andi Kleen <andi@firstfloor.org>
To: linux-kernel@vger.kernel.org, Trond.Myklebust@netapp.com
Subject: NFS lockdep lock misordering mmap_sem<->i_mutex_key with 2.6.32-git1
Date: Mon, 7 Dec 2009 12:59:50 +0100	[thread overview]
Message-ID: <20091207115949.GA7610@basil.fritz.box> (raw)


While booting 2.6.32-git1 on a NFS root box I got the following
lockdep warning early at boot. I haven't looked at details.

-Andi

VFS: Mounted root (nfs filesystem) on device 0:15.
VFS: Mounted root (nfs filesystem) on device 0:15.
Freeing unused kernel memory: 2376k freed

=======================================================
[ INFO: possible circular locking dependency detected ]
-------------------------------------------------------
udevinfo/2551 is trying to acquire lock:
 (&sb->s_type->i_mutex_key#5){+.+.+.}, at: [<ffffffff8118e0d3>] nfs_revalidate_mapping+0x7c/0xc5

but task is already holding lock:
 (&mm->mmap_sem){++++++}, at: [<ffffffff8100fc83>] sys_mmap+0x76/0xc7

which lock already depends on the new lock.


the existing dependency chain (in reverse order) is:

-> #1 (&mm->mmap_sem){++++++}:
       [<ffffffff81071d0b>] __lock_acquire+0x1435/0x1774
       [<ffffffff81072106>] lock_acquire+0xbc/0xd9
       [<ffffffff810baa14>] might_fault+0x84/0xa4
       [<ffffffff810ec340>] filldir+0x6a/0xcb
       [<ffffffff81189bad>] nfs_do_filldir+0x39d/0x4ac
       [<ffffffff8118a4e9>] nfs_readdir+0x82d/0x8ce
       [<ffffffff810ec4bf>] vfs_readdir+0x6c/0xa1
       [<ffffffff810ec632>] sys_getdents+0x7d/0xc9
       [<ffffffff8100ba6b>] system_call_fastpath+0x16/0x1b

-> #0 (&sb->s_type->i_mutex_key#5){+.+.+.}:
       [<ffffffff81071a30>] __lock_acquire+0x115a/0x1774
       [<ffffffff81072106>] lock_acquire+0xbc/0xd9
       [<ffffffff8149210d>] mutex_lock_nested+0x68/0x2d2
       [<ffffffff8118e0d3>] nfs_revalidate_mapping+0x7c/0xc5
       [<ffffffff8118bad9>] nfs_file_mmap+0x68/0x71
       [<ffffffff810c29c0>] mmap_region+0x311/0x50f
       [<ffffffff810c2f13>] do_mmap_pgoff+0x355/0x3b8
       [<ffffffff8100fca1>] sys_mmap+0x94/0xc7
       [<ffffffff8100ba6b>] system_call_fastpath+0x16/0x1b

other info that might help us debug this:

1 lock held by udevinfo/2551:
 #0:  (&mm->mmap_sem){++++++}, at: [<ffffffff8100fc83>] sys_mmap+0x76/0xc7

stack backtrace:
Pid: 2551, comm: udevinfo Not tainted 2.6.32-git1 #31
Call Trace:
 [<ffffffff81070388>] print_circular_bug+0xb3/0xc2
 [<ffffffff81071a30>] __lock_acquire+0x115a/0x1774
 [<ffffffff810a401d>] ? find_get_pages_tag+0x0/0x12a
 [<ffffffff81072106>] lock_acquire+0xbc/0xd9
 [<ffffffff8118e0d3>] ? nfs_revalidate_mapping+0x7c/0xc5
 [<ffffffff8149210d>] mutex_lock_nested+0x68/0x2d2
 [<ffffffff8118e0d3>] ? nfs_revalidate_mapping+0x7c/0xc5
 [<ffffffff8118e0d3>] ? nfs_revalidate_mapping+0x7c/0xc5
 [<ffffffff810c291d>] ? mmap_region+0x26e/0x50f
 [<ffffffff8118e0d3>] nfs_revalidate_mapping+0x7c/0xc5
 [<ffffffff8118bad9>] nfs_file_mmap+0x68/0x71
 [<ffffffff810c29c0>] mmap_region+0x311/0x50f
 [<ffffffff810c2f13>] do_mmap_pgoff+0x355/0x3b8
 [<ffffffff8100fca1>] sys_mmap+0x94/0xc7
 [<ffffffff8100ba6b>] system_call_fastpath+0x16/0x1b

-Andi
-- 
ak@linux.intel.com -- Speaking for myself only.

             reply	other threads:[~2009-12-07 11:59 UTC|newest]

Thread overview: 16+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-12-07 11:59 Andi Kleen [this message]
2009-12-07 12:19 ` NFS lockdep lock misordering mmap_sem<->i_mutex_key with 2.6.32-git1 KOSAKI Motohiro
2009-12-07 13:20   ` Andi Kleen
2009-12-07 17:38     ` KOSAKI Motohiro
2009-12-07 17:38       ` KOSAKI Motohiro
2009-12-15 22:21     ` Al Viro
2009-12-15 23:38       ` Andi Kleen
2009-12-15 23:54         ` Trond Myklebust
2009-12-16  0:09           ` Al Viro
2009-12-16 13:16             ` Trond Myklebust
2009-12-23 16:32               ` Andi Kleen
2009-12-16  0:53           ` Andi Kleen
2009-12-16 13:09             ` Trond Myklebust
2009-12-16 15:57               ` Andi Kleen
2009-12-16  0:06         ` KOSAKI Motohiro
2009-12-16  0:48           ` Andi Kleen

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=20091207115949.GA7610@basil.fritz.box \
    --to=andi@firstfloor.org \
    --cc=Trond.Myklebust@netapp.com \
    --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 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.