NFSv4: don't mark all open state for recovery when handling recallable state revoked...
[linux-2.6-block.git] / fs / nfs / nfs4state.c
index 02488b50534ac0f18a59590a0213f8954b447127..e2e3c4f04d3e097fb411205283048258525be00d 100644 (file)
@@ -159,6 +159,10 @@ int nfs40_discover_server_trunking(struct nfs_client *clp,
                /* Sustain the lease, even if it's empty.  If the clientid4
                 * goes stale it's of no use for trunking discovery. */
                nfs4_schedule_state_renewal(*result);
+
+               /* If the client state need to recover, do it. */
+               if (clp->cl_state)
+                       nfs4_schedule_state_manager(clp);
        }
 out:
        return status;
@@ -563,6 +567,7 @@ static void nfs4_gc_state_owners(struct nfs_server *server)
  * nfs4_get_state_owner - Look up a state owner given a credential
  * @server: nfs_server to search
  * @cred: RPC credential to match
+ * @gfp_flags: allocation mode
  *
  * Returns a pointer to an instantiated nfs4_state_owner struct, or NULL.
  */
@@ -2345,8 +2350,7 @@ static void nfs41_handle_recallable_state_revoked(struct nfs_client *clp)
 {
        /* FIXME: For now, we destroy all layouts. */
        pnfs_destroy_all_layouts(clp);
-       /* FIXME: For now, we test all delegations+open state+locks. */
-       nfs41_handle_some_state_revoked(clp);
+       nfs_test_expired_all_delegations(clp);
        dprintk("%s: Recallable state revoked on server %s!\n", __func__,
                        clp->cl_hostname);
 }