From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Message-Id: <20130518021648.688023639@goodmis.org> Date: Fri, 17 May 2013 22:16:40 -0400 From: Steven Rostedt To: linux-kernel@vger.kernel.org, stable@vger.kernel.org Cc: Anurup m , shyju pv , Sanil kumar , Nataraj m , Li Zefan , David Howells , Andrew Morton Subject: [ 043/136 ] fs/fscache/stats.c: fix memory leak References: <20130518021557.139113314@goodmis.org> Content-Disposition: inline; filename=0043-fs-fscache-stats.c-fix-memory-leak.patch Sender: linux-kernel-owner@vger.kernel.org List-ID: 3.6.11.4 stable review patch. If anyone has any objections, please let me know. ------------------ From: Anurup m [ Upstream commit ec686c9239b4d472052a271c505d04dae84214cc ] There is a kernel memory leak observed when the proc file /proc/fs/fscache/stats is read. The reason is that in fscache_stats_open, single_open is called and the respective release function is not called during release. Hence fix with correct release function - single_release(). Addresses https://bugzilla.kernel.org/show_bug.cgi?id=57101 Signed-off-by: Anurup m Cc: shyju pv Cc: Sanil kumar Cc: Nataraj m Cc: Li Zefan Cc: David Howells Cc: Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds Signed-off-by: Steven Rostedt --- fs/fscache/stats.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/fs/fscache/stats.c b/fs/fscache/stats.c index 4765190..73c0bd7 100644 --- a/fs/fscache/stats.c +++ b/fs/fscache/stats.c @@ -276,5 +276,5 @@ const struct file_operations fscache_stats_fops = { .open = fscache_stats_open, .read = seq_read, .llseek = seq_lseek, - .release = seq_release, + .release = single_release, }; -- 1.7.10.4