Lines Matching refs:fhp

530 fh_verify(struct svc_rqst *rqstp, struct svc_fh *fhp, int type, int access)  in fh_verify()  argument
532 struct knfsd_fh *fh = &fhp->fh_handle; in fh_verify()
538 dprintk("nfsd: fh_verify(%s)\n", SVCFH_fmt(fhp)); in fh_verify()
543 if (!fhp->fh_dentry) { in fh_verify()
659 fhp->fh_dentry = dentry; in fh_verify()
660 fhp->fh_export = exp; in fh_verify()
667 dentry = fhp->fh_dentry; in fh_verify()
668 exp = fhp->fh_export; in fh_verify()
791 fh_compose(struct svc_fh *fhp, struct svc_export *exp, struct dentry *dentry, struct svc_fh *ref_fh) in fh_compose() argument
811 if (fhp->fh_locked || fhp->fh_dentry) { in fh_compose()
815 if (fhp->fh_maxsize < NFS_FHSIZE) in fh_compose()
817 fhp->fh_maxsize, parent->d_name.name, dentry->d_name.name); in fh_compose()
819 fhp->fh_dentry = dentry; /* our internal copy */ in fh_compose()
820 fhp->fh_export = exp; in fh_compose()
826 memset(&fhp->fh_handle.fh_base, 0, NFS_FHSIZE); in fh_compose()
827 fhp->fh_handle.fh_size = NFS_FHSIZE; in fh_compose()
828 fhp->fh_handle.ofh_dcookie = 0xfeebbaca; in fh_compose()
829 fhp->fh_handle.ofh_dev = htonl((MAJOR(exp->ex_dev)<<16)| MINOR(exp->ex_dev)); in fh_compose()
830 fhp->fh_handle.ofh_xdev = fhp->fh_handle.ofh_dev; in fh_compose()
831 fhp->fh_handle.ofh_xino = ino_t_to_u32(exp->ex_ino); in fh_compose()
832 fhp->fh_handle.ofh_dirino = ino_t_to_u32(dentry->d_parent->d_inode->i_ino); in fh_compose()
834 _fh_update_old(dentry, exp, &fhp->fh_handle); in fh_compose()
836 fhp->fh_handle.fh_version = 1; in fh_compose()
837 fhp->fh_handle.fh_auth_type = 0; in fh_compose()
838 datap = fhp->fh_handle.fh_auth+0; in fh_compose()
841 fhp->fh_handle.fh_fsid_type = 1; in fh_compose()
844 fhp->fh_handle.fh_size = 2*4; in fh_compose()
846 fhp->fh_handle.fh_fsid_type = 0; in fh_compose()
850 fhp->fh_handle.fh_size = 3*4; in fh_compose()
853 int size = fhp->fh_maxsize/4 - 3; in fh_compose()
854 fhp->fh_handle.fh_fileid_type = in fh_compose()
856 fhp->fh_handle.fh_size += size*4; in fh_compose()
861 if (fhp->fh_handle.fh_fileid_type == 255) in fh_compose()
871 fh_update(struct svc_fh *fhp) in fh_update() argument
876 if (!fhp->fh_dentry) in fh_update()
879 dentry = fhp->fh_dentry; in fh_update()
882 if (fhp->fh_handle.fh_version != 1) { in fh_update()
883 _fh_update_old(dentry, fhp->fh_export, &fhp->fh_handle); in fh_update()
886 if (fhp->fh_handle.fh_fileid_type != 0) in fh_update()
888 datap = fhp->fh_handle.fh_auth+ in fh_update()
889 fhp->fh_handle.fh_size/4 -1; in fh_update()
890 size = (fhp->fh_maxsize - fhp->fh_handle.fh_size)/4; in fh_update()
891 fhp->fh_handle.fh_fileid_type = in fh_update()
892 _fh_update(dentry, fhp->fh_export, datap, &size); in fh_update()
893 fhp->fh_handle.fh_size += size*4; in fh_update()
915 fh_put(struct svc_fh *fhp) in fh_put() argument
917 struct dentry * dentry = fhp->fh_dentry; in fh_put()
919 fh_unlock(fhp); in fh_put()
920 fhp->fh_dentry = NULL; in fh_put()