13 Jan, 2012

1 commit

  • compile in nfs-for-3.3 branch shows following warnings. Fix it here.

    fs/nfs/nfs4proc.c: In function ‘__nfs4_get_acl_uncached’:
    fs/nfs/nfs4proc.c:3589: warning: format ‘%ld’ expects type ‘long int’, but argument 4 has type ‘size_t’
    fs/nfs/nfs4proc.c:3589: warning: format ‘%ld’ expects type ‘long int’, but argument 6 has type ‘size_t’

    Signed-off-by: Peng Tao
    Signed-off-by: Trond Myklebust

    Peng Tao
     

11 Jan, 2012

1 commit

  • * 'nfs-for-3.3' of git://git.linux-nfs.org/projects/trondmy/linux-nfs:
    NFSv4: Change the default setting of the nfs4_disable_idmapping parameter
    NFSv4: Save the owner/group name string when doing open
    NFS: Remove pNFS bloat from the generic write path
    pnfs-obj: Must return layout on IO error
    pnfs-obj: pNFS errors are communicated on iodata->pnfs_error
    NFS: Cache state owners after files are closed
    NFS: Clean up nfs4_find_state_owners_locked()
    NFSv4: include bitmap in nfsv4 get acl data
    nfs: fix a minor do_div portability issue
    NFSv4.1: cleanup comment and debug printk
    NFSv4.1: change nfs4_free_slot parameters for dynamic slots
    NFSv4.1: cleanup init and reset of session slot tables
    NFSv4.1: fix backchannel slotid off-by-one bug
    nfs: fix regression in handling of context= option in NFSv4
    NFS - fix recent breakage to NFS error handling.
    NFS: Retry mounting NFSROOT
    SUNRPC: Clean up the RPCSEC_GSS service ticket requests

    Linus Torvalds
     

08 Jan, 2012

1 commit

  • ...so that we can do the uid/gid mapping outside the asynchronous RPC
    context.
    This fixes a bug in the current NFSv4 atomic open code where the client
    isn't able to determine what the true uid/gid fields of the file are,
    (because the asynchronous nature of the OPEN call denies it the ability
    to do an upcall) and so fills them with default values, marking the
    inode as needing revalidation.
    Unfortunately, in some cases, the VFS will do some additional sanity
    checks on the file, and may override the server's decision to allow
    the open because it sees the wrong owner/group fields.

    Signed-off-by: Trond Myklebust

    Trond Myklebust
     

05 Jan, 2012

4 commits


22 Dec, 2011

1 commit

  • * master: (848 commits)
    SELinux: Fix RCU deref check warning in sel_netport_insert()
    binary_sysctl(): fix memory leak
    mm/vmalloc.c: remove static declaration of va from __get_vm_area_node
    ipmi_watchdog: restore settings when BMC reset
    oom: fix integer overflow of points in oom_badness
    memcg: keep root group unchanged if creation fails
    nilfs2: potential integer overflow in nilfs_ioctl_clean_segments()
    nilfs2: unbreak compat ioctl
    cpusets: stall when updating mems_allowed for mempolicy or disjoint nodemask
    evm: prevent racing during tfm allocation
    evm: key must be set once during initialization
    mmc: vub300: fix type of firmware_rom_wait_states module parameter
    Revert "mmc: enable runtime PM by default"
    mmc: sdhci: remove "state" argument from sdhci_suspend_host
    x86, dumpstack: Fix code bytes breakage due to missing KERN_CONT
    IB/qib: Correct sense on freectxts increment and decrement
    RDMA/cma: Verify private data length
    cgroups: fix a css_set not found bug in cgroup_attach_proc
    oprofile: Fix uninitialized memory access when writing to writing to oprofilefs
    Revert "xen/pv-on-hvm kexec: add xs_reset_watches to shutdown watches from old kernel"
    ...

    Conflicts:
    kernel/cgroup_freezer.c

    Rafael J. Wysocki
     

10 Dec, 2011

1 commit


07 Dec, 2011

1 commit

  • Allow the freezer to skip wait_on_bit_killable sleeps in the sunrpc
    layer. This should allow suspend and hibernate events to proceed, even
    when there are RPC's pending on the wire.

    Also, wrap the TASK_KILLABLE sleeps in NFS layer in freezer_do_not_count
    and freezer_count calls. This allows the freezer to skip tasks that are
    sleeping while looping on EJUKEBOX or NFS4ERR_DELAY sorts of errors.

    Signed-off-by: Jeff Layton
    Signed-off-by: Rafael J. Wysocki

    Jeff Layton
     

