aboutsummaryrefslogtreecommitdiffstats
path: root/include/linux/dcache.h
diff options
context:
space:
mode:
Diffstat (limited to 'include/linux/dcache.h')
-rw-r--r--include/linux/dcache.h10
1 files changed, 10 insertions, 0 deletions
diff --git a/include/linux/dcache.h b/include/linux/dcache.h
index 7cb043d8f4e8..4bb4de8d95ea 100644
--- a/include/linux/dcache.h
+++ b/include/linux/dcache.h
@@ -161,6 +161,7 @@ struct dentry_operations {
161 struct vfsmount *(*d_automount)(struct path *); 161 struct vfsmount *(*d_automount)(struct path *);
162 int (*d_manage)(struct dentry *, bool); 162 int (*d_manage)(struct dentry *, bool);
163 struct inode *(*d_select_inode)(struct dentry *, unsigned); 163 struct inode *(*d_select_inode)(struct dentry *, unsigned);
164 struct dentry *(*d_real)(struct dentry *, struct inode *);
164} ____cacheline_aligned; 165} ____cacheline_aligned;
165 166
166/* 167/*
@@ -229,6 +230,7 @@ struct dentry_operations {
229#define DCACHE_OP_SELECT_INODE 0x02000000 /* Unioned entry: dcache op selects inode */ 230#define DCACHE_OP_SELECT_INODE 0x02000000 /* Unioned entry: dcache op selects inode */
230 231
231#define DCACHE_ENCRYPTED_WITH_KEY 0x04000000 /* dir is encrypted with a valid key */ 232#define DCACHE_ENCRYPTED_WITH_KEY 0x04000000 /* dir is encrypted with a valid key */
233#define DCACHE_OP_REAL 0x08000000
232 234
233extern seqlock_t rename_lock; 235extern seqlock_t rename_lock;
234 236
@@ -555,4 +557,12 @@ static inline struct dentry *d_backing_dentry(struct dentry *upper)
555 return upper; 557 return upper;
556} 558}
557 559
560static inline struct dentry *d_real(struct dentry *dentry)
561{
562 if (unlikely(dentry->d_flags & DCACHE_OP_REAL))
563 return dentry->d_op->d_real(dentry, NULL);
564 else
565 return dentry;
566}
567
558#endif /* __LINUX_DCACHE_H */ 568#endif /* __LINUX_DCACHE_H */