Print this page
4827 nfs4: slow file locking
4837 NFSv4 client lock retry delay upper limit should be shorter


 410 extern void     rp4_rmhash_locked(rnode4_t *);
 411 extern int      rtable4hash(nfs4_sharedfh_t *);
 412 
 413 extern vnode_t *makenfs4node(nfs4_sharedfh_t *, nfs4_ga_res_t *, struct vfs *,
 414                                 hrtime_t, cred_t *, vnode_t *, nfs4_fname_t *);
 415 extern vnode_t *makenfs4node_by_fh(nfs4_sharedfh_t *, nfs4_sharedfh_t *,
 416     nfs4_fname_t **, nfs4_ga_res_t *, mntinfo4_t *, cred_t *, hrtime_t);
 417 
 418 extern nfs4_opinst_t *r4mkopenlist(struct mntinfo4 *);
 419 extern void     r4releopenlist(nfs4_opinst_t *);
 420 extern int      r4find_by_fsid(mntinfo4_t *, fattr4_fsid *);
 421 
 422 /* Access cache calls */
 423 extern nfs4_access_type_t nfs4_access_check(rnode4_t *, uint32_t, cred_t *);
 424 extern void     nfs4_access_cache(rnode4_t *rp, uint32_t, uint32_t, cred_t *);
 425 extern int      nfs4_access_purge_rp(rnode4_t *);
 426 
 427 extern int      nfs4_free_data_reclaim(rnode4_t *);
 428 extern void     nfs4_rnode_invalidate(struct vfs *);
 429 
 430 extern time_t   r2lease_time(rnode4_t *);
 431 extern int      nfs4_directio(vnode_t *, int, cred_t *);
 432 
 433 /* shadow vnode functions */
 434 extern void     sv_activate(vnode_t **, vnode_t *, nfs4_fname_t **, int);
 435 extern vnode_t  *sv_find(vnode_t *, vnode_t *, nfs4_fname_t **);
 436 extern void     sv_update_path(vnode_t *, char *, char *);
 437 extern void     sv_inactive(vnode_t *);
 438 extern void     sv_exchange(vnode_t **);
 439 extern void     sv_uninit(svnode_t *);
 440 extern void     nfs4_clear_open_streams(rnode4_t *);
 441 
 442 /*
 443  * Mark cached attributes as timed out
 444  *
 445  * The caller must not be holding the rnode r_statelock mutex.
 446  */
 447 #define PURGE_ATTRCACHE4_LOCKED(rp)                             \
 448         rp->r_time_attr_inval = gethrtime();                 \
 449         rp->r_time_attr_saved = rp->r_time_attr_inval;            \
 450         rp->r_pathconf.pc4_xattr_valid = 0;                  \




 410 extern void     rp4_rmhash_locked(rnode4_t *);
 411 extern int      rtable4hash(nfs4_sharedfh_t *);
 412 
 413 extern vnode_t *makenfs4node(nfs4_sharedfh_t *, nfs4_ga_res_t *, struct vfs *,
 414                                 hrtime_t, cred_t *, vnode_t *, nfs4_fname_t *);
 415 extern vnode_t *makenfs4node_by_fh(nfs4_sharedfh_t *, nfs4_sharedfh_t *,
 416     nfs4_fname_t **, nfs4_ga_res_t *, mntinfo4_t *, cred_t *, hrtime_t);
 417 
 418 extern nfs4_opinst_t *r4mkopenlist(struct mntinfo4 *);
 419 extern void     r4releopenlist(nfs4_opinst_t *);
 420 extern int      r4find_by_fsid(mntinfo4_t *, fattr4_fsid *);
 421 
 422 /* Access cache calls */
 423 extern nfs4_access_type_t nfs4_access_check(rnode4_t *, uint32_t, cred_t *);
 424 extern void     nfs4_access_cache(rnode4_t *rp, uint32_t, uint32_t, cred_t *);
 425 extern int      nfs4_access_purge_rp(rnode4_t *);
 426 
 427 extern int      nfs4_free_data_reclaim(rnode4_t *);
 428 extern void     nfs4_rnode_invalidate(struct vfs *);
 429 

 430 extern int      nfs4_directio(vnode_t *, int, cred_t *);
 431 
 432 /* shadow vnode functions */
 433 extern void     sv_activate(vnode_t **, vnode_t *, nfs4_fname_t **, int);
 434 extern vnode_t  *sv_find(vnode_t *, vnode_t *, nfs4_fname_t **);
 435 extern void     sv_update_path(vnode_t *, char *, char *);
 436 extern void     sv_inactive(vnode_t *);
 437 extern void     sv_exchange(vnode_t **);
 438 extern void     sv_uninit(svnode_t *);
 439 extern void     nfs4_clear_open_streams(rnode4_t *);
 440 
 441 /*
 442  * Mark cached attributes as timed out
 443  *
 444  * The caller must not be holding the rnode r_statelock mutex.
 445  */
 446 #define PURGE_ATTRCACHE4_LOCKED(rp)                             \
 447         rp->r_time_attr_inval = gethrtime();                 \
 448         rp->r_time_attr_saved = rp->r_time_attr_inval;            \
 449         rp->r_pathconf.pc4_xattr_valid = 0;                  \