On Fri, Jul 15, 2005 at 01:22:55PM +0200, Jörn Engel wrote:
> On Fri, 15 July 2005 04:06:11 -0700, Andrew Morton wrote:
> > > +
> > > + /* There is no sane reason to use O_DIRECT */
> > > + BUG_ON(file->f_flags & O_DIRECT);
> >
> > err, this seems like an easy way for people to make the kernel go
Linus Torvalds wrote:
"sendfile()" in general I think has been a mistake. It's too specialized,
and the interface has always sucked.
Ok, you're right. I will have a look at the pipe buffer stuff.
As Andrew pointed out, it actually
needs to limit the number of buffers in flight partly because
On Fri, 15 Jul 2005, Jan Engelhardt wrote:
> >
> >This is why I want to get rid of sendfile(). It's a fundamentally broken
> >interface. Really. In contrast, the pipe buffers _can_ be used for direct
> >socket->file interfaces.
>
> How will userspace access these pipe buffers?
You can fill them
>> >With union mount and cowlink, there are two users already. cp(1)
>> >could use it as well, even if the improvement is quite minimal.
>>
>> FTP PUT could use this too - ...
>
>No, FTP PUT _cannot_ use it, exactly because sendfile() can't do anything
>but file sources (and not even all file so
On Fri, 15 Jul 2005, Jan Engelhardt wrote:
>
> >> I don't know if we want to add this feature, really. It's such a
> >> specialised thing.
> >
> >With union mount and cowlink, there are two users already. cp(1)
> >could use it as well, even if the improvement is quite minimal.
>
> FTP PUT coul
On Fri, 15 Jul 2005, Andrew Morton wrote:
>
> I don't know if we want to add this feature, really. It's such a
> specialised thing.
It is, in this format, and I agree - I don't want to add it.
What I'd really like to see is somebody taking a look at my old "pipe as a
zero-copy buffer" patches
>> I don't know if we want to add this feature, really. It's such a
>> specialised thing.
>
>With union mount and cowlink, there are two users already. cp(1)
>could use it as well, even if the improvement is quite minimal.
FTP PUT could use this too - currently, only FTPGETs can use sendfile bec
Andrew Morton wrote:
>
>>+static inline size_t
>>+filemap_copy_from_kernel(struct page *page, unsigned long offset,
>>+const char *buf, unsigned bytes)
>>+{
>>+ char *kaddr;
>>+
>>+ kaddr = kmap(page);
>>+ memcpy(kaddr + offset, buf, bytes);
>>+ kunm
On Fri, 15 July 2005 04:06:11 -0700, Andrew Morton wrote:
> > +
> > + /* There is no sane reason to use O_DIRECT */
> > + BUG_ON(file->f_flags & O_DIRECT);
>
> err, this seems like an easy way for people to make the kernel go BUG.
Is there a sane use for O_DIRECT in combination with sendfile(
Jan Blunck <[EMAIL PROTECTED]> wrote:
>
> This is a generic sendpage() for regular files.
>
> +static inline size_t
> +filemap_copy_from_kernel(struct page *page, unsigned long offset,
> + const char *buf, unsigned bytes)
> +{
> + char *kaddr;
> +
> + kaddr = kmap(pag
This is a generic sendpage() for regular files.
With generic_file_sendpage() it is possible to use sendfile() on file
targets, instead of only sending data to sockets.
This implementation is basically an extension of Joern's original patch
(http://marc.theaimsgroup.com/?l=linux-kernel&m=10945
11 matches
Mail list logo