ALSA: pcm: potential uninitialized return values
[pandora-kernel.git] / fs / lockd / clntlock.c
index 25509eb..de88922 100644 (file)
@@ -79,7 +79,7 @@ EXPORT_SYMBOL_GPL(nlmclnt_init);
  */
 void nlmclnt_done(struct nlm_host *host)
 {
-       nlm_release_host(host);
+       nlmclnt_release_host(host);
        lockd_down();
 }
 EXPORT_SYMBOL_GPL(nlmclnt_done);
@@ -141,6 +141,9 @@ int nlmclnt_block(struct nlm_wait *block, struct nlm_rqst *req, long timeout)
                        timeout);
        if (ret < 0)
                return -ERESTARTSYS;
+       /* Reset the lock status after a server reboot so we resend */
+       if (block->b_status == nlm_lck_denied_grace_period)
+               block->b_status = nlm_lck_blocked;
        req->a_res.status = block->b_status;
        return 0;
 }
@@ -273,7 +276,7 @@ restart:
        spin_unlock(&nlm_blocked_lock);
 
        /* Release host handle after use */
-       nlm_release_host(host);
+       nlmclnt_release_host(host);
        lockd_down();
        return 0;
 }