public inbox for linux-xfs@vger.kernel.org
 help / color / mirror / Atom feed
From: Christoph Hellwig <hch@infradead.org>
To: Dave Chinner <david@fromorbit.com>
Cc: xfs@oss.sgi.com
Subject: Re: [PATCH 2/4] XFS: Use the inode tree for finding dirty inodes
Date: Tue, 22 Jul 2008 00:28:29 -0400	[thread overview]
Message-ID: <20080722042829.GB27123@infradead.org> (raw)
In-Reply-To: <1216556394-17529-3-git-send-email-david@fromorbit.com>

On Sun, Jul 20, 2008 at 10:19:52PM +1000, Dave Chinner wrote:
> Update xfs_sync_inodes to walk the inode radix tree cache to find
> dirty inodes. This removes a huge bunch of nasty, messy code for
> traversing the mount inode list safely and removes another user of
> the mount inode list.

Looks good, some minor nits below:

>  	xfs_inode_t	*ip = NULL;
>  	bhv_vnode_t	*vp = NULL;

As you're touching most uses of vp what about just turning it
into a plain Linux inode?

> +	if (!pag->pag_ici_init)
> +		return 0;

I think it would be cleaner to move this into the caller and not even
call into this function for uninitialized AGs.

> +		read_lock(&pag->pag_ici_lock);
> +		nr_found = radix_tree_gang_lookup(&pag->pag_ici_root,
> +				(void**)&ip, first_index, 1);

This needs a big comment on why you're using the gang lookup for
a single lookup.  I guess that's because the gang lookup skips to
the next actually existing entry instead of returning NULL, but that's
not really obvious to the reader.

> +			VN_RELE(vp);

This should either be an iput or IRELE, VN_RELE is on it's way out.

Btw, all these also apply to the next patch, I won't comment on them
there again.

  reply	other threads:[~2008-07-22  4:27 UTC|newest]

Thread overview: 29+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-07-20 12:19 [PATCH 0/4] XFS: replace the mount inode list with radix tree traversals Dave Chinner
2008-07-20 12:19 ` [PATCH 1/4] XFS: Remove xfs_iflush_all and clean up xfs_finish_reclaim_all() Dave Chinner
2008-07-21  7:58   ` Christoph Hellwig
2008-07-21 11:33     ` Dave Chinner
2008-07-22  4:24       ` Christoph Hellwig
2008-07-20 12:19 ` [PATCH 2/4] XFS: Use the inode tree for finding dirty inodes Dave Chinner
2008-07-22  4:28   ` Christoph Hellwig [this message]
2008-07-22  5:30     ` Dave Chinner
2008-07-22  7:27       ` Christoph Hellwig
2008-07-23  0:05         ` Dave Chinner
2008-07-23  2:10           ` Mark Goodwin
2008-07-23  3:46             ` Eric Sandeen
2008-07-23  4:04               ` Mark Goodwin
2008-07-23  4:09                 ` Eric Sandeen
2008-07-23  5:00                   ` Mark Goodwin
2008-07-23  4:27                 ` Dave Chinner
2008-07-23  4:18             ` Dave Chinner
2008-07-23 15:37             ` Russell Cattelan
2008-07-24  6:02               ` Mark Goodwin
2008-07-25  3:55                 ` Russell Cattelan
2008-07-25  4:08                   ` Mark Goodwin
2008-07-25  5:40                     ` Russell Cattelan
2008-07-25  6:55                   ` Niv Sardi
2008-07-23 20:49             ` Christoph Hellwig
2008-07-24 11:46               ` Dave Chinner
2008-07-20 12:19 ` [PATCH 3/4] XFS: Traverse inode trees when releasing dquots Dave Chinner
2008-07-20 12:19 ` [PATCH 4/4] XFS: remove the mount inode list Dave Chinner
2008-07-22  4:29   ` Christoph Hellwig
2008-07-22  5:42     ` Dave Chinner

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=20080722042829.GB27123@infradead.org \
    --to=hch@infradead.org \
    --cc=david@fromorbit.com \
    --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