[Patch -rc5-mm1] Lockdep annotate rpc_populate for child-relationship of its mutex

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Tue, 2006-05-30 at 14:14 -0700, Roland Dreier wrote:
> Here it is with KALLSYMS_ALL:


ok this ought to do it 


rpc_populate is creating a child inode in a directory, and the
parent already has it's mutex locked. Similar to the VFS code
this needs I_MUTEX_CHILD nesting annotation

Signed-off-by: Arjan van de Ven <[email protected]>
---
 net/sunrpc/rpc_pipe.c |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

Index: linux-2.6.17-rc5-mm1-lockdep/net/sunrpc/rpc_pipe.c
===================================================================
--- linux-2.6.17-rc5-mm1-lockdep.orig/net/sunrpc/rpc_pipe.c
+++ linux-2.6.17-rc5-mm1-lockdep/net/sunrpc/rpc_pipe.c
@@ -557,7 +557,7 @@ rpc_populate(struct dentry *parent,
 	struct dentry *dentry;
 	int mode, i;
 
-	mutex_lock(&dir->i_mutex);
+	mutex_lock_nested(&dir->i_mutex, I_MUTEX_CHILD);
 	for (i = start; i < eof; i++) {
 		dentry = d_alloc_name(parent, files[i].name);
 		if (!dentry)


-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to [email protected]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

[Index of Archives]     [Kernel Newbies]     [Netfilter]     [Bugtraq]     [Photo]     [Stuff]     [Gimp]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Video 4 Linux]     [Linux for the blind]     [Linux Resources]
  Powered by Linux