From: Jan Kara <jack@suse.cz>
To: Li Haifeng <omycle@gmail.com>
Cc: jack@suse.cz, linux-kernel@vger.kernel.org, linux-ext4@vger.kernel.org
Subject: Re: [PATCH] fix the outdated comment in ext2_nfs_get_inode()
Date: Tue, 30 Aug 2011 12:35:45 +0200 [thread overview]
Message-ID: <20110830103545.GA16202@quack.suse.cz> (raw)
In-Reply-To: <CAFNq8R62+5dLbDV3b_rtFgMwTZ2abW+h+tg013L=pij60tTRdw@mail.gmail.com>
On Tue 30-08-11 17:53:58, Li Haifeng wrote:
> The function iget referred by the comment is replaced by ext2_iget .
> And the ext2_read_inode() is not exist, the ext2_iget is "neater". So
> the comment is fixed here.
>
> Signed-off-by: Li Haifeng <omycle@gmail.com>
> ---
> fs/ext2/super.c | 6 ++----
> 1 files changed, 2 insertions(+), 4 deletions(-)
>
> diff --git a/fs/ext2/super.c b/fs/ext2/super.c
> index 1dd62ed..994ced3 100644
> --- a/fs/ext2/super.c
> +++ b/fs/ext2/super.c
> @@ -327,10 +327,8 @@ static struct inode *ext2_nfs_get_inode(struct
> super_block *sb,
> if (ino > le32_to_cpu(EXT2_SB(sb)->s_es->s_inodes_count))
> return ERR_PTR(-ESTALE);
>
> - /* iget isn't really right if the inode is currently unallocated!!
> - * ext2_read_inode currently does appropriate checks, but
> - * it might be "neater" to call ext2_get_inode first and check
> - * if the inode is valid.....
> + /*
> + * ext2_iget isn't really right if the inode is currently unallocated!!
OK, but we should keep there a note that ext2_iget() does appropriate
checks to handle stale inodes.
Honza
> */
> inode = ext2_iget(sb, ino);
> if (IS_ERR(inode))
> --
> 1.7.4.1
--
Jan Kara <jack@suse.cz>
SUSE Labs, CR
next prev parent reply other threads:[~2011-08-30 10:35 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-08-30 9:53 [PATCH] fix the outdated comment in ext2_nfs_get_inode() Li Haifeng
2011-08-30 10:35 ` Jan Kara [this message]
2011-08-30 11:29 ` Li Haifeng
-- strict thread matches above, loose matches on Subject: below --
2011-08-30 11:46 Li Haifeng
2011-08-30 12:11 Li Haifeng
2011-08-30 15:39 ` Jan Kara
2011-08-31 2:06 ` Li Haifeng
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=20110830103545.GA16202@quack.suse.cz \
--to=jack@suse.cz \
--cc=linux-ext4@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=omycle@gmail.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