aboutsummaryrefslogtreecommitdiffstats
path: root/include/linux/pipe_fs_i.h
diff options
context:
space:
mode:
authorJens Axboe <jens.axboe@oracle.com>2007-06-12 15:17:17 -0400
committerJens Axboe <jens.axboe@oracle.com>2007-07-10 02:04:12 -0400
commitc66ab6fa705e1b2887a6d9246b798bdc526839e2 (patch)
tree764ece0ee44f937012dfaa1657709da548ed5b16 /include/linux/pipe_fs_i.h
parent71780f59e127bb281a9302d430495ca9586c14e7 (diff)
splice: abstract out actor data
For direct splicing (or private splicing), the output may not be a file. So abstract out the handling into a specified actor function and put the data in the splice_desc structure earlier, so we can build on top of that. This is the first step in better splice handling for drivers, and also for implementing vmsplice _to_ user memory. Signed-off-by: Jens Axboe <jens.axboe@oracle.com>
Diffstat (limited to 'include/linux/pipe_fs_i.h')
-rw-r--r--include/linux/pipe_fs_i.h10
1 files changed, 6 insertions, 4 deletions
diff --git a/include/linux/pipe_fs_i.h b/include/linux/pipe_fs_i.h
index c8884f971228..883ba9b78d3f 100644
--- a/include/linux/pipe_fs_i.h
+++ b/include/linux/pipe_fs_i.h
@@ -94,13 +94,15 @@ struct splice_desc {
94 94
95typedef int (splice_actor)(struct pipe_inode_info *, struct pipe_buffer *, 95typedef int (splice_actor)(struct pipe_inode_info *, struct pipe_buffer *,
96 struct splice_desc *); 96 struct splice_desc *);
97typedef int (splice_direct_actor)(struct pipe_inode_info *,
98 struct splice_desc *);
97 99
98extern ssize_t splice_from_pipe(struct pipe_inode_info *, struct file *, 100extern ssize_t splice_from_pipe(struct pipe_inode_info *, struct file *,
99 loff_t *, size_t, unsigned int, 101 loff_t *, size_t, unsigned int,
100 splice_actor *); 102 splice_actor *);
101 103extern ssize_t __splice_from_pipe(struct pipe_inode_info *,
102extern ssize_t __splice_from_pipe(struct pipe_inode_info *, struct file *, 104 struct splice_desc *, splice_actor *);
103 loff_t *, size_t, unsigned int, 105extern ssize_t splice_direct_to_actor(struct file *, struct splice_desc *,
104 splice_actor *); 106 splice_direct_actor *);
105 107
106#endif 108#endif