08 Nov, 2011

1 commit

  • Fix a regression that was introduced by commit
    0c2e53f11a6dae9e3af5f50f5ad0382e7c3e0cfa (NFS: Remove the unused
    "lookupfh()" version of nfs4_proc_lookup()).

    In the case where the lookup gets an NFS4ERR_MOVED, we want to return
    the result of nfs4_get_referral(). Instead, that value is getting
    clobbered by the call to nfs4_handle_exception()...

    Reported-by: Tigran Mkrtchyan
    Tested-by: Tigran Mkrtchyan
    Signed-off-by: Trond Myklebust

    Trond Myklebust
     

05 Nov, 2011

1 commit

  • commit d953126 changed how nfs_atomic_lookup handles an -EISDIR return
    from an OPEN call. Prior to that patch, that caused the client to fall
    back to doing a normal lookup. When that patch went in, the code began
    returning that error to userspace. The d_revalidate codepath however
    never had the corresponding change, so it was still possible to end up
    with a NULL ctx->state pointer after that.

    That patch caused a regression. When we attempt to open a directory that
    does not have a cached dentry, that open now errors out with EISDIR. If
    you attempt the same open with a cached dentry, it will succeed.

    Fix this by reverting the change in nfs_atomic_lookup and allowing
    attempts to open directories to fall back to a normal lookup

    Also, add a NFSv4-specific f_ops->open routine that just returns
    -ENOTDIR. This should never be called if things are working properly,
    but if it ever is, then the dprintk may help in debugging.

    To facilitate this, a new file_operations field is also added to the
    nfs_rpc_ops struct.

    Cc: stable@kernel.org
    Signed-off-by: Jeff Layton
    Signed-off-by: Trond Myklebust

    Jeff Layton
     

31 Oct, 2011

1 commit

  • Current pnfs_layoutcommit_inode can not handle parallel layoutcommit.
    And as Trond suggested , there is no need for client to optimize for
    parallel layoutcommit. So add NFS_INO_LAYOUTCOMMITTING flag to
    mark inflight layoutcommit and serialize lalyoutcommit with it.
    Also mark_inode_dirty_sync if pnfs_layoutcommit_inode fails to issue
    layoutcommit.

    Reported-by: Vitaliy Gusev
    Signed-off-by: Peng Tao
    Signed-off-by: Jim Rees
    Signed-off-by: Trond Myklebust

    Peng Tao
     

20 Oct, 2011

1 commit


19 Oct, 2011

3 commits


25 Aug, 2011

4 commits


01 Aug, 2011

4 commits

  • This gives layout driver a chance to cleanup structures they put in at
    encode_layoutcommit.

    Signed-off-by: Andy Adamson
    [fixup layout header pointer for layoutcommit]
    Signed-off-by: Benny Halevy
    Signed-off-by: Benny Halevy
    [rm inode and pnfs_layout_hdr args from cleanup_layoutcommit()]
    Signed-off-by: Jim Rees
    Signed-off-by: Trond Myklebust

    Andy Adamson
     
  • Block layout needs it to determine IO size.

    Signed-off-by: Fred Isaman
    Signed-off-by: Tao Guo
    Signed-off-by: Benny Halevy
    Signed-off-by: Benny Halevy
    Signed-off-by: Jim Rees
    Signed-off-by: Trond Myklebust

    Fred Isaman
     
  • The block driver uses GETDEVICELIST

    Signed-off-by: Andy Adamson
    [pass struct nfs_server * to getdevicelist]
    [get machince creds for getdevicelist]
    [fix getdevicelist decode sizing]
    Signed-off-by: Benny Halevy
    Signed-off-by: Benny Halevy
    Signed-off-by: Jim Rees
    Signed-off-by: Trond Myklebust

    Andy Adamson
     
  • There can be multiple lseg per file, so layoutcommit should be
    able to handle it.

    [Needed in v3.0]
    CC: Stable Tree
    Signed-off-by: Peng Tao
    Signed-off-by: Boaz Harrosh
    Signed-off-by: Jim Rees
    Signed-off-by: Trond Myklebust

    Peng Tao
     

26 Jul, 2011

1 commit


20 Jul, 2011

3 commits


13 Jul, 2011

