From patchwork Wed Jul 3 20:19:57 2013 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Waiman Long X-Patchwork-Id: 256770 Return-Path: X-Original-To: patchwork-incoming@ozlabs.org Delivered-To: patchwork-incoming@ozlabs.org Received: from ozlabs.org (localhost [IPv6:::1]) by ozlabs.org (Postfix) with ESMTP id 9B4CF2C0344 for ; Thu, 4 Jul 2013 10:16:01 +1000 (EST) X-Greylist: delayed 609 seconds by postgrey-1.34 at bilbo; Thu, 04 Jul 2013 06:30:28 EST Received: from g4t0017.houston.hp.com (g4t0017.houston.hp.com [15.201.24.20]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (Client CN "smtp.hp.com", Issuer "VeriSign Class 3 Secure Server CA - G3" (not verified)) by ozlabs.org (Postfix) with ESMTPS id D63972C00A6; Thu, 4 Jul 2013 06:30:28 +1000 (EST) Received: from g4t0009.houston.hp.com (g4t0009.houston.hp.com [16.234.32.26]) by g4t0017.houston.hp.com (Postfix) with ESMTP id 0FA3438F4D; Wed, 3 Jul 2013 20:20:16 +0000 (UTC) Received: from RHEL64.localdomain (unknown [16.99.82.253]) by g4t0009.houston.hp.com (Postfix) with ESMTP id 86BACCC7D; Wed, 3 Jul 2013 20:20:12 +0000 (UTC) From: Waiman Long To: Subject: [PATCH v3 04/25] powerpc: Change how dentry's d_lock field is accessed Date: Wed, 3 Jul 2013 16:19:57 -0400 Message-Id: <1372882797-22614-1-git-send-email-Waiman.Long@hp.com> X-Mailer: git-send-email 1.7.1 To: Alexander Viro , Jeff Layton , Miklos Szeredi , Ingo Molnar , Thomas Gleixner X-Mailman-Approved-At: Thu, 04 Jul 2013 10:15:36 +1000 Cc: cbe-oss-dev@lists.ozlabs.org, Waiman Long , Arnd Bergmann , Peter Zijlstra , linux-kernel@vger.kernel.org, Steven Rostedt , "Chandramouleeswaran, Aswin" , Linus Torvalds , Andi Kleen , Paul Mackerras , Jeremy Kerr , "Norton, Scott J" , linux-fsdevel@vger.kernel.org, linuxppc-dev@lists.ozlabs.org X-BeenThere: linuxppc-dev@lists.ozlabs.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: Linux on PowerPC Developers Mail List List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Errors-To: linuxppc-dev-bounces+patchwork-incoming=ozlabs.org@lists.ozlabs.org Sender: "Linuxppc-dev" Because of the changes made in dcache.h header file, files that use the d_lock field of the dentry structure need to be changed accordingly. All the d_lock's spin_lock() and spin_unlock() calls are replaced by the corresponding d_lock() and d_unlock() calls. There is no change in logic and everything should just work. Signed-off-by: Waiman Long --- arch/powerpc/platforms/cell/spufs/inode.c | 6 +++--- 1 files changed, 3 insertions(+), 3 deletions(-) diff --git a/arch/powerpc/platforms/cell/spufs/inode.c b/arch/powerpc/platforms/cell/spufs/inode.c index 35f77a4..3597c4b 100644 --- a/arch/powerpc/platforms/cell/spufs/inode.c +++ b/arch/powerpc/platforms/cell/spufs/inode.c @@ -165,18 +165,18 @@ static void spufs_prune_dir(struct dentry *dir) mutex_lock(&dir->d_inode->i_mutex); list_for_each_entry_safe(dentry, tmp, &dir->d_subdirs, d_u.d_child) { - spin_lock(&dentry->d_lock); + d_lock(dentry); if (!(d_unhashed(dentry)) && dentry->d_inode) { dget_dlock(dentry); __d_drop(dentry); - spin_unlock(&dentry->d_lock); + d_unlock(dentry); simple_unlink(dir->d_inode, dentry); /* XXX: what was dcache_lock protecting here? Other * filesystems (IB, configfs) release dcache_lock * before unlink */ dput(dentry); } else { - spin_unlock(&dentry->d_lock); + d_unlock(dentry); } } shrink_dcache_parent(dir);