Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754195AbcCAXvG (ORCPT ); Tue, 1 Mar 2016 18:51:06 -0500 Received: from mail333.us4.mandrillapp.com ([205.201.137.77]:42851 "EHLO mail333.us4.mandrillapp.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753862AbcCAXvB (ORCPT ); Tue, 1 Mar 2016 18:51:01 -0500 DomainKey-Signature: a=rsa-sha1; c=nofws; q=dns; s=mandrill; d=linuxfoundation.org; b=YiG/hf13psekErpPOUdX5cUxqsAXLCdPupD/HErcHjBRoAJJviIozwLDfincgtOQPsC7N+HxCiag jqTRRvCNXT7YiB7F1HvJ3EKDDdqI2fn4dbhzJ0Q5tcYkTiBMwe5OZCfZWKGU8x14RYc0Iy2aIqTV mYR088KbmZgXFJ62Yrs=; From: Greg Kroah-Hartman Subject: [PATCH 3.14 031/130] dcache: add missing lockdep annotation X-Mailer: git-send-email 2.7.2 To: Cc: Greg Kroah-Hartman , , Al Viro , Linus Torvalds Message-Id: <20160301234500.863568890@linuxfoundation.org> In-Reply-To: <20160301234459.768886030@linuxfoundation.org> References: <20160301234459.768886030@linuxfoundation.org> X-Report-Abuse: Please forward a copy of this message, including all headers, to abuse@mandrill.com X-Report-Abuse: You can also report abuse here: http://mandrillapp.com/contact/abuse?id=30481620.45fbcd8f48b7472a9306e535a810de7b X-Mandrill-User: md_30481620 Date: Tue, 01 Mar 2016 23:50:59 +0000 MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1200 Lines: 39 3.14-stable review patch. If anyone has any objections, please let me know. ------------------ From: Linus Torvalds commit 9f12600fe425bc28f0ccba034a77783c09c15af4 upstream. lock_parent() very much on purpose does nested locking of dentries, and is careful to maintain the right order (lock parent first). But because it didn't annotate the nested locking order, lockdep thought it might be a deadlock on d_lock, and complained. Add the proper annotation for the inner locking of the child dentry to make lockdep happy. Introduced by commit 046b961b45f9 ("shrink_dentry_list(): take parent's ->d_lock earlier"). Reported-and-tested-by: Josh Boyer Cc: Al Viro Signed-off-by: Linus Torvalds Signed-off-by: Greg Kroah-Hartman --- fs/dcache.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) --- a/fs/dcache.c +++ b/fs/dcache.c @@ -551,7 +551,7 @@ again: } rcu_read_unlock(); if (parent != dentry) - spin_lock(&dentry->d_lock); + spin_lock_nested(&dentry->d_lock, DENTRY_D_LOCK_NESTED); else parent = NULL; return parent;