VFS Operations - Path To Inode Translation

Given a (full or relative) path to a file, find its inode:

Entry function: user_path_walk, in include/linux/fs.h.
Actual lookup function: link_path_walk, in fs/namei.c.

  1. First, get the dentry to "/" (if it's a full path) or to "." (if it's a relative path).
  2. Start scanning the path, and follow via the dcache.
    1. Handle "." by skipping.
    2. Handle ".." using dentry->d_parent.
    3. Handle others via a cache lookup.
    4. If not found in the cache - ask the underlying filesystem to perform a real lookup.

Originally written by Valid HTML 4.01!guy keren