public inbox for linux-xfs@vger.kernel.org
 help / color / mirror / Atom feed
From: Dave Chinner <david@fromorbit.com>
To: Christoph Hellwig <hch@infradead.org>
Cc: xfs@oss.sgi.com
Subject: Re: [PATCH 1/7] repair: parallelise phase 7
Date: Tue, 9 Feb 2016 11:12:34 +1100	[thread overview]
Message-ID: <20160209001234.GP27429@dastard> (raw)
In-Reply-To: <20160208085555.GD5534@infradead.org>

On Mon, Feb 08, 2016 at 12:55:55AM -0800, Christoph Hellwig wrote:
> > +	irec = findfirst_inode_rec(agno);
> > +
> > +	while (irec != NULL)  {
> > +		for (j = 0; j < XFS_INODES_PER_CHUNK; j++)  {
> > +			ASSERT(is_inode_confirmed(irec, j));
> > +
> > +			if (is_inode_free(irec, j))
> > +				continue;
> > +
> > +			ASSERT(no_modify || is_inode_reached(irec, j));
> > +
> > +			nrefs = num_inode_references(irec, j);
> > +			ASSERT(no_modify || nrefs > 0);
> > +
> > +			if (get_inode_disk_nlinks(irec, j) != nrefs)
> > +				update_inode_nlinks(wq->mp,
> > +					XFS_AGINO_TO_INO(wq->mp, agno,
> > +						irec->ino_startnum + j),
> > +					nrefs);
> > +		}
> > +		irec = next_ino_rec(irec);
> 
> Wouldn't this look be slightly cleaner as:
> 
> 	for (irec = findfirst_inode_rec(agno);
> 	     irec;
> 	     irec = next_ino_rec(irec)) {

Yup, done.

Cheers,

Dave.
-- 
Dave Chinner
david@fromorbit.com

_______________________________________________
xfs mailing list
xfs@oss.sgi.com
http://oss.sgi.com/mailman/listinfo/xfs

  reply	other threads:[~2016-02-09  0:12 UTC|newest]

Thread overview: 20+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-02-04 23:05 [PATCH 1/7 v2] repair: big broken filesystems cause pain Dave Chinner
2016-02-04 23:05 ` [PATCH 1/7] repair: parallelise phase 7 Dave Chinner
2016-02-08  8:55   ` Christoph Hellwig
2016-02-09  0:12     ` Dave Chinner [this message]
2016-02-04 23:05 ` [PATCH 2/7] repair: parallelise uncertin inode processing in phase 3 Dave Chinner
2016-02-08  8:58   ` Christoph Hellwig
2016-02-04 23:05 ` [PATCH 3/7] libxfs: directory node splitting does not have an extra block Dave Chinner
2016-02-05 14:20   ` Brian Foster
2016-02-08  9:00   ` Christoph Hellwig
2016-02-04 23:05 ` [PATCH 4/7] libxfs: don't discard dirty buffers Dave Chinner
2016-02-08  9:03   ` Christoph Hellwig
2016-02-04 23:05 ` [PATCH 5/7] libxfs: don't repeatedly shake unwritable buffers Dave Chinner
2016-02-08  9:03   ` Christoph Hellwig
2016-02-04 23:05 ` [PATCH 6/7] libxfs: keep unflushable buffers off the cache MRUs Dave Chinner
2016-02-05 14:22   ` Brian Foster
2016-02-08 10:06   ` Christoph Hellwig
2016-02-08 19:54     ` Dave Chinner
2016-02-04 23:05 ` [PATCH 7/7] libxfs: reset dirty buffer priority on lookup Dave Chinner
2016-02-05 14:23   ` Brian Foster
2016-02-08 10:08   ` Christoph Hellwig

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20160209001234.GP27429@dastard \
    --to=david@fromorbit.com \
    --cc=hch@infradead.org \
    --cc=xfs@oss.sgi.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox