public inbox for linux-xfs@vger.kernel.org
 help / color / mirror / Atom feed
From: Christoph Hellwig <hch@infradead.org>
To: Alex Elder <aelder@sgi.com>
Cc: Kevan Rehm <kfr@sgi.com>, xfs@oss.sgi.com
Subject: Re: [PATCH 3/8] xfsprogs: xfs_repair: don't set the root inode pointer
Date: Sun, 13 Nov 2011 07:01:33 -0500	[thread overview]
Message-ID: <20111113120133.GC19435@infradead.org> (raw)
In-Reply-To: <6833e89ecf7daa3ba69676fb98a4538ee6c3a1b5.1320955675.git.aelder@sgi.com>

On Thu, Nov 10, 2011 at 02:35:13PM -0600, Alex Elder wrote:
> From: Kevan Rehm <kfr@sgi.com>
> 
> In phase 6, in mk_root_dir(), xfs_repair initializes the mount
> point's m_rootip pointer without accounting for that reference.
> This field never really used or needed in repair otherwise, and the
> assigned pointer doesn't really represent a real reference to an
> inode that needs to be cached.  So just kill off this assignment.
> 
> Signed-off-by: Alex Elder <aelder@sgi.com>

Shouldn't this also have Kevan's signoff?

> ---
>  repair/phase6.c |    2 --
>  1 files changed, 0 insertions(+), 2 deletions(-)
> 
> diff --git a/repair/phase6.c b/repair/phase6.c
> index 1c82cb1..81d7fe6 100644
> --- a/repair/phase6.c
> +++ b/repair/phase6.c
> @@ -797,8 +797,6 @@ mk_root_dir(xfs_mount_t *mp)
>  	ip->i_df.if_bytes = ip->i_df.if_real_bytes = 0;
>  	ip->i_df.if_u1.if_extents = NULL;
>  
> -	mp->m_rootip = ip;
> -

Looks good, but can we extent this a bit?  The only reference to
mp->m_rootip in the userspace code is in libxfs_mount.  By making
it a local variable there we can kill the field entirely.

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

  reply	other threads:[~2011-11-13 12:01 UTC|newest]

Thread overview: 19+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-11-10 20:35 [PATCH 0/8] xfsprogs: new resvsp db command, plus some fixes Alex Elder
2011-11-10 20:35 ` [PATCH 1/8] xfsprogs: Fix setbitval() bug when nbits is byte-aligned Alex Elder
2011-11-10 20:35   ` [PATCH 2/8] xfsprogs: unconditionally drop used buffer reference Alex Elder
2011-11-13 11:59     ` Christoph Hellwig
2011-11-10 20:35   ` [PATCH 3/8] xfsprogs: xfs_repair: don't set the root inode pointer Alex Elder
2011-11-13 12:01     ` Christoph Hellwig [this message]
2012-02-07 18:38       ` Christoph Hellwig
2012-02-07 20:25         ` Kevan Rehm
2012-02-07 21:46           ` Kevan Rehm
2011-11-10 20:35   ` [PATCH 4/8] xfsprogs: mkfs.xfs: let libxfs_umount() do its thing Alex Elder
2011-11-13 12:04     ` Christoph Hellwig
2011-11-10 20:35   ` [PATCH 5/8] xfsprogs: Drop root inode refrerence in libxfs_umount() Alex Elder
2011-11-13 12:07     ` Christoph Hellwig
2011-11-10 20:35   ` [PATCH 6/8] xfsprogs: xfs_db: unmount fs before exiting Alex Elder
2011-11-13 12:09     ` Christoph Hellwig
2011-11-10 20:35   ` [PATCH 7/8] xfsprogs: clean up errors in libxfs_mount() consistently Alex Elder
2011-11-14 10:28     ` Christoph Hellwig
2011-11-10 20:35   ` [PATCH 8/8] xfsprogs: xfs_db: add new "resvsp" command Alex Elder
2011-11-11  1:29     ` 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=20111113120133.GC19435@infradead.org \
    --to=hch@infradead.org \
    --cc=aelder@sgi.com \
    --cc=kfr@sgi.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