linux/fs/splice.c
<<
"v3."v3."vo/spa3.1"vospa3 class="lxr_search">"v3."v3."v3."v3. typ Search.1 "v3."vo/spa3.13."voinput typ "3.1 odiv id/ /1o/a>ospa3 class="comment">/*o/spa3.1/ /2o/a>ospa3 class="comment"> * "splice": joining two ropes together by interweaving their strands.o/spa3.1/ /3o/a>ospa3 class="comment"> *o/spa3.1/ /4o/a>ospa3 class="comment"> * This is the "extended pipe" func v3ality, where a pipe is used aso/spa3.1/ /5o/a>ospa3 class="comment"> * a3 arbitrary in-memory buffer. Think of a pipe as a small kernelo/spa3.1/ /6o/a>ospa3 class="comment"> * buffer that you ca3 use to transfer data from one end to the other.o/spa3.1/ /7o/a>ospa3 class="comment"> *o/spa3.1/ /8o/a>ospa3 class="comment"> * The tradi v3al unix read/write is extended with a "splice()" opera v3o/spa3.1/ /9o/a>ospa3 class="comment"> * that transfers data buffers to or from a pipe buffer.o/spa3.1/ > a>ospa3 class="comment"> *o/spa3.1/ 11o/a>ospa3 class="comment"> * Nam d by Larry McVoy, origi3al implementa v3 from Linus, extended byo/spa3.1/ 12o/a>ospa3 class="comment"> * Jens to support splicing to files, network, direct splicing, etc a3do/spa3.1/ 13o/a>ospa3 class="comment"> * fixing lots of bugs.o/spa3.1/ 14o/a>ospa3 class="comment"> *o/spa3.1/ 15o/a>ospa3 class="comment"> * Copyright (C) 2005-2006 Jens Axboe <axboe@kernel.dk>o/spa3.1/ 16o/a>ospa3 class="comment"> * Copyright (C) 2005-2006 Linus Tor ds <tor ds@osdl.org>o/spa3.1/ 17o/a>ospa3 class="comment"> * Copyright (C) 2006 Ingo Molnar <mingo@elte.hu>o/spa3.1/ 18o/a>ospa3 class="comment"> *o/spa3.1/ 19o/a>ospa3 class="comment"> */o/spa3.1/ 2 a>#include <linux/fs.h a>>1/ 21 a>#include <linux/file.h a>>1/ 22 a>#include <linux/pagemap.h a>>1/ 23 a>#include <linux/splice.h a>>1/ 24 a>#include <linux/memcontrol.h a>>1/ 25 a>#include <linux/mm_inline.h a>>1/ 26 a>#include <linux/swap.h a>>1/ 27 a>#include <linux/writeback.h a>>1/ 28 a>#include <linux/export.h a>>1/ 29 a>#include <linux/syscalls.h a>>1/ 3 a>#include <linux/uio.h a>>1/ 31 a>#include <linux/security.h a>>1/ 32 a>#include <linux/gfp.h a>>1/ 33 a>#include <linux/socket.h a>>1/ 34 a>1/ 35o/a>ospa3 class="comment">/*o/spa3.1/ 36o/a>ospa3 class="comment"> * Attempt to steal a page from a pipe buffer. This should perhaps go intoo/spa3.1/ 37o/a>ospa3 class="comment"> * a vm helper func v3, it's already simplified quite a bit by theo/spa3.1/ 38o/a>ospa3 class="comment"> * addi v3 of remove_mapping(). If success is returned, the caller mayo/spa3.1/ 39o/a>ospa3 class="comment"> * attempt to reuse this page for a3other desti3a v3.o/spa3.1/ 4 a>ospa3 class="comment"> */o/spa3.1/ 41 a>static int/oa href="+code=page_cache_pipe_buf_steal" class="sref">page_cache_pipe_buf_steal a>(struct/oa href="+code=pipe_inode_info" class="sref">pipe_inode_info a> *oa href="+code=pipe" class="sref">pipe a>,1/ 42 a> struct/oa href="+code=pipe_buffer" class="sref">pipe_buffer a> *oa href="+code=buf" class="sref">buf a>)1/ 43 a>{1/ 44 a> struct/oa href="+code=page" class="sref">page a> *oa href="+code=page" class="sref">page a> =/oa href="+code=buf" class="sref">buf a>->oa href="+code=page" class="sref">page a>;1/ 45 a> struct/oa href="+code=address_space" class="sref">address_space a> *oa href="+code=mapping" class="sref">mapping a>;1/ 46 a>1/ 47 a> oa href="+code=lock_page" class="sref">lock_page a>(oa href="+code=page" class="sref">page a>);1/ 48 a>1/ 49 a> oa href="+code=mapping" class="sref">mapping a> =/oa href="+code=page_mapping" class="sref">page_mapping a>(oa href="+code=page" class="sref">page a>);1/ 50 a> if (oa href="+code=mapping" class="sref">mapping a>) {1/ 51 a> oa href="+code=WARN_ON" class="sref">WARN_ON a>(!oa href="+code=PageUptodate" class="sref">PageUptodate a>(oa href="+code=page" class="sref">page a>));1/ 52 a>1/ 53 a> ospa3 class="comment">/*o/spa3.1/ 54o/a>ospa3 class="comment"> * At least for ext2 with nobh > v3, we need to wait v3o/spa3.1/ 55o/a>ospa3 class="comment"> * writeback completing n> this page, since we'll remove ito/spa3.1/ 56o/a>ospa3 class="comment"> * from the pagecache. Otherwise truncate wont/wait v3 theo/spa3.1/ 57o/a>ospa3 class="comment"> * page, allowing the disk blocks to be reused by someone elseo/spa3.1/ 58o/a>ospa3 class="comment"> * before we ac ually wrote our data to them. fs corrup v3o/spa3.1/ 59o/a>ospa3 class="comment"> * ensues.o/spa3.1/ 6 a>ospa3 class="comment"> */o/spa3.1/ 61 a> oa href="+code=wait_on_page_writeback" class="sref">wait_on_page_writeback a>(oa href="+code=page" class="sref">page a>);1/ 62 a>1/ 63 a> if (oa href="+code=page_has_private" class="sref">page_has_private a>(oa href="+code=page" class="sref">page a>) &&1/ 64 a> !oa href="+code=try_to_release_page" class="sref">try_to_release_page a>(oa href="+code=page" class="sref">page a>, oa href="+code=GFP_KERNEL" class="sref">GFP_KERNEL a>))1/ 65 a> goto oa href="+code=out_unlock" class="sref">out_unlock a>;1/ 66 a>1/ 67 a> ospa3 class="comment">/*o/spa3.1/ 68o/a>ospa3 class="comment"> * If we succeeded in removing the mapping, set LRU flago/spa3.1/ 69o/a>ospa3 class="comment"> * and return good.o/spa3.1/ 7 a>ospa3 class="comment"> */o/spa3.1/ 71 a> if (oa href="+code=remove_mapping" class="sref">remove_mapping a>(oa href="+code=mapping" class="sref">mapping a>, oa href="+code=page" class="sref">page a>)) {1/ 72 a> oa href="+code=buf" class="sref">buf a>->oa href="+code=flags" class="sref">flags a> |=/oa href="+code=PIPE_BUF_FLAG_LRU" class="sref">PIPE_BUF_FLAG_LRU a>;1/ 73 a> return 0;1/ 74 a> }1/ 75 a> }1/ 76 a>1/ 77 a> ospa3 class="comment">/*o/spa3.1/ 78o/a>ospa3 class="comment"> * Raced with truncate or failed to remove page from currento/spa3.1/ 79o/a>ospa3 class="comment"> * address space, unlock and return failure.o/spa3.1/ 8 a>ospa3 class="comment"> */o/spa3.1/ 81o/a>oa href="+code=out_unlock" class="sref">out_unlock a>:1/ 82 a> oa href="+code=unlock_page" class="sref">unlock_page a>(oa href="+code=page" class="sref">page a>);1/ 83 a> return 1;1/ 84 a>}1/ 85 a>1/ 86 a>static void/oa href="+code=page_cache_pipe_buf_release" class="sref">page_cache_pipe_buf_release a>(struct/oa href="+code=pipe_inode_info" class="sref">pipe_inode_info a> *oa href="+code=pipe" class="sref">pipe a>,1/ 87 a> struct/oa href="+code=pipe_buffer" class="sref">pipe_buffer a> *oa href="+code=buf" class="sref">buf a>)1/ 88 a>{1/ 89 a> oa href="+code=page_cache_release" class="sref">page_cache_release a>(oa href="+code=buf" class="sref">buf a>->oa href="+code=page" class="sref">page a>);1/ 90 a> oa href="+code=buf" class="sref">buf a>->oa href="+code=flags" class="sref">flags a> &= ~oa href="+code=PIPE_BUF_FLAG_LRU" class="sref">PIPE_BUF_FLAG_LRU a>;1/ 91 a>}1/ 92 a>1/ 93o/a>ospa3 class="comment">/*o/spa3.1/ 94o/a>ospa3 class="comment"> * Check whether the contents of buf is OK to access. Since the contento/spa3.1/ 95o/a>ospa3 class="comment"> * is a page cache page, IO may be in flight.o/spa3.1/ 96o/a>ospa3 class="comment"> */o/spa3.1/ 97 a>static int/oa href="+code=page_cache_pipe_buf_confirm" class="sref">page_cache_pipe_buf_confirm a>(struct/oa href="+code=pipe_inode_info" class="sref">pipe_inode_info a> *oa href="+code=pipe" class="sref">pipe a>,1/ 98 a> struct/oa href="+code=pipe_buffer" class="sref">pipe_buffer a> *oa href="+code=buf" class="sref">buf a>)1/ 99 a>{1/100 a> struct/oa href="+code=page" class="sref">page a> *oa href="+code=page" class="sref">page a> =/oa href="+code=buf" class="sref">buf a>->oa href="+code=page" class="sref">page a>;1/101 a> int/oa href="+code=err" class="sref">err a>;1/102 a>1/103 a> if (!oa href="+code=PageUptodate" class="sref">PageUptodate a>(oa href="+code=page" class="sref">page a>)) {1/104 a> oa href="+code=lock_page" class="sref">lock_page a>(oa href="+code=page" class="sref">page a>);1/105 a>1/106 a> ospa3 class="comment">/*o/spa3.1/107o/a>ospa3 class="comment"> * Page got truncated/unhashed. This will cause a 0-byteo/spa3.1/108o/a>ospa3 class="comment"> * splice, if this is the first page.o/spa3.1/109o/a>ospa3 class="comment"> */o/spa3.1/110 a> if (!oa href="+code=page" class="sref">page a>->oa href="+code=mapping" class="sref">mapping a>) {1/111 a> oa href="+code=err" class="sref">err a> =/-oa href="+code=ENODATA" class="sref">ENODATA a>;1/112 a> goto oa href="+code=error" class="sref">error a>;1/113 a> }1/114 a>1/115 a> ospa3 class="comment">/*o/spa3.1/116o/a>ospa3 class="comment"> * Uh oh, read-error from disk.o/spa3.1/117o/a>ospa3 class="comment"> */o/spa3.1/118 a> if (!oa href="+code=PageUptodate" class="sref">PageUptodate a>(oa href="+code=page" class="sref">page a>)) {1/119 a> oa href="+code=err" class="sref">err a> =/-oa href="+code=EIO" class="sref">EIO a>;1/120 a> goto oa href="+code=error" class="sref">error a>;1/121 a> }1/122 a>1/123 a> ospa3 class="comment">/*o/spa3.1/124o/a>ospa3 class="comment"> * Page is ok afterall, we are done.o/spa3.1/125o/a>ospa3 class="comment"> */o/spa3.1/126 a> oa href="+code=unlock_page" class="sref">unlock_page a>(oa href="+code=page" class="sref">page a>);1/127 a> }1/128 a>1/129 a> return 0;1/13 a>oa href="+code=error" class="sref">error a>:1/131 a> oa href="+code=unlock_page" class="sref">unlock_page a>(oa href="+code=page" class="sref">page a>);1/132 a> return oa href="+code=err" class="sref">err a>;1/133 a>}1/134 a>1/135o/a>const struct/oa href="+code=pipe_buf_opera v3s" class="sref">pipe_buf_opera v3s a> oa href="+code=page_cache_pipe_buf_ops" class="sref">page_cache_pipe_buf_ops a> =/{1/136 a> .oa href="+code=can_merge" class="sref">can_merge a> =/0,1/137 a> .oa href="+code=map" class="sref">map a> =/oa href="+code=generic_pipe_buf_map" class="sref">generic_pipe_buf_map a>,1/138 a> .oa href="+code=unmap" class="sref">unmap a> =/oa href="+code=generic_pipe_buf_unmap" class="sref">generic_pipe_buf_unmap a>,1/139 a> .oa href="+code=confirm" class="sref">confirm a> =/oa href="+code=page_cache_pipe_buf_confirm" class="sref">page_cache_pipe_buf_confirm a>,1/140 a> .oa href="+code=release" class="sref">release a> =/oa href="+code=page_cache_pipe_buf_release" class="sref">page_cache_pipe_buf_release a>,1/141 a> .oa href="+code=steal" class="sref">steal a> =/oa href="+code=page_cache_pipe_buf_steal" class="sref">page_cache_pipe_buf_steal a>,1/142 a> .oa href="+code=get" class="sref">get a> =/oa href="+code=generic_pipe_buf_get" class="sref">generic_pipe_buf_get a>,1/143 a>};1/144 a>1/145 a>static int/oa href="+code=user_page_pipe_buf_steal" class="sref">user_page_pipe_buf_steal a>(struct/oa href="+code=pipe_inode_info" class="sref">pipe_inode_info a> *oa href="+code=pipe" class="sref">pipe a>,1/146 a> struct/oa href="+code=pipe_buffer" class="sref">pipe_buffer a> *oa href="+code=buf" class="sref">buf a>)1/147 a>{1/148 a> if (!(oa href="+code=buf" class="sref">buf a>->oa href="+code=flags" class="sref">flags a> &/oa href="+code=PIPE_BUF_FLAG_GIFT" class="sref">PIPE_BUF_FLAG_GIFT a>))1/149 a> return 1;1/150 a>1/151 a> oa href="+code=buf" class="sref">buf a>->oa href="+code=flags" class="sref">flags a> |=/oa href="+code=PIPE_BUF_FLAG_LRU" class="sref">PIPE_BUF_FLAG_LRU a>;1/152 a> return oa href="+code=generic_pipe_buf_steal" class="sref">generic_pipe_buf_steal a>(oa href="+code=pipe" class="sref">pipe a>, oa href="+code=buf" class="sref">buf a>);1/153 a>}1/154 a>1/155 a>static const struct/oa href="+code=pipe_buf_opera v3s" class="sref">pipe_buf_opera v3s a> oa href="+code=user_page_pipe_buf_ops" class="sref">user_page_pipe_buf_ops a> =/{1/156 a> .oa href="+code=can_merge" class="sref">can_merge a> =/0,1/157 a> .oa href="+code=map" class="sref">map a> =/oa href="+code=generic_pipe_buf_map" class="sref">generic_pipe_buf_map a>,1/158 a> .oa href="+code=unmap" class="sref">unmap a> =/oa href="+code=generic_pipe_buf_unmap" class="sref">generic_pipe_buf_unmap a>,1/159 a> .oa href="+code=confirm" class="sref">confirm a> =/oa href="+code=generic_pipe_buf_confirm" class="sref">generic_pipe_buf_confirm a>,1/160 a> .oa href="+code=release" class="sref">release a> =/oa href="+code=page_cache_pipe_buf_release" class="sref">page_cache_pipe_buf_release a>,1/161 a> .oa href="+code=steal" class="sref">steal a> =/oa href="+code=user_page_pipe_buf_steal" class="sref">user_page_pipe_buf_steal a>,1/162 a> .oa href="+code=get" class="sref">get a> =/oa href="+code=generic_pipe_buf_get" class="sref">generic_pipe_buf_get a>,1/163 a>};1/164 a>1/165 a>static void/oa href="+code=wakeup_pipe_readers" class="sref">wakeup_pipe_readers a>(struct/oa href="+code=pipe_inode_info" class="sref">pipe_inode_info a> *oa href="+code=pipe" class="sref">pipe a>)1/166 a>{1/167 a> oa href="+code=smp_mb" class="sref">smp_mb a>();1/168 a> if (oa href="+code=waitqueue_ac ve" class="sref">waitqueue_ac ve a>(&oa href="+code=pipe" class="sref">pipe a>->oa href="+code=wait" class="sref">wait a>))1/169 a> oa href="+code=wake_up_interrup ble" class="sref">wake_up_interrup ble a>(&oa href="+code=pipe" class="sref">pipe a>->oa href="+code=wait" class="sref">wait a>);1/170 a> oa href="+code=kill_fasync" class="sref">kill_fasync a>(&oa href="+code=pipe" class="sref">pipe a>->oa href="+code=fasync_readers" class="sref">fasync_readers a>, oa href="+code=SIGIO" class="sref">SIGIO a>, oa href="+code=POLL_IN" class="sref">POLL_IN a>);1/171 a>}1/172 a>1/173o/a>ospa3 class="comment">/**o/spa3.1/174o/a>ospa3 class="comment"> * splice_to_pipe - fill passed data into a pipeo/spa3.1/175o/a>ospa3 class="comment"> * @pipe: pipe to fillo/spa3.1/176o/a>ospa3 class="comment"> * @spd: data to fillo/spa3.1/177o/a>ospa3 class="comment"> *o/spa3.1/178o/a>ospa3 class="comment"> * Descrip v3:o/spa3.1/179o/a>ospa3 class="comment"> * @spd contains a map of pages and len/offset tuples, along witho/spa3.1/18 a>ospa3 class="comment"> * the struct/pipe_buf_opera v3s associated with these pages. Thiso/spa3.1/181o/a>ospa3 class="comment"> * func v3 will link that data to the/pipe.o/spa3.1/182o/a>ospa3 class="comment"> *o/spa3.1/183o/a>ospa3 class="comment"> */o/spa3.1/184 a>oa href="+code=ssize_t" class="sref">ssize_t a> oa href="+code=splice_to_pipe" class="sref">splice_to_pipe a>(struct/oa href="+code=pipe_inode_info" class="sref">pipe_inode_info a> *oa href="+code=pipe" class="sref">pipe a>,1/185 a> struct/oa href="+code=splice_pipe_desc" class="sref">splice_pipe_desc a> *oa href="+code=spd" class="sref">spd a>)1/186 a>{1/187 a> unsigned int/oa href="+code=spd_pages" class="sref">spd_pages a> =/oa href="+code=spd" class="sref">spd a>->oa href="+code=nr_pages" class="sref">nr_pages a>;1/188 a> int/oa href="+code=ret" class="sref">ret a>,/oa href="+code=do_wakeup" class="sref">do_wakeup a>,/oa href="+code=page_nr" class="sref">page_nr a>;1/189 a>1/190 a> oa href="+code=ret" class="sref">ret a> =/0;1/191 a> oa href="+code=do_wakeup" class="sref">do_wakeup a> =/0;1/192 a> oa href="+code=page_nr" class="sref">page_nr a> =/0;1/193o/a>1/194 a> oa href="+code=pipe_lock" class="sref">pipe_lock a>(oa href="+code=pipe" class="sref">pipe a>);1/195 a>1/196 a> for (;;) {1/197 a> if (!oa href="+code=pipe" class="sref">pipe a>->oa href="+code=readers" class="sref">readers a>) {1/198 a> oa href="+code=send_sig" class="sref">send_sig a>(oa href="+code=SIGPIPE" class="sref">SIGPIPE a>,/oa href="+code=current" class="sref">currento/a>,/0);1/199 a> if (!oa href="+code=ret" class="sref">ret a>)1/200 a> oa href="+code=ret" class="sref">ret a> =/-oa href="+code=EPIPE" class="sref">EPIPE a>;1/201 a> break;1/202 a> }1/203o/a>1/204 a> if (oa href="+code=pipe" class="sref">pipe a>->oa href="+code=nrbufs" class="sref">nrbufs a> </oa href="+code=pipe" class="sref">pipe a>->oa href="+code=buffers" class="sref">buffers a>) {1/205 a> int/oa href="+code=newbuf" class="sref">newbuf a> =/(oa href="+code=pipe" class="sref">pipe a>->oa href="+code=curbuf" class="sref">curbuf a> +/oa href="+code=pipe" class="sref">pipe a>->oa href="+code=nrbufs" class="sref">nrbufs a>) &/(oa href="+code=pipe" class="sref">pipe a>->oa href="+code=buffers" class="sref">buffers a> - 1);1/206 a> struct/oa href="+code=pipe_buffer" class="sref">pipe_buffer a> *oa href="+code=buf" class="sref">buf a> =/oa href="+code=pipe" class="sref">pipe a>->oa href="+code=bufs" class="sref">bufs a> +/oa href="+code=newbuf" class="sref">newbuf a>;1/207o/a>1/208 a> oa href="+code=buf" class="sref">buf a>->oa href="+code=page" class="sref">page a> =/oa href="+code=spd" class="sref">spd a>->oa href="+code=pages" class="sref">pages a>[oa href="+code=page_nr" class="sref">page_nr a>];1/209 a> oa href="+code=buf" class="sref">buf a>->oa href="+code=offset" class="sref">offset a> =/oa href="+code=spd" class="sref">spd a>->oa href="+code=partial" class="sref">partial a>[oa href="+code=page_nr" class="sref">page_nr a>].oa href="+code=offset" class="sref">offset a>;1/210 a> oa href="+code=buf" class="sref">buf a>->oa href="+code=len" class="sref">len a> =/oa href="+code=spd" class="sref">spd a>->oa href="+code=partial" class="sref">partial a>[oa href="+code=page_nr" class="sref">page_nr a>].oa href="+code=len" class="sref">len a>;1/211 a> oa href="+code=buf" class="sref">buf a>->oa href="+code=private" class="sref">private a> =/oa href="+code=spd" class="sref">spd a>->oa href="+code=partial" class="sref">partial a>[oa href="+code=page_nr" class="sref">page_nr a>].oa href="+code=private" class="sref">private a>;1/212 a> oa href="+code=buf" class="sref">buf a>->oa href="+code=ops" class="sref">ops a> =/oa href="+code=spd" class="sref">spd a>->oa href="+code=ops" class="sref">ops a>;1/213 a> if (oa href="+code=spd" class="sref">spd a>->oa href="+code=flags" class="sref">flags a> &/oa href="+code=SPLICE_F_GIFT" class="sref">SPLICE_F_GIFT a>)1/214 a> oa href="+code=buf" class="sref">buf a>->oa href="+code=flags" class="sref">flags a> |=/oa href="+code=PIPE_BUF_FLAG_GIFT" class="sref">PIPE_BUF_FLAG_GIFT a>;1/215 a>1/216 a> oa href="+code=pipe" class="sref">pipe a>->oa href="+code=nrbufs" class="sref">nrbufs a>++;1/217 a> oa href="+code=page_nr" class="sref">page_nr a>++;1/218 a> oa href="+code=ret" class="sref">ret a> +=/oa href="+code=buf" class="sref">buf a>->oa href="+code=len" class="sref">len a>;1/219 a>1/220 a> if (oa href="+code=pipe" class="sref">pipe a>->oa href="+code=inode" class="sref">inode a>)1/221 a> oa href="+code=do_wakeup" class="sref">do_wakeup a> =/1;1/222 a>1/223 a> if (!--oa href="+code=spd" class="sref">spd a>->oa href="+code=nr_pages" class="sref">nr_pages a>)1/224 a> break;1/225 a> if (oa href="+code=pipe" class="sref">pipe a>->oa href="+code=nrbufs" class="sref">nrbufs a> </oa href="+code=pipe" class="sref">pipe a>->oa href="+code=buffers" class="sref">buffers a>)1/226 a> continue;1/227o/a>1/228 a> break;1/229 a> }1/230 a>1/231 a> if (oa href="+code=spd" class="sref">spd a>->oa href="+code=flags" class="sref">flags a> &/oa href="+code=SPLICE_F_NONBLOCK" class="sref">SPLICE_F_NONBLOCK a>) {1/232 a> if (!oa href="+code=ret" class="sref">ret a>)1/233 a> oa href="+code=ret" class="sref">ret a> =/-oa href="+code=EAGAIN" class="sref">EAGAIN a>;1/234 a> break;1/235 a> }1/236 a>1/237 a> if (oa href="+code=signal_pending" class="sref">signal_pending a>(oa href="+code=current" class="sref">currento/a>)) {1/238 a> if (!oa href="+code=ret" class="sref">ret a>)1/239 a> oa href="+code=ret" class="sref">ret a> =/-oa href="+code=ERESTARTSYS" class="sref">ERESTARTSYS a>;1/240 a> break;1/241 a> }1/242 a>1/243 a> if (oa href="+code=do_wakeup" class="sref">do_wakeup a>) {1/244 a> oa href="+code=smp_mb" class="sref">smp_mb a>();1/245 a> if (oa href="+code=waitqueue_ac ve" class="sref">waitqueue_ac ve a>(&oa href="+code=pipe" class="sref">pipe a>->oa href="+code=wait" class="sref">wait a>))1/246 a> oa href="+code=wake_up_interrup ble_sync" class="sref">wake_up_interrup ble_sync a>(&oa href="+code=pipe" class="sref">pipe a>->oa href="+code=wait" class="sref">wait a>);1/247 a> oa href="+code=kill_fasync" class="sref">kill_fasync a>(&oa href="+code=pipe" class="sref">pipe a>->oa href="+code=fasync_readers" class="sref">fasync_readers a>, oa href="+code=SIGIO" class="sref">SIGIO a>, oa href="+code=POLL_IN" class="sref">POLL_IN a>);1/248 a> oa href="+code=do_wakeup" class="sref">do_wakeup a> =/0;1/249 a> }1/250 a>1/251 a> oa href="+code=pipe" class="sref">pipe a>->oa href="+code=waiting_writers" class="sref">waiting_writers a>++;1/252 a> oa href="+code=pipe_wait" class="sref">pipe_wait a>(oa href="+code=pipe" class="sref">pipe a>);1/253 a> oa href="+code=pipe" class="sref">pipe a>->oa href="+code=waiting_writers" class="sref">waiting_writers a>--;1/254 a> }1/255 a>1/256 a> oa href="+code=pipe_unlock" class="sref">pipe_unlock a>(oa href="+code=pipe" class="sref">pipe a>);1/257o/a>1/258 a> if (oa href="+code=do_wakeup" class="sref">do_wakeup a>)1/259 a> oa href="+code=wakeup_pipe_readers" class="sref">wakeup_pipe_readers a>(oa href="+code=pipe" class="sref">pipe a>);1/260 a>1/261 a> while (oa href="+code=page_nr" class="sref">page_nr a> </oa href="+code=spd_pages" class="sref">spd_pages a>)1/262 a> oa href="+code=spd" class="sref">spd a>->oa href="+code=spd_release" class="sref">spd_release a>(oa href="+code=spd" class="sref">spd a>,/oa href="+code=page_nr" class="sref">page_nr a>++);1/263o/a>1/264 a> return oa href="+code=ret" class="sref">ret a>;1/265 a>}1/266 a>1/267 a>void/oa href="+code=spd_release_page" class="sref">spd_release_page a>(struct/oa href="+code=splice_pipe_desc" class="sref">splice_pipe_desc a> *oa href="+code=spd" class="sref">spd a>, unsigned int/oa href="+code=i" class="sref">i a>)1/268 a>{1/269 a> oa href="+code=page_cache_release" class="sref">page_cache_release a>(oa href="+code=spd" class="sref">spd a>->oa href="+code=pages" class="sref">pages a>[oa href="+code=i" class="sref">i a>]);1/270 a>}1/271 a>1/272o/a>ospa3 class="comment">/*o/spa3.1/273o/a>ospa3 class="comment"> * Check if we need to grow the/arrays holding pages and partial page spa3.1/274o/a>ospa3 class="comment"> * descrip v3s.o/spa3.1/275o/a>ospa3 class="comment"> */o/spa3.1/276o/a>int/oa href="+code=splice_grow_spd" class="sref">splice_grow_spd a>(const struct/oa href="+code=pipe_inode_info" class="sref">pipe_inode_info a> *oa href="+code=pipe" class="sref">pipe a>, struct/oa href="+code=splice_pipe_desc" class="sref">splice_pipe_desc a> *oa href="+code=spd" class="sref">spd a>)1/277 a>{1/278 a> unsigned int/oa href="+code=buffers" class="sref">buffers a> =/oa href="+code=ACCESS_ONCE" class="sref">ACCESS_ONCE a>(oa href="+code=pipe" class="sref">pipe a>->oa href="+code=buffers" class="sref">buffers a>);1/279 a>1/280 a> oa href="+code=spd" class="sref">spd a>->oa href="+code=nr_pages_max" class="sref">nr_pages_max a> =/oa href="+code=buffers" class="sref">buffers a>;1/281 a> if (oa href="+code=buffers" class="sref">buffers a> <=/oa href="+code=PIPE_DEF_BUFFERS" class="sref">PIPE_DEF_BUFFERS a>)1/282 a> return 0;1/283o/a>1/284 a> oa href="+code=spd" class="sref">spd a>->oa href="+code=pages" class="sref">pages a> =/oa href="+code=kmalloc" class="sref">kmalloc a>(oa href="+code=buffers" class="sref">buffers a> * sizeof(struct/oa href="+code=page" class="sref">page a> *),/oa href="+code=GFP_KERNEL" class="sref">GFP_KERNEL a>);1/285 a> oa href="+code=spd" class="sref">spd a>->oa href="+code=partial" class="sref">partial a> =/oa href="+code=kmalloc" class="sref">kmalloc a>(oa href="+code=buffers" class="sref">buffers a> * sizeof(struct/oa href="+code=partial_page" class="sref">partial_page a>),/oa href="+code=GFP_KERNEL" class="sref">GFP_KERNEL a>);1/286 a>1/287 a> if (oa href="+code=spd" class="sref">spd a>->oa href="+code=pages" class="sref">pages a> &&/oa href="+code=spd" class="sref">spd a>->oa href="+code=partial" class="sref">partial a>)1/288 a> return 0;1/289 a>1/290 a> oa href="+code=kfree" class="sref">kfree a>(oa href="+code=spd" class="sref">spd a>->oa href="+code=pages" class="sref">pages a>);1/291 a> oa href="+code=kfree" class="sref">kfree a>(oa href="+code=spd" class="sref">spd a>->oa href="+code=partial" class="sref">partial a>);1/292 a> return -oa href="+code=ENOMEM" class="sref">ENOMEM a>;1/293 a>}1/294 a>1/295 a>void/oa href="+code=splice_shrink_spd" class="sref">splice_shrink_spd a>(struct/oa href="+code=splice_pipe_desc" class="sref">splice_pipe_desc a> *oa href="+code=spd" class="sref">spd a>)1/296 a>{1/297 a> if (oa href="+code=spd" class="sref">spd a>->oa href="+code=nr_pages_max" class="sref">nr_pages_max a> <=/oa href="+code=PIPE_DEF_BUFFERS" class="sref">PIPE_DEF_BUFFERS a>)1/298 a> return;1/299 a>1/300 a> oa href="+code=kfree" class="sref">kfree a>(oa href="+code=spd" class="sref">spd a>->oa href="+code=pages" class="sref">pages a>);1/301 a> oa href="+code=kfree" class="sref">kfree a>(oa href="+code=spd" class="sref">spd a>->oa href="+code=partial" class="sref">partial a>);1/302 a>}1/303o/a>1/304 a>static int1/305 a>oa href="+code=__generic_file_splice_read" class="sref">__generic_file_splice_read a>(struct/oa href="+code=file" class="sref">file a> *oa href="+code=in" class="sref">in a>,/oa href="+code=loff_t" class="sref">loff_t a> *oa href="+code=ppos" class="sref">ppos a>,1/306 a> struct/oa href="+code=pipe_inode_info" class="sref">pipe_inode_info a> *oa href="+code=pipe" class="sref">pipe a>, oa href="+code=size_t" class="sref">size_t a> oa href="+code=len" class="sref">len a>,1/307 a> unsigned int/oa href="+code=flags" class="sref">flags a>)1/308 a>{1/309 a> struct/oa href="+code=address_space" class="sref">address_space a> *oa href="+code=mapping" class="sref">mapping a> =/oa href="+code=in" class="sref">in a>->oa href="+code=f_mapping" class="sref">f_mapping a>;1/310 a> unsigned int/oa href="+code=loff" class="sref">loff a>, oa href="+code=nr_pages" class="sref">nr_pages a>, oa href="+code=req_pages" class="sref">req_pages a>;1/311 a> struct/oa href="+code=page" class="sref">page a> *oa href="+code=pages" class="sref">pages a>[oa href="+code=PIPE_DEF_BUFFERS" class="sref">PIPE_DEF_BUFFERS a>];1/312 a> struct/oa href="+code=partial_page" class="sref">partial_page a>/oa href="+code=partial" class="sref">partial a>[oa href="+code=PIPE_DEF_BUFFERS" class="sref">PIPE_DEF_BUFFERS a>];1/313 a> struct/oa href="+code=page" class="sref">page a> *oa href="+code=page" class="sref">page a>;1/314 a> oa href="+code=pgoff_t" class="sref">pgoff_t a>/oa href="+code=index" class="sref">index a>, oa href="+code=end_index" class="sref">end_index a>;1/315 a> oa href="+code=loff_t" class="sref">loff_t a> oa href="+code=isize" class="sref">isize a>;1/316 a> int/oa href="+code=error" class="sref">error a>,/oa href="+code=page_nr" class="sref">page_nr a>;1/317 a> struct/oa href="+code=splice_pipe_desc" class="sref">splice_pipe_desc a> oa href="+code=spd" class="sref">spd a> =/{1/318 a> .oa href="+code=pages" class="sref">pages a> =/oa href="+code=pages" class="sref">pages a>,1/319 a> .oa href="+code=partial" class="sref">partial a> =/oa href="+code=partial" class="sref">partial a>,1/320 a> .oa href="+code=nr_pages_max" class="sref">nr_pages_max a> =/oa href="+code=PIPE_DEF_BUFFERS" class="sref">PIPE_DEF_BUFFERS a>,1/321 a> .oa href="+code=flags" class="sref">flags a> =/oa href="+code=flags" class="sref">flags a>,1/322 a> .oa href="+code=ops" class="sref">ops a> =/&oa href="+code=page_cache_pipe_buf_ops" class="sref">page_cache_pipe_buf_ops a>,1/323 a> .oa href="+code=spd_release" class="sref">spd_release a> =/oa href="+code=spd_release_page" class="sref">spd_release_page a>,1/324 a> };1/325 a>1/326 a> if (oa href="+code=splice_grow_spd" class="sref">splice_grow_spd a>(oa href="+code=pipe" class="sref">pipe a>, &oa href="+code=spd" class="sref">spd a>))1/327 a> return -oa href="+code=ENOMEM" class="sref">ENOMEM a>;1/328 a>1/329 a> oa href="+code=index" class="sref">index a> =/*oa href="+code=ppos" class="sref">ppos a> >>/oa href="+code=PAGE_CACHE_SHIFT" class="sref">PAGE_CACHE_SHIFT a>;1/330 a> oa href="+code=loff" class="sref">loff a> =/*oa href="+code=ppos" class="sref">ppos a> &/~oa href="+code=PAGE_CACHE_MASK" class="sref">PAGE_CACHE_MASK a>;1/331 a> oa href="+code=req_pages" class="sref">req_pages a> =/(oa href="+code=len" class="sref">len a> +/oa href="+code=loff" class="sref">loff a> +/oa href="+code=PAGE_CACHE_SIZE" class="sref">PAGE_CACHE_SIZE a> - 1) >>/oa href="+code=PAGE_CACHE_SHIFT" class="sref">PAGE_CACHE_SHIFT a>;1/332 a> oa href="+code=nr_pages" class="sref">nr_pages a> =/oa href="+code=min" class="sref">min a>(oa href="+code=req_pages" class="sref">req_pages a>, oa href="+code=spd" class="sref">spd a>.oa href="+code=nr_pages_max" class="sref">nr_pages_max a>);1/333o/a>1/334 a> ospa3 class="comment">/*o/spa3.1/335o/a>ospa3 class="comment"> * Lookup the/(hopefully) full range of pages we need.o/spa3.1/336o/a>ospa3 class="comment"> */o/spa3.1/337 a> oa href="+code=spd" class="sref">spd a>.oa href="+code=nr_pages" class="sref">nr_pages a> =/oa href="+code=find_get_pages_contig" class="sref">find_get_pages_contig a>(oa href="+code=mapping" class="sref">mapping a>, oa href="+code=index" class="sref">index a>, oa href="+code=nr_pages" class="sref">nr_pages a>, oa href="+code=spd" class="sref">spd a>.oa href="+code=pages" class="sref">pages a>);1/338 a> oa href="+code=index" class="sref">index a> +=/oa href="+code=spd" class="sref">spd a>.oa href="+code=nr_pages" class="sref">nr_pages a>;1/339 a>1/340 a> ospa3 class="comment">/*o/spa3.1/341o/a>ospa3 class="comment"> * If find_get_pages_contig() returned fewer pages tha3 we needed,o/spa3.1/342o/a>ospa3 class="comment"> * readahead/allocate the/rest and fill in the/holes.o/spa3.1/343o/a>ospa3 class="comment"> */o/spa3.1/344 a> if (oa href="+code=spd" class="sref">spd a>.oa href="+code=nr_pages" class="sref">nr_pages a> </oa href="+code=nr_pages" class="sref">nr_pages a>)1/345 a> oa href="+code=page_cache_sync_readahead" class="sref">page_cache_sync_readahead a>(oa href="+code=mapping" class="sref">mapping a>, &oa href="+code=in" class="sref">in a>->oa href="+code=f_ra" class="sref">f_ra a>, oa href="+code=in" class="sref">in a>,1/346 a> oa href="+code=index" class="sref">index a>, oa href="+code=req_pages" class="sref">req_pages a> -/oa href="+code=spd" class="sref">spd a>.oa href="+code=nr_pages" class="sref">nr_pages a>);1/347o/a>1/348 a> oa href="+code=error" class="sref">error a> =/0;1/349 a> while (oa href="+code=spd" class="sref">spd a>.oa href="+code=nr_pages" class="sref">nr_pages a> </oa href="+code=nr_pages" class="sref">nr_pages a>)/{1/350 a> ospa3 class="comment">/*o/spa3.1/351o/a>ospa3 class="comment"> * Page could be there, find_get_pages_contig() breaks ono/spa3.1/352o/a>ospa3 class="comment"> * the/first hole.o/spa3.1/353o/a>ospa3 class="comment"> */o/spa3.1/354 a> oa href="+code=page" class="sref">page a> =/oa href="+code=find_get_page" class="sref">find_get_page a>(oa href="+code=mapping" class="sref">mapping a>, oa href="+code=index" class="sref">index a>);1/355 a> if (!oa href="+code=page" class="sref">page a>)/{1/356 a> ospa3 class="comment">/*o/spa3.1/357o/a>ospa3 class="comment"> * page didn't exist, allocate one.o/spa3.1/358o/a>ospa3 class="comment"> */o/spa3.1/359 a> oa href="+code=page" class="sref">page a> =/oa href="+code=page_cache_alloc_cold" class="sref">page_cache_alloc_cold a>(oa href="+code=mapping" class="sref">mapping a>);1/360 a> if (!oa href="+code=page" class="sref">page a>)1/361 a> break;1/362 a>1/363 a> oa href="+code=error" class="sref">error a> =/oa href="+code=add_to_page_cache_lru" class="sref">add_to_page_cache_lru a>(oa href="+code=page" class="sref">page a>, oa href="+code=mapping" class="sref">mapping a>, oa href="+code=index" class="sref">index a>,1/364 a> oa href="+code=GFP_KERNEL" class="sref">GFP_KERNEL a>);1/365 a> if (oa href="+code=unlikely" class="sref">unlikely a>(oa href="+code=error" class="sref">error a>)) {1/366 a> oa href="+code=page_cache_release" class="sref">page_cache_release a>(oa href="+code=page" class="sref">page a>);1/367 a> if (oa href="+code=error" class="sref">error a> ==/-oa href="+code=EEXIST" class="sref">EEXIST a>)1/368 a> continue;1/369 a> break;1/370 a> }1/371 a> ospa3 class="comment">/*o/spa3.1/372o/a>ospa3 class="comment"> * add_to_page_cache() locks the/page, unlock it spa3.1/373o/a>ospa3 class="comment"> * to avoid/convoluting the/logic below even more.o/spa3.1/374o/a>ospa3 class="comment"> */o/spa3.1/375 a> oa href="+code=unlock_page" class="sref">unlock_page a>(oa href="+code=page" class="sref">page a>);1/376 a> }1/377o/a>1/378 a> oa href="+code=spd" class="sref">spd a>.oa href="+code=pages" class="sref">pages a>[oa href="+code=spd" class="sref">spd a>.oa href="+code=nr_pages" class="sref">nr_pages a>++] =/oa href="+code=page" class="sref">page a>;1/379 a> oa href="+code=index" class="sref">index a>++;1/380 a> }1/381 a>1/382 a> ospa3 class="comment">/*o/spa3.1/383o/a>ospa3 class="comment"> * Now loop over the/map and see if we need to start IO on anyo/spa3.1/384o/a>ospa3 class="comment"> * pages, fill in the/partial map, etc.o/spa3.1/385o/a>ospa3 class="comment"> */o/spa3.1/386 a> oa href="+code=index" class="sref">index a> =/*oa href="+code=ppos" class="sref">ppos a> >>/oa href="+code=PAGE_CACHE_SHIFT" class="sref">PAGE_CACHE_SHIFT a>;1/387 a> oa href="+code=nr_pages" class="sref">nr_pages a> =/oa href="+code=spd" class="sref">spd a>.oa href="+code=nr_pages" class="sref">nr_pages a>;1/388 a> oa href="+code=spd" class="sref">spd a>.oa href="+code=nr_pages" class="sref">nr_pages a> =/0;1/389 a> for (oa href="+code=page_nr" class="sref">page_nr a> =/0;/oa href="+code=page_nr" class="sref">page_nr a> </oa href="+code=nr_pages" class="sref">nr_pages a>;/oa href="+code=page_nr" class="sref">page_nr a>++) {1/390 a> unsigned int/oa href="+code=this_len" class="sref">this_len a>;1/391 a>1/392 a> if (!oa href="+code=len" class="sref">len a>)1/393 a> break;1/394 a>1/395 a> ospa3 class="comment">/*o/spa3.1/396o/a>ospa3 class="comment"> * this_len is the/max we'll use from this page spa3.1/397o/a>ospa3 class="comment"> */o/spa3.1/398 a> oa href="+code=this_len" class="sref">this_len a> =/oa href="+code=min_t" class="sref">min_t a>(unsigned long,/oa href="+code=len" class="sref">len a>,/oa href="+code=PAGE_CACHE_SIZE" class="sref">PAGE_CACHE_SIZE a> - oa href="+code=loff" class="sref">loff a>);1/399 a> oa href="+code=page" class="sref">page a> =/oa href="+code=spd" class="sref">spd a>.oa href="+code=pages" class="sref">pages a>[oa href="+code=page_nr" class="sref">page_nr a>];1/400 a>1/401 a> if (oa href="+code=PageReadahead" class="sref">PageReadahead a>(oa href="+code=page" class="sref">page a>))1/402 a> oa href="+code=page_cache_async_readahead" class="sref">page_cache_async_readahead a>(oa href="+code=mapping" class="sref">mapping a>, &oa href="+code=in" class="sref">in a>->oa href="+code=f_ra" class="sref">f_ra a>, oa href="+code=in" class="sref">in a>,1/403 a> oa href="+code=page" class="sref">page a>, oa href="+code=index" class="sref">index a>, oa href="+code=req_pages" class="sref">req_pages a> -/oa href="+code=page_nr" class="sref">page_nr a>);1/404 a>1/405 a> ospa3 class="comment">/*o/spa3.1/406o/a>ospa3 class="comment"> * If the/page isn't uptodate, we may need to start io on it spa3.1/407o/a>ospa3 class="comment"> */o/spa3.1/408 a> if (!oa href="+code=PageUptodate" class="sref">PageUptodate a>(oa href="+code=page" class="sref">page a>)) {1/409 a> oa href="+code=lock_page" class="sref">lock_page a>(oa href="+code=page" class="sref">page a>);1/410 a>1/411 a> ospa3 class="comment">/*o/spa3.1/412o/a>ospa3 class="comment"> * Page was truncated, or invalidated by theo/spa3.1/413o/a>ospa3 class="comment"> * filesystem. Redo the/find/create, but this time theo/spa3.1/414o/a>ospa3 class="comment"> */page is kept locked, so there's no chance of anothero/spa3.1/415o/a>ospa3 class="comment"> */race with truncate/invalidate.o/spa3.1/416o/a>ospa3 class="comment"> */o/spa3.1/417 a> if (!oa href="+code=page" class="sref">page a>->oa href="+code=mapping" class="sref">mapping a>) {1/418 a> oa href="+code=unlock_page" class="sref">unlock_page a>(oa href="+code=page" class="sref">page a>);1/419 a> oa href="+code=page" class="sref">page a> =/oa href="+code=find_or_create_page" class="sref">find_or_create_page a>(oa href="+code=mapping" class="sref">mapping a>, oa href="+code=index" class="sref">index a>,1/420 a> oa href="+code=mapping_gfp_mask" class="sref">mapping_gfp_mask a>(oa href="+code=mapping" class="sref">mapping a>));1/421 a>1/422 a> if (!oa href="+code=page" class="sref">page a>)/{1/423 a> oa href="+code=error" class="sref">error a> =/-oa href="+code=ENOMEM" class="sref">ENOMEM a>;1/424 a> break;1/425 a> }1/426 a> oa href="+code=page_cache_release" class="sref">page_cache_release a>(oa href="+code=spd" class="sref">spd a>.oa href="+code=pages" class="sref">pages a>[oa href="+code=page_nr" class="sref">page_nr a>]);1/427 a> oa href="+code=spd" class="sref">spd a>.oa href="+code=pages" class="sref">pages a>[oa href="+code=page_nr" class="sref">page_nr a>] =/oa href="+code=page" class="sref">page a>;1/428 a> }1/429 a> ospa3 class="comment">/*o/spa3.1/430 a>ospa3 class="comment"> */page was already under io and is now done, greato/spa3.1/431o/a>ospa3 class="comment"> */o/spa3.1/432 a> if (oa href="+code=PageUptodate" class="sref">PageUptodate a>(oa href="+code=page" class="sref">page a>)) {1/433 a> oa href="+code=unlock_page" class="sref">unlock_page a>(oa href="+code=page" class="sref">page a>);1/434 a> goto/oa href="+code=fill_it" class="sref">fill_it a>;1/435 a> }1/436 a>1/437 a> ospa3 class="comment">/*o/spa3.1/438o/a>ospa3 class="comment"> * need to read in the/page spa3.1/439 a>ospa3 class="comment"> */o/spa3.1/440 a> oa href="+code=error" class="sref">error a> =/oa href="+code=mapping" class="sref">mapping a>->oa href="+code=a_ops" class="sref">a_ops a>->oa href="+code=readpage" class="sref">readpage a>(oa href="+code=in" class="sref">in a>,/oa href="+code=page" class="sref">page a>);1/441 a> if (oa href="+code=unlikely" class="sref">unlikely a>(oa href="+code=error" class="sref">error a>)) {1/442 a> ospa3 class="comment">/*o/spa3.1/443o/a>ospa3 class="comment"> * We/really should re-lookup the/page here,o/spa3.1/444o/a>ospa3 class="comment"> * but it complicates things a lot. Instead spa3.1/445o/a>ospa3 class="comment"> * lets just do what we already stored, and spa3.1/446o/a>ospa3 class="comment"> * we'll get it the/next time we are called.o/spa3.1/447o/a>ospa3 class="comment"> */o/spa3.1/448 a> if (oa href="+code=error" class="sref">error a> ==/oa href="+code=AOP_TRUNCATED_PAGE" class="sref">AOP_TRUNCATED_PAGE a>)1/449 a> oa href="+code=error" class="sref">error a> =/0;1/450 a>1/451 a> break;1/452 a> }1/453 a> }1/454 a>oa href="+code=fill_it" class="sref">fill_it a>:1/455 a> ospa3 class="comment">/*o/spa3.1/456o/a>ospa3 class="comment"> * i_size must be checked after PageUptodate.o/spa3.1/457o/a>ospa3 class="comment"> */o/spa3.1/458 a> oa href="+code=isize" class="sref">isize a> =/oa href="+code=i_size_read" class="sref">i_size_read a>(oa href="+code=mapping" class="sref">mapping a>->oa href="+code=host" class="sref">host a>);1/459 a> oa href="+code=end_index" class="sref">end_index a> =/(oa href="+code=isize" class="sref">isize a> - 1) >>/oa href="+code=PAGE_CACHE_SHIFT" class="sref">PAGE_CACHE_SHIFT a>;1/460 a> if (oa href="+code=unlikely" class="sref">unlikely a>(!oa href="+code=isize" class="sref">isize a> || oa href="+code=index" class="sref">index a> >/oa href="+code=end_index" class="sref">end_index a>))1/461 a> break;1/462 a>1/463 a> ospa3 class="comment">/*o/spa3.1/464o/a>ospa3 class="comment"> * if this is the/last/page, see if we need to shrinko/spa3.1/465o/a>ospa3 class="comment"> * the/length and stopo/spa3.1/466o/a>ospa3 class="comment"> */o/spa3.1/467 a> if (oa href="+code=end_index" class="sref">end_index a> ==/oa href="+code=index" class="sref">index a>) {1/468 a> unsigned int/oa href="+code=plen" class="sref">plen a>;1/469 a>1/470 a> ospa3 class="comment">/*o/spa3.1/471o/a>ospa3 class="comment"> */max good bytes in this page spa3.1/472o/a>ospa3 class="comment"> */o/spa3.1/473 a> oa href="+code=plen" class="sref">plen a> =/((oa href="+code=isize" class="sref">isize a> - 1) &/~oa href="+code=PAGE_CACHE_MASK" class="sref">PAGE_CACHE_MASK a>) + 1;1/474 a> if (oa href="+code=plen" class="sref">plen a> <=/oa href="+code=loff" class="sref">loff a>)1/475 a> break;1/476 a>1/477 a> ospa3 class="comment">/*o/spa3.1/478o/a>ospa3 class="comment"> * force quit after adding this page spa3.1/479 a>ospa3 class="comment"> */o/spa3.1/480 a> oa href="+code=this_len" class="sref">this_len a> =/oa href="+code=min" class="sref">min a>(oa href="+code=this_len" class="sref">this_len a>,/oa href="+code=plen" class="sref">plen a> - oa href="+code=loff" class="sref">loff a>);1/481 a> oa href="+code=len" class="sref">len a> =/oa href="+code=this_len" class="sref">this_len a>;1/482 a> }1/483o/a>1/484 a> oa href="+code=spd" class="sref">spd a>.oa href="+code=partial" class="sref">partial a>[oa href="+code=page_nr" class="sref">page_nr a>].oa href="+code=offset" class="sref">offset a> =/oa href="+code=loff" class="sref">loff a>;1/485 a> oa href="+code=spd" class="sref">spd a>.oa href="+code=partial" class="sref">partial a>[oa href="+code=page_nr" class="sref">page_nr a>].oa href="+code=len" class="sref">len a> =/oa href="+code=this_len" class="sref">this_len a>;1/486 a> oa href="+code=len" class="sref">len a> -=/oa href="+code=this_len" class="sref">this_len a>;1/487 a> oa href="+code=loff" class="sref">loff a> =/0;1/488 a> oa href="+code=spd" class="sref">spd a>.oa href="+code=nr_pages" class="sref">nr_pages a>++;1/489 a> oa href="+code=index" class="sref">index a>++;1/490 a> }1/491 a>1/492 a> ospa3 class="comment">/*o/spa3.1/493o/a>ospa3 class="comment"> * Release any pages at the/end, if we quit early. 'page_nr' is how faro/spa3.1/494o/a>ospa3 class="comment"> * we got, 'nr_pages' is how many pages are in the/map.o/spa3.1/495o/a>ospa3 class="comment"> */o/spa3.1/496 a> while (oa href="+code=page_nr" class="sref">page_nr a> </oa href="+code=nr_pages" class="sref">nr_pages a>)1/497 a> oa href="+code=page_cache_release" class="sref">page_cache_release a>(oa href="+code=spd" class="sref">spd a>.oa href="+code=pages" class="sref">pages a>[oa href="+code=page_nr" class="sref">page_nr a>++]);1/498 a> oa href="+code=in" class="sref">in a>->oa href="+code=f_ra" class="sref">f_ra a>.oa href="+code=prev_pos" class="sref">prev_pos a> =/(oa href="+code=loff_t" class="sref">loff_t a>)oa href="+code=index" class="sref">index a> <</oa href="+code=PAGE_CACHE_SHIFT" class="sref">PAGE_CACHE_SHIFT a>;1/499 a>1/500 a> if (oa href="+code=spd" class="sref">spd a>.oa href="+code=nr_pages" class="sref">nr_pages a>)1/501 a> oa href="+code=error" class="sref">error a> =/oa href="+code=splice_to_pipe" class="sref">splice_to_pipe a>(oa href="+code=pipe" class="sref">pipe a>, &oa href="+code=spd" class="sref">spd a>);1/502 a>1/503 a> oa href="+code=splice_shrink_spd" class="sref">splice_shrink_spd a>(&oa href="+code=spd" class="sref">spd a>);1/504 a> return oa href="+code=error" class="sref">error a>;1/505 a>}1/506 a>1/507o/a>ospa3 class="comment">/**o/spa3.1/508o/a>ospa3 class="comment"> * generic_file_splice_read - splice data from file to a pipe spa3.1/509 a>ospa3 class="comment"> * @in: file to splice from spa3.1/510 a>ospa3 class="comment"> * @ppos: position in @in spa3.1/511o/a>ospa3 class="comment"> * @pipe: pipe to splice to spa3.1/512o/a>ospa3 class="comment"> * @len: number of bytes to splice spa3.1/513o/a>ospa3 class="comment"> * @flags: splice modifier flags spa3.1/514o/a>ospa3 class="comment"> *o/spa3.1/515o/a>ospa3 class="comment"> * Description:o/spa3.1/516o/a>ospa3 class="comment"> * Will read pages from given file and fill them into a pipe. Ca3 be spa3.1/517o/a>ospa3 class="comment"> * used as long as the/address_space operations for the/source implements spa3.1/518o/a>ospa3 class="comment"> * a readpage() hook.o/spa3.1/519 a>ospa3 class="comment"> *o/spa3.1/520 a>ospa3 class="comment"> */o/spa3.1/521 a>oa href="+code=ssize_t" class="sref">ssize_t a> oa href="+code=generic_file_splice_read" class="sref">generic_file_splice_read a>(struct/oa href="+code=file" class="sref">file a> *oa href="+code=in" class="sref">in a>,/oa href="+code=loff_t" class="sref">loff_t a>/*oa href="+code=ppos" class="sref">ppos a>,1/522 a> struct/oa href="+code=pipe_inode_info" class="sref">pipe_inode_info a>/*oa href="+code=pipe" class="sref">pipe a>, oa href="+code=size_t" class="sref">size_t a> oa href="+code=len" class="sref">len a>,1/523 a> unsigned int/oa href="+code=flags" class="sref">flags a>)1/524 a>{1/525 a> oa href="+code=loff_t" class="sref">loff_t a>/oa href="+code=isize" class="sref">isize a>,/oa href="+code=left" class="sref">left a>;1/526 a> int/oa href="+code=ret" class="sref">ret a>;1/527o/a>1/528 a> oa href="+code=isize" class="sref">isize a> =/oa href="+code=i_size_read" class="sref">i_size_read a>(oa href="+code=in" class="sref">in a>->oa href="+code=f_mapping" class="sref">f_mapping a>->oa href="+code=host" class="sref">host a>);1/529 a> if (oa href="+code=unlikely" class="sref">unlikely a>(*oa href="+code=ppos" class="sref">ppos a> >=/oa href="+code=isize" class="sref">isize a>))1/530 a> return 0;1/531 a>1/532 a> oa href="+code=left" class="sref">left a> =/oa href="+code=isize" class="sref">isize a> - *oa href="+code=ppos" class="sref">ppos a>;1/533 a> if (oa href="+code=unlikely" class="sref">unlikely a>(oa href="+code=left" class="sref">left a> </oa href="+code=len" class="sref">len a>))1/534 a> oa href="+code=len" class="sref">len a> =/oa href="+code=left" class="sref">left a>;1/535 a>1/536 a> oa href="+code=ret" class="sref">ret a> =/oa href="+code=__generic_file_splice_read" class="sref">__generic_file_splice_read a>(oa href="+code=in" class="sref">in a>,/oa href="+code=ppos" class="sref">ppos a>,/oa href="+code=pipe" class="sref">pipe a>, oa href="+code=len" class="sref">len a>,/oa href="+code=flags" class="sref">flags a>);1/537 a> if (oa href="+code=ret" class="sref">ret a> >/0) {1/538 a> *oa href="+code=ppos" class="sref">ppos a> +=/oa href="+code=ret" class="sref">ret a>;1/539 a> oa href="+code=file_accessed" class="sref">file_accessed a>(oa href="+code=in" class="sref">in a>);1/540 a> }1/541 a>1/542 a> return oa href="+code=ret" class="sref">ret a>;1/543o/a>}1/544 a>oa href="+code=EXPORT_SYMBOL" class="sref">EXPORT_SYMBOL a>(oa href="+code=generic_file_splice_read" class="sref">generic_file_splice_read a>);1/545 a>1/546o/a>static/const struct/oa href="+code=pipe_buf_operations" class="sref">pipe_buf_operations a>/oa href="+code=default_pipe_buf_ops" class="sref">default_pipe_buf_ops a> =/{1/547 a> .oa href="+code=can_merge" class="sref">can_merge a> =/0,1/548 a> .oa href="+code=map" class="sref">map a> =/oa href="+code=generic_pipe_buf_map" class="sref">generic_pipe_buf_map a>,1/549 a> .oa href="+code=unmap" class="sref">unmap a> =/oa href="+code=generic_pipe_buf_unmap" class="sref">generic_pipe_buf_unmap a>,1/550 a> .oa href="+code=confirm" class="sref">confirm a> =/oa href="+code=generic_pipe_buf_confirm" class="sref">generic_pipe_buf_confirm a>,1/551 a> .oa href="+code=release" class="sref">release a> =/oa href="+code=generic_pipe_buf_release" class="sref">generic_pipe_buf_release a>,1/552 a> .oa href="+code=steal" class="sref">steal a> =/oa href="+code=generic_pipe_buf_steal" class="sref">generic_pipe_buf_steal a>,1/553 a> .oa href="+code=get" class="sref">get a> =/oa href="+code=generic_pipe_buf_get" class="sref">generic_pipe_buf_get a>,1/554 a>};1/555 a>1/556o/a>static/oa href="+code=ssize_t" class="sref">ssize_t a> oa href="+code=kernel_readv" class="sref">kernel_readv a>(struct/oa href="+code=file" class="sref">file a> *oa href="+code=file" class="sref">file a>,/const struct/oa href="+code=iovec" class="sref">iovec a> *oa href="+code=vec" class="sref">vec a>,1/557 a> unsigned long/oa href="+code=vlen" class="sref">vlen a>,/oa href="+code=loff_t" class="sref">loff_t a>/oa href="+code=offset" class="sref">offset a>)1/558 a>{1/559 a> oa href="+code=mm_segment_t" class="sref">mm_segment_t a>/oa href="+code=old_fs" class="sref">old_fs a>;1/560 a> oa href="+code=loff_t" class="sref">loff_t a>/oa href="+code=pos" class="sref">pos a> =/oa href="+code=offset" class="sref">offset a>;1/561 a> oa href="+code=ssize_t" class="sref">ssize_t a> oa href="+code=res" class="sref">res a>;1/562 a>1/563 a> oa href="+code=old_fs" class="sref">old_fs a> =/oa href="+code=get_fs" class="sref">get_fs a>();1/564 a> oa href="+code=set_fs" class="sref">set_fs a>(oa href="+code=get_ds" class="sref">get_ds a>());1/565 a> ospa3 class="comment">/* The cast to a user pointer is valid due to the/set_fs() */o/spa3.1/566 a> oa href="+code=res" class="sref">res a> =/oa href="+code=vfs_readv" class="sref">vfs_readv a>(oa href="+code=file" class="sref">file a>,/(const struct/oa href="+code=iovec" class="sref">iovec a> oa href="+code=__user" class="sref">__user a> *)oa href="+code=vec" class="sref">vec a>,/oa href="+code=vlen" class="sref">vlen a>,/&oa href="+code=pos" class="sref">pos a>);1/567 a> oa href="+code=set_fs" class="sref">set_fs a>(oa href="+code=old_fs" class="sref">old_fs a>);1/568 a>1/569 a> return oa href="+code=res" class="sref">res a>;1/570 a>}1/571 a>1/572o/a>static/oa href="+code=ssize_t" class="sref">ssize_t a> oa href="+code=kernel_write" class="sref">kernel_write a>(struct/oa href="+code=file" class="sref">file a> *oa href="+code=file" class="sref">file a>,/const char *oa href="+code=buf" class="sref">buf a>,/oa href="+code=size_t" class="sref">size_t a> oa href="+code=count" class="sref">count a>,1/573 a> oa href="+code=loff_t" class="sref">loff_t a>/oa href="+code=pos" class="sref">pos a>)1/574 a>{1/575 a> oa href="+code=mm_segment_t" class="sref">mm_segment_t a>/oa href="+code=old_fs" class="sref">old_fs a>;1/576 a> oa href="+code=ssize_t" class="sref">ssize_t a> oa href="+code=res" class="sref">res a>;1/577o/a>1/578 a> oa href="+code=old_fs" class="sref">old_fs a> =/oa href="+code=get_fs" class="sref">get_fs a>();1/579 a> oa href="+code=set_fs" class="sref">set_fs a>(oa href="+code=get_ds" class="sref">get_ds a>());1/580 a> ospa3 class="comment">/* The cast to a user pointer is valid due to the/set_fs() */o/spa3.1/581 a> oa href="+code=res" class="sref">res a> =/oa href="+code=vfs_write" class="sref">vfs_write a>(oa href="+code=file" class="sref">file a>,/(const char oa href="+code=__user" class="sref">__user a> *)oa href="+code=buf" class="sref">buf a>,/oa href="+code=count" class="sref">count a>,/&oa href="+code=pos" class="sref">pos a>);1/582 a> oa href="+code=set_fs" class="sref">set_fs a>(oa href="+code=old_fs" class="sref">old_fs a>);1/583o/a>1/584 a> return oa href="+code=res" class="sref">res a>;1/585 a>}1/586 a>1/587 a>oa href="+code=ssize_t" class="sref">ssize_t a> oa href="+code=default_file_splice_read" class="sref">default_file_splice_read a>(struct/oa href="+code=file" class="sref">file a> *oa href="+code=in" class="sref">in a>,/oa href="+code=loff_t" class="sref">loff_t a>/*oa href="+code=ppos" class="sref">ppos a>,1/588 a> struct/oa href="+code=pipe_inode_info" class="sref">pipe_inode_info a>/*oa href="+code=pipe" class="sref">pipe a>, oa href="+code=size_t" class="sref">size_t a> oa href="+code=len" class="sref">len a>,1/589 a> unsigned int/oa href="+code=flags" class="sref">flags a>)1/590 a>{1/591 a> unsigned int/oa href="+code=nr_pages" class="sref">nr_pages a>;1/592 a> unsigned int/oa href="+code=nr_freed" class="sref">nr_freed a>;1/593 a> oa href="+code=size_t" class="sref">size_t a> oa href="+code=offset" class="sref">offset a>;1/594 a> struct/oa href="+code=page" class="sref">page a> *oa href="+code=pages" class="sref">pages a>[oa href="+code=PIPE_DEF_BUFFERS" class="sref">PIPE_DEF_BUFFERS a>];1/595 a> struct/oa href="+code=partial_page" class="sref">partial_page a>/oa href="+code=partial" class="sref">partial a>[oa href="+code=PIPE_DEF_BUFFERS" class="sref">PIPE_DEF_BUFFERS a>];1/596 a> struct/oa href="+code=iovec" class="sref">iovec a> *oa href="+code=vec" class="sref">vec a>, oa href="+code=__vec" class="sref">__vec a>[oa href="+code=PIPE_DEF_BUFFERS" class="sref">PIPE_DEF_BUFFERS a>];1/597 a> oa href="+code=ssize_t" class="sref">ssize_t a> oa href="+code=res" class="sref">res a>;1/598 a> oa href="+code=size_t" class="sref">size_t a> oa href="+code=this_len" class="sref">this_len a>;1/599 a> int/oa href="+code=error" class="sref">error a>;1/600 a> int/oa href="+code=i" class="sref">i a>;1/601 a> struct/oa href="+code=splice_pipe_desc" class="sref">splice_pipe_desc a> oa href="+code=spd" class="sref">spd a> =/{1/602 a> .oa href="+code=pages" class="sref">pages a> =/oa href="+code=pages" class="sref">pages a>,1/603 a> .oa href="+code=partial" class="sref">partial a> =/oa href="+code=partial" class="sref">partial a>,1/604 a> .oa href="+code=nr_pages_max" class="sref">nr_pages_max a> =/oa href="+code=PIPE_DEF_BUFFERS" class="sref">PIPE_DEF_BUFFERS a>,1/605 a> .oa href="+code=flags" class="sref">flags a> =/oa href="+code=flags" class="sref">flags a>,1/606 a> .oa href="+code=ops" class="sref">ops a> =/&oa href="+code=default_pipe_buf_ops" class="sref">default_pipe_buf_ops a>,1/607 a> .oa href="+code=spd_release" class="sref">spd_release a> =/oa href="+code=spd_release_page" class="sref">spd_release_page a>,1/608 a> };1/609 a>1/610 a> if (oa href="+code=splice_grow_spd" class="sref">splice_grow_spd a>(oa href="+code=pipe" class="sref">pipe a>, &oa href="+code=spd" class="sref">spd a>))1/611 a> return -oa href="+code=ENOMEM" class="sref">ENOMEM a>;1/612 a>1/613 a> oa href="+code=res" class="sref">res a> =/-oa href="+code=ENOMEM" class="sref">ENOMEM a>;1/614 a> oa href="+code=vec" class="sref">vec a> =/oa href="+code=__vec" class="sref">__vec a>;1/615 a> if (oa href="+code=spd" class="sref">spd a>.oa href="+code=nr_pages_max" class="sref">nr_pages_max a> >/oa href="+code=PIPE_DEF_BUFFERS" class="sref">PIPE_DEF_BUFFERS a>) {1/616 a> oa href="+code=vec" class="sref">vec a> =/oa href="+code=kmalloc" class="sref">kmalloc a>(oa href="+code=spd" class="sref">spd a>.oa href="+code=nr_pages_max" class="sref">nr_pages_max a> * sizeof(struct/oa href="+code=iovec" class="sref">iovec a>), oa href="+code=GFP_KERNEL" class="sref">GFP_KERNEL a>);1/617 a> if (!oa href="+code=vec" class="sref">vec a>)1/618 a> goto/oa href="+code=shrink_ret" class="sref">shrink_ret a>;1/619 a> }1/620 a>1/621 a> oa href="+code=offset" class="sref">offset a> =/*oa href="+code=ppos" class="sref">ppos a> &/~oa href="+code=PAGE_CACHE_MASK" class="sref">PAGE_CACHE_MASK a>;1/622 a> oa href="+code=nr_pages" class="sref">nr_pages a> =/(oa href="+code=len" class="sref">len a> + oa href="+code=offset" class="sref">offset a> + oa href="+code=PAGE_CACHE_SIZE" class="sref">PAGE_CACHE_SIZE a> - 1) >>/oa href="+code=PAGE_CACHE_SHIFT" class="sref">PAGE_CACHE_SHIFT a>;1/623o/a>1/624 a> for (oa href="+code=i" class="sref">i a> =/0;/oa href="+code=i" class="sref">i a> </oa href="+code=nr_pages" class="sref">nr_pages a> &&/oa href="+code=i" class="sref">i a> </oa href="+code=spd" class="sref">spd a>.oa href="+code=nr_pages_max" class="sref">nr_pages_max a> &&/oa href="+code=len" class="sref">len a>;/oa href="+code=i" class="sref">i a>++) {1/625 a> struct/oa href="+code=page" class="sref">page a> *oa href="+code=page" class="sref">page a>;1/626 a>1/627 a> oa href="+code=page" class="sref">page a> =/oa href="+code=alloc_page" class="sref">alloc_page a>(oa href="+code=GFP_USER" class="sref">GFP_USER a>);1/628 a> oa href="+code=error" class="sref">error a> =/-oa href="+code=ENOMEM" class="sref">ENOMEM a>;1/629 a> if (!oa href="+code=page" class="sref">page a>)1/630 a> goto/oa href="+code=err" class="sref">err a>;1/631 a>1/632 a> oa href="+code=this_len" class="sref">this_len a> =/oa href="+code=min_t" class="sref">min_t a>(oa href="+code=size_t" class="sref">size_t a>, oa href="+code=len" class="sref">len a>,/oa href="+code=PAGE_CACHE_SIZE" class="sref">PAGE_CACHE_SIZE a> - oa href="+code=offset" class="sref">offset a>);1/633 a> oa href="+code=vec" class="sref">vec a>[oa href="+code=i" class="sref">i a>].oa href="+code=iov_base" class="sref">iov_base a> =/(void oa href="+code=__user" class="sref">__user a> *) oa href="+code=page_address" class="sref">page_address a>(oa href="+code=page" class="sref">page a>);1/634 a> oa href="+code=vec" class="sref">vec a>[oa href="+code=i" class="sref">i a>].oa href="+code=iov_len" class="sref">iov_len a> =/oa href="+code=this_len" class="sref">this_len a>;1/635 a> oa href="+code=spd" class="sref">spd a>.oa href="+code=pages" class="sref">pages a>[oa href="+code=i" class="sref">i a>] =/oa href="+code=page" class="sref">page a>;1/636 a> oa href="+code=spd" class="sref">spd a>.oa href="+code=nr_pages" class="sref">nr_pages a>++;1/637 a> oa href="+code=len" class="sref">len a> -=/oa href="+code=this_len" class="sref">this_len a>;1/638 a> oa href="+code=offset" class="sref">offset a> =/0;1/639 a> }1/640 a>1/641 a> oa href="+code=res" class="sref">res a> =/oa href="+code=kernel_readv" class="sref">kernel_readv a>(oa href="+code=in" class="sref">in a>,/oa href="+code=vec" class="sref">vec a>, oa href="+code=spd" class="sref">spd a>.oa href="+code=nr_pages" class="sref">nr_pages a>,/*oa href="+code=ppos" class="sref">ppos a>);1/642 a> if (oa href="+code=res" class="sref">res a> </0) {1/643 a> oa href="+code=error" class="sref">error a> =/oa href="+code=res" class="sref">res a>;1/644 a> goto/oa href="+code=err" class="sref">err a>;1/645 a> }1/646 a>1/647 a> oa href="+code=error" class="sref">error a> =/0;1/648 a> if (!oa href="+code=res" class="sref">res a>)1/649 a> goto/oa href="+code=err" class="sref">err a>;1/650 a>1/651 a> oa href="+code=nr_freed" class="sref">nr_freed a> =/0;1/652 a> for (oa href="+code=i" class="sref">i a> =/0;/oa href="+code=i" class="sref">i a> </oa href="+code=spd" class="sref">spd a>.oa href="+code=nr_pages" class="sref">nr_pages a>;/oa href="+code=i" class="sref">i a>++) {1/653 a> oa href="+code=this_len" class="sref">this_len a> =/oa href="+code=min_t" class="sref">min_t a>(oa href="+code=size_t" class="sref">size_t a>, oa href="+code=vec" class="sref">vec a>[oa href="+code=i" class="sref">i a>].oa href="+code=iov_len" class="sref">iov_len a>, oa href="+code=res" class="sref">res a>);1/654 a> oa href="+code=spd" class="sref">spd a>.oa href="+code=partial" class="sref">partial a>[oa href="+code=i" class="sref">i a>].oa href="+code=offset" class="sref">offset a> =/0;1/655 a> oa href="+code=spd" class="sref">spd a>.oa href="+code=partial" class="sref">partial a>[oa href="+code=i" class="sref">i a>].oa href="+code=len" class="sref">len a> =/oa href="+code=this_len" class="sref">this_len a>;1/656 a> if (!oa href="+code=this_len" class="sref">this_len a>) {1/657 a> oa href="+code=__free_page" class="sref">__free_page a>(oa href="+code=spd" class="sref">spd a>.oa href="+code=pages" class="sref">pages a>[oa href="+code=i" class="sref">i a>]);1/658 a> oa href="+code=spd" class="sref">spd a>.oa href="+code=pages" class="sref">pages a>[oa href="+code=i" class="sref">i a>] =/oa href="+code=NULL" class="sref">NULL a>;1/659 a> oa href="+code=nr_freed" class="sref">nr_freed a>++;1/660 a> }1/661 a> oa href="+code=res" class="sref">res a> -=/oa href="+code=this_len" class="sref">this_len a>;1/662 a> }1/663 a> oa href="+code=spd" class="sref">spd a>.oa href="+code=nr_pages" class="sref">nr_pages a> -=/oa href="+code=nr_freed" class="sref">nr_freed a>;1/664 a>1/665 a> oa href="+code=res" class="sref">res a> =/oa href="+code=splice_to_pipe" class="sref">splice_to_pipe a>(oa href="+code=pipe" class="sref">pipe a>, &oa href="+code=spd" class="sref">spd a>);1/666 a> if (oa href="+code=res" class="sref">res a> >/0)1/667 a> *oa href="+code=ppos" class="sref">ppos a> +=/oa href="+code=res" class="sref">res a>;1/668 a>1/669 a>oa href="+code=shrink_ret" class="sref">shrink_ret a>:1/670 a> if (oa href="+code=vec" class="sref">vec a> !=/oa href="+code=__vec" class="sref">__vec a>)1/671 a> oa href="+code=kfree" class="sref">kfree a>(oa href="+code=vec" class="sref">vec a>);1/672 a> oa href="+code=splice_shrink_spd" class="sref">splice_shrink_spd a>(&oa href="+code=spd" class="sref">spd a>);1/673 a> return oa href="+code=res" class="sref">res a>;1/674 a>1/675 a>oa href="+code=err" class="sref">err a>:1/676 a> for (oa href="+code=i" class="sref">i a> =/0;/oa href="+code=i" class="sref">i a> </oa href="+code=spd" class="sref">spd a>.oa href="+code=nr_pages" class="sref">nr_pages a>;/oa href="+code=i" class="sref">i a>++)1/677 a> oa href="+code=__free_page" class="sref">__free_page a>(oa href="+code=spd" class="sref">spd a>.oa href="+code=pages" class="sref">pages a>[oa href="+code=i" class="sref">i a>]);1/678 a>1/679 a> oa href="+code=res" class="sref">res a> =/oa href="+code=error" class="sref">error a>;1/680 a> goto/oa href="+code=shrink_ret" class="sref">shrink_ret a>;1/681 a>}1/682 a>oa href="+code=EXPORT_SYMBOL" class="sref">EXPORT_SYMBOL a>(oa href="+code=default_file_splice_read" class="sref">default_file_splice_read a>);1/683o/a>1/684o/a>ospa3 class="comment">/*o/spa3.1/685o/a>ospa3 class="comment"> * Send 'sd->len' bytes to socket from 'sd->file' at position 'sd->pos'o/spa3.1/686o/a>ospa3 class="comment"> * using sendpage(). Return the/number of bytes sent.o/spa3.1/687o/a>ospa3 class="comment"> */o/spa3.1/688 a>static/int/oa href="+code=pipe_to_sendpage" class="sref">pipe_to_sendpage a>(struct/oa href="+code=pipe_inode_info" class="sref">pipe_inode_info a>/*oa href="+code=pipe" class="sref">pipe a>,1/689 a> struct/oa href="+code=pipe_buffer" class="sref">pipe_buffer a>/*oa href="+code=buf" class="sref">buf a>,/struct/oa href="+code=splice_desc" class="sref">splice_desc a> *oa href="+code=sd" class="sref">sd a>)1/690 a>{1/691 a> struct/oa href="+code=file" class="sref">file a> *oa href="+code=file" class="sref">file a> =/oa href="+code=sd" class="sref">sd a>->oa href="+code=u" class="sref">u a>.oa href="+code=file" class="sref">file a>;1/692 a> oa href="+code=loff_t" class="sref">loff_t a>/oa href="+code=pos" class="sref">pos a> =/oa href="+code=sd" class="sref">sd a>->oa href="+code=pos" class="sref">pos a>;1/693 a> int/oa href="+code=more" class="sref">more a>;1/694 a>1/695 a> if (!oa href="+code=likely" class="sref">likely a>(oa href="+code=file" class="sref">file a>->oa href="+code=f_op" class="sref">f_op a> &&/oa href="+code=file" class="sref">file a>->oa href="+code=f_op" class="sref">f_op a>->oa href="+code=sendpage" class="sref">sendpage a>))1/696 a> return -oa href="+code=EINVAL" class="sref">EINVAL a>;1/697o/a>1/698 a> oa href="+code=more" class="sref">more a> =/(oa href="+code=sd" class="sref">sd a>->oa href="+code=flags" class="sref">flags a> &/oa href="+code=SPLICE_F_MORE" class="sref">SPLICE_F_MORE a>) ?/oa href="+code=MSG_MORE" class="sref">MSG_MORE a> :/0;1/699 a> if (oa href="+code=sd" class="sref">sd a>->oa href="+code=len" class="sref">len a> </oa href="+code=sd" class="sref">sd a>->oa href="+code=total_len" class="sref">total_len a>)1/700 a> oa href="+code=more" class="sref">more a> |=/oa href="+code=MSG_SENDPAGE_NOTLAST" class="sref">MSG_SENDPAGE_NOTLAST a>;1/701 a> return oa href="+code=file" class="sref">file a>->oa href="+code=f_op" class="sref">f_op a>->oa href="+code=sendpage" class="sref">sendpage a>(oa href="+code=file" class="sref">file a>,/oa href="+code=buf" class="sref">buf a>->oa href="+code=page" class="sref">page a>,/oa href="+code=buf" class="sref">buf a>->oa href="+code=offset" class="sref">offset a>,1/702 a> oa href="+code=sd" class="sref">sd a>->oa href="+code=len" class="sref">len a>,/&oa href="+code=pos" class="sref">pos a>,/oa href="+code=more" class="sref">more a>);1/703o/a>}1/704 a>1/705o/a>ospa3 class="comment">/*o/spa3.1/706o/a>ospa3 class="comment"> * This is a little more tricky than the/file -> pipe splicing. There are spa3.1/707o/a>ospa3 class="comment"> * basically three cases: spa3.1/708 a>ospa3 class="comment"> * spa3.1/709 a>ospa3 class="comment"> * - Destination page already exists in the/address space/and there spa3.1/710 a>ospa3 class="comment"> * are users of it. For that case we have no other option that spa3.1/711 a>ospa3 class="comment"> * copying the/data. Tough luck.o/spa3.1/712 a>ospa3 class="comment"> * - Destination page already exists in the/address space, but there spa3.1/713 a>ospa3 class="comment"> * are no users of it. Make sure it's uptodate, then drop it. Fall spa3.1/714o/a>ospa3 class="comment"> * through to last case.o/spa3.1/715o/a>ospa3 class="comment"> * - Destination page does not exist, we ca3 add the/pipe page too/spa3.1/716o/a>ospa3 class="comment"> * the page cache/and avoid the copy.o/spa3.1/717o/a>ospa3 class="comment"> *o/spa3.1/718 a>ospa3 class="comment"> * If asked to move pages to the/output file (SPLICE_F_MOVE is set in spa3.1/719 a>ospa3 class="comment"> * sd->flags), we attempt to migrate pages from the/pipe to the/output spa3.1/720 a>ospa3 class="comment"> * file address space/page cache. This is possible if no one else has spa3.1/721 a>ospa3 class="comment"> * the/pipe page referenced outside of the/pipe and page cache. If spa3.1/722 a>ospa3 class="comment"> * SPLICE_F_MOVE isn't set, or we ca3not move the page, we simply create spa3.1/723 a>ospa3 class="comment"> * a new page in the/output file page cache/and fill/dirty that.o/spa3.1/724o/a>ospa3 class="comment"> */o/spa3.1/725 a>int/oa href="+code=pipe_to_file" class="sref">pipe_to_file a>(struct/oa href="+code=pipe_inode_info" class="sref">pipe_inode_info a>/*oa href="+code=pipe" class="sref">pipe a>, struct/oa href="+code=pipe_buffer" class="sref">pipe_buffer a>/*oa href="+code=buf" class="sref">buf a>,1/726 a> /struct/oa href="+code=splice_desc" class="sref">splice_desc a> *oa href="+code=sd" class="sref">sd a>)1/727 a>{1/728 a> struct/oa href="+code=file" class="sref">file a> *oa href="+code=file" class="sref">file a> =/oa href="+code=sd" class="sref">sd a>->oa href="+code=u" class="sref">u a>.oa href="+code=file" class="sref">file a>;1/729 a> struct/oa href="+code=address_space" class="sref">address_space a> *oa href="+code=mapping" class="sref">mapping a> =/oa href="+code=file" class="sref">file a>->oa href="+code=f_mapping" class="sref">f_mapping a>;1/730 a> unsigned int/oa href="+code=offset" class="sref">offset a>,/oa href="+code=this_len" class="sref">this_len a>;1/731 a> struct/oa href="+code=page" class="sref">page a> *oa href="+code=page" class="sref">page a>;1/732 a> void *oa href="+code=fsdata" class="sref">fsdata a>;1/733 a> int/oa href="+code=ret" class="sref">ret a>;1/734 a>1/735 a> oa href="+code=offset" class="sref">offset a> =/oa href="+code=sd" class="sref">sd a>->oa href="+code=pos" class="sref">pos a> &/~oa href="+code=PAGE_CACHE_MASK" class="sref">PAGE_CACHE_MASK a>;1/736 a>1/737 a> oa href="+code=this_len" class="sref">this_len a> =/oa href="+code=sd" class="sref">sd a>->oa href="+code=len" class="sref">len a>;1/738 a> if (oa href="+code=this_len" class="sref">this_len a> + oa href="+code=offset" class="sref">offset a> >/oa href="+code=PAGE_CACHE_SIZE" class="sref">PAGE_CACHE_SIZE a>)1/739 a> oa href="+code=this_len" class="sref">this_len a> =/oa href="+code=PAGE_CACHE_SIZE" class="sref">PAGE_CACHE_SIZE a> - oa href="+code=offset" class="sref">offset a>;1/740 a>1/741 a> oa href="+code=ret" class="sref">ret a> =/oa href="+code=pagecache_write_begin" class="sref">pagecache_write_begin a>(oa href="+code=file" class="sref">file a>,/oa href="+code=mapping" class="sref">mapping a>, oa href="+code=sd" class="sref">sd a>->oa href="+code=pos" class="sref">pos a>,/oa href="+code=this_len" class="sref">this_len a>,1/742 a> oa href="+code=AOP_FLAG_UNINTERRUPTIBLE" class="sref">AOP_FLAG_UNINTERRUPTIBLE a>,/&oa href="+code=page" class="sref">page a>,/&oa href="+code=fsdata" class="sref">fsdata a>);1/743 a> if (oa href="+code=unlikely" class="sref">unlikely a>(oa href="+code=ret" class="sref">ret a>))1/744 a> goto/oa href="+code=out" class="sref">out a>;1/745 a>1/746 a> if (oa href="+code=buf" class="sref">buf a>->oa href="+code=page" class="sref">page a> !=/oa href="+code=page" class="sref">page a>) {1/747 a> char *oa href="+code=src" class="sref">src a> =/oa href="+code=buf" class="sref">buf a>->oa href="+code=ops" class="sref">ops a>->oa href="+code=map" class="sref">map a>(oa href="+code=pipe" class="sref">pipe a>, oa href="+code=buf" class="sref">buf a>,/1);1/748 a> char *oa href="+code=dst" class="sref">dst a> =/oa href="+code=kmap_atomic" class="sref">kmap_atomic a>(oa href="+code=page" class="sref">page a>);1/749 a>1/750 a> oa href="+code=memcpy" class="sref">memcpy a>(oa href="+code=dst" class="sref">dst a> + oa href="+code=offset" class="sref">offset a>, oa href="+code=src" class="sref">src a> + oa href="+code=buf" class="sref">buf a>->oa href="+code=offset" class="sref">offset a>,/oa href="+code=this_len" class="sref">this_len a>);1/751 a> oa href="+code=flush_dcache_page" class="sref">flush_dcache_page a>(oa href="+code=page" class="sref">page a>);1/752 a> oa href="+code=kunmap_atomic" class="sref">kunmap_atomic a>(oa href="+code=dst" class="sref">dst a>);1/753 a> oa href="+code=buf" class="sref">buf a>->oa href="+code=ops" class="sref">ops a>->oa href="+code=unmap" class="sref">unmap a>(oa href="+code=pipe" class="sref">pipe a>, oa href="+code=buf" class="sref">buf a>,/oa href="+code=src" class="sref">src a>);1/754 a> }1/755 a> oa href="+code=ret" class="sref">ret a> =/oa href="+code=pagecache_write_end" class="sref">pagecache_write_end a>(oa href="+code=file" class="sref">file a>,/oa href="+code=mapping" class="sref">mapping a>, oa href="+code=sd" class="sref">sd a>->oa href="+code=pos" class="sref">pos a>,/oa href="+code=this_len" class="sref">this_len a>,/oa href="+code=this_len" class="sref">this_len a>,1/756 a> oa href="+code=page" class="sref">page a>,/oa href="+code=fsdata" class="sref">fsdata a>);1/757 a>oa href="+code=out" class="sref">out a>:1/758 a> return oa href="+code=ret" class="sref">ret a>;1/759 a>}1/760 a>oa href="+code=EXPORT_SYMBOL" class="sref">EXPORT_SYMBOL a>(oa href="+code=pipe_to_file" class="sref">pipe_to_file a>);1/761 a>1/762 a>static/void oa href="+code=wakeup_pipe_writers" class="sref">wakeup_pipe_writers a>(struct/oa href="+code=pipe_inode_info" class="sref">pipe_inode_info a>/*oa href="+code=pipe" class="sref">pipe a>)1/763 a>{1/764 a> oa href="+code=smp_mb" class="sref">smp_mb a>();1/765 a> if (oa href="+code=waitqueue_active" class="sref">waitqueue_active a>(&oa href="+code=pipe" class="sref">pipe a>->oa href="+code=wait" class="sref">wait a>))1/766 a> oa href="+code=wake_up_interruptible" class="sref">wake_up_interruptible a>(&oa href="+code=pipe" class="sref">pipe a>->oa href="+code=wait" class="sref">wait a>);1/767 a> oa href="+code=kill_fasync" class="sref">kill_fasync a>(&oa href="+code=pipe" class="sref">pipe a>->oa href="+code=fasync_writers" class="sref">fasync_writers a>,/oa href="+code=SIGIO" class="sref">SIGIO a>,/oa href="+code=POLL_OUT" class="sref">POLL_OUT a>);1/768 a>}1/769 a>1/770 a>ospa3 class="comment">/**o/spa3.1/771 a>ospa3 class="comment"> * splice_from_pipe_feed - feed available data from a/pipe to a file spa3.1/772 a>ospa3 class="comment"> * @pipe: pipe to splice from spa3.1/773 a>ospa3 class="comment"> * @sd: information to @actor spa3.1/774o/a>ospa3 class="comment"> * @actor: handler that splices the/data spa3.1/775o/a>ospa3 class="comment"> * spa3.1/776o/a>ospa3 class="comment"> * Description: spa3.1/777o/a>ospa3 class="comment"> * This function loops over the/pipe and calls @actor to do the spa3.1/778 a>ospa3 class="comment"> * actual moving of a single struct/pipe_buffer to the/desired spa3.1/779 a>ospa3 class="comment"> * destination. It returns when there's no more buffers left in spa3.1/780 a>ospa3 class="comment"> * the/pipe or if the/requested number of bytes (@sd->total_len) spa3.1/781 a>ospa3 class="comment"> * have been copied. It returns a positive/number (one) if the spa3.1/782 a>ospa3 class="comment"> * pipe needs to be/filled with more data, zero if the/required spa3.1/783 a>ospa3 class="comment"> * number of bytes have been copied and -errno on error.o/spa3.1/784o/a>ospa3 class="comment"> * spa3.1/785o/a>ospa3 class="comment"> * This, together with splice_from_pipe_{begin,end,next}, may be spa3.1/786o/a>ospa3 class="comment"> * used to implement the/functionality of __splice_from_pipe() when spa3.1/787o/a>ospa3 class="comment"> * locking is required around copying the/pipe buffers to the spa3.1/788 a>ospa3 class="comment"> * destination. spa3.1/789 a>ospa3 class="comment"> */o/spa3.1/790 a>int/oa href="+code=splice_from_pipe_feed" class="sref">splice_from_pipe_feed a>(struct/oa href="+code=pipe_inode_info" class="sref">pipe_inode_info a>/*oa href="+code=pipe" class="sref">pipe a>,/struct/oa href="+code=splice_desc" class="sref">splice_desc a> *oa href="+code=sd" class="sref">sd a>,1/791 a> oa href="+code=splice_actor" class="sref">splice_actor a> *oa href="+code=actor" class="sref">actor a>)1/792 a>{1/793 a> int/oa href="+code=ret" class="sref">ret a>;1/794 a>1/795 a> while (oa href="+code=pipe" class="sref">pipe a>->oa href="+code=nrbufs" class="sref">nrbufs a>) {1/796 a> struct/oa href="+code=pipe_buffer" class="sref">pipe_buffer a>/*oa href="+code=buf" class="sref">buf a> =/oa href="+code=pipe" class="sref">pipe a>->oa href="+code=bufs" class="sref">bufs a> + oa href="+code=pipe" class="sref">pipe a>->oa href="+code=curbuf" class="sref">curbuf a>;1/797 a> const struct/oa href="+code=pipe_buf_operations" class="sref">pipe_buf_operations a>/*oa href="+code=ops" class="sref">ops a> =/oa href="+code=buf" class="sref">buf a>->oa href="+code=ops" class="sref">ops a>;1/798 a>1/799 a> oa href="+code=sd" class="sref">sd a>->oa href="+code=len" class="sref">len a> =/oa href="+code=buf" class="sref">buf a>->oa href="+code=len" class="sref">len a>;1/800 a> if (oa href="+code=sd" class="sref">sd a>->oa href="+code=len" class="sref">len a> >/oa href="+code=sd" class="sref">sd a>->oa href="+code=total_len" class="sref">total_len a>)1/801 a> oa href="+code=sd" class="sref">sd a>->oa href="+code=len" class="sref">len a> =/oa href="+code=sd" class="sref">sd a>->oa href="+code=total_len" class="sref">total_len a>;1/802 a>1/803 a> oa href="+code=ret" class="sref">ret a> =/oa href="+code=buf" class="sref">buf a>->oa href="+code=ops" class="sref">ops a>->oa href="+code=confirm" class="sref">confirm a>(oa href="+code=pipe" class="sref">pipe a>, oa href="+code=buf" class="sref">buf a>);1/804 a> if (oa href="+code=unlikely" class="sref">unlikely a>(oa href="+code=ret" class="sref">ret a>)) {1/805 a> if (oa href="+code=ret" class="sref">ret a> ==/-oa href="+code=ENODATA" class="sref">ENODATA a>)1/806 a> oa href="+code=ret" class="sref">ret a> =/0;1/807 a> return oa href="+code=ret" class="sref">ret a>;1/808 a> }1/809 a>1/810 a> oa href="+code=ret" class="sref">ret a> =/oa href="+code=actor" class="sref">actor a>(oa href="+code=pipe" class="sref">pipe a>, oa href="+code=buf" class="sref">buf a>,/oa href="+code=sd" class="sref">sd a>);1/811 a> if (oa href="+code=ret" class="sref">ret a> <=/0)1/812 a> return oa href="+code=ret" class="sref">ret a>;1/813o/a>1/814 a> oa href="+code=buf" class="sref">buf a>->oa href="+code=offset" class="sref">offset a> +=/oa href="+code=ret" class="sref">ret a>;1/815 a> oa href="+code=buf" class="sref">buf a>->oa href="+code=len" class="sref">len a> -=/oa href="+code=ret" class="sref">ret a>;1/816 a>1/817 a> oa href="+code=sd" class="sref">sd a>->oa href="+code=num_spliced" class="sref">num_spliced a> +=/oa href="+code=ret" class="sref">ret a>;1/818 a> oa href="+code=sd" class="sref">sd a>->oa href="+code=len" class="sref">len a> -=/oa href="+code=ret" class="sref">ret a>;1/819 a> oa href="+code=sd" class="sref">sd a>->oa href="+code=pos" class="sref">pos a> +=/oa href="+code=ret" class="sref">ret a>;1/820 a> oa href="+code=sd" class="sref">sd a>->oa href="+code=total_len" class="sref">total_len a> -=/oa href="+code=ret" class="sref">ret a>;1/821 a>1/822 a> if (!oa href="+code=buf" class="sref">buf a>->oa href="+code=len" class="sref">len a>) {1/823 a> oa href="+code=buf" class="sref">buf a>->oa href="+code=ops" class="sref">ops a> =/oa href="+code=NULL" class="sref">NULL a>;1/824 a> oa href="+code=ops" class="sref">ops a>->oa href="+code=release" class="sref">release a>(oa href="+code=pipe" class="sref">pipe a>, oa href="+code=buf" class="sref">buf a>);1/825 a> oa href="+code=pipe" class="sref">pipe a>->oa href="+code=curbuf" class="sref">curbuf a> =/(oa href="+code=pipe" class="sref">pipe a>->oa href="+code=curbuf" class="sref">curbuf a> + 1) &/(oa href="+code=pipe" class="sref">pipe a>->oa href="+code=buffers" class="sref">buffers a> -/1);1/826 a> / oa href="+code=pipe" class="sref">pipe a>->oa href="+code=nrbufs" class="sref">nrbufs a>--;1/827 a> if (oa href="+code=pipe" class="sref">pipe a>->oa href="+code=inode" class="sref">inode a>)1/828 a> / oa href="+code=sd" class="sref">sd a>->oa href="+code=need_wakeup" class="sref">need_wakeup a> =/oa href="+code=true" class="sref">true a>;1/829 a> }1/830 a>1/831 a> if (!oa href="+code=sd" class="sref">sd a>->oa href="+code=total_len" class="sref">total_len a>)1/832 a> return 0;1/833 a> }1/834 a>1/835 a> return 1;1/836 a>}1/837 a>oa href="+code=EXPORT_SYMBOL" class="sref">EXPORT_SYMBOL a>(oa href="+code=splice_from_pipe_feed" class="sref">splice_from_pipe_feed a>);1/838 a>1/839 a>ospa3 class="comment">/**o/spa3.1/840 a>ospa3 class="comment"> * splice_from_pipe_next -/wait for some data to splice from spa3.1/841 a>ospa3 class="comment"> * @pipe: pipe to splice from spa3.1/842 a>ospa3 class="comment"> * @sd: information about the splice operation spa3.1/843 a>ospa3 class="comment"> * spa3.1/844o/a>ospa3 class="comment"> * Description: spa3.1/845o/a>ospa3 class="comment"> * This function will/wait for some data and return a positive spa3.1/846o/a>ospa3 class="comment"> * value (one) if pipe buffers are available. It will/return zero spa3.1/847o/a>ospa3 class="comment"> * or -errno if no more data needs to be/spliced. spa3.1/848 a>ospa3 class="comment"> */o/spa3.1/849 a>int/oa href="+code=splice_from_pipe_next" class="sref">splice_from_pipe_next a>(struct/oa href="+code=pipe_inode_info" class="sref">pipe_inode_info a>/*oa href="+code=pipe" class="sref">pipe a>,/struct/oa href="+code=splice_desc" class="sref">splice_desc a> *oa href="+code=sd" class="sref">sd a>)1/850 a>{1/851 a> while (!oa href="+code=pipe" class="sref">pipe a>->oa href="+code=nrbufs" class="sref">nrbufs a>) {1/852 a> if (!oa href="+code=pipe" class="sref">pipe a>->oa href="+code=writers" class="sref">writers a>)1/853 a> return 0;1/854 a>1/855 a> if (!oa href="+code=pipe" class="sref">pipe a>->oa href="+code=waiting_writers" class="sref">waiting_writers a> &&/oa href="+code=sd" class="sref">sd a>->oa href="+code=num_spliced" class="sref">num_spliced a>)1/856 a> return 0;1/857o/a>1/858 a> if (oa href="+code=sd" class="sref">sd a>->oa href="+code=flags" class="sref">flags a> &/oa href="+code=SPLICE_F_NONBLOCK" class="sref">SPLICE_F_NONBLOCK a>)1/859 a> return -oa href="+code=EAGAIN" class="sref">EAGAIN a>;1/860 a>1/861 a> if (oa href="+code=signal_pending" class="sref">signal_pending a>(oa href="+code=current" class="sref">current a>))1/862 a> return -oa href="+code=ERESTARTSYS" class="sref">ERESTARTSYS a>;1/863o/a>1/864 a> if (oa href="+code=sd" class="sref">sd a>->oa href="+code=need_wakeup" class="sref">need_wakeup a>) {1/865 a> oa href="+code=wakeup_pipe_writers" class="sref">wakeup_pipe_writers a>(oa href="+code=pipe" class="sref">pipe a>);1/866 a> oa href="+code=sd" class="sref">sd a>->oa href="+code=need_wakeup" class="sref">need_wakeup a> =/oa href="+code=false" class="sref">false a>;1/867 a> }1/868 a>1/869 a> oa href="+code=pipe_wait" class="sref">pipe_wait a>(oa href="+code=pipe" class="sref">pipe a>);1/870 a> }1/871 a>1/872 a> return 1;1/873o/a>}1/874o/a>oa href="+code=EXPORT_SYMBOL" class="sref">EXPORT_SYMBOL a>(oa href="+code=splice_from_pipe_next" class="sref">splice_from_pipe_next a>);1/875 a>1/876o/a>ospa3 class="comment">/**o/spa3.1/877o/a>ospa3 class="comment"> * splice_from_pipe_begin -/start splicing from pipe spa3.1/878 a>ospa3 class="comment"> * @sd: information about the splice operation spa3.1/879 a>ospa3 class="comment"> * spa3.1/880 a>ospa3 class="comment"> * Description: spa3.1/881 a>ospa3 class="comment"> * This function should be/called before a loop containing spa3.1/882 a>ospa3 class="comment"> * splice_from_pipe_next() and splice_from_pipe_feed() too/spa3.1/883 a>ospa3 class="comment"> * initialize the necessary fields of @sd. spa3.1/884o/a>ospa3 class="comment"> */o/spa3.1/885o/a>void oa href="+code=splice_from_pipe_begin" class="sref">splice_from_pipe_begin a>(struct/oa href="+code=splice_desc" class="sref">splice_desc a> *oa href="+code=sd" class="sref">sd a>)1/886o/a>{1/887 a> oa href="+code=sd" class="sref">sd a>->oa href="+code=num_spliced" class="sref">num_spliced a> =/0;1/888 a> oa href="+code=sd" class="sref">sd a>->oa href="+code=need_wakeup" class="sref">need_wakeup a> =/oa href="+code=false" class="sref">false a>;1/889 a>}1/890 a>oa href="+code=EXPORT_SYMBOL" class="sref">EXPORT_SYMBOL a>(oa href="+code=splice_from_pipe_begin" class="sref">splice_from_pipe_begin a>);1/891 a>1/892 a>ospa3 class="comment">/**o/spa3.1/893 a>ospa3 class="comment"> * splice_from_pipe_end - finish splicing from pipe spa3.1/894o/a>ospa3 class="comment"> * @pipe: pipe to splice from spa3.1/895o/a>ospa3 class="comment"> * @sd: information about the splice operation spa3.1/896o/a>ospa3 class="comment"> * spa3.1/897o/a>ospa3 class="comment"> * Description: spa3.1/898 a>ospa3 class="comment"> * This function will/wake up pipe writers if necessary. It should spa3.1/899 a>ospa3 class="comment"> * be/called after a loop containing splice_from_pipe_next() and spa3.1/900 a>ospa3 class="comment"> * splice_from_pipe_feed(). spa3.1/901 a>ospa3 class="comment"> */o/spa3.1/902 a>void oa href="+code=splice_from_pipe_end" class="sref">splice_from_pipe_end a>(struct/oa href="+code=pipe_inode_info" class="sref">pipe_inode_info a>/*oa href="+code=pipe" class="sref">pipe a>,/struct/oa href="+code=splice_desc" class="sref">splice_desc a> *oa href="+code=sd" class="sref">sd a>)1/903 a>{1/904 a> if (oa href="+code=sd" class="sref">sd a>->oa href="+code=need_wakeup" class="sref">need_wakeup a>)1/905 a> oa href="+code=wakeup_pipe_writers" class="sref">wakeup_pipe_writers a>(oa href="+code=pipe" class="sref">pipe a>);1/906 a>}1/907 a>oa href="+code=EXPORT_SYMBOL" class="sref">EXPORT_SYMBOL a>(oa href="+code=splice_from_pipe_end" class="sref">splice_from_pipe_end a>);1/908 a>1/909 a>ospa3 class="comment">/**o/spa3.1/910 a>ospa3 class="comment"> * __splice_from_pipe -/splice data from a/pipe to given actor spa3.1/911 a>ospa3 class="comment"> * @pipe: pipe to splice from spa3.1/912 a>ospa3 class="comment"> * @sd: information to @actor spa3.1/913 a>ospa3 class="comment"> * @actor: handler that splices the/data spa3.1/914o/a>ospa3 class="comment"> * spa3.1/915o/a>ospa3 class="comment"> * Description: spa3.1/916o/a>ospa3 class="comment"> * This function does little more than loop over the/pipe and call spa3.1/917o/a>ospa3 class="comment"> * @actor to do the actual moving of a single struct/pipe_buffer to spa3.1/918 a>ospa3 class="comment"> * the/desired destination. See/pipe_to_file,/pipe_to_sendpage, or spa3.1/919 a>ospa3 class="comment"> * pipe_to_user.o/spa3.1/920 a>ospa3 class="comment"> *o/spa3.1/921 a>ospa3 class="comment"> */o/spa3.1/922 a>oa href="+code=ssize_t" class="sref">ssize_t a> oa href="+code=__splice_from_pipe" class="sref">__splice_from_pipe a>(struct/oa href="+code=pipe_inode_info" class="sref">pipe_inode_info a>/*oa href="+code=pipe" class="sref">pipe a>,/struct/oa href="+code=splice_desc" class="sref">splice_desc a> *oa href="+code=sd" class="sref">sd a>,1/923 a> oa href="+code=splice_actor" class="sref">splice_actor a> *oa href="+code=actor" class="sref">actor a>)1/924 a>{1/925 a> int/oa href="+code=ret" class="sref">ret a>;1/926 a>1/927 a> oa href="+code=splice_from_pipe_begin" class="sref">splice_from_pipe_begin a>(oa href="+code=sd" class="sref">sd a>);1/928 a> do {1/929 a> oa href="+code=ret" class="sref">ret a> =/oa href="+code=splice_from_pipe_next" class="sref">splice_from_pipe_next a>(oa href="+code=pipe" class="sref">pipe a>,/oa href="+code=sd" class="sref">sd a>);1/930 a> if (oa href="+code=ret" class="sref">ret a> >/0)1/931 a> oa href="+code=ret" class="sref">ret a> =/oa href="+code=splice_from_pipe_feed" class="sref">splice_from_pipe_feed a>(oa href="+code=pipe" class="sref">pipe a>,/oa href="+code=sd" class="sref">sd a>,/oa href="+code=actor" class="sref">actor a>);1/932 a> } while (oa href="+code=ret" class="sref">ret a> >/0);1/933 a> oa href="+code=splice_from_pipe_end" class="sref">splice_from_pipe_end a>(oa href="+code=pipe" class="sref">pipe a>,/oa href="+code=sd" class="sref">sd a>);1/934 a>1/935 a> return oa href="+code=sd" class="sref">sd a>->oa href="+code=num_spliced" class="sref">num_spliced a> ? oa href="+code=sd" class="sref">sd a>->oa href="+code=num_spliced" class="sref">num_spliced a> :/oa href="+code=ret" class="sref">ret a>;1/936 a>}1/937 a>oa href="+code=EXPORT_SYMBOL" class="sref">EXPORT_SYMBOL a>(oa href="+code=__splice_from_pipe" class="sref">__splice_from_pipe a>);1/938 a>1/939 a>ospa3 class="comment">/**o/spa3.1/940 a>ospa3 class="comment"> * splice_from_pipe -/splice data from a/pipe to a file spa3.1/941 a>ospa3 class="comment"> * @pipe: pipe to splice from spa3.1/942 a>ospa3 class="comment"> * @out: file to splice to spa3.1/943 a>ospa3 class="comment"> * @ppos: position in @out spa3.1/944o/a>ospa3 class="comment"> * @len: how many bytes to splice spa3.1/945o/a>ospa3 class="comment"> * @flags: splice modifier flags spa3.1/946o/a>ospa3 class="comment"> * @actor: handler that splices the/data spa3.1/947o/a>ospa3 class="comment"> * spa3.1/948 a>ospa3 class="comment"> * Description: spa3.1/949 a>ospa3 class="comment"> * See/__splice_from_pipe. This function locks the/pipe inode, spa3.1/950 a>ospa3 class="comment"> * otherwise it's identical to __splice_from_pipe().o/spa3.1/951 a>ospa3 class="comment"> *o/spa3.1/952 a>ospa3 class="comment"> */o/spa3.1/953 a>oa href="+code=ssize_t" class="sref">ssize_t a> oa href="+code=splice_from_pipe" class="sref">splice_from_pipe a>(struct/oa href="+code=pipe_inode_info" class="sref">pipe_inode_info a>/*oa href="+code=pipe" class="sref">pipe a>,/struct/oa href="+code=file" class="sref">file a>/*oa href="+code=out" class="sref">out a>,1/954 a> oa href="+code=loff_t" class="sref">loff_t a>/*oa href="+code=ppos" class="sref">ppos a>,/oa href="+code=size_t" class="sref">size_t a> oa href="+code=len" class="sref">len a>, unsigned int/oa href="+code=flags" class="sref">flags a>,1/955 a> oa href="+code=splice_actor" class="sref">splice_actor a> *oa href="+code=actor" class="sref">actor a>)1/956o/a>{1/957 a> oa href="+code=ssize_t" class="sref">ssize_t a> oa href="+code=ret" class="sref">ret a>;1/958 a> struct/oa href="+code=splice_desc" class="sref">splice_desc a> oa href="+code=sd" class="sref">sd a> = {1/959 a> .oa href="+code=total_len" class="sref">total_len a> =/oa href="+code=len" class="sref">len a>,1/960 a> .oa href="+code=flags" class="sref">flags a> =/oa href="+code=flags" class="sref">flags a>,1/961 a> .oa href="+code=pos" class="sref">pos a> =/*oa href="+code=ppos" class="sref">ppos a>,1/962 a> .oa href="+code=u" class="sref">u a>.oa href="+code=file" class="sref">file a>/=/oa href="+code=out" class="sref">out a>,1/963 a> };1/964 a>1/965 a> oa href="+code=pipe_lock" class="sref">pipe_lock a>(oa href="+code=pipe" class="sref">pipe a>);1/966 a> oa href="+code=ret" class="sref">ret a> =/oa href="+code=__splice_from_pipe" class="sref">__splice_from_pipe a>(oa href="+code=pipe" class="sref">pipe a>,/&oa href="+code=sd" class="sref">sd a>,/oa href="+code=actor" class="sref">actor a>);1/967 a> oa href="+code=pipe_unlock" class="sref">pipe_unlock a>(oa href="+code=pipe" class="sref">pipe a>);1/968 a>1/969 a> return oa href="+code=ret" class="sref">ret a>;1/970 a>}1/971 a>1/972 a>ospa3 class="comment">/**o/spa3.1/973 a>ospa3 class="comment"> * generic_file_splice_write -/splice data from a/pipe to a file spa3.1/974o/a>ospa3 class="comment"> * @pipe: pipe info spa3.1/975o/a>ospa3 class="comment"> * @out: file to write to spa3.1/976o/a>ospa3 class="comment"> * @ppos: position in @out spa3.1/977o/a>ospa3 class="comment"> * @len: number of bytes to splice spa3.1/978 a>ospa3 class="comment"> * @flags: splice modifier flags spa3.1/979 a>ospa3 class="comment"> * spa3.1/980 a>ospa3 class="comment"> * Description: spa3.1/981 a>ospa3 class="comment"> * Will/either move or copy pages (determined by @flags options) from spa3.1/982 a>ospa3 class="comment"> * the/given pipe inode to the/given file.o/spa3.1/983 a>ospa3 class="comment"> *o/spa3.1/984o/a>ospa3 class="comment"> */o/spa3.1/985o/a>oa href="+code=ssize_t" class="sref">ssize_t a>1/986o/a>oa href="+code=generic_file_splice_write" class="sref">generic_file_splice_write a>(struct/oa href="+code=pipe_inode_info" class="sref">pipe_inode_info a>/*oa href="+code=pipe" class="sref">pipe a>,/struct/oa href="+code=file" class="sref">file a>/*oa href="+code=out" class="sref">out a>,1/987 a> oa href="+code=loff_t" class="sref">loff_t a>/*oa href="+code=ppos" class="sref">ppos a>,/oa href="+code=size_t" class="sref">size_t a> oa href="+code=len" class="sref">len a>, unsigned int/oa href="+code=flags" class="sref">flags a>)1/ o/a>vo{1/989 a> struct/oa href="+code=address_space" class="sref">address_space a>/*oa href="+code=mapping" class="sref">mapping a>/=/oa href="+code=out" class="sref">out a>->oa href="+code=f_mapping" class="sref">f_mapping a>;1/990 a> struct/oa href="+code=inode" class="sref">inode a>/*oa href="+code=inode" class="sref">inode a>/=/oa href="+code=mapping" class="sref">mapping a>->oa href="+code=host" class="sref">host a>;1/991 a> struct/oa href="+code=splice_desc" class="sref">splice_desc a> oa href="+code=sd" class="sref">sd a> = {1/992 a> .oa href="+code=total_len" class="sref">total_len a> =/oa href="+code=len" class="sref">len a>,1/993 a> .oa href="+code=flags" class="sref">flags a> =/oa href="+code=flags" class="sref">flags a>,1/994 a> .oa href="+code=pos" class="sref">pos a> =/*oa href="+code=ppos" class="sref">ppos a>,1/995 a> .oa href="+code=u" class="sref">u a>.oa href="+code=file" class="sref">file a>/=/oa href="+code=out" class="sref">out a>,1/996 a> };1/997 a> oa href="+code=ssize_t" class="sref">ssize_t a> oa href="+code=ret" class="sref">ret a>;1/998 a>1/999 a> oa href="+code=sb_start_write" class="sref">sb_start_write a>(oa href="+code=inode" class="sref">inode a>->oa href="+code=i_sb" class="sref">i_sb a>);11000 a>1
1001  a>        oa href="+code=pipe_lock" class="sref">pipe_lock  a>(oa href="+code=pipe" class="sref">pipe  a>);11002  a>11003  a>        oa href="+code=splice_from_pipe_begin" class="sref">splice_from_pipe_begin  a>(&oa href="+code=sd" class="sref">sd  a>);11004  a>        do {11005  a>                oa href="+code=ret" class="sref">ret  a> =/oa href="+code=splice_from_pipe_next" class="sref">splice_from_pipe_next  a>(oa href="+code=pipe" class="sref">pipe  a>,/&oa href="+code=sd" class="sref">sd  a>);11006  a>                if (oa href="+code=ret" class="sref">ret  a> <=/0)11007  a>                        break;11008  a>11009  a>                oa href="+code=mutex_lock_nested" class="sref">mutex_lock_nested  a>(&oa href="+code=inode" class="sref">inode  a>->oa href="+code=i_mutex" class="sref">i_mutex  a>,/oa href="+code=I_MUTEX_CHILD" class="sref">I_MUTEX_CHILD  a>);11010  a>                oa href="+code=ret" class="sref">ret  a> =/oa href="+code=file_remove_suid" class="sref">file_remove_suid  a>(oa href="+code=out" class="sref">out  a>);11011  a>                if (!oa href="+code=ret" class="sref">ret  a>) {11012  a>                        oa href="+code=ret" class="sref">ret  a> =/oa href="+code=file_update_time" class="sref">file_update_time  a>(oa href="+code=out" class="sref">out  a>);11013  a>                        if (!oa href="+code=ret" class="sref">ret  a>)11014  a>                                oa href="+code=ret" class="sref">ret  a> =/oa href="+code=splice_from_pipe_feed" class="sref">splice_from_pipe_feed  a>(oa href="+code=pipe" class="sref">pipe  a>,/&oa href="+code=sd" class="sref">sd  a>,11015  a>                                                            oa href="+code=pipe_to_file" class="sref">pipe_to_file  a>);11016  a>                }11017  a>                oa href="+code=mutex_unlock" class="sref">mutex_unlock  a>(&oa href="+code=inode" class="sref">inode  a>->oa href="+code=i_mutex" class="sref">i_mutex  a>);11018  a>        } while (oa href="+code=ret" class="sref">ret  a> >/0);11019  a>        oa href="+code=splice_from_pipe_end" class="sref">splice_from_pipe_end  a>(oa href="+code=pipe" class="sref">pipe  a>,/&oa href="+code=sd" class="sref">sd  a>);11020  a>11021  a>        oa href="+code=pipe_unlock" class="sref">pipe_unlock  a>(oa href="+code=pipe" class="sref">pipe  a>);11022  a>11023  a>        if (oa href="+code=sd" class="sref">sd  a>.oa href="+code=num_spliced" class="sref">num_spliced  a>)11024  a>                oa href="+code=ret" class="sref">ret  a> =/oa href="+code=sd" class="sref">sd  a>.oa href="+code=num_spliced" class="sref">num_spliced  a>;11025  a>11026  a>        if (oa href="+code=ret" class="sref">ret  a> >/0) {11027  a>                unsigned long/oa href="+code=nr_pages" class="sref">nr_pages  a>;11028  a>                int/oa href="+code=err" class="sref">err  a>;11029  a>11030  a>                oa href="+code=nr_pages" class="sref">nr_pages  a> =/(oa href="+code=ret" class="sref">ret  a> + oa href="+code=PAGE_CACHE_SIZE" class="sref">PAGE_CACHE_SIZE  a> - 1) >>/oa href="+code=PAGE_CACHE_SHIFT" class="sref">PAGE_CACHE_SHIFT  a>;11031  a>11032  a>                oa href="+code=err" class="sref">err  a> =/oa href="+code=generic_write_sync" class="sref">generic_write_sync  a>(oa href="+code=out" class="sref">out  a>,/*oa href="+code=ppos" class="sref">ppos  a>,/oa href="+code=ret" class="sref">ret  a>);11033  a>                if (oa href="+code=err" class="sref">err  a>)11034  a>                        oa href="+code=ret" class="sref">ret  a> =/oa href="+code=err" class="sref">err  a>;11035  a>                else11036  a>                        *oa href="+code=ppos" class="sref">ppos  a> +=/oa href="+code=ret" class="sref">ret  a>;11037  a>                oa href="+code=balance_dirty_pages_ratelimited_nr" class="sref">balance_dirty_pages_ratelimited_nr  a>(oa href="+code=mapping" class="sref">mapping  a>,/oa href="+code=nr_pages" class="sref">nr_pages  a>);11038  a>        }11039  a>        oa href="+code=sb_end_write" class="sref">sb_end_write  a>(oa href="+code=inode" class="sref">inode  a>->oa href="+code=i_sb" class="sref">i_sb  a>);11040  a>11041  a>        return oa href="+code=ret" class="sref">ret  a>;11042  a>}11043o/a>11044o/a>oa href="+code=EXPORT_SYMBOL" class="sref">EXPORT_SYMBOL  a>(oa href="+code=generic_file_splice_write" class="sref">generic_file_splice_write  a>);11045  a>11046  a>static int/oa href="+code=write_pipe_buf" class="sref">write_pipe_buf  a>(struct/oa href="+code=pipe_inode_info" class="sref">pipe_inode_info  a>/*oa href="+code=pipe" class="sref">pipe  a>,/struct/oa href="+code=pipe_buffer" class="sref">pipe_buffer  a>/*oa href="+code=buf" class="sref">buf  a>,11047  a>                          struct/oa href="+code=splice_desc" class="sref">splice_desc  a> *oa href="+code=sd" class="sref">sd  a>)1104/a>vo{11049  a>        int/oa href="+code=ret" class="sref">ret  a>;11050  a>        void *oa href="+code=data" class="sref">data  a>;11051  a>11052  a>        oa href="+code=data" class="sref">data  a> =/oa href="+code=buf" class="sref">buf  a>->oa href="+code=ops" class="sref">ops  a>->oa href="+code=map" class="sref">map  a>(oa href="+code=pipe" class="sref">pipe  a>,/oa href="+code=buf" class="sref">buf  a>,/0);11053  a>        oa href="+code=ret" class="sref">ret  a> =/oa href="+code=kernel_write" class="sref">kernel_write  a>(oa href="+code=sd" class="sref">sd  a>->oa href="+code=u" class="sref">u  a>.oa href="+code=file" class="sref">file  a>,/oa href="+code=data" class="sref">data  a> + oa href="+code=buf" class="sref">buf  a>->oa href="+code=offset" class="sref">offset  a>,/oa href="+code=sd" class="sref">sd  a>->oa href="+code=len" class="sref">len  a>, oa href="+code=sd" class="sref">sd  a>->oa href="+code=pos" class="sref">pos  a>);11054  a>        oa href="+code=buf" class="sref">buf  a>->oa href="+code=ops" class="sref">ops  a>->oa href="+code=unmap" class="sref">unmap  a>(oa href="+code=pipe" class="sref">pipe  a>,/oa href="+code=buf" class="sref">buf  a>,/oa href="+code=data" class="sref">data  a>);11055  a>11056  a>        return oa href="+code=ret" class="sref">ret  a>;11057  a>}11058  a>11059  a>static oa href="+code=ssize_t" class="sref">ssize_t  a> oa href="+code=default_file_splice_write" class="sref">default_file_splice_write  a>(struct/oa href="+code=pipe_inode_info" class="sref">pipe_inode_info  a>/*oa href="+code=pipe" class="sref">pipe  a>,11060  a>                                         struct/oa href="+code=file" class="sref">file  a>/*oa href="+code=out" class="sref">out  a>, oa href="+code=loff_t" class="sref">loff_t  a>/*oa href="+code=ppos" class="sref">ppos  a>,11061  a>                                         oa href="+code=size_t" class="sref">size_t  a> oa href="+code=len" class="sref">len  a>, unsigned int/oa href="+code=flags" class="sref">flags  a>)11062a>vo{11063  a>        oa href="+code=ssize_t" class="sref">ssize_t  a> oa href="+code=ret" class="sref">ret  a>;11064  a>11065  a>        oa href="+code=ret" class="sref">ret  a> =/oa href="+code=splice_from_pipe" class="sref">splice_from_pipe  a>(oa href="+code=pipe" class="sref">pipe  a>,/oa href="+code=out" class="sref">out  a>, oa href="+code=ppos" class="sref">ppos  a>,/oa href="+code=len" class="sref">len  a>, oa href="+code=flags" class="sref">flags  a>,/oa href="+code=write_pipe_buf" class="sref">write_pipe_buf  a>);11066  a>        if (oa href="+code=ret" class="sref">ret  a> >/0)11067  a>                *oa href="+code=ppos" class="sref">ppos  a> +=/oa href="+code=ret" class="sref">ret  a>;11068  a>11069  a>        return oa href="+code=ret" class="sref">ret  a>;11070  a>}11071  a>11072  a>ospa3 class="comment">/**o/spa3.11073  a>ospa3 class="comment"> * generic_splice_sendpage -/splice data from a/pipe to a socket  spa3.11074o/a>ospa3 class="comment"> * @pipe:       pipe to splice from  spa3.11075o/a>ospa3 class="comment"> * @out:        socket to write to  spa3.11076o/a>ospa3 class="comment"> * @ppos:       position in @out  spa3.11077o/a>ospa3 class="comment"> * @len:        number of bytes to splice  spa3.11078  a>ospa3 class="comment"> * @flags:      splice modifier flags  spa3.11079  a>ospa3 class="comment"> *  spa3.11080  a>ospa3 class="comment"> * Description:  spa3.11081  a>ospa3 class="comment"> *    Will/send @len bytes from the/pipe to a network socket. No data copying  spa3.11082  a>ospa3 class="comment"> *    is involved.  spa3.11083  a>ospa3 class="comment"> *o/spa3.11084o/a>ospa3 class="comment"> */o/spa3.11085o/a>oa href="+code=ssize_t" class="sref">ssize_t  a>/oa href="+code=generic_splice_sendpage" class="sref">generic_splice_sendpage  a>(struct/oa href="+code=pipe_inode_info" class="sref">pipe_inode_info  a>/*oa href="+code=pipe" class="sref">pipe  a>,/struct/oa href="+code=file" class="sref">file  a>/*oa href="+code=out" class="sref">out  a>,11086  a>                                oa href="+code=loff_t" class="sref">loff_t  a>/*oa href="+code=ppos" class="sref">ppos  a>,/oa href="+code=size_t" class="sref">size_t  a> oa href="+code=len" class="sref">len  a>, unsigned int/oa href="+code=flags" class="sref">flags  a>)11087a>vo{11088  a>        return oa href="+code=splice_from_pipe" class="sref">splice_from_pipe  a>(oa href="+code=pipe" class="sref">pipe  a>,/oa href="+code=out" class="sref">out  a>, oa href="+code=ppos" class="sref">ppos  a>,/oa href="+code=len" class="sref">len  a>, oa href="+code=flags" class="sref">flags  a>,/oa href="+code=pipe_to_sendpage" class="sref">pipe_to_sendpage  a>);11089  a>}11090  a>11091o/a>oa href="+code=EXPORT_SYMBOL" class="sref">EXPORT_SYMBOL  a>(oa href="+code=generic_splice_sendpage" class="sref">generic_splice_sendpage  a>);11092  a>11093  a>ospa3 class="comment">/*o/spa3.11094o/a>ospa3 class="comment"> * Attempt to initiate a splice from/pipe to file.o/spa3.11095o/a>ospa3 class="comment"> */o/spa3.11096  a>static long/oa href="+code=do_splice_from" class="sref">do_splice_from  a>(struct/oa href="+code=pipe_inode_info" class="sref">pipe_inode_info  a>/*oa href="+code=pipe" class="sref">pipe  a>,/struct/oa href="+code=file" class="sref">file  a>/*oa href="+code=out" class="sref">out  a>,11097  a>                           oa href="+code=loff_t" class="sref">loff_t  a>/*oa href="+code=ppos" class="sref">ppos  a>,/oa href="+code=size_t" class="sref">size_t  a> oa href="+code=len" class="sref">len  a>, unsigned int/oa href="+code=flags" class="sref">flags  a>)1109/a>vo{11099  a>        oa href="+code=ssize_t" class="sref">ssize_t  a>/(*oa href="+code=splice_write" class="sref">splice_write  a>)(struct/oa href="+code=pipe_inode_info" class="sref">pipe_inode_info  a>/*,/struct/oa href="+code=file" class="sref">file  a>/*,11100  a>                                oa href="+code=loff_t" class="sref">loff_t  a>/*,/oa href="+code=size_t" class="sref">size_t  a>, unsigned int);11101  a>        int/oa href="+code=ret" class="sref">ret  a>;11102  a>11103  a>        if (oa href="+code=unlikely" class="sref">unlikely  a>(!(oa href="+code=out" class="sref">out  a>->oa href="+code=f_mode" class="sref">f_mode  a> &/oa href="+code=FMODE_WRITE" class="sref">FMODE_WRITE  a>)))11104  a>                return -oa href="+code=EBADF" class="sref">EBADF  a>;11105  a>11106  a>        if (oa href="+code=unlikely" class="sref">unlikely  a>(oa href="+code=out" class="sref">out  a>->oa href="+code=f_flags" class="sref">f_flags  a> &/oa href="+code=O_APPEND" class="sref">O_APPEND  a>))11107  a>                return -oa href="+code=EINVAL" class="sref">EINVAL  a>;11108  a>11109  a>        oa href="+code=ret" class="sref">ret  a> =/oa href="+code=rw_verify_area" class="sref">rw_verify_area  a>(oa href="+code=WRITE" class="sref">WRITE  a>,/oa href="+code=out" class="sref">out  a>, oa href="+code=ppos" class="sref">ppos  a>,/oa href="+code=len" class="sref">len  a>);11110  a>        if (oa href="+code=unlikely" class="sref">unlikely  a>(oa href="+code=ret" class="sref">ret  a> < 0))11111  a>                return oa href="+code=ret" class="sref">ret  a>;11112  a>11113  a>        if (oa href="+code=out" class="sref">out  a>->oa href="+code=f_op" class="sref">f_op  a> &&/oa href="+code=out" class="sref">out  a>->oa href="+code=f_op" class="sref">f_op  a>->oa href="+code=splice_write" class="sref">splice_write  a>)11114  a>                oa href="+code=splice_write" class="sref">splice_write  a>/=/oa href="+code=out" class="sref">out  a>->oa href="+code=f_op" class="sref">f_op  a>->oa href="+code=splice_write" class="sref">splice_write  a>;111 nam else1sd de=pipesref">2ass="lin108" id)1i11plice.c#L1087" idelse11088  a>        return oa href="+code=splice_from_pipe" class="sref">splice_from_pipe  a>(oa href="+code=pipe" class="sref">pipe  a>,/oa href="+code=out" class="sref">out  a>, a>,/oa href="+code=out" clasNVAL" clas"line" nam 1018 1a>   11="+code=pipe_to_sendpage" clas1om_pipe_en1  a>(oa href="+code=pipe"1class1"sref">pipe  a>,/&oa href=1+code=sd" 1lass="sref">sd  a>);11080  a>ospa3 clasclass="line" nam 1092  a1    oa hre1="+code=pipe_unlock" clas1="sre12tes from the/pipe to a networkospa3 class="comment">/*o/spa3.1pipe  a>);11082  a>ospa3 class="cosplice from/pipe to file.o/spa3.1     if (o1 href="+code=sd" class="s1ef">s1  a>.oe" nam 1095o/a>ospa3 class="tize_t" class="sra3 class="tiplice.c#L1096" idp002">1002  a>1,/oa href="+cod                      struct/oa href="+code=file" class="sref">file  a>/*oa href="+code=out" class="1et  a> =/o1 href="+code=sd" class="s1ef">s12"sref">pipe  a>,/&oa href=.c#L1096" id1096  a>static long/oa href="+code=do_splice_from" class="sref">do_spl7">1097  a>                           oa href="+code=loff_t" class="sref">loff_t  a>/*oahref="+code=out" class="1e>splice_wref">num_spliced  a>;1file  a>/*oa href="+href="+code=ppos" class="sref">ppos  a>,/oa href="+code=size_t" class="sref">size_11126  a12>, unsigned int/oa href="+code1e" nam 1027  a>            1   un1igned long/oa " id109/a>vo{1 >/0);11099  a>        oa " class="sref">splice_write  a class="sref">file  a>/*,11028  12splice.c#L1008" id1096  a>static long/oa hre100" id1100  a>                                oa hrefcode=err" 1lass="sref">err  a>;1size_t  a>, unsigned int);1PAGE_C1CHE_SIZE  a> - 1) >>1/oa h1ef="+code=PAGE_CACHE_SHIFT" cl1ss="sref">1AGE_CACHE_SHIFT  a>;11102  a>11002  a>11103  a>        if (oa href="+code=unlikely" class="sref">unliREAely  a>(oa href=">unliREAeclass="sref">out  a>->oa hrefs="sref">o1t  a>,/*oa href="+code=pp1s" cl1ss="sref">ppos  a>,/oaE_WRITE" class="sref">FMODE_WRITE  a>)))11033  13="sref">ssize_t  a> oa href="1          1          oa href="+code=1et" c1ass="sref">ret8" id1108  a>11109  aREAely  a>(oa href=REAeclas100" id1002  a>1,/oa href="+cod="sref">rw_verify_area  a>(oa href="+code=WRITE" class="sref">WRITE  a>,/oa href="+code=out" claf">err  a>111105  a>11110  a>                 1      *oa href="+code=ppo1" cla1s="sref">ppos  a> +=/o+code=ret" class="sref">ret  a> < 0))1(oa href1"+code=mapping" class="sr1f">ma13      return -oa href="+code=E="sref">nr1pages  a>);11002  a>11103 e.c#L1113" id1113002">1002  a>11103 e.c#L1113" idsple" t  a> >/0);1sple" t  a> >/0);111002  a>11103 e.c#L1113" idsple" t  a> >/0);1i_sb  a>);1114splice.c#L1031" idsple" t  a> >/0);11sd de=pipee" t  a> >/0);1<.c#"sref">sd de=pipee" to1ass="sref">ret  a>;11042  a>}1 >/0);11002  a>1,/oa href="+cod="sref">rw_verify_area  a>(oa href="+code=WRice_from" class="sref">do_spl7">1097  a>    pipe" class="sref">pipe  a>,/oa href="+code=out" class="sref">out  a>, a>,/oa href="+code=out" cla>EXPORT_SY1BOL  a>(oa href="+code=ge1eric_1ile_spde=pipe_to_sendpage" clas1generic_fi1e_splice_write  a>);1 * @pclass="line" nam 1071  a>1 struct/oa1href="+code=splice_desc" 1lass=14ss="comment"> * @len:        na href=direct"+coe  a>*o/spa3.1sda href="fs/splice.c#L1078" idsd  a>)1 * @flags:   @i     posit      pipket  spa3.11079  a>@sd    posit e  a>*ong/rmarite te wher  pipket  sp3.110151080  a>ospa3 class="@e  a>    poshandlspa3h11081  a>1de=data" c1ass="sref">data  a>;11081  a>1d="sref">o1  a>(oa href="+code=pipe"1class15="line" nam 1072  a>oospa3 class="comment"> *  spa3.1, oa href="+code=s1" cla15s="line" nam 1093  a>>>>Thcketst">/*ecial case helper pipket  spdirectly between two"comment"> *  spa3.1 * @pipe:   t toints, withoutc" quircla ="cex#L10ctsplicl Internally ="calloca#L100omment"> *  spa3.1data  a>);1 * @out:   a/pipe ts cach     a3.1 *  spa3.1115ospa3 class="comment"> * @ppos ed batret  a>;1 * @len:        ice.c#L1094" id1057  a>}1 * @flags:  splice from/pipe to file.o/spa3.1ref="+code1pipe_inode_info" class="s1ef">p1pe_ino" id109/a>vo{11087" class="line" namdirect"+coe  a>  a> >/0);1plice.c#L1096" idp002">1002  a>1ode=buf" class="sref">buf  a>,11047  a1igned int/oa href="+code1ref">out  1>, oa href="+code=loff_t"1class1"sref">loff_t  a>/*oa href="+code=ppo1087" class="line" namdirect"e  a>  a> >/0);1plicL1047" class="line  a>  a> >/0);1plic0 return -oa href="+code=E  a> oa hr1f="+code=len" class="sref1>len 1a>, unsigned int/oa href="+code1flags" cla1s="sref">flags  a>)11096  a>static long/oa href="+code=do_splice_from" class="sref">do_s>,/oa href="+code=out" cla063  a>   1    oa href="+code=ssize_1" cla16t;oa href="+c1095o/a>osp">ret  a> < 0))1 < 0)) tiondo_s>,/oa href="+code=out" cla0EXPORT_SY1lass="sref">ret  a>;1,/oa href="+code=out" cla0eneric_fi1lags" class="sref">flags 1a>,/o1 href="+code=w7">1097  a>                           oa href="+code=loff_t" class="sref">loff_t  a>/*o>,/oa href="+code=out" cla0         1class="line" nam         if (=size_t" class="srei       if (oa hipe  a>,/oa href="+code=out" class="sref">out  a>, >,/oa href="+code=out" cla0de=ret" c1      *oa href="+code=ppo1" cla1s="sref">ppos  a> +=/oa href="1code=ret" 1lass="sref">ret  a>;11080  a>ospa3 clasclass="line" nam 1092  a169" id117s="line" nam 1079          * Wec" quire 3.1ret  a>;11080  a>ospa3 class        * randomly drop*eg splice ice_w splice c#L10cla. Use 3.11 oa hr1m 1070  a>}1d c#L10claefa>* bat!11072  a        *splice from/pipe to file.o/spa3.173">1073  1>ospa3 class="comment"> *1gener17="sref">sd  a>->oa href="i  a>        if (oa hief="+code1108  a>11002  a>11103 pathc#L1113" id11d072r pe  ne" nam 110d_9" id110i  a>        if (oa hief="+code>,/oa href="+code=out" claL1074" cla1s="line" nam 1071o/a>o17splice.c#L1062" id1102  a>111S_ISREG        if (oa hief="+code)ss="line" nafd11S_ISBLK        if (oa hief="+code)am 1110  a>       oL1075" cl1ss="line" nam 1015o/a>17ss="sref">file  a>/*ode=O_APPEND" class="sref">O_APPEND  a>))11076o/1781077o/a>o1pa3 c178plice.c#L10680">1080  a>ospa3 clasclass="line" nam 1092  a16ode=ret" 1"line" nam 1078 1a>osp13 class="comment"> * @flags:         * nei3.1>*on na>*outctst">ef">a>oe=Op ="cinternal/pipe attach   3.11079          * 'out' andctransfer p.11080  a>ospa3 class        *splice from/pipe to file.o/spa3.1spa3 class1"comment"> *    Will/send1@len 18splice.c#L1051" iddo_s1108  a>1spl087">1087a>vo{1do_s>,/oa href="+code=out" claice.c#L1081" id1102  a>1do_s) href="fs/splice.c#L1026" i11do_s1108  a>11096 alloc_ a>statam))1, a>,/oa href="+code=out" clapipe  a>,/&code=out" class="sreice_from" class="sref">do_s),/oa href="+code=out" clafile  a>/*oa href="de=O_APPEND" class="srefNOMEMPPEND  a>))1,/oa href="+code=out" claiflags  a>)11080  a>ospa3 clasclass="line" nam 1092  a1+code=flag1" class="sref">flags  a>,1oa hr18 class="comment"> * @flags:                 * Wspdon't have ="ci@fldmmente" ter, butcwe'llte" t p.1 *  spa3.1pi1e_to_sendpage  a>);11079                  * outcofa3.11089  a>}11080  a>ospa3 class                * PIPliREAeERS approprmmenlylice.c#L1094" idEXPOR1_SYMBOL  a>(oa href="+cod1=gene19splice.c#L1071" idgeneric_1plice_sendpage  a>);1ppos  a>,/oaout" class="sreice_from" class="sref">do_sice_write" class="sre" tert" class="sref">e" tertdo_s1101>,/oa href="+code=out" cla1ssize_t  a> oa href="1ine" nam <1L1094">1094o/a>ospa3 clas1="com19"sref">pipe  a>,/&8  a>1spl087">1087a>vo{1do_s1108  a>1do_s>,/oa href="+code=out" clafilde=pipe_to_sendpage" clas1f">pipe  a1,/struct/oa href="+code=f1le" c198 oa hr1f="+code=len" class="sref1>len 198plice.c#L10680">1080  a>ospa3 clasclass="line" nam 1092  a1flags" cla1s="sref">flags  a>)1 * @flags:         * Do p.1pipe_i2ode_i20s="line" nam 1079          *splice from/pipe to file.o/spa3.2="+code=lo2f_t" class="sref">loff_t 2a>/*,20splice.c#L1020" id1100>,/oa href="+code=out" cl2L1101" id<2L1101" class="line" nam <2L110120splice.c#L1051" id < 0)) tiondo_s1100>,/oa href="+code=out" cl2L3101" id<2Llice_sendpage  a>);1loff_t  a>/*o1loff_ttotal_lasdo_s>,/oa href="+code=out" cl2="+code=f_2ode" class="sref">f_mode 2a> &a20="sref">sd  a>->oa href="e=out" class="sref">out  a>, 1out  a>, >,/oa href="+code=out" cl2" class="l2ne" nam 1104  a>2     2         return -oa href="+cod2=EBADF" cl2ss="sref">EBADF  a>;11080  a>ospa3 clasclass="line" nam 1092  a2 href="+co2e=f_flags" class="sref">f2flags20ospa3 class="comment"> * @pp        * Don't b11107  a>  2     20ss="comment"> * @len:               *splice from/pipe to file.o/spa3.2=9ass="lin2"="sref">flags  a>)1out  a>, ss="li= ~d11SPLICE_F_NONBLOCKa>, >,/oa href="+code=out" cl2ss="sref">2ut  a>, oa href="+code=pp2s" cl21sref">pipe  a>,/&oa href=2 if (oa hr2f="+code=unlikely" class=2sref"2unlikely  a>(owh    idWRITE  ahref="fs/splice.c#L1026" i2L1111" cla2s="line" nam 1112  a> 21splice.c#L1031" idloff_te" t_lasa>, >,/oa href="+code=out" cl2s3101" id<2lass="sref">ret  a>;1ppos  a>,/oaout" class="srele  a>/*,1sd  a>1sd  a>oa href="+code=WRirev_i=sd" class="sref">rev_i=sdo_s1108  a>1sd  a>>,/oa href="+code=out" cl2s"+code=f_2de=f_op" class="sref">f_o2  a>-21="sref">ssize_t  a> oa href="2a href="+c2de=f_op" class="sref">f_o2  a>-21"sref">pipe  a>,/&8  a>11108  a>1p002">1002  a>1s="lirite" class="sri=sd" class="sref">sd  a>oa href="+code=WRice_from" class="sref">do_spl7">1097  a>    pipe" class="sref">pipe  a>,/oa href="+code=out" class="sref">out  a>, a>,/oa href="+code=out" cl2">splice_w2ite  a>;11105  a>11110  a>      27e  write 2a>)1file  a>/*oa href="gopipf="fs/splice.c#out_releas_from" class="srout_releas_  a>>,/oa href="+code=out" cl2slass="lin2ef="+code=inode" class="s2ef">i21="sref">ppos  a> +=/oa href="2sNVAL" cla2"line" nam 1018 2a>   21splice.c#L1008" idloff_te" t_lasa>, 1108  a>1(oa href="+code=pipe"2class22splice.c#L1029" idloff_ttotal_lasdo_s1108  a>1loff_te" t_lasa>, >,/oa href="+code=out" cl2+code=sd" 2lass="sref">sd  a>);11080  a>ospa3 clasclass="line" nam 1092  a2e=pipe" cl2ss="sref">pipe  a>);11082  a>ospa3 class="ccccccccccccccccc* NOTE: nonb1spa3.13.1s22s="line" nam 1093  cccccccccccccccc* must not d.13.1s22a3 class="comment"> * @pipe:cccccccccccccccc* could gce ctua  d hre  a3.1 *  spa3.1num_spliced  a>;1 * @out:cccccccccccccccc*splice from/pipe to file.o/spa3.21226  a22ss="sref">file  a>/*o8  a>11108  a>11088  a>        rete" nam 1047  a>>,/oa href="+code=out" cl2+lass="lin2027">1027  a>            2   un22gned long/oa href="+c5" id1105  a>12028  22splice.c#L1008" idsd  a>1108  a>1rev_i=sdo_s>,/oa href="+code=out" cl2code=err" 2lass="sref">err  a>;1PAGE_C2CHE_SIZE  a> - 1) >>2/oa h23sref">loff_t  a>/*oa de=pipe_to_sendpage" clas2ss="sref">2AGE_CACHE_SHIFT  a>;1o2t  a>,/*oa href="+code=pp2s" cl2ss="sref">ppos  a>,/oa1" id < 0)) tiondo_s1href="fs/splice.c#L1067" id1067  2d2033  23t;oa href="+code=splice_write" classlass="sref">loff_t  a>/*o1-ref="fs/splice.c#L1067" id1067  2d href="+c2          oa href="+code=2et" c23"sref">pipe  a>,/&8  a>1sd  a>1108  a>1sd  a>>,/oa href="+code=out" cl2f">err  a>21ppos  a> +=/orite_pipe_buf" class="sref">write_pipe_buf  a>ne" 8  a>1loff_te" t_lasa>, mhref="fs/splice.c#L1026" i2a>(oa href2"+code=mapping" class="sr2f">ma23gned long/oa href="+c,/&o href="fs/splice.c#L1024" idsd  a>1108  a>1rev_i=sdo_sa>->oa href="+cL1067" id1067  2dNVAL" cla2pages  a>);1i_sb  a>);1241" class="line" nam 124             return oa href="2e="sref">o2ass="sref">ret  a>;11042  a>}1sd  a>->oa href="ice_from" class="sref">do_sice_write" class="srnrbufsd" class="sref"nrbufsdo_s1108  a>1do_sice_write" class="srcursref">ppos  a>,/oacursredo_s1100>,/oa href="+code=out" cl2>EXPORT_SY2BOL  a>(oa href="+code=ge2eric_24splice.c#L1064" idsd ac.1sse.c#L1024" idsd ac.1sse.plice class="sref">p002">1002  a>1>,/oa href="+code=out" cl2generic_fi2e_splice_write  a>);1sd  a>)11080  a>ospa3 clasclass="line" nam 1092  a2L1049" id<2L1049" class="line" nam <2L104925s="line" nam 1079          * If wspdid ="cin79"plespa3ransfer wspmust releas_  s="line" nam 1092  a2L=i_sb" cl20" class="line" nam 10251080  a>ospa3 class        * 3.1 *  spa3.1data  a>;1o2  a>(oa href="+code=pipe"2class25s="sref">pposfa>*e class="sref">p02">1002  a>1ze_t" class="srei       if (oa hipe  a>ne" 8  a>1do_sice_write" class="srsreferket  a> < 0)) referkdo_s>ze_t" class="srei       if (oa hipe  ++mhref="fs/splice.c#L1026" i2ass="sref"2len  a>, oa href="+code=s2" cla25t;oa href="+code=spli.c#L1096" id= refer;oa hef="+code=do_splsref">ppos  a>,/oasredo_s1108  a>1do_sice_write" class="srsreket  a> < 0)) resdo_sa>->oa href="+ci       if (oa hipe  >,/oa href="+code=out" cl2aEXPORT_SY2pe  a>,/oa href="+code=bu2" cla25        return -oa href="+cod2aeneric_fi2ss="sref">data  a>);1ppos  a>,/oasredo_sice_write" class="sropket  a> < 0))opka>, mhref="fs/splice.c#L1026" i2a         256" class="line" nam 125ss="sref">file  a>/*oa href="dppos  a>,/oasredo_sice_write" class="sropket  a> < 0))opka>, ice_write" class="sre"leas_from" class="srreleas_  a>88" id1088  a>        retsref">ppos  a>,/oasredo_s>>,/oa href="+code=out" cl2ode=ret" c2ass="sref">ret  a>;1ppos  a>,/oasredo_sice_write" class="sropket  a> < 0))opka>, 1108  a>11057  a>}1p26splice.c#L102de=pipe_to_sendpage" clas2r=i_sb" cl2>, oa href="+code=loff_t"2class26f="+code=PAGE_CACHE_SHIFT" cl2  a> oa hr2f="+code=len" class="sref2>len 26splice.c#L1032" i=out" class="sre tionet  a> < 0)) tiondo_sm 1110  a>      2flags" cla2s="sref">flags  a>)1ppos  a>,/oa1" id < 0)) tiondo_s1ref="fs/splice.c#L1067" id1067  2063  a>   2    oa href="+code=ssize_2" cla26="sref">ssize_t  a> oa href="20EXPORT_SY2lass="sref">ret  a>;11067  20eneric_fi2lags" class="sref">flags 2a>,/o2 href=de=pipe_to_sendpage" clas2r         2class="line" nam     f="fs/splice.c#L1090" class="line" nam 1090  a>1  a> >/0);1plic>>,/oa href="+code=out" cl20de=ret" c2      *oa href="+code=ppo2" cla2s="sref">ppos  a> +=/oa href="2code=ret" 2lass="sref">ret  a>;1  a> >/0);111096  a>static long/oa href="+code=do_splice_from" class="sref">do_spf">ppos  a> +=/oa href="269" id127o  a>/*,/struct/oa href="+code=file"ode=buf" class="sref">buf  a>,11047  am 1110  a>      2ode=ret" c2ass="sref">ret  a>;1 oa hr2m 1070  a>}1p href="+code=pipe_inode_info1104" c"+code=kernel_wr href="+code=pipe_inode_inf>,/oa href="+code=out" cl2olags" cla2/splice.c#L1072" id1073  2>ospa3 class="comment"> *2gener27="sref">sd  a5" id */o/spa3.11088  a>        ret href="+code=pipe_inode_infa>s="lirite" class="sr href="+code=pipe_inode_infne" nam 1103 p=sd" class="sref"f_>sd  a>oa href="+code=WRe.c#L1024" idloff_ttotal_lasdo_spf">ppos  a> +=/oa href="26EXPORT_SY2s="line" nam 1072o/a>o27"sref">pipe  a>,/&">ppos  a>,/oa1" idout  a>, >>,/oa href="+code=out" cl2oL1075" cl2ss="line" nam 1025o/a>27href=de=pipe_to_sendpage" clas2d2076o/2781077o/a>o2pa3 c27ss="comment"> * @len:      class="line" nam 1071  a>26ode=ret" 2"line" nam 1078 2a>osp23 class="comment"> * @flags: * 11079    @i     posit      pipket  spa3.11080  a>ospa3 class  @rea     posiinputc     offs id *    Will/send2@len 28tes from the/pipe to a network@out:  posit      pipket  sp3.11072  a>o@las:  posit numbercofa tion pipket  s11073  2s/splice.c#L1083" id1093  a>@out  :  posiket  spmodifiercout  a>a href="fs/splice.c#L1075" id2iEXPORT_SY2/splice.c#L1084" id * @pipe: a>a href="fs/splice.c#L1075" id2iL1075" cl2,/struct/oa href="+code=f2le" c28pa3 class="comment"> * @out:  ospa3 class="comment"> *  spa3.1 * @ppos edFor usea t 1 *  spa3.1flags  a>)1 * @len:        nnnndoclaeite  a3.1<=p2">carite would incur ="cextra systempc=ll"comment"> *  spa3.1flags  a>,2oa hr28 class="comment"> * @flags:  nnnn(ket  sp  a+ ket  spout, as 79"par   3. just  end    ()). So thckehelper"comment"> *  spa3.1pi2e_to_sendpage  a>);11079   nnnnc="cket  spdirectly through*a1089  a>}11080  a>ospa3 class a>a href="fs/splice.c#L1075" id2ref">EXPOR2_SYMBOL  a>(oa href="+cod2=gene29splice.c#L1071" idgeneric_2plice_sendpage  a>);11095o/a>ospa3 class="directent"> */o/spa3.1p002">1002  a>1,/oa href="+cod                      struct/oa href="+code=file" class="sref">file  a>/*oa 3.c#L1096" idpurn oa href="+code=splice_rom/pipe to file.o/spa3.2"3">1073  2s/splice.c#L1093" idloff_t  a>/*oa+href="+code=ppos" class="sref">ppos  a>,/oa href="+code=size_t" class="sref">size_2ine" nam <2L1094">1094o/a>ospa3 clas2="com29"srefref="fs/splice.c#L1026" i2filode=buf" class="sref">buf  a>,1file  a>/*o"+code=kernel_wrlass="sref">loff_t  a>/*o111111111111loff_t  a>/*oahref="+code=out" class="2  a> oa hr2f="+code=len" class="sref2>len 29gned long/oa href="+c"+code=kernel_wrtotal_lass="sref">loff_ttotal_lasdo_s111111loff_t  a>/*oahref="+code=out" class="2 ode=ret" 2s="sref">flags  a>)1out  a>, s111111111out  a>, ahref="+code=out" class="3pipe_inode3info" class="sref">pipe_i3ode_i30o  a>/*,/struct/oa hr"+code=kernel_wri=sd" class="sref">sd  a>111111111111file  a>/*oa href="+code=out" class="3p1pe_inode3i 1089  a>}1/*,30sref">loff_t  a>/*oa "+code=kernel_wrunam 1104" c"+code=kernel_wr href="+code=pipe_inode_inf111111111,/oa href="+code=out" cl3L3101" id<3Llice_sendpage  a>);11095o/a>osp">ret  a> < 0))1,/oa href="+code=out" cl3L4101" id<3L/splice.c#L1093" id &a30="sref">ssize_t  a> oa href="3" class="l3ne" nam 1104  a>3     30ss="sref">ret8" id1108  a>1  a> >/0);1plice class="sref">p002">1002  a>1s="lirite" class="sre" nam 1047  a1ze_t" class="sredirect"a href=e  a>  a> >/0);11>,/oa href="+code=out" cl3=EBADF" cl3ss="sref">EBADF  a>;1write_pipe_buf  a>ge" na,/oa href="+code=out" cl3=7BADF" cl3s/struct/oa href="+code=f3flags30ss="sref">file  a>/*ohref="+code=file" class="sref">file  a>/*oaosd  a>>,/oa href="+code=out" cl3=8BADF" cl3s="+code=len" class="sref3     30="sref">ppos  a> +=/oa href="3=9ass="lin3"="sref">flags  a>)1ret  a> < 0))13ut  a>, oa href="+code=pp3s" cl31sref"de=pipe_to_sendpage" clas3 if (oa hr3f="+code=unlikely" class=3sref"31f="+code=PAGE_CACHE_SHIFT" cl3L1111" cla3s="line" nam 1113  a> 31splice" nam =size_t" class="srea href= a>stti_ a>s  a> >/0);1stti_ a>s11096  a>static long/oa href="+code=do_spli a>s  a> >/0);1do_spf">ppos  a> +=/oa href="3s3101" id<3lass="sref">ret  a>;1ppos  a>,/oaaaaaaaaaaaaaaaa.c#L1096" id1096  a>static long/oa href="+code=do_splo a>s  a> >/0);1do_spf">ppos  a> +=/oa href="3s4101" id<3de=f_op" class="sref">f_o3  a>-31t;oa href="+code=splia>,/oaaaaaaaaaa1" idloff_t  a>/*oa+href="+code=ppos" class="sref">ppos  a>,/oa href="+code=sif="fs/splice.c#L1111" id<3s class="l3de=f_op" class="sref">f_o3  a>-31        return -oa href="+cod3">splice_w3ite  a>;1 * @outclass="line" nam 1092  a37e  write 3a>)1 * @pposDeterm"fs wher  pipket  sp3./a3.1lice.c#L1094" idi31ss="comment"> * @len:        splice from/pipe to file.o/spa3.3sNVAL" cla3"line" nam 1018 3a>   31splice" nam 1095o/a>ospa3 class=ent"> */o/spa3.1p002">1002  a>1,/oa href="+cod                      struct/oa ,/oa href="+cod__userfrom" class="sr__useroa href="+code=do_splotru002">1002  a>1ppos  a> +=/oa href="3om_pipe_en3  a>(oa href="+code=pipe"3class32splice.c#L1029" idpurn oa href="+code=splice_>,/oa href="+cod                      struct/oa ,/oa href="+cod__userfrom" class="sr__useroa href="+code=do_splotruurn oa href="+code=truurndo_spf">ppos  a> +=/oa href="3oif (oa hr3lass="sref">sd  a>);1loff_t  a>/*oa href="1" idloff_t  a>/*oa+href="+code=ppos" class="sref">ppos  a>,/oa href="+code=sif">ppos  a> +=/oa href="3o1111" cla3="+code=pipe_unlock" clas3="sre32>, unsigned int/oa href="+code3e=pipe" cl3ss="sref">pipe  a>);11096  a>static long/oa href="+code=do_spli a>s  a> >/0);1do_sf="fs/splice.c#L1111" id<3     if (o3 href="+code=sd" class="s3ef">s324lice.c#L1062.c#L1096" id1096  a>static long/oa href="+code=do_splo a>s  a> >/0);1do_sf="fs/splice.c#L1111" id<3  class="l3 href="+code=sd" class="s3ef">s32ss="sref">ret8" idsplice_w3ef">num_spliced  a>;11095o/a>osp">ret  a> < 0))1,/oa href="+code=out" cl31326  a3281027  a>            3   un32gned long/oa f="+code=do_spli a>s  a> >/0);1do_so1096 get_ a>statamplice class="sref">p002">1002  a>13028  32splice.c#L1108" ids  a> >/0);1do_so1096 get_ a>statamplice class="sref">purn oa href="+code=spliceif="fs/splice.c#L1111" id<3code=err" 3lass="sref">err  a>;1pipe  a>,/&oa href=3ef">PAGE_C3CHE_SIZE  a> - 1) >>3/oa h33sref">loff_t 5" ids  a> >/0);1do_sos="line" nam 1113o a>s  a> >/0);1do_smhref="fs/splice.c#L1026" i3ss="sref">3AGE_CACHE_SHIFT  a>;11002  a>1ppos  a> +=/oa href="3s="sref">o3t  a>,/*oa href="+code=pp3s" cl3ss="sref">ppos  a>,/oaaaaaaaaade=O_APPEND" class="srefSPIPl oa href="+codefSPIPl hre>,/oa href="+code=out" cl3d3033  33="sref">ssize_t  a> oa href="3d href="+c3          oa href="+code=3et" c33"sref">pipe  a>,/&2" i=id1002  a>11103  a>        if (oa hfef="+code1ne" nam 1113FMODliREAe       if (oa hFMODliREAedo_siif">ppos  a> +=/oa href="3s>splice_w31file  a>/*oa href="de=O_APPEND" class="srefBADF oa href="+codefBADF hre>,/oa href="+code=out" cl3doL1026" c3      *oa href="+code=ppo3" cla338(oa href3"+code=mapping" class="sr3f">ma33gned long/oa href="+c2" i=id1103  a>        if (oa hfef="+code1ne" nam 1113FMODliWRITl oa href="+codeFMODliWRITldo_siif">ppos  a> +=/oa href="3sNVAL" cla3pages  a>);1,/oa href="+code=out" cl3d_write  a3(oa href="+code=inode" cl3ss="s34sref">pipe  a>,/&oa href=3e=i_sb" cl3ss="sref">i_sb  a>);1loff_t  a>/*oa lass="comment"> * @outcl Sp;oacla 3o s lf would be fun, but...  splice from/pipe to file.o/spa3.3es="sref">341" class="line" nam 134splice.c#L1031" ids  a> >/0);1do_so<do_smrom/pipe to file.o/spa3.3e="sref">o3ass="sref">ret  a>;1ppos  a>,/oaaaaaaaaade=O_APPEND" class="sref">O_APPEND  a>))11042  a>}1ssize_t  a> oa href="3>EXPORT_SY3BOL  a>(oa href="+code=ge3eric_34"sref">pipe  a>,/&+code=ret" class="srefa href= a>stti_ a>s  a> >/0);1stti_ a>s1do_spa href="fs/splicu a>s  a> >/0);1do_spl7">1097  a>    pipe" class="sref">pipe  a>,/oa href="+code=out" class="sref">out  a>, a>,/oa href="+code=out" cl3generic_fi3e_splice_write  a>);1filde=pipe_to_sendpage" clas3g         3ef="+code=pipe_buffer" cl3ss="s348s  a> >/0);1do_smhref="fs/splice.c#L1026" i3eNVAL" cla3lass="sref">sd  a>)11002  a>1/*,/struct/oa href="+codde=O_APPEND" class="srefSPIPl oa href="+codefSPIPl hre>,/oa href="+code=out" cl3L=i_sb" cl30" class="line" nam 1035sref">loff_t  a>/*oa 5" iddata  a>;1/*oa 5" i=id1103  a>        if (oa hfef="+code1ne" nam 1113FMODliPWRITl oa href="+codeFMODliPWRITldo_siif">ppos  a> +=/oa href="3d="sref">o3  a>(oa href="+code=pipe"3class35s="sref">ppos  a>,/oaaaaaaaaaaaaaaaaade=O_APPEND" class="sref">O_APPEND  a>))1, oa href="+code=s3" cla35t;oa href="+code=spli a>/*oa 5" id*eg splice ice_w 3aEXPORT_SY33ss="sref">EBADF  a>;1ppos  a>,/oasredo_sice_write" S2vAULTclass="sref">O_AvAULT  a>))1);1125ss="s} else)11s="lid1103 p=sd" class))110573 a>}1<)111108  a>1 */o/spa3.1s  a> >/0);1do_spa class="sref">purn oa href="+code=splice_ef="+code=do_splotr oa hr;/0);1do_spl7">1097  a>    pipe" class="sref">pipe  a>,/oa href="+code=out" class="sref">out  a>, a>,/oa href_sendpage"3clas2r=i_sb" cl2>, oa hre3="+co3e=loff_t"2class26f="+code=PAGE3CACHE_SHIF3" cl2  a> oa hr2f="+code=3en" c36a>;1do_sos="line" nrfrom);1 classcopy"fs/s_userfrom);1 cla96 get_ a>statamplicef="+code=do_splotruurn oa href="+c="+code=splice_ef="+code=do_splotr oa hr;/ode=truurndo_sp   oaofid*e>1110  a> 3    2flags" cla2s="sref">3lags 3a>)11O_AvAULT  a>))11367  2063  a>   2    oa hr3f="+c3de=ssize_2" cla26="sref">ssize3t  a> oa h3ef="20EXPORT_SY2lass="sre3">ret36+code=ge3eric_34"sref">pipe  a>,/&+code=095">1095o/a>osp">ret  a> < 0))1,/oa href1367  20eneric_fi2lags" cla3s="sr36>);1filde=pipe_to_sendpage"3clas2r         2class="li3e" na36ffer" cl3ss="s3481113o a>s  a> >/0);1do_smhref="fs/spa> +=/oa h3ef="2code=ret" 2lass="sre3">ret36>)1ppos  a> +=/oa h3ef="269" id127o  a>/*,/struct/oa href="+codde=O_APPEND" class="srefSPIPl oa href="+codefSPIPl hre>,/oa href>1110  a> 3    2ode=ret" c2ass="sref3>ret 37am 1035sref">loff_t  a>/*oa 5" id1002  a/0);1do_smhref="fs/splice.c#L1036" i2o a> oa hr2m 107037a>;1/*oa 5" i=id1002  a>11103  a>        if (oa hfef="+code1ne" nam 1113FMODliREAe     P  if (oa hFMODliREAedo_siif">ppos  ="+code=ou3" cl2olags" cla2/splice.c3L107237de=pipe"3class35s="sref">ppos  a>,/oaaaaaaaaaaaaaaaaade=O_APPEND" class="sref">O_APPEND  a>))11073  2>ospa3 cl3ss="c37"+code=s3" cla35t;oa href="+code=spli a>/*oa 5" id1002  a/ode=truurndo_sp   oaofid*ea> +=/oa h3ef="26EXPORT_SY2s="line" 3am 1072o/a>o27"sref">pipe  a>,/&aa>,/oasredo_sice_write" S2vAULTclass="sref">O_AvAULT  a>))1);1125ss="s} else)1;11002  a>11103 p=sd" class))11073  a>26ode=ret" 2"line" na3 }1<)111108  a>1p002">1002="+code=splice_ef="+code=do_splotr oa hr;/0);1do_spa href="fs/splicu a>s  a> >/0);1do_spl7">1097  a>    pipe" class="sref">pipe  a>,/oa href="+code=out" class="sref">out  a>, a>,/oa hrefce.c#L10743 id<21de=ret" c2080" id;11002  a/0);1do_sos="line" nrfrom);1 classcopy"fs/s_userfrom);1 cla96 get_ a>statamplicef="+code=do_splotru002">1002  a/="+code=splice_ef="+code=do_splotr oa hr;/ode=truurndo_sp   oaofid*eice.c#L1073" id2ice.c#L1082" id)11O_AvAULT  a>))11073  2s/splice.3#L10838e=ssize_2" cla26="sref">ssize3ice.c#L1073" id2iEXPORT_SY2/splice.c3L108438+code=ge3eric_34"sref">pipe  a>,/&+code=095">1095o/a>osp">ret  a> < 0))1,/oa hrefice.c#L1073" id2iL1075" cl2,/struct/3a hre38>);1filde=pipe_toa3.13lags 38>;1O_APPEND  a>))13lags  f34ss="sref">filde=pipe_toa3.1pi2e_to_send3age  39node" cl3ss="s34sref">pipe  a>oL1094" cl3ss="2s="line" n2m 10893 a>}110comment"> * @outclass="line" nam EXPOR2_SYMBOL  3>(oa 3ref="+cod2=gene29splice.c#L107 Map     ov a>/o    arrays:  pages   d  posii/pe"gth tupples. With thfa tion pipket  s1generic_2plice_sen3page 39s="line"2nam <28="line" nam s324liure b1/oa tion pipket  s11073  2s/splice.3#L10939 id * @hat operate  aa>/o pieces.a tion pipket  s11034o/a>39id *rs,gs: whicha tion pipket  s1O_m p00ovec;1p00ova hr;but...  splice from/pipe d3.13lags 3a>)1file  a>/*ohages class="srnrbuf9ages="sref">file  a>/*oa href="+c4de=out" cl4ss="3pipe_inode3info" cla4s="sr4f">pipe_i3ode_i30o  a>>>>>>>>>>>>>>>>>o324lice.c#L1062.c#L109artial_page class="srnrbuf9artial_page class="sr__useroa hr9artial class="srnrbuf9artial02  a/="+code=splice_bool class="srnrbufbool;1file  a>/*oa href="+c4d1=out" cl4ss="2s="line" n2m 10894 a>}1/*,30sref"cccccccccccccccc>loff_t  a>/*oa+href="+code=rfrom" class class="srnrbuf9from" classef="+code=truurndo_sif">ppos 4to file.o/4pa3.3L1101" id<3L1101" cl4ss="l40ck" clas3="sre32>, unsigned in4="+code=ou4" cl3L3101" id<3Llice_sen4page 4a>);1 &a30="sref">ssize4t  a> oa h4ef="3" class="l3ne" nam <4L11044>1104  a>3    "2unlikely  a>(owh    nr_vec" class="srnrbufsd_vec"a hra/0);1do_smhref="fs/s4="+code=ou4" cl3=EBADF" cl3ss="sref"4EBADF40>);1loff_t  f32splice.c#L110do_spnhages class="srnrbufn9ages="sr))1p00ovec;1O_clary="sr))1;14lags 408">1018 2a>   21splice.c#L1008" id3ut  a>, o4 href41">pipe_i3ode_i30o  a>a>/*oa+href="+code=->oa href="+ci       if (oa hipe  >,/oa hre4_sendpage"4clas3 if (oa hr3f="+code=4nlike4y" class=3sref"31f="+code=PAGE4CACHE_SHIF4" cl3L1111" cla3s="line" 4am O_AvAULT  a>))1ret4 a>;1/*oa 5" idO_clary="sr;/0);1do_sp0ovclass="sref">p00ova hr;/ode=truurndo_sp   oaofclaryclass="sref">O_clary="sr       struct/oap*4a> +=/oa h4ef="3s4101" id<3de=f_op" 4lass=4sref">f_o3  a>-31t;oa href="+cbreak))1f_o3  a>-31        retur4 -oa href=4+cod3">splice_w3ite  a>;14a hre41>);111claryclass="sref">O_clary="sr24" id))11226  a22ss="sref">file  a>/*"+code=kernel_wrlass="sref" nam 11claryclass="sref">O_clary="sr24" id))1ppos 4to file.o/4pa3.3sNVAL" cla3"line" na4 1018 2a>   21splice h2ef="f2910comment"> * @outclass="line" nam 4a> +=/oa h4ef="3om_pipe_en3  a>(oa h4ef="+42e" nam <2L104925s="line" nam  +=/oa h4ef="3oif (oa hr3lass="sre4">sd 42am 10251080  a>osp99999999*be fun, but...  splice from/pipe4a> +=/oa h4ef="3o1111" cla3="+code=p4pe_un42ck" clas2="sre22splice"+code=splice_errirect"a href=e  aerrir <002 ))1;1/*oa 5" id*4ce.c#L11114 id<3     if (o3 href="+c4de=sd42ref">f_o3  a>-31t;oa href="+cbreak))1O_AvAULT  a>))1num_s4liced42>);1statamplicVERIFYL1113">1113FMODliREAVERIFYL111302  a/="+code=splice_be" class="sre"leasblass="s;/0);1do_spl7">1097  a>    pipe" cla      struct/oap*4c7+code=ou4" cl3125ss="sref">filbreak))110274 a>  42ss="sref3     30="sref">ppos 4ce.c#L11114 id<3eNVAL" cla3lass="lin4" nam428">1018 2a>   21splice h2ef="f2910comment"> * @outclass="line" nam 4ce.c#L11114 id<3code=err" 3lass="sre4">err43e" nam <2L104925s="line" nam o@las:  9ages, thf9"mapmment"> * @outclass="line" nam 4c> +=/oa h4ref=3ef">PAGE_C3CHE_SIZE 4a> - 43am 10251080  a>osp99999999*    nnnnss=" 9ages.a tion pipket  s13AGE_CACHE4SHIFT43a>;1o3t  a>,/*o4 href4"+code=pp3s" cl3ss="srhref="+c,/&ef="+code=do_splotr oa hr =2(>loff_t  f32s)i="sr__useroa hrbe" class="sre"leasblass="se~="sr__useroa hrPAGE_MASKclass="sre"leasPAGE_MASK  a>))13033  33="sref">ssize4t  a> oa h4ef="3d href="+c3         4oa hr4f="+code=3et" c33"srefe h2ef="f2910comment"> * @outclass="line" nam 4ce.c#L11114ef="3s>splice_w31osp99999999* pe"gth a esltip    p thfnPAGE_SIZE.a tion pipket  s1i31ss="comment"/pipe to99999999*be fun, but...  splice from/pipe4ae.c#L11114ef="3sNVAL" cla3pages  a>4;1O_APPEND  a>))1pipe_i3ode_i30o  a>ade=spli a>/*oa 5" alff_t  class="srnrbufalff_t ="sra/0);1et_ a>statamplicef="+code=do_splotr oa hr >1~="sr__useroa hrPAGE_MASKclass="sre"leasPAGE_MASK  a>      struct/oap*4,/&oa 4ref=3e=i_sb" cl3ss="sref"4i_sb 4a>);1341" class4"line4 nam <)1o3ass="sref4>ret 4a>;1do_spnhages class="srnrbufn9ages="sr =2(t_ a>statamplicef="+code=do_splotr oa hr lt; 0)) resdo_sa>"+code=kernel_wrlass="sreflt; 0)) resdo_sa>PAGE_SIZEclass="sre"leasPAGE_SIZE"sref- 1)writerite_; 0)) resdo_sa>PAGE_SHIFTclass="sref">O_PAGE_SHIFT  a>))1104244ref">f_o3  a>-31t;oa ade=spli a>/*oa 5" nhages class="srnrbufn9ages="sr rite_; 0)) resdo_sa>rfrom" class class="srnrbuf9from" classef="f- oa+href="+code=write" class="srsreferket  a> <     struct/oap*4,  a> oa h4ef="3>EXPORT_SY3BOL  a>(o4 href4"+code=ge3eric_34"srefs34s="sr0);1do_spnhages class="srnrbufn9ages="sr =2; 0)) resdo_sa>rfrom" class class="srnrbuf9from" classef="f- oa+href="+code=write" class="srsreferket  a> <))1);1<)11226  a22ss="sref">file  a>/*errirect"a href=e  aerrir <002splice" nam =sim do_spnhages class="srnrbufn9ages="sref">file  a>/*oa href="+c4 id1s="lhages class="srnrbuf9ages="sr[oa+href="+code=write" class="srsreferket  a> <]"sref">out  a>, a>,/oa hre4lice.c#L1046" i3eNVAL" cla3lass="sre4">sd 44a>}1<)1ode=spli a>/*oa 5" idfile  a>/*errirect"a href=e  aerrir <0<= 0      struct/oap*4="+code=ou4" cl3L=i_sb" cl30" class=4line"4nam 1035sref"""""""""break))1 +=/oa h4ef="3d="sref">o3  a>(oa h4ef="+4ode=pipe"3class35s="sre h2ef="f2910comment"> * @outclass="line" nam 4107" id, 4a hre45 id/o thfn9artial 9age"map.a tion pipket  s1EBAD45id);1file  a>/*errirect"a href=e  aerrir <)*oa+href="+code=->oa href="+ci    ++a/0);1do_smhref="fs/s41sendpage"46" i2a         256" class4"line4 nam 125ss="ssssssssscons 7a>/*oa+href="+code=r"+code=kernel_wrlapss="sref" nam 11minidfile  a>/*"1" iddo_spl7">1097  a>    pipe" class="sref">pipe  aPAGE_SIZEclass="sre"leasPAGE_SIZE"sref- t_ a>statamplicef="+code=do_splotr oa hr"sref">out  a>, a>,/oa hre41idppos 41ice.c#L104" cl2oNVAL" cla2m 105745>)1s="lhartial class="srnrbuf9artial02  [oa+href="+code=write" class="srsreferket  a> <]24" id11r"+code=kernel_wrlapss="sreef="+code=trdo_sf="fs/spl4_"+code=ou4clas2r=i_sb" cl2>, oa hre4="+co4e=loff_t"2class26f="+code=PAGE4CACHE_SHIF4" cl2  a> oa hr2f="+code=4en" c46a>;11110  a> 4    2flags" cla2s="sref">4lags 4a>)111r"+code=kernel_wrlapss="sreef="+code=trdo_sf="fs/spl4_07" id   2    oa hr4f="+c46ref">f_o3  a>-31t;oa href="+coa+href="+code=write" class="srsreferket  a> <++ef="+code=trdo_sf="fs/spl4_ splice i4ef="20EXPORT_SY2lass="sre4">ret46+code=ge3eric_34"sreff34ss="sref">filde=pipe_t41467  20eneric_fi2lags" cla4s="sr46>);1<)11226  a22ss="sr h2ef="f2910comment"> * @outclass="line" nam 4="+code=ou4" cl20de=ret" c2      *oa4href=46class="s3ef">i31ss="comment"/pipe to99999999* W   ndn@pp  t+ ketlete  end 0ov;/o3op @ppossinlagstlprobab kmment"> * @outclass="line" nam 4=ice.c#L104ef="2code=ret" 2lass="sre4">ret46ags  a>,2oa hr28 class="comm/pipe to99999999* meana+we havosDetmovossom   p this a>/o  1110  a> 4    2ode=ret" c2ass="sref4>ret 47am 10251080  a>osp99999999*be fun, but...  splice from/pipe4lice.c#L1046" i2o a> oa hr2m 107047a>;11097  a>    pipe" cla but...  splice from/pipe4l1110  a> 4" cl2olags" cla2/splice.c4L107247de=pipe"3class35s="sref">pposbreak))11073  2>ospa3 cl4ss="c47oL1033">3033  33="sref">ssize4a> +=/oa h4ef="26EXPORT_SY2s="line" 4am 1072o/a>o27"srefr h2ef="f2910comment"> * @outclass="line" nam 4="+code=ou4" cl2oL1075" cl2ss="line"4nam <47"+code=f2le" c28pa3 class="c0  a>osp99999999* Don@pp  t+ kntinu.codewe"mappt  sew=" 9ages @hanewe"askt  s25,mment"> * @outclass="line" nam 4=sendpage"4clas2dosp99999999* 25sodewe"mappt  thfnmax a>o@las:  9ages @hat we havomment"> * @outclass="line" nam 4="+code=ou4href2 class="li2e" nam i31ss="comment"/pipe to99999999* room s251ss-privmentpliclice.c#L1094" id4>ice.c#L104  a>26ode=ret" 2"line" na4 ,2oa hr28 class="comm/pipe to99999999*be fun, but...  splice from/pipe4.c#L1078" 4d/*oa 5" errirect"a href=e  aerrir <0<r0);1do_spnhages class="srnrbufn9ages="sr >11035sref"""""""""break))1)1do_spnr_vec" class="srnrbufsd_vec"a hr--))11073  2s/splice.4#L10848ref">f_o3  a>-31t;oa oa+href="+code=-ovclass="sref">p00ova hr++ef="+code=trdo_sf="fs/spl4ice.c#L1074" id2iEXPORT_SY2/splice.c4L108448+code=ge3ericf34ss="sref">filde=pipe_t4ice.c#L1074" id2iL1075" cl2,/struct/4a hre48>);1<)11226  ode=spli a>/*oa 5" write" class="srsreferket  a> <     struct/oap*4a3.14lags 48>;1pipe  a>,/&+code=write" class="srsreferket  a> <))148a>}1<)1pi2e_to_send4age  49de=pipe"2clas">pipe  a>,/&+code=errirect"a href=e  aerrir <))110894 a>}1filde=pipe_t4ice.c#L1074" id2ref">EXPOR2_SYMBOL  4>(oa 49nam <)1generic_2plice_sen4page 49s="li1113  a> 31splice" nam =sigt;/0);1 classcopy"fs/s_usegt;/0);1 cla1105"s324lice.c#L1062.c#L1096" id1096  a>static long/oa hr href="fs/splicu a>  a> >/s324lice.c#L1062.c#L1096" iket  a class="srnrbuf9from" clas  a>static long/oa hr" cclass="srsreferket="sref">file  a>/*oa href="+c4tce.c#L1074pa3.2"3">1073  2s/splice.4#L10949ref">f_o3  a>-31t;oa href="+ca29ss="sref">filode=buf" class="sref">buf  a>,1*4tce.c#L1074ize_2ine" nam <2L1094">1044o/a>49iddo_smhref="fs/s4tce.c#L10746" i2buf  a>,11226  o 31splice" nam =si095">1095o/a>osp">ret  a> < 0))1,/oa hre4de=out" cl4ss="2  a> oa hr2f="+code=4en" c49ss="sref3     30="sref">ppos 4d3.14lags 4a>)110comment"> * @outclass="line" nam 5de=out" cl5ss="3pipe_inode3info" cla5s="sr50e" nam <2L104925s="line" nam  * @outclass="line" nam 5d1=out" cl5ss="2s="line" n2m 108950am 10251080  a>osp* pages   d doing    atom  arfromment"> * @outclass="line" nam 5d2=out" cl5s id2ref">EXPOR2_SYMBOL  5ss="l50a>;1);110_pages_writeab o">1095o/a>osp">caslt>10_pages_writeab o1105"ref">file  a>/*" href="fs/splice.c#L1002  a>1pipe  a" href="fs/splice.c#L1002  a>11097  a>    pipe" cla  /0);1do_smhref="fs/s5="+code=ou5" cl3L4101" id<3L/splice.5#L10950ref">f_o3  a>-31t;oa oa+href="+code=arsref">buf  a>,111" cclass="srsreferket="sr02  a>11file  a>/* href="fs/splicu a>  a> >/atic long/oa hr" cclass="srsreferket="sre 1"sref">out  a>, a>,/oa hre5t  a> oa h5ef="3" class="l3ne" nam <5L110450+code=ge3eric_34"srefe"+code=splice_p8  a>111__rfrom);1 cla>10atom   a>1file  a>/*" href="fs/splice.c#L1002  a>1pipe  a"rsref">buf  a>,1" cclass="srsreferket="sr02  a>1out  a>, a>,/oa hre5t6 a> oa h5e" i2pipe  a" href="fs/splice.c#L1002  a>11097  a>    pipe" cla sref">out  a>, a>,/oa hre5t7 a> oa h5e" i2<11" cclass="srsreferket="sr02  a>11file  a>/* href="fs/splicu a>  a> >/atic long/oa hr" cclass="srsreferket="sre ="sref">pipe  a"rsref">buf  a>,1out  a>, a>,/oa hre5t8 a> oa h5es="2  a> oa hr2f="+code=5en" c50>;11do_smhref="fs/s5=9 a> oa h5es="2 ode=ret" 2s="sref">5lags 508">1018 2a>   21splic_34"srefe"+code=splice_p8  a>111" href="fs/splice.c#L1002  a>11097  a>    pipe" clasref">out  a>, a>,/oa hre5ce.c#L11115 id<3ss="sref">3ut  a>, o5 href51">pipe_i3ode_i30o  a>>>>>>>>>goto/0);1do_spa class="sref">purn oa hrsref">out  a>, a>,/oa hre5c1=out" cl5clas3 if (oa hr3f="+code=5nlike51am 1035sref"f34ss="sref">filde=pipe_t5CACHE_SHIF5" cl3L1111" cla3s="line" 5am filde=pipe_t5C"+code=ou5ef="3s3101" id<3lass="sre5">ret5 a>;1<34ss="sref">filde=pipe_t5C"+code=ou5ef="3s4101" id<3de=f_op" 5lass=5sref">f_o3  a>r h2ef="f2910comment"> * @outclass="line" nam 5a  a> oa h5 id<3s class="l3de=f_op" 5lass=51id * @outclass="line" nam 5 -oa href=5+cod3">splice_w3ite  a>;15a hre51"+code=f2le" c28pa3 class="c0  a>osp*be fun, but...  splice from/pipe5a7+code=ou52  a37e  write 3a>)11226  oa+href="+code=arsref">buf  a>,111" cclass="srsreferket="sr02  a>11file  a>/* href="fs/splicu a>  a> >/atic long/oa hr" cclass="srsreferket="sr, 0 sref">out  a>, a>,/oa hre5a8+code=ou5ss="3slass="lin3ef="+code5inode51ss="sref3     30="sref">ppos 5to file.o/5pa3.3sNVAL" cla3"line" na5 1018 2a>  e"+code=splice_p8  a>111" href="fs/splice.c#L1002  a>11097  a>    pipe" clasref">out  a>, a>,/oa hre5a> +=/oa h5ef="3om_pipe_en3  a>(oa h5ef="+52">pipe_i3ode_ode=spli a>/*oa 5" idstatamplic" href="fs/splice.c#L1002  a>1pipe  a"rsref">buf  a>,1" cclass="srsreferket="sr02  a>1pipe  a" href="fs/splice.c#L1002  a>11097  a>    pipe" cla  ref">out  a>, a>,/oa hre5a1=out" cl5ef="3oif (oa hr3lass="sre5">sd 52>);1"+code=splice_p8  a>1O_AvAULT  a>))1;111" cclass="srsreferket="sr02  a>11file  a>/* href="fs/splicu a>  a> >/atic long/oa hr" cclass="srsreferket="sre ="sref">pipe  a"rsref">buf  a>,1out  a>, a>,/oa hre5ce.c#L11115 id<3     if (o3 href="+c5de=sd52ref">0);1do_spa class="sref">purn oa hr:ref">out  a>, a>,/oa hre5c  a> oa h5 id<3  class="l3 href="+c5de=sd52+code=ge3ericode=spli a>/*oa 5" p8  a>1out  a>, a>,/oa hre5a-oa href=5 id<3 >splice_w3ef">num_s5liced52>);1statamplic" href="fs/splice.c#L1002  a>111095">1095o/a>osp">ret  a> < 0))1,/oa hre5c7+code=ou5" cl3">pipe  a>,/&+code=095">1095o/a>osp">ret  a> < 0))1,/oa hre5c8+code=ou5href3+lass="lin3027">10275 a>  52ss="sf34ss="sref">filde=pipe_t5ce.c#L11115 id<3eNVAL" cla3lass="lin5" nam52a>}1<)1err53e" nam <2L104925s="line" nacomment"> * @outclass="line" nam 5c> +=/oa h5ref=3ef">PAGE_C3CHE_SIZE 5a> - 53am 1025108* For lacks:  a bettft"ietle80">ate  ,"ietle80"> vm"line"()sDet> *rspacnmment"> * @outclass="line" nam 5lice.c#L1056" i3ss="sref">3AGE_CACHE5SHIFT53a>;1 +=/oa h5ef="3s="sref">o3t  a>,/*o5 href53s="line"2nam <28="line" nam 1095o/a>osp">cile class="sr__useroa hrfi o">1095o/a>osp">cile cla, cons 79324lice.c#L1062.c#L10 ovecclass="sref">p00ovec;1p00ova hr;but...  splice from/pipe5t  a> oa h5ef="3d href="+c3         5oa hr5f="+code=3et" c33"sreffffffffffffff>loff_t  f32splice.c#L110,/oa href="+code=out" class="but...  splice from/pipe5t-oa href=5ef="3s>splice_w31do_smhref="fs/s5="+code=ou5" cl3doL1026" c3      *oa5href=53nam s324lice.c#L1062.c#L1096" id1096  a>static long/oa hr href="fs/splicu a>  a> > < 0))1,/oa hre5l8+code=ou5href3a>(oa href3"+code=ma5ping"538am s324lice.c#L1062.c#L10f" class="sref">buf  a>,15;11018 2a>  e"+code=splice_s"1" id,/oa hre5="+code=ou5" cl3d_write  a3(oa href=5+code54">pipe_i3ode_a>/*oa+href="+code=errirect"a href=e  aerrir <))1);11095o/a>osp">ret  a> < 0))1,/oa hre5to file.o/5pa3.3es="sref">341" class5"line5 nam <)1o3ass="sref5>ret 54a>;111 href="fs/splicu a>  a> >002splice" nam =sim file  a>/*fi o">1095o/a>osp">cile cla sref">out  a>, a>,/oa hre5="+code=ou5107"3e104254ref">f_o3  a>a26splice.c#L1032" i href="fs/splicu a>  a> >"but...  splice from/pipe5,  a> oa h5ef="3>EXPORT_SY3BOL  a>(o5 href5"+code=ge3eric_34"srefaaaaaaaaaaaaaaaade=O_APPBADFclass="sref">O_ABADF  a> < 0))1,/oa hre5t-oa href=5" cl3generic_fi3e_splice_5rite 5a>);1<)11226  oa+href="+code=m file  a>/* href="fs/splicu a>  a> > sref">out  a>, a>,/oa hre5=8+code=ou5href3 struct/oa3href="+co5e=spl54ss="sref3     30="sref">ppos 5lice.c#L1056" i3eNVAL" cla3lass="sre5">sd 548">1018 2a>  e"+code=splice_errirect"a href=e  aerrir <002splice" nam =sip8  a>1(owh    nr_seoa href="+code=ounr_seoa cla /0);1do_smhref="fs/s5="+code=ou5" cl3L=i_sb" cl30" class=5line"5nam 1035sref"void e.c#L1062.c#L10 ,/oa href="+cod__userfrom" class="sr__useroa hrbe" class="sre"leasblass="srout_releas_  a>>,/oa hre5lice.c#L1056" i3de=data" c3ass="sref5>data55ck" clas2="sre22splice"+code=splice_"1" ido3  a>(oa h5ef="+55a>;1<34ss="sref">filde=pipe_t5107" id, 5a hre55ref">f_o3  a>-31t;oa o <2L104925s="line" nacomment"> * @outclass="line" nam 5g splice i5e_w 3aEXPORT_SY33ss="sref5>EBAD55id * @outclass="line" nam 5g-oa href=5+cod2aeneric_fi2ss="sref"5data 55"+code=f2le" c28pa3 class="c0  a>osp99999999*be fun, but...  splice from/pipe51sendpage"56" i2a         256" class5"line5 nam 125ss="se"+code=splice_errirect"a href=e  aerrir <002splice" nam =sim statamplicbe" class="sre"leasblass="s;/  a>1s="liovclass="sref">p00ova hr02  a>1 sref">out  a>, a>,/oa hre51id1file  a>/*errirect"a href=e  aerrir <  ref">out  a>, a>,/oa hre51ice.c#L105" cl2oNVAL" cla2m 105755>)1statamplicl7">1097  a>    pipe" class  a>1s="liovclass="sref">p00ova hr02  a>1 sref">out  a>, a>,/oa hre5_"+code=ou5clas2r=i_sb" cl2>, oa hre5="+co56am 1035sref">loff_t  a>/*oa 5" unfile  a>/*errirect"a href=e  aerrir <  ref">out  a>, a>,/oa hre5CACHE_SHIF5" cl2  a> oa hr2f="+code=5en" c56a>;1 +=/oa h5    2flags" cla2s="sref">5lags 56a>;1<34ss="sref">filde=pipe_t5_07" id   2    oa hr5f="+c56ref">f_o3  a>-31t;oa o <2L104925s="line" nacomment"> * @outclass="line" nam 5_ splice i5ef="20EXPORT_SY2lass="sre5">ret56id1567  20eneric_fi2lags" cla5s="sr56"+code=f2le" c28pa3 class="c0  a>osp99999999*be fun, but...  splice from/pipe5_sendpage"5clas2r         2class="li5e" na56L1026">1226  a22ss="sode=spli a>/*oa 5" id*5="+code=ou5" cl20de=ret" c2      *oa5href=56>;1ret56>)1do_smhref="fs/s5a> +=/oa h5ef="269" ids="lerrirect"a href=e  aerrir <002do_sice_write" S2vAULTclass="sref">O_AvAULT  a>))11035sref"""""""""break))1 oa hr2m 107057a>;1filde=pipe_t5l1110  a> 5" cl2olags" cla2/splice.c5L107257a>;1<34ss="sref">filde=pipe_t5 id1073  2>ospa3 cl5ss="c57ref">f_o3  a>-31t;oa ade=spli a>/*oa 5" idstatamplicVERIFYLWRITE class="srnrbufVERIFYLWRITE >/atic long/oa hr"e" class="sre"leasblass="s;/0);1do_spl7">1097  a>    pipe" cla   /0);1do_smhref="fs/s5a splice i5ef="26EXPORT_SY2s="line" 5am 1072o/a>o27"srefccccccccs="lerrirect"a href=e  aerrir <002do_sice_write" S2vAULTclass="sref">O_AvAULT  a>))115" cl2oL1075" cl2ss="line"5nam <57>);11226  a22ss="sf34ss="sref">filde=pipe_t5l"+code=ou5href2 class="li2e" nam ppos 5>ice.c#L105  a>26ode=ret" 2"line" na5 1018 2a>   21splice.c#L1008" id1035sref"e.c#L1008" id,/oa href="+code=out" class=002splice" nam =si>,/oa href="+code=out" class=rout_releas_  a>>,/oa hre5cice.c#L105;111"e" class="sre"leasblass="srout_releas_  a>>,/oa hre5ice.c#L1075" id2ice.c#L1082" id)1do_sp" href="fs/splice.c#L1024" id1073  2s/splice.5#L10858e=ssize_2" cla26="sref">ssize5ice.c#L1075" id2iEXPORT_SY2/splice.c5L108458+code=ge3eric_34"sref       oa href=    11__a href=f cla href="fs/splicu a>__a href=f cla hremm05"ref">file  a>/* href="fs/splicu a>  a> >ss  a>1s="l" href="fs/splice.c#L10;/0);1do_spgt;/0);1 classcopy"fs/s_usegt;/0);1 cla1105 sref">out  a>, a>,/oa hre5ice.c#L1075" id2iL1075" cl2,/struct/5a hre58>);1do_smhref="fs/s5a3.1125ss="sssssssssa26splice.c#L1032" ip8  a>1do_smhref="fs/s5a"+code=ou5="fs2iclass="li2s="sref">5lags 58>;1111"   ,/oa hre5a3.158a>}1<)1pi2e_to_send5age  59de=pipe"2class22splicccccccccbreak))1108959am 1035sref"f34ss="sref">filde=pipe_t5ice.c#L1075" id2ref">EXPOR2_SYMBOL  5>(oa 59nam <)1generic_2plice_sen5page 59>)1do_spp8  a>111"   ,/oa hre5tce.c#L1075pa3.2"3">1073  2s/splice.5#L10959e=ssize_2" cla26="sref">ssize5tce.c#L1075ize_2ine" nam <2L1094">1054o/a>59+code=ge3eric_34"sref 26s       oa href=    do_spl7">1097  a>    pipe" cla ze_2" cla26="sref">ssize5tce.c#L10756" i2 oa hr2f="+code=5en" c59>;15lags 5a>)1p00ova hr++ef="+code=trdo_sf="fs/spl6de=out" cl6ss="3pipe_inode3info" cla6s="sr6f">pipe_i3ode_f34ss="sref">filde=pipe_t6d1=out" cl6ss="2s="line" n2m 108960=loff_t"2class26f="+code=PAGE6d2=out" cl6s id2ref">EXPOR2_SYMBOL  6ss="l60a>;1do_spgt;/0unlock class="srnrbufm file  a>/* href="fs/splicu a>  a> > sref">out  a>, a>,/oa hre6="+code=ou6" cl3L3101" id<3Llice_sen6page 60a>;1<34ss="sref">filde=pipe_t6="+code=ou6" cl3L4101" id<3L/splice.6#L10960ref">f_o3  a>a26splice.c#L1032" ip8  a>1do_smhref="fs/s6t  a> oa h6ef="3" class="l3ne" nam <6L110460+code=ge3eric_34"srefe"+code=splice_p8  a>111errirect"a href=e  aerrir <))1 oa h6e" i2<">pipe  a>,/&+code=095">1095o/a>osp">ret  a> < 0))1,/oa hre6t8 a> oa h6es="2  a> oa hr2f="+code=6en" c60ss="sf34ss="sref">filde=pipe_t6=9 a> oa h6es="2 ode=ret" 2s="sref">6lags 60a>}1<)13ut  a>, o6 href61e" nam <2L104925s="line" nacomment"> * @outclass="line" nam 6c1=out" cl6clas3 if (oa hr3f="+code=6nlike61am 1025108* vm"line" "line"a+a ss=" addresd rangeaa>/o   * @outclass="line" nam 6c2=out" cl6" cl3L1111" cla3s="line" 6am ;1 * @outclass="line" nam 6c"+code=ou6ef="3s3101" id<3lass="sre6">ret61s="line"2nam <28="line" nam < @o funl). I9"both"07ses @he output ia+  oa h6 id<3s class="l3de=f_op" 6lass=61id1095o/a>osp">cile class="sr__useroa hrfi o">1095o/a>osp">cile cla, cons 79324lice.c#L1062.c#L10 ovecclass="sref">p00ovec;1p00ova hr;but...  splice from/pipe6a6 a> oa h6+cod3">splice_w3ite  a>;16a hre61>);1loff_t  f32splice.c#L110,/oa href="+code=out" class="but...  splice from/pipe6a7+code=ou62  a37e  write 3a>)1do_smhref="fs/s6a8+code=ou6ss="3slass="lin3ef="+code6inode618am s324lice.c#L1062.c#L1096" id1096  a>static long/oa hr href="fs/splicu a>  a> > < 0))1,/oa hre6to file.o/6pa3.3sNVAL" cla3"line" na6 1018 2a>  s324lice.c#L1062.c#L109agef="fs/splicu a> age  a>static long/oa hr ages class="srnrbuf9ages="sr[oa+href="+code=PIPE_DEF_BUFFERS class="srnrbufPIPE_DEF_BUFFERS="sr] < 0))1,/oa hre6a> +=/oa h6ef="3om_pipe_en3  a>(oa h6ef="+62">pipe_i3ode_s324lice.c#L1062.c#L109artial_9agef="fs/splicu a> artial_9age;1,/oa hre6a1=out" cl6ef="3oif (oa hr3lass="sre6">sd 62>);1buf  a>,1do_smhref="fs/s6a> +=/oa h6ef="3o1111" cla3="+code=p6pe_un62ck" clas2="sre22splic24" id11rages class="srnrbuf9ages="sr;but...  splice from/pipe6/oa href="6code3e=pipe" cl3ss="sref"6pipe 62a>;111rartial class="srnrbuf9artial02  ;but...  splice from/pipe6/"+code=ou6 id<3     if (o3 href="+c6de=sd62ref">f_o3  a>-31t;oa 24" id11PIPE_DEF_BUFFERS class="srnrbufPIPE_DEF_BUFFERS="sr;but...  splice from/pipe6/  a> oa h6 id<3  class="l3 href="+c6de=sd62+code=ge3eric_34"sref24" id,/oa href="+code=out" class=002splice" nam =si>,/oa href="+code=out" class=;but...  splice from/pipe6/6 a> oa h6 id<3 >splice_w3ef">num_s6liced62>);11s="lss="_page_9from" c_ip class="srsreferss="_page_9from" c_ip ass=;but...  splice from/pipe6/7+code=ou6" cl3125ss="s24" id11"pd_relee" _9agef="fs/splicu a>"pd_relee" _9ageass=;but...  splice from/pipe6/8+code=ou6href3+lass="lin3027">10276 a>  628am } < 0))1,/oa hre6ao file.o/6 id<3eNVAL" cla3lass="lin6" nam628">1018 2a>  f32splice.c#L1101095o/a>osp">ret  a> < 0))1,/oa hre6ce.c#L11116 id<3code=err" 3lass="sre6">err63e" na< 0))1,/oa hre6c1=out" cl6ref=3ef">PAGE_C3CHE_SIZE 6a> - 63>);1  a> >002splice" nam =sim file  a>/*fi o">1095o/a>osp">cile cla sref">out  a>, a>,/oa hre6lice.c#L1066" i3ss="sref">3AGE_CACHE6SHIFT63ck" clas2="sra26splice.c#L1032" i href="fs/splicu a>  a> >"but...  splice from/pipe6a> +=/oa h6ef="3s="sref">o3t  a>,/*o6 href6"+code=pp3s" cl3ss="sraaaaaaaaaaaaaaaade=O_APPBADFclass="sref">O_ABADF  a> < 0))1,/oa hre6="+code=ou6" cl3d3033  33="sref">ssize6t  a> oa h6ef="3d href="+c3         6oa hr6f="+code=3et"  26s       oa href=  href=grow_sp href="fs/splice.phref=grow_sp mm05"ref">file  a>/* href="fs/splicu a>  a> >ss  a>1s="l"p href="fs/splice.pd"lin      struct/oap*6t-oa href=6ef="3s>splice_w31);1O_ANOMEM  a> < 0))1,/oa hre6=7+code=ou6" cl3doL1026" c3      *oa6href=63L1026)1s="l"p href="fs/splice.pd"lin24" idfile  a>/*0ovclass="sref">p00ova hr;plice.c#L1106;1al" class="sre"leas>al" ="sr;but...  splice from/pipe6="+code=ou6" cl3d_write  a3(oa href=6+code64de=pipe"2class22splicccccccccccccccccccccccccccccs="l"p href="fs/splice.pd"lin24" idout  a>, a>,/oa hre6,/&oa 6ref=3e=i_sb" cl3ss="sref"6i_sb 6a>);1out  a>, a>,/oa hre6,ice.c#L106pa3.3es="sref">341" class6"line64a>;1111"  href="fs/splice.pd"lin24" idout  a>, a>,/oa hre6,> +=/oa h6pa3.3e="sref">o3ass="sref6>ret 64a>;1out  a>, a>,/oa hre6,"+code=ou6107"3e104264ref">f_o3  a>-31t;oa e.c#L1008" id111" ine"L);1 href="fs/splicu a>"line"L);1 hremm05"ref">file  a>/* href="fs/splicu a>  a> >ss  a>1s="l"p href="fs/splice.pd"lin sref">out  a>, a>,/oa hre6,  a> oa h6ef="3>EXPORT_SY3BOL  a>(o6 href6"+coderef">out  a>, a>,/oa hre6,-oa href=6" cl3generic_fi3e_splice_6rite 646am s="l"pine"Lshrink_sp href="fs/splice.phref=shrink_sp mm05"  a>1s="l"p href="fs/splice.pd"lin sref">out  a>, a>,/oa hre6,7+code=ou6clas3g         3ef="+code6pipe_64nam ">pipe  a>,/&+code=095">1095o/a>osp">ret  a> < 0))1,/oa hre6=8+code=ou6href3 struct/oa3href="+co6e=spl64ss="sf34ss="sref">filde=pipe_t6lice.c#L1066" i3eNVAL" cla3lass="sre6">sd 64a>}1<)1 * @outclass="line" nam 6="+code=ou6" cl3L=i_sb" cl30" class=6line"65am 1025108* Note  ea> vm"line" only ss=lly supports tru" "lineing =f cla ss=" memorymment"> * @outclass="line" nam 6=ice.c#L1066" i3de=data" c3ass="sref6>data65a>;1 * @outclass="line" nam 6=> +=/oa h6ef="3d="sref">o3  a>(oa h6ef="+65s="line"2nam <28="line" nam < operate    ea> 079"bl supported without any funky align80"> restricte  smment"> * @outclass="line" nam 6="+code=ou6107"3ass="sref"3len  a>, 6a hre65 id * @outclass="line" nam 6=  a> oa h6e_w 3aEXPORT_SY33ss="sref6>EBAD65id * @outclass="line" nam 6=-oa href=6+cod2aeneric_fi2ss="sref"6data 65"+code=f2le" c28pa3 class="c* solute  s s25s eat:mment"> * @outclass="line" nam 6=7+code=ou66" i2a         256" class6"line65plice.c#337rom31ospa3 class=omment"> * @outclass="line" nam 6=8+code=ou6" cl2ode=ret" c2ass="sref6>ret 65class="s3ef">i31ss="comment"*1256">- memcpy()sDnnndataaa>/ern=lly, at which poa>/*we"might aa+well justmment"> * @outclass="line" nam 6=ice.c#L106" cl2oNVAL" cla2m 105765ags  a>,2oa hr28 class="comm*oL1256">do  - Lots ofsnasty vm tricks,  ea> aposnei@her fast nor flexible (itmment"> * @outclass="line" nam 6_"+code=ou6clas2r=i_sb" cl2>, oa hre6="+co66am 1025108*        haa+restricte   limi>ate  sso  both"ends  p thfn  a>).a tion pipket  s1 oa hr2f="+code=6en" c66a>;1 +=/oa h6    2flags" cla2s="sref">6lags 66s="line"2nam <28="line" nam < Curr" nlyawe"punt   d ietle80"> it  a+a normal rfro, sefn  a>0);1 cla().a tion pipket  s1   2    oa hr6f="+c66 idret66id1667  20eneric_fi2lags" cla6s="sr66"+codea>,/&+code=SYSCALL_DEFINE4">1095o/a>osp">SYSCALL_DEFINE4mm05"ref">file  a>/*vm"line"f="fs/splicu a>vm"line" >ssa>/;2splice" nam =si> href="fs/splicefd cla, cons 79324lice.c#L1062.c#L10 ovecclass="sref">p00ovec;1p00ova hr;but...  splice from/pipe6_sendpage"6clas2r         2class="li6e" na66L1026">1226  a22ss="s>loff_t  f32s;plice.c#L110,/oa href="+code=out" class="but...  splice from/pipe6="+code=ou6" cl20de=ret" c2      *oa6href=66>;1do_smhref="fs/s6_ice.c#L106ef="2code=ret" 2lass="sre6">ret668">1018 2a>  s324lice.c#L1062.c#L10fi o">1095o/a>osp">cile class="sr__useroa hrfi o">1095o/a>osp">cile cla < 0))1,/oa hre6a> +=/oa h6ef="269" id1a>/*oa+href="+code=>p class="sref">pur>p c <))1 oa hr2m 107067nam <)1loff_t  a>/*oa 5" unfile  a>/*nr_seoa href="+code=ounr_seoa claerite_ref">file  a>/*UIO_MAXIOV href="+code=ouUIO_MAXIOV"lin      struct/oap*6 id1073  2>ospa3 cl6ss="c67ref">f_o3  a>-31t;oa aaaaaaaaaaaaaaaade=O_APPINVALclass="sref">O_AINVAL <))11072o/a>el"  ade=spli a>/*oa 5" id16" cl2oL1075" cl2ss="line"6nam <67>);1s="lerrirect"a href=e  aerrir <002do_sice_write" S2BADFclass="sref">O_ABADF  a> < 0))1,/oa hre6>ice.c#L106  a>26ode=ret" 2"line" na6 1018 2a>  e"+code=splice_fi o">1095o/a>osp">cile clas02splice" nam =si>m 1095o/a>osp">cm file  a>/*f href="fs/splicefd cla,   a>1s="l>p class="sref">pur>p c < sref">out  a>, a>,/oa hre6.c#L1078" 6dpipe_i3ode_ode=spli a>/*oa 5" fi o">1095o/a>osp">cile cla  0);1do_smhref="fs/s6ce.c#L10746 id<21de=ret" c2080" id1035sref"ode=spli a>/*oa 5" fi o">1095o/a>osp">cile cla02  a>11095o/a>osp">c_mne" claer a>12splice" nam =siFMODELWRITE class="srnrbufFMODELWRITEass="but...  splice from/pipe6cice.c#L106;1s="lerrirect"a href=e  aerrir <002ref">file  a>/*vm"line"L);1 href="fs/splicu a>vm"line"L);1 hremm05"spli a>/*oa 5" fi o">1095o/a>osp">cile cla;2splice" nam =si0ovclass="sref">p00ova hr;plice.c#L110,/oa href="+code=out" class="sref">out  a>, a>,/oa hre6.1110  a> 6" id2ice.c#L1082" id)1/*oa 5" fi o">1095o/a>osp">cile cla02  a>11095o/a>osp">c_mne" claer a>12splice" nam =siFMODELREAD class="srnrbufFMODELREADass="but...  splice from/pipe6cid1073  2s/splice.6#L10868ref">f_o3  a>-31t;oa href="+cs="lerrirect"a href=e  aerrir <002ref">file  a>/*vm"line"L);1 classcopy"fs/s_usevm"line"L);1 cla1105"spli a>/*oa 5" fi o">1095o/a>osp">cile cla;2splice" nam =si0ovclass="sref">p00ova hr;plice.c#L110,/oa href="+code=out" class="sref">out  a>, a>,/oa hre6.  a> oa h6" id2iEXPORT_SY2/splice.c6L108468+coderef">out  a>, a>,/oa hre6ice.c#L1076" id2iL1075" cl2,/struct/6a hre68>);1s="l>p colight">1095o/a>osp">cp colight1105"spli a>/*oa 5" fi o">1095o/a>osp">cile cla;2splice" nam =si>p class="sref">pur>p c < sref">out  a>, a>,/oa hre6.sendpage"6="fs2if34ss="sref">filde=pipe_t6a"+code=ou6="fs2iclass="li2s="sref">6lags 68ss="sref3     30="sref">ppos 6a3.1688">1018 2a>  ">pipe  a>,/&+code=errirect"a href=e  aerrir <))1pi2e_to_send6age  69de=pif34ss="sref">filde=pipe_t6ae.c#L10746ss="2s="line" n2m 108969=loff_t"2class26f="+code=PAGE6ice.c#L1076" id2ref">EXPOR2_SYMBOL  6>(oa 69nam ,/&+code=SYSCALL_DEFINE6ect"a href=e  aSYSCALL_DEFINE61105"spli a>/*oa 5" "line"f="fs/splicu a>"line" >ssa>/;2splice" nam =si> _i">1097  a>    pi> _i" cla;2splice" nam =siloffid1097  a>    pioffii"a hr;but...  splice from/pipe6to file.o/6pa3.2">generic_2plice_sen6page 69>)1/;2splice" nam =si> _a class="sref">pur> _a c cla;2splice" nam =siloffidpurnffia ca hr;but...  splice from/pipe6tid1073  2s/splice.6#L10969ref">f_o3  a>-31t;oa oa+href="+code=a1" iddo_spl7">1097  a>    pipe" cla, >loff_t  a>/;2splice" nam =si>,/oa href="+code=out" class="but...  splice from/pipe6tce.c#L1076ize_2ine" nam <2L1094">1064o/a>69+code0);1do_smhref="fs/s6tce.c#L10766" i2s324lice.c#L1062.c#L10fi o">1095o/a>osp">cile class="sr__useroa hri">1097  a>    pii" cla;2s="sr__useroa hra class="sref">purn oa hrsref">out  a>, a>,/oa hre6a"+code=ou6ss="2  a> oa hr2f="+code=6en" c69>;1p c_i">1097  a>    pi>p c_i" cla;2splice" nam =si>p c_a class="sref">pur>p c_a ca hrsref">out  a>, a>,/oa hre6a3.16lags 69a>}1<)1pipe_i3ode_ode=spli a>/*oa 5" id*7d1=out" cl7ss="2s="line" n2m 108970am 1035sref"aaaaaaa ))1EXPOR2_SYMBOL  7ss="l70nam <)1;111errirect"a href=e  aerrir <002do_sice_write" S2BADFclass="sref">O_ABADF  a> < 0))1,/oa hre7="+code=ou7" cl3L4101" id<3L/splice.7#L10970ref">f_o3  a>="sr__useroa hri">1097  a>    pii" clas02splice" nam =si>m 1095o/a>osp">cm file  a>/*f _i">1097  a>    pi> _i" cla;2  a>1s="l>p c_i">1097  a>    pi>p c_i" cla sref">out  a>, a>,/oa hre7t  a> oa h7ef="3" class="l3ne" nam <7L110470="+code=3et"  26s       oa href=i">1097  a>    pii" cla  0);1do_smhref="fs/s7t6 a> oa h7e" i21097  a>    pii" cla02  a>11095o/a>osp">c_mne" claer a>12splice" nam =siFMODELREAD class="srnrbufFMODELREADass=" 0);1do_smhref="fs/s7t7 a> oa h7e" i2<125ss="sssssssss="sr__useroa hra class="sref">purn oa hrs02splice" nam =si>m 1095o/a>osp">cm file  a>/*f _a class="sref">pur> _a c cla;2  a>1s="l>p c_a class="sref">pur>p c_a ca hr sref">out  a>, a>,/oa hre7t8 a> oa h7es="2  a> oa hr2f="+code=7en" c70>;1purn oa hr" 0);1do_smhref="fs/s7t9 a> oa h7es="2 ode=ret" 2s="sref">7lags 70ef="fs/s3lice.33spliccccccccccccccccc 26s       oa href=a class="sref">purn oa hr02  a>11095o/a>osp">c_mne" claer a>12splice" nam =siFMODELWRITE class="srnrbufFMODELWRITEass="but...  splice from/pipe7ce.c#L11117 id<3ss="sref">3ut  a>, o7 href71de=pipe"2class22splicccccccccccccccccccccccccs="lerrirect"a href=e  aerrir <002ref">file  a>/*do_"line"f="fs/splicu a>do_"line"mm05"ref">file  a>/*i">1097  a>    pii" cla;2splice" nam =sioffii">1097  a>    pioffii"a hr;but...  splice from/pipe7c1=out" cl7clas3 if (oa hr3f="+code=7nlike71am 1035sref"""""""""ass22splicccccccccccccccccccccccccs="la class="sref">purn oa hr;2splice" nam =sioffia class="sref">purnffia ca hr;but...  splice from/pipe7c2=out" cl7" cl3L1111" cla3s="line" 7am ;1ass22splicccccccccccccccccccccccccs="ll7">1097  a>    pipe" cla, s="l>,/oa href="+code=out" class="sref">out  a>, a>,/oa hre7c"+code=ou7ef="3s3101" id<3lass="sre7">ret71>)1s="l>p colight">1095o/a>osp">cp colight1105"spli a>/*oa 5" a class="sref">purn oa hr;2splice" nam =si>p c_a class="sref">pur>p c_a ca hr sref">out  a>, a>,/oa hre7C"+code=ou7ef="3s4101" id<3de=f_op" 7lass=71ref">f_o3  a>-31t;oa href="+cf34ss="sref">filde=pipe_t7a  a> oa h7 id<3s class="l3de=f_op" 7lass=71+code=ge3eric_34"sreff34ss="sref">filde=pipe_t7a6 a> oa h7+cod3">splice_w3ite  a>;17a hre71>);1<)1125ss="se"+code=splice_>p colight">1095o/a>osp">cp colight1105"spli a>/*oa 5" i">1097  a>    pii" cla;2splice" nam =si>p c_i">1097  a>    pi>p c_i" cla sref">out  a>, a>,/oa hre7a8+code=ou7ss="3slass="lin3ef="+code7inode718am f34ss="sref">filde=pipe_t7a9 a> oa h7pa3.3sNVAL" cla3"line" na7 }1<)1(oa h7ef="+72">pipe_i3ode_">pipe  a>,/&+code=errirect"a href=e  aerrir <))1sd 72>);1filde=pipe_t7a> +=/oa h7ef="3o1111" cla3="+code=p7pe_un72nam <)1 * @outclass="line" nam 7/"+code=ou7 id<3     if (o3 href="+c7de=sd72 id * @outclass="line" nam 7/  a> oa h7 id<3  class="l3 href="+c7de=sd72idpipe 2" appropriate errir.a tion pipket  s1num_s7liced72"+code=f2le" c28pa3 class="c*be fun, but...  splice from/pipe7/7+code=ou7" cl30prep>1097  a>    pii  a>0prep1105"s324lice.c#L1062.c#L1096" id1096  a>static long/oa hr href="fs/splicu a>  a> >, >loff_t  a>/*oa+href="+code=>,/oa href="+code=out" class="but...  splice from/pipe7/8+code=ou7href3+lass="lin3027">10277 a>  72>;1do_smhref="fs/s7ao file.o/7 id<3eNVAL" cla3lass="lin7" nam728">1018 2a>  a>/*oa+href="+code=095">1095o/a>osp">ret  a> < 0))1,/oa hre7ce.c#L11117 id<3code=err" 3lass="sre7">err73e" na< 0))1,/oa hre7c1=out" cl7ref=3ef">PAGE_C3CHE_SIZE 7a> - 73>);1 * @outclass="line" nam 7lice.c#L1076" i3ss="sref">3AGE_CACHE7SHIFT73a>;1 * @outclass="line" nam 7loa href="7ef="3s="sref">o3t  a>,/*o7 href73s="line"2nam <28="line" nam eeeeeeee* ia+"lecul13 ve anyways, so missing on" ia+ok.a tion pipket  s1 oa h7ef="3d href="+c3         7oa hr7f="+code=3et"  26s       oa href= href="fs/splicu a>  a> >02  a>1splice_w31);1s="lp8  a>17;11018 2a>  e"+code=splice_m file  a>/* href="fs/splicu a>  a> > sref">out  a>, a>,/oa hre7="+code=ou7" cl3d_write  a3(oa href=7+code74e" na< 0))1,/oa hre7,/&oa 7ref=3e=i_sb" cl3ss="sref"7i_sb 7a>);1do_smhref="fs/s7,ice.c#L107pa3.3es="sref">341" class7"line74a>;1file  a>/*curr" ndo_smhref="fs/s7,oa href="7pa3.3e="sref">o3ass="sref7>ret 74>)1s="lp8  a>1104274ref">f_o3  a>-31t;oa         break))1EXPORT_SY3BOL  a>(o7 href7"+code=ge3eric_34"sreff34ss="sref">filde=pipe_t7,-oa href=7" cl3generic_fi3e_splice_7rite 74>);1125ss="sssssssssbreak))1;1do_smhref="fs/s7,e.c#L111176" i3eNVAL" cla3lass="sre7">sd 74ef="fs/s3lice.33splicccccccccade=spli a>/*oa 5" f,/oa href="+code=out" class=0r a>12splice" nam =siSPLICE_F_NONBLOCK href="+code=ouSPLICE_F_NONBLOCKass=" 0);1do_smhref="fs/s7to file.o/7pa3.3L1049" id<3L1049" cl7ss="l75de=pipe"2class22splicccccccccccccccccs="lp8  a>11035sref"125ss="sssssssssbreak))1filde=pipe_t7=> +=/oa h7ef="3d="sref">o3  a>(oa h7ef="+75>)1filde=pipe_t7="+code=ou7107"3ass="sref"3len  a>, 7a hre75ref">f_o3  a>-31t;oa o"+code=splice_m file  a>/* href="fs/splicu a>  a> > sref">out  a>, a>,/oa hre7=  a> oa h7e_w 3aEXPORT_SY33ss="sref7>EBAD75+code=ge3ericf34ss="sref">filde=pipe_t7=-oa href=7+cod2aeneric_fi2ss="sref"7data 75>);1<)1o"+code=splice_m file  a>/* href="fs/splicu a>  a> > sref">out  a>, a>,/oa hre7=8+code=ou7" cl2ode=ret" c2ass="sref7>ret 75>;1pipe  a>,/&+code=095">1095o/a>osp">ret  a> < 0))1,/oa hre7=ice.c#L107" cl2oNVAL" cla2m 105775ags  f34ss="sref">filde=pipe_t7_sendpage"7clas2ref="+code2pipe_inod7_info76e" na< 0))1,/oa hre7_"+code=ou7clas2r=i_sb" cl2>, oa hre7="+co76am 102510comment"> * @outclass="line" nam 7_ice.c#L107" cl2  a> oa hr2f="+code=7en" c76a>;1 * @outclass="line" nam 7_> +=/oa h7    2flags" cla2s="sref">7lags 76s="line"2nam <28="line" nam < ">pipe 2" appropriate errir.a tion pipket  s1   2    oa hr7f="+c76 id oa h7ef="20EXPORT_SY2lass="sre7">ret76id/*oa+href="+code=o  a>0prep>1097  a>    pio  a>0prep1105"s324lice.c#L1062.c#L1096" id1096  a>static long/oa hr href="fs/splicu a>  a> >, >loff_t  a>/*oa+href="+code=>,/oa href="+code=out" class="but...  splice from/pipe71767  20eneric_fi2lags" cla7s="sr76"+cod0);1do_smhref="fs/s7_sendpage"7clas2r         2class="li7e" na76L1026">1226  a>/*oa+href="+code=095">1095o/a>osp">ret  a> < 0))1,/oa hre7="+code=ou7" cl20de=ret" c2      *oa7href=76ss="sref3     30="sref">ppos 7_ice.c#L107ef="2code=ret" 2lass="sre7">ret768">1018 2a>  L1020">102510comment"> * @outclass="line" nam 7a> +=/oa h7ef="269" id * @outclass="line" nam 7>1110  a> 7    2ode=ret" c2ass="sref7>ret 77am 1025108mmmmmmmm* ia+"lecul13 ve anyways, so missing on" ia+ok.a tion pipket  s1 oa hr2m 107077a>;1loff_t  a>/*oa 5"  href="fs/splicu a>  a> >02  a>1do_sp href="fs/splicu a>  a> >02  a>11073  2>ospa3 cl7ss="c77ref">f_o3  a>-31t;oa aaaaaaa ))1out  a>, a>,/oa hre7 oL1067">17" cl2oL1075" cl2ss="line"7nam <776am s="lp8  a>1o"+code=splice_m file  a>/* href="fs/splicu a>  a> > sref">out  a>, a>,/oa hre7l"+code=ou7href2 class="li2e" nam ppos 7>ice.c#L107  a>26ode=ret" 2"line" na7 1018 2a>  "2unlikf_t  a>/*oa 5"  href="fs/splicu a>  a> >02  a>1do_sp href="fs/splicu a>  a> >02  a>1do_smhref="fs/s7.c#L1078" 7ddo_smhref="fs/s7.1110  a> 7 id<21de=ret" c2080" id1035sref"oL1256">o"+code=splice_send_offfile  a>/*SIGPIPE href="+code=ouSIGPIPE cla;2splice" nam =sicurr" nout  a>, a>,/oa hre7cice.c#L107;1s="lp8  a>1out  a>, a>,/oa hre7c1110  a> 7" id2ice.c#L1082" id)11073  2s/splice.7#L10878ref">f_o3  a>-31t;oa f34ss="sref">filde=pipe_t7.  a> oa h7" id2iEXPORT_SY2/splice.c7L108478+code=ge3eric_34"srefade=spli a>/*oa 5" f,/oa href="+code=out" class=0r a>12splice" nam =siSPLICE_F_NONBLOCK href="+code=ouSPLICE_F_NONBLOCKass=" 0);1do_smhref="fs/s7ice.c#L1077" id2iL1075" cl2,/struct/7a hre78>);1s="lp8  a>1125ss="sssssssssbreak))17lags 78>;1filde=pipe_t7.ice.c#L107="fs2iode=ret" 2" class="7ref">78ef="fs/s3lice.33splic 26s       oa href=  gnal_9endingfile  a>/*curr" ndo_smhref="fs/s7a3.1pi2e_to_send7age  79de=pipe"2class22splicccccccccs="lp8  a>1108979am 1035sref"ssssssssbreak))1EXPOR2_SYMBOL  7>(oa 79a>;1filde=pipe_t7to file.o/7pa3.2">generic_2plice_sen7page 79>)1do_sp href="fs/splicu a>  a> >02  a>11073  2s/splice.7#L10979ref">f_o3  a>-31t;oa oa+href="+code=m file  a>/* href="fs/splicu a>  a> > sref">out  a>, a>,/oa hre7tce.c#L1077ize_2ine" nam <2L1094">1074o/a>79+code=ge3eric_34"sref0);1do_sp href="fs/splicu a>  a> >02  a>1filde=pipe_t7tsendpage"76" i2< oa hr2f="+code=7en" c798am s="lm file  a>/* href="fs/splicu a>  a> > sref">out  a>, a>,/oa hre7a3.17lags 798">1018 2a>  ">pipe  a>,/&+code=095">1095o/a>osp">ret  a> < 0))1,/oa hre8de=out" cl8ss="3pipe_inode3info" cla8s="sr80de=pif34ss="sref">filde=pipe_t8d1=out" cl8ss="2s="line" n2m 108980=loff_t"2class26f="+code=PAGE8d2=out" cl8s id2ref">EXPOR2_SYMBOL  8ss="l80a>;1 * @outclass="line" nam 8="+code=ou8" cl3L3101" id<3Llice_sen8page 80s="line"2nam <28="line" nam < Sline" cont" ns  p i  a>ato+o  a>.a tion pipket  s1 oa h8ef="3" class="l3ne" nam <8L110480id/*oa+href="+code="line"L  a>0);1 href="fs/splicu a>"line"L  a>0);1 hre1105"s324lice.c#L1062.c#L1096" id1096  a>static long/oa hri href="fs/splicu a>i  a> >,but...  splice from/pipe8t6 a> oa h8e" i21096  a>static long/oa hro href="fs/splicu a>o  a> >,but...  splice from/pipe8t7 a> oa h8e" i2<125ss="sssssssssL1256">s="la1" iddo_spl7">1097  a>    pipe" cla, >loff_t  a>/*oa+href="+code=>,/oa href="+code=out" class="but...  splice from/pipe8t8 a> oa h8es="2  a> oa hr2f="+code=8en" c80>;1do_smhref="fs/s8t9 a> oa h8es="2 ode=ret" 2s="sref">8lags 808">1018 2a>  s324lice.c#L1062.c#L109from" cfa href="+cod__use9from" cfa   a>static long/oa hri" cf="fs/splicu a>i" c cla, tatic long/oa hro" cf="fs/splicu a>o" c cla < 0))1,/oa hre8ce.c#L11118 id<3ss="sref">3ut  a>, o8 href81de=pipe"2clasa>/*oa+href="+code=095">1095o/a>osp">ret  a>e"  ;plice.c#L110,/oa hre8c1=out" cl8clas3 if (oa hr3f="+code=8nlike81>);1do_spinputLwakeup>1097  a>    piinputLwakeup  a>e" oa+href="+code=>al" class="sre"leas>al" ="sr < 0))1,/oa hre8c2=out" cl8" cl3L1111" cla3s="line" 8am ret81>)11095o/a>osp">ret  a>e" atic long/oa hri hre0prep>1097  a>    pii  a>0prep1105"atic long/oa hri href="fs/splicu a>i  a> >, s="l>,/oa href="+code=out" class="sref">out  a>, a>,/oa hre8a6 a> oa h8+cod3">splice_w3ite  a>;18a hre81>);11095o/a>osp">ret  a>"but...  splice from/pipe8a7+code=ou82  a37e  write 3a>)1125ss="s">pipe  a>,/&+code=095">1095o/a>osp">ret  a> < 0))1,/oa hre8a8+code=ou8ss="3slass="lin3ef="+code8inode81ss="sref3     30="sref">ppos 8a9 a> oa h8pa3.3sNVAL" cla3"line" na8 1018 2a>  e"+code=splice_095">1095o/a>osp">ret  a>e" atic long/oa hro  a>0prep>1097  a>    pio  a>0prep1105"atic long/oa hro href="fs/splicu a>o  a> >, s="l>,/oa href="+code=out" class="sref">out  a>, a>,/oa hre8a> +=/oa h8ef="3om_pipe_en3  a>(oa h8ef="+82">pipe_i3ode_ode=spli a>/*oa 5" 095">1095o/a>osp">ret  a>"but...  splice from/pipe8a1=out" cl8ef="3oif (oa hr3lass="sre8">sd 82am 1035sref"aaaaaaa a>,/&+code=095">1095o/a>osp">ret  a> < 0))1,/oa hre8a> +=/oa h8ef="3o1111" cla3="+code=p8pe_un82nam <)1;1 * @outclass="line" nam 8/"+code=ou8 id<3     if (o3 href="+c8de=sd82 id * @outclass="line" nam 8/  a> oa h8 id<3  class="l3 href="+c8de=sd82id processesmment"> * @outclass="line" nam 8/6 a> oa h8 id<3 >splice_w3ef">num_s8liced82"+code=f2le" c28pa3 class="cmmmmmmmm* could deadlock (on" doing tee f cl A 02  a B, @he o@her f cl B 02  a A).a tion pipket  s110278 a>  828am s="lm out  a>, a>,/oa hre8a9 a> oa h8 id<3eNVAL" cla3lass="lin8" nam82a>}1<)1err83">pipe_i3ode_do 0);1do_smhref="fs/s8c1=out" cl8ref=3ef">PAGE_C3CHE_SIZE 8a> - 83am 1035sref"ode=plice.c#L1032" io href="fs/splicu a>o  a> >02  a>1do_smhref="fs/s8lice.c#L1086" i3ss="sref">3AGE_CACHE8SHIFT83a>;1s="lsend_offfile  a>/*SIGPIPE href="+code=ouSIGPIPE cla;2splice" nam =sicurr" nout  a>, a>,/oa hre8loa href="8ef="3s="sref">o3t  a>,/*o8 href8"+code=pp3s" cl3ss="sr035sref"ode=plice.c#L1032" i095">1095o/a>osp">ret  a>"but...  splice from/pipe8="+code=ou8" cl3df_o3  a>-31t;oa         oL1256">s="lp8  a>1out  a>, a>,/oa hre8t  a> oa h8ef="3d href="+c3         8oa hr83+code=ge3eric_34"srefffffffffbreak))1splice_w31);1filde=pipe_t8=7+code=ou8" cl3doL1026" c3      *oa8href=83L1026)1;18;1,/oa hre8,/&oa 8ref=3e=i_sb" cl3ss="sref"8i_sb 84am 1035sref"a h2ef="f25tes from thcomment"> * @outclass="line" nam 8,ice.c#L108pa3.3es="sref">341" class8"line84a>;1 * @outclass="line" nam 8,oa href="8pa3.3e="sref">o3ass="sref8>ret 84s="line"2nam <28="line" nam eeeeeeeeeeeeeeee*   a>a1s empty or @he output   a>a1s full.a tion pipket  s1104284 id oa h8ef="3>EXPORT_SY3BOL  a>(o8 href8"+code=ge3eric_34"srefa26splice.c#L1032" ii href="fs/splicu a>i  a> >02  a>1do_spo href="fs/splicu a>o  a> >02  a>1do_smhref="fs/s8,-oa href=8" cl3generic_fi3e_splice_8rite 84>);1125ss="sssssssssode=spli a>/*oa 5" 095">1095o/a>osp">ret  a>"but...  splice from/pipe8,8+code=ou8href3 struct/oa3href="+co8e=spl84>;1sd 84a>}1<)1/*oa 5" f,/oa href="+code=out" class=0r a>12splice" nam =siSPLICE_F_NONBLOCK href="+code=ouSPLICE_F_NONBLOCKass=" 0);1do_smhref="fs/s8="+code=ou8" cl3L=i_sb" cl30" class=8line"8nam 1035sref"125ss="ssssssssss="lp8  a>1 +=/oa h8ef="3d="sref">o3  a>(oa h8ef="+85>)1filde=pipe_t8="+code=ou8107"3ass="sref"3len  a>, 8a hre85ref">34ss="sref">filde=pipe_t8=  a> oa h8e_w 3aEXPORT_SY33ss="sref8>EBAD85+code=ge3eric_34"srefffffffffa h2ef="f25tes from thcomment"> * @outclass="line" nam 8=-oa href=8+cod2aeneric_fi2ss="sref"8data 85"+code=f2le" c28pa3 class="ccccccccccccccccccccccccc* W  raced with ano@her ss="as/writer   d haven@pp  tmment"> * @outclass="line" nam 8=7+code=ou86" i2a         256" class8"line85plice.c#337rom31ospa3 class=cccccccccccccccccccccccc* managed to process any " class.  A zero"aaaaaamment"> * @outclass="line" nam 8=8+code=ou8" cl2ode=ret" c2ass="sref8>ret 85class="s3ef">i31ss="comment"cccccccccccccccccccccccc* value means EOF, so 095r0n10sts=".mment"> * @outclass="line" nam 8=e.c#L11118" cl2oNVAL" cla2m 105785ags  a>,2oa hr28 class="commcccccccccccccccccccccccc*be fun, but...  splice from/pipe8_sendpage"8clas2ref="+code2pipe_inod8_info86de=pipe"2class22splicccccccccs="lm file  a>/*i href="fs/splicu a>i  a> > sref">out  a>, a>,/oa hre8_"+code=ou8clas2r=i_sb" cl2>, oa hre8="+co86am 1035sref"oL1256">o"+code=splice_m file  a>/*o href="fs/splicu a>o  a> >"sref">out  a>, a>,/oa hre8_ice.c#L108" cl2  a> oa hr2f="+code=8en" c86ck" clas2="sre22splicccccccccgoto La+href="+code=095r05" class="line"095r0idout  a>, a>,/oa hre8_> +=/oa h8    2flags" cla2s="sref">8lags 86>)1filde=pipe_t8_"+code=ou867  2063  a>   2    oa hr8f="+c86ref">34ss="sref">filde=pipe_t8_  a> oa h8ef="20EXPORT_SY2lass="sre8">ret86+code=ge3eric_34"sref0);1do_spi" cf="fs/splicu a>i" c clae" atic long/oa hri href="fs/splicu a>i  a> >02  a>1i  a> >02  a>1out  a>, a>,/oa hre8_-oa href=867  20eneric_fi2lags" cla8s="sr86>);1s="ln" cf="fs/splicu a>n" c clae" "ref">file  a>/*o href="fs/splicu a>o  a> >02  a>1file  a>/*o href="fs/splicu a>o  a> >02  a>1out  a>, a>,/oa hre8_7+code=ou8clas2r         2class="li8e" na86L1026">1226  a22ss="satic long/oa hro" cf="fs/splicu a>o" c clae" atic long/oa hro  a>f="fs/splicu a>o  a> >02  a>1,/oa hre8="+code=ou8" cl20de=ret" c2      *oa8href=86ss="sref3     30="sref">ppos 8_ice.c#L108ef="2code=ret" 2lass="sre8">ret86ef="fs/s3lice.33splic 26s       oa href=l7">1097  a>    pipe" clae>= 0);1do_spi" cf="fs/splicu a>i" c cla02  a>1do_smhref="fs/s8a> +=/oa h8ef="269" id * @outclass="line" nam 8>1110  a> 8    2ode=ret" c2ass="sref8>ret 87am 1025108mmmmmmmmmmmmmmmmmmmmmmmm* Simply movosnnn wholn " clas f cl i  a>ato+o  a>mment"> * @outclass="line" nam 8>ice.c#L1086" i2o a> oa hr2m 107087a>;1)1,/oa hre8 id1073  2>ospa3 cl8ss="c87ref">f_o3  a>-31t;oa a22ss="satic long/oa hri" cf="fs/splicu a>i" c cla02  a>1O_NULL cla < 0))1,/oa hre8   a> oa h8ef="26EXPORT_SY2s="line" 8am 18" cl2oL1075" cl2ss="line"8nam <87>);1i  a> >02  a>1file  a>/*i href="fs/splicu a>i  a> >02  a>112"ref">file  a>/*i href="fs/splicu a>i  a> >02  a>1out  a>, a>,/oa hre8lsendpage"8clas2d125ss="sssssssss="sr__useroa hri href="fs/splicu a>i  a> >02  a>1;11097  a>    piinputLwakeup  a>e" oa+href="+code=truef="fs/splicu a>true cla < 0))1,/oa hre8 ice.c#L108  a>26ode=ret" 2"line" na8 do_smhref="fs/s8.c#L1078" 8d * @outclass="line" nam 8.1110  a> 8 id<21de=ret" c2080" id1025108mmmmmmmmmmmmmmmmmmmmmmmm* Get a utca 0"c>ato+tnis   a>a" clas,mment"> * @outclass="line" nam 8.ice.c#L108;11073  2s/splice.8#L10888ref">f_o3  a>-31t;oa href="+cs="li" cf="fs/splicu a>i" c cla02  a>11/*oa 5" i href="fs/splicu a>i  a> >, s="li" cf="fs/splicu a>i" c cla"sref">out  a>, a>,/oa hre8.  a> oa h8" id2iEXPORT_SY2/splice.c8L108488+code=ge3eric_34"srefmmmmmmmm*atic long/oa hro" cf="fs/splicu a>o" c clae" tatic long/oa hri" cf="fs/splicu a>i" c cla < 0))1,/oa hre8ice.c#L1078" id2iL1075" cl2,/struct/8a hre88>);1<)1125ss="sssssssss= h2ef="f25tes from thcomment"> * @outclass="line" nam 8."+code=ou8="fs2iclass="li2s="sref">8lags 88class="s3ef">i31ss="comment"cccccccccccccccccccccccc* Don@pp  t inherit thfngift t" c, we"need tomment"> * @outclass="line" nam 8.ice.c#L108="fs2iode=ret" 2" class="8ref">88ags  a>,2oa hr28 class="commcccccccccccccccccccccccc* prev0"> multipln sts=ls  p tnis  ag>.a tion pipket  s1pi2e_to_send8age  89e" nam <2L104925s="line" nammmmmmmmmcccccccccccccccc*be fun, but...  splice from/pipe8ae.c#L10748ss="2s="line" n2m 108989am 1035sref"ssssssssatic long/oa hro" cf="fs/splicu a>o" c cla02  a>11= ~>1EXPOR2_SYMBOL  8>(oa 89nam <)1generic_2plice_sen8page 89>)111097  a>    pipe" clae" oa+href="+code=l7">1097  a>    pipe" cla < 0))1,/oa hre8iid1073  2s/splice.8#L10989ref">f_o3  a>-31t;oa ssssssssatic long/oa hro href="fs/splicu a>o  a> >02  a>11084o/a>89+code=ge3eric_34"srefssssssssatic long/oa hri" cf="fs/splicu a>i" c cla02  a>1111097  a>    pipe" claef="+code=trdo_sf="fs/spl8tce.c#L10786" i2111097  a>    pipe" claef="+code=trdo_sf="fs/spl8tsendpage"86" i2<125ss="sf34ss="sref">filde=pipe_t8a"+code=ou8ss="2  a> oa hr2f="+code=8en" c89>;1111097  a>    pipe" claef="+code=trdo_sf="fs/spl8tice.c#L108ss="2 ode=ret" 2s="sref">8lags 89ef="fs/s3lice.33splic>111097  a>    pipe" claef="+code=trdo_sf="fs/spl9de=out" cl9ss="3pipe_inode3info" cla9s="sr90">pipe_i3ode_} "2unlikf_t  a>/*oa 5" "+code=kernel_wrlass="sre ef="+code=trdo_sf="fs/spl9d1=out" cl9ss="2s="line" n2m 108990=loff_t"2class26f="+code=PAGE9d2=out" cl9s id2ref">EXPOR2_SYMBOL  9ss="l90ck" clas2="srs="lm file  a>/*i href="fs/splicu a>i  a> > sref">out  a>, a>,/oa hre9="+code=ou9" cl3L3101" id<3Llice_sen9page 90a>;111m file  a>/*o href="fs/splicu a>o  a> >"sref">out  a>, a>,/oa hre9="+code=ou9" cl3L4101" id<3L/splice.9#L10990ref">34ss="sref">filde=pipe_t9t  a> oa h9ef="3" class="l3ne" nam <9L110490="+code=3et" = h2ef="f25tes from thcomment"> * @outclass="line" nam 9t6 a> oa h9e" i2, wakeup any pot" nial ss="ass.a tion pipket  s1 oa h9es="2  a> oa hr2f="+code=9en" c90>;11095o/a>osp">ret  a>e> 0"but...  splice from/pipe9t9 a> oa h9es="2 ode=ret" 2s="sref">9lags 90ef="fs/s3lice.33splicspli a>/*oa 5" wakeupL  a>0ss="ass href="+code=ouwakeupL  a>0ss="assmm05"ref">file  a>/*o href="fs/splicu a>o  a> >"sref">out  a>, a>,/oa hre9ce.c#L11119 id<3ss="sref">3ut  a>, o9 href91e" na< 0))1,/oa hre9c1=out" cl9clas3 if (oa hr3f="+code=9nlike91>);11097  a>    piinputLwakeup  a>"but...  splice from/pipe9c2=out" cl9" cl3L1111" cla3s="line" 9am ;10writers href="+code=ouwakeupL  a>0writersmm05"ref">file  a>/*i href="fs/splicu a>i  a> > sref">out  a>, a>,/oa hre9c"+code=ou9ef="3s3101" id<3lass="sre9">ret91>)1f_o3  a>aaaaaaa a>,/&+code=095">1095o/a>osp">ret  a> < 0))1,/oa hre9c  a> oa h9 id<3s class="l3de=f_op" 9lass=91+codef34ss="sref">filde=pipe_t9a6 a> oa h9+cod3">splice_w3ite  a>;19a hre91>);1<)1 * @outclass="line" nam 9a8+code=ou9ss="3slass="lin3ef="+code9inode91class="s3ef">i31ss="comment"* Link cont" ns  p i  a>ato+o  a>.a tion pipket  s1,2oa hr28 class="comm*be fun, but...  splice from/pipe9a> +=/oa h9ef="3om_pipe_en3  a>(oa h9ef="+92">pip1113  aa>/*oa+href="+code=e_ek1 href="fs/splicu a>e_ek1 hremm05"s324lice.c#L1062.c#L1096" id1096  a>static long/oa hri href="fs/splicu a>i  a> >,but...  splice from/pipe9a1=out" cl9ef="3oif (oa hr3lass="sre9">sd 92am 1035sref""""""s324lice.c#L1062.c#L1096" id1096  a>static long/oa hro href="fs/splicu a>o  a> >,but...  splice from/pipe9a> +=/oa h9ef="3o1111" cla3="+code=p9pe_un92ck" clas2="sre22spliccccccatic long/oa hra1" iddo_spl7">1097  a>    pipe" cla, >loff_t  a>/*oa+href="+code=>,/oa href="+code=out" class="but...  splice from/pipe9/oa href="9code3e=pipe" cl3ss="sref"9pipe 92a>;1<0);1do_smhref="fs/s9/"+code=ou9 id<3     if (o3 href="+c9de=sd92ref">f_o3  a>s324lice.c#L1062.c#L109from" cfa href="+cod__use9from" cfa   a>static long/oa hri" cf="fs/splicu a>i" c cla, tatic long/oa hro" cf="fs/splicu a>o" c cla < 0))1,/oa hre9/  a> oa h9 id<3  class="l3 href="+c9de=sd92="+code=3et"  >/*oa+href="+code=095">1095o/a>osp">ret  a>e"  ;plice.c#L110i  a>e"  ;plice.c#L110,/oa hre9/6 a> oa h9 id<3 >splice_w3ef">num_s9liced92>);1<)1oc#337rom31ospa3 classcomment"> * @outclass="line" nam 9/8+code=ou9href3+lass="lin3027">10279 a>  92class="s3ef">i31ss="comment"cccccccc* Pot" nial ABBA deadlock, work around it by ordering lockmment"> * @outclass="line" nam 9a9 a> oa h9 id<3eNVAL" cla3lass="lin9" nam92ags  a>,2oa hr28 class="commcccccccc* grabbing by   a>a1096 address. O@herwisesnwo dicfa 0"> processesmment"> * @outclass="line" nam 9ce.c#L11119 id<3code=err" 3lass="sre9">err93e" nam <2L104925s="line" nammmmmmmmm* could deadlock (on" doing tee f cl A 02  a B, @he o@her f cl B 02  a A).a tion pipket  s1PAGE_C3CHE_SIZE 9a> - 93am 1025108mmmmmmmm*be fun, but...  splice from/pipe9lice.c#L1096" i3ss="sref">3AGE_CACHE9SHIFT93ck" clas2="srs="lm out  a>, a>,/oa hre9loa href="9ef="3s="sref">o3t  a>,/*o9 href93>)1f_o3  a>do 0);1do_smhref="fs/s9t  a> oa h9ef="3d href="+c3         9oa hr93+code=ge3eric_34"srefode=plice.c#L1032" io href="fs/splicu a>o  a> >02  a>1do_smhref="fs/s9t-oa href=9ef="3s>splice_w31);1file  a>/*SIGPIPE href="+code=ouSIGPIPE cla;2splice" nam =sicurr" nout  a>, a>,/oa hre9=7+code=ou9" cl3doL1026" c3      *oa9href=93nam 125ss="sssssssssode=plice.c#L1032" i095">1095o/a>osp">ret  a>"but...  splice from/pipe9l8+code=ou9href3a>(oa href3"+code=ma9ping"93>;11out  a>, a>,/oa hre9le.c#L11119ef="3sNVAL" cla3pages  a>9;1filde=pipe_t9,/&oa 9ref=3e=i_sb" cl3ss="sref"9i_sb 94=loff_t"2class26f="+code=PAGE9,ice.c#L109pa3.3es="sref">341" class9"line94a>;1 * @outclass="line" nam 9,oa href="9pa3.3e="sref">o3ass="sref9>ret 94s="line"2nam <28="line" nam eeeeeeeeeeeeeeee* Ifawe"have iteratt  alln10p c " class or r2naout ofmment"> * @outclass="line" nam 9,"+code=ou9107"3e104294 idEXPORT_SY3BOL  a>(o9 href94id);1do_spi href="fs/splicu a>i  a> >02  a>1do_spo href="fs/splicu a>o  a> >02  a>1" classass="but...  splice from/pipe9,7+code=ou9clas3g         3ef="+code9pipe_94nam 125ss="sssssssssbreak))1ppos 9=e.c#L111196" i3eNVAL" cla3lass="sre9">sd 94ef="fs/s3lice.33splicatic long/oa hri" cf="fs/splicu a>i" c clae" atic long/oa hri href="fs/splicu a>i  a> >02  a>1file  a>/*i href="fs/splicu a>i  a> >02  a>112"ref">file  a>/*i href="fs/splicu a>i  a> >02  a>1out  a>, a>,/oa hre9to file.o/9pa3.3L1049" id<3L1049" cl9ss="l95de=pipe"2class22spliclice.c#L110file  a>/*o href="fs/splicu a>o  a> >02  a>1file  a>/*o href="fs/splicu a>o  a> >02  a>1out  a>, a>,/oa hre9="+code=ou9" cl3L=i_sb" cl30" class=9line"95=loff_t"2class26f="+code=PAGE9=ice.c#L1096" i3de=data" c3ass="sref9>data95ck" clas2="sre22splicoc#337rom31ospa3 classcomment"> * @outclass="line" nam 9=> +=/oa h9ef="3d="sref">o3  a>(oa h9ef="+95s="line"2nam <28="line" nam eeeeeeeeeeeeeeee* Get a utca 0"c>ato+tnis   a>a" clas,mment"> * @outclass="line" nam 9="+code=ou9107"3ass="sref"3len  a>, 9a hre95 idEBAD95id);1s="li" cf="fs/splicu a>i" c cla02  a>11/*oa 5" i href="fs/splicu a>i  a> >, s="li" cf="fs/splicu a>i" c cla"sref">out  a>, a>,/oa hre9=7+code=ou96" i2a         256" class9"line95L1026)1s="lo" cf="fs/splicu a>o" c clae" atic long/oa hro  a>f="fs/splicu a>o  a> >02  a>1,/oa hre9=e.c#L11119" cl2oNVAL" cla2m 105795ef="fs/s3lice.33splic*atic long/oa hro" cf="fs/splicu a>o" c clae" tatic long/oa hri" cf="fs/splicu a>i" c cla < 0))1,/oa hre9_sendpage"9clas2ref="+code2pipe_inod9_info96e" na< 0))1,/oa hre9_"+code=ou9clas2r=i_sb" cl2>, oa hre9="+co96am 1035sref"oc#337rom31ospa3 classcomment"> * @outclass="line" nam 9_ice.c#L109" cl2  a> oa hr2f="+code=9en" c96a>;1 * @outclass="line" nam 9_> +=/oa h9    2flags" cla2s="sref">9lags 96s="line"2nam <28="line" nam mmmmmmmmeeeeeeee* prev0"> multipln sts=ls  p tnis  ag>.a tion pipket  s1   2    oa hr9f="+c96 id oa h9ef="20EXPORT_SY2lass="sre9">ret96+code=ge3eric_34"sref0);1do_spo" cf="fs/splicu a>o" c cla02  a>11= ~>11226  a22ss="s 26slice.c#L11011097  a>    pipe" clae2  a >11097  a>    pipe" cla"but...  splice from/pipe9="+code=ou9" cl20de=ret" c2      *oa9href=96>;111097  a>    pipe" clae" oa+href="+code=l7">1097  a>    pipe" cla < 0))1,/oa hre9_ice.c#L109ef="2code=ret" 2lass="sre9">ret96a>}1<)11110  a> 9    2ode=ret" c2ass="sref9>ret 97am 1035sref"otic long/oa hrp8  a>111097  a>    pipe" claef="+code=trdo_sf="fs/spl9>ice.c#L1096" i2o a> oa hr2m 107097a>;111097  a>    pipe" claef="+code=trdo_sf="fs/spl9l1110  a> 9" cl2olags" cla2/splice.c9L107297>)1"+code=ou9 cla273">1073  2>ospa3 cl9ss="c97ref">f_o3  a>} "2unlikf_t  a>/*oa 5" "+code=kernel_wrlass="sre ef="+code=trdo_sf="fs/spl9   a> oa h9ef="26EXPORT_SY2s="line" 9am );1 * @outclass="line" nam 9lsendpage"9clas2daaaaaaa2AGAINs 26we"have thfnpot" nial  p somn dataain @hemment"> * @outclass="line" nam 9l"+code=ou9href2 class="li2e" nam i31ss="comment"cccccccc* fuaaae, o@herwisesjust>aaaaaaa0mment"> * @outclass="line" nam 9lice.c#L109  a>26ode=ret" 2"line" na9 ,2oa hr28 class="commcccccccc*be fun, but...  splice from/pipe9.c#L1078" 9dpipe_i3ode_ode=plice.c#L1032" i095">1095o/a>osp">ret  a>e& a>1r a>12ref">file  a>/*i href="fs/splicu a>i  a> >02  a>112splice" nam =siSPLICE_F_NONBLOCK href="+code=ouSPLICE_F_NONBLOCKass=""but...  splice from/pipe9.1110  a> 9 id<21de=ret" c2080" id1035sref"otic long/oa hrp8  a>1;111m file  a>/*i href="fs/splicu a>i  a> > sref">out  a>, a>,/oa hre9cid1073  2s/splice.9#L10898ref">f_o3  a>nam 11m file  a>/*o href="fs/splicu a>o  a> >"sref">out  a>, a>,/oa hre9.  a> oa h9" id2iEXPORT_SY2/splice.c9L108498+codef="+code=trdo_sf="fs/spl9ice.c#L1079" id2iL1075" cl2,/struct/9a hre98>);1 * @outclass="line" nam 9.sendpage"9="fs2iIfawe"put dataain @he output   a>, wakeup any pot" nial ss="ass.a tion pipket  s19lags 98class="s3ef">i31ss="comment"cccccccc*be fun, but...  splice from/pipe9.ice.c#L109="fs2iode=ret" 2" class="9ref">989>pipe_i3ode_ode=lice.c#L1032" i095">1095o/a>osp">ret  a>e> 0"but...  splice from/pipe9a3.1pi2e_to_send9age  99de=pipe"2class22splic>10ss="ass href="+code=ouwakeupL  a>0ss="assmm05"ref">file  a>/*o href="fs/splicu a>o  a> >"sref">out  a>, a>,/oa hre9ae.c#L10749ss="2s="line" n2m 108999=loff_t"2class26f="+code=PAGE9ice.c#L1079" id2ref">EXPOR2_SYMBOL  9>(oa 99a>;11095o/a>osp">ret  a> < 0))1,/oa hre9to file.o/9pa3.2">generic_2plice_sen9page 99>)1filde=pipe_t9iid1073  2s/splice.9#L10999ref">34ss="sref">filde=pipe_t9tce.c#L1079ize_2ine" nam <2L1094">1094o/a>99id * @outclass="line" nam 9tce.c#L10796" i2 * @outclass="line" nam 9tsendpage"96" i2<s @he @pp  in@pp    ag>s on @he @pp  out@pp     a>.a tion pipket  s1 oa hr2f="+code=9en" c99class="s3ef">i31ss="comment"* The @pp  t" cl@pp   used are thfnSPLICE_F_* variants, curr" nlysnnn onlymment"> * @outclass="line" nam 9tice.c#L109ss="2 ode=ret" 2s="sref">9lags 99ags  a>,2oa hr28 class="comm* aplineabln on>a1s SPLICE_F_NONBLOCK.a tion pipket  s120degs  a>,2oa hr28 class="comm*be fun, bu/pre>ipket  s120d=loff1113  alonga a>,/&+code=do_tee">1095o/a>osp">do_teemm05"s324lice.c#L1062.c#L10funl href="+code=outunl>;1out >, s="la1" iddo_spl7">1097  a>    pipe" cla,pipket  s1EXPOR2_SYMBOL 20d i>20dck" clas2="sre22splicccc>loff_t  a>/*oa+href="+code=>,/oa href="+code=out" class="but...  splice from/pip20d3=out" c20da3.2">generic_2plice_se20da3>20da>;1<0);1do_smhref="fs/20d4=out" c20da3.2"3">1073  2s/splice20da3>20dref">f_o3  a>s324lice.c#L1062.c#L109fromd1096  a>static long/oa hri href="fs/splicu a>i  a> >e" oa+href="+code=get_m file  a>/*icode=kernel_wrlai" cla"sref">out  a>, a>,/oa hr20d5=out" c20dze_2ine" nam <2L1094">120dze>20d5ef">f_o3  a>s324lice.c#L1062.c#L109fromd1096  a>static long/oa hro href="fs/splicu a>o  a> >e" oa+href="+code=get_m file  a>/*outf="fs/splicu a>out >"sref">out  a>, a>,/oa hr20d6=out" c20d" i220d>);11095o/a>osp">ret  a>e" do_sice_write" S2INVALclass="sref">O_2INVAL  a> < 0))1,/oa hr20d7=out" c20d" i2<20dL1026)120d8am <082" cla28a3 class="ccomment"> * @outclass="line" nam20d9=out" c20ds="2 ode=ret" 2s="sref"20ds=>20dags  a>,2oa hr28 class="commcccccccc* Dulineatesnnn cont" ns  p i  a>ato+o  a> without actuallymment"> * @outclass="line" nam201e=out" c20 id<3ss="sref">3ut  a>, 20 id>20 igs  a>,2oa hr28 class="commcccccccc* copying thn data.a tion pipket  s11025108mmmmmmmm*be fun, but...  splice from/pip20 2=out" c20" cl3L1111" cla3s="line"20" c>20 ck" clas2="sr 26slice.c#L110file  a>/*o href="fs/splicu a>o  a> >e& a>1r a>12ref">file  a>/*i href="fs/splicu a>i  a> > !" atic long/oa hro  a>f="fs/splicu a>o  a> >" 0);1do_smhref="fs/20 3=out" c20ef="3s3101" id<3lass="sr20ef=>20 >)1 * @outclass="line" nam2014=out" c20ef="3s4101" id<3de=f_op"20ef=>20  idlless we 0"counter    error. The i  a>/o  a>mment"> * @outclass="line" nam20 5=out" c20 id<3s class="l3de=f_op"20 id>20 idsplice_w3ite  a>;20+co>20 "+code=f2le" c28pa3 class="ccccccccccccccccc*be fun, but...  splice from/pip20 7=out" c202  a37e  write 3a>)120 L1026">1226  a22ss="satic long/oa hr095">1095o/a>osp">ret  a>e" ref">file  a>/*i hre_prep>1097  a>    pii hre_prep1105"spli a>/*oa 5" i href="fs/splicu a>i  a> >, s="l>,/oa href="+code=out" class=" < 0))1,/oa hr2018=out" c20ss="3slass="lin3ef="+cod20ss=>20 >;11095o/a>osp">ret  a>" 0);1do_smhref="fs/20 9=out" c20pa3.3sNVAL" cla3"line" n20pa3>20 ef="fs/s3lice.33splicccccccccatic long/oa hr095">1095o/a>osp">ret  a>e" ref">file  a>/*o hre_prep>1097  a>    pio hre_prep1105"spli a>/*oa 5" o href="fs/splicu a>o  a> >, s="l>,/oa href="+code=out" class=" < 0))1,/oa hr202e=out" c20ef="3om_pipe_en3  a>(oa 20ef=>20eff="fs/s3lice.33splicccccccccode=plice.c#L1032" i095">1095o/a>osp">ret  a>"but...  splice from/pip20e1=out" c20ef="3oif (oa hr3lass="sr20ef=>20eam 1035sref"125ss="ssssssssss="lp8  a>1do_spl_ek1 href="fs/splicu a>e_ek1 hremm05"spli a>/*oa 5" i href="fs/splicu a>i  a> >, s="lo href="fs/splicu a>o  a> >, s="ll7">1097  a>    pipe" cla, s="l>,/oa href="+code=out" class=" < 0))1,/oa hr2022=out" c20ef="3o1111" cla3="+code=20ef=>20eck" clas2="sre22splicf34ss="sref">filde=pipe_20e3=out" c20code3e=pipe" cl3ss="sref20cod>20e>)1filde=pipe_20e4=out" c20 id<3     if (o3 href="+20 id>20eref">34ss="sref">filde=pipe_20e5=out" c20 id<3  class="l3 href="+20 id>20e5ef">f_o3  a>aaaaaaa a>,/&+code=095">1095o/a>osp">ret  a> < 0))1,/oa hr20e6=out" c20 id<3 >splice_w3ef">num_20 id>20e6)1filde=pipe_20e7=out" c20" cl320eL1026)110220hre>20eclass=plice" nam =siSYSCALL_DEFINE4">1095o/a>osp">SYSCALL_DEFINE4mm05"spli a>/*oa 5" tee">1095o/a>osp">teemm05," >/, s="l>dicode=kernel_wrla>dicmm05," >/, s="l>doutf="fs/splicu a>>dout >, s="la1" ids="ll7">1097  a>    pipe" cla, >loff_t  a>/, s="l>,/oa href="+code=out" class=")1do_smhref="fs/203e=out" c20 id<3code=err" 3lass="sr20 id>20 ief">f_o3  a>s324lice.c#L1062.c#L10funl href="+code=outunl>;1,/oa hr2031=out" c20ref=3ef">PAGE_C3CHE_SIZE20ref>20 >);1s="l>putLicode=kernel_wrla>putLic cla < 0))1,/oa hr2032=out" c206" i3ss="sref">3AGE_CACH206" >20 nam <)1o3t  a>,/*20ef=>20 >)1llikel0mm05"plice.c#L1032" i"+code=kernel_wrlass="sre ")120 ref">f_o3  a>-31t;oa aaaaaaa0 < 0))1,/oa hr2035=out" c20ef="3d href="+c3        20ef=>20 +codef="+code=trdo_sf="fs/sp20 6=out" c20ef="3s>splice_w3120 >);1O_2BADF cla < 0))1,/oa hr2037=out" c20" cl3doL1026" c3      *o20" c>20 7);1do_spfget_lightf="fs/splicu a>>get_lightmm05"spli a>/*oa 5" >dicode=kernel_wrla>dicmm05,"r a>1s="l>putLicode=kernel_wrla>putLic cla" < 0))1,/oa hr2038=out" c20href3a>(oa href3"+code=m20hre>20 >;1do_smhref="fs/2039=out" c20ef="3sNVAL" cla3pages  a20ef=>20 ef="fs/s3lice.33splic 26s       oa href=icode=kernel_wrlai" cla02  a>1_mne" >e& a>1 0);1do_spFMODE_READode=kernel_wrlaFMODE_READ cla" 0);1do_smhref="fs/204e=out" c20" cl3d_write  a3(oa href20" c>20" f="fs/s3lice.33spliccccccccco>/*oa+href="+code=>putLoutf="fs/splicu a>>putLout cla < 0))1,/oa hr2041=out" c20ref=3e=i_sb" cl3ss="sref20ref>20"am 1035sref"125ss="ss324lice.c#L1062.c#L10funl href="+code=outunl>;1do_spfget_lightf="fs/splicu a>>get_lightmm05"spli a>/*oa 5" >doutf="fs/splicu a>>dout >, r a>1s="l>putLoutf="fs/splicu a>>putLout cla" < 0))1,/oa hr2042=out" c20pa3.3es="sref">341" clas20pa3>20"nam <)1o3ass="sre20pa3>20">)1do_smhref="fs/2044=out" c20107"3e20"ref">f_o3  a>-31t;oa ssssssssssssssss 26slice.c#L110out >02  a>1_mne" >e& a>1 0);1do_spFMODE_WRITEode=kernel_wrlaFMODE_WRITEass=")1,/&+code=do_tee">1095o/a>osp">do_teemm05"atic long/oa hricode=kernel_wrlai" cla, atic long/oa hroutf="fs/splicu a>out >, s="ll7">1097  a>    pipe" cla, s="l>,/oa href="+code=out" class=" < 0))1,/oa hr2046=out" c20" cl3generic_fi3e_splice20" c>20">);1>putLlightmm05"ref">file  a>/*outf="fs/splicu a>out >, s="l>putLoutf="fs/splicu a>>putLout cla" < 0))1,/oa hr2047=out" c20clas3g         3ef="+cod20cla>20"nam 125ss="sssssssssf34ss="sref">filde=pipe_2048=out" c20href3 struct/oa3href="+c20hre>20">;1filde=pipe_2049=out" c206" i3eNVAL" cla3lass="sr206" >20"ef="fs/s3lice.33splicatic long/oa hr>putLlightf="fs/splicu a>>putLlightmm05"ref">file  a>/*icode=kernel_wrlai" cla, atic long/oa hr>putLicode=kernel_wrla>putLic cla" < 0))1,/oa hr205e=out" c20pa3.3L1049" id<3L1049" c20pa3>20pa)1filde=pipe_2051=out" c20" cl3L=i_sb" cl30" class20" c>20p=loff_t"2class26f="+code=PAG20p2=out" c206" i3de=data" c3ass="sre206" >20pa>;1o3  a>(oa 20ef=>20p>)1filde=pipe_20p4=out" c20107"3ass="sref"3len  a>,20107>20p id
    The original LXR software bysnnn 4ss="srefhttp://sourceforge.net/projects/lxr">LXR 3 clunity cla, tnis experilassal version bys4ss="srefmailto:lxr@refux.nopipxr@refux.no cla. pxr.refux.no kindly hostt bys4ss="srefhttp://www.redpill-refpro.nopiRedpill Linpro AS cla, provider p Lefux consulting and operations servic>s si"c>a>99i.