diff options
Diffstat (limited to 'fs/proc')
-rw-r--r-- | fs/proc/base.c | 6 | ||||
-rw-r--r-- | fs/proc/inode.c | 2 | ||||
-rw-r--r-- | fs/proc/internal.h | 4 |
3 files changed, 6 insertions, 6 deletions
diff --git a/fs/proc/base.c b/fs/proc/base.c index fa0e6bee40fa..9562df760901 100644 --- a/fs/proc/base.c +++ b/fs/proc/base.c @@ -297,7 +297,7 @@ static int proc_fd_link(struct inode *inode, struct dentry **dentry, struct vfsm struct task_struct *task = proc_task(inode); struct files_struct *files; struct file *file; - int fd = proc_type(inode) - PROC_TID_FD_DIR; + int fd = proc_fd(inode); files = get_files_struct(task); if (files) { @@ -1368,7 +1368,6 @@ static struct inode *proc_pid_make_inode(struct super_block * sb, struct task_st */ get_task_struct(task); ei->task = task; - ei->type = ino; inode->i_uid = 0; inode->i_gid = 0; if (task_dumpable(task)) { @@ -1418,7 +1417,7 @@ static int tid_fd_revalidate(struct dentry *dentry, struct nameidata *nd) { struct inode *inode = dentry->d_inode; struct task_struct *task = proc_task(inode); - int fd = proc_type(inode) - PROC_TID_FD_DIR; + int fd = proc_fd(inode); struct files_struct *files; files = get_files_struct(task); @@ -1525,6 +1524,7 @@ static struct dentry *proc_lookupfd(struct inode * dir, struct dentry * dentry, if (!inode) goto out; ei = PROC_I(inode); + ei->fd = fd; files = get_files_struct(task); if (!files) goto out_unlock; diff --git a/fs/proc/inode.c b/fs/proc/inode.c index 722b9c463111..fbc94df138a7 100644 --- a/fs/proc/inode.c +++ b/fs/proc/inode.c @@ -95,7 +95,7 @@ static struct inode *proc_alloc_inode(struct super_block *sb) if (!ei) return NULL; ei->task = NULL; - ei->type = 0; + ei->fd = 0; ei->op.proc_get_link = NULL; ei->pde = NULL; inode = &ei->vfs_inode; diff --git a/fs/proc/internal.h b/fs/proc/internal.h index 0502f17b860d..6264b7a3a9f0 100644 --- a/fs/proc/internal.h +++ b/fs/proc/internal.h @@ -46,7 +46,7 @@ static inline struct task_struct *proc_task(struct inode *inode) return PROC_I(inode)->task; } -static inline int proc_type(struct inode *inode) +static inline int proc_fd(struct inode *inode) { - return PROC_I(inode)->type; + return PROC_I(inode)->fd; } |