27 Feb, 2009

1 commit


07 Feb, 2009

1 commit

  • When the changes were done to the protocol last release, some endian
    bugs crept in. This patch fixes those endian problems and has been
    verified to run on 32/64 bit and x86/ppc architectures.

    This version of the patch incorporates the correct annotations
    for endian variables.

    Signed-off-by: Eric Van Hensbergen
    Signed-off-by: David S. Miller

    Eric Van Hensbergen
     

20 Jan, 2009

1 commit


16 Jan, 2009

1 commit

  • If INET=y and INFINIBAND=y, but IPV6=m then INFINIBAND_ADDR_TRANS is set
    to n and the RDMA CM functions rdma_connect() et al are not built.
    However, the current config dependencies allow NET_9P_RDMA to be selected
    in this, which leads to a build failure. Fix this by adding a dependency
    on INFINIBAND_ADDR_TRANS to disallow NET_9P_RDMA in this case.

    Reported-by: Randy Dunlap
    Signed-off-by: Roland Dreier
    Acked-by: Randy Dunlap
    Tested-by: Randy Dunlap
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Roland Dreier
     

29 Dec, 2008

1 commit

  • * git://git.kernel.org/pub/scm/linux/kernel/git/davem/net-next-2.6: (1429 commits)
    net: Allow dependancies of FDDI & Tokenring to be modular.
    igb: Fix build warning when DCA is disabled.
    net: Fix warning fallout from recent NAPI interface changes.
    gro: Fix potential use after free
    sfc: If AN is enabled, always read speed/duplex from the AN advertising bits
    sfc: When disabling the NIC, close the device rather than unregistering it
    sfc: SFT9001: Add cable diagnostics
    sfc: Add support for multiple PHY self-tests
    sfc: Merge top-level functions for self-tests
    sfc: Clean up PHY mode management in loopback self-test
    sfc: Fix unreliable link detection in some loopback modes
    sfc: Generate unique names for per-NIC workqueues
    802.3ad: use standard ethhdr instead of ad_header
    802.3ad: generalize out mac address initializer
    802.3ad: initialize ports LACPDU from const initializer
    802.3ad: remove typedef around ad_system
    802.3ad: turn ports is_individual into a bool
    802.3ad: turn ports is_enabled into a bool
    802.3ad: make ntt bool
    ixgbe: Fix set_ringparam in ixgbe to use the same memory pools.
    ...

    Fixed trivial IPv4/6 address printing conflicts in fs/cifs/connect.c due
    to the conversion to %pI (in this networking merge) and the addition of
    doing IPv6 addresses (from the earlier merge of CIFS).

    Linus Torvalds
     

22 Nov, 2008

1 commit


18 Nov, 2008

