lkml.org 
[lkml]   [2012]   [Feb]   [21]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
    /
    From
    Date
    SubjectRe: compat: autofs v5 packet size ambiguity - update
    On Tue, Feb 21, 2012 at 7:33 PM, Linus Torvalds
    <torvalds@linux-foundation.org> wrote:
    >
    > But I'm sure that the autofs daemon does something simple that we can
    > depend on in practice.

    I didn't find the most recent source code, but the first thing that
    automount.c does after calling "mount" (which is a for+exec, so we
    cannot take the mounting is_compat_task() into account is to open the
    new root for the ioctlfd, and then it does a stat.

    And then it does a AUTOFS_IOC_PROTOVER ioctl to see what the protocol
    version is.

    So we could just decide that

    (a) we add a mount option for the packet size (or just "v6" - which
    would be "v5 with a fixed packet size")

    (b) in the absence of an explicit mount option, we look at
    is_compat_task() for the first AUTOFS_IOC_PROTOVER ioctl we get.

    That looks fairly straightforward and safe. Hmm?

    Where are the automount sources supposed to be, anyway? kernel.org has
    a v5 directory, but it's empty.

    Linus


    \
     
     \ /
      Last update: 2012-02-22 04:51    [W:3.884 / U:0.404 seconds]
    ©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site