From: Daniel Phillips <phillips@phunq.net>
To: Pavel Machek <pavel@ucw.cz>
Cc: linux-kernel@vger.kernel.org, dm-devel@redhat.com
Subject: Re: [RFC] An alternative interface to device mapper
Date: Sat, 8 Mar 2008 04:06:15 -0800 [thread overview]
Message-ID: <200803080406.16305.phillips@phunq.net> (raw)
In-Reply-To: <20080308113803.GB4016@ucw.cz>
Hi Pavel,
On Saturday 08 March 2008 03:38, Pavel Machek wrote:
> > Unlike a pipe, there is no waiting for input on a ddlink: if there is
> > nothing to read then the read returns immediately with zero length. If
> > some other behavior is desired it can be obtained using poll.
>
> That's kind of strange, no?
It doesn't feel strange in practice. The ddlink framework itself does
not implement this, the module does (e.g. ddsetup). So you can put a
poll wait in your read method if that suits your interface. It just
does not seem to be useful for ddsetup, which does not produce any
data of the kind that needs an application to sit in a loop waiting for
something to arrive. If there is an application like that, it would
probably want to poll the ddlink anyway, to avoid having a whole thread
dedicated to just that.
Maybe the reason it does not feel strange to omit the wait is, reading
from proc never waits. A ddlink fd is more like proc than like a pipe.
It was Trond who started called his thing a "pipefs", blame him ;-)
> Should not description of interface go to Doc* somewhere?
Yes, will fix.
Daniel
next prev parent reply other threads:[~2008-03-08 12:06 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2008-03-05 9:29 Daniel Phillips
2008-03-05 16:39 ` Jonathan Corbet
2008-03-05 19:23 ` Daniel Phillips
2008-03-08 11:38 ` Pavel Machek
2008-03-08 12:06 ` Daniel Phillips [this message]
2008-03-06 2:31 david
2008-03-06 4:49 ` Daniel Phillips
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=200803080406.16305.phillips@phunq.net \
--to=phillips@phunq.net \
--cc=dm-devel@redhat.com \
--cc=linux-kernel@vger.kernel.org \
--cc=pavel@ucw.cz \
/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
all inboxes | Powered by JetHome®