The single_ helpers will be used in fdinfo output to
eliminate code duplication.

Signed-off-by: Cyrill Gorcunov <[email protected]>
Cc: Pavel Emelyanov <[email protected]>
Cc: Oleg Nesterov <[email protected]>
Cc: Andrey Vagin <[email protected]>
Cc: Al Viro <[email protected]>
Cc: Alexey Dobriyan <[email protected]>
Cc: James Bottomley <[email protected]>
Cc: "Aneesh Kumar K.V" <[email protected]>
Cc: Alexey Dobriyan <[email protected]>
Cc: Matthew Helsley <[email protected]>
Cc: "J. Bruce Fields" <[email protected]>
Cc: "Aneesh Kumar K.V" <[email protected]>
Cc: Andrew Morton <[email protected]>
---
 fs/seq_file.c            |    9 ++++++---
 include/linux/seq_file.h |    3 +++
 2 files changed, 9 insertions(+), 3 deletions(-)

Index: linux-2.6.git/fs/seq_file.c
===================================================================
--- linux-2.6.git.orig/fs/seq_file.c
+++ linux-2.6.git/fs/seq_file.c
@@ -565,20 +565,23 @@ int seq_bitmap_list(struct seq_file *m,
 }
 EXPORT_SYMBOL(seq_bitmap_list);
 
-static void *single_start(struct seq_file *p, loff_t *pos)
+void *single_start(struct seq_file *p, loff_t *pos)
 {
        return NULL + (*pos == 0);
 }
+EXPORT_SYMBOL(single_start);
 
-static void *single_next(struct seq_file *p, void *v, loff_t *pos)
+void *single_next(struct seq_file *p, void *v, loff_t *pos)
 {
        ++*pos;
        return NULL;
 }
+EXPORT_SYMBOL(single_next);
 
-static void single_stop(struct seq_file *p, void *v)
+void single_stop(struct seq_file *p, void *v)
 {
 }
+EXPORT_SYMBOL(single_stop);
 
 int single_open(struct file *file, int (*show)(struct seq_file *, void *),
                void *data)
Index: linux-2.6.git/include/linux/seq_file.h
===================================================================
--- linux-2.6.git.orig/include/linux/seq_file.h
+++ linux-2.6.git/include/linux/seq_file.h
@@ -122,6 +122,9 @@ static inline int seq_nodemask_list(stru
        return seq_bitmap_list(m, mask->bits, MAX_NUMNODES);
 }
 
+void *single_start(struct seq_file *, loff_t *);
+void *single_next(struct seq_file *, void *, loff_t *);
+void single_stop(struct seq_file *, void *);
 int single_open(struct file *, int (*)(struct seq_file *, void *), void *);
 int single_open_size(struct file *, int (*)(struct seq_file *, void *), void 
*, size_t);
 int single_release(struct inode *, struct file *);

--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to [email protected]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Reply via email to