* [GIT PULL] Please pull NFS client changes
@ 2018-12-06 21:55 Trond Myklebust
2018-12-07 18:35 ` pr-tracker-bot
0 siblings, 1 reply; 25+ messages in thread
From: Trond Myklebust @ 2018-12-06 21:55 UTC (permalink / raw)
To: torvalds; +Cc: linux-kernel, linux-nfs
Hi Linus,
Apologies for the relatively high volume this late in -rc. This is mainly
fallout from the updates to the SUNRPC code that is being triggered from
less common combinations of NFS mount options.
Cheers
Trond
The following changes since commit 4b78317679c4f3782a3cff0ddb269c1fcfde7621:
Merge branch 'x86-pti-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip (2018-12-01 12:35:48 -0800)
are available in the Git repository at:
git://git.linux-nfs.org/projects/trondmy/linux-nfs.git tags/nfs-for-4.20-5
for you to fetch changes up to 79462857eb547e5d17fc8445b9768615e02dc1cf:
SUNRPC: Don't force a redundant disconnection in xs_read_stream() (2018-12-05 07:11:12 -0500)
----------------------------------------------------------------
NFS client bugfixes for Linux 4.20
Highlights include:
Stable fixes:
- Fix a page leak when using RPCSEC_GSS/krb5p to encrypt data.
Bugfixes:
- Fix a regression that causes the RPC receive code to hang
- Fix call_connect_status() so that it handles tasks that got transmitted
while queued waiting for the socket lock.
- Fix a memory leak in call_encode()
- Fix several other connect races.
- Fix receive code error handling.
- Use the discard iterator rather than MSG_TRUNC for compatibility with
AF_UNIX/AF_LOCAL sockets.
- nfs: don't dirty kernel pages read by direct-io
- pnfs/Flexfiles fix to enforce per-mirror stateid only for NFSv4 data
servers
----------------------------------------------------------------
Chuck Lever (1):
SUNRPC: Fix leak of krb5p encode pages
Dave Kleikamp (1):
nfs: don't dirty kernel pages read by direct-io
Tigran Mkrtchyan (1):
flexfiles: enforce per-mirror stateid only for v4 DSes
Trond Myklebust (9):
SUNRPC: call_connect_status() must handle tasks that got transmitted
SUNRPC: Fix a memory leak in call_encode()
SUNRPC: Fix a potential race in xprt_connect()
SUNRPC: Fix RPC receive hangs
SUNRPC: Fix up handling of the XDRBUF_SPARSE_PAGES flag
SUNRPC: Treat EFAULT as a truncated message in xs_read_stream_request()
SUNRPC: Use the discard iterator rather than MSG_TRUNC
SUNRPC: Fix up socket polling
SUNRPC: Don't force a redundant disconnection in xs_read_stream()
fs/nfs/direct.c | 9 +++-
fs/nfs/flexfilelayout/flexfilelayout.c | 6 ++-
include/linux/sunrpc/xdr.h | 1 -
net/sunrpc/auth_gss/auth_gss.c | 4 ++
net/sunrpc/clnt.c | 8 ++++
net/sunrpc/xprt.c | 13 +++++-
net/sunrpc/xprtsock.c | 81 ++++++++++++++++------------------
7 files changed, 73 insertions(+), 49 deletions(-)
--
Trond Myklebust
Linux NFS client maintainer, Hammerspace
trond.myklebust@hammerspace.com
^ permalink raw reply [flat|nested] 25+ messages in thread
* [GIT PULL] Please pull NFS client changes
@ 2022-04-08 17:30 Trond Myklebust
2022-04-08 17:46 ` pr-tracker-bot
0 siblings, 1 reply; 25+ messages in thread
From: Trond Myklebust @ 2022-04-08 17:30 UTC (permalink / raw)
To: torvalds; +Cc: linux-nfs, linux-kernel
Hi Linus,
The following changes since commit 7c9d845f0612e5bcd23456a2ec43be8ac43458f1:
NFSv4/pNFS: Fix another issue with a list iterator pointing to the head (2022-03-28 08:36:34 -0400)
are available in the Git repository at:
git://git.linux-nfs.org/projects/trondmy/linux-nfs.git tags/nfs-for-5.18-2
for you to fetch changes up to ff053dbbaffec45c85e5bfe43306d26694a6433f:
SUNRPC: Move the call to xprt_send_pagedata() out of xprt_sock_sendmsg() (2022-04-07 16:20:01 -0400)
----------------------------------------------------------------
NFS client bugfixes for Linux 5.18
Highlights include:
Stable fixes:
- SUNRPC: Ensure we flush any closed sockets before xs_xprt_free()
Bugfixes:
- Fix an Oopsable condition due to SLAB_ACCOUNT setting in the NFSv4.2
xattr code.
- Fix for open() using an file open mode of '3' in NFSv4
- Replace readdir's use of xxhash() with hash_64()
- Several patches to handle malloc() failure in SUNRPC
----------------------------------------------------------------
ChenXiaoSong (2):
Revert "NFSv4: Handle the special Linux file open access mode"
NFSv4: fix open failure with O_ACCMODE flag
Muchun Song (1):
NFSv4.2: Fix missing removal of SLAB_ACCOUNT on kmem_cache allocation
NeilBrown (1):
SUNRPC: handle malloc failure in ->request_prepare
Trond Myklebust (9):
NFS: Replace readdir's use of xxhash() with hash_64()
SUNRPC: Ensure we flush any closed sockets before xs_xprt_free()
SUNRPC: Handle ENOMEM in call_transmit_status()
SUNRPC: Handle low memory situations in call_status()
NFSv4/pnfs: Handle RPC allocation errors in nfs4_proc_layoutget
NFS: Ensure rpc_run_task() cannot fail in nfs_async_rename()
SUNRPC: Handle allocation failure in rpc_new_task()
SUNRPC: svc_tcp_sendmsg() should handle errors from xdr_alloc_bvec()
SUNRPC: Move the call to xprt_send_pagedata() out of xprt_sock_sendmsg()
fs/file_table.c | 1 +
fs/nfs/Kconfig | 4 ----
fs/nfs/dir.c | 19 +++----------------
fs/nfs/inode.c | 1 -
fs/nfs/internal.h | 10 ++++++++++
fs/nfs/nfs42xattr.c | 2 +-
fs/nfs/nfs4file.c | 6 ++++--
fs/nfs/nfs4proc.c | 2 ++
fs/nfs/unlink.c | 1 +
include/linux/nfs_xdr.h | 1 +
include/linux/sunrpc/xprt.h | 5 ++---
include/trace/events/sunrpc.h | 1 -
net/sunrpc/clnt.c | 20 +++++++++++++++++---
net/sunrpc/sched.c | 5 +++++
net/sunrpc/socklib.c | 6 ------
net/sunrpc/svcsock.c | 13 +++++++++----
net/sunrpc/xprt.c | 30 ++++++++++++++++--------------
net/sunrpc/xprtsock.c | 33 +++++++++++++++++++++++++++------
18 files changed, 99 insertions(+), 61 deletions(-)
--
Trond Myklebust
Linux NFS client maintainer, Hammerspace
trond.myklebust@hammerspace.com
^ permalink raw reply [flat|nested] 25+ messages in thread
* [GIT PULL] Please pull NFS client changes
@ 2018-11-25 3:04 Trond Myklebust
2018-11-25 17:45 ` pr-tracker-bot
0 siblings, 1 reply; 25+ messages in thread
From: Trond Myklebust @ 2018-11-25 3:04 UTC (permalink / raw)
To: torvalds; +Cc: linux-kernel, linux-nfs
Hi Linus,
The following changes since commit 9ff01193a20d391e8dbce4403dd5ef87c7eaaca6:
Linux 4.20-rc3 (2018-11-18 13:33:44 -0800)
are available in the Git repository at:
git://git.linux-nfs.org/projects/trondmy/linux-nfs.git tags/nfs-for-4.20-4
for you to fetch changes up to bb21ce0ad227b69ec0f83279297ee44232105d96:
flexfiles: use per-mirror specified stateid for IO (2018-11-22 14:04:55 -0500)
----------------------------------------------------------------
NFS client bugfixes for Linux 4.20
Highlights include:
Bugfixes:
- Fix a NFSv4 state manager deadlock when returning a delegation
- NFSv4.2 copy do not allocate memory under the lock
- flexfiles: Use the correct stateid for IO in the tightly coupled case
----------------------------------------------------------------
Olga Kornievskaia (1):
NFSv4.2 copy do not allocate memory under the lock
Tigran Mkrtchyan (1):
flexfiles: use per-mirror specified stateid for IO
Trond Myklebust (1):
NFSv4: Fix a NFSv4 state manager deadlock
fs/nfs/callback_proc.c | 22 +++++++++++-----------
fs/nfs/flexfilelayout/flexfilelayout.c | 21 +++++++++------------
fs/nfs/flexfilelayout/flexfilelayout.h | 4 ++++
fs/nfs/flexfilelayout/flexfilelayoutdev.c | 19 +++++++++++++++++++
fs/nfs/nfs42proc.c | 19 ++++++++++---------
fs/nfs/nfs4_fs.h | 2 ++
fs/nfs/nfs4state.c | 16 +++++++++++-----
7 files changed, 66 insertions(+), 37 deletions(-)
--
Trond Myklebust
Linux NFS client maintainer, Hammerspace
trond.myklebust@hammerspace.com
^ permalink raw reply [flat|nested] 25+ messages in thread
* [GIT PULL] Please pull NFS client changes
@ 2018-01-30 14:39 Trond Myklebust
0 siblings, 0 replies; 25+ messages in thread
From: Trond Myklebust @ 2018-01-30 14:39 UTC (permalink / raw)
To: torvalds; +Cc: linux-kernel, linux-nfs
Hi Linus,
The following changes since commit a8750ddca918032d6349adbf9a4b6555e7db20da:
Linux 4.15-rc8 (2018-01-14 15:32:30 -0800)
are available in the Git repository at:
git://git.linux-nfs.org/projects/trondmy/linux-nfs.git tags/nfs-for-4.16-1
for you to fetch changes up to e231c6879cfd44e4fffd384bb6dd7d313249a523:
NFS: Fix a race between mmap() and O_DIRECT (2018-01-28 22:00:15 -0500)
----------------------------------------------------------------
NFS client updates for Linux 4.16
Highlights include:
Stable bugfixes:
- Fix breakages in the nfsstat utility due to the inclusion of the NFSv4
LOOKUPP operation.
- Fix a NULL pointer dereference in nfs_idmap_prepare_pipe_upcall() due to
nfs_idmap_legacy_upcall() being called without an 'aux' parameter.
- Fix a refcount leak in the standard O_DIRECT error path.
- Fix a refcount leak in the pNFS O_DIRECT fallback to MDS path.
- Fix CPU latency issues with nfs_commit_release_pages()
- Fix the LAYOUTUNAVAILABLE error case in the file layout type.
- NFS: Fix a race between mmap() and O_DIRECT
Features:
- Support the statx() mask and query flags to enable optimisations when
the user is requesting only attributes that are already up to date in
the inode cache, or is specifying the AT_STATX_DONT_SYNC flag.
- Add a module alias for the SCSI pNFS layout type.
Bugfixes:
- Automounting when resolving a NFSv4 referral should preserve the RDMA
transport protocol settings.
- Various other RDMA bugfixes from Chuck.
- pNFS block layout fixes.
- Always set NFS_LOCK_LOST when a lock is lost.
----------------------------------------------------------------
Arnd Bergmann (1):
nfs: remove unused label in nfs_encode_fh()
Benjamin Coddington (7):
NFS: remove unused offset arg in nfs_pgio_rpcsetup
pnfs/blocklayout: Add module alias for LAYOUT4_SCSI
pnfs/blocklayout: set PNFS_LAYOUTRETURN_ON_ERROR
pnfs/blocklayout: handle transient devices
SUNRPC: Fix null rpc_clnt dereference in rpc_task_queued tracepoint
pnfs/blocklayout: pnfs_block_dev_map uses bytes, not sectors
pnfs/blocklayout: Ensure disk address in block device map
Chuck Lever (39):
nfs: Define NFS_RDMA_PORT
nfs: Referrals should use the same proto setting as their parent
nfs: Update server port after referral or migration
SUNRPC: Remove rpc_protocol()
xprtrdma: Fix buffer leak after transport set up failure
xprtrdma: Fix backchannel allocation of extra rpcrdma_reps
xprtrdma: Eliminate unnecessary lock cycle in xprt_rdma_send_request
xprtrdma: Per-mode handling for Remote Invalidation
xprtrdma: Remove ri_reminv_expected
xprtrdma: Remove unused padding variables
xprtrdma: Initialize the xprt address string array earlier
xprtrdma: Remove another sockaddr_storage field (cdata::addr)
xprtrdma: Support IPv6 in xprt_rdma_set_port
xprtrdma: Move unmap-safe logic to rpcrdma_marshal_req
xprtrdma: buf_free not called for CB replies
xprtrdma: Split xprt_rdma_send_request
xprtrdma: Don't clear RPC_BC_PA_IN_USE on pre-allocated rpc_rqst's
xprtrdma: Replace all usage of "frmr" with "frwr"
xprtrdma: Remove usage of "mw"
xprtrdma: Introduce rpcrdma_mw_unmap_and_put
nfs: Use proper enum definitions for nfs_show_stable
rdma/ib: Add trace point macros to display human-readable values
rpcrdma: infrastructure for static trace points in rpcrdma.ko
xprtrdma: Add trace points in RPC Call transmit paths
xprtrdma: Add trace points in the RPC Reply handler paths
xprtrdma: Add trace points to instrument memory registration
xprtrdma: Add trace points in reply decoder path
xprtrdma: Add trace points to instrument memory invalidation
xprtrdma: Add trace points to instrument MR allocation and recovery
xprtrdma: Add trace points for connect events
xprtrdma: Add trace points in the client-side backchannel code paths
xprtrdma: Add trace points to instrument QP and CQ access upcalls
xprtrdma: Instrument allocation/release of rpcrdma_req/rep objects
xprtrdma: Fix "bytes registered" accounting
xprtrdma: Correct some documenting comments
SUNRPC: Trace xprt_timer events
sunrpc: Format RPC events consistently for display
SUNRPC: task_run_action should display tk_callback
SUNRPC: Micro-optimize __rpc_execute
Elena Reshetova (4):
lockd: convert nlm_host.h_count from atomic_t to refcount_t
lockd: convert nsm_handle.sm_count from atomic_t to refcount_t
lockd: convert nlm_lockowner.count from atomic_t to refcount_t
lockd: convert nlm_rqst.a_count from atomic_t to refcount_t
Eric Biggers (1):
NFS: reject request for id_legacy key without auxdata
J. Bruce Fields (1):
NFS: commit direct writes even if they fail partially
Jan Chochol (1):
nfs: Do not convert nfs_idmap_cache_timeout to jiffies
NeilBrown (2):
nfs: remove dead code from nfs_encode_fh()
NFSv4: always set NFS_LOCK_LOST when a lock is lost.
Scott Mayhew (1):
nfs/pnfs: fix nfs_direct_req ref leak when i/o falls back to the mds
Tigran Mkrtchyan (1):
nfs41: do not return ENOMEM on LAYOUTUNAVAILABLE
Trond Myklebust (12):
NFS: Add a cond_resched() to nfs_commit_release_pages()
NFSv4: Convert CLOSE to use nfs4_async_handle_exception()
NFSv4: Convert DELEGRETURN to use nfs4_handle_exception()
NFSv4: Convert LOCKU to use nfs4_async_handle_exception()
NFS: Fix nfsstat breakage due to LOOKUPP
Support statx() mask and query flags parameters
SUNRPC: Chunk reading of replies from the server
SUNRPC: Add explicit rescheduling points in the receive path
Merge tag 'nfs-rdma-for-4.16-1' of git://git.linux-nfs.org/projects/anna/linux-nfs
lockd: Fix server refcounting
NFS: Remove a redundant call to unmap_mapping_range()
NFS: Fix a race between mmap() and O_DIRECT
fs/lockd/clntproc.c | 14 +-
fs/lockd/host.c | 22 +-
fs/lockd/mon.c | 14 +-
fs/lockd/svcproc.c | 2 +-
fs/nfs/blocklayout/blocklayout.c | 94 +++-
fs/nfs/blocklayout/blocklayout.h | 7 +-
fs/nfs/blocklayout/dev.c | 7 +-
fs/nfs/direct.c | 4 +-
fs/nfs/export.c | 5 -
fs/nfs/filelayout/filelayout.c | 4 +-
fs/nfs/inode.c | 53 ++-
fs/nfs/io.c | 2 +-
fs/nfs/nfs4client.c | 24 +-
fs/nfs/nfs4idmap.c | 6 +-
fs/nfs/nfs4namespace.c | 2 -
fs/nfs/nfs4proc.c | 42 +-
fs/nfs/nfs4state.c | 5 +-
fs/nfs/nfs4sysctl.c | 2 +-
fs/nfs/nfs4xdr.c | 64 +--
fs/nfs/nfstrace.h | 22 +-
fs/nfs/pagelist.c | 8 +-
fs/nfs/pnfs.c | 6 +-
fs/nfs/pnfs.h | 6 +-
fs/nfs/pnfs_dev.c | 1 -
fs/nfs/write.c | 2 +
include/linux/lockd/lockd.h | 9 +-
include/linux/nfs4.h | 12 +-
include/linux/sunrpc/clnt.h | 1 -
include/linux/sunrpc/xprtrdma.h | 2 +-
include/trace/events/rdma.h | 129 ++++++
include/trace/events/rpcrdma.h | 890 ++++++++++++++++++++++++++++++++++++++
include/trace/events/sunrpc.h | 12 +-
include/uapi/linux/nfs.h | 1 +
net/sunrpc/clnt.c | 16 -
net/sunrpc/sched.c | 26 +-
net/sunrpc/xprt.c | 2 +-
net/sunrpc/xprtrdma/backchannel.c | 78 ++--
net/sunrpc/xprtrdma/fmr_ops.c | 157 ++++---
net/sunrpc/xprtrdma/frwr_ops.c | 329 +++++++-------
net/sunrpc/xprtrdma/module.c | 12 +-
net/sunrpc/xprtrdma/rpc_rdma.c | 162 +++----
net/sunrpc/xprtrdma/transport.c | 128 +++---
net/sunrpc/xprtrdma/verbs.c | 280 ++++++------
net/sunrpc/xprtrdma/xprt_rdma.h | 116 ++---
net/sunrpc/xprtsock.c | 36 +-
45 files changed, 1995 insertions(+), 821 deletions(-)
create mode 100644 include/trace/events/rdma.h
create mode 100644 include/trace/events/rpcrdma.h
--
Trond Myklebust
Linux NFS client maintainer, PrimaryData
trond.myklebust@primarydata.com
^ permalink raw reply [flat|nested] 25+ messages in thread
* [GIT PULL] Please pull NFS client changes
@ 2017-10-09 17:35 Trond Myklebust
0 siblings, 0 replies; 25+ messages in thread
From: Trond Myklebust @ 2017-10-09 17:35 UTC (permalink / raw)
To: torvalds; +Cc: linux-kernel, linux-nfs
Hi Linus,
The following changes since commit 9e66317d3c92ddaab330c125dfe9d06eee268aff:
Linux 4.14-rc3 (2017-10-01 14:54:54 -0700)
are available in the git repository at:
git://git.linux-nfs.org/projects/trondmy/linux-nfs.git tags/nfs-for-4.14-3
for you to fetch changes up to e8fa33a6f6c7688591542db955794b69b8cecc55:
NFSv4/pnfs: Fix an infinite layoutget loop (2017-10-04 14:06:54 -0400)
----------------------------------------------------------------
NFS client bugfixes for Linux 4.14
Hightlights include:
stable fixes:
- nfs/filelayout: fix oops when freeing filelayout segment
- NFS: Fix uninitialized rpc_wait_queue
bugfixes:
- NFSv4/pnfs: Fix an infinite layoutget loop
- nfs: RPC_MAX_AUTH_SIZE is in bytes
----------------------------------------------------------------
Benjamin Coddington (1):
NFS: Fix uninitialized rpc_wait_queue
Colin Ian King (1):
sunrpc: remove redundant initialization of sock
Dan Carpenter (1):
NFS: Cleanup error handling in nfs_idmap_request_key()
J. Bruce Fields (1):
nfs: RPC_MAX_AUTH_SIZE is in bytes
Scott Mayhew (1):
nfs/filelayout: fix oops when freeing filelayout segment
Trond Myklebust (1):
NFSv4/pnfs: Fix an infinite layoutget loop
fs/nfs/client.c | 2 +-
fs/nfs/filelayout/filelayout.c | 3 ++-
fs/nfs/nfs4idmap.c | 2 +-
fs/nfs/nfs4proc.c | 3 +--
fs/nfs/nfs4xdr.c | 4 ++--
net/sunrpc/xprtsock.c | 2 +-
6 files changed, 8 insertions(+), 8 deletions(-)
--
Trond Myklebust
Linux NFS client maintainer, PrimaryData
trond.myklebust@primarydata.com
^ permalink raw reply [flat|nested] 25+ messages in thread
* [GIT PULL] Please pull NFS client changes
@ 2016-01-14 21:09 Trond Myklebust
0 siblings, 0 replies; 25+ messages in thread
From: Trond Myklebust @ 2016-01-14 21:09 UTC (permalink / raw)
To: Linus Torvalds
Cc: Linux NFS Mailing List, Linux Kernel Mailing List, Stephen Rothwell
Hi Linus,
The following changes since commit 74bf8efb5fa6e958d2d7c7917b8bb672085ec0c6:
Linux 4.4-rc7 (2015-12-27 18:17:37 -0800)
are available in the git repository at:
git://git.linux-nfs.org/projects/trondmy/linux-nfs.git tags/nfs-for-4.5-1
for you to fetch changes up to 44aab3e09ef947e546ee61c5082c41b86dd15e53:
NFS: Fix a compile warning about unused variable in
nfs_generic_pg_pgios() (2016-01-08 08:12:47 -0500)
Please note that Stephen saw a conflict between commits:
926ea40a7ee2 ("NFSv4: Fix a compile warning about no prototype for
nfs4_ioctl()")
and
04b38d601239 ("vfs: pull btrfs clone API to vfs layer")
from Al's vfs tree. The fixup should be trivial.
Cheers
Trond
----------------------------------------------------------------
NFS client updates for Linux 4.5
Highlights include:
Stable fixes:
- Fix a regression in the SunRPC socket polling code
- Fix the attribute cache revalidation code
- Fix race in __update_open_stateid()
- Fix an lo->plh_block_lgets imbalance in layoutreturn
- Fix an Oopsable typo in ff_mirror_match_fh()
Features:
- pNFS layout recall performance improvements.
- pNFS/flexfiles: Support server-supplied layoutstats sampling period
Bugfixes + cleanups:
- NFSv4: Don't perform cached access checks before we've OPENed the file
- Fix starvation issues with background flushes
- Reclaim writes should be flushed as unstable writes if there are already
entries in the commit lists
- Various bugfixes from Chuck to fix NFS/RDMA send queue ordering problems
- Ensure that we propagate fatal layoutget errors back to the application
- Fixes for sundry flexfiles layoutstats bugs
- Fix files/flexfiles to not cache invalidated layouts in the DS commit buckets
----------------------------------------------------------------
Andrew Elble (3):
nfs: fix missing assignment in nfs4_sequence_done tracepoint
nfs: Fix race in __update_open_stateid()
nfs: machine credential support for additional operations
Benjamin Coddington (1):
NFS: Use wait_on_atomic_t() for unlock after readahead
Chuck Lever (10):
xprtrdma: Fix additional uses of spin_lock_irqsave(rb_lock)
xprtrdma: xprt_rdma_free() must not release backchannel reqs
xprtrdma: Disable RPC/RDMA backchannel debugging messages
xprtrdma: Move struct ib_send_wr off the stack
xprtrdma: Introduce ro_unmap_sync method
xprtrdma: Add ro_unmap_sync method for FRWR
xprtrdma: Add ro_unmap_sync method for FMR
xprtrdma: Add ro_unmap_sync method for all-physical registration
xprtrdma: Invalidate in the RPC reply handler
xprtrdma: Revert commit e7104a2a9606 ('xprtrdma: Cap req_cqinit').
Dan Carpenter (2):
xprtrdma: clean up some curly braces
xprtrdma: checking for NULL instead of IS_ERR()
Jeff Layton (1):
nfs: add new tracepoint for pnfs_update_layout
Olga Kornievskaia (2):
Adding stateid information to tracepoints
Adding tracepoint to cached open
Peng Tao (9):
NFS42: handle layoutstats stateid error
NFS41: pop some layoutget errors to application
nfs: clean up rest of reqs when failing to add one
nfs: centralize pgio error cleanup
nfs: handle request add failure properly
nfs: only remove page from mapping if launder_page fails
NFS41: map NFS4ERR_LAYOUTUNAVAILABLE to ENODATA
pnfs/flexfiles: do not mark delay-like status as DS failure
pnfs/flexfiles: count io stat in rpc_count_stats callback
Stefan Hajnoczi (1):
SUNRPC: drop unused xs_reclassify_socketX() helpers
Trond Myklebust (42):
NFS: Allow the combination pNFS and labeled NFS
NFSv4: Fix unused variable warnings in nfs4_init_*_client_string()
pNFS: Modify pnfs_update_layout tracepoints to use layout stateid
NFSv4: Don't perform cached access checks before we've OPENed the file
NFSv4.1/pnfs: Fixup an lo->plh_block_lgets imbalance in layoutreturn
NFS: Background flush should not be low priority
NFS: Flush reclaim writes using FLUSH_COND_STABLE
pNFS/flexfiles: Support server-supplied layoutstats sampling period
pNFS/flexfiles: Don't prevent flexfiles client from retrying LAYOUTGET
pNFS/flexfiles: Don't mark the entire layout as failed, when returning it
pNFS/flexfiles: Fix a statistics gathering imbalance
pNFS: Add flag to track if we've called
nfs4_ff_layout_stat_io_start_read/write
pNFS/flexfiles: Ensure we record layoutstats even if RPC is
terminated early
pNFS: Ensure nfs4_layoutget_prepare returns the correct error
NFSv4.1/pNFS: Add a helper to mark the layout as returned
pNFS: If we have to delay the layout callback, mark the layout for return
NFSv4.1/pNFS: Ensure we enforce RFC5661 Section 12.5.5.2.1
NFSv4.1/pNFS: Don't return NFS4ERR_DELAY unnecessarily in CB_LAYOUTRECALL
NFSv4: List stateid information in the callback tracepoints
Merge tag 'nfs-rdma-4.5' of git://git.linux-nfs.org/projects/anna/nfs-rdma
Merge branch 'flexfiles'
NFS: Ensure we revalidate attributes before using execute_ok()
NFS: Fix attribute cache revalidation
pNFS/flexfiles: Fix an Oopsable typo in ff_mirror_match_fh()
SUNRPC: Fix a missing break in rpc_anyaddr()
NFS/pNFS: Fix up pNFS write reschedule layering violations and bugs
NFS: Allow multiple commit requests in flight per file
NFSv4.1/pNFS: Don't queue up a new commit if the layout segment is invalid
NFS: Relax requirements in nfs_flush_incompatible
NFSv4.1/pNFS: Don't pass stateids by value to pnfs_send_layoutreturn()
NFSv4.1/pNFS: Use nfs4_stateid_copy for copying stateids
NFSv4.1/pNFS: pnfs_mark_matching_lsegs_return() should set the iomode
NFSv4.1/pNFS: pnfs_error_mark_layout_for_return() must always
return layout
NFSv4.1/pNFS: Fix a race in initiate_file_draining()
NFSv4.1/pNFS: Cleanup pnfs_mark_matching_lsegs_invalid()
NFSv4.1/pnfs: Cleanup copying of pnfs_layout_range structures
NFSv4.1/pNFS: Cleanup constify struct pnfs_layout_range arguments
Merge branch 'pnfs_generic'
SUNRPC: Fixup socket wait for memory
Merge branch 'bugfixes'
NFSv4: Fix a compile warning about no prototype for nfs4_ioctl()
NFS: Fix a compile warning about unused variable in nfs_generic_pg_pgios()
Wei Tang (1):
nfs: do not initialise statics to 0
fs/nfs/callback_proc.c | 52 +++-
fs/nfs/dir.c | 21 +-
fs/nfs/direct.c | 48 +++-
fs/nfs/file.c | 6 +-
fs/nfs/filelayout/filelayout.c | 18 +-
fs/nfs/flexfilelayout/flexfilelayout.c | 205 ++++++++++----
fs/nfs/flexfilelayout/flexfilelayout.h | 1 +
fs/nfs/flexfilelayout/flexfilelayoutdev.c | 16 +-
fs/nfs/inode.c | 78 ++++--
fs/nfs/internal.h | 39 ++-
fs/nfs/nfs42proc.c | 29 +-
fs/nfs/nfs4file.c | 2 +-
fs/nfs/nfs4proc.c | 71 +++--
fs/nfs/nfs4sysctl.c | 2 +-
fs/nfs/nfs4trace.c | 1 +
fs/nfs/nfs4trace.h | 431 ++++++++++++++++++++++++++++--
fs/nfs/nfstrace.h | 1 -
fs/nfs/pagelist.c | 126 ++++-----
fs/nfs/pnfs.c | 180 ++++++++-----
fs/nfs/pnfs.h | 54 ++--
fs/nfs/pnfs_nfs.c | 10 +-
fs/nfs/read.c | 43 +--
fs/nfs/write.c | 133 +++++----
include/linux/nfs4.h | 14 +
include/linux/nfs_fs.h | 23 +-
include/linux/nfs_fs_sb.h | 1 +
include/linux/nfs_xdr.h | 6 +-
net/sunrpc/clnt.c | 1 +
net/sunrpc/xprtrdma/backchannel.c | 26 +-
net/sunrpc/xprtrdma/fmr_ops.c | 64 +++++
net/sunrpc/xprtrdma/frwr_ops.c | 174 ++++++++++--
net/sunrpc/xprtrdma/physical_ops.c | 13 +
net/sunrpc/xprtrdma/rpc_rdma.c | 16 ++
net/sunrpc/xprtrdma/transport.c | 3 +
net/sunrpc/xprtrdma/verbs.c | 16 +-
net/sunrpc/xprtrdma/xprt_rdma.h | 14 +-
net/sunrpc/xprtsock.c | 63 ++---
37 files changed, 1481 insertions(+), 520 deletions(-)
--
Trond Myklebust
Linux NFS client maintainer, PrimaryData
trond.myklebust@primarydata.com
^ permalink raw reply [flat|nested] 25+ messages in thread
* [GIT PULL] Please pull NFS client changes
@ 2015-09-07 20:59 Trond Myklebust
2015-09-08 1:59 ` Stephen Rothwell
0 siblings, 1 reply; 25+ messages in thread
From: Trond Myklebust @ 2015-09-07 20:59 UTC (permalink / raw)
To: Linus Torvalds
Cc: Linux NFS Mailing List, Linux Kernel Mailing List, Oleg Drokin,
Doug Ledford
Hi Linus,
The following changes since commit 74d33293e467df61de1b1d8b2fbe29e550dec33b:
Linux 4.2-rc5 (2015-08-02 18:34:55 -0700)
are available in the git repository at:
git://git.linux-nfs.org/projects/trondmy/linux-nfs.git tags/nfs-for-4.3-1
for you to fetch changes up to 5445b1fbd123420bffed5e629a420aa2a16bf849:
NFSv4: Respect the server imposed limit on how many changes we may cache (2015-09-07 12:36:17 -0400)
Please note this aside from the usual NFS and RPC related commits, this
series includes 1 core inifiniband change (acked-by Doug Ledford) and a
corresponding fixup for the RPC layer and one for the Lustre filesystem
(acked-by Oleg Drokin).
Cheers
Trond
----------------------------------------------------------------
NFS client updates for Linux 4.3
Highlights include:
Stable patches:
- Fix atomicity of pNFS commit list updates
- Fix NFSv4 handling of open(O_CREAT|O_EXCL|O_RDONLY)
- nfs_set_pgio_error sometimes misses errors
- Fix a thinko in xs_connect()
- Fix borkage in _same_data_server_addrs_locked()
- Fix a NULL pointer dereference of migration recovery ops for v4.2 client
- Don't let the ctime override attribute barriers.
- Revert "NFSv4: Remove incorrect check in can_open_delegated()"
- Ensure flexfiles pNFS driver updates the inode after write finishes
- flexfiles must not pollute the attribute cache with attrbutes from the DS
- Fix a protocol error in layoutreturn
- Fix a protocol issue with NFSv4.1 CLOSE stateids
Bugfixes + cleanups
- pNFS blocks bugfixes from Christoph
- Various cleanups from Anna
- More fixes for delegation corner cases
- Don't fsync twice for O_SYNC/IS_SYNC files
- Fix pNFS and flexfiles layoutstats bugs
- pnfs/flexfiles: avoid duplicate tracking of mirror data
- pnfs: Fix layoutget/layoutreturn/return-on-close serialisation issues.
- pnfs/flexfiles: error handling retries a layoutget before fallback to MDS
Features:
- Full support for the OPEN NFS4_CREATE_EXCLUSIVE4_1 mode from Kinglong
- More RDMA client transport improvements from Chuck
- Removal of the deprecated ib_reg_phys_mr() and ib_rereg_phys_mr() verbs
from the SUNRPC, Lustre and core infiniband tree.
- Optimise away the close-to-open getattr if there is no cached data
----------------------------------------------------------------
Anna Schumaker (9):
NFS: Remove unused variable "pages_ptr"
NFS: Rename nfs_readdir_free_pagearray() and nfs_readdir_large_page()
SUNRPC: Drop double-underscores from rpc_cmp_addr{4|6}()
SUNRPC: Add an rpc_cmp_addr_port() function
NFS: Use RPC functions for matching sockaddrs
NFS: Combine nfs_idmap_{init|quit}() and nfs_idmap_{init|quit}_keyring()
NFS: Remove nfs41_server_notify_{target|highest}_slotid_update()
NFS: Rename nfs_commit_unstable_pages() to nfs_write_inode()
NFS: Remove nfs_release()
Christoph Hellwig (5):
pnfs/blocklayout: calculate layoutupdate size correctly
pnfs/blocklayout: set up layoutupdate_pages properly
pnfs/blocklayout: reject too long signatures
pnfs/blocklayout: pass proper file mode to blkdev_get/put
pnfs: move common blocklayout XDR defintions to nfs4.h
Chuck Lever (15):
xprtrdma: Make xprt_setup_rdma() agnostic to family of server address
xprtrdma: Raise maximum payload size to one megabyte
xprtrdma: Increase default credit limit
xprtrdma: Don't fall back to PHYSICAL memory registration
xprtrdma: Remove last ib_reg_phys_mr() call site
xprtrdma: Clean up rpcrdma_ia_open()
xprtrdma: Remove logic that constructs RDMA_MSGP type calls
xprtrdma: Account for RPC/RDMA header size when deciding to inline
xprtrdma: Always provide a write list when sending NFS READ
xprtrdma: Don't provide a reply chunk when expecting a short reply
xprtrdma: Fix XDR tail buffer marshalling
xprtrdma: Fix large NFS SYMLINK calls
xprtrdma: Clean up xprt_rdma_print_stats()
xprtrdma: Count RDMA_NOMSG type calls
core: Remove the ib_reg_phys_mr() and ib_rereg_phys_mr() verbs
Devesh Sharma (1):
xprtrdma: take HCA driver refcount at client
Jeff Layton (2):
sunrpc: increase UNX_MAXNODENAME from 32 to __NEW_UTS_LEN bytes
nfs: remove some dead code in ff_layout_pg_get_mirror_count_write
Kinglong Mee (10):
NFS: Error out when register_shrinker fail in register_nfs_fs
NFS: Remove duplicate svc_xprt_put from nfs41_callback_up
NFS: Fix a NULL pointer dereference of migration recovery ops for v4.2 client
NFS: Check size by inode_newsize_ok in nfs_setattr
NFS: Make opened as optional argument in _nfs4_do_open
NFS: Update NFS4_BITMAP_SIZE
NFS: Get suppattr_exclcreat when getting server capabilities
NFS: Send attributes in OPEN request for NFS4_CREATE_EXCLUSIVE4_1
nfs: Fix truncated client owner id without proto type
nfs: Remove unneeded checking of the return value from scnprintf
NeilBrown (1):
NFSv4: don't set SETATTR for O_RDONLY|O_EXCL
Oleg Drokin (1):
staging/lustre/o2iblnd: remove references to ib_reg_phsy_mr()
Peng Tao (8):
pnfs/flexfiles: LAYOUTSTATS ii_count should be ops instead of bytes
NFS41: make sure sending LAYOUTRETURN before close if marked so
NFS41/flexfiles: update inode after write finishes
NFS41: fix list splice type
NFS41: remove NFS_LAYOUT_ROC flag
NFS41/flexfiles: zero out DS write wcc
nfs42: decode_layoutstats does not need res parameter
nfs42: remove unused declaration
Trond Myklebust (58):
NFSv4.1/pnfs: Fix atomicity of commit list updates
NFSv4.2/pnfs: Use GFP_NOIO for layoutstat reporting in the writeback path
pNFS: Tighten up locking around DS commit buckets
NFSv4.1/pnfs: Remove redundant checks in pnfs_layoutgets_blocked()
NFSv4.1/pnfs: Fix serialisation of layout return and layoutget
NFSv4.1/pnfs: Don't prevent layoutgets when doing return-on-close
NFSv4.1/pnfs: Remove redundant lo->plh_block_lgets in layoutreturn
NFSv4.1/pnfs: Remove redundant check in pnfs_layoutgets_blocked()
NFSv4.1/pnfs: Remove redundant wakeup in pnfs_send_layoutreturn()
NFS: nfs_set_pgio_error sometimes misses errors
NFSv4.1/pNFS: Fix borken function _same_data_server_addrs_locked()
SUNRPC: Fix a thinko in xs_connect()
Merge tag 'nfs-rdma-for-4.3' of git://git.linux-nfs.org/projects/anna/nfs-rdma
Merge branch 'bugfixes'
Merge branch 'layoutfixes'
NFS: Don't let the ctime override attribute barriers.
SUNRPC: Drop double-underscores from __rpc_cmp_addr6()
NFS: Don't fsync twice for O_SYNC/IS_SYNC files
NFSv4.1/pnfs: Fix a close/delegreturn hang when return-on-close is set
NFSv4.1/pnfs: Play safe w.r.t. close() races when return-on-close is set
Revert "NFSv4: Remove incorrect check in can_open_delegated()"
SUNRPC: Allow sockets to do GFP_NOIO allocations
pNFS: Fix an unused variable warning in pnfs_roc_get_barrier
NFSv4: Enable delegated opens even when reboot recovery is pending
NFSv4.1/pnfs: Ensure the flexfiles layoutstats timers are consistent
NFSv4.1/pnfs Ensure flexfiles reports all connection related errors
NFSv4: Force a post-op attribute update when holding a delegation
NFSv4.1/pnfs: Add a tracepoint for return-on-close events
NFSv4: Add a tracepoint for CB_GETATTR
NFSv4: Add a tracepoint for CB_LAYOUTRECALL
NFSv4.1/flexfiles: Add refcounting to struct nfs4_ff_layout_mirror
NFSv4.1/flexfiles: Remove mirror backpointer to lseg.
NFSv4.1/flexfile: Ensure uniqueness of mirrors across layout segments
NFSv4.2/pnfs: Make the layoutstats timer configurable
NFSv4.1/pnfs Improve the packing of struct pnfs_layout_hdr
NFSv4.1/pnfs: Add sanity check for the layout range returned by the server
NFSv4.1/pnfs: Allow pNFS device drivers to customise layout segment insertion
NFSv4.1/flexfiles: Allow coalescing of new layout segments and existing ones
NFSv4.1/pNFS: pnfs_mark_matching_lsegs_return must notify of layout return
NFSv4.1/flexfiles: Fix a protocol error in layoutreturn
NFSv4.1/pnfs: Ensure layoutreturn reserves space for the opaque payload
SUNRPC: xs_reset_transport must mark the connection as disconnected
SUNRPC: Prevent SYN+SYNACK+RST storms
NFSv4.1/flexfiles: Don't mark the entire deviceid as bad for file errors
NFSv4.1: Fix a protocol issue with CLOSE stateids
NFSv4.1/pnfs: Don't ask for a read layout for an empty file.
NFSv4.1/pnfs: Handle LAYOUTGET return values correctly
NFSv4.1/pNFS: Don't request a minimal read layout beyond the end of file
NFSv4.1/flexfiles: Fix freeing of mirrors
NFSv4.1/flexfiles: Fix incorrect usage of pnfs_generic_mark_devid_invalid()
NFSv4.1/flexfiles: RW layouts are valid only if all mirrors are valid
NFSv4.1/flexfiles: Mark layout for return if the mirrors are invalid
NFSv4.1/flexfiles: Mark the layout for return in ff_layout_io_track_ds_error()
NFSv4.1/flexfiles: Clean up ff_layout_write_done_cb/ff_layout_commit_done_cb
NFS: Optimise away the close-to-open getattr if there is no cached data
Revert "NFS: Make close(2) asynchronous when closing NFS O_DIRECT files"
NFSv4: Express delegation limit in units of pages
NFSv4: Respect the server imposed limit on how many changes we may cache
kbuild test robot (1):
NFSv4.1/flexfile: ff_layout_remove_mirror can be static
Documentation/kernel-parameters.txt | 9 +
drivers/infiniband/core/verbs.c | 67 ----
.../staging/lustre/lnet/klnds/o2iblnd/o2iblnd.c | 251 +-----------
.../staging/lustre/lnet/klnds/o2iblnd/o2iblnd.h | 32 +-
.../staging/lustre/lnet/klnds/o2iblnd/o2iblnd_cb.c | 55 +--
.../lustre/lnet/klnds/o2iblnd/o2iblnd_modparams.c | 6 -
fs/nfs/blocklayout/blocklayout.h | 19 +-
fs/nfs/blocklayout/dev.c | 9 +-
fs/nfs/blocklayout/extent_tree.c | 19 +-
fs/nfs/callback.c | 4 -
fs/nfs/callback_proc.c | 9 +-
fs/nfs/client.c | 113 +-----
fs/nfs/delegation.c | 29 +-
fs/nfs/delegation.h | 3 +-
fs/nfs/dir.c | 20 +-
fs/nfs/file.c | 21 +-
fs/nfs/flexfilelayout/flexfilelayout.c | 424 ++++++++++++++-------
fs/nfs/flexfilelayout/flexfilelayout.h | 5 +-
fs/nfs/flexfilelayout/flexfilelayoutdev.c | 82 +++-
fs/nfs/inode.c | 61 +--
fs/nfs/internal.h | 20 +-
fs/nfs/nfs3xdr.c | 1 +
fs/nfs/nfs42.h | 2 -
fs/nfs/nfs42xdr.c | 5 +-
fs/nfs/nfs4_fs.h | 4 +-
fs/nfs/nfs4client.c | 5 +-
fs/nfs/nfs4file.c | 32 +-
fs/nfs/nfs4idmap.c | 14 +-
fs/nfs/nfs4proc.c | 136 ++++---
fs/nfs/nfs4state.c | 12 +-
fs/nfs/nfs4trace.h | 61 +++
fs/nfs/nfs4xdr.c | 75 +++-
fs/nfs/pagelist.c | 4 +-
fs/nfs/pnfs.c | 227 ++++++-----
fs/nfs/pnfs.h | 48 ++-
fs/nfs/pnfs_nfs.c | 88 +++--
fs/nfs/super.c | 7 +-
fs/nfs/write.c | 36 +-
fs/nfsd/blocklayoutxdr.c | 2 +-
fs/nfsd/blocklayoutxdr.h | 15 -
include/linux/nfs4.h | 18 +
include/linux/nfs_fs.h | 2 +-
include/linux/nfs_fs_sb.h | 5 +
include/linux/nfs_xdr.h | 8 +-
include/linux/sunrpc/addr.h | 27 +-
include/linux/sunrpc/auth.h | 8 +-
include/linux/sunrpc/xprtrdma.h | 2 +-
include/rdma/ib_verbs.h | 46 ---
include/uapi/linux/nfs4.h | 2 +-
net/sunrpc/auth_unix.c | 2 +-
net/sunrpc/xprtrdma/fmr_ops.c | 19 +
net/sunrpc/xprtrdma/frwr_ops.c | 5 +
net/sunrpc/xprtrdma/physical_ops.c | 25 +-
net/sunrpc/xprtrdma/rpc_rdma.c | 197 +++++-----
net/sunrpc/xprtrdma/transport.c | 77 ++--
net/sunrpc/xprtrdma/verbs.c | 234 ++++--------
net/sunrpc/xprtrdma/xprt_rdma.h | 27 +-
net/sunrpc/xprtsock.c | 18 +-
58 files changed, 1340 insertions(+), 1414 deletions(-)
--
Trond Myklebust
Linux NFS client maintainer, PrimaryData
trond.myklebust@primarydata.com
^ permalink raw reply [flat|nested] 25+ messages in thread
* Re: [GIT PULL] Please pull NFS client changes
2015-09-07 20:59 Trond Myklebust
@ 2015-09-08 1:59 ` Stephen Rothwell
2015-09-08 6:01 ` Christoph Hellwig
0 siblings, 1 reply; 25+ messages in thread
From: Stephen Rothwell @ 2015-09-08 1:59 UTC (permalink / raw)
To: Linus Torvalds
Cc: Trond Myklebust, Linux NFS Mailing List,
Linux Kernel Mailing List, Oleg Drokin, Doug Ledford
Hi Linus,
On Mon, 07 Sep 2015 16:59:04 -0400 Trond Myklebust <trond.myklebust@primarydata.com> wrote:
>
> The following changes since commit 74d33293e467df61de1b1d8b2fbe29e550dec33b:
>
> Linux 4.2-rc5 (2015-08-02 18:34:55 -0700)
>
> are available in the git repository at:
>
> git://git.linux-nfs.org/projects/trondmy/linux-nfs.git tags/nfs-for-4.3-1
>
> for you to fetch changes up to 5445b1fbd123420bffed5e629a420aa2a16bf849:
>
> NFSv4: Respect the server imposed limit on how many changes we may cache (2015-09-07 12:36:17 -0400)
This contains about 12 commits new since Sept 1 and the last 6 are only
appearing in linux-next today (though I did not do Friday and Monday's
linux-next). Not judging, just noting.
--
Cheers,
Stephen Rothwell sfr@canb.auug.org.au
^ permalink raw reply [flat|nested] 25+ messages in thread
* Re: [GIT PULL] Please pull NFS client changes
2015-09-08 1:59 ` Stephen Rothwell
@ 2015-09-08 6:01 ` Christoph Hellwig
2015-09-11 16:27 ` Christoph Hellwig
0 siblings, 1 reply; 25+ messages in thread
From: Christoph Hellwig @ 2015-09-08 6:01 UTC (permalink / raw)
To: Stephen Rothwell
Cc: Linus Torvalds, Trond Myklebust, Linux NFS Mailing List,
Linux Kernel Mailing List, Oleg Drokin, Doug Ledford
On Tue, Sep 08, 2015 at 11:59:00AM +1000, Stephen Rothwell wrote:
> This contains about 12 commits new since Sept 1 and the last 6 are only
> appearing in linux-next today (though I did not do Friday and Monday's
> linux-next). Not judging, just noting.
And one of tese recent commits causes a regression for block layouts
in xfstests generic/075. Still need to check which one.
Trond, I think it's really time the NFS client gets regular automated
tests at least against the Linux server for v3/4/4.1/pNFS - I'm finding
regressions pretty much every time I kick off a simple xfstests run.
^ permalink raw reply [flat|nested] 25+ messages in thread
* Re: [GIT PULL] Please pull NFS client changes
2015-09-08 6:01 ` Christoph Hellwig
@ 2015-09-11 16:27 ` Christoph Hellwig
2015-09-11 17:06 ` Trond Myklebust
0 siblings, 1 reply; 25+ messages in thread
From: Christoph Hellwig @ 2015-09-11 16:27 UTC (permalink / raw)
To: Stephen Rothwell
Cc: Linus Torvalds, Trond Myklebust, Linux NFS Mailing List,
Linux Kernel Mailing List, Oleg Drokin, Doug Ledford
On Mon, Sep 07, 2015 at 11:01:36PM -0700, Christoph Hellwig wrote:
> On Tue, Sep 08, 2015 at 11:59:00AM +1000, Stephen Rothwell wrote:
> > This contains about 12 commits new since Sept 1 and the last 6 are only
> > appearing in linux-next today (though I did not do Friday and Monday's
> > linux-next). Not judging, just noting.
>
> And one of tese recent commits causes a regression for block layouts
> in xfstests generic/075. Still need to check which one.
"NFSv4.1/pNFS: Don't request a minimal read layout beyond the end of file"
is the culprit, posted to the list for the first time and committed on
Aug 31.
^ permalink raw reply [flat|nested] 25+ messages in thread
* Re: [GIT PULL] Please pull NFS client changes
2015-09-11 16:27 ` Christoph Hellwig
@ 2015-09-11 17:06 ` Trond Myklebust
0 siblings, 0 replies; 25+ messages in thread
From: Trond Myklebust @ 2015-09-11 17:06 UTC (permalink / raw)
To: Christoph Hellwig
Cc: Stephen Rothwell, Linus Torvalds, Linux NFS Mailing List,
Linux Kernel Mailing List, Oleg Drokin, Doug Ledford
On Fri, Sep 11, 2015 at 12:27 PM, Christoph Hellwig <hch@infradead.org> wrote:
> On Mon, Sep 07, 2015 at 11:01:36PM -0700, Christoph Hellwig wrote:
>> On Tue, Sep 08, 2015 at 11:59:00AM +1000, Stephen Rothwell wrote:
>> > This contains about 12 commits new since Sept 1 and the last 6 are only
>> > appearing in linux-next today (though I did not do Friday and Monday's
>> > linux-next). Not judging, just noting.
>>
>> And one of tese recent commits causes a regression for block layouts
>> in xfstests generic/075. Still need to check which one.
>
> "NFSv4.1/pNFS: Don't request a minimal read layout beyond the end of file"
>
> is the culprit, posted to the list for the first time and committed on
> Aug 31.
That looks like it is tickling a server protocol bug.
The minimum length is just that; a minimum. If the server wants the
layout to be block aligned, then it is supposed to adjust the returned
offset + length values so that they cover the range described by the
offset+minimum length (see table 13 on
https://tools.ietf.org/html/rfc5661#page-540).
The server is only supposed to fail the LAYOUTGET request if it is
completely unable to meet those requirements. Furthermore, it is
supposed to return either NFS4ERR_BADLAYOUT or NFS4ERR_LAYOUTTRYLATER
(depending on what the value of the minimum layout was); as far as I
can see, the current code is returning NFS4ERR_LAYOUTUNAVAILABLE.
Cheers,
Trond
^ permalink raw reply [flat|nested] 25+ messages in thread
* [GIT PULL] Please pull NFS client changes
@ 2014-12-08 3:09 Trond Myklebust
0 siblings, 0 replies; 25+ messages in thread
From: Trond Myklebust @ 2014-12-08 3:09 UTC (permalink / raw)
To: Linus Torvalds; +Cc: Linux NFS Mailing List, Linux Kernel mailing list
[-- Attachment #1: Type: text/plain, Size: 6523 bytes --]
Hi Linus,
The following changes since commit 5d01410fe4d92081f349b013a2e7a95429e4f2c9:
Linux 3.18-rc6 (2014-11-23 15:25:20 -0800)
are available in the git repository at:
git://git.linux-nfs.org/projects/trondmy/linux-nfs.git tags/nfs-for-3.19-1
for you to fetch changes up to 388f0c776781fe64ce951701bfe712b2182a31f2:
sunrpc: add a debugfs rpc_xprt directory with an info file in it (2014-11-27 13:14:52 -0500)
----------------------------------------------------------------
NFS client updates for Linux 3.19
Highlights include:
Features:
- NFSv4.2 client support for hole punching and preallocation.
- Further RPC/RDMA client improvements.
- Add more RPC transport debugging tracepoints.
- Add RPC debugging tools in debugfs.
Bugfixes:
- Stable fix for layoutget error handling
- Fix a change in COMMIT behaviour resulting from the recent io code updates
----------------------------------------------------------------
Anna Schumaker (3):
NFS: Use nfs_server_capable() for checknig NFS_CAP_SEEK
nfs: Add ALLOCATE support
nfs: Add DEALLOCATE support
Christoph Hellwig (1):
pnfs/blocklayout: fix end calculation in pnfs_num_cont_bytes
Chuck Lever (10):
xprtrdma: Return an errno from rpcrdma_register_external()
xprtrdma: Cap req_cqinit
xprtrdma: unmap all FMRs during transport disconnect
xprtrdma: Refactor tasklet scheduling
xprtrdma: Re-write rpcrdma_flush_cqs()
xprtrdma: Enable pad optimization
xprtrdma: Display async errors
SUNRPC: serialize iostats updates
NFS: SETCLIENTID XDR buffer sizes are incorrect
NFS: Clean up nfs4_init_callback()
Jan Kara (1):
nfs: Remove dead case from nfs4_map_errors()
Jeff Layton (8):
sunrpc: add some tracepoints in svc_rqst handling functions
sunrpc: add new tracepoints in xprt handling code
sunrpc: add tracepoints in xs_tcp_data_recv
lockd: eliminate LOCKD_DEBUG
sunrpc: eliminate RPC_DEBUG
sunrpc: eliminate RPC_TRACEPOINTS
sunrpc: add debugfs file for displaying client rpc_task queue
sunrpc: add a debugfs rpc_xprt directory with an info file in it
Li RongQing (2):
nfs: replace nfs_add_stats with nfs_inc_stats when add one
nfs: define nfs_inc_fscache_stats and using it as possible
Markus Elfring (1):
NFS: Deletion of unnecessary checks before the function call "nfs_put_client"
Peng Tao (1):
nfs41: fix nfs4_proc_layoutget error handling
Trond Myklebust (2):
Merge tag 'nfs-cel-for-3.19' of git://git.linux-nfs.org/projects/anna/nfs-rdma into linux-next
Merge tag 'nfs-rdma-for-3.19' of git://git.linux-nfs.org/projects/anna/nfs-rdma into linux-next
Weston Andros Adamson (1):
NFS: fix subtle change in COMMIT behavior
fs/lockd/svclock.c | 2 +-
fs/nfs/blocklayout/blocklayout.c | 2 +-
fs/nfs/callback_proc.c | 2 +-
fs/nfs/filelayout/filelayoutdev.c | 3 +-
fs/nfs/fscache.c | 24 +--
fs/nfs/inode.c | 9 +-
fs/nfs/iostat.h | 5 +
fs/nfs/nfs42.h | 2 +
fs/nfs/nfs42proc.c | 77 ++++++++-
fs/nfs/nfs42xdr.c | 139 +++++++++++++++
fs/nfs/nfs4_fs.h | 1 +
fs/nfs/nfs4client.c | 46 +++--
fs/nfs/nfs4file.c | 31 ++++
fs/nfs/nfs4proc.c | 12 +-
fs/nfs/nfs4xdr.c | 12 +-
fs/nfs/pagelist.c | 11 +-
fs/nfs/read.c | 2 +-
fs/nfs/write.c | 19 ++-
include/linux/lockd/debug.h | 6 +-
include/linux/nfs4.h | 2 +
include/linux/nfs_fs.h | 4 +-
include/linux/nfs_fs_sb.h | 2 +
include/linux/nfs_xdr.h | 14 ++
include/linux/sunrpc/auth.h | 2 +-
include/linux/sunrpc/clnt.h | 4 +
include/linux/sunrpc/debug.h | 64 +++++--
include/linux/sunrpc/metrics.h | 3 +
include/linux/sunrpc/sched.h | 8 +-
include/linux/sunrpc/xprt.h | 3 +
include/linux/sunrpc/xprtsock.h | 59 +++++++
include/trace/events/sunrpc.h | 160 +++++++++++++++++
include/uapi/linux/nfsd/debug.h | 2 +-
net/sunrpc/Kconfig | 1 +
net/sunrpc/Makefile | 1 +
net/sunrpc/auth.c | 4 +-
net/sunrpc/auth_generic.c | 2 +-
net/sunrpc/auth_gss/auth_gss.c | 2 +-
net/sunrpc/auth_gss/gss_generic_token.c | 2 +-
net/sunrpc/auth_gss/gss_krb5_crypto.c | 2 +-
net/sunrpc/auth_gss/gss_krb5_keys.c | 2 +-
net/sunrpc/auth_gss/gss_krb5_mech.c | 2 +-
net/sunrpc/auth_gss/gss_krb5_seal.c | 2 +-
net/sunrpc/auth_gss/gss_krb5_seqnum.c | 2 +-
net/sunrpc/auth_gss/gss_krb5_unseal.c | 2 +-
net/sunrpc/auth_gss/gss_krb5_wrap.c | 2 +-
net/sunrpc/auth_gss/gss_mech_switch.c | 2 +-
net/sunrpc/auth_gss/gss_rpc_xdr.h | 2 +-
net/sunrpc/auth_gss/svcauth_gss.c | 2 +-
net/sunrpc/auth_null.c | 4 +-
net/sunrpc/auth_unix.c | 2 +-
net/sunrpc/backchannel_rqst.c | 2 +-
net/sunrpc/clnt.c | 16 +-
net/sunrpc/debugfs.c | 292 ++++++++++++++++++++++++++++++++
net/sunrpc/rpcb_clnt.c | 2 +-
net/sunrpc/sched.c | 4 +-
net/sunrpc/stats.c | 21 ++-
net/sunrpc/sunrpc_syms.c | 12 +-
net/sunrpc/svc.c | 23 +--
net/sunrpc/svc_xprt.c | 31 ++--
net/sunrpc/sysctl.c | 2 +-
net/sunrpc/xprt.c | 19 ++-
net/sunrpc/xprtrdma/rpc_rdma.c | 4 +-
net/sunrpc/xprtrdma/transport.c | 12 +-
net/sunrpc/xprtrdma/verbs.c | 122 ++++++++++---
net/sunrpc/xprtrdma/xprt_rdma.h | 6 +
net/sunrpc/xprtsock.c | 77 ++-------
66 files changed, 1171 insertions(+), 244 deletions(-)
create mode 100644 net/sunrpc/debugfs.c
--
Trond Myklebust
Linux NFS client maintainer, PrimaryData
trond.myklebust@primarydata.com
[-- Attachment #2: This is a digitally signed message part --]
[-- Type: application/pgp-signature, Size: 819 bytes --]
^ permalink raw reply [flat|nested] 25+ messages in thread
* [GIT PULL] Please pull NFS client changes
@ 2014-10-06 13:03 Trond Myklebust
0 siblings, 0 replies; 25+ messages in thread
From: Trond Myklebust @ 2014-10-06 13:03 UTC (permalink / raw)
To: Linus Torvalds; +Cc: Linux NFS Mailing List, Linux Kernel mailing list
Hi Linus,
The following changes since commit cd9288ffaea4359d5cfe2b8d264911506aed26a4:
NFSv4: Fix another bug in the close/open_downgrade code (2014-09-18 13:04:22 -0400)
are available in the git repository at:
git://git.linux-nfs.org/projects/trondmy/linux-nfs.git tags/nfs-for-3.18-1
for you to fetch changes up to 72c23f0819977d37924af92a42a9b7fbfd1c95d8:
Merge branch 'bugfixes' into linux-next (2014-09-30 17:21:41 -0400)
Please note the presence of the following 2 "non-NFS" patches which are
needed for Neil's nfs_release_page() deadlock avoidance:
cbbce8220949: SCHED: add some "wait..on_bit...timeout()" interfaces.
Acked-by: Peter Zijlstra (Intel) <peterz@infradead.org>
Acked-by: Ingo Molnar <mingo@kernel.org>
and
a4796e37c12e: MM: export page_wakeup functions
Acked-by: Andrew Morton <akpm@linux-foundation.org>
Cheers
Trond
----------------------------------------------------------------
NFS client updates for Linux 3.18
Highlights include:
Stable fixes:
- fix an NFSv4.1 state renewal regression
- fix open/lock state recovery error handling
- fix lock recovery when CREATE_SESSION/SETCLIENTID_CONFIRM fails
- fix statd when reconnection fails
- Don't wake tasks during connection abort
- Don't start reboot recovery if lease check fails
- fix duplicate proc entries
Features:
- pNFS block driver fixes and clean ups from Christoph
- More code cleanups from Anna
- Improve mmap() writeback performance
- Replace use of PF_TRANS with a more generic mechanism for avoiding
deadlocks in nfs_release_page
----------------------------------------------------------------
Andy Adamson (1):
NFSv4.1: Fix an NFSv4.1 state renewal regression
Anna Schumaker (5):
NFS: Clear up state owner lock usage
NFS: Unconditionally enable commit code
NFS: Move v3 declarations out of internal.h
NFS: Remove v3 not compiled check from validate_mount_data()
NFS: Move NFS v3 acl functions to nfs3_fs.h
Benjamin Coddington (2):
SUNRPC: Don't wake tasks during connection abort
lockd: Try to reconnect if statd has moved
Chris Perl (1):
rpc: xs_bind - do not bind when requesting a random ephemeral port
Christoph Hellwig (32):
nfs: cap request size to fit a kmalloced page array
pnfs: do not pass uninitialized lsegs to ->free_lseg
pnfs: don't check sequence on new stateids in layoutget
pnfs: retry after a bad stateid error from layoutget
pnfs: avoid using stale stateids after layoutreturn
pnfs: allow splicing pre-encoded pages into the layoutcommit args
pnfs/blocklayout: reject pnfs blocksize larger than page size
pnfs/blocklayout: improve GETDEVICEINFO error reporting
pnfs/blocklayout: plug block queues
pnfs/blocklayout: correctly decrement extent length
pnfs: force a layout commit when encountering busy segments during recall
pnfs: add flag to force read-modify-write in ->write_begin
pnfs: add return_range method
pnfs/blocklayout: remove read-modify-write handling in bl_write_pagelist
pnfs/blocklayout: don't set pages uptodate
pnfs/blocklayout: rewrite extent tracking
pnfs/blocklayout: implement the return_range method
pnfs/blocklayout: return layouts on setattr
pnfs: factor GETDEVICEINFO implementations
pnfs: add a common GETDEVICELIST implementation
pnfs: add a nfs4_get_deviceid helper
pnfs/blocklayout: use the device id cache
nfs: setattr can only change regular file sizes
pnfs/blocklayout: remove some debugging
pnfs/objlayout: fix endianess annotation in objio_alloc_deviceid_node
pnfs: remove GETDEVICELIST implementation
pnfs/blocklayout: allocate separate pages for the layoutcommit payload
pnfs/blocklayout: move extent processing to blocklayout.c
pnfs/blocklayout: refactor extent processing
pnfs/blocklayout: move all rpc_pipefs related code into a single file
pnfs/blocklayout: in-kernel GETDEVICEINFO XDR parsing
pnfs: enable CB_NOTIFY_DEVICEID support
David Howells (1):
NFS: Fabricate fscache server index key correctly
Fabian Frederick (1):
nfs: fix duplicate proc entries
Jason Baron (2):
rpc: return sent and err from xs_sendpages()
rpc: Add -EPERM processing for xs_udp_send_request()
Jeff Layton (2):
nfs: fix RCU cl_xprt handling in nfs_swap_activate/deactivate
nfs: add __acquires and __releases annotations to seqfile start/stop routines
NeilBrown (7):
NFSv4: use exponential retry on NFS4ERR_DELAY for async requests.
NFS: don't use STABLE writes during writeback.
SCHED: add some "wait..on_bit...timeout()" interfaces.
MM: export page_wakeup functions
NFS: avoid deadlocks with loop-back mounted NFS filesystems.
NFS: avoid waiting at all in nfs_release_page when congested.
NFS/SUNRPC: Remove other deadlock-avoidance mechanisms in nfs_release_page()
Olga Kornievskaia (1):
Fixing lease renewal
Peng Tao (3):
nfs41: add a helper function to set layoutcommit after commit
nfs/filelayout: set layoutcommit depending on write verifier
nfs41: change PNFS_LAYOUTRET_ON_SETATTR to only return on truncation to smaller size
Stephen Rothwell (1):
pnfs/blocklayout: include vmalloc.h for __vmalloc
Trond Myklebust (8):
NFS: Fix a compile warning when !(CONFIG_NFS_V3 || CONFIG_NFS_V4)
pNFS/blocklayout: Remove a couple of unused variables
pnfs/blocklayout: Fix a 64-bit division/remainder issue in bl_map_stripe
NFSv3: Fix missing includes of nfs3_fs.h
SUNRPC: Add missing support for RPC_CLNT_CREATE_NO_RETRANS_TIMEOUT
NFSv4: Fix lock recovery when CREATE_SESSION/SETCLIENTID_CONFIRM fails
NFSv4: fix open/lock state recovery error handling
Merge branch 'bugfixes' into linux-next
fs/lockd/mon.c | 6 +
fs/nfs/blocklayout/Makefile | 3 +-
fs/nfs/blocklayout/blocklayout.c | 1386 +++++++++++------------------------
fs/nfs/blocklayout/blocklayout.h | 213 +++---
fs/nfs/blocklayout/blocklayoutdev.c | 384 ----------
fs/nfs/blocklayout/blocklayoutdm.c | 108 ---
fs/nfs/blocklayout/dev.c | 363 +++++++++
fs/nfs/blocklayout/extent_tree.c | 602 +++++++++++++++
fs/nfs/blocklayout/extents.c | 908 -----------------------
fs/nfs/blocklayout/rpc_pipefs.c | 285 +++++++
fs/nfs/callback_proc.c | 23 +-
fs/nfs/client.c | 6 +-
fs/nfs/direct.c | 14 -
fs/nfs/file.c | 52 +-
fs/nfs/filelayout/filelayout.c | 34 +-
fs/nfs/filelayout/filelayout.h | 7 +-
fs/nfs/filelayout/filelayoutdev.c | 108 +--
fs/nfs/fscache-index.c | 3 +-
fs/nfs/inode.c | 4 +-
fs/nfs/internal.h | 7 -
fs/nfs/nfs3_fs.h | 34 +
fs/nfs/nfs3acl.c | 1 +
fs/nfs/nfs3client.c | 1 +
fs/nfs/nfs3proc.c | 1 +
fs/nfs/nfs3super.c | 1 +
fs/nfs/nfs4proc.c | 138 ++--
fs/nfs/nfs4renewd.c | 12 +-
fs/nfs/nfs4state.c | 18 +-
fs/nfs/nfs4xdr.c | 179 +----
fs/nfs/objlayout/objio_osd.c | 113 ++-
fs/nfs/objlayout/objlayout.c | 70 --
fs/nfs/objlayout/objlayout.h | 5 -
fs/nfs/pagelist.c | 8 +
fs/nfs/pnfs.c | 105 ++-
fs/nfs/pnfs.h | 50 +-
fs/nfs/pnfs_dev.c | 150 ++--
fs/nfs/super.c | 11 -
fs/nfs/write.c | 150 ++--
include/linux/nfs_fs.h | 41 --
include/linux/nfs_xdr.h | 17 +-
include/linux/pagemap.h | 12 +-
include/linux/sunrpc/xprt.h | 1 +
include/linux/wait.h | 5 +-
kernel/sched/wait.c | 36 +
mm/filemap.c | 21 +-
net/sunrpc/clnt.c | 5 +
net/sunrpc/sched.c | 2 -
net/sunrpc/xprtrdma/transport.c | 2 -
net/sunrpc/xprtsock.c | 121 +--
49 files changed, 2520 insertions(+), 3306 deletions(-)
delete mode 100644 fs/nfs/blocklayout/blocklayoutdev.c
delete mode 100644 fs/nfs/blocklayout/blocklayoutdm.c
create mode 100644 fs/nfs/blocklayout/dev.c
create mode 100644 fs/nfs/blocklayout/extent_tree.c
delete mode 100644 fs/nfs/blocklayout/extents.c
create mode 100644 fs/nfs/blocklayout/rpc_pipefs.c
create mode 100644 fs/nfs/nfs3_fs.h
--
Trond Myklebust
Linux NFS client maintainer, PrimaryData
trond.myklebust@primarydata.com
^ permalink raw reply [flat|nested] 25+ messages in thread
* [GIT PULL] Please pull NFS client changes
@ 2014-07-19 20:07 Trond Myklebust
0 siblings, 0 replies; 25+ messages in thread
From: Trond Myklebust @ 2014-07-19 20:07 UTC (permalink / raw)
To: Linus Torvalds; +Cc: Linux NFS Mailing List, Linux Kernel mailing list
[-- Attachment #1: Type: text/plain, Size: 2326 bytes --]
Hi Linus,
Apologies for the relative lateness of this pull request, however the
commits fix some issues with the NFS read/write code updates in 3.16-rc1
that can cause serious Oopsing when using small r/wsize. The delay was
mainly due to extra testing to make sure that the fixes behave
correctly.
The following changes since commit 66b068604903849c5dee3842eb72564064c64c72:
NFSv4: test SECINFO RPC_AUTH_GSS pseudoflavors for support (2014-06-24 18:46:58 -0400)
are available in the git repository at:
git://git.linux-nfs.org/projects/trondmy/linux-nfs.git tags/nfs-for-3.16-3
for you to fetch changes up to f563b89b182594f827b4100bd34f916339785a77:
NFS: Don't reset pg_moreio in __nfs_pageio_add_request (2014-07-13 15:18:44 -0400)
----------------------------------------------------------------
NFS client fixes for Linux 3.16
Highlights include;
- Stable fix for an NFSv3 posix ACL regression
- Multiple fixes for regressions to the NFS generic read/write code
- Fix page splitting bugs that come into play when a small rsize/wsize
read/write needs to be sent again (due to error conditions or page
redirty).
- Fix nfs_wb_page_cancel, which is called by the "invalidatepage" method
- Fix 2 compile warnings about unused variables.
- Fix a performance issue affecting unstable writes.
----------------------------------------------------------------
Christoph Hellwig (1):
nfs: only show Posix ACLs in listxattr if actually present
Trond Myklebust (2):
NFS: Remove 2 unused variables
NFS: Don't reset pg_moreio in __nfs_pageio_add_request
Weston Andros Adamson (5):
nfs: mark nfs_page reqs with flag for extra ref
nfs: nfs_page should take a ref on the head req
nfs: change find_request to find_head_request
nfs: handle multiple reqs in nfs_page_async_flush
nfs: handle multiple reqs in nfs_wb_page_cancel
fs/nfs/direct.c | 2 -
fs/nfs/internal.h | 1 +
fs/nfs/nfs3acl.c | 43 +++++++
fs/nfs/nfs3proc.c | 4 +-
fs/nfs/pagelist.c | 20 +++-
fs/nfs/write.c | 335 +++++++++++++++++++++++++++++++++++++++++++++---------
6 files changed, 343 insertions(+), 62 deletions(-)
--
Trond Myklebust
Linux NFS client maintainer, PrimaryData
trond.myklebust@primarydata.com
[-- Attachment #2: This is a digitally signed message part --]
[-- Type: application/pgp-signature, Size: 819 bytes --]
^ permalink raw reply [flat|nested] 25+ messages in thread
* [GIT PULL] Please pull NFS client changes
@ 2014-01-27 16:49 Trond Myklebust
0 siblings, 0 replies; 25+ messages in thread
From: Trond Myklebust @ 2014-01-27 16:49 UTC (permalink / raw)
To: Torvalds Linus; +Cc: Linux NFS Mailing List, Linux Kernel mailing list
[-- Attachment #1: Type: text/plain, Size: 4627 bytes --]
Hi Linus,
The following changes since commit 374b105797c3d4f29c685f3be535c35f5689b30e:
Linux 3.13-rc3 (2013-12-06 09:34:04 -0800)
are available in the git repository at:
git://git.linux-nfs.org/projects/trondmy/linux-nfs.git tags/nfs-for-3.14-1
for you to fetch changes up to ed7e5423014ad89720fcf315c0b73f2c5d0c7bd2:
pnfs: Proper delay for NFS4ERR_RECALLCONFLICT in layout_get_done (2014-01-22 18:10:49 -0700)
----------------------------------------------------------------
NFS client updates for Linux 3.14
Highlights include:
- Stable fix for an infinite loop in RPC state machine
- Stable fix for a use after free situation in the NFSv4 trunking discovery
- Stable fix for error handling in the NFSv4 trunking discovery
- Stable fix for the page write update code
- Stable fix for the NFSv4.1 mount time security negotiation
- Stable fix for the NFSv4 open code.
- O_DIRECT locking fixes
- fix an Oops in the pnfs file commit code
- RPC layer needs finer grained handling of connection errors
- More RPC GSS upcall fixes
----------------------------------------------------------------
Alexander Aring (1):
nfs: fix dead code of ipv6_addr_scope
Boaz Harrosh (1):
pnfs: Proper delay for NFS4ERR_RECALLCONFLICT in layout_get_done
Christoph Hellwig (7):
nfs: fix size updates for aio writes
nfs: defer inode_dio_done call until size update is done
nfs: increment i_dio_count for reads, too
nfs: merge nfs_direct_read into nfs_file_direct_read
nfs: merge nfs_direct_write into nfs_file_direct_write
nfs: take i_mutex during direct I/O reads
nfs: page cache invalidation for dio
Jeff Layton (6):
sunrpc: create a new dummy pipe for gssd to hold open
sunrpc: replace sunrpc_net->gssd_running flag with a more reliable check
nfs: check if gssd is running before attempting to use krb5i auth in SETCLIENTID call
rpc_pipe: remove the clntXX dir if creating the pipe fails
sunrpc: add an "info" file for the dummy gssd pipe
rpc_pipe: fix cleanup of dummy gssd directory when notification fails
Niels de Vos (1):
NFS: dprintk() should not print negative fileids and inode numbers
Scott Mayhew (1):
nfs: always make sure page is up-to-date before extending a write to cover the entire page
Toralf Förster (1):
point to the right include file in a comment (left over from a9004abc3)
Trond Myklebust (8):
NFSv4: OPEN must handle the NFS4ERR_IO return code correctly
SUNRPC: Ensure xprt_connect_status handles all potential connection errors
SUNRPC: Handle connect errors ECONNABORTED and EHOSTUNREACH
SUNRPC: Report connection error values to rpc_tasks on the pending queue
SUNRPC: Add tracepoint for socket errors
NFSv4.1: Don't trust attributes if a pNFS LAYOUTCOMMIT is outstanding
NFSv4.1: Fix a race in nfs4_write_inode
NFSv4.1: Handle errors correctly in nfs41_walk_client_list
Weston Andros Adamson (4):
sunrpc: Fix infinite loop in RPC state machine
nfs4.1: properly handle ENOTSUP in SECINFO_NO_NAME
nfs4: fix discover_server_trunking use after free
pnfs: fix BUG in filelayout_recover_commit_reqs
fs/nfs/dir.c | 18 +--
fs/nfs/direct.c | 279 ++++++++++++++++++++-----------------
fs/nfs/file.c | 6 +-
fs/nfs/inode.c | 48 ++++---
fs/nfs/nfs3acl.c | 4 +-
fs/nfs/nfs4client.c | 25 ++--
fs/nfs/nfs4filelayout.c | 16 +--
fs/nfs/nfs4filelayoutdev.c | 2 +-
fs/nfs/nfs4proc.c | 43 ++++--
fs/nfs/nfs4state.c | 4 +-
fs/nfs/nfs4super.c | 14 +-
fs/nfs/nfs4xdr.c | 47 ++++---
fs/nfs/pnfs.c | 67 ++++-----
fs/nfs/pnfs.h | 16 +++
fs/nfs/read.c | 12 +-
fs/nfs/write.c | 19 +--
include/linux/sunrpc/rpc_pipe_fs.h | 5 +-
include/trace/events/sunrpc.h | 1 +
net/sunrpc/auth_gss/auth_gss.c | 17 +--
net/sunrpc/clnt.c | 15 +-
net/sunrpc/netns.h | 3 +-
net/sunrpc/rpc_pipe.c | 169 +++++++++++++++++++++-
net/sunrpc/sunrpc_syms.c | 8 +-
net/sunrpc/xprt.c | 5 +
net/sunrpc/xprtsock.c | 42 +++++-
25 files changed, 597 insertions(+), 288 deletions(-)
--
Trond Myklebust
Linux NFS client maintainer
[-- Attachment #2: This is a digitally signed message part --]
[-- Type: application/pgp-signature, Size: 819 bytes --]
^ permalink raw reply [flat|nested] 25+ messages in thread
* [GIT PULL] Please pull NFS client changes
@ 2011-10-25 12:25 Trond Myklebust
0 siblings, 0 replies; 25+ messages in thread
From: Trond Myklebust @ 2011-10-25 12:25 UTC (permalink / raw)
To: Linus Torvalds; +Cc: linux-nfs, linux-kernel
Hi Linus,
Please pull from the "nfs-for-3.2" branch of the repository at
git pull git://git.linux-nfs.org/projects/trondmy/linux-nfs.git nfs-for-3.2
This will update the following files through the appended changesets.
Cheers,
Trond
----
fs/nfs/blocklayout/blocklayout.c | 58 ++++++++++++----------
fs/nfs/blocklayout/blocklayout.h | 4 +-
fs/nfs/blocklayout/blocklayoutdev.c | 35 +++----------
fs/nfs/client.c | 11 +++-
fs/nfs/delegation.c | 2 +-
fs/nfs/fscache-index.c | 4 +-
fs/nfs/idmap.c | 25 +---------
fs/nfs/inode.c | 16 +++---
fs/nfs/internal.h | 10 ----
fs/nfs/nfs4filelayout.c | 33 +++----------
fs/nfs/nfs4proc.c | 93 +++++++++++++---------------------
fs/nfs/pnfs.c | 52 ++++++++++----------
fs/nfs/pnfs.h | 5 +-
fs/nfs/read.c | 40 +++++++--------
fs/nfs/super.c | 17 ++++--
fs/nfs/unlink.c | 4 +-
fs/nfs/write.c | 73 ++++++++++++++++-----------
include/linux/nfs_fs.h | 1 -
include/linux/nfs_page.h | 1 +
include/linux/nfs_xdr.h | 5 --
include/linux/sunrpc/clnt.h | 3 +-
include/linux/sunrpc/rpc_pipe_fs.h | 2 +
net/sunrpc/addr.c | 6 +-
net/sunrpc/auth_gss/auth_gss.c | 24 +--------
net/sunrpc/clnt.c | 4 +-
net/sunrpc/rpc_pipe.c | 20 ++++++++
net/sunrpc/rpcb_clnt.c | 6 +-
27 files changed, 242 insertions(+), 312 deletions(-)
commit 940aab490215424a269f93d2eba2794fc8b3e269
Author: Malahal Naineni <malahal@us.ibm.com>
Date: Tue Sep 20 17:27:14 2011 -0700
Check validity of cl_rpcclient in nfs_server_list_show
As soon as the nfs_client gets created, its cl_rpcclient is set to
ERR_PTR(-EINVAL). The rpc client structure is allocated later. Check
if the client is ready before using the cl_rpcclient pointer.
Signed-off-by: Malahal Naineni <malahal@us.ibm.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit b6ee8cd2642f6d822dd1a4ba62298b65ff99b72e
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date: Wed Oct 19 12:17:29 2011 -0700
NFS: Get rid of the nfs_rdata_mempool
We don't need a mempool in order to guarantee reliable NFS read performance.
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit fba730050d1246d0e6ef44e026e0b584732fec2b
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date: Wed Oct 19 12:17:29 2011 -0700
NFS: Don't rely on PageError in nfs_readpage_release_partial
Don't rely on the PageError flag to tell us if one of the partial reads of
the page failed. Instead, replace that with a dedicated flag in the
struct nfs_page.
Then clean out redundant uses of the PageError flag: the VM no longer
checks it for reads.
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit fbb5a9abf0d589e9471dc93b18025b7b921d22c9
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date: Wed Oct 19 12:17:29 2011 -0700
NFS: Get rid of unnecessary calls to ClearPageError() in read code
The generic file read code does that for us anyway.
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit d00c5d43866720963a265fa3129f3203cac35b8e
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date: Wed Oct 19 12:17:29 2011 -0700
NFS: Get rid of nfs_restart_rpc()
It can trivially be replaced with rpc_restart_call_prepare.
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit b8ef70639b609c5d12c618f1d9ffae6ac13aebe3
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date: Wed Oct 19 12:17:29 2011 -0700
NFS: Get rid of the unused nfs_write_data->flags field
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit a1940805d0636c6cdf37636f55b43b9681d53e73
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date: Wed Oct 19 12:17:29 2011 -0700
NFS: Get rid of the unused nfs_read_data->flags field
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 08ef7bd3bc04261d14d570ac7eaac3eac947b1ba
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date: Tue Oct 18 16:11:49 2011 -0700
NFSv4: Translate NFS4ERR_BADNAME into ENOENT when applied to a lookup
Both LOOKUP and OPEN operations may return NFS4ERR_BADNAME if we send a
an invalid name as a filename argument. As far as the application is
concerned, it just has to know that the file doesn't exist, and so
ENOENT would be the appropriate reply. We should only return EINVAL
if the filename is being used to _create_ a new object on the
remote filesystem.
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 0c2e53f11a6dae9e3af5f50f5ad0382e7c3e0cfa
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date: Tue Oct 18 16:11:22 2011 -0700
NFS: Remove the unused "lookupfh()" version of nfs4_proc_lookup()
...and also remove the associated nfs_v4_clientops entry.
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit a9a4a87a5942e9271523197a90aaa82349c818fb
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date: Mon Oct 17 16:08:46 2011 -0700
NFS: Use the inode->i_version to cache NFSv4 change attribute information
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 919066d690541f4bd727b0e0fc2f7a20a7e3b3a7
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date: Mon Oct 17 16:08:10 2011 -0700
SUNRPC: Remove unnecessary export of rpc_sockaddr2uaddr
It is only used internally by the RPC code.
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit d77385f23830ee6c400569bac8b37e6eb3b7d360
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date: Mon Oct 17 16:08:10 2011 -0700
SUNRPC: Fix rpc_sockaddr2uaddr
rpc_sockaddr2uaddr is only used by net/sunrpc/rpcb_clnt.c, where
it is used in a non-blockable context in at least one case.
Add non-blocking capability by adding a gfp_t argument
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 45402c38eec740f52422aafc92937c6a4a8c8c0e
Author: H Hartley Sweeten <hartleys@visionengravers.com>
Date: Fri Sep 2 14:39:12 2011 -0700
nfs/super.c: local functions should be static
commit ae50c0b5 "pnfs: client stats" added additional information to
the output of /proc/self/mountstats. The new functions introduced are
only used in this file and should be marked static.
If CONFIG_NFS_V4_1 is not defined, empty stub functions are used. If
CONFIG_NFS_V4 is not defined these stub functions are not used at all.
Adding static for the functions results in compile warnings:
fs/nfs/super.c:743: warning: 'show_sessions' defined but not used
fs/nfs/super.c:756: warning: 'show_pnfs' defined but not used
Fix this by adding a #ifdef CONFIG_NFS_V4 guard around the two
show_ functions.
Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com>
Cc: Trond Myklebust <Trond.Myklebust@netapp.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 7542274519b3ba87555410c66e8356ac1e3bc9b3
Author: Peng Tao <bergwolf@gmail.com>
Date: Thu Sep 22 21:50:17 2011 -0400
pnfsblock: fix writeback deadlock
We should check if the sector is already initialized before
trying to grab the page from page cache. Otherwise when two
pages of the same block are written back by two threads each
calling from writepage_locked, it can cause deadlock like bellow.
[ 1080.972099] INFO: task kswapd0:25 blocked for more than 120 seconds.
[ 1080.972377] "echo 0 > /proc/sys/kernel/hung_task_timeout_secs" disables this message.
[ 1080.972812] kswapd0 D ffff88000c4926c0 0 25 2 0x00000000
[ 1080.972816] ffff88000df276b0 0000000000000046 ffff88000df27640 ffffffff81013ba7
[ 1080.972821] ffff88000c492310 ffff88000df27fd8 ffff88000df27fd8 00000000001d3440
[ 1080.972824] ffff88000c378000 ffff88000c492310 ffff8800175d3d40 ffff880017fc75a8
[ 1080.972828] Call Trace:
[ 1080.972860] [<ffffffff81013ba7>] ? read_tsc+0x9/0x19
[ 1080.972877] [<ffffffff810e0b23>] ? lock_page+0x2b/0x2b
[ 1080.972899] [<ffffffff81475a1d>] io_schedule+0x63/0x7e
[ 1080.972902] [<ffffffff810e0b31>] sleep_on_page+0xe/0x12
[ 1080.972905] [<ffffffff81475fe8>] __wait_on_bit_lock+0x46/0x8f
[ 1080.972916] [<ffffffff810822d7>] ? lock_release_holdtime.part.7+0x6b/0x72
[ 1080.972919] [<ffffffff810e0af6>] __lock_page+0x66/0x68
[ 1080.972928] [<ffffffff81072705>] ? autoremove_wake_function+0x3d/0x3d
[ 1080.972932] [<ffffffff810e0b1f>] lock_page+0x27/0x2b
[ 1080.972934] [<ffffffff810e0bcf>] find_lock_page+0x34/0x57
[ 1080.972937] [<ffffffff810e1738>] find_or_create_page+0x34/0x8a
[ 1080.972947] [<ffffffffa034245b>] bl_write_pagelist+0x205/0x6da [blocklayoutdriver]
[ 1080.972951] [<ffffffffa034145d>] ? bl_free_lseg+0x38/0x38 [blocklayoutdriver]
[ 1080.972995] [<ffffffffa02e27b9>] ? nfs_write_rpcsetup+0x118/0x123 [nfs]
[ 1080.973033] [<ffffffffa030246b>] pnfs_generic_pg_writepages+0x10b/0x1f4 [nfs]
[ 1080.973089] [<ffffffffa02deaae>] nfs_pageio_doio+0x1a/0x43 [nfs]
[ 1080.973098] [<ffffffffa02df035>] nfs_pageio_complete+0x16/0x2d [nfs]
[ 1080.973108] [<ffffffffa02e2d8f>] nfs_writepage_locked+0xa0/0xbf [nfs]
[ 1080.973119] [<ffffffffa02e36a1>] nfs_writepage+0x16/0x2b [nfs]
[ 1080.973122] [<ffffffff810e8762>] ? clear_page_dirty_for_io+0x87/0x9a
[ 1080.973133] [<ffffffff810efc5b>] shrink_page_list+0x39b/0x6c8
[ 1080.973139] [<ffffffff810f03bb>] shrink_inactive_list+0x22c/0x39e
[ 1080.973144] [<ffffffff810822d7>] ? lock_release_holdtime.part.7+0x6b/0x72
[ 1080.973148] [<ffffffff810f0c33>] shrink_zone+0x445/0x588
[ 1080.973152] [<ffffffff810f1a11>] balance_pgdat+0x2c2/0x56b
[ 1080.973170] [<ffffffff81254208>] ? __bitmap_weight+0x34/0x80
[ 1080.973175] [<ffffffff810f1f78>] kswapd+0x2be/0x2fa
[ 1080.973179] [<ffffffff810726c8>] ? __init_waitqueue_head+0x4b/0x4b
[ 1080.973183] [<ffffffff810f1cba>] ? balance_pgdat+0x56b/0x56b
[ 1080.973187] [<ffffffff81071f69>] kthread+0xa8/0xb0
[ 1080.973200] [<ffffffff814806b4>] kernel_thread_helper+0x4/0x10
[ 1080.973205] [<ffffffff81071ec1>] ? __init_kthread_worker+0x5a/0x5a
[ 1080.973210] [<ffffffff814806b0>] ? gs_change+0x13/0x13
[ 1080.973213] no locks held by kswapd0/25.
Signed-off-by: Peng Tao <peng_tao@emc.com>
Signed-off-by: Jim Rees <rees@umich.edu>
Cc: stable@kernel.org [3.0]
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit e6d05a757c314ad88d0649d3835a8a1daa964236
Author: Peng Tao <bergwolf@gmail.com>
Date: Thu Sep 22 21:50:16 2011 -0400
pnfsblock: fix NULL pointer dereference
bl_add_page_to_bio returns error pointer. bio should be reset to
NULL in failure cases as the out path always calls bl_submit_bio.
Signed-off-by: Peng Tao <peng_tao@emc.com>
Signed-off-by: Jim Rees <rees@umich.edu>
Cc: stable@kernel.org [3.0]
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 9b7eecdcfeb943f130d86bbc249fde4994b6fe30
Author: Peng Tao <bergwolf@gmail.com>
Date: Thu Sep 22 21:50:15 2011 -0400
pnfs: recoalesce when ld read pagelist fails
For pnfs pagelist read failure, we need to pg_recoalesce and resend IO to
mds.
Signed-off-by: Peng Tao <peng_tao@emc.com>
Signed-off-by: Jim Rees <rees@umich.edu>
Cc: stable@kernel.org [3.0]
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 8ce160c5ef06cc89c2b6b26bfa5ef7a5ce2c93e0
Author: Peng Tao <bergwolf@gmail.com>
Date: Thu Sep 22 21:50:14 2011 -0400
pnfs: recoalesce when ld write pagelist fails
For pnfs pagelist write failure, we need to pg_recoalesce and resend IO to
mds.
Signed-off-by: Peng Tao <peng_tao@emc.com>
Signed-off-by: Jim Rees <rees@umich.edu>
Cc: stable@kernel.org [3.0]
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 1b0ae068779874f54b55aac3a2a992bcf3f2c3c4
Author: Peng Tao <bergwolf@gmail.com>
Date: Thu Sep 22 21:50:12 2011 -0400
pnfs: make _set_lo_fail generic
file layout and block layout both use it to set mark layout io failure
bit. So make it generic.
Signed-off-by: Peng Tao <peng_tao@emc.com>
Signed-off-by: Jim Rees <rees@umich.edu>
Cc: stable@kernel.org [3.0]
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 760383f1ee4d14b0e0bdf0cddee648d9b8633429
Author: Peng Tao <bergwolf@gmail.com>
Date: Thu Sep 22 21:50:11 2011 -0400
pnfsblock: add missing rpc_put_mount and path_put
Reviewed-by: Jeff Layton <jlayton@redhat.com>
Signed-off-by: Peng Tao <peng_tao@emc.com>
Signed-off-by: Jim Rees <rees@umich.edu>
Cc: stable@kernel.org [3.0]
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit c1225158a8dad9e9d5eee8a17dbbd9c7cda05ab9
Author: Peng Tao <bergwolf@gmail.com>
Date: Thu Sep 22 21:50:10 2011 -0400
SUNRPC/NFS: make rpc pipe upcall generic
The same function is used by idmap, gss and blocklayout code. Make it
generic.
Signed-off-by: Peng Tao <peng_tao@emc.com>
Signed-off-by: Jim Rees <rees@umich.edu>
Cc: stable@kernel.org [3.0]
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit fdc17abbc4b6094b34ee8ff5d91eaba8637594a2
Author: Jim Rees <rees@umich.edu>
Date: Thu Sep 22 21:50:09 2011 -0400
pnfsblock: fix size of upcall message
Make the status field explicitly 32 bits. "...it's unlikely that the kernel
and userspace would differ on the size of an int here, but it might be a
good idea to go ahead and make that explicitly 32 bits in case we end up
dealing with more exotic arches at some point in the future."
Suggested-by: Jeff Layton <jlayton@redhat.com>
Signed-off-by: Jim Rees <rees@umich.edu>
Signed-off-by: Benny Halevy <bhalevy@tonian.com>
Cc: stable@kernel.org [3.0]
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 516f2e24faa7548a61d9ba790958528469c2e284
Author: Jim Rees <rees@umich.edu>
Date: Thu Sep 22 21:50:08 2011 -0400
pnfsblock: fix return code confusion
Always return PTR_ERR, not NULL, from nfs4_blk_get_deviceinfo and
nfs4_blk_decode_device.
Check for IS_ERR, not NULL, in bl_set_layoutdriver when calling
nfs4_blk_get_deviceinfo.
Signed-off-by: Jim Rees <rees@umich.edu>
Signed-off-by: Benny Halevy <bhalevy@tonian.com>
Cc: stable@kernel.org [3.0]
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 2da956523526e440ef4f4dd174e26f5ac06fe011
Author: Jeff Layton <jlayton@redhat.com>
Date: Wed Oct 12 10:57:42 2011 -0400
nfs: don't try to migrate pages with active requests
nfs_find_and_lock_request will take a reference to the nfs_page and
will then put it if the req is already locked. It's possible though
that the reference will be the last one. That put then can kick off
a whole series of reference puts:
nfs_page
nfs_open_context
dentry
inode
If the inode ends up being deleted, then the VFS will call
truncate_inode_pages. That function will try to take the page lock, but
it was already locked when migrate_page was called. The code
deadlocks.
Fix this by simply refusing the migration request if PagePrivate is
already set, indicating that the page is already associated with an
active read or write request.
We've had a customer test a backported version of this patch and
the preliminary results seem good.
Cc: stable@kernel.org
Cc: Andrea Arcangeli <aarcange@redhat.com>
Reported-by: Harshula Jayasuriya <harshula@redhat.com>
Signed-off-by: Jeff Layton <jlayton@redhat.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit b9dd3abbbc708da5e3c53424a5b2c66ab580f97e
Author: Mi Jinlong <mijinlong@cn.fujitsu.com>
Date: Wed Oct 12 15:09:34 2011 +0800
nfs: fix bug about IPv6 address scope checking
The result from ipv6_addr_scope() always not be a single SCOPE,
so we can't use equal to compare the result with IPV6_ADDR_SCOPE_LINKLOCAL
at nfs_sockaddr_match_ipaddr6.
This patch fixs the problem, and lets checking address before scope_id.
Signed-off-by: Mi Jinlong <mijinlong@cn.fujitsu.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 3236c3e1adc0c7ec83eaff1de2d06746b7c5bb28
Author: Jeff Layton <jlayton@redhat.com>
Date: Tue Oct 11 09:49:21 2011 -0400
nfs: don't redirty inode when ncommit == 0 in nfs_commit_unstable_pages
commit 420e3646 allowed the kernel to reduce the number of unnecessary
commit calls by skipping the commit when there are a large number of
outstanding pages.
However, the current test in nfs_commit_unstable_pages does not handle
the edge condition properly. When ncommit == 0, then that means that the
kernel doesn't need to do anything more for the inode. The current test
though in the WB_SYNC_NONE case will return true, and the inode will end
up being marked dirty. Once that happens the inode will never be clean
until there's a WB_SYNC_ALL flush.
Fix this by immediately returning from nfs_commit_unstable_pages when
ncommit == 0.
Mike noticed this problem initially in RHEL5 (2.6.18-based kernel) which
has a backported version of 420e3646. The inode cache there was growing
very large. The inode cache was unable to be shrunk since the inodes
were all marked dirty. Calling sync() would essentially "fix" the
problem -- the WB_SYNC_ALL flush would result in the inodes all being
marked clean.
What I'm not clear on is how big a problem this is in mainline kernels
as the writeback code there is very different. Either way, it seems
incorrect to re-mark the inode dirty in this case.
Reported-by: Mike McLean <mikem@redhat.com>
Signed-off-by: Jeff Layton <jlayton@redhat.com>
Cc: stable@kernel.org [2.6.34+]
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 59b7c05fffba030e5d9e72324691e2f99aa69b79
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date: Mon Oct 17 18:22:55 2011 -0700
Revert "NFS: Ensure that writeback_single_inode() calls write_inode() when syncing"
This reverts commit b80c3cb628f0ebc241b02e38dd028969fb8026a2.
The reverted commit was rendered obsolete by a VFS fix: commit
5547e8aac6f71505d621a612de2fca0dd988b439 (writeback: Update dirty flags in
two steps). We now no longer need to worry about writeback_single_inode()
missing our marking the inode for COMMIT in 'do_writepages()' call.
Reverting this patch, fixes a performance regression in which the inode
would continuously get queued to the dirty list, causing the writeback
code to unnecessarily try to send a COMMIT.
Signed-off-by: Trond Myklebust <Trond.Myklebust>
Tested-by: Simon Kirby <sim@hostway.ca>
Cc: stable@kernel.org [2.6.35+]
--
Trond Myklebust
Linux NFS client maintainer
NetApp
Trond.Myklebust@netapp.com
www.netapp.com
^ permalink raw reply [flat|nested] 25+ messages in thread
* [GIT PULL] Please pull nfs client changes
@ 2011-07-27 18:40 Trond Myklebust
0 siblings, 0 replies; 25+ messages in thread
From: Trond Myklebust @ 2011-07-27 18:40 UTC (permalink / raw)
To: Linus Torvalds
Hi Linus,
Please pull from the "nfs-for-3.1" branch of the repository at
git pull git://git.linux-nfs.org/projects/trondmy/linux-nfs.git nfs-for-3.1
This will update the following files through the appended changesets.
Cheers,
Trond
----
fs/lockd/clntproc.c | 9 +-
fs/nfs/Kconfig | 1 +
fs/nfs/callback_proc.c | 57 +++--
fs/nfs/client.c | 7 +-
fs/nfs/delegation.c | 16 +-
fs/nfs/internal.h | 13 ++
fs/nfs/namespace.c | 2 +-
fs/nfs/nfs4_fs.h | 5 +
fs/nfs/nfs4filelayout.c | 80 ++++++-
fs/nfs/nfs4filelayout.h | 17 ++-
fs/nfs/nfs4filelayoutdev.c | 452 +++++++++++++++++++++++++++++----------
fs/nfs/nfs4proc.c | 215 ++++++++++++++++++-
fs/nfs/nfs4state.c | 9 +-
fs/nfs/nfs4xdr.c | 247 +++++++++++++++++++++-
fs/nfs/objlayout/objio_osd.c | 20 ++-
fs/nfs/pagelist.c | 69 +++++-
fs/nfs/pnfs.c | 221 ++++++++++++++++---
fs/nfs/pnfs.h | 74 +++----
fs/nfs/pnfs_dev.c | 64 +++---
fs/nfs/read.c | 166 ++++++++------
fs/nfs/unlink.c | 37 +++-
fs/nfs/write.c | 156 ++++++++------
include/linux/nfs4.h | 3 +
include/linux/nfs_fs_sb.h | 5 +-
include/linux/nfs_page.h | 17 +-
include/linux/nfs_xdr.h | 34 +++-
include/linux/pnfs_osd_xdr.h | 31 +---
include/linux/sunrpc/bc_xprt.h | 6 +-
include/linux/sunrpc/sched.h | 4 +
include/linux/sunrpc/svc.h | 4 +-
include/linux/sunrpc/xprt.h | 34 ++--
net/sunrpc/Kconfig | 4 +
net/sunrpc/Makefile | 2 +-
net/sunrpc/backchannel_rqst.c | 7 +-
net/sunrpc/bc_svc.c | 3 -
net/sunrpc/clnt.c | 15 +-
net/sunrpc/sched.c | 38 +++-
net/sunrpc/svc.c | 6 +-
net/sunrpc/svcsock.c | 14 +-
net/sunrpc/xdr.c | 2 +-
net/sunrpc/xprt.c | 257 +++++++++++++++--------
net/sunrpc/xprtrdma/transport.c | 6 +-
net/sunrpc/xprtrdma/xprt_rdma.h | 2 +-
net/sunrpc/xprtsock.c | 57 ++++-
44 files changed, 1856 insertions(+), 632 deletions(-)
commit ed1e6211a0a134ff23592c6f057af982ad5dab52
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date: Mon Jul 25 15:37:29 2011 -0400
NFSv4: Don't use the delegation->inode in nfs_mark_return_delegation()
nfs_mark_return_delegation() is usually called without any locking, and
so it is not safe to dereference delegation->inode. Since the inode is
only used to discover the nfs_client anyway, it makes more sense to
have the callers pass a valid pointer to the nfs_server as a parameter.
Reported-by: Ian Kent <raven@themaw.net>
Cc: stable@kernel.org
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 73ca1001ed6881b476e8252adcd0eede1ea368ea
Author: Jeff Layton <jlayton@redhat.com>
Date: Mon Jul 18 11:26:30 2011 -0400
nfs: don't use d_move in nfs_async_rename_done
If the task that initiated the sillyrename ends up being killed by a
fatal signal, then it will eventually return back to userspace and end
up releasing the i_mutex. d_move however needs to be done while holding
the i_mutex.
Instead of using d_move here, just unhash the old and new dentries to
prevent them from being found by lookups. With this change though, the
dentries are now incorrect post-rename and do not reflect the actual
name of the file on the server. I'm proceeding under the assumption
that since they are unhashed that this isn't really a problem.
In order for the sillydelete to still work though, the dname must be
copied earlier when setting up the sillydelete info, and the name must
be recopied if the sillydelete info has to be moved to a new dentry.
Reported-by: Al Viro <viro@ZenIV.linux.org.uk>
Signed-off-by: Jeff Layton <jlayton@redhat.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 2773395b34883fe54418de188733a63bb38e0ad6
Author: Steve Dickson <steved@redhat.com>
Date: Thu Jul 21 13:49:02 2011 -0400
RDMA: Increasing RPCRDMA_MAX_DATA_SEGS
Our performance team has noticed that increasing
RPCRDMA_MAX_DATA_SEGS from 8 to 64 significantly
increases throughput when using the RDMA transport.
Signed-off-by: Steve Dickson <steved@redhat.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 34006cee28f7344f9557a4be3816c7891b1bbab1
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date: Sun Jul 17 18:11:34 2011 -0400
SUNRPC: Replace xprt->resend and xprt->sending with a priority queue
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 3b27bad7f7ceacca6d6c0ef647ffb38aa55a8336
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date: Sun Jul 17 18:11:34 2011 -0400
SUNRPC: Allow caller of rpc_sleep_on() to select priority levels
Currently, the caller has to change the value of task->tk_priority if
it wants to select on which priority level the task will sleep.
This patch allows the caller to select a priority level at sleep time
rather than always using task->tk_priority.
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit d9ba131d8f58c0d2ff5029e7002ab43f913b36f9
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date: Sun Jul 17 18:11:30 2011 -0400
SUNRPC: Support dynamic slot allocation for TCP connections
Allow the number of available slots to grow with the TCP window size.
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 21de0a955f3af29fa1100d96f66e6adade89e77a
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date: Sun Jul 17 16:57:32 2011 -0400
SUNRPC: Clean up the slot table allocation
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 8d9266ffe4332afc5ac9de401ef6f825b3798585
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date: Sun Jul 17 16:01:09 2011 -0400
SUNRPC: Initalise the struct xprt upon allocation
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 43cedbf0e8dfb9c5610eb7985d5f21263e313802
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date: Sun Jul 17 16:01:03 2011 -0400
SUNRPC: Ensure that we grab the XPRT_LOCK before calling xprt_alloc_slot
This throttles the allocation of new slots when the socket is busy
reconnecting and/or is out of buffer space.
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit f85ef69ce08bc2209858135328335f668ba35bdb
Author: J. Bruce Fields <bfields@redhat.com>
Date: Fri Jul 15 19:18:42 2011 -0400
pnfs: simplify pnfs files module autoloading
Embed the necessary alias into the module rather than waiting for
someone to add it to /etc/modprobe.conf
Signed-off-by: J. Bruce Fields <bfields@redhat.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 674e405b8b3310702fd43d314f5f432ec2cb9980
Author: J. Bruce Fields <bfields@redhat.com>
Date: Fri Jul 15 19:09:08 2011 -0400
nfs: document nfsv4 sillyrename issues
Somebody working on this code asked what the deal was with NFSv4, since
this comment notes that it's v2/v3's statelessness that requires
sillyrename. Shouldn't hurt to document the answer.
Signed-off-by: J. Bruce Fields <bfields@redhat.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 94b134ac8e9965309e70684b504c53bca36338b4
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date: Wed Jul 13 19:26:49 2011 -0400
NFS: Convert nfs4_set_ds_client to EXPORT_SYMBOL_GPL
This is not part of an external ABI...
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 0d961aa934b799ca7369db582e52952cc50c656d
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date: Wed Jul 13 19:24:15 2011 -0400
SUNRPC: Convert the backchannel exports to EXPORT_SYMBOL_GPL
Ensure that the backchannel exports conform to the existing sunrpc
practice.
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 9e00abc3c20904fd6a5d888bb7023925799ec8a5
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date: Wed Jul 13 19:20:49 2011 -0400
SUNRPC: sunrpc should not explicitly depend on NFS config options
Change explicit references to CONFIG_NFS_V4_1 to implicit ones
Get rid of the unnecessary defines in backchannel_rqst.c and
bc_svc.c: the Makefile takes care of those dependency.
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 1f9453578f059d2651aa6c6b16756627fc9f2a74
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date: Wed Jul 13 15:59:57 2011 -0400
NFS: Clean up - simplify the switch to read/write-through-MDS
Use nfs_pageio_reset_read_mds and nfs_pageio_reset_write_mds instead of
completely reinitialising the struct nfs_pageio_descriptor.
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit dce81290eed64d24493989bb7a08f9e20495e184
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date: Wed Jul 13 15:59:19 2011 -0400
NFS: Move the pnfs write code into pnfs.c
...and ensure that we recoalese to take into account differences in
differences in block sizes when falling back to write through the MDS.
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 493292ddc78d18ee2ad2d5c24c2b7dd6a24641d2
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date: Wed Jul 13 15:58:28 2011 -0400
NFS: Move the pnfs read code into pnfs.c
...and ensure that we recoalese to take into account differences in
block sizes when falling back to read through the MDS.
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit d9156f9f364897e93bdd98b4ad22138de18f7c24
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date: Tue Jul 12 13:42:02 2011 -0400
NFS: Allow the nfs_pageio_descriptor to signal that a re-coalesce is needed
If an attempt to do pNFS fails, and we have to fall back to writing through
the MDS, then we may want to re-coalesce the requests that we already have
since the block size for the MDS read/writes may be different to that of
the DS read/writes.
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit d097971d8ab4042eaa4bff98698ae9cc55942327
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date: Tue Jul 12 13:42:02 2011 -0400
NFS: Use the nfs_pageio_descriptor->pg_bsize in the read/write request
Instead of looking up the rsize and wsize, the routines that generate the
RPC requests should really be using the pg_bsize, since that is what we
use when deciding whether or not to coalesce write requests...
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 50828d7e6767a92726708bc0666e2b8b84575808
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date: Tue Jul 12 13:42:02 2011 -0400
NFS: Cache rpc_ops in struct nfs_pageio_descriptor
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 275acaafd45fbc8ecc3beabd6367e60b3049606a
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date: Tue Jul 12 13:42:02 2011 -0400
NFS: Clean up: split out the RPC transmission from nfs_pagein_multi/one
...and do the same for nfs_flush_multi/one.
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 3b6091846d5b6113d695c79caec7cc96b62d469b
Author: Peng Tao <bergwolf@gmail.com>
Date: Fri Jul 15 03:33:42 2011 -0400
NFS: fix return value of nfs_pagein_one/nfs_flush_one
Signed-off-by: Peng Tao <peng_tao@emc.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 6e4efd568574221840ee8dd86f176dc977c1330c
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date: Tue Jul 12 13:42:02 2011 -0400
NFS: Clean up nfs_read_rpcsetup and nfs_write_rpcsetup
Split them up into two parts: one which sets up the struct nfs_read/write_data,
the other which sets up the actual RPC call or pNFS call.
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 87ed5eb44ad9338b1617a0e78dea81d681325298
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date: Tue Jul 12 13:42:01 2011 -0400
NFS: Don't use DATA_SYNC writes
If we're writing back data, and the FLUSH_STABLE flag is set, then we
always want to use NFS_FILE_SYNC, since we're always in a situation where
we're doing page reclaim, and so we want to free up the page as quickly
as possible.
If we're in the FLUSH_COND_STABLE case, then we either want to use another
unstable write (if we have to do a commit anyway) or again, we want to
use NFS_FILE_SYNC because we know that we have no more pages to write
out.
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit c47abcf8ff4d0c56d20ce541e80d3e1c975f54b5
Author: Andy Adamson <andros@netapp.com>
Date: Wed Jun 15 17:52:40 2011 -0400
NFSv4.1: do not use deviceids after MDS clientid invalidation
Mark all deviceids established under an expired MDS clientid as invalid.
Stop all new i/o through DS and send through the MDS.
Don't use any new LAYOUTGETs that use the invalid deviceid. Purge all layouts
established under the expired MDS clientid.
Remove the MDS clientid deviceid and data servers reference
Signed-off-by: Andy Adamson <andros@netapp.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit a56aaa02b1f723e28b41d339ddff02e958d32d43
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date: Wed Jun 15 11:59:10 2011 -0400
NFSv4.1: Clean up layoutreturn
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@netapp.com>
commit aa5c01446610f0305f96251d0f9621866b8e5a14
Author: Boaz Harrosh <bharrosh@panasas.com>
Date: Mon Jun 13 17:52:55 2011 -0400
pnfs-obj: pnfs_osd_xdr: Remove dead code and cleanup
* Some leftovers from ancient times.
* This file will only define common types and client API.
Remove server from comments
Signed-off-by: Boaz Harrosh <Boaz Harrosh bharrosh@panasas.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 7c24d9489fe57d67cb56c6bdad58d89806e7fd97
Author: Andy Adamson <andros@netapp.com>
Date: Mon Jun 13 18:22:38 2011 -0400
NFSv4.1: File layout only supports whole file layouts
Ask for whole file layouts. Until support for layout segments is fully
supported in the file layout code, discard non-whole file layouts.
Signed-off-by: Andy Adamson <andros@netapp.com>
Signed-off-by: Fred Isaman <iisaman@netapp.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 47cb498e9316314e7e681f417135589195ad78a7
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date: Tue Jun 14 12:18:11 2011 -0400
NFSv4.1: Clean ups for the device id cache
The fact that the global device id cache holds a reference to the
nfs4_deviceid_node until it is invisible to rcu lookups implies that
we can always assume that the reference count is non-zero in
_find_get_deviceid.
Also clean up nfs4_put_deviceid_node and the removal of the device id
from the cache.
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit e885de1a5bc9f46ef8f934c5a7602c89d2d51e8d
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date: Fri Jun 10 13:30:23 2011 -0400
NFSv4.1: Fall back to ordinary i/o through the mds if we have no layout segment
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit d8007d4dd6ff8749cc8a4063c3ec87442db76d82
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date: Fri Jun 10 13:30:23 2011 -0400
NFSv4.1: Add an initialisation callback for pNFS
Ensure that we always get a layout before setting up the i/o request.
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 1751c3638f2a07a8c66a803a31791bab9bd3fced
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date: Fri Jun 10 13:30:23 2011 -0400
NFS: Cleanup of the nfs_pageio code in preparation for a pnfs bugfix
We need to ensure that the layouts are set up before we can decide to
coalesce requests. To do so, we want to further split up the struct
nfs_pageio_descriptor operations into an initialisation callback, a
coalescing test callback, and a 'do i/o' callback.
This patch cleans up the existing callback methods before adding the
'initialisation' callback.
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit f062eb6ced3b297277b94b4da3113b1d3782e539
Author: Bryan Schumaker <bjschuma@netapp.com>
Date: Thu Jun 2 14:59:10 2011 -0400
NFS: test and free stateids during recovery
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 <bjschuma@netapp.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 9aeda35fd643eba683fdb8dba8907fa796a85dda
Author: Bryan Schumaker <bjschuma@netapp.com>
Date: Thu Jun 2 14:59:09 2011 -0400
NFS: added FREE_STATEID call
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 <bjschuma@netapp.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 7d9747947ae66d8f6a9a9a023a3a5e28df6a536e
Author: Bryan Schumaker <bjschuma@netapp.com>
Date: Thu Jun 2 14:59:08 2011 -0400
NFS: Added TEST_STATEID call
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 <bjschuma@netapp.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit fca78d6d2c77f87d7dbee89bbe4836a44da881e2
Author: Bryan Schumaker <bjschuma@netapp.com>
Date: Thu Jun 2 14:59:07 2011 -0400
NFS: Add SECINFO_NO_NAME procedure
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 <bjschuma@netapp.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 6382a44138e7aa40bf52170e7afc014443a24806
Author: Weston Andros Adamson <dros@netapp.com>
Date: Wed Jun 1 16:44:44 2011 -0400
NFS: move pnfs layouts to nfs_server structure
Layouts should be tracked per nfs_server (aka superblock)
instead of per struct nfs_client, which may have multiple FSIDs associated
with it.
Signed-off-by: Weston Andros Adamson <dros@netapp.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 35dbbc99e93e57680837c17f96efe370f0535064
Author: Weston Andros Adamson <dros@netapp.com>
Date: Wed Jun 1 16:32:21 2011 -0400
NFS: fix comment
We support IPv4 and IPv6 now.
Signed-off-by: Weston Andros Adamson <dros@netapp.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 78fe0f41d9937ee62817912ac8d627e06243c269
Author: Weston Andros Adamson <dros@netapp.com>
Date: Tue May 31 19:05:47 2011 -0400
NFS: use scope from exchange_id to skip reclaim
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 <dros@netapp.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 7e574f0d3911c5cc60d4d2b57fee975c462d6cd0
Author: Weston Andros Adamson <dros@netapp.com>
Date: Tue May 31 18:48:58 2011 -0400
NFS: pnfs: loop over multipath addrs on connect
Don't just use the first addr in the multipath list - instead, loop
over addresses when calling nfs4_set_ds_client() (which calls connect)
until it is successful.
Although this is not real multipath support, it's a quick fix to handle when
an MDS sends a list of addresses for a DS and some of the addr families are
unsupported or misconfigured (like no routable ipv6 addr assigned).
This will attempt all paths to the DS before giving up, instead of immediately
falling back to the MDS.
As before, an error encountered after a successful connect() will cause all
i/o to fall back to the MDS.
Signed-off-by: Weston Andros Adamson <dros@netapp.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 14f9a6076f5388f3fd6341ad4b841337b28fc825
Author: Weston Andros Adamson <dros@netapp.com>
Date: Tue May 31 18:48:57 2011 -0400
NFS: Parse and store all multipath DS addresses
This parses and stores all addresses associated with each data server,
laying the groundwork for supporting multipath to data servers.
- Skips over addresses that cannot be parsed (ie IPv6 addrs if v6 is not
enabled). Only fails if none of the addresses are recognizable
- Currently only uses the first address that parsed cleanly
- Tested against pynfs server (modified to support multipath)
Signed-off-by: Weston Andros Adamson <dros@netapp.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit c9895cb69b07a4b17d8fdae26667f9a9fba5183b
Author: Weston Andros Adamson <dros@netapp.com>
Date: Tue May 31 18:48:56 2011 -0400
NFS: pnfs IPv6 support
Handle ipv6 remote addresses from GETDEVICEINFO
- supports netid "tcp" for ipv4 and "tcp6" for ipv6 as rfc 5665 specifies
- added ds_remotestr to avoid having to handle different AFs in every dprintk
- tested against pynfs 4.1 server, submitting ipv6 support patch to pynfs
- tested with IPv6 disabled, it compiles cleanly and relies on rpc_pton to
refuse to accept IPv6 addresses
Signed-off-by: Weston Andros Adamson <dros@netapp.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 82c2c8b8616fa9e77264c53f0df483f74ac54613
Author: Vasily Averin <vvs@sw.ru>
Date: Wed Jun 1 16:54:32 2011 +0400
lockd: properly convert be32 values in debug messages
lockd: server returns status 50331648
it's quite hard to understand that number in this message is 3 in big endian
Signed-off-by: Vasily Averin <vvs@sw.ru>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 726fd6ad59f73bd116b6a22d701db078183673c8
Author: Vasily Averin <vvs@sw.ru>
Date: Wed Jun 1 16:23:59 2011 +0400
sunrpc: use dprint_status() macro in call_decode()
common dprint_status() macro is used in all callbacks but not in call_decode()
Signed-off-by: Vasily Averin <vvs@sw.ru>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
--
Trond Myklebust
Linux NFS client maintainer
NetApp
Trond.Myklebust@netapp.com
www.netapp.com
^ permalink raw reply [flat|nested] 25+ messages in thread
* [GIT PULL] Please pull NFS client changes
@ 2011-03-17 17:19 Trond Myklebust
0 siblings, 0 replies; 25+ messages in thread
From: Trond Myklebust @ 2011-03-17 17:19 UTC (permalink / raw)
To: Linus Torvalds
Hi Linus,
Please pull from the "nfs-for-2.6.39" branch of the repository at
git pull git://git.linux-nfs.org/projects/trondmy/nfs-2.6.git nfs-for-2.6.39
This will update the following files through the appended changesets.
Cheers,
Trond
----
Documentation/filesystems/nfs/pnfs.txt | 7 +
Documentation/kernel-parameters.txt | 8 +
fs/nfs/callback_proc.c | 2 +-
fs/nfs/client.c | 131 +++++++++---
fs/nfs/direct.c | 8 +-
fs/nfs/file.c | 4 -
fs/nfs/idmap.c | 90 +++++++--
fs/nfs/internal.h | 22 ++
fs/nfs/nfs3proc.c | 1 +
fs/nfs/nfs4_fs.h | 28 +++
fs/nfs/nfs4filelayout.c | 361 +++++++++++++++++++++++++++++---
fs/nfs/nfs4filelayout.h | 19 ++-
fs/nfs/nfs4filelayoutdev.c | 252 ++++++++++++++++++++---
fs/nfs/nfs4proc.c | 123 ++++++++++--
fs/nfs/nfs4renewd.c | 6 +-
fs/nfs/nfs4state.c | 6 +
fs/nfs/nfs4xdr.c | 38 ++--
fs/nfs/pagelist.c | 22 ++-
fs/nfs/pnfs.c | 330 ++++++++++++++---------------
fs/nfs/pnfs.h | 118 ++++++-----
fs/nfs/proc.c | 1 +
fs/nfs/read.c | 127 +++++++----
fs/nfs/super.c | 284 +++++++------------------
fs/nfs/write.c | 153 +++++++++-----
include/linux/nfs_fs.h | 2 +-
include/linux/nfs_fs_sb.h | 4 +-
include/linux/nfs_idmap.h | 9 +-
include/linux/nfs_iostat.h | 2 +
include/linux/nfs_page.h | 6 +-
include/linux/nfs_xdr.h | 16 ++-
include/linux/sunrpc/clnt.h | 1 +
include/linux/sunrpc/xprt.h | 3 +-
net/sunrpc/auth_gss/auth_gss.c | 2 +-
net/sunrpc/auth_gss/gss_krb5_mech.c | 2 +-
net/sunrpc/clnt.c | 18 +-
net/sunrpc/sched.c | 29 +--
net/sunrpc/xprt.c | 25 +--
net/sunrpc/xprtrdma/rpc_rdma.c | 86 ++++----
net/sunrpc/xprtrdma/verbs.c | 53 ++++-
net/sunrpc/xprtrdma/xprt_rdma.h | 1 +
40 files changed, 1600 insertions(+), 800 deletions(-)
commit 8e26de238fd794c8ea56a5c98bf67c40cfeb051d
Author: Stanislav Kinsbursky <skinsbursky@parallels.com>
Date: Thu Mar 17 18:54:23 2011 +0300
RPC: killing RPC tasks races fixed
RPC task RPC_TASK_QUEUED bit is set must be checked before trying to wake up
task rpc_killall_tasks() because task->tk_waitqueue can not be set (equal to
NULL).
Also, as Trond Myklebust mentioned, such approach (instead of checking
tk_waitqueue to NULL) allows us to "optimise away the call to
rpc_wake_up_queued_task() altogether for those
tasks that aren't queued".
Here is an example of dereferencing of tk_waitqueue equal to NULL:
CPU 0 CPU 1 CPU 2
-------------------- --------------------- --------------------------
nfs4_run_open_task
rpc_run_task
rpc_execute
rpc_set_active
rpc_make_runnable
(waiting)
rpc_async_schedule
nfs4_open_prepare
nfs_wait_on_sequence
nfs_umount_begin
rpc_killall_tasks
rpc_wake_up_task
rpc_wake_up_queued_task
spin_lock(tk_waitqueue == NULL)
BUG()
rpc_sleep_on
spin_lock(&q->lock)
__rpc_sleep_on
task->tk_waitqueue = q
Signed-off-by: Stanislav Kinsbursky <skinsbursky@openvz.org>
Cc: stable@kernel.org
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit ba3c578de274a5438bafbce03f9225936698051c
Author: j223yang@asset.uwaterloo.ca <j223yang@asset.uwaterloo.ca>
Date: Wed Mar 16 11:16:22 2011 -0400
xprt: remove redundant check
remove redundant check.
Signed-off-by: Jinqiu Yang <crindy646@gmail.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit a8de240a9074b72b156d9e6d53f00076e6cd5f03
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date: Tue Mar 15 19:56:30 2011 -0400
SUNRPC: Convert struct rpc_xprt to use atomic_t counters
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit e020c6800c9621a77223bf2c1ff68180e41e8ebf
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date: Tue Mar 15 19:56:30 2011 -0400
SUNRPC: Ensure we always run the tk_callback before tk_action
This fixes a race in which the task->tk_callback() puts the rpc_task
to sleep, setting a new callback. Under certain circumstances, the current
code may end up executing the task->tk_action before it gets round to the
callback.
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
Cc: stable@kernel.org
commit 986d4abbddf9e76184f6cabf66654ea8e61bcde5
Author: Randy Dunlap <randy.dunlap@oracle.com>
Date: Tue Mar 15 17:11:59 2011 -0700
sunrpc: fix printk format warning
Fix printk format build warning:
net/sunrpc/xprtrdma/verbs.c:1463: warning: format '%llx' expects type 'long long unsigned int', but argument 3 has type 'dma_addr_t'
Signed-off-by: Randy Dunlap <randy.dunlap@oracle.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 4d4a76f3309edc671918a767b336492fbc80a16d
Author: j223yang@asset.uwaterloo.ca <j223yang@asset.uwaterloo.ca>
Date: Thu Mar 10 12:40:28 2011 -0500
xprt: remove redundant null check
'req' is dereferenced before checked for NULL.
The patch simply removes the check.
Signed-off-by: Jinqiu Yang<crindy646@gmail.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 8f68cd42d85f31fb58dd2cabf3ff4aad0a2bafd9
Author: Stephen Rothwell <sfr@canb.auug.org.au>
Date: Tue Mar 15 18:37:09 2011 +1100
nfs: BKL is no longer needed, so remove the include
Signed-off-by: Stephen Rothwell <sfr@canb.auug.org.au>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit e0dca7a05df4e23a8f5b07742e99e2a6f7d67db1
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date: Mon Mar 14 18:20:01 2011 -0400
NFS: Fix a warning in fs/nfs/idmap.c
Commit 45a52a02072b2a7e265f024cfdb00127e08dd9f2 (NFS move nfs_client
initialization into nfs_get_client) introduces a new warning in
fs/nfs/idmap.c:
‘struct rpc_timeout’ declared inside parameter list
Fix it by adding a forward declaration for the struct rpc_timeout
in include/linux/nfs_xdr.h
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit c5cb09b6f898609922f9b873661f6cbc26cb29e1
Author: Rob Landley <rlandley@parallels.com>
Date: Wed Mar 9 16:02:37 2011 -0600
Cleanup: Factor out some cut-and-paste code.
Factor out some cut-and-paste code in options parsing.
Saves about 800 bytes on x86-64.
Signed-off-by: Rob Landley <rlandley@parallels.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit c12bacec458bef16d843c052f38422862f3da8fe
Author: Rob Landley <rlandley@parallels.com>
Date: Wed Mar 9 15:54:13 2011 -0600
cleanup: save 60 lines/100 bytes by combining two mostly duplicate functions.
Eliminate two mostly duplicate functions (nfs_parse_simple_hostname()
and nfs_parse_protected_hostname()) and instead just make the calling
function (nfs_parse_devname()) do everything.
Signed-off-by: Rob Landley <rlandley@parallels.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 7ec10f26e1fd5fcceb9c96e508c1292a816199f7
Author: Konstantin Khlebnikov <khlebnikov@openvz.org>
Date: Tue Feb 22 00:28:34 2011 +0300
NFS: account direct-io into task io accounting
Account NFS direct-io reads and writes into Task I/O Accounting.
Do it before complition to handle aio.
NFS have unusual direct-io implementation,
thus accounting in generic code does not work.
Signed-off-by: Konstantin Khlebnikov <khlebnikov@openvz.org>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit f8628220bb395104697be9c447c1085846dfc97c
Author: Kevin Coffman <kwc@citi.umich.edu>
Date: Thu Mar 3 00:51:41 2011 +0000
gss:krb5 only include enctype numbers in gm_upcall_enctypes
Make the value in gm_upcall_enctypes just the enctype values.
This allows the values to be used more easily elsewhere.
Signed-off-by: Kevin Coffman <kwc@citi.umich.edu>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 5c635e09cec0feeeb310968e51dad01040244851
Author: Tom Tucker <tom@ogc.us>
Date: Wed Feb 9 19:45:34 2011 +0000
RPCRDMA: Fix FRMR registration/invalidate handling.
When the rpc_memreg_strategy is 5, FRMR are used to map RPC data.
This mode uses an FRMR to map the RPC data, then invalidates
(i.e. unregisers) the data in xprt_rdma_free. These FRMR are used
across connections on the same mount, i.e. if the connection goes
away on an idle timeout and reconnects later, the FRMR are not
destroyed and recreated.
This creates a problem for transport errors because the WR that
invalidate an FRMR may be flushed (i.e. fail) leaving the
FRMR valid. When the FRMR is later used to map an RPC it will fail,
tearing down the transport and starting over. Over time, more and
more of the FRMR pool end up in the wrong state resulting in
seemingly random disconnects.
This fix keeps track of the FRMR state explicitly by setting it's
state based on the successful completion of a reg/inv WR. If the FRMR
is ever used and found to be in the wrong state, an invalidate WR
is prepended, re-syncing the FRMR state and avoiding the connection loss.
Signed-off-by: Tom Tucker <tom@ogc.us>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit bd7ea31b9e8a342be76e0fe8d638343886c2d8c5
Author: Tom Tucker <tom@ogc.us>
Date: Wed Feb 9 19:45:28 2011 +0000
RPCRDMA: Fix to XDR page base interpretation in marshalling logic.
The RPCRDMA marshalling logic assumed that xdr->page_base was an
offset into the first page of xdr->page_list. It is in fact an
offset into the xdr->page_list itself, that is, it selects the
first page in the page_list and the offset into that page.
The symptom depended in part on the rpc_memreg_strategy, if it was
FRMR, or some other one-shot mapping mode, the connection would get
torn down on a base and bounds error. When the badly marshalled RPC
was retransmitted it would reconnect, get the error, and tear down the
connection again in a loop forever. This resulted in a hung-mount. For
the other modes, it would result in silent data corruption. This bug is
most easily reproduced by writing more data than the filesystem
has space for.
This fix corrects the page_base assumption and otherwise simplifies
the iov mapping logic.
Signed-off-by: Tom Tucker <tom@ogc.us>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit b064eca2cf6440bf9d5843b24cc4010624031694
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date: Tue Feb 22 15:44:32 2011 -0800
NFSv4: Send unmapped uid/gids to the server when using auth_sys
The new behaviour is enabled using the new module parameter
'nfs4_disable_idmapping'.
Note that if the server rejects an unmapped uid or gid, then
the client will automatically switch back to using the idmapper.
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 3ddeb7c5c61d0d6bfd837487d3454ffdb788bb91
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date: Tue Feb 22 15:44:31 2011 -0800
NFSv4: Propagate the error NFS4ERR_BADOWNER to nfs4_do_setattr
This will be required in order to switch uid/gid mapping back on if the
admin has tried to disable it.
Note that we also propagate NFS4ERR_BADNAME at the same time, in order to
work around a Linux server bug.
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit e4fd72a17d2703cfd626c55893ac4ca7e7d81ce9
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date: Tue Feb 22 15:44:31 2011 -0800
NFSv4: cleanup idmapper functions to take an nfs_server argument
...instead of the nfs_client.
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit f0b851689a5da2354f19bcbbac30cd2cab45c4a1
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date: Tue Feb 22 15:44:31 2011 -0800
NFSv4: Send unmapped uid/gids to the server if the idmapper fails
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 5cf36cfdc8caa2724738ad0842c5c3dd02f309dc
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date: Tue Feb 22 15:44:31 2011 -0800
NFSv4: If the server sends us a numeric uid/gid then accept it
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 75247affd7930cc3dcf57f850f0d7898379ef3b3
Author: Benny Halevy <bhalevy@panasas.com>
Date: Tue Feb 22 15:56:01 2011 -0800
NFSv4.1: reject zero layout with zeroed stripe unit
Allowing stripe_unit==0 causes the client to crash later on
when dividing by zero.
Reported-by: Marc Eshel <eshel@almaden.ibm.com>
Signed-off-by: Benny Halevy <bhalevy@panasas.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 36fe432d33e078caee5c954e15e929819c2cacae
Author: Fred Isaman <iisaman@netapp.com>
Date: Thu Mar 3 15:13:49 2011 +0000
NFSv4.1: Clear lseg pointer in ->doio function
Now that we have access to the pointer, clear it immediately after
the put, instead of in caller.
Signed-off-by: Fred Isaman <iisaman@netapp.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit c76069bda0f17cd3e153e54d9ac01242909c6b15
Author: Fred Isaman <iisaman@netapp.com>
Date: Thu Mar 3 15:13:48 2011 +0000
NFSv4.1: rearrange ->doio args
This will make it possible to clear the lseg pointer in the same
function as it is put, instead of in the caller nfs_pageio_doio().
Signed-off-by: Fred Isaman <iisaman@netapp.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit a69aef1496726ed88386dad65abfcc8cd3195304
Author: Fred Isaman <iisaman@netapp.com>
Date: Thu Mar 3 15:13:47 2011 +0000
NFSv4.1: pnfs filelayout driver write
Allows the pnfs filelayout driver to write to the data servers.
Note that COMMIT to data servers will be implemented in a future
patch. To avoid improper behavior, for the moment any WRITE to a data
server that would also require a COMMIT to the data server is sent
NFS_FILE_SYNC.
Signed-off-by: Andy Adamson <andros@citi.umich.edu>
Signed-off-by: Dean Hildebrand <dhildeb@us.ibm.com>
Signed-off-by: Fred Isaman <iisaman@citi.umich.edu>
Signed-off-by: Mingyang Guo <guomingyang@nrchpc.ac.cn>
Signed-off-by: Oleg Drokin <green@linuxhacker.ru>
Signed-off-by: Ricardo Labiaga <Ricardo.Labiaga@netapp.com>
Signed-off-by: Andy Adamson <andros@netapp.com>
Signed-off-by: Benny Halevy <bhalevy@panasas.com>
Signed-off-by: Fred Isaman <iisaman@netapp.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 7ffd10640dc008f6d5a375bd6450755745c63c7d
Author: Fred Isaman <iisaman@netapp.com>
Date: Thu Mar 3 15:13:46 2011 +0000
NFSv4.1: remove GETATTR from ds writes
Any WRITE compound directed to a data server needs to have the
GETATTR calls suppressed.
Signed-off-by: Fred Isaman <iisaman@netapp.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 0382b74409c6b9ef12c952b50bb44f557a361a43
Author: Andy Adamson <andros@netapp.com>
Date: Thu Mar 3 15:13:45 2011 +0000
NFSv4.1: implement generic pnfs layer write switch
Signed-off-by: Andy Adamson <andros@citi.umich.edu>
Signed-off-by: Boaz Harrosh <bharrosh@panasas.com>
Signed-off-by: Dean Hildebrand <dhildeb@us.ibm.com>
Signed-off-by: Fred Isaman <iisaman@citi.umich.edu>
Signed-off-by: J. Bruce Fields <bfields@fieldses.org>
Signed-off-by: Mike Sager <sager@netapp.com>
Signed-off-by: Ricardo Labiaga <Ricardo.Labiaga@netapp.com>
Signed-off-by: Tao Guo <guotao@nrchpc.ac.cn>
Signed-off-by: Andy Adamson <andros@netapp.com>
Signed-off-by: Benny Halevy <bhalevy@panasas.com>
Signed-off-by: Fred Isaman <iisaman@netapp.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 44b83799a922a153957c65ccfc985a8c902958c8
Author: Fred Isaman <iisaman@netapp.com>
Date: Thu Mar 3 15:13:44 2011 +0000
NFSv4.1: trigger LAYOUTGET for writes
Signed-off-by: Fred Isaman <iisaman@netapp.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 5053aa568d4017aeb1fa35247d4ad96be262920f
Author: Fred Isaman <iisaman@netapp.com>
Date: Thu Mar 3 15:13:43 2011 +0000
NFSv4.1: Send lseg down into nfs_write_rpcsetup
We grab the lseg sent in from the doio function and attach it to
each struct nfs_write_data created. This is how the lseg will be
sent to the layout driver.
Signed-off-by: Fred Isaman <iisaman@netapp.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit b029bc9b0880cbaf999f580c0ea8f06dd274fc77
Author: Fred Isaman <iisaman@netapp.com>
Date: Thu Mar 3 15:13:42 2011 +0000
NFSv4.1: add callback to nfs4_write_done
Add callback that pnfs layout driver can use to do its own handling
of data server WRITE response.
Signed-off-by: Fred Isaman <iisaman@netapp.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit d138d5d17be6a60d883e8bd4e22bc218d3adfab3
Author: Andy Adamson <andros@netapp.com>
Date: Thu Mar 3 15:13:41 2011 +0000
NFSv4.1: rearrange nfs_write_rpcsetup
Reorder nfs_write_rpcsetup, preparing for a pnfs entry point.
Signed-off-by: Andy Adamson <andros@netapp.com>
Signed-off-by: Fred Isaman <iisaman@netapp.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 80fe2b192dbc53261e385dc26d90f5195f1c62e7
Author: Fred Isaman <iisaman@netapp.com>
Date: Tue Mar 1 01:34:23 2011 +0000
NFSv4.1: lseg documentation
Signed-off-by: Fred Isaman <iisaman@netapp.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 568e8c494ded95a28c5dd8b79b4d3ffb95b6d845
Author: Andy Adamson <andros@netapp.com>
Date: Tue Mar 1 01:34:22 2011 +0000
NFSv4.1: turn off pNFS on ds connection failure
If a data server is unavailable, go through MDS.
Mark the deviceid containing the data server as a negative cache entry.
Do not try to connect to any data server on a deviceid marked as a negative
cache entry. Mark any layout that tries to use the marked deviceid as failed.
Inodes with a layout marked as fails will not use the layout for I/O, and will
not perform any more layoutgets.
Inodes without a layout will still do layoutget, but the layout will get
marked immediately.
Signed-off-by: Andy Adamson <andros@netapp.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit ea8eecdd11ee6becd09c095c8efa88aa7df95961
Author: Christoph Hellwig <hch@infradead.org>
Date: Tue Mar 1 01:34:21 2011 +0000
NFSv4.1 move deviceid cache to filelayout driver
No need for generic cache with only one user.
Keep a simple hash of deviceids in the filelayout driver.
Signed-off-by: Christoph Hellwig <hch@infradead.org>
Acked-by: Andy Adamson <andros@netapp.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit cbdabc7f8bf14ca1d40ab1cb86f64b3bc09716e8
Author: Andy Adamson <andros@netapp.com>
Date: Tue Mar 1 01:34:20 2011 +0000
NFSv4.1: filelayout async error handler
Use our own async error handler.
Mark the layout as failed and retry i/o through the MDS on specified errors.
Update the mds_offset in nfs_readpage_retry so that a failed short-read retry
to a DS gets correctly resent through the MDS.
Signed-off-by: Andy Adamson <andros@netapp.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit dc70d7b3189597f313df7bd2da849cfc39063b15
Author: Andy Adamson <andros@netapp.com>
Date: Tue Mar 1 01:34:19 2011 +0000
NFSv4.1: filelayout read
Attempt a pNFS file layout read by setting up the nfs_read_data struct and
calling nfs_initiate_read with the data server rpc client and the
filelayout rpc call ops.
Error handling is implemented in a subsequent patch.
Signed-off-by: Andy Adamson <andros@citi.umich.edu>
Signed-off-by: Dean Hildebrand <dhildeb@us.ibm.com>
Signed-off-by: Fred Isaman <iisaman@citi.umich.edu>
Signed-off-by: Fred Isaman <iisaman@netapp.com>
Signed-off-by: Mingyang Guo <guomingyang@nrchpc.ac.cn>
Signed-off-by: Oleg Drokin <green@linuxhacker.ru>
Signed-off-by: Ricardo Labiaga <Ricardo.Labiaga@netapp.com>
Tested-by: Guo Mingyang <guomingyang@nrchpc.ac.cn>
Signed-off-by: Andy Adamson <andros@netapp.com>
Signed-off-by: Benny Halevy <bhalevy@panasas.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit cfe7f4120f8b1b9465c333d1e42efd4669b1799f
Author: Fred Isaman <iisaman@netapp.com>
Date: Tue Mar 1 01:34:18 2011 +0000
NFSv4.1: filelayout i/o helpers
Prepare for filelayout_read_pagelist with helper functions that find the correct
data server, filehandle, and offset.
Signed-off-by: Andy Adamson <andros@citi.umich.edu>
Signed-off-by: Dean Hildebrand <dhildeb@us.ibm.com>
Signed-off-by: Fred Isaman <iisaman@netapp.com>
Signed-off-by: Marc Eshel <eshel@almaden.ibm.com>
Signed-off-by: Mike Sager <sager@netapp.com>
Signed-off-by: Oleg Drokin <green@linuxhacker.ru>
Signed-off-by: Tao Guo <guotao@nrchpc.ac.cn>
Signed-off-by: Tigran Mkrtchyan <tigran@anahit.desy.de>
Signed-off-by: Tigran Mkrtchyan <tigran.mkrtchyan@desy.de>
Signed-off-by: Andy Adamson <andros@netapp.com>
Signed-off-by: Benny Halevy <bhalevy@panasas.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit d83217c13531fd59730d77b5c2284e90e56c0a50
Author: Andy Adamson <andros@netapp.com>
Date: Tue Mar 1 01:34:17 2011 +0000
NFSv4.1: data server connection
Introduce a data server set_client and init session following the
nfs4_set_client and nfs4_init_session convention.
Once a new nfs_client is on the nfs_client_list, the nfs_client cl_cons_state
serializes access to creating an nfs_client struct with matching properties.
Use the new nfs_get_client() that initializes new clients.
Signed-off-by: Andy Adamson <andros@netapp.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 64419a9b20938d9070fdd8c58c2fa23c911915f8
Author: Andy Adamson <andros@netapp.com>
Date: Tue Mar 1 01:34:16 2011 +0000
NFSv4.1: generic read
Separate the rpc run portion of nfs_read_rpcsetup into a new function
nfs_initiate_read that is called for normal NFS I/O.
Add a pNFS read_pagelist function that is called instead of nfs_intitate_read
for pNFS reads.
Signed-off-by: Andy Adamson <andros@citi.umich.edu>
Signed-off-by: Boaz Harrosh <bharrosh@panasas.com>
Signed-off-by: Dean Hildebrand <dhildeb@us.ibm.com>
Signed-off-by: Fred Isaman <iisaman@citi.umich.edu>
Signed-off-by: Fred Isaman <iisaman@netapp.com>
Signed-off-by: Mike Sager <sager@netapp.com>
Signed-off-by: Mingyang Guo <guomingyang@nrchpc.ac.cn>
Signed-off-by: Ricardo Labiaga <Ricardo.Labiaga@netapp.com>
Signed-off-by: Tao Guo <guotao@nrchpc.ac.cn>
Signed-off-by: Andy Adamson <andros@netapp.com>
Signed-off-by: Benny Halevy <bhalevy@panasas.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit bae724ef95b0d0a1f4518f5451e7c8aabc41f820
Author: Fred Isaman <iisaman@netapp.com>
Date: Tue Mar 1 01:34:15 2011 +0000
NFSv4.1: shift pnfs_update_layout locations
Move the pnfs_update_layout call location to nfs_pageio_do_add_request().
Grab the lseg sent in the doio function to nfs_read_rpcsetup and attach
it to each nfs_read_data so it can be sent to the layout driver.
Signed-off-by: Andy Adamson <andros@netapp.com>
Signed-off-by: Andy Adamson <andros@citi.umich.edu>
Signed-off-by: Dean Hildebrand <dhildeb@us.ibm.com>
Signed-off-by: Fred Isaman <iisaman@citi.umich.edu>
Signed-off-by: Fred Isaman <iisaman@netapp.com>
Signed-off-by: Benny Halevy <bhalevy@panasas.com>
Signed-off-by: Boaz Harrosh <bharrosh@panasas.com>
Signed-off-by: Oleg Drokin <green@linuxhacker.ru>
Signed-off-by: Tao Guo <guotao@nrchpc.ac.cn>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 94ad1c80e28f9700c84b4d28d1e5302ddf63a6fd
Author: Fred Isaman <iisaman@netapp.com>
Date: Tue Mar 1 01:34:14 2011 +0000
NFSv4.1: coelesce across layout stripes
Add a pg_test layout driver hook which is used to avoid coelescing I/O across
layout stripes.
Signed-off-by: Andy Adamson <andros@netapp.com>
Signed-off-by: Andy Adamson <andros@citi.umich.edu>
Signed-off-by: Dean Hildebrand <dhildeb@us.ibm.com>
Signed-off-by: Fred Isaman <iisaman@citi.umich.edu>
Signed-off-by: Fred Isaman <iisaman@netapp.com>
Signed-off-by: Benny Halevy <bhalevy@panasas.com>
Signed-off-by: Boaz Harrosh <bharrosh@panasas.com>
Signed-off-by: Oleg Drokin <green@linuxhacker.ru>
Signed-off-by: Tao Guo <guotao@nrchpc.ac.cn>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit d684d2ae10a4f95d3035abf698d7d611ff2cd279
Author: Fred Isaman <iisaman@netapp.com>
Date: Tue Mar 1 01:34:13 2011 +0000
NFSv4.1: lseg refcounting
Prepare put_lseg and get_lseg to be called from the pNFS I/O code.
Pull common code from pnfs_lseg_locked to call from pnfs_lseg.
Inline pnfs_lseg_locked into it's only caller.
Signed-off-by: Fred Isaman <iisaman@netapp.com>
Signed-off-by: Benny Halevy <bhalevy@panasas.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 94de8b27d0dcb2608d56a7e5c2941b87e6da7ce3
Author: Andy Adamson <andros@netapp.com>
Date: Tue Mar 1 01:34:12 2011 +0000
NFSv4.1: add MDS mount DS only check
The DS only role cannot be used to mount.
Signed-off-by: Andy Adamson <andros@netapp.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit d6fb79d433d0a34c36bdf74eaf90857193a6261f
Author: Andy Adamson <andros@netapp.com>
Date: Tue Mar 1 01:34:11 2011 +0000
NFSv4.1: new flag for lease time check
Data servers cannot send nfs4_proc_get_lease_time. but still need to setup
state renewal. Add the NFS_CS_CHECK_LEASE_TIME bit to indicate if the lease
time can be checked.
Signed-off-by: Andy Adamson <andros@netapp.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit d3b4c9d76738df49a7db7682c2518a0ef9f7391d
Author: Andy Adamson <andros@netapp.com>
Date: Tue Mar 1 01:34:10 2011 +0000
NFSv4.1: new flag for state renewal check
Data servers not sharing a session with the mount MDS always have an empty
cl_superblocks list.
Replace the cl_superblocks empty list check to see if it is time to shut down
renewd with the NFS_CS_STOP_RENEW bit which is not set by such a data server.
Signed-off-by: Andy Adamson <andros@netapp.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 89d1ea65798953b251e399b17f32d31033889ae0
Author: Andy Adamson <andros@netapp.com>
Date: Tue Mar 1 01:34:09 2011 +0000
NFSv4.1: send zero stateid seqid on v4.1 i/o
Data servers require a zero stateid seqid, and there is no advantage to not
doing the same for all NFSv4.1
Signed-off-by: Andy Adamson <andros@netapp.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 45a52a02072b2a7e265f024cfdb00127e08dd9f2
Author: Andy Adamson <andros@netapp.com>
Date: Tue Mar 1 01:34:08 2011 +0000
NFS move nfs_client initialization into nfs_get_client
Now nfs_get_client returns an nfs_client ready to be used no matter if it was
found or created.
Signed-off-by: Andy Adamson <andros@netapp.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit bf9c1387ca80deac792c9ecf1c64dfcc5d1cc768
Author: Andy Adamson <andros@netapp.com>
Date: Tue Mar 1 01:34:07 2011 +0000
NFSv4.1: put_layout_hdr can remove nfsi->layout
Prevents an Oops triggered by CB_LAYOUTRECALL and LAYOUTGET race on a
pnfs_layout_hdr first pnfs_layout_segment.
Signed-off-by: Andy Adamson <andros@netapp.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 6f78befc417dd7122249706b49520da29ba58451
Author: Andy Adamson <andros@netapp.com>
Date: Tue Mar 1 01:34:06 2011 +0000
NFSv4: remove CONFIG_NFS_V4 from nfs_read_data
Cleanup nfs_read_data. We also won't use CONFIG_NFS_V4_1 for additional
NFSv4.1 fields in subsequent patches.
Signed-off-by: Andy Adamson <andros@netapp.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 136028967a283929c6f01518d0700b73fa622d56
Author: Fred Isaman <iisaman@netapp.com>
Date: Fri Feb 11 15:42:38 2011 +0000
NFS: change nfs_writeback_done to return void
The return values are not used by any callers.
Signed-off-by: Fred Isaman <iisaman@netapp.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 83762c56c1ba7c5b4b92fb32d570661633228bc6
Author: Fred Isaman <iisaman@netapp.com>
Date: Fri Feb 11 15:42:37 2011 +0000
NFS: remove pointless if statement in nfs_direct_write_result
The code was doing nothing more in either branch of the if.
Signed-off-by: Fred Isaman <iisaman@netapp.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit eabf5baaaaf41b6a0273043cfb06d53dca67acef
Author: Fred Isaman <iisaman@netapp.com>
Date: Fri Feb 11 15:42:36 2011 +0000
RPC: clarify rpc_run_task error handling
rpc_run_task can only fail if it is not passed in a preallocated task.
However, that is not at all clear with the current code. So
remove several impossible to occur failure checks.
Signed-off-by: Fred Isaman <iisaman@netapp.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit cee6a5372f8804f58acc87f07816f64db36718e2
Author: Fred Isaman <iisaman@netapp.com>
Date: Fri Feb 11 15:42:35 2011 +0000
RPC: remove check for impossible condition in rpc_make_runnable
queue_work() only returns 0 or 1, never a negative value.
Signed-off-by: Fred Isaman <iisaman@netapp.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit f49f9baac8f63de9cbc17a0a84e04060496e8e76
Author: Fred Isaman <iisaman@netapp.com>
Date: Thu Feb 3 18:28:52 2011 +0000
pnfs: fix pnfs lock inversion of i_lock and cl_lock
The pnfs code was using throughout the lock order i_lock, cl_lock.
This conflicts with the nfs delegation code. Rework the pnfs code
to avoid taking both locks simultaneously.
Currently the code takes the double lock to add/remove the layout to a
nfs_client list, while atomically checking that the list of lsegs is
empty. To avoid this, we rely on existing serializations. When a
layout is initialized with lseg count equal zero, LAYOUTGET's
openstateid serialization is in effect, making it safe to assume it
stays zero unless we change it. And once a layout's lseg count drops
to zero, it is set as DESTROYED and so will stay at zero.
Signed-off-by: Fred Isaman <iisaman@netapp.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 9f52c2525e09854ed6aa4cbd83915a56226d86c1
Author: Fred Isaman <iisaman@netapp.com>
Date: Thu Feb 3 18:28:51 2011 +0000
pnfs: do not need to clear NFS_LAYOUT_BULK_RECALL flag
We do not need to clear the NFS_LAYOUT_BULK_RECALL, as setting it
guarantees that NFS_LAYOUT_DESTROYED will be set once any outstanding
io is finished.
Signed-off-by: Fred Isaman <iisaman@netapp.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 38511722446993d926861696194c39ef135d85a4
Author: Fred Isaman <iisaman@netapp.com>
Date: Thu Feb 3 18:28:50 2011 +0000
pnfs: avoid incorrect use of layout stateid
The code could violate the following from RFC5661, section 12.5.3:
"Once a client has no more layouts on a file, the layout stateid is no
longer valid and MUST NOT be used."
This can occur when a layout already has a lseg, starts another
non-everlapping LAYOUTGET, and a CB_LAYOUTRECALL for the existing lseg
is processed before we hit pnfs_layout_process().
Solve by setting, each time the client has no more lsegs for a file, a
flag which blocks further use of the layout and triggers its removal.
This also fixes a second bug which occurs in the same instance as
above. If we actually use pnfs_layout_process, we add the new lseg to
the layout, but the layout has been removed from the nfs_client list
by the intervening CB_LAYOUTRECALL and will not be added back. Thus
the newly acquired lseg will not be properly returned in the event of
a subsequent CB_LAYOUTRECALL.
Signed-off-by: Fred Isaman <iisaman@netapp.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
--
Trond Myklebust
Linux NFS client maintainer
NetApp
Trond.Myklebust@netapp.com
www.netapp.com
^ permalink raw reply [flat|nested] 25+ messages in thread
* [GIT PULL] Please pull NFS client changes...
@ 2011-01-11 23:08 Trond Myklebust
0 siblings, 0 replies; 25+ messages in thread
From: Trond Myklebust @ 2011-01-11 23:08 UTC (permalink / raw)
To: Linus Torvalds; +Cc: linux-nfs, linux-kernel
Hi Linus,
Please pull from the "nfs-for-2.6.38" branch of the repository at
git pull git://git.linux-nfs.org/projects/trondmy/nfs-2.6.git nfs-for-2.6.38
This will update the following files through the appended changesets.
Cheers,
Trond
----
fs/lockd/Makefile | 6 +-
fs/lockd/clnt4xdr.c | 605 ++++++++
fs/lockd/clntlock.c | 4 +-
fs/lockd/clntproc.c | 18 +-
fs/lockd/clntxdr.c | 627 +++++++++
fs/lockd/host.c | 409 ++++---
fs/lockd/mon.c | 110 +-
fs/lockd/svc4proc.c | 20 +-
fs/lockd/svclock.c | 34 +-
fs/lockd/svcproc.c | 28 +-
fs/lockd/xdr.c | 287 ----
fs/lockd/xdr4.c | 255 ----
fs/nfs/callback.c | 83 +-
fs/nfs/callback.h | 59 +-
fs/nfs/callback_proc.c | 326 +++--
fs/nfs/callback_xdr.c | 143 ++-
fs/nfs/client.c | 302 +++--
fs/nfs/delegation.c | 362 ++++--
fs/nfs/delegation.h | 1 +
fs/nfs/dir.c | 72 +-
fs/nfs/idmap.c | 2 +-
fs/nfs/inode.c | 3 +-
fs/nfs/internal.h | 19 +-
fs/nfs/mount_clnt.c | 83 +-
fs/nfs/nfs2xdr.c | 1294 ++++++++++++------
fs/nfs/nfs3xdr.c | 2889 ++++++++++++++++++++++++++++-----------
fs/nfs/nfs4_fs.h | 13 +-
fs/nfs/nfs4filelayout.c | 6 +-
fs/nfs/nfs4proc.c | 188 ++-
fs/nfs/nfs4renewd.c | 11 +-
fs/nfs/nfs4state.c | 293 +++--
fs/nfs/nfs4xdr.c | 1426 +++++++++----------
fs/nfs/pagelist.c | 7 +-
fs/nfs/pnfs.c | 524 +++++---
fs/nfs/pnfs.h | 76 +-
fs/nfs/proc.c | 5 +-
fs/nfs/super.c | 18 +-
fs/nfs/unlink.c | 2 +-
fs/nfsd/nfs4callback.c | 686 ++++++----
include/linux/lockd/debug.h | 10 -
include/linux/lockd/lockd.h | 6 +-
include/linux/nfs3.h | 3 +
include/linux/nfs4.h | 8 +-
include/linux/nfs_fs_sb.h | 15 +-
include/linux/nfs_xdr.h | 6 +-
include/linux/sunrpc/auth.h | 8 +-
include/linux/sunrpc/bc_xprt.h | 15 +-
include/linux/sunrpc/clnt.h | 4 +-
include/linux/sunrpc/svc.h | 2 +-
include/linux/sunrpc/svc_xprt.h | 1 +
include/linux/sunrpc/xdr.h | 14 +-
net/sunrpc/auth.c | 28 +-
net/sunrpc/auth_gss/auth_gss.c | 44 +-
net/sunrpc/bc_svc.c | 2 +-
net/sunrpc/clnt.c | 21 +-
net/sunrpc/rpc_pipe.c | 2 +-
net/sunrpc/rpcb_clnt.c | 147 +--
net/sunrpc/svc.c | 36 +-
net/sunrpc/svcsock.c | 106 ++-
net/sunrpc/xdr.c | 155 ++-
60 files changed, 7852 insertions(+), 4077 deletions(-)
commit 357f54d6b38252737116a6d631f6ac28ded018ed
Author: Andy Adamson <andros@netapp.com>
Date: Tue Dec 14 10:11:57 2010 -0500
NFS fix the setting of exchange id flag
Indicate support for referrals. Do not set any PNFS roles. Check the flags
returned by the server for validity. Do not use exchange flags from an old
client ID instance when recovering a client ID.
Update the EXCHID4_FLAG_XXX set to RFC 5661.
Signed-off-by: Andy Adamson <andros@netapp.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 6650239a4b01077e80d5a4468562756d77afaa59
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date: Sat Jan 8 17:45:38 2011 -0500
NFS: Don't use vm_map_ram() in readdir
vm_map_ram() is not available on NOMMU platforms, and causes trouble
on incoherrent architectures such as ARM when we access the page data
through both the direct and the virtual mapping.
The alternative is to use the direct mapping to access page data
for the case when we are not crossing a page boundary, but to copy
the data into a linear scratch buffer when we are accessing data
that spans page boundaries.
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
Tested-by: Marc Kleine-Budde <mkl@pengutronix.de>
Cc: stable@kernel.org [2.6.37]
commit d035c36c58dd9183ad6aa7875dea89893faedb55
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date: Tue Dec 21 10:45:27 2010 -0500
NFSv4: Ensure continued open and lockowner name uniqueness
In order to enable migration support, we will want to move some of the
structures that are subject to migration into the struct nfs_server.
In particular, if we are to move the state_owner and state_owner_id to
being a per-filesystem structure, then we should label the resulting
open/lock owners with a per-filesytem label to ensure global uniqueness.
This patch does so by adding the super block s_dev to the open/lock owner
name.
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit d3978bb325510f0a26ebd92f211b36c5f98b2306
Author: Chuck Lever <chuck.lever@oracle.com>
Date: Fri Dec 24 01:33:04 2010 +0000
NFS: Move cl_delegations to the nfs_server struct
Delegations are per-inode, not per-nfs_client. When a server file
system is migrated, delegations on the client must be moved from the
source to the destination nfs_server. Make it easier to manage a
mount point's delegation list across a migration event by moving the
list to the nfs_server struct.
Clean up: I added documenting comments to public functions I changed
in this patch. For consistency I added comments to all the other
public functions in fs/nfs/delegation.c.
Signed-off-by: Chuck Lever <chuck.lever@oracle.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit dda4b225623f316335052828c24a16e2da313f8f
Author: Chuck Lever <chuck.lever@oracle.com>
Date: Fri Dec 24 01:32:54 2010 +0000
NFS: Introduce nfs_detach_delegations()
Clean up: Refactor code that takes clp->cl_lock and calls
nfs_detach_delegations_locked() into its own function.
While we're changing the call sites, get rid of the second parameter
and the logic in nfs_detach_delegations_locked() that uses it, since
callers always set that parameter of nfs_detach_delegations_locked()
to NULL.
Signed-off-by: Chuck Lever <chuck.lever@oracle.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 24d292b894273495f9664bb495e575f8cb7e8cac
Author: Chuck Lever <chuck.lever@oracle.com>
Date: Fri Dec 24 01:32:43 2010 +0000
NFS: Move cl_state_owners and related fields to the nfs_server struct
NFSv4 migration needs to reassociate state owners from the source to
the destination nfs_server data structures. To make that easier, move
the cl_state_owners field to the nfs_server struct. cl_openowner_id
and cl_lockowner_id accompany this move, as they are used in
conjunction with cl_state_owners.
The cl_lock field in the parent nfs_client continues to protect all
three of these fields.
Signed-off-by: Chuck Lever <chuck.lever@oracle.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit fca5238ef3232cd0cf4bf0457e751b3bb20912a9
Author: Chuck Lever <chuck.lever@oracle.com>
Date: Fri Dec 24 01:32:32 2010 +0000
NFS: Allow walking nfs_client.cl_superblocks list outside client.c
We're about to move some fields from struct nfs_client to struct
nfs_server. There is a many-to-one relationship between nfs_servers
and nfs_clients. After these fields are moved to the nfs_server
struct, to visit all of the data in these fields that is owned by one
nfs_client, code will need to visit each nfs_server on the
cl_superblocks list for that nfs_client.
To serialize changes to the cl_superblocks list during these little
expeditions, protect the list with RCU.
Signed-off-by: Chuck Lever <chuck.lever@oracle.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit f7e8917a67980924651a9e244510e63ef05c7755
Author: Fred Isaman <iisaman@netapp.com>
Date: Thu Jan 6 11:36:32 2011 +0000
pnfs: layout roc code
A layout can request return-on-close. How this interacts with the
forgetful model of never sending LAYOUTRETURNS is a bit ambiguous.
We forget any layouts marked roc, and wait for them to be completely
forgotten before continuing with the close. In addition, to compensate
for races with any inflight LAYOUTGETs, and the fact that we do not get
any layout stateid back from the server, we set the barrier to the worst
case scenario of current_seqid + number of outstanding LAYOUTGETS.
Signed-off-by: Fred Isaman <iisaman@netapp.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 36840370845629e6cb4324d1dd4aff6778670503
Author: Alexandros Batsakis <batsakis@netapp.com>
Date: Thu Jan 6 11:36:31 2011 +0000
pnfs: update nfs4_callback_recallany to handle layouts
While here, update the code a bit.
Signed-off-by: Alexandros Batsakis <batsakis@netapp.com>
Signed-off-by: Fred Isaman <iisaman@netapp.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 43f1b3da8b35d706d6c47880fc211d2519b4a587
Author: Fred Isaman <iisaman@netapp.com>
Date: Thu Jan 6 11:36:30 2011 +0000
pnfs: add CB_LAYOUTRECALL handling
This is the heart of the wave 2 submission. Add the code to trigger
drain and forget of any afected layouts. In addition, we set a
"barrier", below which any LAYOUTGET reply is ignored. This is to
compensate for the fact that we do not wait for outstanding LAYOUTGETs
to complete as per section 12.5.5.2.1 of RFC 5661.
Signed-off-by: Fred Isaman <iisaman@netapp.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit f2a625616045fe46e1d5fceebdd825f5acdecdb7
Author: Fred Isaman <iisaman@netapp.com>
Date: Thu Jan 6 11:36:29 2011 +0000
pnfs: CB_LAYOUTRECALL xdr code
This is the xdr decoding for CB_LAYOUTRECALL.
Signed-off-by: Alexandros Batsakis <batsakis@netapp.com>
Signed-off-by: Dean Hildebrand <dhildeb@us.ibm.com>
Signed-off-by: Marc Eshel <eshel@almaden.ibm.com>
Signed-off-by: Andy Adamson <andros@netapp.com>
Signed-off-by: Benny Halevy <bhalevy@panasas.com>
Signed-off-by: Fred Isaman <iisaman@netapp.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit cc6e5340b0981feac5a00a992bab6154cb4b1fa1
Author: Fred Isaman <iisaman@netapp.com>
Date: Thu Jan 6 11:36:28 2011 +0000
pnfs: change lo refcounting to atomic_t
This will be required to allow us to grab reference outside of i_lock.
While we are at it, make put_layout_hdr take the same argument as all the
related functions.
Signed-off-by: Fred Isaman <iisaman@netapp.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit fc1794c5b04f5322bad05385cd91b52ec85aab72
Author: Fred Isaman <iisaman@netapp.com>
Date: Thu Jan 6 11:36:27 2011 +0000
pnfs: check that partial LAYOUTGET return is ignored
Either a bad server reply, or our ignoring of multiple array segments in
a reply, can cause a reply to not meet our requirements. Ensure
that we ignore such replies.
Signed-off-by: Fred Isaman <iisaman@netapp.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 2130ff663633e8a57921779ebfe62fc39d5585ec
Author: Fred Isaman <iisaman@netapp.com>
Date: Thu Jan 6 11:36:26 2011 +0000
pnfs: add layout to client list before sending rpc
Since this list will be used to search for layouts to recall,
this is necessary to avoid a race where the recall comes in,
sees there is nothing in the client list, and prepares to return
NOMATCHING, while the LAYOUTGET gets processed before the recall
updates the stateid.
Signed-off-by: Fred Isaman <iisaman@netapp.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit cf7d63f1f9895713551df2e6d18b006f8af26e91
Author: Fred Isaman <iisaman@netapp.com>
Date: Thu Jan 6 11:36:25 2011 +0000
pnfs: serialize LAYOUTGET(openstateid)
We shouldn't send a LAYOUTGET(openstateid) unless all outstanding RPCs
using the previous stateid are completed. This requires choosing the
stateid to encode earlier, so we can abort if one is not available (we
want to use the open stateid, but a LAYOUTGET is already out using
it), and adding a count of the number of outstanding rpc calls using
layout state (which for now consist solely of LAYOUTGETs).
Signed-off-by: Fred Isaman <iisaman@netapp.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit c31663d4a1fac5ce1954d656cbcf80eb883b814a
Author: Fred Isaman <iisaman@netapp.com>
Date: Thu Jan 6 11:36:24 2011 +0000
pnfs: layoutget rpc code cleanup
No functional changes, just some code minor code rearrangement and
comments.
Signed-off-by: Fred Isaman <iisaman@netapp.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 4541d16c024ce40a0781e03c185ecdfe34aec46f
Author: Fred Isaman <iisaman@netapp.com>
Date: Thu Jan 6 11:36:23 2011 +0000
pnfs: change how lsegs are removed from layout list
This is to prepare the way for sensible io draining. Instead of just
removing the lseg from the list, we instead clear the VALID flag
(preventing new io from grabbing references to the lseg) and remove
the reference holding it in the list. Thus the lseg will be removed
once any io in progress completes and any references still held are
dropped.
Signed-off-by: Fred Isaman <iisaman@netapp.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit fd6002e9b8a93220d5f53b93d9624caf73cdc8a2
Author: Fred Isaman <iisaman@netapp.com>
Date: Thu Jan 6 11:36:22 2011 +0000
pnfs: change layout state seqlock to a spinlock
This prepares for future changes, where the layout state needs
to change atomically with several other variables. In particular,
it will need to know if lo->segs is empty, as we test that instead
of manipulating the NFS_LAYOUT_STATEID_SET bit. Moreover, the
layoutstateid is not really a read-mostly structure, as it is
written almost as often as it is read.
The behavior of pnfs_get_layout_stateid is also slightly changed, so that
it no longer changes the stateid. Its name is changed to +pnfs_choose_layoutget_stateid.
Signed-off-by: Fred Isaman <iisaman@netapp.com>
Signed-off-by: Benny Halevy <bhalevy@panasas.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit b7edfaa1983362842351e425adeb8e297b4c11fb
Author: Fred Isaman <iisaman@netapp.com>
Date: Thu Jan 6 11:36:21 2011 +0000
pnfs: add prefix to struct pnfs_layout_hdr fields
Signed-off-by: Fred Isaman <iisaman@netapp.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 566052c53b5146e23a99ab95fb5c11f8a295a084
Author: Fred Isaman <iisaman@netapp.com>
Date: Thu Jan 6 11:36:20 2011 +0000
pnfs: add prefix to struct pnfs_layout_segment fields
While we are renaming all the fields, change lo->state to lo->plh_flags.
Signed-off-by: Fred Isaman <iisaman@netapp.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit daaa82d1c72e10dc16cad3a810e225f9188dc7aa
Author: Fred Isaman <iisaman@netapp.com>
Date: Thu Jan 6 11:36:19 2011 +0000
pnfs: remove unnecessary field lgp->status
Signed-off-by: Fred Isaman <iisaman@netapp.com>
Signed-off-by: Benny Halevy <bhalevy@panasas.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 52fabd73199cd00932f92c9f548bdf66a5bbc23d
Author: Fred Isaman <iisaman@netapp.com>
Date: Thu Jan 6 11:36:18 2011 +0000
pnfs: fix incorrect comment in destroy_lseg
Comment references get_layout_hdr_locked, which never existed in
submitted code.
Signed-off-by: Fred Isaman <iisaman@netapp.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 4a19de0f4b693139bb10b7cc3cfe1f618576ba67
Author: Andy Adamson <andros@netapp.com>
Date: Thu Jan 6 02:04:35 2011 +0000
NFS rename client back channel transport field
Differentiate from server backchannel
Signed-off-by: Andy Adamson <andros@netapp.com>
Acked-by: Bruce Fields <bfields@redhat.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 42acd021824578fa0eeb6eb58d457c23ec5dc9c0
Author: Andy Adamson <andros@netapp.com>
Date: Thu Jan 6 02:04:34 2011 +0000
NFS add session back channel draining
Currently session draining only drains the fore channel.
The back channel processing must also be drained.
Use the back channel highest_slot_used to indicate that a callback is being
processed by the callback thread. Move the session complete to be per channel.
When the session is draininig, wait for any current back channel processing
to complete and stop all new back channel processing by returning NFS4ERR_DELAY
to the back channel client.
Drain the back channel, then the fore channel.
Signed-off-by: Andy Adamson <andros@netapp.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit ece0de633c4d9106c39ea9f0db1638c42ead2541
Author: Andy Adamson <andros@netapp.com>
Date: Thu Jan 6 02:04:33 2011 +0000
NFS RPC_AUTH_GSS unsupported on v4.1 back channel
Signed-off-by: Andy Adamson <andros@netapp.com>
Acked-by: Bruce Fields <bfields@redhat.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit c36fca52f5e4594ffd0ff175b328966b0d393184
Author: Andy Adamson <andros@netapp.com>
Date: Thu Jan 6 02:04:32 2011 +0000
NFS refactor nfs_find_client and reference client across callback processing
Fixes a bug where the nfs_client could be freed during callback processing.
Refactor nfs_find_client to use minorversion specific means to locate the
correct nfs_client structure.
In the NFS layer, V4.0 clients are found using the callback_ident field in the
CB_COMPOUND header. V4.1 clients are found using the sessionID in the
CB_SEQUENCE operation which is also compared against the sessionID associated
with the back channel thread after a successful CREATE_SESSION.
Each of these methods finds the one an only nfs_client associated
with the incoming callback request - so nfs_find_client_next is not needed.
In the RPC layer, the pg_authenticate call needs to find the nfs_client. For
the v4.0 callback service, the callback identifier has not been decoded so a
search by address, version, and minorversion is used. The sessionid for the
sessions based callback service has (usually) not been set for the
pg_authenticate on a CB_NULL call which can be sent prior to the return
of a CREATE_SESSION call, so the sessionid associated with the back channel
thread is not used to find the client in pg_authenticate for CB_NULL calls.
Pass the referenced nfs_client to each CB_COMPOUND operation being proceesed
via the new cb_process_state structure. The reference is held across
cb_compound processing.
Use the new cb_process_state struct to move the NFS4ERR_RETRY_UNCACHED_REP
processing from process_op into nfs4_callback_sequence where it belongs.
Signed-off-by: Andy Adamson <andros@netapp.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 2c2618c6f29c41a0a966f14f05c8bf45fcabb750
Author: Andy Adamson <andros@netapp.com>
Date: Thu Jan 6 02:04:31 2011 +0000
NFS associate sessionid with callback connection
The sessions based callback service is started prior to the CREATE_SESSION call
so that it can handle CB_NULL requests which can be sent before the
CREATE_SESSION call returns and the session ID is known.
Set the callback sessionid after a sucessful CREATE_SESSION.
Signed-off-by: Andy Adamson <andros@netapp.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit f4eecd5da3422e82e88e36c33cbd2595eebcacb1
Author: Andy Adamson <andros@netapp.com>
Date: Thu Jan 6 02:04:30 2011 +0000
NFS implement v4.0 callback_ident
Use the small id to pointer translator service to provide a unique callback
identifier per SETCLIENTID call used to identify the v4.0 callback service
associated with the clientid.
Signed-off-by: Andy Adamson <andros@netapp.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit ea00528126a701845d7c445e725b271940381e3d
Author: Andy Adamson <andros@netapp.com>
Date: Thu Jan 6 02:04:29 2011 +0000
NFS do not clear minor version at nfs_client free
Resetting the client minor version operations causes nfs4_destroy_callback
to fail to shutdown the NFSv4.1 callback service.
There is no reason to reset the client minorversion operations when the
nfs_client struct is being freed.
Remove the minorverion reset and rename the function.
Signed-off-by: Andy Adamson <andros@netapp.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 01c9a0bc60507af7f28cb9138a81836de4528199
Author: Andy Adamson <andros@netapp.com>
Date: Thu Jan 6 02:04:28 2011 +0000
NFS use svc_create_xprt for NFSv4.1 callback service
The new back channel transport means we call the normal creation routine as
well as svc_xprt_put.
Signed-off-by: Andy Adamson <andros@netapp.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 16b2d1e1d12de000404d7c845d0db1226511f84d
Author: Andy Adamson <andros@netapp.com>
Date: Thu Jan 6 02:04:27 2011 +0000
SUNRPC register and unregister the back channel transport
Signed-off-by: Andy Adamson <andros@netapp.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 1f11a034cdc4b45ee56d51b87a9e37cb776fb15b
Author: Andy Adamson <andros@netapp.com>
Date: Thu Jan 6 02:04:26 2011 +0000
SUNRPC new transport for the NFSv4.1 shared back channel
Move the current sock create and destroy routines into the new transport ops.
Back channel socket will be destroyed by the svc_closs_all call in svc_destroy.
Added check: only TCP supported on shared back channel.
Signed-off-by: Andy Adamson <andros@netapp.com>
Acked-by: Bruce Fields <bfields@redhat.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 71e161a6a9fa021a280e564254fcda894e6fbd14
Author: Andy Adamson <andros@netapp.com>
Date: Thu Jan 6 02:04:25 2011 +0000
SUNRPC fix bc_send print
Signed-off-by: Andy Adamson <andros@netapp.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 4b5b3ba16be1b195d2e1161746637acd4b9fed4f
Author: Andy Adamson <andros@netapp.com>
Date: Thu Jan 6 02:04:24 2011 +0000
SUNRPC move svc_drop to caller of svc_process_common
The NFSv4.1 shared back channel does not need to call svc_drop because the
callback service never outlives the single connection it services, and it
reuses it's buffers and keeps the trasport.
Signed-off-by: Andy Adamson <andros@netapp.com>
Acked-by: Bruce Fields <bfields@redhat.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 64c2ce8b72eceec4030b04bca32d098b3d1431bb
Author: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com>
Date: Thu Dec 9 11:35:25 2010 +0000
nfsv4: Switch to generic xattr handling code
This patch make nfsv4 use the generic xattr handling code
to get the nfsv4 acl. This will help us to add richacl
support to nfsv4 in later patches
Signed-off-by: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit a8a5da996df7d2d91b5aef2752da9adcefea4bc6
Author: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com>
Date: Thu Dec 9 11:35:14 2010 +0000
nfs: Set MS_POSIXACL always
We want to skip VFS applying mode for NFS. So set MS_POSIXACL always
and selectively use umask. Ideally we would want to use umask only
when we don't have inheritable ACEs set. But NFS currently don't
allow to send umask to the server. So this is best what we can do
and this is consistent with NFSv3
Signed-off-by: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit bf0c84f1614bffc59565d04f09b9ac6b1aa269a9
Author: Namhyung Kim <namhyung@gmail.com>
Date: Tue Dec 28 17:02:46 2010 +0000
NFS: use ERR_CAST()
Use ERR_CAST() intead of wierd-looking cast.
Signed-off-by: Namhyung Kim <namhyung@gmail.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 5f3e97c9ee6290befb5a2e78baf95ff951a8a34a
Author: J. Bruce Fields <bfields@redhat.com>
Date: Tue Dec 21 23:49:34 2010 +0000
nfs: fix mispelling of idmap CONFIG symbol
Trivial, but confusing when you're trying to grep through this
code....
Signed-off-by: J. Bruce Fields <bfields@redhat.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit beb0f0a9fba1fa98b378329a9a5b0a73f25097ae
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date: Mon Dec 20 21:19:26 2010 +0000
kernel panic when mount NFSv4
On Tue, 2010-12-14 at 16:58 +0800, Mi Jinlong wrote:
> Hi,
>
> When testing NFSv4 at RHEL6 with kernel 2.6.32, I got a kernel panic
> at NFS client's __rpc_create_common function.
>
> The panic place is:
> rpc_mkpipe
> __rpc_lookup_create() <=== find pipefile *idmap*
> __rpc_mkpipe() <=== pipefile is *idmap*
> __rpc_create_common()
> ****** BUG_ON(!d_unhashed(dentry)); ****** *panic*
>
> It means that the dentry's d_flags have be set DCACHE_UNHASHED,
> but it should not be set here.
>
> Is someone known this bug? or give me some idea?
>
> A reproduce program is append, but it can't reproduce the bug every time.
> the export is: "/nfsroot *(rw,no_root_squash,fsid=0,insecure)"
>
> And the panic message is append.
>
> ============================================================================
> #!/bin/sh
>
> LOOPTOTAL=768
> LOOPCOUNT=0
> ret=0
>
> while [ $LOOPCOUNT -ne $LOOPTOTAL ]
> do
> ((LOOPCOUNT += 1))
> service nfs restart
> /usr/sbin/rpc.idmapd
> mount -t nfs4 127.0.0.1:/ /mnt|| return 1;
> ls -l /var/lib/nfs/rpc_pipefs/nfs/*/
> umount /mnt
> echo $LOOPCOUNT
> done
>
> ===============================================================================
> Code: af 60 01 00 00 89 fa 89 f0 e8 64 cf 89 f0 e8 5c 7c 64 cf 31 c0 8b 5c 24 10 8b
> 74 24 14 8b 7c 24 18 8b 6c 24 1c 83 c4 20 c3 <0f> 0b eb fc 8b 46 28 c7 44 24 08 20
> de ee f0 c7 44 24 04 56 ea
> EIP:[<f0ee92ea>] __rpc_create_common+0x8a/0xc0 [sunrpc] SS:ESP 0068:eccb5d28
> ---[ end trace 8f5606cd08928ed2]---
> Kernel panic - not syncing: Fatal exception
> Pid:7131, comm: mount.nfs4 Tainted: G D -------------------2.6.32 #1
> Call Trace:
> [<c080ad18>] ? panic+0x42/0xed
> [<c080e42c>] ? oops_end+0xbc/0xd0
> [<c040b090>] ? do_invalid_op+0x0/0x90
> [<c040b10f>] ? do_invalid_op+0x7f/0x90
> [<f0ee92ea>] ? __rpc_create_common+0x8a/0xc0[sunrpc]
> [<f0edc433>] ? rpc_free_task+0x33/0x70[sunrpc]
> [<f0ed6508>] ? prc_call_sync+0x48/0x60[sunrpc]
> [<f0ed656e>] ? rpc_ping+0x4e/0x60[sunrpc]
> [<f0ed6eaf>] ? rpc_create+0x38f/0x4f0[sunrpc]
> [<c080d80b>] ? error_code+0x73/0x78
> [<f0ee92ea>] ? __rpc_create_common+0x8a/0xc0[sunrpc]
> [<c0532bda>] ? d_lookup+0x2a/0x40
> [<f0ee94b1>] ? rpc_mkpipe+0x111/0x1b0[sunrpc]
> [<f10a59f4>] ? nfs_create_rpc_client+0xb4/0xf0[nfs]
> [<f10d6c6d>] ? nfs_fscache_get_client_cookie+0x1d/0x50[nfs]
> [<f10d3fcb>] ? nfs_idmap_new+0x7b/0x140[nfs]
> [<c05e76aa>] ? strlcpy+0x3a/0x60
> [<f10a60ca>] ? nfs4_set_client+0xea/0x2b0[nfs]
> [<f10a6d0c>] ? nfs4_create_server+0xac/0x1b0[nfs]
> [<c04f1400>] ? krealloc+0x40/0x50
> [<f10b0e8b>] ? nfs4_remote_get_sb+0x6b/0x250[nfs]
> [<c04f14ec>] ? kstrdup+0x3c/0x60
> [<c0520739>] ? vfs_kern_mount+0x69/0x170
> [<f10b1a3c>] ? nfs_do_root_mount+0x6c/0xa0[nfs]
> [<f10b1b47>] ? nfs4_try_mount+0x37/0xa0[nfs]
> [<f10afe6d>] ? nfs4_validate_text_mount_data+-x7d/0xf0[nfs]
> [<f10b1c42>] ? nfs4_get_sb+0x92/0x2f0
> [<c0520739>] ? vfs_kern_mount+0x69/0x170
> [<c05366d2>] ? get_fs_type+0x32/0xb0
> [<c052089f>] ? do_kern_mount+0x3f/0xe0
> [<c053954f>] ? do_mount+0x2ef/0x740
> [<c0537740>] ? copy_mount_options+0xb0/0x120
> [<c0539a0e>] ? sys_mount+0x6e/0xa0
Hi,
Does the following patch fix the problem?
Cheers
Trond
--------------------------
SUNRPC: Fix a BUG in __rpc_create_common
From: Trond Myklebust <Trond.Myklebust@netapp.com>
Mi Jinlong reports:
When testing NFSv4 at RHEL6 with kernel 2.6.32, I got a kernel panic
at NFS client's __rpc_create_common function.
The panic place is:
rpc_mkpipe
__rpc_lookup_create() <=== find pipefile *idmap*
__rpc_mkpipe() <=== pipefile is *idmap*
__rpc_create_common()
****** BUG_ON(!d_unhashed(dentry)); ****** *panic*
The test is wrong: we can find ourselves with a hashed negative dentry here
if the idmapper tried to look up the file before we got round to creating
it.
Just replace the BUG_ON() with a d_drop(dentry).
Reported-by: Mi Jinlong <mijinlong@cn.fujitsu.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 51f128ea1c9224c1e3cf6c6a1498431d97699668
Author: Dan Carpenter <error27@gmail.com>
Date: Sun Jan 2 20:20:42 2011 +0000
lockd: double unlock in next_host_state()
We unlock again after we goto out.
Signed-off-by: Dan Carpenter <error27@gmail.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 878215feb8b2417c4700090b4335739858cf7b5a
Author: Jesper Juhl <jj@chaosbits.net>
Date: Fri Dec 24 22:22:37 2010 +0000
NFS: Don't leak in nfs_proc_symlink()
Hi,
In fs/nfs/proc.c::nfs_proc_symlink() we will leak memory if either
nfs_alloc_fhandle() or nfs_alloc_fattr() returns NULL but the other one
doesn't.
This patch ensures memory allocated by one when the other fails is always
released (this is safe since nfs_free_fattr() and nfs_free_fhandle() both
call kfree which deals gracefully with NULL pointers).
Signed-off-by: Jesper Juhl <jj@chaosbits.net>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 1174dd1f890b7f8be8ec6a7071657fe8f59e18b7
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date: Tue Dec 21 10:52:24 2010 -0500
NFSv4: Convert a few commas into semicolons...
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit b3bcedadf23264c3b7afcbfbfe1965a17ef1352c
Author: Joe Perches <joe@perches.com>
Date: Tue Dec 21 10:52:24 2010 -0500
net/sunrpc/clnt.c: Convert sprintf_symbol to %ps
Signed-off-by: Joe Perches <joe@perches.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit aa69947399a119d7f1b35bbcd62c849839b35449
Author: Stanislav Kinsbursky <skinsbursky@parallels.com>
Date: Wed Dec 8 12:40:13 2010 +0300
NFS: suppressing showing of default mount port value in /proc fixed
Update: added check for zero value as it was before (note: can't simply check
mountd_port for positive value because it's typeof unsigned short)
Default value for mount server port is set to NFS_UNSPEC_PORT (-1) and will not
be changed during parsing mount options for mound data version 6. This default
value will be showed for mountport in /proc/mounts always since current default
check is for zero value. This small mistake leads to big problem, because
during umount.nfs execution from old user-space utils (at least nfs-utils
1.0.9) this value will be used as the server port to connect to. This request
will be rejected (since port is 65535) and thus nfs mount point can't be
unmounted.
Note from Chuck Lever (chuck.lever@oracle.com): this is only possible if
/etc/mtab is a link to /proc/mounts. Not all systems have this configuration.
Signed-off-by: Stanislav Kinsbursky <skinsbursky@parallels.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 611c96c8f728c4bcdbadaa2387942d3c0641cadf
Author: J. Bruce Fields <bfields@redhat.com>
Date: Mon Dec 13 19:05:46 2010 -0500
nfs4: fix units bug causing hang on recovery
Note that cl_lease_time is in jiffies. This can cause a very long wait
in the NFS4ERR_CLID_INUSE case.
Signed-off-by: J. Bruce Fields <bfields@redhat.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 72895b1ac7baeda76835cddb3edb019a90d32bcb
Author: Jesper Juhl <jj@chaosbits.net>
Date: Thu Dec 9 23:17:15 2010 +0100
nfs: Take advantage of kmem_cache_zalloc() in nfs_page_alloc()
Take advantage of kmem_cache_zalloc() in nfs_page_alloc(). Save a call to
memset() and a few bytes.
Before:
[jj@dragon linux-2.6]$ size fs/nfs/pagelist.o
text data bss dec hex filename
1765 0 8 1773 6ed fs/nfs/pagelist.o
After:
[jj@dragon linux-2.6]$ size fs/nfs/pagelist.o
text data bss dec hex filename
1749 0 8 1757 6dd fs/nfs/pagelist.o
Signed-off-by: Jesper Juhl <jj@chaosbits.net>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit c8b031ebc1246d42463c5c69df8f610ca9f48e77
Author: Tobias Klauser <tklauser@distanz.ch>
Date: Thu Dec 9 15:53:28 2010 +0100
NFS: Remove redundant unlikely()
IS_ERR() already implies unlikely(), so it can be omitted here.
Signed-off-by: Tobias Klauser <tklauser@distanz.ch>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 79691836603541e81a3793970826ac4a75429572
Author: Chuck Lever <chuck.lever@oracle.com>
Date: Tue Dec 14 15:06:52 2010 +0000
lockd: Remove src_sap and src_len from nlm_lookup_host_info struct
Clean up.
The contents of the src_sap field is not used in nlm_alloc_host().
Signed-off-by: Chuck Lever <chuck.lever@oracle.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 2025889828bb14b56d9aa4c1a785bd9847ccdc4b
Author: Chuck Lever <chuck.lever@oracle.com>
Date: Tue Dec 14 15:06:41 2010 +0000
lockd: Remove nlm_lookup_host()
Clean up.
Remove the now unused helper nlm_lookup_host().
Signed-off-by: Chuck Lever <chuck.lever@oracle.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit fcc072c783491ca465e4d1e74da7dbb48dbf7a31
Author: Chuck Lever <chuck.lever@oracle.com>
Date: Tue Dec 14 15:06:32 2010 +0000
lockd: Make nrhosts an unsigned long
Clean up.
Signed-off-by: Chuck Lever <chuck.lever@oracle.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit d2df0484bb38f2e0d9754b00597d4a6d1cf666d0
Author: Chuck Lever <chuck.lever@oracle.com>
Date: Tue Dec 14 15:06:22 2010 +0000
lockd: Rename nlm_hosts
Clean up.
nlm_hosts now contains only server-side entries. Rename it to match
convention of client side cache.
Signed-off-by: Chuck Lever <chuck.lever@oracle.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 67216b94d498f5880d8bba2a6b841880739dd524
Author: Chuck Lever <chuck.lever@oracle.com>
Date: Tue Dec 14 15:06:12 2010 +0000
lockd: Clean up nlmsvc_lookup_host()
Clean up.
Change nlmsvc_lookup_host() to be purpose-built for server-side
nlm_host management. This replaces the generic nlm_lookup_host()
helper function, just like on the client side. The lookup logic is
specialized for server host lookups.
The server side cache also gets its own specialized equivalent of the
nlm_release_host() function.
Signed-off-by: Chuck Lever <chuck.lever@oracle.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 8ea6ecc8b0759756a766c05dc7c98c51ec90de37
Author: Chuck Lever <chuck.lever@oracle.com>
Date: Tue Dec 14 15:05:52 2010 +0000
lockd: Create client-side nlm_host cache
NFS clients don't need the garbage collection processing that is
performed on nlm_host structures. The client picks up an nlm_host at
mount time and holds a reference to it until the file system is
unmounted.
Servers, on the other hand, don't have a precise way to tell when an
nlm_host is no longer being used, so zero refcount nlm_host entries
are left to expire in the cache after a time.
Basically there's nothing holding a reference to an nlm_host between
individual server-side NLM requests, but we can't afford the expense
of recreating them for every new NLM request from a client. The
nlm_host cache adds some lifetime hysteresis to entries in the cache
so the next time a particular nlm_host is needed, it's likely to be
discovered by a lookup rather than created from whole cloth.
With the new implementation, client nlm_host cache items are no longer
garbage collected, and are destroyed directly by a new release
function specialized for client entries, nlmclnt_release_host(). They
are cached in their own data structure, and have their own lookup
logic, simplified and specialized for client nlm_host entries.
However, the client nlm_host cache still shares reboot recovery logic
with the server nlm_host cache. The NSM "peer rebooted" downcall for
clients and servers still come through the same RPC call. This is a
legacy formal API that would be difficult to alter, and besides, the
user space NSM implementation can't tell the difference between peers
that are clients or servers.
For this reason, the client cache continues to share the
nlm_host_mutex (and reboot recovery logic) with the server cache.
Signed-off-by: Chuck Lever <chuck.lever@oracle.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 7db836d4a427c3c64406b00b6d8d745d6335d72a
Author: Chuck Lever <chuck.lever@oracle.com>
Date: Tue Dec 14 15:05:42 2010 +0000
lockd: Split nlm_release_call()
The nlm_release_call() function is invoked from both the server and
the client side. We're about to introduce a distinct server- and
client-side nlm_release_host(), so nlm_release_call() must first be
split into a client-side and a server-side version.
Signed-off-by: Chuck Lever <chuck.lever@oracle.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 723bb5b5052faba57060a2feb564ced22416b5bc
Author: Chuck Lever <chuck.lever@oracle.com>
Date: Tue Dec 14 15:05:33 2010 +0000
lockd: Add nlm_destroy_host_locked()
Refactor the tail of nlm_gc_hosts() into nlm_destroy_host() so that
this logic can be used separately from garbage collection.
Rename it _locked() to document that it must be called with the hosts
cache mutex held.
Signed-off-by: Chuck Lever <chuck.lever@oracle.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit a7952f4056d4d9c63c70534bcfd4f2c11e487000
Author: Chuck Lever <chuck.lever@oracle.com>
Date: Tue Dec 14 15:05:23 2010 +0000
lockd: Add nlm_alloc_host()
Refactor nlm_host allocation and initialization into a separate
function. This will be the common piece of server and client nlm_host
lookup logic after the nlm_host cache is split.
Small change: use kmalloc() instead of kzalloc(), as we're overwriting
almost all fields in the new nlm_host struct with non-zero values
immediately after it is allocated. An added benefit is we now have an
explicit reference to each field name where it is initialized (for all
you cscope fans out there).
Signed-off-by: Chuck Lever <chuck.lever@oracle.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit b10e30f6559978e3c8ca2a70c1cb35d6680a4021
Author: J. Bruce Fields <bfields@citi.umich.edu>
Date: Tue Dec 14 15:05:13 2010 +0000
lockd: reorganize nlm_host_rebooted
Minor reorganization; no change in behavior. This will save some
duplicated code after we split the client and server host caches.
Signed-off-by: J. Bruce Fields <bfields@citi.umich.edu>
[ cel: Forward-ported to 2.6.37 ]
Signed-off-by: Chuck Lever <chuck.lever@oracle.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit b113746888c260a02f6ae1e92b0b9ef7e9c38993
Author: J. Bruce Fields <bfields@citi.umich.edu>
Date: Tue Dec 14 15:05:03 2010 +0000
lockd: define host_for_each{_safe} macros
We've got a lot of loops like this, and I find them a little easier to
read with the macros. More such loops are coming.
Signed-off-by: J. Bruce Fields <bfields@citi.umich.edu>
[ cel: Forward-ported to 2.6.37 ]
Signed-off-by: Chuck Lever <chuck.lever@oracle.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit bf2695516db982e90a22fc94f93491b481796bb1
Author: Chuck Lever <chuck.lever@oracle.com>
Date: Tue Dec 14 14:59:29 2010 +0000
SUNRPC: New xdr_streams XDR decoder API
Now that all client-side XDR decoder routines use xdr_streams, there
should be no need to support the legacy calling sequence [rpc_rqst *,
__be32 *, RPC res *] anywhere. We can construct an xdr_stream in the
generic RPC code, instead of in each decoder function.
This is a refactoring change. It should not cause different behavior.
Signed-off-by: Chuck Lever <chuck.lever@oracle.com>
Tested-by: J. Bruce Fields <bfields@redhat.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 9f06c719f474be7003763284a990bed6377bb0d4
Author: Chuck Lever <chuck.lever@oracle.com>
Date: Tue Dec 14 14:59:18 2010 +0000
SUNRPC: New xdr_streams XDR encoder API
Now that all client-side XDR encoder routines use xdr_streams, there
should be no need to support the legacy calling sequence [rpc_rqst *,
__be32 *, RPC arg *] anywhere. We can construct an xdr_stream in the
generic RPC code, instead of in each encoder function.
Also, all the client-side encoder functions return 0 now, making a
return value superfluous. Take this opportunity to convert them to
return void instead.
This is a refactoring change. It should not cause different behavior.
Signed-off-by: Chuck Lever <chuck.lever@oracle.com>
Tested-by: J. Bruce Fields <bfields@redhat.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 1ac7c23e4af5e83525137661595000099f1ce94f
Author: Chuck Lever <chuck.lever@oracle.com>
Date: Tue Dec 14 14:59:09 2010 +0000
SUNRPC: Determine value of "nrprocs" automatically
Clean up.
Just fixed a panic where the nrprocs field in a different upper layer
client was set by hand incorrectly. Use the compiler-generated method
used by the other upper layer protocols.
Signed-off-by: Chuck Lever <chuck.lever@oracle.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 4129ccf303593a1922a934697f99e682ff491504
Author: Chuck Lever <chuck.lever@oracle.com>
Date: Tue Dec 14 14:58:59 2010 +0000
SUNRPC: Avoid return code checking in rpcbind XDR encoder functions
Clean up.
The trend in the other XDR encoder functions is to BUG() when encoding
problems occur, since a problem here is always due to a local coding
error. Then, instead of a status, zero is unconditionally returned.
Update the rpcbind XDR encoders to behave this way.
To finish the update, use the new-style be32_to_cpup() and
cpu_to_be32() macros, and compute the buffer sizes using raw integers
instead of sizeof(). This matches the conventions used in other XDR
functions.
Signed-off-by: Chuck Lever <chuck.lever@oracle.com>
Tested-by: J. Bruce Fields <bfields@redhat.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit b43cd8c153f6902100ed50c1f7e11a470c73a73f
Author: Chuck Lever <chuck.lever@oracle.com>
Date: Tue Dec 14 14:58:49 2010 +0000
NFS: Remove unused UMNT response data structure
Clean up.
The UMNT request has a NULL response. There's no need to set up a
mountres structure for it.
Signed-off-by: Chuck Lever <chuck.lever@oracle.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 98eb2b4f9323bcf2a46476576d3155758cb0a473
Author: Chuck Lever <chuck.lever@oracle.com>
Date: Tue Dec 14 14:58:40 2010 +0000
NFS: Avoid return code checking in mount XDR encoder functions
Clean up.
The trend in the other XDR encoder functions is to BUG() when encoding
problems occur, since a problem here is always due to a local coding
error. Then, instead of a status, zero is unconditionally returned.
Update the mount client XDR encoders to behave this way.
To finish the update, use the new-style be32_to_cpup() and
cpu_to_be32() macros, and compute the buffer sizes using raw integers
instead of sizeof(). This matches the conventions used in other XDR
functions.
Signed-off-by: Chuck Lever <chuck.lever@oracle.com>
Tested-by: J. Bruce Fields <bfields@redhat.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 49b170047f4a9fe1483132e14a11bdf493bdb8af
Author: Chuck Lever <chuck.lever@oracle.com>
Date: Tue Dec 14 14:58:30 2010 +0000
NSM: Avoid return code checking in NSM XDR encoder functions
Clean up.
The trend in the other XDR encoder functions is to BUG() when encoding
problems occur, since a problem here is always due to a local coding
error. Then, instead of a status, zero is unconditionally returned.
Update the NSM XDR encoders to behave this way.
To finish the update, use the new-style be32_to_cpup() and
cpu_to_be32() macros, and compute the buffer sizes using raw integers
instead of sizeof(). This matches the conventions used in other XDR
functions
Signed-off-by: Chuck Lever <chuck.lever@oracle.com>
Tested-by: J. Bruce Fields <bfields@redhat.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit ead00597882c4ee3c534d6880cc3bcb4d412cc4b
Author: Chuck Lever <chuck.lever@oracle.com>
Date: Tue Dec 14 14:58:21 2010 +0000
NFS: Squelch compiler warning in decode_getdeviceinfo()
Clean up.
.../linux/nfs-2.6/fs/nfs/nfs4xdr.c: In function ‘decode_getdeviceinfo’:
.../linux/nfs-2.6/fs/nfs/nfs4xdr.c:5008: warning: comparison between signed and unsigned integer expressions
Signed-off-by: Chuck Lever <chuck.lever@oracle.com>
Tested-by: J. Bruce Fields <bfields@redhat.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 573c4e1ef53a6b891b73cc2257e1604da754a2e4
Author: Chuck Lever <chuck.lever@oracle.com>
Date: Tue Dec 14 14:58:11 2010 +0000
NFS: Simplify ->decode_dirent() calling sequence
Clean up.
The pointer returned by ->decode_dirent() is no longer used as a
pointer. The only call site (xdr_decode() in fs/nfs/dir.c) simply
extracts the errno value encoded in the pointer. Replace the
returned pointer with a standard integer errno return value.
Also, pass the "server" argument as part of the nfs_entry instead of
as a separate parameter. It's faster to derive "server" in
nfs_readdir_xdr_to_array() since we already have the directory's inode
handy. "server" ought to be invariant for a set of entries in the
same directory, right?
The legacy versions of decode_dirent() don't use "server" anyway, so
it's wasted work for them to derive and pass "server" for each entry.
Signed-off-by: Chuck Lever <chuck.lever@oracle.com>
Tested-by: J. Bruce Fields <bfields@redhat.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 8111f373600cd43b3198b48b9238e3ad2fd9908d
Author: Chuck Lever <chuck.lever@oracle.com>
Date: Tue Dec 14 14:58:01 2010 +0000
NFS: Fix hdrlen calculation in NFSv4's decode_read()
When computing the length of the header, be sure to include the
four octets consumed by "count".
Signed-off-by: Chuck Lever <chuck.lever@oracle.com>
Tested-by: J. Bruce Fields <bfields@redhat.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit d8367c504e39528a057a5d7a267b6724f7fdb4b8
Author: Chuck Lever <chuck.lever@oracle.com>
Date: Tue Dec 14 14:57:52 2010 +0000
lockd: Move nlmdbg_cookie2a() to svclock.c
Clean up. nlmdbg_cookie2a() is used only in svclock.c.
Signed-off-by: Chuck Lever <chuck.lever@oracle.com>
Tested-by: J. Bruce Fields <bfields@redhat.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 7d93bd71cb3e2629cc88bc59f393bd4df4162b94
Author: Chuck Lever <chuck.lever@oracle.com>
Date: Tue Dec 14 14:57:42 2010 +0000
NFS: Repair whitespace damage in NFS PROC macro
Clean up.
When I was making other changes in this area, checkscript.pl
complained about the use of leading blanks in the PROC macros in the
xdr files.
Signed-off-by: Chuck Lever <chuck.lever@oracle.com>
Tested-by: J. Bruce Fields <bfields@redhat.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 85a56480191ca9f08fc775c129b9eb5c8c1f2c05
Author: Chuck Lever <chuck.lever@oracle.com>
Date: Tue Dec 14 14:57:32 2010 +0000
NFSD: Update XDR decoders in NFSv4 callback client
Clean up.
Remove old-style NFSv4 XDR macros in favor of the style now used in
fs/nfs/nfs4xdr.c. These were forgotten during the recent nfs4xdr.c
rewrite.
Additional whitespace cleanup adds to the size of this patch.
Signed-off-by: Chuck Lever <chuck.lever@oracle.com>
Tested-by: J. Bruce Fields <bfields@redhat.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit a033db487eec09afde00a3562842982a8053c887
Author: Chuck Lever <chuck.lever@oracle.com>
Date: Tue Dec 14 14:57:22 2010 +0000
NFSD: Update XDR encoders in NFSv4 callback client
Clean up.
Remove old-style NFSv4 XDR macros in favor of the style now used in
fs/nfs/nfs4xdr.c. These were forgotten during the recent nfs4xdr.c
rewrite.
Signed-off-by: Chuck Lever <chuck.lever@oracle.com>
Tested-by: J. Bruce Fields <bfields@redhat.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 3460f29a27344db8c7af62cafdb961286ef0b6cd
Author: Chuck Lever <chuck.lever@oracle.com>
Date: Tue Dec 14 14:57:12 2010 +0000
lockd: Introduce new-style XDR functions for NLMv4
We'd like to prevent local buffer overflows caused by malicious or
broken servers. New xdr_stream style decoders can do that.
For efficiency, we also want to be able to pass xdr_streams from
call_encode() to all XDR encoding functions, rather than building
an xdr_stream in every XDR encoding function in the kernel.
Same idea as the NLM v3 XDR overhaul.
Signed-off-by: Chuck Lever <chuck.lever@oracle.com>
Tested-by: J. Bruce Fields <bfields@redhat.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit f6048709391336cf27fb5c1cfca8e792103e5a73
Author: Chuck Lever <chuck.lever@oracle.com>
Date: Tue Dec 14 14:57:02 2010 +0000
NFS: Move and update xdr_decode_foo() functions that we're keeping
Clean up.
Move the timestamp decoder to match the placement and naming
conventions of the other helpers. Fold xdr_decode_fattr() into
decode_fattr3(), which is now it's only user. Fold
xdr_decode_wcc_attr() into decode_wcc_attr(), which is now it's only
user.
Signed-off-by: Chuck Lever <chuck.lever@oracle.com>
Tested-by: J. Bruce Fields <bfields@redhat.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit b2cdd9c9c95e0e389a8b75fe25f266fc5267bbb6
Author: Chuck Lever <chuck.lever@oracle.com>
Date: Tue Dec 14 14:56:52 2010 +0000
NFS: Remove unused old NFSv3 decoder functions
Clean up. Remove unused legacy result decoder functions, and any
now unused decoder helper functions.
Signed-off-by: Chuck Lever <chuck.lever@oracle.com>
Tested-by: J. Bruce Fields <bfields@redhat.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit f5fc3c50c99a7df2bf908dfe66f112d35178ee07
Author: Chuck Lever <chuck.lever@oracle.com>
Date: Tue Dec 14 14:56:42 2010 +0000
NFS: Switch in new NFSv3 decoder functions
The naming scheme of the new decoder functions, which follows the
NFSv4 XDR decoder functions, is slightly different than the scheme
used for the old functions. Rename the functions as a separate
step to keep the patches clean.
Signed-off-by: Chuck Lever <chuck.lever@oracle.com>
Tested-by: J. Bruce Fields <bfields@redhat.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit e4f9323409369a3aeb01885c0c4409d2eeec794a
Author: Chuck Lever <chuck.lever@oracle.com>
Date: Tue Dec 14 14:56:30 2010 +0000
NFS: Introduce new-style XDR decoding functions for NFSv2
We'd like to prevent local buffer overflows caused by malicious or
broken servers. New xdr_stream style decoders can do that.
For efficiency, we also eventually want to be able to pass xdr_streams
from call_decode() to all XDR decoding functions, rather than building
an xdr_stream in every XDR decoding function in the kernel.
Static helper functions are left without the "inline" directive. This
allows the compiler to choose automatically how to optimize these for
size or speed.
Signed-off-by: Chuck Lever <chuck.lever@oracle.com>
Tested-by: J. Bruce Fields <bfields@redhat.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 9d5a64343925a152e1907c652a0d71d6640868b3
Author: Chuck Lever <chuck.lever@oracle.com>
Date: Tue Dec 14 14:56:20 2010 +0000
NFS: Update xdr_encode_foo() functions that we're keeping
Clean up. Move the timestamp and the sattr encoder to match the
placement convention of the other helpers, update their coding style,
and refresh their documenting comments.
Signed-off-by: Chuck Lever <chuck.lever@oracle.com>
Tested-by: J. Bruce Fields <bfields@redhat.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 499ff710b2fd3a03c8195c82340e5166eed04205
Author: Chuck Lever <chuck.lever@oracle.com>
Date: Tue Dec 14 14:56:10 2010 +0000
NFS: Remove unused old NFSv3 encoder functions
Clean up. Remove unused legacy argument encoder functions, and any
now unused encoder helper functions.
Signed-off-by: Chuck Lever <chuck.lever@oracle.com>
Tested-by: J. Bruce Fields <bfields@redhat.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit ad96b5b5eae59696b97e207d730b8c8cfb9d4e42
Author: Chuck Lever <chuck.lever@oracle.com>
Date: Tue Dec 14 14:56:01 2010 +0000
NFS: Replace old NFSv3 encoder functions with xdr_stream-based ones
The naming scheme of the new encoder functions, which follows the
NFSv4 XDR encoder functions, is slightly different than the scheme
used for the old functions. Rename the functions as a separate
step to keep the patches clean.
Signed-off-by: Chuck Lever <chuck.lever@oracle.com>
Tested-by: J. Bruce Fields <bfields@redhat.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit d9c407b138926132e1f93c01fb2dee50eb0bb615
Author: Chuck Lever <chuck.lever@oracle.com>
Date: Tue Dec 14 14:55:50 2010 +0000
NFS: Introduce new-style XDR encoding functions for NFSv3
We're interested in taking advantage of the safety benefits of
xdr_streams. These data structures allow more careful checking for
buffer overflow while encoding. More careful type checking is also
introduced in the new functions.
For efficiency, we also eventually want to be able to pass xdr_streams
from call_encode() to all XDR encoding functions, rather than building
an xdr_stream in every XDR encoding function in the kernel. To do
this means all encoders must be ready to handle a passed-in
xdr_stream.
The new encoders follow the modern paradigm for XDR encoders: BUG on
error, and always return a zero status code.
Static helper functions are left without the "inline" directive. This
allows the compiler to choose automatically how to optimize these for
size or speed.
Signed-off-by: Chuck Lever <chuck.lever@oracle.com>
Tested-by: J. Bruce Fields <bfields@redhat.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 2b061f9ef216b6d229b06267f188167fd6ab3d9b
Author: Chuck Lever <chuck.lever@oracle.com>
Date: Tue Dec 14 14:55:40 2010 +0000
lockd: Introduce new-style XDR functions for NLMv3
We'd like to prevent local buffer overflows caused by malicious or
broken servers. New xdr_stream style decoders can do that.
For efficiency, we also eventually want to be able to pass xdr_streams
from call_encode() and call_decode() to all XDR encoding functions,
rather than building an xdr_stream in every XDR encoding and decoding
function in the kernel.
To do all of this, rewrite the XDR encoding and decoding functions in
fs/lockd/xdr.c to use xdr_streams. This makes them more or less
incompatible with server-side XDR helper functions, so break them out
into a separate source file.
Static helper functions are left without the "inline" directive. This
allows the compiler to choose automatically how to optimize these for
size or speed.
SHARE-related functionality doesn't seem to be used, as those
functions are hiding behind a #define that isn't set anywhere that I
can find. And, they've been in there forever (at least as far back as
the kernel's git history goes), yet remain unused. Let's take the
opportunity to bin them. It should be easy enough for someone to
introduce proper XDR functions if at some point SHARE-related NLM
functionality is desired.
Signed-off-by: Chuck Lever <chuck.lever@oracle.com>
Tested-by: J. Bruce Fields <bfields@redhat.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 5f96e5e31b4f4a2f126adfe0586a7555c11b0562
Author: Chuck Lever <chuck.lever@oracle.com>
Date: Tue Dec 14 14:55:30 2010 +0000
NFS: Move and update xdr_decode_foo() functions that we're keeping
Clean up.
Move the timestamp decoder to match the placement and naming
conventions of the other helpers. Fold xdr_decode_fattr() into
decode_fattr(), which is now it's only user.
Signed-off-by: Chuck Lever <chuck.lever@oracle.com>
Tested-by: J. Bruce Fields <bfields@redhat.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 661ad4239a51a2169a366a227c68cf3b654ab936
Author: Chuck Lever <chuck.lever@oracle.com>
Date: Tue Dec 14 14:55:20 2010 +0000
NFS: Replace old NFSv2 decoder functions with xdr_stream-based ones
Clean up. Remove unused legacy result decoder functions, and any
now unused decoder helper functions.
Signed-off-by: Chuck Lever <chuck.lever@oracle.com>
Tested-by: J. Bruce Fields <bfields@redhat.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit f796f8b3ae292abb9cb2931e8db6fc1d69bba09d
Author: Chuck Lever <chuck.lever@oracle.com>
Date: Tue Dec 14 14:55:10 2010 +0000
NFS: Introduce new-style XDR decoding functions for NFSv2
We'd like to prevent local buffer overflows caused by malicious or
broken servers. New xdr_stream style decoders can do that.
For efficiency, we also eventually want to be able to pass xdr_streams
from call_decode() to all XDR decoding functions, rather than building
an xdr_stream in every XDR decoding function in the kernel.
nfs_decode_dirent() is renamed to follow the naming convention of the
other two dirent decoders.
Static helper functions are left without the "inline" directive. This
allows the compiler to choose automatically how to optimize these for
size or speed.
Signed-off-by: Chuck Lever <chuck.lever@oracle.com>
Tested-by: J. Bruce Fields <bfields@redhat.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 858284932462cec260f3d1d7426aeb03f5dbc2ad
Author: Chuck Lever <chuck.lever@oracle.com>
Date: Tue Dec 14 14:55:00 2010 +0000
NFS: Use the "nfs_stat" enum for nfs_stat_to_errno()'s argument
Clean up.
To distinguish more clearly between the on-the-wire NFSERR_ value and
our local errno values, use the proper type for the argument of
nfs_stat_to_errno().
Add a documenting comment appropriate for a global function shared
outside this source file.
Signed-off-by: Chuck Lever <chuck.lever@oracle.com>
Tested-by: J. Bruce Fields <bfields@redhat.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 282ac2a573dd1be4230710932cd471ed5a3a94b8
Author: Chuck Lever <chuck.lever@oracle.com>
Date: Tue Dec 14 14:54:50 2010 +0000
NFS: Update xdr_encode_foo() functions that we're keeping
Clean up.
The new helper functions are kept in order by section of RFC 1094.
Move the two timestamp encoders we're keeping, update their coding
style, and refresh their documenting comments.
Signed-off-by: Chuck Lever <chuck.lever@oracle.com>
Tested-by: J. Bruce Fields <bfields@redhat.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 2d70f533eab0a0cabd05ee878b6709707bf63c86
Author: Chuck Lever <chuck.lever@oracle.com>
Date: Tue Dec 14 14:54:40 2010 +0000
NFS: Remove old NFSv2 encoder functions
Clean up: Remove unused legacy argument encoder functions, and any
now unused encoder helper functions.
Signed-off-by: Chuck Lever <chuck.lever@oracle.com>
Tested-by: J. Bruce Fields <bfields@redhat.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 25a0866cc63281b480cc0c11ddeaccb2ffc57dc9
Author: Chuck Lever <chuck.lever@oracle.com>
Date: Tue Dec 14 14:54:30 2010 +0000
NFS: Introduce new-style XDR encoding functions for NFSv2
We're interested in taking advantage of the safety benefits of
xdr_streams. These data structures allow more careful checking for
buffer overflow while encoding. More careful type checking is also
introduced in the new functions.
For efficiency, we also eventually want to be able to pass xdr_streams
from call_encode() to all XDR encoding functions, rather than building
an xdr_stream in every XDR encoding function in the kernel. To do
this means all encoders must be ready to handle a passed-in
xdr_stream.
The new encoders follow the modern paradigm for XDR encoders: BUG on
any error, and always return a zero status code.
Static helper functions are left without the "inline" directive. This
allows the compiler to choose automatically how to optimize these for
size or speed.
Signed-off-by: Chuck Lever <chuck.lever@oracle.com>
Tested-by: J. Bruce Fields <bfields@redhat.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
--
Trond Myklebust
Linux NFS client maintainer
NetApp
Trond.Myklebust@netapp.com
www.netapp.com
^ permalink raw reply [flat|nested] 25+ messages in thread
* [GIT PULL] Please pull NFS client changes
@ 2010-08-06 18:26 Trond Myklebust
0 siblings, 0 replies; 25+ messages in thread
From: Trond Myklebust @ 2010-08-06 18:26 UTC (permalink / raw)
To: Linus Torvalds; +Cc: linux-nfs, linux-kernel
Hi Linus,
Please pull from the "nfs-for-2.6.36" branch of the repository at
git pull git://git.linux-nfs.org/projects/trondmy/nfs-2.6.git nfs-for-2.6.36
This will update the following files through the appended changesets.
Cheers,
Trond
----
fs/nfs/Kconfig | 10 +-
fs/nfs/callback_proc.c | 19 +--
fs/nfs/client.c | 143 ++++++-------
fs/nfs/delegation.c | 16 +-
fs/nfs/delegation.h | 4 +-
fs/nfs/dir.c | 9 -
fs/nfs/direct.c | 29 ++-
fs/nfs/file.c | 51 ++---
fs/nfs/getroot.c | 2 +-
fs/nfs/inode.c | 74 ++++++-
fs/nfs/internal.h | 7 +-
fs/nfs/nfs2xdr.c | 7 +-
fs/nfs/nfs3xdr.c | 8 +-
fs/nfs/nfs4_fs.h | 57 ++++-
fs/nfs/nfs4proc.c | 474 +++++++++++++++++++++++-----------------
fs/nfs/nfs4renewd.c | 4 +-
fs/nfs/nfs4state.c | 82 +++++---
fs/nfs/nfs4xdr.c | 111 ++++++++--
fs/nfs/pagelist.c | 8 +-
fs/nfs/read.c | 3 +-
fs/nfs/super.c | 26 ++-
fs/nfs/unlink.c | 2 +-
fs/nfs/write.c | 9 +-
include/linux/nfs4.h | 1 +
include/linux/nfs_fs.h | 13 +-
include/linux/nfs_fs_sb.h | 7 +-
include/linux/nfs_mount.h | 1 +
include/linux/nfs_page.h | 1 +
include/linux/nfs_xdr.h | 12 +-
include/linux/sunrpc/auth.h | 21 +--
include/linux/sunrpc/clnt.h | 5 +-
include/linux/sunrpc/sched.h | 7 +-
include/linux/sunrpc/xprt.h | 1 +
net/sunrpc/auth.c | 157 +++++++++----
net/sunrpc/auth_generic.c | 23 +--
net/sunrpc/auth_gss/auth_gss.c | 29 +--
net/sunrpc/auth_null.c | 2 +-
net/sunrpc/auth_unix.c | 21 +-
net/sunrpc/clnt.c | 182 +++++++++++----
net/sunrpc/sched.c | 104 ++--------
net/sunrpc/sunrpc_syms.c | 15 +-
net/sunrpc/xprt.c | 3 +
net/sunrpc/xprtsock.c | 38 ++--
43 files changed, 1057 insertions(+), 741 deletions(-)
commit 3dce9a5c3a39a664e372886ea86c42ae7ae33dfc
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date: Wed Aug 4 14:39:16 2010 -0400
NFS: NFSv4.1 is no longer a "developer only" feature
Mark it as 'experimental' instead, since in practice, NFSv4.1 should now be
relatively stable.
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit b3edc2bc19b4856c705f4aea3f5472970b99f386
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date: Wed Aug 4 14:38:01 2010 -0400
NFS: NFS_V4 is no longer an EXPERIMENTAL feature
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit d5eff1a3412f6d75bf28f423c5015ece8055407a
Author: Bryan Schumaker <bjschuma@netapp.com>
Date: Tue Aug 3 13:04:00 2010 -0400
NFS: Fix /proc/mount for legacy binary interface
Add a flag so we know if we mounted the NFS server using the legacy
binary interface. If we used the legacy interface, then we should not
show the mountd options.
Signed-off-by: Bryan Schumaker <bjschuma@netapp.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 761fe93cdfa29071879d882c92e966ae692c0048
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date: Wed Aug 4 09:29:52 2010 -0400
NFS: Fix the locking in nfs4_callback_getattr
The delegation is protected by RCU now, so we need to replace the
nfsi->rwsem protection with an rcu protected section.
Reported-by: Fred Isaman <iisaman@netapp.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 0d8a374673c9bc62bc78a2d8fe64553a51542cb4
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date: Sun Aug 1 20:14:55 2010 -0400
SUNRPC: Defer deleting the security context until gss_do_free_ctx()
There is no need to delete the gss context separately from the rest
of the security context information, and doing so gives rise to a
an rcu_dereference_check() warning.
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit c3ae62ae08bb0db3639d8c579e4ff0967d908199
Author: J. Bruce Fields <bfields@redhat.com>
Date: Tue Aug 3 17:22:20 2010 -0400
SUNRPC: prevent task_cleanup running on freed xprt
We saw a report of a NULL dereference in xprt_autoclose:
https://bugzilla.redhat.com/show_bug.cgi?id=611938
This appears to be the result of an xprt's task_cleanup running after
the xprt is destroyed. Nothing in the current code appears to prevent
that.
Signed-off-by: J. Bruce Fields <bfields@redhat.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit d6a1ed08c6acea647b3f2aaebe0261f079e1be49
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date: Sat Jul 31 14:29:08 2010 -0400
SUNRPC: Reduce asynchronous RPC task stack usage
We should just farm out asynchronous RPC tasks immediately to rpciod...
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit a17c2153d2e271b0cbacae9bed83b0eaa41db7e1
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date: Sat Jul 31 14:29:08 2010 -0400
SUNRPC: Move the bound cred to struct rpc_rqst
This will allow us to save the original generic cred in rpc_message, so
that if we migrate from one server to another, we can generate a new bound
cred without having to punt back to the NFS layer.
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 8572b8e2e3c5f3d990122348c4d2c64dad338611
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date: Sat Jul 31 14:29:08 2010 -0400
SUNRPC: Clean up of rpc_bindcred()
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 58f9612c6ea858f532021a0ce42ec53cb0a493b3
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date: Sat Jul 31 14:29:08 2010 -0400
SUNRPC: Move remaining RPC client related task initialisation into clnt.c
Now that rpc_run_task() is the sole entry point for RPC calls, we can move
the remaining rpc_client-related initialisation of struct rpc_task from
sched.c into clnt.c.
Also move rpc_killall_tasks() into the same file, since that too is
relative to the rpc_clnt.
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit d9b6cd94601e1d17273f93a326a135fbf487a918
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date: Sat Jul 31 14:29:08 2010 -0400
SUNRPC: Ensure that rpc_exit() always wakes up a sleeping task
Make rpc_exit() non-inline, and ensure that it always wakes up a task that
has been queued.
Kill off the now unused rpc_wake_up_task().
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 241269bd0b580faae71575443d9ab38df7469126
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date: Sat Jul 31 14:29:08 2010 -0400
SUNRPC: Make the credential cache hashtable size configurable
This patch allows the user to configure the credential cache hashtable size
using a new module parameter: auth_hashtable_size
When set, this parameter will be rounded up to the nearest power of two,
with a maximum allowed value of 1024 elements.
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 988664a0f6bbfc356e6ce55f7a87b8594050012f
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date: Sat Jul 31 14:29:07 2010 -0400
SUNRPC: Store the hashtable size in struct rpc_cred_cache
Cleanup in preparation for allowing the user to determine the maximum hash
table size.
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 5d8d9a4d9ff74c55901642b4e2ac5124830ddafe
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date: Sat Jul 31 14:29:07 2010 -0400
NFS: Ensure the AUTH_UNIX credcache is allocated dynamically
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit d05dd4e98f0dd30ee933e05ac9363614c47df83a
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date: Sat Jul 31 14:29:07 2010 -0400
NFS: Fix the NFS users of rpc_restart_call()
Fix up those functions that depend on knowing whether or not
rpc_restart_call is successful or not.
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit f1f88fc7e818c6678c6799a2edb8f1aeccc124aa
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date: Sat Jul 31 14:29:07 2010 -0400
SUNRPC: The function rpc_restart_call() should return success/failure
Both rpc_restart_call_prepare() and rpc_restart_call() test for the
RPC_TASK_KILLED flag, and fail to restart the RPC call if that flag is set.
This patch allows callers to know whether or not the restart was
successful, so that they can perform cleanups etc in case of failure.
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit a6f03393ec86fd25523c79497a9a773bda170d1d
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date: Sat Jul 31 14:29:07 2010 -0400
NFSv4: Get rid of the bogus RPC_ASSASSINATED(task) checks
There is no real reason to have RPC_ASSASSINATED() checks in the NFS code.
As far as it is concerned, this is just an RPC error...
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 452e93523d9433f83670e7b42cbe75319c208762
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date: Sat Jul 31 14:29:06 2010 -0400
NFSv4: Clean up the process of renewing the NFSv4 lease
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 14516c3a30e256e8d4e7a9af271c8df644ac3222
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date: Sat Jul 31 14:29:06 2010 -0400
NFSv4.1: Handle NFS4ERR_DELAY on SEQUENCE correctly
In RFC5661, an NFS4ERR_DELAY error on a SEQUENCE operation has the special
meaning that the server is not finished processing the request. In this
case we want to just retry the request without touching the slot.
Also fix a bug whereby we would fail to update the sequence id if the
server returned any error other than NFS_OK/NFS4ERR_DELAY.
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 0a8ebba943dd89bdd57c5dab5a66932f690847d9
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date: Sat Jul 31 14:29:06 2010 -0400
NFS: nfs_rename() should not have to flush out writebacks
We don't really support nfs servers that invalidate the file handle after a
rename, so precautions such as flushing out dirty data before renaming the
file are superfluous.
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 1b924e5f878e3cd62a20bd8dbf3b911a40185a99
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date: Sat Jul 31 14:29:06 2010 -0400
NFS: Clean up the callers of nfs_wb_all()
There is no need to flush out writes before calling nfs_wb_all().
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit af7fa16506bf9b6323e862a61e14c20555152bb3
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date: Sat Jul 31 14:29:06 2010 -0400
NFS: Fix up the fsync code
Christoph points out that the VFS will always flush out data before calling
nfs_fsync(), so we can dispense with a full call to nfs_wb_all(), and
replace that with a simpler call to nfs_commit_inode().
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 77041ed9b49a9e10f374bfa6e482d30ee7a3d46e
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date: Thu Jul 1 12:49:11 2010 -0400
NFSv4: Ensure the lockowners are labelled using the fl_owner and/or fl_pid
flock locks want to be labelled using the process pid, while posix locks
want to be labelled using the fl_owner.
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit d3c7b7ccc199ee564177ee914c04771d6bc00295
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date: Thu Jul 1 12:49:01 2010 -0400
NFSv4: Add support for the RELEASE_LOCKOWNER operation
This is needed by NFSv4.0 servers in order to keep the number of locking
stateids at a manageable level.
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit daccbded7f153ec84a3baf3136052e41d0eab555
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date: Fri Jun 25 18:11:43 2010 -0400
NFSv4: Clean up for lockowner XDR encoding
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit f11ac8db5d07b6e99d41ff4aa39d878ee5cef1c5
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date: Fri Jun 25 16:35:53 2010 -0400
NFSv4: Ensure that we track the NFSv4 lock state in read/write requests.
This patch fixes bugzilla entry 14501:
https://bugzilla.kernel.org/show_bug.cgi?id=14501
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 1f0e890dba5b0f543fea47732116b1c65d55614e
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date: Thu Jun 24 15:11:43 2010 -0400
NFSv4: Clean up struct nfs4_state_owner
The 'so_delegations' list appears to be unused.
Also eliminate so_client. If we already have so_server, we can get to the
nfs_client structure.
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 1055d76d91e69c8ea9fb748db4d4a53b6384df31
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date: Wed Jun 16 09:52:27 2010 -0400
NFSv4.1: There is no need to init the session more than once...
Set up a flag to ensure that is indeed the case.
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit fe74ba3a8db003410e48863a5cafa6ac90674540
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date: Wed Jun 16 09:52:27 2010 -0400
NFSv41: Cleanup for nfs4_alloc_session.
There is no reason to change the nfs_client state every time we allocate a
new session. Move that line into nfs4_init_client_minor_version.
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit d77d76ffb638bd013782138cca6d8f4918c5afd6
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date: Wed Jun 16 09:52:27 2010 -0400
NFSv41: Clean up exclusive create
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit a4432345352c2be157ed844603147ac2c82f209c
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date: Wed Jun 16 09:52:27 2010 -0400
NFSv41: Deprecate nfs_client->cl_minorversion
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit e047a10c1293ee0ab20258154e7f3ebf8ad502d6
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date: Wed Jun 16 09:52:27 2010 -0400
NFSv41: Fix nfs_async_inode_return_delegation() ugliness
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit c48f4f3541e67881c9eb7c46e052f5ece48ef530
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date: Wed Jun 16 09:52:27 2010 -0400
NFSv41: Convert the various reboot recovery ops etc to minor version ops
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 97dc135947181a6670949a480da56c3ebf8d3715
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date: Wed Jun 16 09:52:26 2010 -0400
NFSv41: Clean up the NFSv4.1 minor version specific operations
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit a2118c33aad6c447ad5e0a60cfaea3939b52ce0a
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date: Wed Jun 16 09:52:26 2010 -0400
NFSv41: Don't store session state in the nfs_client->cl_state
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit df8964554a4e19c8ddcc4d9c642c4d267662d770
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date: Wed Jun 16 09:52:26 2010 -0400
NFSv41: Further cleanup for nfs4_sequence_done
Instead of testing if the nfs_client has a session, we should be testing if
the struct nfs4_sequence_res was set up with one.
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 035168ab39f66e4946d493f9ee20d11e154f332a
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date: Wed Jun 16 09:52:26 2010 -0400
NFSv4.1: Make nfs4_setup_sequence take a nfs_server argument
In anticipation of the day when we have per-filesystem sessions, and also
in order to allow the session to change in the event of a filesystem
migration event.
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 71ac6da9944e2c9ec73ca64ca7bca74428858585
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date: Wed Jun 16 09:52:26 2010 -0400
NFSv4.1: Merge the nfs41_proc_async_sequence() and nfs4_proc_sequence()
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit aa5190d0ed7d042c6d7d89fe8101558a912eee73
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date: Wed Jun 16 09:52:25 2010 -0400
NFSv4: Kill nfs4_async_handle_error() abuses by NFSv4.1
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit d185a334c748b3ca9de1f3a293fd8a9cf68378ab
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date: Wed Jun 16 09:52:25 2010 -0400
NFSv4.1: Simplify nfs41_sequence_done()
Nobody uses the rpc_status parameter.
It is not obvious why we need the struct nfs_client argument either, when
we already have that information in the session.
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 2a6e26cdb8f17b1075c2dfd8f2f3c341bac4f441
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date: Wed Jun 16 09:52:25 2010 -0400
NFSv4.1: Clean up nfs4_setup_sequence
Firstly, there is little point in first zeroing out the entire struct
nfs4_sequence_res, and then initialising all fields save one. Just
initialise the last field to zero...
Secondly, nfs41_setup_sequence() has only 2 possible return values: 0, or
-EAGAIN, so there is no 'terminate rpc task' case.
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit d5f8d3fe72594f2e896b407f78daf24f37ef4d53
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date: Wed Jun 16 09:52:25 2010 -0400
NFSv41: Fix a memory leak in nfs41_proc_async_sequence()
If the call to rpc_call_async() fails, then the arguments will not be
freed, since there will be no call to nfs41_sequence_call_done
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit d3f6baaa34c54040b3ef30950e59b54ac0624b21
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date: Tue Jun 22 08:52:39 2010 -0400
NFSv4: Fix an embarassing typo in encode_attrs()
Apparently, we have never been able to set the atime correctly from the
NFSv4 client.
Reported-by: 小倉一夫 <ka-ogura@bd6.so-net.ne.jp>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
Cc: stable@kernel.org
commit 0be8189f2c87fcc747d6a4a657a0b6e2161b2318
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date: Fri Jun 18 12:23:58 2010 -0400
NFSv4: Ensure that /proc/self/mountinfo displays the minor version number
Currently, we do not display the minor version mount parameter in the
/proc mount info.
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
Cc: stable@kernel.org
commit 44950b67a6239b377a9e6fd52c498b310bcdd713
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date: Thu Jun 17 11:45:12 2010 -0400
NFSv4.1: Ensure that we initialise the session when following a referral
Put the code that is common to both the referral and ordinary mount cases
into a common helper routine.
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit b76ce56192bcf618013fb9aecd83488cffd645cc
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date: Wed Jun 16 13:57:32 2010 -0400
SUNRPC: Fix a re-entrancy bug in xs_tcp_read_calldir()
If the attempt to read the calldir fails, then instead of storing the read
bytes, we currently discard them. This leads to a garbage final result when
upon re-entry to the same routine, we read the remaining bytes.
Fixes the regression in bugzilla number 16213. Please see
https://bugzilla.kernel.org/show_bug.cgi?id=16213
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
Cc: stable@kernel.org
commit f799bdb355edaabd81b778087613409a8932fbe9
Author: Andy Adamson <andros@netapp.com>
Date: Wed Jun 16 09:51:02 2010 -0400
nfs4 use mandatory attribute file type in nfs4_get_root
S_ISDIR(fsinfo.fattr->mode) checks the file type rather than the mode bits,
so we should be checking for the NFS_ATTR_FATTR_TYPE fattr property.
Signed-off-by: Andy Adamson <andros@netapp.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
Cc: stable@kernel.org
^ permalink raw reply [flat|nested] 25+ messages in thread
* [GIT PULL] Please pull NFS client changes
@ 2010-05-17 22:28 Trond Myklebust
2010-05-18 8:59 ` Lukas Hejtmanek
0 siblings, 1 reply; 25+ messages in thread
From: Trond Myklebust @ 2010-05-17 22:28 UTC (permalink / raw)
To: Linus Torvalds; +Cc: linux-kernel, linux-nfs
Hi Linus,
Please pull from the "nfs-for-2.6.35" branch of the repository at
git pull git://git.linux-nfs.org/projects/trondmy/nfs-2.6.git nfs-for-2.6.35
This will update the following files through the appended changesets.
Cheers,
Trond
----
fs/nfs/client.c | 55 ++-
fs/nfs/delegation.c | 2 +-
fs/nfs/dir.c | 143 ++++---
fs/nfs/file.c | 15 +-
fs/nfs/fscache.c | 3 +-
fs/nfs/getroot.c | 191 ++++------
fs/nfs/inode.c | 58 +++-
fs/nfs/internal.h | 4 +-
fs/nfs/iostat.h | 6 +-
fs/nfs/namespace.c | 20 +-
fs/nfs/nfs3acl.c | 23 +-
fs/nfs/nfs3proc.c | 128 ++++---
fs/nfs/nfs3xdr.c | 2 +-
fs/nfs/nfs4_fs.h | 8 +-
fs/nfs/nfs4namespace.c | 12 +-
fs/nfs/nfs4proc.c | 172 +++++---
fs/nfs/nfs4state.c | 36 +-
fs/nfs/nfs4xdr.c | 22 +-
fs/nfs/nfsroot.c | 14 +-
fs/nfs/pagelist.c | 14 +-
fs/nfs/proc.c | 144 ++++---
fs/nfs/read.c | 4 +-
fs/nfs/super.c | 147 ++++++--
fs/nfs/unlink.c | 4 +-
include/linux/ktime.h | 10 +-
include/linux/nfs_fs.h | 14 +
include/linux/nfs_fs_sb.h | 1 -
include/linux/nfs_xdr.h | 7 +-
include/linux/sunrpc/auth.h | 1 +
include/linux/sunrpc/auth_gss.h | 1 +
include/linux/sunrpc/gss_api.h | 8 +-
include/linux/sunrpc/gss_krb5.h | 184 +++++++++-
include/linux/sunrpc/metrics.h | 7 +-
include/linux/sunrpc/sched.h | 20 +-
include/linux/sunrpc/xdr.h | 8 +-
include/linux/sunrpc/xprt.h | 13 +-
net/sunrpc/auth.c | 19 +-
net/sunrpc/auth_gss/Makefile | 2 +-
net/sunrpc/auth_gss/auth_gss.c | 89 ++++-
net/sunrpc/auth_gss/gss_krb5_crypto.c | 697 ++++++++++++++++++++++++++++++++-
net/sunrpc/auth_gss/gss_krb5_keys.c | 336 ++++++++++++++++
net/sunrpc/auth_gss/gss_krb5_mech.c | 584 +++++++++++++++++++++++++--
net/sunrpc/auth_gss/gss_krb5_seal.c | 155 ++++++--
net/sunrpc/auth_gss/gss_krb5_seqnum.c | 83 ++++-
net/sunrpc/auth_gss/gss_krb5_unseal.c | 113 +++++-
net/sunrpc/auth_gss/gss_krb5_wrap.c | 404 ++++++++++++++++---
net/sunrpc/auth_gss/gss_mech_switch.c | 21 +-
net/sunrpc/auth_gss/gss_spkm3_mech.c | 5 +-
net/sunrpc/auth_gss/svcauth_gss.c | 17 +-
net/sunrpc/clnt.c | 19 +-
net/sunrpc/sched.c | 26 +-
net/sunrpc/stats.c | 29 +-
net/sunrpc/xdr.c | 1 +
net/sunrpc/xprt.c | 59 ++--
net/sunrpc/xprtrdma/transport.c | 31 +-
net/sunrpc/xprtsock.c | 40 +--
56 files changed, 3378 insertions(+), 853 deletions(-)
commit 126e216a8730532dfb685205309275f87e3d133e
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date: Thu May 13 12:55:38 2010 -0400
SUNRPC: Don't spam gssd with upcall requests when the kerberos key expired
Now that the rpc.gssd daemon can explicitly tell us that the key expired,
we should cache that information to avoid spamming gssd.
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 9bb0b8136a7d5b50c5807af3bf12b758fb257814
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date: Thu May 13 12:51:50 2010 -0400
SUNRPC: Reorder the struct rpc_task fields
This improves the packing of the rpc_task, and ensures that on 64-bit
platforms the size reduces to 216 bytes.
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit d72b6cec8d42eb7c2a249b613abf2c2b7a6eeb47
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date: Thu May 13 12:51:50 2010 -0400
SUNRPC: Remove the 'tk_magic' debugging field
It has not triggered in almost a decade. Time to get rid of it...
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit d60dbb20a74c2cfa142be0a34dac3c6547ea086c
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date: Thu May 13 12:51:49 2010 -0400
SUNRPC: Move the task->tk_bytes_sent and tk_rtt to struct rpc_rqst
It seems strange to maintain stats for bytes_sent in one structure, and
bytes received in another. Try to assemble all the RPC request-related
stats in struct rpc_rqst
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 9c7e7e23371e629dbb3b341610a418cdf1c19d91
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date: Thu May 13 12:51:06 2010 -0400
NFS: Don't call iput() in nfs_access_cache_shrinker
iput() can potentially attempt to allocate memory, so we should avoid
calling it in a memory shrinker. Instead, rely on the fact that iput() will
call nfs_access_zap_cache().
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 1a81bb8a1fa62ccb9b2411ac10ce702ca4ed302a
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date: Thu May 13 12:51:06 2010 -0400
NFS: Clean up nfs_access_zap_cache()
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 61d5eb2985b3b1d69fd53d7dc9789037c27f8d91
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date: Thu May 13 12:51:06 2010 -0400
NFS: Don't run nfs_access_cache_shrinker() when the mask is GFP_NOFS
Both iput() and put_rpccred() might allocate memory under certain
circumstances, so make sure that we don't recurse and deadlock...
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 20673406534176ead9b984a84b662928110f77b1
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date: Thu May 13 12:51:06 2010 -0400
SUNRPC: Ensure rpcauth_prune_expired() respects the nr_to_scan parameter
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 93a05e65c090dda9cbd79d0cf57b65c4dbd8da55
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date: Thu May 13 12:51:06 2010 -0400
SUNRPC: Ensure memory shrinker doesn't waste time in rpcauth_prune_expired()
The 'cred_unused' list, that is traversed by rpcauth_cache_shrinker is
ordered by time. If we hit a credential that is under the 60 second garbage
collection moratorium, we should exit because we know at that point that
all successive credentials are subject to the same moratorium...
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit d300a41ef1c39cc5e6b90fd8834ea7ab16b5c48f
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date: Thu May 13 12:51:03 2010 -0400
SUNRPC: Dont run rpcauth_cache_shrinker() when gfp_mask is GFP_NOFS
Under some circumstances, put_rpccred() can end up allocating memory, so
check the gfp_mask to prevent deadlocks.
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 93870d76fee22e887aa6e7e1fc904dbeca976928
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date: Thu May 13 12:51:03 2010 -0400
NFS: Read requests can use GFP_KERNEL.
There is no danger of deadlock should the allocation trigger page
writeback.
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 18eb884282bbaf99700ba5b60ded782807d52408
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date: Thu May 13 12:51:02 2010 -0400
NFS: Clean up nfs_create_request()
There is no point in looping if we're out of memory.
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 1f4c86c0be9064ab4eebd9e67c84606c1cfeec4b
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date: Thu May 13 12:51:02 2010 -0400
NFS: Don't use GFP_KERNEL in rpcsec_gss downcalls
Again, we can deadlock if the memory reclaim triggers a writeback that
requires a rpcsec_gss credential lookup.
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 8535b2be5181fc3019e4150567ef53210fe3b04f
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date: Thu May 13 12:51:01 2010 -0400
NFSv4: Don't use GFP_KERNEL allocations in state recovery
We do not want to have the state recovery thread kick off and wait for a
memory reclaim, since that may deadlock when the writebacks end up
waiting for the state recovery thread to complete.
The safe thing is therefore to use GFP_NOFS in all open, close,
delegation return, lock, etc. operations that may be called by the
state recovery thread.
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 712a4338669d7d57f952244abb608e6ac07e39da
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date: Wed May 12 17:50:23 2010 -0400
SUNRPC: Fix xs_setup_bc_tcp()
It is a BUG for anybody to call this function without setting
args->bc_xprt. Trying to return an error value is just wrong, since the
user cannot fix this: it is a programming error, not a user error.
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit ff8399709e41bf72b4cb145612a0f9a9f7283c83
Author: Chuck Lever <chuck.lever@oracle.com>
Date: Fri May 7 13:34:47 2010 -0400
SUNRPC: Replace jiffies-based metrics with ktime-based metrics
Currently RPC performance metrics that tabulate elapsed time use
jiffies time values. This is problematic on systems that use slow
jiffies (for instance 100HZ systems built for paravirtualized
environments). It is also a problem for computing precise latency
statistics for advanced network transports, such as InfiniBand,
that can have round-trip latencies significanly faster than a single
clock tick.
For the RPC client, adopt the high resolution time stamp mechanism
already used by the network layer and blktrace: ktime.
We use ktime format time stamps for all internal computations, and
convert to milliseconds for presentation. As a result, we need only
addition operations in the performance critical paths; multiply/divide
is required only for presentation.
We could report RTT metrics in microseconds. In fact the mountstats
format is versioned to accomodate exactly this kind of interface
improvement.
For now, however, we'll stay with millisecond precision for
presentation to maintain backwards compatibility with the handful of
currently deployed user space tools. At a later point, we'll move to
an API such as BDI_STATS where a finer timestamp precision can be
reported.
Signed-off-by: Chuck Lever <chuck.lever@oracle.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit f56916b97fe2031761ca611f0a342efd913afb33
Author: Chuck Lever <chuck.lever@oracle.com>
Date: Fri May 7 13:34:37 2010 -0400
ktime: introduce ktime_to_ms()
To report ktime statistics to user space in milliseconds, a new helper
is required.
When considering how to do this conversion, I didn't immediately see
why the extra step of converting ktime to a timeval was needed. To
make that more clear, introduce a couple of large comments.
Signed-off-by: Chuck Lever <chuck.lever@oracle.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit bbc72cea58f671665b6362be0d4e391813ac0eee
Author: Chuck Lever <chuck.lever@oracle.com>
Date: Fri May 7 13:34:27 2010 -0400
SUNRPC: RPC metrics and RTT estimator should use same RTT value
Compute an RPC request's RTT once, and use that value both for reporting
RPC metrics, and for adjusting the RTT context used by the RPC client's RTT
estimator algorithm.
Signed-off-by: Chuck Lever <chuck.lever@oracle.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 9bc4e3ca46e4eb9cb434de4175c6041d00bbdca3
Author: Chuck Lever <chuck.lever@oracle.com>
Date: Fri May 7 13:34:17 2010 -0400
NFS: Calldata for nfs4_renew_done()
I'm about to change task->tk_start from a jiffies value to a ktime_t
value in order to make RPC RTT reporting more precise.
Recently (commit dc96aef9) nfs4_renew_done() started to reference
task->tk_start so that a jiffies value no longer had to be passed
from nfs4_proc_async_renew(). This allowed the calldata to point to
an nfs_client instead.
Changing task->tk_start to a ktime_t value makes it effectively
useless for renew timestamps, so we need to restore the pre-dc96aef9
logic that provided a jiffies "start" timestamp to nfs4_renew_done().
Both an nfs_client pointer and a timestamp need to be passed to
nfs4_renew_done(), so create a new nfs_renewdata structure that
contains both, resembling what is already done for delegreturn,
lock, and unlock.
Signed-off-by: Chuck Lever <chuck.lever@oracle.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit dfe52c0419b8324bacd69bd28aae77e2d6ee0379
Author: Chuck Lever <chuck.lever@oracle.com>
Date: Fri May 7 13:34:08 2010 -0400
NFS: Squelch compiler warning in nfs_add_server_stats()
Clean up:
fs/nfs/iostat.h: In function ‘nfs_add_server_stats’:
fs/nfs/iostat.h:41: warning: comparison between signed and unsigned integer expressions
fs/nfs/iostat.h:41: warning: comparison between signed and unsigned integer expressions
fs/nfs/iostat.h:41: warning: comparison between signed and unsigned integer expressions
fs/nfs/iostat.h:41: warning: comparison between signed and unsigned integer expressions
Commit fce22848 replaced the open-coded per-cpu logic in several
functions in fs/nfs/iostat.h with a single invocation of
this_cpu_ptr(). This macro assumes its second argument is signed,
not unsigned.
Signed-off-by: Chuck Lever <chuck.lever@oracle.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit a6d5ff64bae02438d914f088672cab1916153954
Author: Chuck Lever <chuck.lever@oracle.com>
Date: Fri May 7 13:33:58 2010 -0400
NFS: Clean up fscache_uniq mount option
Clean up: fscache_uniq takes a string, so it should be included
with the other string mount option definitions, by convention.
Signed-off-by: Chuck Lever <chuck.lever@oracle.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 0f15c53d5b1829c10dd901f37b8263aa25ecf864
Author: Chuck Lever <chuck.lever@oracle.com>
Date: Fri May 7 13:33:48 2010 -0400
NFS: Squelch compiler warning
Seen with -Wextra:
/home/cel/linux/fs/nfs/fscache.c: In function ‘__nfs_readpages_from_fscache’:
/home/cel/linux/fs/nfs/fscache.c:479: warning: comparison between signed and unsigned integer expressions
The comparison implicitly converts "int" to "unsigned", making it
safe. But there's no need for the implicit type conversions here, and
the dfprintk() already uses a "%u" formatter for "npages." Better to
reduce confusion.
Signed-off-by: Chuck Lever <chuck.lever@oracle.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 9605a069f83d999e60cd57dc8010708fe08291c0
Author: Chuck Lever <chuck.lever@oracle.com>
Date: Fri May 7 13:33:30 2010 -0400
SUNRPC: Trivial cleanups in include/linux/sunrpc/xdr.h
Clean up: Update the documenting comment, and fix some minor white
space issues.
Signed-off-by: Chuck Lever <chuck.lever@oracle.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit bb8b27e504c0f0463535fea31b42bcaa393c3fb0
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date: Fri Apr 16 16:43:06 2010 -0400
NFSv4: Clean up the NFSv4 setclientid operation
Reviewed-by: Chuck Lever <chuck.lever@oracle.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit d7cf8dd01289b3c64057e38d34c2857f6633d52c
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date: Fri Apr 16 16:42:46 2010 -0400
NFSv4: Allow attribute caching with 'noac' mounts if client holds a delegation
If the server has given us a delegation on a file, we _know_ that we can
cache the attribute information even when the user has specified 'noac'.
Reviewed-by: Chuck Lever <chuck.lever@oracle.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit a8ce4a8f37fef0a09a1e920c2e09f67a80426c7e
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date: Fri Apr 16 16:42:12 2010 -0400
SUNRPC: Fail over more quickly on connect errors
We should not allow soft tasks to wait for longer than the major timeout
period when waiting for a reconnect to occur.
Remove the field xprt->connect_timeout since it has been obsoleted by
xprt->reestablish_timeout.
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 0b9e79431377df452348e78262dd5a3dc359eeef
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date: Fri Apr 16 16:41:57 2010 -0400
SUNRPC: Move the test for XPRT_CONNECTING into xprt_connect()
This fixes a bug with setting xprt->stat.connect_start.
Reviewed-by: Chuck Lever <chuck.lever@oracle.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 19445b99b6d66af661c586c052de23110731a502
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date: Fri Apr 16 16:41:10 2010 -0400
SUNRPC: Cleanup - make rpc_new_task() call rpc_release_calldata on failure
Also have it return an ERR_PTR(-ENOMEM) instead of a null pointer.
Reviewed-by: Chuck Lever <chuck.lever@oracle.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit ee5ebe851ed60206f150d3f189416f9c63245b66
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date: Fri Apr 16 16:37:01 2010 -0400
SUNRPC: Clean up xprt_release()
Reviewed-by: Chuck Lever <chuck.lever@oracle.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit fd86dfd2637db1aef9ebf96ba41aeedb87521e78
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date: Mon Apr 19 19:26:23 2010 -0400
NFSv4: Fix up the documentation for nfs_do_refmount
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 1b4c6065b903390067c1b49bd616db5994c0d51c
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date: Mon Apr 19 19:14:28 2010 -0400
NFS: Replace nfsroot on-stack filehandle
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit b157b06ca24514ef4b766cabb8e852c950040923
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date: Mon Apr 19 19:05:48 2010 -0400
NFS: Cleanup file handle allocations in fs/nfs/super.c
Use the new helper functions instead of open coding.
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit ce587e07ba2e25b5c9d286849885b82676661f3e
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date: Fri Apr 16 16:22:52 2010 -0400
NFS: Prevent the mount code from looping forever on broken exports
Keep a global count of how many referrals that the current task has
traversed on a path lookup. Return ELOOP if the count exceeds
MAX_NESTED_LINKS.
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 6e94d62993cb79397856f3330577917ca79cffa2
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date: Fri Apr 16 16:22:52 2010 -0400
NFS: Reduce stack footprint of nfs3_proc_getacl() and nfs3_proc_setacl()
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit ca7e9a0df263493bbdf76f47fd9e9ac48ad6f331
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date: Fri Apr 16 16:22:52 2010 -0400
NFS: Reduce stack footprint of nfs_statfs()
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 987f8dfc9862f2c7b59594089793dedeebf0cf5e
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date: Fri Apr 16 16:22:52 2010 -0400
NFS: Reduce stack footprint of nfs_setattr()
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 0ab64e0e147e45c07e33d344401cf898a6c181c0
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date: Fri Apr 16 16:22:51 2010 -0400
NFS: Reduce stack footprint of nfs4_proc_create()
Move the O_EXCL open handling into _nfs4_do_open() where it belongs. Doing
so also allows us to reuse the struct fattr from the opendata.
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 23a306120fcb2879ed2b814716c1cb2a8eb74f72
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date: Fri Apr 16 16:22:51 2010 -0400
NFS: Reduce the stack footprint of nfs_proc_symlink()
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit eb872f0c8e5c9801da05d5c2a6e402af8e27160e
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date: Fri Apr 16 16:22:51 2010 -0400
NFS: Reduce the stack footprint of nfs_proc_create
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 39967ddf19ff98b6e0d7b43fe60bcbf2c254c478
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date: Fri Apr 16 16:22:50 2010 -0400
NFS: Reduce the stack footprint of nfs_rmdir
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit d346890bea062d697e24fb4e34591428021ad011
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date: Fri Apr 16 16:22:50 2010 -0400
NFS: Reduce stack footprint of nfs_proc_remove()
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 3b14d6542d7efbec614277d1cd7d6f5b5a2be9ca
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date: Fri Apr 16 16:22:50 2010 -0400
NFS: Reduce stack footprint of nfs3_proc_readlink()
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 136f2627c932da5835e67e464e191d8c43c3f3fd
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date: Fri Apr 16 16:22:49 2010 -0400
NFS: Reduce the stack footprint of nfs_link()
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit aa49b4cf7dbf45438563f0ff6a2d23a68b70a7b9
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date: Fri Apr 16 16:22:49 2010 -0400
NFS: Reduce stack footprint of nfs_readdir()
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 011fff7239eb90e33e7bebba48bf596fced06eb9
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date: Fri Apr 16 16:22:49 2010 -0400
NFS: Reduce stack footprint of nfs3_proc_rename() and nfs4_proc_rename()
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit a3cba2aad9c0a63279716d377efbf37c176ed400
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date: Fri Apr 16 16:22:49 2010 -0400
NFS: Reduce stack footprint of nfs_revalidate_inode()
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit c407d41a1612aa487f5a9cb5338ed7dc60fe1da2
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date: Fri Apr 16 16:22:48 2010 -0400
NFSv4: Reduce stack footprint of nfs4_proc_access() and nfs3_proc_access()
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 4f727296d2428b60138793a0a1207a4085eacf99
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date: Fri Apr 16 16:22:48 2010 -0400
NFSv4: Reduce the stack footprint of nfs4_remote_referral_get_sb
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 8bac9db9cf85f2518cb523bb1d69c481975c1f9a
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date: Fri Apr 16 16:22:48 2010 -0400
NFSv4: Reduce stack footprint of nfs4_get_root()
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 04ffdbe2e69beb0f1745f921871fbe0f97dc4697
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date: Fri Apr 16 16:22:48 2010 -0400
NFS: Reduce the stack footprint of nfs_follow_remote_path()
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit e1fb4d05d5a3265f1f6769bee034175f91ecc2dd
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date: Fri Apr 16 16:22:47 2010 -0400
NFS: Reduce the stack footprint of nfs_lookup
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 364d015e5208e4669a4ae9fab2ab104ff26bc159
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date: Fri Apr 16 16:22:46 2010 -0400
NFSv4: Reduce the stack footprint of try_location()
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit fbca779a8d240d82ef1439247033fd491f81547c
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date: Fri Apr 16 16:22:46 2010 -0400
NFS: Reduce the stack footprint of nfs_create_server
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit a4d7f16806e98cee752006d3a8c10067a7c2aa6b
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date: Fri Apr 16 16:22:46 2010 -0400
NFS: Reduce the stack footprint of nfs_follow_mountpoint()
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 815409d22df870ea0b0d86f2a3bf33c35bcef55c
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date: Fri Apr 16 16:22:46 2010 -0400
NFSv4: Eliminate nfs4_path_walk()
All we really want is the ability to retrieve the root file handle. We no
longer need the ability to walk down the path, since that is now done in
nfs_follow_remote_path().
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 2d36bfde8565b315e624302d12da5a7c9d195522
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date: Fri Apr 16 16:22:45 2010 -0400
NFS: Add helper functions for allocating filehandles and fattr structs
NFS Filehandles and struct fattr are really too large to be allocated on
the stack. This patch adds in a couple of helper functions to allocate them
dynamically instead.
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit fc54a0c65fc8cae6b0355512f0b619c1515e7d7f
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date: Thu Apr 8 14:25:20 2010 -0400
gss_krb5: Advertise rc4-hmac enctype support in the rpcsec_gss/krb5 upcall
Update the upcall info indicating which Kerberos enctypes
the kernel supports
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit fffdaef2eb4a7333952e55cf97f1fc0fcc35f981
Author: Kevin Coffman <kwc@citi.umich.edu>
Date: Wed Mar 17 13:03:06 2010 -0400
gss_krb5: Add support for rc4-hmac encryption
Add necessary changes to add kernel support for the rc4-hmac Kerberos
encryption type used by Microsoft and described in rfc4757.
Signed-off-by: Kevin Coffman <kwc@citi.umich.edu>
Signed-off-by: Steve Dickson <steved@redhat.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 5af46547ec451918f3ba51efe59b317d33adf701
Author: Kevin Coffman <kwc@citi.umich.edu>
Date: Wed Mar 17 13:03:05 2010 -0400
gss_krb5: Use confounder length in wrap code
All encryption types use a confounder at the beginning of the
wrap token. In all encryption types except arcfour-hmac, the
confounder is the same as the blocksize. arcfour-hmac has a
blocksize of one, but uses an eight byte confounder.
Add an entry to the crypto framework definitions for the
confounder length and change the wrap/unwrap code to use
the confounder length rather than assuming it is always
the blocksize.
Signed-off-by: Kevin Coffman <kwc@citi.umich.edu>
Signed-off-by: Steve Dickson <steved@redhat.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 1dbd9029f3024d058da1cf6c6658c28aac2e4e1c
Author: Kevin Coffman <kwc@citi.umich.edu>
Date: Wed Mar 17 13:03:04 2010 -0400
gssd_krb5: More arcfour-hmac support
For the arcfour-hmac support, the make_seq_num and get_seq_num
functions need access to the kerberos context structure.
This will be used in a later patch.
Signed-off-by: Kevin Coffman <kwc@citi.umich.edu>
Signed-off-by: Steve Dickson <steved@redhat.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit fc263a917afad3bda7b823a6edc803a40e7f6015
Author: Kevin Coffman <kwc@citi.umich.edu>
Date: Wed Mar 17 13:03:03 2010 -0400
gss_krb5: Save the raw session key in the context
This is needed for deriving arcfour-hmac keys "on the fly"
using the sequence number or checksu
Signed-off-by: Kevin Coffman <kwc@citi.umich.edu>
Signed-off-by: Steve Dickson <steved@redhat.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 8b23707612cffdba694dcd18aa8a018918aa86dc
Author: Kevin Coffman <kwc@citi.umich.edu>
Date: Wed Mar 17 13:03:02 2010 -0400
gssd_krb5: arcfour-hmac support
For arcfour-hmac support, the make_checksum function needs a usage
field to correctly calculate the checksum differently for MIC and
WRAP tokens.
Signed-off-by: Kevin Coffman <kwc@citi.umich.edu>
Signed-off-by: Steve Dickson <steved@redhat.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit bf6d359c508cf83401c942262a9749752598394d
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date: Thu Apr 8 14:23:06 2010 -0400
gss_krb5: Advertise AES enctype support in the rpcsec_gss/krb5 upcall
Update upcall info indicating which Kerberos enctypes
the kernel supports
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 934a95aa1c9c6ad77838800b79c306e982437605
Author: Kevin Coffman <kwc@citi.umich.edu>
Date: Wed Mar 17 13:03:00 2010 -0400
gss_krb5: add remaining pieces to enable AES encryption support
Add the remaining pieces to enable support for Kerberos AES
encryption types.
Signed-off-by: Kevin Coffman <kwc@citi.umich.edu>
Signed-off-by: Steve Dickson <steved@redhat.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit de9c17eb4a912c9028f7b470eb80815144883b26
Author: Kevin Coffman <kwc@citi.umich.edu>
Date: Wed Mar 17 13:02:59 2010 -0400
gss_krb5: add support for new token formats in rfc4121
This is a step toward support for AES encryption types which are
required to use the new token formats defined in rfc4121.
Signed-off-by: Kevin Coffman <kwc@citi.umich.edu>
[SteveD: Fixed a typo in gss_verify_mic_v2()]
Signed-off-by: Steve Dickson <steved@redhat.com>
[Trond: Got rid of the TEST_ROTATE/TEST_EXTRA_COUNT crap]
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit c43abaedaff92a7bcbfe04b593164bb5faba3078
Author: Kevin Coffman <kwc@citi.umich.edu>
Date: Wed Mar 17 13:02:58 2010 -0400
xdr: Add an export for the helper function write_bytes_to_xdr_buf()
Signed-off-by: Kevin Coffman <kwc@citi.umich.edu>
Signed-off-by: Steve Dickson <steved@redhat.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 4018bf3eec5ff6bf1234a602a4e72518757a7f55
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date: Thu Apr 8 14:21:12 2010 -0400
gss_krb5: Advertise triple-des enctype support in the rpcsec_gss/krb5 upcall
Update the upcall info indicating which Kerberos enctypes the kernel
supports.
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 958142e97e04d6c266ae093739bbbbd03afcd497
Author: Kevin Coffman <kwc@citi.umich.edu>
Date: Wed Mar 17 13:02:55 2010 -0400
gss_krb5: add support for triple-des encryption
Add the final pieces to support the triple-des encryption type.
Signed-off-by: Kevin Coffman <kwc@citi.umich.edu>
Signed-off-by: Steve Dickson <steved@redhat.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 683ac6656cb05b6e83593770ffc049eee4a4d119
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date: Thu Apr 8 14:09:58 2010 -0400
gss_krb5: Add upcall info indicating supported kerberos enctypes
The text based upcall now indicates which Kerberos encryption types are
supported by the kernel rpcsecgss code. This is used by gssd to
determine which encryption types it should attempt to negotiate
when creating a context with a server.
The server principal's database and keytab encryption types are
what limits what it should negotiate. Therefore, its keytab
should be created with only the enctypes listed by this file.
Currently we support des-cbc-crc, des-cbc-md4 and des-cbc-md5
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 47d84807762966c3611c38adecec6ea703ddda7a
Author: Kevin Coffman <kwc@citi.umich.edu>
Date: Wed Mar 17 13:02:54 2010 -0400
gss_krb5: handle new context format from gssd
For encryption types other than DES, gssd sends down context information
in a new format. This new format includes the information needed to
support the new Kerberos GSS-API tokens defined in rfc4121.
Signed-off-by: Kevin Coffman <kwc@citi.umich.edu>
Signed-off-by: Steve Dickson <steved@redhat.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 4891f2d008e4343eedea39ba1fe74864f1d32be0
Author: Kevin Coffman <kwc@citi.umich.edu>
Date: Wed Mar 17 13:02:53 2010 -0400
gss_krb5: import functionality to derive keys into the kernel
Import the code to derive Kerberos keys from a base key into the
kernel. This will allow us to change the format of the context
information sent down from gssd to include only a single key.
Signed-off-by: Kevin Coffman <kwc@citi.umich.edu>
Signed-off-by: Steve Dickson <steved@redhat.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit e1f6c07b1160ef28e8754d12e6c03288dd9d5ca8
Author: Kevin Coffman <kwc@citi.umich.edu>
Date: Wed Mar 17 13:02:52 2010 -0400
gss_krb5: add ability to have a keyed checksum (hmac)
Encryption types besides DES may use a keyed checksum (hmac).
Modify the make_checksum() function to allow for a key
and take care of enctype-specific processing such as truncating
the resulting hash.
Signed-off-by: Kevin Coffman <kwc@citi.umich.edu>
Signed-off-by: Steve Dickson <steved@redhat.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 81d4a4333a1dfd6070f046265d928bb4c79aff88
Author: Kevin Coffman <kwc@citi.umich.edu>
Date: Wed Mar 17 13:02:51 2010 -0400
gss_krb5: introduce encryption type framework
Add enctype framework and change functions to use the generic
values from it rather than the values hard-coded for des.
Signed-off-by: Kevin Coffman <kwc@citi.umich.edu>
Signed-off-by: Steve Dickson <steved@redhat.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit a8cc1cb7d7a12b0e2855832d10cfbfaffebfad6c
Author: Kevin Coffman <kwc@citi.umich.edu>
Date: Wed Mar 17 13:02:50 2010 -0400
gss_krb5: prepare for new context format
Prepare for new context format by splitting out the old "v1"
context processing function
Signed-off-by: Kevin Coffman <kwc@citi.umich.edu>
Signed-off-by: Steve Dickson <steved@redhat.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 1ac3719a2214c545c7e19d34e272a148ca9a24f1
Author: Kevin Coffman <kwc@citi.umich.edu>
Date: Wed Mar 17 13:02:49 2010 -0400
gss_krb5: split up functions in preparation of adding new enctypes
Add encryption type to the krb5 context structure and use it to switch
to the correct functions depending on the encryption type.
Signed-off-by: Kevin Coffman <kwc@citi.umich.edu>
Signed-off-by: Steve Dickson <steved@redhat.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 54ec3d462f3c2a3fe48a7bd592160bee31360087
Author: J. Bruce Fields <bfields@citi.umich.edu>
Date: Wed Mar 17 13:02:48 2010 -0400
gss_krb5: Don't expect blocksize to always be 8 when calculating padding
Signed-off-by: Steve Dickson <steved@redhat.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 7561042fb7870be0b4ee57efddce68bda8968abf
Author: Kevin Coffman <kwc@citi.umich.edu>
Date: Wed Mar 17 13:02:47 2010 -0400
gss_krb5: Added and improved code comments
Signed-off-by: Steve Dickson <steved@redhat.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
commit 725f2865d4df31ac0768b13ae763beadc4bb8ce9
Author: Kevin Coffman <kwc@citi.umich.edu>
Date: Wed Mar 17 13:02:46 2010 -0400
gss_krb5: Introduce encryption type framework
Make the client and server code consistent regarding the extra buffer
space made available for the auth code when wrapping data.
Add some comments/documentation about the available buffer space
in the xdr_buf head and tail when gss_wrap is called.
Add a compile-time check to make sure we are not exceeding the available
buffer space.
Add a central function to shift head data.
Signed-off-by: Kevin Coffman <kwc@citi.umich.edu>
Signed-off-by: Steve Dickson <steved@redhat.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
^ permalink raw reply [flat|nested] 25+ messages in thread
* Re: [GIT PULL] Please pull NFS client changes
2010-05-17 22:28 Trond Myklebust
@ 2010-05-18 8:59 ` Lukas Hejtmanek
0 siblings, 0 replies; 25+ messages in thread
From: Lukas Hejtmanek @ 2010-05-18 8:59 UTC (permalink / raw)
To: Trond Myklebust; +Cc: Linus Torvalds, linux-kernel, linux-nfs
Hi Trond,
On Mon, May 17, 2010 at 06:28:01PM -0400, Trond Myklebust wrote:
> commit 9c7e7e23371e629dbb3b341610a418cdf1c19d91
> Author: Trond Myklebust <Trond.Myklebust@netapp.com>
> Date: Thu May 13 12:51:06 2010 -0400
>
> NFS: Don't call iput() in nfs_access_cache_shrinker
>
> iput() can potentially attempt to allocate memory, so we should avoid
> calling it in a memory shrinker. Instead, rely on the fact that iput() will
> call nfs_access_zap_cache().
>
> Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
>
> commit 1a81bb8a1fa62ccb9b2411ac10ce702ca4ed302a
> Author: Trond Myklebust <Trond.Myklebust@netapp.com>
> Date: Thu May 13 12:51:06 2010 -0400
>
> NFS: Clean up nfs_access_zap_cache()
>
> Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
>
> commit 61d5eb2985b3b1d69fd53d7dc9789037c27f8d91
> Author: Trond Myklebust <Trond.Myklebust@netapp.com>
> Date: Thu May 13 12:51:06 2010 -0400
>
> NFS: Don't run nfs_access_cache_shrinker() when the mask is GFP_NOFS
>
> Both iput() and put_rpccred() might allocate memory under certain
> circumstances, so make sure that we don't recurse and deadlock...
>
> Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
>
> commit 93a05e65c090dda9cbd79d0cf57b65c4dbd8da55
> Author: Trond Myklebust <Trond.Myklebust@netapp.com>
> Date: Thu May 13 12:51:06 2010 -0400
>
> SUNRPC: Ensure memory shrinker doesn't waste time in rpcauth_prune_expired()
>
> The 'cred_unused' list, that is traversed by rpcauth_cache_shrinker is
> ordered by time. If we hit a credential that is under the 60 second garbage
> collection moratorium, we should exit because we know at that point that
> all successive credentials are subject to the same moratorium...
>
> Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
>
> commit d300a41ef1c39cc5e6b90fd8834ea7ab16b5c48f
> Author: Trond Myklebust <Trond.Myklebust@netapp.com>
> Date: Thu May 13 12:51:03 2010 -0400
>
> SUNRPC: Dont run rpcauth_cache_shrinker() when gfp_mask is GFP_NOFS
>
> Under some circumstances, put_rpccred() can end up allocating memory, so
> check the gfp_mask to prevent deadlocks.
>
> Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
>
> commit 93870d76fee22e887aa6e7e1fc904dbeca976928
> Author: Trond Myklebust <Trond.Myklebust@netapp.com>
> Date: Thu May 13 12:51:03 2010 -0400
>
> NFS: Read requests can use GFP_KERNEL.
>
> There is no danger of deadlock should the allocation trigger page
> writeback.
>
> Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
>
> commit 1f4c86c0be9064ab4eebd9e67c84606c1cfeec4b
> Author: Trond Myklebust <Trond.Myklebust@netapp.com>
> Date: Thu May 13 12:51:02 2010 -0400
>
> NFS: Don't use GFP_KERNEL in rpcsec_gss downcalls
>
> Again, we can deadlock if the memory reclaim triggers a writeback that
> requires a rpcsec_gss credential lookup.
>
> Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
>
> commit 8535b2be5181fc3019e4150567ef53210fe3b04f
> Author: Trond Myklebust <Trond.Myklebust@netapp.com>
> Date: Thu May 13 12:51:01 2010 -0400
>
> NFSv4: Don't use GFP_KERNEL allocations in state recovery
>
> We do not want to have the state recovery thread kick off and wait for a
> memory reclaim, since that may deadlock when the writebacks end up
> waiting for the state recovery thread to complete.
>
> The safe thing is therefore to use GFP_NOFS in all open, close,
> delegation return, lock, etc. operations that may be called by the
> state recovery thread.
>
> Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
do these solve also cases when rpc.gssd itself needs memory and there is no
free memory because there is a lot of dirty pages as NFS cache?
rpc.gssd needs memory whenever it needs to create a new kerberos context (in
particular, fread needs it).
--
Lukáš Hejtmánek
^ permalink raw reply [flat|nested] 25+ messages in thread
end of thread, other threads:[~2022-04-08 17:46 UTC | newest]
Thread overview: 25+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2018-12-06 21:55 [GIT PULL] Please pull NFS client changes Trond Myklebust
2018-12-07 18:35 ` pr-tracker-bot
-- strict thread matches above, loose matches on Subject: below --
2022-04-08 17:30 Trond Myklebust
2022-04-08 17:46 ` pr-tracker-bot
2018-11-25 3:04 Trond Myklebust
2018-11-25 17:45 ` pr-tracker-bot
2018-01-30 14:39 Trond Myklebust
2017-10-09 17:35 Trond Myklebust
2016-01-14 21:09 Trond Myklebust
2015-09-07 20:59 Trond Myklebust
2015-09-08 1:59 ` Stephen Rothwell
2015-09-08 6:01 ` Christoph Hellwig
2015-09-11 16:27 ` Christoph Hellwig
2015-09-11 17:06 ` Trond Myklebust
2014-12-08 3:09 Trond Myklebust
2014-10-06 13:03 Trond Myklebust
2014-07-19 20:07 Trond Myklebust
2014-01-27 16:49 Trond Myklebust
2011-10-25 12:25 Trond Myklebust
2011-07-27 18:40 [GIT PULL] Please pull nfs " Trond Myklebust
2011-03-17 17:19 [GIT PULL] Please pull NFS " Trond Myklebust
2011-01-11 23:08 Trond Myklebust
2010-08-06 18:26 Trond Myklebust
2010-05-17 22:28 Trond Myklebust
2010-05-18 8:59 ` Lukas Hejtmanek
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).