All of lore.kernel.org
 help / color / mirror / Atom feed
* Why do we pass in a directory and a dentry to lookup() and rename()
@ 2010-12-26 21:45 Theodore Ts'o
       [not found] ` <AANLkTikS1BMu+DyZEVZ9H6daoh5dJM7uGPUB9ugdHuRA@mail.gmail.com>
  2010-12-28  9:46 ` Neil Brown
  0 siblings, 2 replies; 4+ messages in thread
From: Theodore Ts'o @ 2010-12-26 21:45 UTC (permalink / raw)
  To: Al Viro; +Cc: linux-fsdevel

In the inode operations functions lookup() and rename():

	struct dentry * (*lookup)(struct inode *inode,
	       	      		  struct dentry *dentry,
				  struct nameidata *nd);

	int (*rename)(struct inode *old_dir, struct dentry *old_dentry,
	    	      struct inode *new_dir, struct dentry *new_entry);

... is the fact that we pass in the inode superfluous?

i.e., it looks like in all cases one can obtain the inode by looking at
dentry->d_parent.  Or am I missing something?

Thanks,

							- Ted

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2011-01-05 11:26 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2010-12-26 21:45 Why do we pass in a directory and a dentry to lookup() and rename() Theodore Ts'o
     [not found] ` <AANLkTikS1BMu+DyZEVZ9H6daoh5dJM7uGPUB9ugdHuRA@mail.gmail.com>
2010-12-27  5:50   ` Ted Ts'o
2010-12-28  9:46 ` Neil Brown
2011-01-05 11:26   ` Al Viro

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.