Re: [PATCH] splice support #2

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



* Linus Torvalds <[email protected]> wrote:

> The reason it goes through a pipe is two-fold:
> 
>  - the pipe _is_ the buffer. The reason sendfile() sucks is that sendfile 
>    cannot work with <n> different buffer representations. sendfile() only 
>    works with _one_ buffer representation, namely the "page cache of the 
>    file".

The main problem of sendfile() is that it exposes an incoming-fd 
'offset', which pretty much hardcodes the assumption that the incoming 
file is a pagecache-backed object. I believe the flush_fd solution to 
sys_splice() would solve that range of problems, and thus slice could be 
used for offset-less file objects too.

all the remaining problems of sendfile() just derive from this basic 
pagecache assumption that is hardcoded in the ABI. Once this one is 
overcome (and i believe fd_flush overcomes it), there's no reason why we 
couldnt implement the complete range of sys_splice() transfers.

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

[Index of Archives]     [Kernel Newbies]     [Netfilter]     [Bugtraq]     [Photo]     [Stuff]     [Gimp]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Video 4 Linux]     [Linux for the blind]     [Linux Resources]
  Powered by Linux