Re: [PATCH 08/13] xfs: refactor xfs_qm_dqtobp and xfs_qm_dqalloc

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



>  /*
> + * Ensure that the given in-core dquot has a buffer on disk backing it, and
> + * return the buffer. This is called when the bmapi finds a hole.
>   */
>  STATIC int
> +xfs_qm_dqalloc_ondisk(
> +	struct xfs_trans	**tpp,
> +	struct xfs_dquot	*dqp,
> +	struct xfs_buf		**bpp)
>  {
> +	struct xfs_bmbt_irec	map;
> +	struct xfs_defer_ops	dfops;
> +	struct xfs_mount	*mp = (*tpp)->t_mountp;
> +	struct xfs_buf		*bp;
> +	struct xfs_inode	*quotip;
> +	xfs_fsblock_t		firstblock;
> +	int			nmaps = 1;
> +	int			error;
>  
>  	trace_xfs_dqalloc(dqp);
>  
> +	quotip = xfs_quota_inode(mp, dqp->dq_flags);

I'd initialize quotip on the line where it is declarated.

> +xfs_qm_dqread_ondisk(
> +	struct xfs_mount	*mp,
> +	struct xfs_dquot	*dqp,
> +	struct xfs_buf		**bpp)
>  {
>  	struct xfs_bmbt_irec	map;
>  	struct xfs_buf		*bp;
>  	struct xfs_inode	*quotip;
>  	uint			lock_mode;
> +	int			nmaps = 1;
> +	int			error;
>  
> +	quotip = xfs_quota_inode(mp, dqp->dq_flags);

Same here?

Also shouldn't the function names be something like

xfs_dquot_disk_alloc and xfs_dquot_disk_read?
--
To unsubscribe from this list: send the line "unsubscribe linux-xfs" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html



[Index of Archives]     [XFS Filesystem Development (older mail)]     [Linux Filesystem Development]     [Linux Audio Users]     [Yosemite Trails]     [Linux Kernel]     [Linux RAID]     [Linux SCSI]


  Powered by Linux