Re: [PATCH 1/2] xfs: refactor xfs_bmap_count_blocks using newer btree helpers

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

 



> +		error = xfs_btree_count_blocks(cur, &btblocks);
> +		xfs_btree_del_cursor(cur, error);
> +		if (error)
> +			return error;
> +
> +		*count += btblocks - 1;

Can you throw in a comment explaining the -1 here?  Without doing
extra research I can't think of a reason why it would be there.

> +		/* fall through */
> +	case XFS_DINODE_FMT_EXTENTS:
> +		*nextents = xfs_bmap_count_leaves(ifp, count);
>  		return 0;

I don't think you need the return statement here as there is a return 0
just below it.



[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