'\" t .\" Title: splice_from_pipe_feed .\" Author: [FIXME: author] [see http://docbook.sf.net/el/author] .\" Generator: DocBook XSL Stylesheets v1.79.1 .\" Date: January 2017 .\" Manual: splice API .\" Source: Kernel Hackers Manual 4.8.15 .\" Language: English .\" .TH "SPLICE_FROM_PIPE_FEE" "9" "January 2017" "Kernel Hackers Manual 4\&.8\&." "splice API" .\" ----------------------------------------------------------------- .\" * Define some portability stuff .\" ----------------------------------------------------------------- .\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ .\" http://bugs.debian.org/507673 .\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html .\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ .ie \n(.g .ds Aq \(aq .el .ds Aq ' .\" ----------------------------------------------------------------- .\" * set default formatting .\" ----------------------------------------------------------------- .\" disable hyphenation .nh .\" disable justification (adjust text to left margin only) .ad l .\" ----------------------------------------------------------------- .\" * MAIN CONTENT STARTS HERE * .\" ----------------------------------------------------------------- .SH "NAME" splice_from_pipe_feed \- feed available data from a pipe to a file .SH "SYNOPSIS" .HP \w'int\ splice_from_pipe_feed('u .BI "int splice_from_pipe_feed(struct\ pipe_inode_info\ *\ " "pipe" ", struct\ splice_desc\ *\ " "sd" ", splice_actor\ *\ " "actor" ");" .SH "ARGUMENTS" .PP \fIpipe\fR .RS 4 pipe to splice from .RE .PP \fIsd\fR .RS 4 information to \fIactor\fR .RE .PP \fIactor\fR .RS 4 handler that splices the data .RE .SH "DESCRIPTION" .PP This function loops over the pipe and calls \fIactor\fR to do the actual moving of a single struct pipe_buffer to the desired destination\&. It returns when there\*(Aqs no more buffers left in the pipe or if the requested number of bytes (\fIsd\fR\->total_len) have been copied\&. It returns a positive number (one) if the pipe needs to be filled with more data, zero if the required number of bytes have been copied and \-errno on error\&. .PP This, together with splice_from_pipe_{begin,end,next}, may be used to implement the functionality of \fB__splice_from_pipe\fR when locking is required around copying the pipe buffers to the destination\&. .SH "COPYRIGHT" .br