VFS: Add a fallthrough flag for marking virtual dentries
Add a DCACHE_FALLTHRU flag to indicate that, in a layered filesystem, this is a virtual dentry that covers another one in a lower layer that should be used instead. This may be recorded on medium if directory integration is stored there. The flag can be set with d_set_fallthru() and tested with d_is_fallthru(). Original-author: Valerie Aurora <vaurora@redhat.com> Signed-off-by: David Howells <dhowells@redhat.com> Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
This commit is contained in:
parent
e7f7d2253c
commit
df1a085af1
2 changed files with 27 additions and 1 deletions
|
@ -223,6 +223,7 @@ struct dentry_operations {
|
|||
#define DCACHE_FILE_TYPE 0x00500000 /* Other file type (or fallthru to such) */
|
||||
|
||||
#define DCACHE_MAY_FREE 0x00800000
|
||||
#define DCACHE_FALLTHRU 0x01000000 /* Fall through to lower layer */
|
||||
|
||||
extern seqlock_t rename_lock;
|
||||
|
||||
|
@ -470,6 +471,14 @@ static inline bool d_is_positive(const struct dentry *dentry)
|
|||
return !d_is_negative(dentry);
|
||||
}
|
||||
|
||||
extern void d_set_fallthru(struct dentry *dentry);
|
||||
|
||||
static inline bool d_is_fallthru(const struct dentry *dentry)
|
||||
{
|
||||
return dentry->d_flags & DCACHE_FALLTHRU;
|
||||
}
|
||||
|
||||
|
||||
extern int sysctl_vfs_cache_pressure;
|
||||
|
||||
static inline unsigned long vfs_pressure_ratio(unsigned long val)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue