提交 891ae71d 编写于 作者: A Alexey Dobriyan 提交者: Linus Torvalds
上级 f6d2f584
...@@ -113,12 +113,12 @@ static inline void *__PDE_DATA(const struct inode *inode) ...@@ -113,12 +113,12 @@ static inline void *__PDE_DATA(const struct inode *inode)
return PDE(inode)->data; return PDE(inode)->data;
} }
static inline struct pid *proc_pid(struct inode *inode) static inline struct pid *proc_pid(const struct inode *inode)
{ {
return PROC_I(inode)->pid; return PROC_I(inode)->pid;
} }
static inline struct task_struct *get_proc_task(struct inode *inode) static inline struct task_struct *get_proc_task(const struct inode *inode)
{ {
return get_pid_task(proc_pid(inode), PIDTYPE_PID); return get_pid_task(proc_pid(inode), PIDTYPE_PID);
} }
......
...@@ -129,7 +129,7 @@ int open_related_ns(struct ns_common *ns, ...@@ -129,7 +129,7 @@ int open_related_ns(struct ns_common *ns,
struct ns_common *(*get_ns)(struct ns_common *ns)); struct ns_common *(*get_ns)(struct ns_common *ns));
/* get the associated pid namespace for a file in procfs */ /* get the associated pid namespace for a file in procfs */
static inline struct pid_namespace *proc_pid_ns(struct inode *inode) static inline struct pid_namespace *proc_pid_ns(const struct inode *inode)
{ {
return inode->i_sb->s_fs_info; return inode->i_sb->s_fs_info;
} }
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册