aboutsummaryrefslogtreecommitdiffstats
path: root/include/linux/seq_file.h
diff options
context:
space:
mode:
Diffstat (limited to 'include/linux/seq_file.h')
-rw-r--r--include/linux/seq_file.h19
1 files changed, 6 insertions, 13 deletions
diff --git a/include/linux/seq_file.h b/include/linux/seq_file.h
index 67c2563961f3..5b5369c3c209 100644
--- a/include/linux/seq_file.h
+++ b/include/linux/seq_file.h
@@ -10,6 +10,7 @@ struct seq_operations;
10struct file; 10struct file;
11struct path; 11struct path;
12struct inode; 12struct inode;
13struct dentry;
13 14
14struct seq_file { 15struct seq_file {
15 char *buf; 16 char *buf;
@@ -30,6 +31,8 @@ struct seq_operations {
30 int (*show) (struct seq_file *m, void *v); 31 int (*show) (struct seq_file *m, void *v);
31}; 32};
32 33
34#define SEQ_SKIP 1
35
33int seq_open(struct file *, const struct seq_operations *); 36int seq_open(struct file *, const struct seq_operations *);
34ssize_t seq_read(struct file *, char __user *, size_t, loff_t *); 37ssize_t seq_read(struct file *, char __user *, size_t, loff_t *);
35loff_t seq_lseek(struct file *, loff_t, int); 38loff_t seq_lseek(struct file *, loff_t, int);
@@ -42,6 +45,9 @@ int seq_printf(struct seq_file *, const char *, ...)
42 __attribute__ ((format (printf,2,3))); 45 __attribute__ ((format (printf,2,3)));
43 46
44int seq_path(struct seq_file *, struct path *, char *); 47int seq_path(struct seq_file *, struct path *, char *);
48int seq_dentry(struct seq_file *, struct dentry *, char *);
49int seq_path_root(struct seq_file *m, struct path *path, struct path *root,
50 char *esc);
45 51
46int single_open(struct file *, int (*)(struct seq_file *, void *), void *); 52int single_open(struct file *, int (*)(struct seq_file *, void *), void *);
47int single_release(struct inode *, struct file *); 53int single_release(struct inode *, struct file *);
@@ -62,18 +68,5 @@ extern struct list_head *seq_list_start_head(struct list_head *head,
62extern struct list_head *seq_list_next(void *v, struct list_head *head, 68extern struct list_head *seq_list_next(void *v, struct list_head *head,
63 loff_t *ppos); 69 loff_t *ppos);
64 70
65struct net;
66struct seq_net_private {
67 struct net *net;
68};
69
70int seq_open_net(struct inode *, struct file *,
71 const struct seq_operations *, int);
72int seq_release_net(struct inode *, struct file *);
73static inline struct net *seq_file_net(struct seq_file *seq)
74{
75 return ((struct seq_net_private *)seq->private)->net;
76}
77
78#endif 71#endif
79#endif 72#endif