[PATCH 02/14] libxfs: adjust refcounts in reflink btree
Dave Chinner
david at fromorbit.com
Wed Jul 1 18:32:28 CDT 2015
On Wed, Jul 01, 2015 at 04:10:22PM -0700, Darrick J. Wong wrote:
> On Wed, Jul 01, 2015 at 11:06:54AM +1000, Dave Chinner wrote:
> > On Thu, Jun 25, 2015 at 04:39:23PM -0700, Darrick J. Wong wrote:
> > > Provide a function to adjust the reference counts for a range of
> > > blocks in the reflink btree.
.....
> > > +{
> > > + struct xfs_btree_cur *cur;
> > > + int error;
> > > + int i, have;
> > > + bool real_crl; /* cbno/clen is on disk? */
> > > + xfs_agblock_t lbno, cbno, rbno; /* rlextent start */
> > > + xfs_extlen_t llen, clen, rlen; /* rlextent length */
> > > + xfs_nlink_t lnr, cnr, rnr; /* rlextent refcount */
> >
> > "num" is the usual shorthand for "number". And in this case, nr is
> > extremely ambiguous: Number of records, number of reflinks, some
> > other number? I can't easily tell when I read the code, so the
> > variable names need to be better. factoring will certainly help
> > here.
>
> "refc" as shorthand for reference count, perhaps?
refcnt is the usual self-documenting shorthand ;)
Cheers,
Dave.
--
Dave Chinner
david at fromorbit.com
More information about the xfs
mailing list