6 commits

  • Since we take a reference to it, we really ought to pass the a pointer to
    the layout header in the arguments instead of assuming that
    NFS_I(inode)->layout will forever point to the correct object.

    Signed-off-by: Trond Myklebust

    Trond Myklebust
     
  • When recovering open files and locks, the stateid should be tested
    against the server and freed if it is invalid. This patch adds new
    recovery functions for NFS v4.1.

    Signed-off-by: Bryan Schumaker
    Signed-off-by: Trond Myklebust

    Bryan Schumaker
     
  • FREE_STATEID is used to tell the server that we want to free a stateid
    that no longer has any locks associated with it. This allows the client
    to reclaim locks without encountering edge conditions documented in
    section 8.4.3 of RFC 5661.

    Signed-off-by: Bryan Schumaker
    Signed-off-by: Trond Myklebust

    Bryan Schumaker
     
  • This patch adds in the xdr for doing a TEST_STATEID call with a single
    stateid. RFC 5661 allows multiple stateids to be tested in a single
    call, but only testing one keeps things simpler for now.

    Signed-off-by: Bryan Schumaker
    Signed-off-by: Trond Myklebust

    Bryan Schumaker
     
  • If the client is using NFS v4.1, then we can use SECINFO_NO_NAME to find
    the secflavor for the initial mount. If the server doesn't support
    SECINFO_NO_NAME then I fall back on the "guess and check" method used
    for v4.0 mounts.

    Signed-off-by: Bryan Schumaker
    Signed-off-by: Trond Myklebust

    Bryan Schumaker
     
  • can be skipped if the "eir_server_scope" from the exchange_id proc differs from
    previous calls.

    Also, in the future server_scope will be useful for determining whether client
    trunking is available

    Signed-off-by: Weston Andros Adamson
    Signed-off-by: Trond Myklebust

    Weston Andros Adamson
     

15 Jun, 2011

3 commits

  • _pnfs_return_layout had the following problems:

    - it did not call pnfs_free_lseg_list on all paths
    - it unintentionally did a forgetful return when there was no outstanding io
    - it raced with concurrent LAYOUTGETS

    Signed-off-by: Fred Isaman
    Signed-off-by: Trond Myklebust

    Fred Isaman
     
  • Commit 28331a46d88459788c8fca72dbb0415cd7f514c9 "Ensure we request the
    ordinary fileid when doing readdirplus"
    changed the meaning of NFS_ATTR_FATTR_FILEID which used to be set when
    FATTR4_WORD1_MOUNTED_ON_FILED was requested.

    Allow nfs_fhget to succeed with only a mounted on fileid when crossing
    a mountpoint or a referral.

    Ask for the fileid of the absent file system if mounted_on_fileid is not
    supported.

    Signed-off-by: Andy Adamson
    cc:stable@kernel.org [2.6.39]
    Signed-off-by: Trond Myklebust

    Andy Adamson
     
  • We don't support header padding yet so better off ditching it

    Reported-by: Sid Moore
    Signed-off-by: Benny Halevy
    Signed-off-by: Trond Myklebust

    Benny Halevy
     

30 May, 2011

2 commits

  • * 'pnfs-submit' of git://git.open-osd.org/linux-open-osd: (32 commits)
    pnfs-obj: pg_test check for max_io_size
    NFSv4.1: define nfs_generic_pg_test
    NFSv4.1: use pnfs_generic_pg_test directly by layout driver
    NFSv4.1: change pg_test return type to bool
    NFSv4.1: unify pnfs_pageio_init functions
    pnfs-obj: objlayout_encode_layoutcommit implementation
    pnfs: encode_layoutcommit
    pnfs-obj: report errors and .encode_layoutreturn Implementation.
    pnfs: encode_layoutreturn
    pnfs: layoutret_on_setattr
    pnfs: layoutreturn
    pnfs-obj: osd raid engine read/write implementation
    pnfs: support for non-rpc layout drivers
    pnfs-obj: define per-inode private structure
    pnfs: alloc and free layout_hdr layoutdriver methods
    pnfs-obj: objio_osd device information retrieval and caching
    pnfs-obj: decode layout, alloc/free lseg
    pnfs-obj: pnfs_osd XDR client implementation
    pnfs-obj: pnfs_osd XDR definitions
    pnfs-obj: objlayoutdriver module skeleton
    ...

    Linus Torvalds
     
  • With the objects layout security model, we have object capabilities
    that are associated with the layout and we anticipate that the server
    will issue a cb_layoutrecall for any setattr that changes security
    related attributes (user/group/mode/acl) or truncates the file.

    Therefore, the layout is returned before issuing the setattr to avoid
    the anticipated cb_layoutrecall.

    Signed-off-by: Benny Halevy

    Benny Halevy