mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-30 11:41:38 -04:00
vfs: new d_init method
Allow filesystem to initialize dentry at allocation time. Signed-off-by: Miklos Szeredi <[email protected]> Signed-off-by: Al Viro <[email protected]>
This commit is contained in:
parent
17648b871d
commit
285b102d3b
4 changed files with 17 additions and 0 deletions
|
|
@ -15,6 +15,7 @@ prototypes:
|
|||
int (*d_compare)(const struct dentry *, const struct dentry *,
|
||||
unsigned int, const char *, const struct qstr *);
|
||||
int (*d_delete)(struct dentry *);
|
||||
int (*d_init)(struct dentry *);
|
||||
void (*d_release)(struct dentry *);
|
||||
void (*d_iput)(struct dentry *, struct inode *);
|
||||
char *(*d_dname)((struct dentry *dentry, char *buffer, int buflen);
|
||||
|
|
@ -30,6 +31,7 @@ d_weak_revalidate:no no yes no
|
|||
d_hash no no no maybe
|
||||
d_compare: yes no no maybe
|
||||
d_delete: no yes no no
|
||||
d_init: no no yes no
|
||||
d_release: no no yes no
|
||||
d_prune: no yes no no
|
||||
d_iput: no no yes no
|
||||
|
|
|
|||
|
|
@ -923,6 +923,7 @@ struct dentry_operations {
|
|||
int (*d_compare)(const struct dentry *, const struct dentry *,
|
||||
unsigned int, const char *, const struct qstr *);
|
||||
int (*d_delete)(const struct dentry *);
|
||||
int (*d_init)(struct dentry *);
|
||||
void (*d_release)(struct dentry *);
|
||||
void (*d_iput)(struct dentry *, struct inode *);
|
||||
char *(*d_dname)(struct dentry *, char *, int);
|
||||
|
|
@ -995,6 +996,8 @@ struct dentry_operations {
|
|||
always cache a reachable dentry. d_delete must be constant and
|
||||
idempotent.
|
||||
|
||||
d_init: called when a dentry is allocated
|
||||
|
||||
d_release: called when a dentry is really deallocated
|
||||
|
||||
d_iput: called when a dentry loses its inode (just prior to its
|
||||
|
|
|
|||
Loading…
Reference in a new issue