Patch "NFS: Fix a memory leak in nfs_do_recoalesce" has been added to the 4.1-stable tree
Subsystems (2)
This is a note to let you know that I've just added the patch titled
NFS: Fix a memory leak in nfs_do_recoalesce
to the 4.1-stable tree which can be found at:
http://www.kernel.org/git/?p=linux/kernel/git/stable/stable-queue.git;a=summary
The filename of the patch is:
nfs-fix-a-memory-leak-in-nfs_do_recoalesce.patch
and it can be found in the queue-4.1 subdirectory.
If you, or anyone else, feels it should not be added to the stable tree, please let <[email protected]> know about it.
Quoted 1 line
From
03d5eb65b53889fe98a5ecddfe205c16e3093190Mon Sep 17 00:00:00 2001
From: Trond Myklebust <[email protected]>
Date: Mon, 27 Jul 2015 10:23:19 -0400
Subject: NFS: Fix a memory leak in nfs_do_recoalesce
From: Trond Myklebust <[email protected]>
commit 03d5eb65b53889fe98a5ecddfe205c16e3093190 upstream.
If the function exits early, then we must put those requests that were not processed back onto the &mirror->pg_list so they can be cleaned up by nfs_pgio_error().
--- fs/nfs/pagelist.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-)
fs/nfs/pagelist.c +4 -1
@@ -1110,8 +1110,11 @@ static int nfs_do_recoalesce(struct nfs_nfs_list_remove_request (req);if (__nfs_pageio_add_request (desc, req))continue ; -if (desc->pg_error <0 ) +if (desc->pg_error <0 ) { +list_splice_tail (&head, &mirror->pg_list); + mirror->pg_recoalesce =1 ;return 0 ; + }break ; } }while (mirror->pg_recoalesce);
Patches currently in stable-queue which might be from [email protected] are
queue-4.1/nfsv4-we-must-set-nfs_open_state-flag-in-nfs_resync_open_stateid_locked.patch queue-4.1/nfs-fix-a-memory-leak-in-nfs_do_recoalesce.patch queue-4.1/nfs-don-t-revalidate-the-mapping-if-both-size-and-change-attr-are-up-to-date.patch