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 2/2] free partially initialized inodes using destroy_inode
Date: Thu, 23 Oct 2008 08:30:49 +1100	[thread overview]
Message-ID: <20081022213049.GS18495@disturbed> (raw)
In-Reply-To: <20081022163129.GC25556@infradead.org>

On Wed, Oct 22, 2008 at 12:31:29PM -0400, Christoph Hellwig wrote:
> To make sure we free the security data inodes need to be freed using
> the proper VFS helper (which we also need to export for this). We mark
> these inodes bad so we can skip the flush path for them.

Looks good, except for one minor mistake in a comment:

> Index: xfs-2.6/fs/xfs/xfs_inode.h
> ===================================================================
> --- xfs-2.6.orig/fs/xfs/xfs_inode.h	2008-10-22 17:57:30.000000000 +0200
> +++ xfs-2.6/fs/xfs/xfs_inode.h	2008-10-22 18:00:15.000000000 +0200
> @@ -310,6 +310,23 @@ static inline struct inode *VFS_I(struct
>  }
>  
>  /*
> + * Get rid of a partially initialized inode.
> + *
> + * We have to go through destroy_inode to make sure allocations
> + * from init_inode_always like the security data are undone.
> + *
> + * We mark the inode dirty so that it takes the short cut in
                        ^^^^^
			"bad"

> + * the reclaim path instead of going through the flush path
> + * which doesn't make sense for an inode that has never seen the
> + * light of day.
> + */
> +static inline void xfs_destroy_inode(struct xfs_inode *ip)
> +{
> +	make_bad_inode(VFS_I(ip));
> +	return destroy_inode(VFS_I(ip));
> +}
> +
> +/*
>   * i_flags helper functions
>   */
>  static inline void

I don't think this needs another round of review just to fix the
comment, so it can probably go straight in if the committer can
touch up that comment.

Cheers,

Dave.
-- 
Dave Chinner
david@fromorbit.com

  reply	other threads:[~2008-10-22 21:29 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-10-22 16:31 [PATCH 2/2] free partially initialized inodes using destroy_inode Christoph Hellwig
2008-10-22 21:30 ` Dave Chinner [this message]
2008-10-23  4:58   ` Lachlan McIlroy

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=20081022213049.GS18495@disturbed \
    --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