From: Waiman Long <waiman.long@hp.com>
To: jaegeuk.kim@samsung.com
Cc: Al Viro <viro@ZenIV.linux.org.uk>,
"Linux Kernel, Mailing List" <linux-kernel@vger.kernel.org>
Subject: Re: [BUG] deadlock on rename_lock
Date: Thu, 27 Feb 2014 23:06:58 -0500 [thread overview]
Message-ID: <53100B62.8000704@hp.com> (raw)
In-Reply-To: <1393548357.4705.75.camel@kjgkr>
On 02/27/2014 07:45 PM, Jaegeuk Kim wrote:
> Hi Al,
>
> In the following configuration, I met a deadlock condition like below.
>
> Kernel: 3.14-rc3
> Workload: fsstress with 10 threads
> Reproducible scenario: N/A
>
> Is it related to this patch?
> commit 1370e97bb2eb1ef2df7355204e5a4ba13e12b861
> Author: Waiman Long<Waiman.Long@hp.com>
> Date: Thu Sep 12 10:55:34 2013 -0400
>
> seqlock: Add a new locking reader type
>
> In d_walk(),
> /*
> * might go back up the wrong parent if we have had a
> rename
> * or deletion
> */
> if (this_parent != child->d_parent ||
> (child->d_flags& DCACHE_DENTRY_KILLED) ||
>
> --> I suspect that the upper conditions can trigger rename_retry even
> though rename_retry was done once before.
>
> need_seqretry(&rename_lock, seq)) {
> spin_unlock(&this_parent->d_lock);
> rcu_read_unlock();
> goto rename_retry;
> }
>
> Thanks,
>
>
It seems like the rename_lock may not be able to fully protect against
the setting of the DCACHE_DENTRY_KILLED flag. Al, should this case be
handled separately? I am 100% sure if we could just release the lock and
let it try again without causing infinite loop.
-Longman
prev parent reply other threads:[~2014-02-28 4:07 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-02-28 0:45 [BUG] deadlock on rename_lock Jaegeuk Kim
2014-02-28 4:06 ` Waiman Long [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=53100B62.8000704@hp.com \
--to=waiman.long@hp.com \
--cc=jaegeuk.kim@samsung.com \
--cc=linux-kernel@vger.kernel.org \
--cc=viro@ZenIV.linux.org.uk \
/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.