diff options
Diffstat (limited to 'fs/proc/internal.h')
-rw-r--r-- | fs/proc/internal.h | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/fs/proc/internal.h b/fs/proc/internal.h index c529b5f16ee4..86a24060e1b9 100644 --- a/fs/proc/internal.h +++ b/fs/proc/internal.h @@ -84,6 +84,24 @@ struct proc_maps_private { void proc_init_inodecache(void); +/* + * General functions + */ +static inline struct proc_inode *PROC_I(const struct inode *inode) +{ + return container_of(inode, struct proc_inode, vfs_inode); +} + +static inline struct proc_dir_entry *PDE(const struct inode *inode) +{ + return PROC_I(inode)->pde; +} + +static inline void *__PDE_DATA(const struct inode *inode) +{ + return PDE(inode)->data; +} + static inline struct pid *proc_pid(struct inode *inode) { return PROC_I(inode)->pid; |