From: Dave Chinner <david@fromorbit.com>
To: Tetsuo Handa <penguin-kernel@I-love.SAKURA.ne.jp>
Cc: linux-fsdevel@vger.kernel.org, xfs@oss.sgi.com
Subject: Re: [3.14-rc5 xfs] Lockdep warning
Date: Tue, 11 Mar 2014 08:08:37 +1100 [thread overview]
Message-ID: <20140310210837.GZ6851@dastard> (raw)
In-Reply-To: <201403101955.AAI04114.QJOFFFtHMSOLOV@I-love.SAKURA.ne.jp>
On Mon, Mar 10, 2014 at 07:55:19PM +0900, Tetsuo Handa wrote:
> I get below lockdep warning as of 1dc3217d on linux.git. I guess the situation
> is same as of v3.14-rc6 because there is no changes in fs/xfs directory between
> 1dc3217d and v3.14-rc6.
False positive. Lockdep is complaining about having different page
fault lock heirarchies for regular files versus directories. It's
too stupid to understand that the directory and regular inodes have
differnet lock classes and so therefore this:
> [ 96.098894] Possible unsafe locking scenario:
>
> [ 96.099795] CPU0 CPU1
> [ 96.100234] ---- ----
> [ 96.100666] lock(&(&ip->i_lock)->mr_lock);
> [ 96.101158] lock(&mm->mmap_sem);
> [ 96.101597] lock(&(&ip->i_lock)->mr_lock);
> [ 96.102030] lock(&mm->mmap_sem);
is impossible, because what it really is:
CPU0 CPU1
ilock (IS_DIR)
lock(mmap_sem)
ilock(IS_REG)
lock(mmap_sem)
cannot deadlock because there two different inode locks involved
here.
So, to shut lockdep up, we've got to fundamentally alter the locking
strategy. The current code is not broken, but we've now got to jump
throw complex hoops to make the locking validator understand that
it's not broken. This is a great example of how lockdep can be
considered harmful....
Solutions being discussed in this thread:
http://oss.sgi.com/pipermail/xfs/2014-March/034815.html
> Also, the culprit commits were already backported to
> RHEL7 beta somewhere between 3.10.0-90.el7 and 3.10.0-97.el7 .
That should already be sorted out. :)
Cheers,
Dave.
--
Dave Chinner
david@fromorbit.com
_______________________________________________
xfs mailing list
xfs@oss.sgi.com
http://oss.sgi.com/mailman/listinfo/xfs
prev parent reply other threads:[~2014-03-10 21:08 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-03-10 10:55 [3.14-rc5 xfs] Lockdep warning Tetsuo Handa
2014-03-10 21:08 ` Dave Chinner [this message]
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=20140310210837.GZ6851@dastard \
--to=david@fromorbit.com \
--cc=linux-fsdevel@vger.kernel.org \
--cc=penguin-kernel@I-love.SAKURA.ne.jp \
--cc=xfs@oss.sgi.com \
/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