[PATCH 12/15] xfs: use vfs inode nlink field everywhere

Christoph Hellwig hch at infradead.org
Wed Feb 17 01:35:06 CST 2016


> index 685c7a7..1408be3 100644
> --- a/libxfs/libxfs_api_defs.h
> +++ b/libxfs/libxfs_api_defs.h
> @@ -108,4 +108,8 @@
>  
>  #define xfs_verify_cksum		libxfs_verify_cksum
>  
> +/* inode link counts */
> +#define set_nlink(inode, nlink)	({ (inode)->i_nlink = (nlink); })
> +#define inc_nlink(inode)	(inode)->i_nlink++

Can we defines these as inlines?

> +		ip->i_vnode.i_nlink++;		/* account for . */

Shouldn't we use VFS_I() like everywhere else?



More information about the xfs mailing list