Re: Setting inode during lookup

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Tuesday 31 August 2004 20:00, Shehjar Tikoo wrote:
> Hi all.
Hi there,
>
> I have a query regarding lookups in VFS.Im using
> version 2.6.7.
>
> open_namei calls path_lookup, in case of a plain open,
> which in turn calls __emul_lookup_dentry,
> if the path is an absolute path.
> In __emul_lookup_dentry theres a call to path_walk
> which calls link_path_walk,
However, before calling __emul_lookup_dentry, two lines above we do the 
following: which means that we mostly assign the current->fs->altroot dentry 
to the nd->dentry, i.e. we assign the alternative root dentry of the current 
process to the dentry of the nameidata nd struct. 
875                         nd->dentry = dget(current->fs->altroot);

which means that we mostly assign the current->fs->altroot dentry to the 
nd->dentry, i.e. we assign the alternative root dentry of the current process 
to the dentry of the nameidata nd struct. What I can't tell you, though is, 
what exactly the alternative root is. :)
> now inside 
> link_path_lookup 
you mean here link_path_walk
> , nd->dentry->d_inode is being used to 
> arrive at the inode.
> but i cant figure out where we set nd->dentry->inode
> before we use it here.
Thus, we assign the altroot->d_inode to the inode in link_path_walk.
>
>
> Thanks
> Shehjar
>
>
Hope I can be of any help,
Boris.
>
>
> __________________________________
> Do you Yahoo!?
> New and Improved Yahoo! Mail - 100MB free storage!
> http://promotions.yahoo.com/new_mail
>
> --
> Kernelnewbies: Help each other learn about the Linux kernel.
> Archive:       http://mail.nl.linux.org/kernelnewbies/
> FAQ:           http://kernelnewbies.org/faq/

Attachment: pgpfkLQNvcWi5.pgp
Description: PGP signature


[Index of Archives]     [Newbies FAQ]     [Linux Kernel Mentors]     [Linux Kernel Development]     [IETF Annouce]     [Git]     [Networking]     [Security]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux RAID]     [Linux SCSI]     [Linux ACPI]
  Powered by Linux