aboutsummaryrefslogtreecommitdiffstats
path: root/include
diff options
context:
space:
mode:
authorEric W. Biederman <ebiederm@xmission.com>2008-02-08 07:18:30 -0500
committerLinus Torvalds <torvalds@woody.linux-foundation.org>2008-02-08 12:22:23 -0500
commitbe614086a4aff163d5aa0dc160638d1193b59cde (patch)
treef60781ec8485fa7c1a5324a9767ec762e38b7447 /include
parent94413d8807a3c511a3675be4ce27a4d16d6408ee (diff)
proc: implement proc_single_file_operations
Currently many /proc/pid files use a crufty precursor to the current seq_file api, and they don't have direct access to the pid_namespace or the pid of for which they are displaying data. So implement proc_single_file_operations to make the seq_file routines easy to use, and to give access to the full state of the pid of we are displaying data for. Signed-off-by: Eric W. Biederman <ebiederm@xmission.com> Cc: Oleg Nesterov <oleg@tv-sign.ru> Cc: Alexey Dobriyan <adobriyan@gmail.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'include')
-rw-r--r--include/linux/proc_fs.h3
1 files changed, 3 insertions, 0 deletions
diff --git a/include/linux/proc_fs.h b/include/linux/proc_fs.h
index e43551516831..b04ebf09fb91 100644
--- a/include/linux/proc_fs.h
+++ b/include/linux/proc_fs.h
@@ -262,6 +262,9 @@ extern void kclist_add(struct kcore_list *, void *, size_t);
262union proc_op { 262union proc_op {
263 int (*proc_get_link)(struct inode *, struct dentry **, struct vfsmount **); 263 int (*proc_get_link)(struct inode *, struct dentry **, struct vfsmount **);
264 int (*proc_read)(struct task_struct *task, char *page); 264 int (*proc_read)(struct task_struct *task, char *page);
265 int (*proc_show)(struct seq_file *m,
266 struct pid_namespace *ns, struct pid *pid,
267 struct task_struct *task);
265}; 268};
266 269
267struct proc_inode { 270struct proc_inode {