iter_file_splice_write(9)
π iter_file_splice_write π
okay so before we get into it β this lil page lives in the Kernel API Manual, section 9, bestie. That's your vibe check for where you are rn. β¨
πΈ NAME πΈ
iter_file_splice_write β splice data from a pipe to a file, no cap π«Ά
π SYNOPSIS π
ssize_t iter_file_splice_write (struct pipe_inode_info *pipe , struct
file *out , loff_t *ppos , size_t len , unsigned int flags );
π¦ ARGUMENTS π¦
she takes five args, let's meet them π
pipeβ pipe info. that's the pipe inode we're pulling from, mhm.outβ the file to write to. the destination, the main character of this story tbh.pposβ position inout. where we're at in the file, so pls don't lose her.lenβ number of bytes to splice. yes, asize_t, yes it matters. π₯flagsβ splice modifier flags. these lil guys decide a LOT, keep reading π
β DESCRIPTION β
okay so here's the tea π β this function will either move or copy pages from the given pipe inode to the given file. which one happens? that's determined by the flags options, so like, pay attention to your flags bestie, they're literally the deciding factor π
and the lil special-sauce detail: this one is ->write_iter-based. iykyk π§
π SEE ALSO π
Kernel file ./fs/splice.c β go read her, she ate π
splice_to_pipe(9)copy_splice_read(9)splice_from_pipe_feed(9)splice_from_pipe_next(9)splice_from_pipe_begin(9)splice_from_pipe_end(9)__splice_from_pipe(9)splice_from_pipe(9)splice_to_socket(9)vfs_splice_read(9)splice_direct_to_actor(9)do_splice_direct(9)splice_file_range(9)
π real talk: the whole splice squad is listed above, so don't be out here guessing at behaviour when the answers are literally one page over, fr fr.
okay that's the whole page, mwah π β brought to you by ./fs, dated October 2026, and filed under iter_file_splice_write(9) in the Kernel API Manual. go splice something iconic β¨π«Ά
π¦ where this page comes from
- nixpkgs unstable: linux-manual 7.3.1
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms