mirror of
https://github.com/Fishwaldo/Star64_linux.git
synced 2025-06-27 09:02:06 +00:00
[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>
This commit is contained in:
parent
4e1b36fb48
commit
521b5d0c40
3 changed files with 15 additions and 4 deletions
|
@ -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);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue