[ 3.5.yuz extended stable ] Patch "ceph: fix dentry reference leak in encode_fh()" has been added to staging queue

Herton Ronaldo Krzesinski herton.krzesinski at canonical.com
Tue Nov 20 17:19:48 UTC 2012

This is a note to let you know that I have just added a patch titled

    ceph: fix dentry reference leak in encode_fh()

to the linux-3.5.y-queue branch of the 3.5.yuz extended stable tree 
which can be found at:


If you, or anyone else, feels it should not be added to this tree, please 
reply to this email.

For more information about the 3.5.yuz tree, see



>From 9949bb432e95b3a2b7dc8d844b019de010567100 Mon Sep 17 00:00:00 2001
From: David Zafman <david.zafman at inktank.com>
Date: Thu, 18 Oct 2012 14:01:43 -0700
Subject: [PATCH 75/78] ceph: fix dentry reference leak in encode_fh()

commit 52eb5a900a9863a8b77a895f770e5d825c8e02c6 upstream.

Call to d_find_alias() needs a corresponding dput()

This fixes http://tracker.newdream.net/issues/3271

Signed-off-by: David Zafman <david.zafman at inktank.com>
Reviewed-by: Sage Weil <sage at inktank.com>
Signed-off-by: Herton Ronaldo Krzesinski <herton.krzesinski at canonical.com>
 fs/ceph/export.c |    2 ++
 1 file changed, 2 insertions(+)

diff --git a/fs/ceph/export.c b/fs/ceph/export.c
index 02ce909..9349bb3 100644
--- a/fs/ceph/export.c
+++ b/fs/ceph/export.c
@@ -90,6 +90,8 @@ static int ceph_encode_fh(struct inode *inode, u32 *rawfh, int *max_len,
 		*max_len = handle_length;
 		type = 255;
+	if (dentry)
+		dput(dentry);
 	return type;


More information about the kernel-team mailing list