On Thu, Nov 5, 2020 at 6:39 AM Chengguang Xu <cgxu519@xxxxxxxxxxxx> wrote: > > Hello, > > I have a question about opening file of underlying filesystem in overlayfs, > > why we use overlayfs' path(vfsmount/dentry) struct for underlying fs' file > > in ovl_open_realfile()? Is it by design? Sure. open_with_fake_path() is only used by overlayfs. IIRC, one of the reasons was to display the user expected path in /proc/<pid>/maps. There may have been other reasons. Thanks, Amir. > > > Thanks, > Chengguang