]> Pileus Git - ~andy/linux/blobdiff - fs/nfsd/nfs4state.c
[PATCH] nfsd4: nfs4_check_delegmode
[~andy/linux] / fs / nfsd / nfs4state.c
index bb95275e7bae0a9397d8f49afb889379cd93d216..31f7082df49f7fe04e91a463261f58884f28217b 100644 (file)
@@ -1526,6 +1526,15 @@ out:
        return status;
 }
 
+static inline int
+nfs4_check_delegmode(struct nfs4_delegation *dp, int flags)
+{
+       if ((flags & WR_STATE) && (dp->dl_type == NFS4_OPEN_DELEGATE_READ))
+               return nfserr_openmode;
+       else
+               return nfs_ok;
+}
+
 static struct nfs4_delegation *
 find_delegation_file(struct nfs4_file *fp, stateid_t *stid)
 {
@@ -1960,15 +1969,6 @@ out:
        return status;
 }
 
-static inline int
-nfs4_check_delegmode(struct nfs4_delegation *dp, int flags)
-{
-       if ((flags & WR_STATE) && (dp->dl_type == NFS4_OPEN_DELEGATE_READ))
-               return nfserr_openmode;
-       else
-               return nfs_ok;
-}
-
 static inline int
 check_special_stateids(svc_fh *current_fh, stateid_t *stateid, int flags)
 {