09 May, 2009

3 commits


28 Mar, 2009

2 commits

  • simple_set_mnt() is defined as returning 'int' but always returns 0.
    Callers assume simple_set_mnt() never fails and don't properly cleanup if
    it were to _ever_ fail. For instance, get_sb_single() and get_sb_nodev()
    should:

    up_write(sb->s_unmount);
    deactivate_super(sb);

    if simple_set_mnt() fails.

    Since simple_set_mnt() never fails, would be cleaner if it did not
    return anything.

    [akpm@linux-foundation.org: fix build]
    Signed-off-by: Sukadev Bhattiprolu
    Acked-by: Serge Hallyn
    Cc: Al Viro
    Cc: Christoph Hellwig
    Signed-off-by: Andrew Morton
    Signed-off-by: Al Viro

    Sukadev Bhattiprolu
     
  • Signed-off-by: Al Viro

    Al Viro
     

22 Jan, 2009

1 commit


25 Dec, 2008

1 commit


20 Dec, 2008

3 commits


14 Nov, 2008

1 commit

  • Wrap access to task credentials so that they can be separated more easily from
    the task_struct during the introduction of COW creds.

    Change most current->(|e|s|fs)[ug]id to current_(|e|s|fs)[ug]id().

    Change some task->e?[ug]id to task_e?[ug]id(). In some places it makes more
    sense to use RCU directly rather than a convenient wrapper; these will be
    addressed by later patches.

    Signed-off-by: David Howells
    Reviewed-by: James Morris
    Acked-by: Serge Hallyn
    Reviewed-by: Eric Van Hensbergen
    Cc: Ron Minnich
    Cc: Latchesar Ionkov
    Cc: v9fs-developer@lists.sourceforge.net
    Signed-off-by: James Morris

    David Howells
     

23 Oct, 2008

1 commit


18 Oct, 2008

8 commits

  • In v9fs_get_inode(), for block, as well as char devices (in theory),
    the function init_special_inode() is called to set up callback functions
    for file ops. this function uses the file mode's value to determine whether
    to use block or char dev functions. In v9fs_inode_from_fid(), the function
    p9mode2unixmode() is used, but for all devices it initially returns S_IFBLK,
    then uses v9fs_get_inode() to initialise a new inode, then finally uses
    v9fs_stat2inode(), which would determine whether the inode is a block or
    character device. However, at that point init_special_inode() had already
    decided to use the block device functions, so even if the inode's mode is
    turned to a character device, the block functions are still used to operate
    on them. The attached patch simply calls init_special_inode() again for devices
    after parsing device node data in v9fs_stat2inode() so that the proper functions
    are used.

    Signed-off-by: Eric Van Hensbergen

    Magnus Deininger
     
  • Remove depricated conv functions which have been replaced with new
    protocol routines.

    This patch also reworks the one instance of the file-system code which
    directly calls conversion routines (to accomplish unpacking dirreads).

    Signed-off-by: Eric Van Hensbergen

    Eric Van Hensbergen
     
  • Now that the new protocol functions are in place, this patch switches
    the client code to using the new support code.

    Signed-off-by: Eric Van Hensbergen

    Eric Van Hensbergen
     
  • Currently reading a directory is implemented in the client code.
    This function is not actually a wire operation, but a meta operation
    which calls read operations and processes the results.

    This patch moves this functionality to the fs layer and calls component
    wire operations instead of constructing their packets. This provides a
    cleaner separation and will help when we reorganize the client functions
    and protocol processing methods.

    Signed-off-by: Eric Van Hensbergen

    Eric Van Hensbergen
     
  • Currently, the 9p net wire operation ensures that all data is sent by sending
    multiple packets if the data requested is larger than the msize. This is
    better handled in the vfs code so that we can simplify wire operations to
    being concerned with only putting data onto and taking data off of the wire.

    Signed-off-by: Eric Van Hensbergen

    Eric Van Hensbergen
     
  • There are a couple of methods in the client code which aren't actually
    wire operations. To keep things organized cleaner, these operations are
    being moved to the fs layer.

    This patch moves the readn meta-function (which executes multiple wire
    reads until a buffer is full) to the fs layer.

    Signed-off-by: Eric Van Hensbergen

    Eric Van Hensbergen
     
  • Currently there are two separate versions of read and write. One for
    dealing with user buffers and the other for dealing with kernel buffers.
    There is a tremendous amount of code duplication in the otherwise
    identical versions of these functions. This patch adds an additional
    user buffer parameter to read and write and conditionalizes handling of
    the buffer on whether the kernel buffer or the user buffer is populated.

    Signed-off-by: Eric Van Hensbergen

    Eric Van Hensbergen
     
  • Right now there is a transport module structure which provides per-transport
    type functions and data and a transport structure which contains per-instance
    public data as well as function pointers to instance specific functions.

    This patch moves public transport visible instance data to the client
    structure (which in some cases had duplicate data) and consolidates the
    functions into the transport module structure.

    Signed-off-by: Eric Van Hensbergen

    Eric Van Hensbergen
     

14 Oct, 2008

