This will be needed later when getting the lowerdata path from the ovl_entry in ovl_lookup() before the dentry is set up. Signed-off-by: Alexander Larsson <alexl@xxxxxxxxxx> --- fs/overlayfs/overlayfs.h | 1 + fs/overlayfs/util.c | 11 +++++++++-- 2 files changed, 10 insertions(+), 2 deletions(-) diff --git a/fs/overlayfs/overlayfs.h b/fs/overlayfs/overlayfs.h index 477008186d18..3d14770dc711 100644 --- a/fs/overlayfs/overlayfs.h +++ b/fs/overlayfs/overlayfs.h @@ -395,6 +395,7 @@ void ovl_path_upper(struct dentry *dentry, struct path *path); void ovl_path_lower(struct dentry *dentry, struct path *path); void ovl_path_lowerdata(struct dentry *dentry, struct path *path); void ovl_i_path_real(struct inode *inode, struct path *path); +void ovl_entry_path_lowerdata(struct ovl_entry *oe, struct path *path); void ovl_entry_path_real(struct ovl_fs *ofs, struct ovl_entry *oe, struct dentry *upperdentry, struct path *path); enum ovl_path_type ovl_path_real(struct dentry *dentry, struct path *path); diff --git a/fs/overlayfs/util.c b/fs/overlayfs/util.c index 77c954591daa..17eff3e31239 100644 --- a/fs/overlayfs/util.c +++ b/fs/overlayfs/util.c @@ -242,9 +242,9 @@ void ovl_path_lower(struct dentry *dentry, struct path *path) } } -void ovl_path_lowerdata(struct dentry *dentry, struct path *path) +void ovl_entry_path_lowerdata(struct ovl_entry *oe, + struct path *path) { - struct ovl_entry *oe = OVL_E(dentry); struct ovl_path *lowerdata = ovl_lowerdata(oe); struct dentry *lowerdata_dentry = ovl_lowerdata_dentry(oe); @@ -262,6 +262,13 @@ void ovl_path_lowerdata(struct dentry *dentry, struct path *path) } } +void ovl_path_lowerdata(struct dentry *dentry, struct path *path) +{ + struct ovl_entry *oe = OVL_E(dentry); + + return ovl_entry_path_lowerdata(oe, path); +} + enum ovl_path_type ovl_path_real(struct dentry *dentry, struct path *path) { enum ovl_path_type type = ovl_path_type(dentry); -- 2.39.2