This is a note to let you know that I've just added the patch titled

    NFSv4: Fix two infinite loops in the mount code

to the 3.3-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:
     nfsv4-fix-two-infinite-loops-in-the-mount-code.patch
and it can be found in the queue-3.3 subdirectory.

If you, or anyone else, feels it should not be added to the stable tree,
please let <stable@vger.kernel.org> know about it.


>From 05e9cfb408b24debb3a85fd98edbfd09dd148881 Mon Sep 17 00:00:00 2001
From: Trond Myklebust <trond.mykleb...@netapp.com>
Date: Tue, 27 Mar 2012 18:13:02 -0400
Subject: NFSv4: Fix two infinite loops in the mount code

From: Trond Myklebust <trond.mykleb...@netapp.com>

commit 05e9cfb408b24debb3a85fd98edbfd09dd148881 upstream.

We can currently loop forever in nfs4_lookup_root() and in
nfs41_proc_secinfo_no_name(), if the first iteration returns a
NFS4ERR_DELAY or something else that causes exception.retry to get
set.

Reported-by: Weston Andros Adamson <d...@netapp.com>
Signed-off-by: Trond Myklebust <trond.mykleb...@netapp.com>
Signed-off-by: Greg Kroah-Hartman <gre...@linuxfoundation.org>

---
 fs/nfs/nfs4proc.c |    6 ++++--
 1 file changed, 4 insertions(+), 2 deletions(-)

--- a/fs/nfs/nfs4proc.c
+++ b/fs/nfs/nfs4proc.c
@@ -2249,11 +2249,12 @@ static int nfs4_lookup_root(struct nfs_s
                switch (err) {
                case 0:
                case -NFS4ERR_WRONGSEC:
-                       break;
+                       goto out;
                default:
                        err = nfs4_handle_exception(server, err, &exception);
                }
        } while (exception.retry);
+out:
        return err;
 }
 
@@ -6068,11 +6069,12 @@ nfs41_proc_secinfo_no_name(struct nfs_se
                case 0:
                case -NFS4ERR_WRONGSEC:
                case -NFS4ERR_NOTSUPP:
-                       break;
+                       goto out;
                default:
                        err = nfs4_handle_exception(server, err, &exception);
                }
        } while (exception.retry);
+out:
        return err;
 }
 


Patches currently in stable-queue which might be from 
trond.mykleb...@netapp.com are

queue-3.3/nfsv4.1-fix-layoutcommit-error-handling.patch
queue-3.3/nfsv4-rate-limit-the-state-manager-warning-messages.patch
queue-3.3/sunrpc-we-must-not-use-list_for_each_entry_safe-in-rpc_wake_up.patch
queue-3.3/nfsv4-fix-two-infinite-loops-in-the-mount-code.patch
queue-3.3/nfsv4-return-the-delegation-if-the-server-returns-nfs4err_openmode.patch
queue-3.3/nfs-properly-handle-the-case-where-the-delegation-is-revoked.patch
--
To unsubscribe from this list: send the line "unsubscribe stable" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Reply via email to