From: Herbert Poetzl <herbert@13thfloor.at>
To: "Jörn Engel" <joern@wohnheim.fh-wedel.de>
Cc: Andrew Morton <akpm@osdl.org>,
Jan Blunck <j.blunck@tu-harburg.de>,
torvalds@osdl.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH] generic_file_sendpage
Date: Thu, 21 Jul 2005 07:34:30 +0200 [thread overview]
Message-ID: <20050721053430.GA859@MAIL.13thfloor.at> (raw)
In-Reply-To: <20050715112255.GC2721@wohnheim.fh-wedel.de>
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 BUG.
>
> Is there a sane use for O_DIRECT in combination with sendfile()?
>
> If not, I'd like to change sys_sendfile() and return -EINVAL for
> O_DIRECT file descriptors.
>
> > > + if (unlikely(signal_pending(current)))
> > > + return -EINTR;
> >
> > This doesn't help. The reason we've avoided file-to-file sendfile() is
> > that it can cause applications to get uninterruptibly stuck in the kernel
> > for ages. This code doesn't solve that problem. It needs to handle
> > signal_pending() inside the main loop.
> >
> > And it probably needs to return a sane value (number of bytes copied)
> > rather than -EINTR.
>
> Makes sense.
>
> > 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.
you might soon add linux-vserver to the list, as
we will be using this for a special version of the
COW links (to break unified links on write) ...
best,
Herbert
> Jörn
>
> --
> All art is but imitation of nature.
> -- Lucius Annaeus Seneca
> -
> To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
> the body of a message to majordomo@vger.kernel.org
> More majordomo info at http://vger.kernel.org/majordomo-info.html
> Please read the FAQ at http://www.tux.org/lkml/
next prev parent reply other threads:[~2005-07-21 5:37 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2005-07-15 10:48 [PATCH] generic_file_sendpage Jan Blunck
2005-07-15 11:06 ` Andrew Morton
2005-07-15 11:22 ` Jörn Engel
2005-07-15 13:13 ` Jan Engelhardt
2005-07-15 16:08 ` Linus Torvalds
2005-07-15 19:02 ` Jan Engelhardt
2005-07-15 19:16 ` Linus Torvalds
2005-07-21 5:34 ` Herbert Poetzl [this message]
2005-07-15 12:34 ` [PATCH] generic_file_sendpage (updated patch) Jan Blunck
2005-07-15 16:01 ` [PATCH] generic_file_sendpage Linus Torvalds
2005-07-20 19:03 ` Jan Blunck
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20050721053430.GA859@MAIL.13thfloor.at \
--to=herbert@13thfloor.at \
--cc=akpm@osdl.org \
--cc=j.blunck@tu-harburg.de \
--cc=joern@wohnheim.fh-wedel.de \
--cc=linux-kernel@vger.kernel.org \
--cc=torvalds@osdl.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox