[pnfs] [PATCH 06/23] 2.6-latest pnfs client initalize pnfs inode fields

Benny Halevy bhalevy at panasas.com
Sun Dec 23 04:55:58 EST 2007


On Dec. 13, 2007, 22:51 +0200, andros at umich.edu wrote:
> From: Andy Adamson <andros at umich.edu>
> 
> Signed-off by: Andy Adamson<andros at umich.edu>
> ---
>  fs/nfs/inode.c |    5 +++++
>  1 files changed, 5 insertions(+), 0 deletions(-)
> 
> diff --git a/fs/nfs/inode.c b/fs/nfs/inode.c
> index 1929189..149c951 100644
> --- a/fs/nfs/inode.c
> +++ b/fs/nfs/inode.c
> @@ -1156,6 +1156,11 @@ struct inode *nfs_alloc_inode(struct super_block *sb)
>  	nfsi->acl_default = ERR_PTR(-EAGAIN);
>  #endif
>  #ifdef CONFIG_NFS_V4
> +#ifdef CONFIG_PNFS
> +	nfsi->pnfs_layout_state = 0;
> +	nfsi->current_layout = NULL;
> +	nfsi->layoutcommit_ctx = NULL;
> +#endif /* CONFIG_PNFS */
>  	nfsi->nfs4_acl = NULL;
>  #endif /* CONFIG_NFS_V4 */
>  	return &nfsi->vfs_inode;

OK if I move the ##ifdef CONFIG_PNFS block outside of the #ifdef CONFIG_NFS_V4
to keep the code structure as simple as possible?

Benny


More information about the pNFS mailing list