nfsd: Remove duplicate checking of nfsd_net in nfs4_laundromat()

This change “nfsd: Remove duplicate checking of nfsd_net in nfs4_laundromat()” in Linux kernel is authored by Kinglong Mee <kinglongmee [at] gmail.com> on Mon Jul 13 17:33:55 2015 +0800.

nfsd: Remove duplicate checking of nfsd_net in nfs4_laundromat()

Signed-off-by: Kinglong Mee <kinglongmee@gmail.com>
Signed-off-by: J. Bruce Fields <bfields@redhat.com>

This Linux change may have been applied to various maintained Linux releases and you can find Linux releases including commit 7a5e8d5.

There are 2 lines of Linux source code added/deleted in this change. Code changes to Linux kernel are as follows.

 fs/nfsd/nfs4state.c | 2 --
 1 file changed, 2 deletions(-)

diff --git a/fs/nfsd/nfs4state.c b/fs/nfsd/nfs4state.c
index 780fd6e..433355d 100644
--- a/fs/nfsd/nfs4state.c
+++ b/fs/nfsd/nfs4state.c
@@ -4340,8 +4340,6 @@ void nfsd4_cleanup_open_state(struct nfsd4_compound_state *cstate,
 	spin_lock(&state_lock);
 	list_for_each_safe(pos, next, &nn->del_recall_lru) {
 		dp = list_entry (pos, struct nfs4_delegation, dl_recall_lru);
-		if (net_generic(dp->dl_stid.sc_client->net, nfsd_net_id) != nn)
-			continue;
 		if (time_after((unsigned long)dp->dl_time, (unsigned long)cutoff)) {
 			t = dp->dl_time - cutoff;
 			new_timeo = min(new_timeo, t);

The commit for this change in Linux stable tree is 7a5e8d5 (patch).

Leave a Reply

Your email address will not be published. Required fields are marked *