All of lore.kernel.org
 help / color / mirror / Atom feed
From: Al Viro <viro@ZenIV.linux.org.uk>
To: Nick Piggin <npiggin@gmail.com>
Cc: "J. R. Okajima" <hooanon05@yahoo.co.jp>,
	linux-fsdevel <linux-fsdevel@vger.kernel.org>,
	linux-kernel@vger.kernel.org
Subject: Re: vfs-scale, nd->inode after __do_follow_link()
Date: Fri, 14 Jan 2011 05:28:13 +0000	[thread overview]
Message-ID: <20110114052813.GZ19804@ZenIV.linux.org.uk> (raw)
In-Reply-To: <AANLkTinXPOSxHPtffqe3m5MWppDfr6kFVMsd6k7-dkic@mail.gmail.com>

On Fri, Jan 14, 2011 at 03:09:10PM +1100, Nick Piggin wrote:

> > + ? ? ? ? ? ? ? ? ? ? ? struct dentry *i = path.dentry->d_inode;
> > + ? ? ? ? ? ? ? ? ? ? ? if (!IS_ERR(cookie) && i->i_op->put_link)
> > + ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? i->i_op->put_link(path.dentry, &nd, cookie);
> > ? ? ? ? ? ? ? ? ? ? ? ?/* nd.path had been dropped */
> > ? ? ? ? ? ? ? ? ? ? ? ?nd.path = path;
> > ? ? ? ? ? ? ? ? ? ? ? ?goto out_path;
> 
> It should be the inode we followed, rather than the inode of the
> new path, I think.

And that's what the first argument of __do_follow_link() is.  I'm actually
tempted to rename it from path to symlink and make it const to clarify
the things a bit.

BTW, "i" as a name for local struct inode * is -><- that close to being a
shootable offense.  Please, rename to e.g. struct inode *link (and it's
struct inode, not struct dentry).

  parent reply	other threads:[~2011-01-14  5:28 UTC|newest]

Thread overview: 15+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-01-14  2:10 vfs-scale, nd->inode after __do_follow_link() J. R. Okajima
2011-01-14  2:33 ` J. R. Okajima
2011-01-14  4:09 ` Nick Piggin
2011-01-14  4:09   ` Nick Piggin
2011-01-14  4:41   ` J. R. Okajima
2011-01-14  5:28   ` Al Viro [this message]
2011-01-14  5:38     ` J. R. Okajima
2011-01-14  5:40       ` J. R. Okajima
2011-01-14  8:40     ` Nick Piggin
2011-01-14  9:17       ` Sedat Dilek
2011-01-14  9:17         ` Sedat Dilek
2011-01-14 23:34         ` J.H.
2011-01-15  1:20           ` [Ocfs2-devel] " J.H.
2011-01-15 18:16             ` Nick Piggin
2011-01-14 12:54       ` J. R. Okajima

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=20110114052813.GZ19804@ZenIV.linux.org.uk \
    --to=viro@zeniv.linux.org.uk \
    --cc=hooanon05@yahoo.co.jp \
    --cc=linux-fsdevel@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=npiggin@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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.