Loading fs/nfs/delegation.c +7 −4 Original line number Diff line number Diff line Loading @@ -585,20 +585,23 @@ int nfs_client_return_marked_delegations(struct nfs_client *clp) } /** * nfs_inode_return_delegation_noreclaim - return delegation, don't reclaim opens * nfs_inode_evict_delegation - return delegation, don't reclaim opens * @inode: inode to process * * Does not protect against delegation reclaims, therefore really only safe * to be called from nfs4_clear_inode(). * to be called from nfs4_clear_inode(). Guaranteed to always free * the delegation structure. */ void nfs_inode_return_delegation_noreclaim(struct inode *inode) void nfs_inode_evict_delegation(struct inode *inode) { struct nfs_delegation *delegation; delegation = nfs_inode_detach_delegation(inode); if (delegation != NULL) if (delegation != NULL) { set_bit(NFS_DELEGATION_INODE_FREEING, &delegation->flags); nfs_do_return_delegation(inode, delegation, 1); } } /** * nfs_inode_return_delegation - synchronously return a delegation Loading fs/nfs/delegation.h +1 −1 Original line number Diff line number Diff line Loading @@ -43,7 +43,7 @@ void nfs_inode_reclaim_delegation(struct inode *inode, const struct cred *cred, fmode_t type, const nfs4_stateid *stateid, unsigned long pagemod_limit); int nfs4_inode_return_delegation(struct inode *inode); int nfs_async_inode_return_delegation(struct inode *inode, const nfs4_stateid *stateid); void nfs_inode_return_delegation_noreclaim(struct inode *inode); void nfs_inode_evict_delegation(struct inode *inode); struct inode *nfs_delegation_find_inode(struct nfs_client *clp, const struct nfs_fh *fhandle); void nfs_server_return_all_delegations(struct nfs_server *); Loading fs/nfs/nfs4super.c +2 −2 Original line number Diff line number Diff line Loading @@ -92,8 +92,8 @@ static void nfs4_evict_inode(struct inode *inode) { truncate_inode_pages_final(&inode->i_data); clear_inode(inode); /* If we are holding a delegation, return it! */ nfs_inode_return_delegation_noreclaim(inode); /* If we are holding a delegation, return and free it */ nfs_inode_evict_delegation(inode); /* Note that above delegreturn would trigger pnfs return-on-close */ pnfs_return_layout(inode); pnfs_destroy_layout(NFS_I(inode)); Loading Loading
fs/nfs/delegation.c +7 −4 Original line number Diff line number Diff line Loading @@ -585,20 +585,23 @@ int nfs_client_return_marked_delegations(struct nfs_client *clp) } /** * nfs_inode_return_delegation_noreclaim - return delegation, don't reclaim opens * nfs_inode_evict_delegation - return delegation, don't reclaim opens * @inode: inode to process * * Does not protect against delegation reclaims, therefore really only safe * to be called from nfs4_clear_inode(). * to be called from nfs4_clear_inode(). Guaranteed to always free * the delegation structure. */ void nfs_inode_return_delegation_noreclaim(struct inode *inode) void nfs_inode_evict_delegation(struct inode *inode) { struct nfs_delegation *delegation; delegation = nfs_inode_detach_delegation(inode); if (delegation != NULL) if (delegation != NULL) { set_bit(NFS_DELEGATION_INODE_FREEING, &delegation->flags); nfs_do_return_delegation(inode, delegation, 1); } } /** * nfs_inode_return_delegation - synchronously return a delegation Loading
fs/nfs/delegation.h +1 −1 Original line number Diff line number Diff line Loading @@ -43,7 +43,7 @@ void nfs_inode_reclaim_delegation(struct inode *inode, const struct cred *cred, fmode_t type, const nfs4_stateid *stateid, unsigned long pagemod_limit); int nfs4_inode_return_delegation(struct inode *inode); int nfs_async_inode_return_delegation(struct inode *inode, const nfs4_stateid *stateid); void nfs_inode_return_delegation_noreclaim(struct inode *inode); void nfs_inode_evict_delegation(struct inode *inode); struct inode *nfs_delegation_find_inode(struct nfs_client *clp, const struct nfs_fh *fhandle); void nfs_server_return_all_delegations(struct nfs_server *); Loading
fs/nfs/nfs4super.c +2 −2 Original line number Diff line number Diff line Loading @@ -92,8 +92,8 @@ static void nfs4_evict_inode(struct inode *inode) { truncate_inode_pages_final(&inode->i_data); clear_inode(inode); /* If we are holding a delegation, return it! */ nfs_inode_return_delegation_noreclaim(inode); /* If we are holding a delegation, return and free it */ nfs_inode_evict_delegation(inode); /* Note that above delegreturn would trigger pnfs return-on-close */ pnfs_return_layout(inode); pnfs_destroy_layout(NFS_I(inode)); Loading