Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 1 Oct 2017 21:45:15 +0000 (UTC)
From:      Rick Macklem <rmacklem@FreeBSD.org>
To:        src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-11@freebsd.org
Subject:   svn commit: r324180 - stable/11/sys/fs/nfsclient
Message-ID:  <201710012145.v91LjFBf062169@repo.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: rmacklem
Date: Sun Oct  1 21:45:15 2017
New Revision: 324180
URL: https://svnweb.freebsd.org/changeset/base/324180

Log:
  MFC: r323689
  Fix bogus FREAD with NFSV4OPEN_ACCESSREAD. No functional change.
  
  The code in nfscl_doflayoutio() bogusly used FREAD instead of
  NFSV4OPEN_ACCESSREAD. Since both happen to be defined as "1", this
  worked and the patch doesn't result in a functional change.
  Found by inspection during development of Flex File Layout support.

Modified:
  stable/11/sys/fs/nfsclient/nfs_clrpcops.c
Directory Properties:
  stable/11/   (props changed)

Modified: stable/11/sys/fs/nfsclient/nfs_clrpcops.c
==============================================================================
--- stable/11/sys/fs/nfsclient/nfs_clrpcops.c	Sun Oct  1 21:20:28 2017	(r324179)
+++ stable/11/sys/fs/nfsclient/nfs_clrpcops.c	Sun Oct  1 21:45:15 2017	(r324180)
@@ -5664,7 +5664,7 @@ nfscl_doflayoutio(vnode_t vp, struct uio *uiop, int *i
 				np->n_flag &= ~NDSCOMMIT;
 				mtx_unlock(&np->n_mtx);
 			}
-		} else if (rwflag == FREAD)
+		} else if (rwflag == NFSV4OPEN_ACCESSREAD)
 			error = nfsrpc_readds(vp, uiop, stateidp, eofp, *dspp,
 			    io_off, xfer, fhp, cred, p);
 		else {



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201710012145.v91LjFBf062169>