From 3863e89caec3c83dbeae9c3077389db6206dc8e7 Mon Sep 17 00:00:00 2001 From: Ben Hutchings Date: Sun, 27 Apr 2014 01:20:19 +0100 Subject: nfsd: Add fh_{want,drop}_write() Part of commit bad0dcffc21d17a07dbb83a2bf764f35a57feba5 ('new helpers: fh_{want,drop}_write()') upstream. Signed-off-by: Ben Hutchings --- fs/nfsd/vfs.h | 10 ++++++++++ 1 file changed, 10 insertions(+) (limited to 'fs/nfsd') diff --git a/fs/nfsd/vfs.h b/fs/nfsd/vfs.h index 85d4d42..c7fe962 100644 --- a/fs/nfsd/vfs.h +++ b/fs/nfsd/vfs.h @@ -108,4 +108,14 @@ struct posix_acl *nfsd_get_posix_acl(struct svc_fh *, int); int nfsd_set_posix_acl(struct svc_fh *, int, struct posix_acl *); #endif +static inline int fh_want_write(struct svc_fh *fh) +{ + return mnt_want_write(fh->fh_export->ex_path.mnt); +} + +static inline void fh_drop_write(struct svc_fh *fh) +{ + mnt_drop_write(fh->fh_export->ex_path.mnt); +} + #endif /* LINUX_NFSD_VFS_H */ -- cgit v1.1