From: Christoph Hellwig <hch@infradead.org>
To: Carlos Maiolino <cmaiolino@redhat.com>
Cc: xfs@oss.sgi.com
Subject: Re: [PATCH 2/2] xfs_repair: Properly set lost+found inode as used
Date: Tue, 8 Nov 2011 14:07:00 -0500 [thread overview]
Message-ID: <20111108190700.GA7941@infradead.org> (raw)
In-Reply-To: <1320777990-6556-3-git-send-email-cmaiolino@redhat.com>
On Tue, Nov 08, 2011 at 04:46:30PM -0200, Carlos Maiolino wrote:
> This patch makes mk_orphanage() to properly set the inode link count of
> the recently allocated inode in the AVL tree, avoiding the lost+found
> directory to be bypass the link count check in phase7 and possibly leaving
> lost+found directory with a wrong link count.
Thanks a lot, this looks very good technically.
Unfortunately I have a few style nipicks anyway:
> @@ -875,6 +877,18 @@ mk_orphanage(xfs_mount_t *mp)
> ORPHANAGE, error);
> }
> ip->i_d.di_nlink++; /* account for . */
> + ino = ip->i_ino;
> +
> + irec = find_inode_rec(mp,
> + XFS_INO_TO_AGNO(mp, ino),
> + XFS_INO_TO_AGINO(mp,ino));
Please always use whitespaces after the comma.
> + ino_offset = get_inode_offset(mp, ino, irec);
> +
> + /* Set the inode allocated to lost+found as used in the AVL
> + * tree, so it is not bypassed in phase 7
> + */
The canonical comment style would be:
/*
* Mark the inode allocated to lost+found as used in the AVL tree
* so it is not skipped in phase 7.
*/
(also note the slight change in wording to make it easier to parse for
me, but I'm no native speaker either)
*
> + set_inode_used(irec,ino_offset);
> + add_inode_ref(irec,ino_offset);
Same whitespace comment as above here.
Feel free to add my:
Reviewed-by: Christoph Hellwig <hch@lst.de>
after these cosmetic fixups.
_______________________________________________
xfs mailing list
xfs@oss.sgi.com
http://oss.sgi.com/mailman/listinfo/xfs
next prev parent reply other threads:[~2011-11-08 19:07 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-11-08 18:46 [PATCH 0/2] Set lost+found inode as used after its allocation Carlos Maiolino
2011-11-08 18:46 ` [PATCH 1/2] xfs_repair: Add inline function to get avl tree node Carlos Maiolino
2011-11-08 18:56 ` Eric Sandeen
2011-11-08 19:02 ` Carlos Maiolino
2011-11-08 19:07 ` Christoph Hellwig
2011-11-08 18:46 ` [PATCH 2/2] xfs_repair: Properly set lost+found inode as used Carlos Maiolino
2011-11-08 18:55 ` Eric Sandeen
2011-11-08 19:07 ` Christoph Hellwig [this message]
-- strict thread matches above, loose matches on Subject: below --
2011-11-09 16:54 [PATCH 0/2] Set lost+found inode as used after its allocation Carlos Maiolino
2011-11-09 16:54 ` [PATCH 2/2] xfs_repair: Properly set lost+found inode as used Carlos Maiolino
2011-11-14 18:09 ` Ben Myers
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=20111108190700.GA7941@infradead.org \
--to=hch@infradead.org \
--cc=cmaiolino@redhat.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