Lines Matching refs:fhp

181 nfsd_lookup_dentry(struct svc_rqst *rqstp, struct svc_fh *fhp,  in nfsd_lookup_dentry()  argument
190 dprintk("nfsd: nfsd_lookup(fh %s, %.*s)\n", SVCFH_fmt(fhp), len,name); in nfsd_lookup_dentry()
192 dparent = fhp->fh_dentry; in nfsd_lookup_dentry()
193 exp = exp_get(fhp->fh_export); in nfsd_lookup_dentry()
215 fh_lock_nested(fhp, I_MUTEX_PARENT); in nfsd_lookup_dentry()
252 nfsd_lookup(struct svc_rqst *rqstp, struct svc_fh *fhp, const char *name, in nfsd_lookup() argument
259 err = fh_verify(rqstp, fhp, S_IFDIR, NFSD_MAY_EXEC); in nfsd_lookup()
262 err = nfsd_lookup_dentry(rqstp, fhp, name, len, &exp, &dentry); in nfsd_lookup()
272 err = fh_compose(resfh, exp, dentry, fhp); in nfsd_lookup()
285 commit_metadata(struct svc_fh *fhp) in commit_metadata() argument
287 struct inode *inode = d_inode(fhp->fh_dentry); in commit_metadata()
290 if (!EX_ISSYNC(fhp->fh_export)) in commit_metadata()
328 nfsd_get_write_access(struct svc_rqst *rqstp, struct svc_fh *fhp, in nfsd_get_write_access() argument
331 struct inode *inode = d_inode(fhp->fh_dentry); in nfsd_get_write_access()
337 err = nfsd_permission(rqstp, fhp->fh_export, fhp->fh_dentry, in nfsd_get_write_access()
362 nfsd_setattr(struct svc_rqst *rqstp, struct svc_fh *fhp, struct iattr *iap, in nfsd_setattr() argument
380 get_write_count = !fhp->fh_dentry; in nfsd_setattr()
383 err = fh_verify(rqstp, fhp, ftype, accmode); in nfsd_setattr()
387 host_err = fh_want_write(fhp); in nfsd_setattr()
392 dentry = fhp->fh_dentry; in nfsd_setattr()
409 err = nfsd_get_write_access(rqstp, fhp, iap); in nfsd_setattr()
432 fh_lock(fhp); in nfsd_setattr()
434 fh_unlock(fhp); in nfsd_setattr()
441 err = nfserrno(commit_metadata(fhp)); in nfsd_setattr()
475 __be32 nfsd4_set_nfs4_label(struct svc_rqst *rqstp, struct svc_fh *fhp, in nfsd4_set_nfs4_label() argument
482 error = fh_verify(rqstp, fhp, 0 /* S_IFREG */, NFSD_MAY_SATTR); in nfsd4_set_nfs4_label()
486 dentry = fhp->fh_dentry; in nfsd4_set_nfs4_label()
494 __be32 nfsd4_set_nfs4_label(struct svc_rqst *rqstp, struct svc_fh *fhp, in nfsd4_set_nfs4_label() argument
501 __be32 nfsd4_vfs_fallocate(struct svc_rqst *rqstp, struct svc_fh *fhp, in nfsd4_vfs_fallocate() argument
512 error = commit_metadata(fhp); in nfsd4_vfs_fallocate()
562 nfsd_access(struct svc_rqst *rqstp, struct svc_fh *fhp, u32 *access, u32 *supported) in nfsd_access() argument
570 error = fh_verify(rqstp, fhp, 0, NFSD_MAY_NOP); in nfsd_access()
574 export = fhp->fh_export; in nfsd_access()
575 dentry = fhp->fh_dentry; in nfsd_access()
637 nfsd_open(struct svc_rqst *rqstp, struct svc_fh *fhp, umode_t type, in nfsd_open() argument
662 err = fh_verify(rqstp, fhp, type, may_flags); in nfsd_open()
666 path.mnt = fhp->fh_export->ex_path.mnt; in nfsd_open()
667 path.dentry = fhp->fh_dentry; in nfsd_open()
911 nfsd_vfs_write(struct svc_rqst *rqstp, struct svc_fh *fhp, struct file *file, in nfsd_vfs_write() argument
936 exp = fhp->fh_export; in nfsd_vfs_write()
979 __be32 nfsd_read(struct svc_rqst *rqstp, struct svc_fh *fhp, in nfsd_read() argument
986 err = nfsd_open(rqstp, fhp, S_IFREG, NFSD_MAY_READ, &file); in nfsd_read()
1005 nfsd_write(struct svc_rqst *rqstp, struct svc_fh *fhp, struct file *file, in nfsd_write() argument
1012 err = nfsd_permission(rqstp, fhp->fh_export, fhp->fh_dentry, in nfsd_write()
1016 err = nfsd_vfs_write(rqstp, fhp, file, offset, vec, vlen, cnt, in nfsd_write()
1019 err = nfsd_open(rqstp, fhp, S_IFREG, NFSD_MAY_WRITE, &file); in nfsd_write()
1024 err = nfsd_vfs_write(rqstp, fhp, file, offset, vec, vlen, in nfsd_write()
1043 nfsd_commit(struct svc_rqst *rqstp, struct svc_fh *fhp, in nfsd_commit() argument
1058 err = nfsd_open(rqstp, fhp, S_IFREG, in nfsd_commit()
1062 if (EX_ISSYNC(fhp->fh_export)) { in nfsd_commit()
1122 nfsd_create(struct svc_rqst *rqstp, struct svc_fh *fhp, in nfsd_create() argument
1139 err = fh_verify(rqstp, fhp, S_IFDIR, NFSD_MAY_CREATE); in nfsd_create()
1143 dentry = fhp->fh_dentry; in nfsd_create()
1154 host_err = fh_want_write(fhp); in nfsd_create()
1159 fh_lock_nested(fhp, I_MUTEX_PARENT); in nfsd_create()
1164 err = fh_compose(resfhp, fhp->fh_export, dchild, fhp); in nfsd_create()
1170 if (!fhp->fh_locked) { in nfsd_create()
1232 err2 = nfserrno(commit_metadata(fhp)); in nfsd_create()
1256 do_nfsd_create(struct svc_rqst *rqstp, struct svc_fh *fhp, in do_nfsd_create() argument
1275 err = fh_verify(rqstp, fhp, S_IFDIR, NFSD_MAY_EXEC); in do_nfsd_create()
1279 dentry = fhp->fh_dentry; in do_nfsd_create()
1288 host_err = fh_want_write(fhp); in do_nfsd_create()
1292 fh_lock_nested(fhp, I_MUTEX_PARENT); in do_nfsd_create()
1304 err = fh_verify(rqstp, fhp, S_IFDIR, NFSD_MAY_CREATE); in do_nfsd_create()
1309 err = fh_compose(resfhp, fhp->fh_export, dchild, fhp); in do_nfsd_create()
1366 fh_drop_write(fhp); in do_nfsd_create()
1372 fh_drop_write(fhp); in do_nfsd_create()
1399 err = nfserrno(commit_metadata(fhp)); in do_nfsd_create()
1408 fh_unlock(fhp); in do_nfsd_create()
1411 fh_drop_write(fhp); in do_nfsd_create()
1426 nfsd_readlink(struct svc_rqst *rqstp, struct svc_fh *fhp, char *buf, int *lenp) in nfsd_readlink() argument
1434 err = fh_verify(rqstp, fhp, S_IFLNK, NFSD_MAY_NOP); in nfsd_readlink()
1438 path.mnt = fhp->fh_export->ex_path.mnt; in nfsd_readlink()
1439 path.dentry = fhp->fh_dentry; in nfsd_readlink()
1472 nfsd_symlink(struct svc_rqst *rqstp, struct svc_fh *fhp, in nfsd_symlink() argument
1488 err = fh_verify(rqstp, fhp, S_IFDIR, NFSD_MAY_CREATE); in nfsd_symlink()
1492 host_err = fh_want_write(fhp); in nfsd_symlink()
1496 fh_lock(fhp); in nfsd_symlink()
1497 dentry = fhp->fh_dentry; in nfsd_symlink()
1506 err = nfserrno(commit_metadata(fhp)); in nfsd_symlink()
1507 fh_unlock(fhp); in nfsd_symlink()
1509 fh_drop_write(fhp); in nfsd_symlink()
1511 cerr = fh_compose(resfhp, fhp->fh_export, dnew, fhp); in nfsd_symlink()
1696 nfsd_unlink(struct svc_rqst *rqstp, struct svc_fh *fhp, int type, in nfsd_unlink() argument
1707 err = fh_verify(rqstp, fhp, S_IFDIR, NFSD_MAY_REMOVE); in nfsd_unlink()
1711 host_err = fh_want_write(fhp); in nfsd_unlink()
1715 fh_lock_nested(fhp, I_MUTEX_PARENT); in nfsd_unlink()
1716 dentry = fhp->fh_dentry; in nfsd_unlink()
1738 host_err = commit_metadata(fhp); in nfsd_unlink()
1877 nfsd_readdir(struct svc_rqst *rqstp, struct svc_fh *fhp, loff_t *offsetp, in nfsd_readdir() argument
1889 err = nfsd_open(rqstp, fhp, S_IFDIR, may_flags, &file); in nfsd_readdir()
1914 nfsd_statfs(struct svc_rqst *rqstp, struct svc_fh *fhp, struct kstatfs *stat, int access) in nfsd_statfs() argument
1918 err = fh_verify(rqstp, fhp, 0, NFSD_MAY_NOP | access); in nfsd_statfs()
1921 .mnt = fhp->fh_export->ex_path.mnt, in nfsd_statfs()
1922 .dentry = fhp->fh_dentry, in nfsd_statfs()