1 commit

  • This is a much better version of a previous patch to make the parser
    tables constant. Rather than changing the typedef, we put the "const" in
    all the various places where its required, allowing the __initconst
    exception for nfsroot which was the cause of the previous trouble.

    This was posted for review some time ago and I believe its been in -mm
    since then.

    Signed-off-by: Steven Whitehouse
    Cc: Alexander Viro
    Signed-off-by: Linus Torvalds

    Steven Whitehouse
     

25 Sep, 2008

1 commit

  • In case of error, the function p9_client_walk returns an ERR pointer, but
    never returns a NULL pointer. So a NULL test that comes after an IS_ERR
    test should be deleted.

    The semantic match that finds this problem is as follows:
    (http://www.emn.fr/x-info/coccinelle/)

    //
    @match_bad_null_test@
    expression x, E;
    statement S1,S2;
    @@
    x = p9_client_walk(...)
    ... when != x = E
    * if (x != NULL)
    S1 else S2
    //

    Signed-off-by: Julien Brunel
    Signed-off-by: Julia Lawall
    Signed-off-by: Eric Van Hensbergen
    Signed-off-by: Andrew Morton

    Julien Brunel
     

25 Aug, 2008

1 commit


03 Jul, 2008

1 commit

  • The legacy protocol's open operation doesn't handle an append operation
    (it is expected that the client take care of it). We were incorrectly
    passing the extended protocol's flag through even in legacy mode. This
    was reported in bugzilla report #10689. This patch fixes the problem
    by disallowing extended protocol open modes from being passed in legacy
    mode and implemented append functionality on the client side by adding
    a seek after the open.

    Signed-off-by: Eric Van Hensbergen

    Eric Van Hensbergen
     

15 May, 2008

4 commits

  • There was some cleanup issues during early mount which would trigger
    a kernel bug for certain types of failure. This patch reorganizes the
    cleanup to get rid of the bad behavior.

    This also merges the 9pnet and 9pnet_fd modules for the purpose of
    configuration and initialization. Keeping the fd transport separate
    from the core 9pnet code seemed like a good idea at the time, but in
    practice has caused more harm and confusion than good.

    Signed-off-by: Eric Van Hensbergen

    Eric Van Hensbergen
     
  • …that this function can fail, return an int, diagnose other option-parsing failures, and adjust the sole caller: (v9fs_session_init): Handle kstrdup failure. Propagate any new v9fs_parse_options failure "up".

    Signed-off-by: Jim Meyering <meyering@redhat.com>
    Cc: Ron Minnich <rminnich@sandia.gov>
    Cc: Latchesar Ionkov <lucho@ionkov.net>
    Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
    Acked-by: Eric Van Hensbergen <ericvh@gmail.com>

    Jim Meyering
     
  • The kernel-doc comments of much of the 9p system have been in disarray since
    reorganization. This patch fixes those problems, adds additional documentation
    and a template book which collects the 9p information.

    Signed-off-by: Eric Van Hensbergen

    Eric Van Hensbergen
     
  • match_strcpy() is a somewhat creepy function: the caller needs to make sure
    that the destination buffer is big enough, and when he screws up or
    forgets, match_strcpy() happily overruns the buffer.

    There's exactly one customer: v9fs_parse_options(). I believe it currently
    can't overflow its buffer, but that's not exactly obvious.

    The source string is a substing of the mount options. The kernel silently
    truncates those to PAGE_SIZE bytes, including the terminating zero. See
    compat_sys_mount() and do_mount().

    The destination buffer is obtained from __getname(), which allocates from
    name_cachep, which is initialized by vfs_caches_init() for size PATH_MAX.

    We're safe as long as PATH_MAX
    Cc: Latchesar Ionkov
    Cc: Jim Meyering
    Cc: "Randy.Dunlap"
    Signed-off-by: Andrew Morton
    Signed-off-by: Eric Van Hensbergen

    Markus Armbruster
     

25 Apr, 2008

1 commit


19 Apr, 2008

1 commit


08 Feb, 2008

1 commit


07 Feb, 2008

4 commits

  • This merges the mux.c (including the connection interface) with trans_fd
    in preparation for transport API changes. Ultimately, trans_fd will need
    to be rewritten to clean it up and simplify the implementation, but this
    reorganization is viewed as the first step.

    Signed-off-by: Eric Van Hensbergen

    Eric Van Hensbergen
     
  • v9fs was allowing writable mmap which could lead to kernel BUG() cases.
    This sets the mmap function to generic_file_readonly_mmap which (correctly)
    returns an error to applications which open mmap for writing.

    Signed-off-by: Eric Van Hensbergen

    Eric Van Hensbergen
     
  • GDM gets unhappy if /var/gdm doesn't have the sticky bit set. This patch adds
    support for the sticky bit in much the same way setuid/setgid is supported.

    With this patch, I can launch X from a v9fs rootfs (although I quickly run out
    of fds in the server once gnome starts up).

    Signed-off-by: Anthony Liguori
    Acked-by: Eric Van Hensbergen

    Anthony Liguori
     
  • When a new user attached at a directory other than the root, he would end
    up in the parent directory of the cwd. This was due to a logic error in
    the code which attaches the user at the mount point and walks back to the
    cwd. This patch fixes that.

    Signed-off-by: Eric Van Hensbergen

    Eric Van Hensbergen
     

06 Nov, 2007

2 commits


24 Oct, 2007

2 commits


18 Oct, 2007

1 commit