Author: rmacklem
Date: Tue Apr 25 19:48:25 2017
New Revision: 317420
URL: https://svnweb.freebsd.org/changeset/base/317420

Log:
  MFC: r316667
  Fix the NFSv4 client hndling of a stale write verifier in the Commit 
operation.
  
  When the NFSv4 client Commit operation encountered a stale write verifier,
  it erroneously mapped that to EIO. This could have caused recently written
  data to be lost when a server crashes/reboots between an UNSTABLE write
  and the subsequent commit. This patch fixes this.
  The bug was only for the NFSv4 client and did not affect NFSv3.

Modified:
  stable/10/sys/fs/nfsclient/nfs_clport.c
Directory Properties:
  stable/10/   (props changed)

Modified: stable/10/sys/fs/nfsclient/nfs_clport.c
==============================================================================
--- stable/10/sys/fs/nfsclient/nfs_clport.c     Tue Apr 25 19:35:13 2017        
(r317419)
+++ stable/10/sys/fs/nfsclient/nfs_clport.c     Tue Apr 25 19:48:25 2017        
(r317420)
@@ -1125,7 +1125,7 @@ nfscl_maperr(struct thread *td, int erro
 {
        struct proc *p;
 
-       if (error < 10000)
+       if (error < 10000 || error >= NFSERR_STALEWRITEVERF)
                return (error);
        if (td != NULL)
                p = td->td_proc;
_______________________________________________
[email protected] mailing list
https://lists.freebsd.org/mailman/listinfo/svn-src-stable-10
To unsubscribe, send any mail to "[email protected]"

Reply via email to