1 commit

  • Conflicts:
    fs/cifs/misc.c

    Merge to resolve above, per the patch below.

    Signed-off-by: James Morris

    diff --cc fs/cifs/misc.c
    index ec36410,addd1dc..0000000
    --- a/fs/cifs/misc.c
    +++ b/fs/cifs/misc.c
    @@@ -347,13 -338,13 +338,13 @@@ header_assemble(struct smb_hdr *buffer
    /* BB Add support for establishing new tCon and SMB Session */
    /* with userid/password pairs found on the smb session */
    /* for other target tcp/ip addresses BB */
    - if (current->fsuid != treeCon->ses->linux_uid) {
    + if (current_fsuid() != treeCon->ses->linux_uid) {
    cFYI(1, ("Multiuser mode and UID "
    "did not match tcon uid"));
    - read_lock(&GlobalSMBSeslock);
    - list_for_each(temp_item, &GlobalSMBSessionList) {
    - ses = list_entry(temp_item, struct cifsSesInfo, cifsSessionList);
    + read_lock(&cifs_tcp_ses_lock);
    + list_for_each(temp_item, &treeCon->ses->server->smb_ses_list) {
    + ses = list_entry(temp_item, struct cifsSesInfo, smb_ses_list);
    - if (ses->linux_uid == current->fsuid) {
    + if (ses->linux_uid == current_fsuid()) {
    if (ses->server == treeCon->ses->server) {
    cFYI(1, ("found matching uid substitute right smb_uid"));
    buffer->Uid = ses->Suid;

    James Morris
     

15 Nov, 2008

1 commit

  • linux-next:

    Make 9p's RDMA option depend on INET since it uses Infiniband rdma_*
    functions and that code depends on INET. Otherwise 9p can try to
    use symbols which don't exist.

    ERROR: "rdma_destroy_id" [net/9p/9pnet_rdma.ko] undefined!
    ERROR: "rdma_connect" [net/9p/9pnet_rdma.ko] undefined!
    ERROR: "rdma_create_id" [net/9p/9pnet_rdma.ko] undefined!
    ERROR: "rdma_create_qp" [net/9p/9pnet_rdma.ko] undefined!
    ERROR: "rdma_resolve_route" [net/9p/9pnet_rdma.ko] undefined!
    ERROR: "rdma_disconnect" [net/9p/9pnet_rdma.ko] undefined!
    ERROR: "rdma_resolve_addr" [net/9p/9pnet_rdma.ko] undefined!

    I used an if/endif block so that the menu items would remain
    presented together.

    Also correct an article adjective.

    Signed-off-by: Randy Dunlap
    Signed-off-by: Eric Van Hensbergen

    Randy Dunlap
     

14 Nov, 2008

2 commits

  • Conflicts:
    security/keys/internal.h
    security/keys/process_keys.c
    security/keys/request_key.c

    Fixed conflicts above by using the non 'tsk' versions.

    Signed-off-by: James Morris

    James Morris
     
  • 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
     

06 Nov, 2008

7 commits

  • Fix printk format warnings in net/9p.
    Built cleanly on 7 arches.

    net/9p/client.c:820: warning: format '%llx' expects type 'long long unsigned int', but argument 4 has type 'u64'
    net/9p/client.c:820: warning: format '%llx' expects type 'long long unsigned int', but argument 5 has type 'u64'
    net/9p/client.c:867: warning: format '%llx' expects type 'long long unsigned int', but argument 4 has type 'u64'
    net/9p/client.c:867: warning: format '%llx' expects type 'long long unsigned int', but argument 5 has type 'u64'
    net/9p/client.c:932: warning: format '%llx' expects type 'long long unsigned int', but argument 5 has type 'u64'
    net/9p/client.c:932: warning: format '%llx' expects type 'long long unsigned int', but argument 6 has type 'u64'
    net/9p/client.c:982: warning: format '%llx' expects type 'long long unsigned int', but argument 4 has type 'u64'
    net/9p/client.c:982: warning: format '%llx' expects type 'long long unsigned int', but argument 5 has type 'u64'
    net/9p/client.c:1025: warning: format '%llx' expects type 'long long unsigned int', but argument 4 has type 'u64'
    net/9p/client.c:1025: warning: format '%llx' expects type 'long long unsigned int', but argument 5 has type 'u64'
    net/9p/client.c:1227: warning: format '%llx' expects type 'long long unsigned int', but argument 7 has type 'u64'
    net/9p/client.c:1227: warning: format '%llx' expects type 'long long unsigned int', but argument 12 has type 'u64'
    net/9p/client.c:1227: warning: format '%llx' expects type 'long long unsigned int', but argument 8 has type 'u64'
    net/9p/client.c:1227: warning: format '%llx' expects type 'long long unsigned int', but argument 13 has type 'u64'
    net/9p/client.c:1252: warning: format '%llx' expects type 'long long unsigned int', but argument 7 has type 'u64'
    net/9p/client.c:1252: warning: format '%llx' expects type 'long long unsigned int', but argument 12 has type 'u64'
    net/9p/client.c:1252: warning: format '%llx' expects type 'long long unsigned int', but argument 8 has type 'u64'
    net/9p/client.c:1252: warning: format '%llx' expects type 'long long unsigned int', but argument 13 has type 'u64'

    Signed-off-by: Randy Dunlap
    Signed-off-by: Eric Van Hensbergen

    Randy Dunlap
     
  • Signed-off-by: Roel Kluin
    Signed-off-by: Eric Van Hensbergen

    Roel Kluin
     
  • Removed duplicated #include in
    net/9p/trans_rdma.c.

    Signed-off-by: Huang Weiyi
    Signed-off-by: Eric Van Hensbergen

    Huang Weiyi
     
  • If a T or R fcall cannot be allocated, the function returns an error
    but neglects to free the wait queue that was successfully allocated.

    If it comes through again a second time this wq will be overwritten
    with a new allocation and the old allocation will be leaked.

    Also, if the client is subsequently closed, the close path will
    attempt to clean up these allocations, so set the req fields to
    NULL to avoid duplicate free.

    Signed-off-by: Tom Tucker
    Signed-off-by: Eric Van Hensbergen

    Tom Tucker
     
  • T and R fcall are reused until the client is destroyed. There does
    not need to be a special case for Flush

    Signed-off-by: Tom Tucker
    Signed-off-by: Eric Van Hensbergen

    Tom Tucker
     
  • The client lock must be IRQ safe. Some of the lock acquisition paths
    took regular spin locks.

    Signed-off-by: Tom Tucker
    Signed-off-by: Eric Van Hensbergen

    Tom Tucker
     
  • The RDMA connection manager is fundamentally asynchronous.
    Since the async callback context is the client pointer, the
    transport in the client struct needs to be set prior to calling
    the first async op.

    Signed-off-by: Tom Tucker
    Signed-off-by: Eric Van Hensbergen

    Tom Tucker
     

23 Oct, 2008

3 commits


18 Oct, 2008

20 commits

  • During the reorganization some of the multi-theaded locking assumptions were
    accidently relaxed. This patch moves us back towards a more conservative
    locking strategy.

    Signed-off-by: Eric Van Hensbergen

    Eric Van Hensbergen
     
  • When we get an error on parsing a stat due to a protocol bug,
    we can generate an oops during cleanup because we didn't
    initialize the string pointers in the stat structure.

    Signed-off-by: Eric Van Hensbergen

    Eric Van Hensbergen
     
  • The new debug support lacks some of the information that the previous fcprint
    code provided -- this patch focuses on better presentation of debug data along
    with more helpful debug along error paths.

    Signed-off-by: Eric Van Hensbergen

    Eric Van Hensbergen
     
  • 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
     
  • This removes the vestigial tag field from the p9_req_t structure.

    Signed-off-by: Eric Van Hensbergen

    Eric Van Hensbergen
     
  • One of the current debug options allows users to get a verbose dump of fcalls.
    This isn't really necessary as correctly parsed protocol frames can be printed
    as part of the code in the client functions. The consolidated printfcalls
    structure would require new entries to be added for every extension. This
    patch removes the debug print methods and their use.

    Signed-off-by: Eric Van Hensbergen

    Eric Van Hensbergen
     
  • This adds a new protocol processing support code based on Anthony Liguori's
    9p library code. This code performs protocol marshalling/unmarshalling using
    printf like strings to represent protocol elements. It is my intent to use
    them to replace the current functions in conv.c as well as the
    p9_create_* functions.

    This should make the client implementation much more clear, and also make it
    much easier to add new protocol extensions by limiting the number of places
    in which changes need to be made.

    Signed-off-by: Eric Van Hensbergen

    Eric Van Hensbergen
     
  • Alsmot all 9P client wire functions have their own (set of) functions.
    Tversion is an exception as its encapsulated into the client_create code.

    This patch moves the protocol specifics of this to a function to match the
    rest of the 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
     
  • 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
     
  • Post p9_fd_poll() error path which checks m->poll_waddr[i] for PTR_ERR
    value has the following problems.

    * It's completely unused. Error value is set iff NULL @wait_address
    has been specified to p9_pollwait() which is guaranteed not to
    happen.

    * It dereferences @m after deallocating it (introduced by 571ffeaf and
    spotted by Raja R Harinath.

    * It returned the wrong value on error. It should return
    poll_waddr[i] but it returnes poll_waddr (introduced by 571ffeaf).

    * p9_mux_poll_stop() doesn't handle PTR_ERR value. It will try to
    operate on the PTR_ERR value as if it's a normal pointer and cause
    oops.

    As the error path is bogus in the first place, there's no reason to
    hold onto it. Kill it.

    Signed-off-by: Tejun Heo
    Signed-off-by: Eric Van Hensbergen
    Cc: Raja R Harinath

    Tejun Heo
     
  • This code moves the rpc function to the common client base,
    reorganizes the flush code to be more simple and stable, and
    makes the necessary adjustments to the underlying transports
    to adapt to the new structure.

    This reduces the overall amount of code duplication between the
    transports and should make adding new transports more straightforward.

    Signed-off-by: Eric Van Hensbergen

    Eric Van Hensbergen
     
  • This patch reworks the read_work function to enable it to directly use a passed
    in rcall structure. This should help allow us to remove unnecessary copies
    in the future.

    Signed-off-by: Eric Van Hensbergen

    Eric Van Hensbergen
     
  • Apply the now common p9_req_t structure to the fd transport.

    Signed-off-by: Eric Van Hensbergen

    Eric Van Hensbergen
     
  • Simplify trans_fd by using new common client tagpool structure.

    Signed-off-by: Eric Van Hensbergen

    Eric Van Hensbergen
     
  • The virtio transport uses a simplified request management system
    that I want to use for all transports. This patch adapts and moves the
    exisiting code for managing requests to the client common code.
    Later patches will apply these mechanisms to the other transports.

    Signed-off-by: Eric Van Hensbergen

    Eric Van Hensbergen
     
  • The current trans_fd rpc mechanisms use a dynamic callback mechanism which
    introduces a lot of complexity which only accomodates a single special case.
    This patch removes much of that complexity in favor of a simple exception
    mechanism to deal with flushes.

    Signed-off-by: Eric Van Hensbergen

    Eric Van Hensbergen
     
  • Currently, trans_fd has two structures (p9_req and p9_mux-rpc)
    which contain mostly duplicate data.

    This patch consolidates these two structures and removes p9_mux_rpc.

    Signed-off-by: Eric Van Hensbergen

    Eric Van Hensbergen