[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Question on dentry structure
On Tue, 30 Jan 2001, Bob Dilworth wrote:
> However, it contains ONLY the file name and not the path to the file
> (e.g., it contains myfile.dat not /home/accounts/myfile.dat). There
> are a couple of other dentry structs that MAY point to the directory
> files that make up the path to the file (there should be a separate
> dentry object for each of the directory files). These structures are
> d_parent, d_child, or d_subdirs. Does anyone out there know which of
> the above 3 dentry structures provides the path to the directory files
The good news is, such a routine to generate the path exists. Look at
d_path() / __d_path(). An example usage can be found in
fs/proc/<something> proc_pid_read_maps().
enjoy !
john
--
"...except Alan Cox, but he's actually not human, but about
a thousand gnomes working in under-ground caves in Swansea."
- Linus Torvalds
-
Kernelnewbies: Help each other learn about the Linux kernel.
Archive: http://mail.nl.linux.org/
IRC Channel: irc.openprojects.net / #kernelnewbies
Web Page: http://www.surriel.com/kernelnewbies.shtml