From: Ian Kent <raven@themaw.net>
To: Linus Torvalds <torvalds@linux-foundation.org>
Cc: "H. Peter Anvin" <hpa@zytor.com>,
Linux Kernel Mailing List <linux-kernel@vger.kernel.org>,
Michael Tokarev <mjt@tls.msk.ru>,
Alan Cox <alan@lxorguk.ukuu.org.uk>,
Thomas Meyer <thomas@m3y3r.de>,
autofs@vger.kernel.org
Subject: Re: autofs: make the autofsv5 packet file descriptor use a packetized pipe
Date: Mon, 30 Apr 2012 09:29:58 +0800 [thread overview]
Message-ID: <1335749398.2281.0.camel@perseus.themaw.net> (raw)
In-Reply-To: <CA+55aFzDhkVzaUYQwKbkUqoRNb223+w0-k=pOxTZHja75JOMvQ@mail.gmail.com>
On Sun, 2012-04-29 at 17:43 -0700, Linus Torvalds wrote:
> On Sun, Apr 29, 2012 at 5:35 PM, H. Peter Anvin <hpa@zytor.com> wrote:
> >
> > Which is funny/sad, because that's actually the intended way the
> > interface is meant to work.
>
> Well, the autofs packet model is actually horribly badly misdesigned
> even for that: the header doesn't contain the size of the packet. It
> contains the packet *type*, and from that you can then determine the
> size (of course, every other program would determine it *wrongly* for
> this whole x86-64 alignment reason), but that is actually a horrible
> model because it assumes you know all the packet types.
>
> (There's a "len" field in the v5 packet, but that's not the packet
> length, that's the length of the name component)
>
> And the reason nobody does that is that in practice there is only ever
> one single type of packet that is possible anyway, so there's no point
> in even reading the header to find the type.
>
> So a much nicer model is one where the actual *size* of the packet is
> in the header. That would have allowed for not having that fixed
> maximum size of a name etc, and would have avoided the whole problem
> to begin with.
>
> Of course, the nicest model of all is to just use a packetized
> interface to begin with, so that none of these issues exist. Which is
> what we're now effectively moving to, unless we can find some horrible
> program that makes that impossible due to it playing games and knowing
> it's a "stream".
>
> Looking at am-utils, I think we're ok so far. But maybe you know of
> yet another crazy user of the autofs interfaces.
autodir looks ok as well.
http://sourceforge.net/projects/intraperson/files/latest/download
>
> Linus
next prev parent reply other threads:[~2012-04-30 1:30 UTC|newest]
Thread overview: 19+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <20120429205429.63CCD7C0064@ra.kernel.org>
2012-04-30 0:15 ` H. Peter Anvin
2012-04-30 0:25 ` Linus Torvalds
2012-04-30 0:28 ` H. Peter Anvin
2012-04-30 0:33 ` Linus Torvalds
2012-04-30 0:35 ` H. Peter Anvin
2012-04-30 0:43 ` Linus Torvalds
2012-04-30 0:45 ` H. Peter Anvin
2012-04-30 1:29 ` Ian Kent [this message]
2012-04-30 1:56 ` Linus Torvalds
2012-04-30 5:57 ` Ian Kent
2012-04-30 0:30 ` H. Peter Anvin
2012-04-30 0:37 ` Linus Torvalds
2012-04-30 20:03 ` H. Peter Anvin
2012-04-30 20:11 ` Linus Torvalds
2012-04-30 20:14 ` H. Peter Anvin
2012-04-30 6:27 ` Michael Tokarev
2012-04-30 6:43 ` Michael Tokarev
2012-04-30 6:48 ` H. Peter Anvin
2012-04-30 6:55 ` Ian Kent
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=1335749398.2281.0.camel@perseus.themaw.net \
--to=raven@themaw.net \
--cc=alan@lxorguk.ukuu.org.uk \
--cc=autofs@vger.kernel.org \
--cc=hpa@zytor.com \
--cc=linux-kernel@vger.kernel.org \
--cc=mjt@tls.msk.ru \
--cc=thomas@m3y3r.de \
--cc=torvalds@linux-foundation.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
Powered by JetHome