mirror of
https://github.com/raspberrypi/linux.git
synced 2025-12-06 01:49:46 +00:00
vfs: add d_real_inode() helper
commit a118084432 upstream.
Needed by the following fix.
Signed-off-by: Miklos Szeredi <mszeredi@redhat.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
This commit is contained in:
committed by
Greg Kroah-Hartman
parent
2ce30374d2
commit
8b8b6b53d3
@@ -576,5 +576,17 @@ static inline struct inode *vfs_select_inode(struct dentry *dentry,
|
||||
return inode;
|
||||
}
|
||||
|
||||
/**
|
||||
* d_real_inode - Return the real inode
|
||||
* @dentry: The dentry to query
|
||||
*
|
||||
* If dentry is on an union/overlay, then return the underlying, real inode.
|
||||
* Otherwise return d_inode().
|
||||
*/
|
||||
static inline struct inode *d_real_inode(struct dentry *dentry)
|
||||
{
|
||||
return d_backing_inode(d_real(dentry));
|
||||
}
|
||||
|
||||
|
||||
#endif /* __LINUX_DCACHE_H */
|
||||
|
||||
Reference in New Issue
Block a user