summaryrefslogtreecommitdiffstats
path: root/include/linux/seq_file.h
diff options
context:
space:
mode:
authorAl Viro <viro@zeniv.linux.org.uk>2008-03-28 00:46:41 -0400
committerAl Viro <viro@zeniv.linux.org.uk>2008-04-21 23:14:02 -0400
commit521b5d0c40386f4a9805cdec7bd979fc96a86aeb (patch)
tree2193c12ee3dc0551790c79370603acb57e0f59e7 /include/linux/seq_file.h
parent4e1b36fb485dd81b0818ef1bc8fb5c0f2923a283 (diff)
downloadop-kernel-dev-521b5d0c40386f4a9805cdec7bd979fc96a86aeb.zip
op-kernel-dev-521b5d0c40386f4a9805cdec7bd979fc96a86aeb.tar.gz
[PATCH] teach seq_file to discard entries
Allow ->show() return SEQ_SKIP; that will discard all output from that element and move on. Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Diffstat (limited to 'include/linux/seq_file.h')
-rw-r--r--include/linux/seq_file.h2
1 files changed, 2 insertions, 0 deletions
diff --git a/include/linux/seq_file.h b/include/linux/seq_file.h
index 1da1e62..d65796d 100644
--- a/include/linux/seq_file.h
+++ b/include/linux/seq_file.h
@@ -30,6 +30,8 @@ struct seq_operations {
int (*show) (struct seq_file *m, void *v);
};
+#define SEQ_SKIP 1
+
int seq_open(struct file *, const struct seq_operations *);
ssize_t seq_read(struct file *, char __user *, size_t, loff_t *);
loff_t seq_lseek(struct file *, loff_t, int);
OpenPOWER on IntegriCloud