LKML Archive on lore.kernel.org
help / color / mirror / Atom feed
* [GIT PULL] Please pull NFS client bugfixes
@ 2015-01-29 21:37 Trond Myklebust
  0 siblings, 0 replies; 82+ messages in thread
From: Trond Myklebust @ 2015-01-29 21:37 UTC (permalink / raw)
  To: Linus Torvalds; +Cc: Linux NFS Mailing List, Linux Kernel Mailing List

Hi Linus,

The following changes since commit ec6f34e5b552fb0a52e6aae1a5afbbb1605cc6cc:

  Linux 3.19-rc5 (2015-01-18 18:02:20 +1200)

are available in the git repository at:

  git://git.linux-nfs.org/projects/trondmy/linux-nfs.git tags/nfs-for-3.19-3

for you to fetch changes up to 2ef47eb1aee171ecf1d83311b9f7fae80f330181:

  NFS: Fix use of nfs_attr_use_mounted_on_fileid() (2015-01-21 17:15:41 -0500)

----------------------------------------------------------------
NFS client bugfixes for Linux 3.19

Highlights include:
- Stable fix for a NFSv4.1 Oops on mount
- Stable fix for an O_DIRECT deadlock condition
- Fix an issue with submounted volumes and fake duplicate inode numbers

----------------------------------------------------------------
Anna Schumaker (1):
      NFS: Fix use of nfs_attr_use_mounted_on_fileid()

Peng Tao (1):
      nfs: fix dio deadlock when O_DIRECT flag is flipped

Trond Myklebust (1):
      NFSv4.1: Fix an Oops in nfs41_walk_client_list

 fs/nfs/direct.c     | 6 ++++++
 fs/nfs/inode.c      | 5 +++--
 fs/nfs/internal.h   | 2 --
 fs/nfs/nfs4client.c | 2 +-
 4 files changed, 10 insertions(+), 5 deletions(-)



^ permalink raw reply	[flat|nested] 82+ messages in thread

* Re: [GIT PULL] Please pull NFS client bugfixes
  2021-01-12 14:31 Trond Myklebust
@ 2021-01-12 18:00 ` pr-tracker-bot
  0 siblings, 0 replies; 82+ messages in thread
From: pr-tracker-bot @ 2021-01-12 18:00 UTC (permalink / raw)
  To: Trond Myklebust; +Cc: torvalds, linux-nfs, linux-kernel

The pull request you sent on Tue, 12 Jan 2021 14:31:12 +0000:

> git://git.linux-nfs.org/projects/trondmy/linux-nfs.git tags/nfs-for-5.11-2

has been merged into torvalds/linux.git:
https://git.kernel.org/torvalds/c/e609571b5ffa3528bf85292de1ceaddac342bc1c

Thank you!

-- 
Deet-doot-dot, I am a bot.
https://korg.docs.kernel.org/prtracker.html

^ permalink raw reply	[flat|nested] 82+ messages in thread

* [GIT PULL] Please pull NFS client bugfixes
@ 2021-01-12 14:31 Trond Myklebust
  2021-01-12 18:00 ` pr-tracker-bot
  0 siblings, 1 reply; 82+ messages in thread
From: Trond Myklebust @ 2021-01-12 14:31 UTC (permalink / raw)
  To: torvalds; +Cc: linux-nfs, linux-kernel

Hi Linus,

The following changes since commit e71ba9452f0b5b2e8dc8aa5445198cd9214a6a62:

  Linux 5.11-rc2 (2021-01-03 15:55:30 -0800)

are available in the Git repository at:

  git://git.linux-nfs.org/projects/trondmy/linux-nfs.git tags/nfs-for-5.11-2

for you to fetch changes up to 896567ee7f17a8a736cda8a28cc987228410a2ac:

  NFS: nfs_igrab_and_active must first reference the superblock (2021-01-10 16:29:28 -0500)

----------------------------------------------------------------
NFS client bugfixes for Linux 5.11

Highlights include:

Bugfixes:
- Fix parsing of link-local IPv6 addresses
- Fix confusing logging of mount errors that was introduced by the
  fsopen() patchset.
- Fix a tracing use after free in _nfs4_do_setlk()
- Layout return-on-close fixes when called from nfs4_evict_inode()
- Layout segments were being leaked in pnfs_generic_clear_request_commit()
- Don't leak DS commits in pnfs_generic_retry_commit()
- Fix an Oopsable use-after-free when nfs_delegation_find_inode_server()
  calls iput() on an inode after the super block has gone away.

----------------------------------------------------------------
Dave Wysochanski (1):
      NFS4: Fix use-after-free in trace_event_raw_event_nfs4_set_lock

Scott Mayhew (1):
      NFS: Adjust fs_context error logging

Trond Myklebust (9):
      pNFS: Mark layout for return if return-on-close was not sent
      pNFS: We want return-on-close to complete when evicting the inode
      pNFS: Clean up pnfs_layoutreturn_free_lsegs()
      pNFS: Stricter ordering of layoutget and layoutreturn
      NFS/pNFS: Don't call pnfs_free_bucket_lseg() before removing the request
      NFS/pNFS: Don't leak DS commits in pnfs_generic_retry_commit()
      NFS/pNFS: Fix a leak of the layout 'plh_outstanding' counter
      NFS: nfs_delegation_find_inode_server must first reference the superblock
      NFS: nfs_igrab_and_active must first reference the superblock

j.nixdorf@avm.de (1):
      net: sunrpc: interpret the return value of kstrtou32 correctly

 fs/nfs/delegation.c | 12 ++++++----
 fs/nfs/internal.h   | 38 +++++++++++++++++++++++-------
 fs/nfs/nfs4proc.c   | 28 +++++++++-------------
 fs/nfs/nfs4super.c  |  4 ++--
 fs/nfs/pnfs.c       | 67 ++++++++++++++++++++++++++++-------------------------
 fs/nfs/pnfs.h       |  8 +++----
 fs/nfs/pnfs_nfs.c   | 22 ++++++++----------
 net/sunrpc/addr.c   |  2 +-
 8 files changed, 99 insertions(+), 82 deletions(-)

-- 
Trond Myklebust
Linux NFS client maintainer, Hammerspace
trond.myklebust@hammerspace.com



^ permalink raw reply	[flat|nested] 82+ messages in thread

* Re: [GIT PULL] Please pull NFS client bugfixes
  2020-09-28 17:27 Trond Myklebust
@ 2020-09-28 18:16 ` pr-tracker-bot
  0 siblings, 0 replies; 82+ messages in thread
From: pr-tracker-bot @ 2020-09-28 18:16 UTC (permalink / raw)
  To: Trond Myklebust; +Cc: torvalds, linux-nfs, linux-kernel

The pull request you sent on Mon, 28 Sep 2020 17:27:14 +0000:

> git://git.linux-nfs.org/projects/trondmy/linux-nfs.git tags/nfs-for-5.9-3

has been merged into torvalds/linux.git:
https://git.kernel.org/torvalds/c/fb0155a09b0224a7147cb07a4ce6034c8d29667f

Thank you!

-- 
Deet-doot-dot, I am a bot.
https://korg.docs.kernel.org/prtracker.html

^ permalink raw reply	[flat|nested] 82+ messages in thread

* [GIT PULL] Please pull NFS client bugfixes
@ 2020-09-28 17:27 Trond Myklebust
  2020-09-28 18:16 ` pr-tracker-bot
  0 siblings, 1 reply; 82+ messages in thread
From: Trond Myklebust @ 2020-09-28 17:27 UTC (permalink / raw)
  To: torvalds; +Cc: linux-nfs, linux-kernel

Hi Linus,

The following changes since commit 856deb866d16e29bd65952e0289066f6078af773:

  Linux 5.9-rc5 (2020-09-13 16:06:00 -0700)

are available in the Git repository at:

  git://git.linux-nfs.org/projects/trondmy/linux-nfs.git tags/nfs-for-5.9-3

for you to fetch changes up to b9df46d08a8d098ea2124cb9e3b84458a474b4d4:

  pNFS/flexfiles: Be consistent about mirror index types (2020-09-18 09:25:33 -0400)

Cheers,
  Trond
----------------------------------------------------------------
NFS client bugfixes for Linux 5.9

Highlights include:

Bugfixes:
- NFSv4.2: copy_file_range needs to invalidate caches on success
- NFSv4.2: Fix security label length not being reset
- pNFS/flexfiles: Ensure we initialise the mirror bsizes correctly on read
- pNFS/flexfiles: Fix signed/unsigned type issues with mirror indices

----------------------------------------------------------------
Jeffrey Mitchell (1):
      nfs: Fix security label length not being reset

Olga Kornievskaia (1):
      NFSv4.2: fix client's attribute cache management for copy_file_range

Trond Myklebust (2):
      pNFS/flexfiles: Ensure we initialise the mirror bsizes correctly on read
      pNFS/flexfiles: Be consistent about mirror index types

 fs/nfs/dir.c                           |  3 +++
 fs/nfs/flexfilelayout/flexfilelayout.c | 43 +++++++++++++++++-----------------
 fs/nfs/nfs42proc.c                     | 10 +++++++-
 include/linux/nfs_xdr.h                |  4 ++--
 4 files changed, 36 insertions(+), 24 deletions(-)
-- 
Trond Myklebust
Linux NFS client maintainer, Hammerspace
trond.myklebust@hammerspace.com



^ permalink raw reply	[flat|nested] 82+ messages in thread

* Re: [GIT PULL] Please pull NFS client bugfixes
  2020-05-15 21:00 Trond Myklebust
@ 2020-05-15 21:10 ` pr-tracker-bot
  0 siblings, 0 replies; 82+ messages in thread
From: pr-tracker-bot @ 2020-05-15 21:10 UTC (permalink / raw)
  To: Trond Myklebust; +Cc: torvalds, linux-nfs, linux-kernel

The pull request you sent on Fri, 15 May 2020 21:00:11 +0000:

> git://git.linux-nfs.org/projects/trondmy/linux-nfs.git tags/nfs-for-5.7-5

has been merged into torvalds/linux.git:
https://git.kernel.org/torvalds/c/12bf0b632ed090358cbf03e323e5342212d0b2e4

Thank you!

-- 
Deet-doot-dot, I am a bot.
https://korg.wiki.kernel.org/userdoc/prtracker

^ permalink raw reply	[flat|nested] 82+ messages in thread

* [GIT PULL] Please pull NFS client bugfixes
@ 2020-05-15 21:00 Trond Myklebust
  2020-05-15 21:10 ` pr-tracker-bot
  0 siblings, 1 reply; 82+ messages in thread
From: Trond Myklebust @ 2020-05-15 21:00 UTC (permalink / raw)
  To: torvalds; +Cc: linux-nfs, linux-kernel

Hi Linus,

The following changes since commit 2ef96a5bb12be62ef75b5828c0aab838ebb29cb8:

  Linux 5.7-rc5 (2020-05-10 15:16:58 -0700)

are available in the Git repository at:

  git://git.linux-nfs.org/projects/trondmy/linux-nfs.git tags/nfs-for-5.7-5

for you to fetch changes up to 8eed292bc8cbf737e46fb1c119d4c8f6dcb00650:

  NFSv3: fix rpc receive buffer size for MOUNT call (2020-05-14 18:42:44 -0400)

----------------------------------------------------------------
NFS client bugfixes for Linux 5.7

Highlights include:

Stable fixes:
- nfs: fix NULL deference in nfs4_get_valid_delegation

Bugfixes:
- Fix corruption of the return value in cachefiles_read_or_alloc_pages()
- Fix several fscache cookie issues
- Fix a fscache queuing race that can trigger a BUG_ON
- NFS: Fix 2 use-after-free regressions due to the RPC_TASK_CRED_NOREF flag
- SUNRPC: Fix a use-after-free regression in rpc_free_client_work()
- SUNRPC: Fix a race when tearing down the rpc client debugfs directory
- SUNRPC: Signalled ASYNC tasks need to exit
- NFSv3: fix rpc receive buffer size for MOUNT call

----------------------------------------------------------------
Chuck Lever (1):
      SUNRPC: Signalled ASYNC tasks need to exit

Dave Wysochanski (3):
      NFS: Fix fscache super_cookie index_key from changing after umount
      NFS: Fix fscache super_cookie allocation
      NFSv4: Fix fscache cookie aux_data to ensure change_attr is included

David Howells (1):
      cachefiles: Fix corruption of the return value in cachefiles_read_or_alloc_pages()

J. Bruce Fields (2):
      nfs: fix NULL deference in nfs4_get_valid_delegation
      SUNRPC: 'Directory with parent 'rpc_clnt' already present!'

Lei Xue (1):
      cachefiles: Fix race between read_waiter and read_copier involving op->to_do

NeilBrown (1):
      SUNRPC: fix use-after-free in rpc_free_client_work()

Olga Kornievskaia (1):
      NFSv3: fix rpc receive buffer size for MOUNT call

Trond Myklebust (3):
      Merge tag 'fscache-fixes-20200508-2' of git://git.kernel.org/.../dhowells/linux-fs
      NFS: Don't use RPC_TASK_CRED_NOREF with delegreturn
      NFS/pnfs: Don't use RPC_TASK_CRED_NOREF with pnfs

 fs/cachefiles/rdwr.c | 12 ++++++------
 fs/nfs/fscache.c     | 39 ++++++++++++++++++---------------------
 fs/nfs/mount_clnt.c  |  3 ++-
 fs/nfs/nfs4proc.c    |  2 +-
 fs/nfs/nfs4state.c   |  2 +-
 fs/nfs/pagelist.c    |  5 +++--
 fs/nfs/pnfs_nfs.c    |  3 ++-
 fs/nfs/super.c       |  1 -
 fs/nfs/write.c       |  4 ++--
 net/sunrpc/clnt.c    |  9 +++++++--
 10 files changed, 42 insertions(+), 38 deletions(-)
-- 
Trond Myklebust
Linux NFS client maintainer, Hammerspace
trond.myklebust@hammerspace.com



^ permalink raw reply	[flat|nested] 82+ messages in thread

* Re: [GIT PULL] Please pull NFS client bugfixes
  2020-05-02 13:35 Trond Myklebust
@ 2020-05-02 18:45 ` pr-tracker-bot
  0 siblings, 0 replies; 82+ messages in thread
From: pr-tracker-bot @ 2020-05-02 18:45 UTC (permalink / raw)
  To: Trond Myklebust; +Cc: torvalds, linux-nfs, linux-kernel

The pull request you sent on Sat, 2 May 2020 13:35:02 +0000:

> git://git.linux-nfs.org/projects/trondmy/linux-nfs.git tags/nfs-for-5.7-4

has been merged into torvalds/linux.git:
https://git.kernel.org/torvalds/c/29a47f456d6213a3173722a098a3a18865ea4db3

Thank you!

-- 
Deet-doot-dot, I am a bot.
https://korg.wiki.kernel.org/userdoc/prtracker

^ permalink raw reply	[flat|nested] 82+ messages in thread

* [GIT PULL] Please pull NFS client bugfixes
@ 2020-05-02 13:35 Trond Myklebust
  2020-05-02 18:45 ` pr-tracker-bot
  0 siblings, 1 reply; 82+ messages in thread
From: Trond Myklebust @ 2020-05-02 13:35 UTC (permalink / raw)
  To: torvalds; +Cc: linux-nfs, linux-kernel

Hi Linus,

The following changes since commit ae83d0b416db002fe95601e7f97f64b59514d936:

  Linux 5.7-rc2 (2020-04-19 14:35:30 -0700)

are available in the Git repository at:

  git://git.linux-nfs.org/projects/trondmy/linux-nfs.git tags/nfs-for-5.7-4

for you to fetch changes up to 9c07b75b80eeff714420fb6a4c880b284e529d0f:

  NFS: Fix a race in __nfs_list_for_each_server() (2020-04-30 15:08:26 -0400)

Thanks
  Trond

----------------------------------------------------------------
NFS client bugfixes for Linux 5.7

Highlights include:

Stable fixes
- fix handling of backchannel binding in BIND_CONN_TO_SESSION

Bugfixes
- Fix a credential use-after-free issue in pnfs_roc()
- Fix potential posix_acl refcnt leak in nfs3_set_acl
- defer slow parts of rpc_free_client() to a workqueue
- Fix an Oopsable race in __nfs_list_for_each_server()
- Fix trace point use-after-free race
- Regression: the RDMA client no longer responds to server disconnect requests
- Fix return values of xdr_stream_encode_item_{present, absent}
- _pnfs_return_layout() must always wait for layoutreturn completion

Cleanups
- Remove unreachable error conditions

----------------------------------------------------------------
Andreas Gruenbacher (1):
      nfs: Fix potential posix_acl refcnt leak in nfs3_set_acl

Chuck Lever (3):
      xprtrdma: Restore wake-up-all to rpcrdma_cm_event_handler()
      xprtrdma: Fix trace point use-after-free race
      xprtrdma: Fix use of xdr_stream_encode_item_{present, absent}

NeilBrown (1):
      SUNRPC: defer slow parts of rpc_free_client() to a workqueue.

Olga Kornievskaia (1):
      NFSv4.1: fix handling of backchannel binding in BIND_CONN_TO_SESSION

Trond Myklebust (4):
      NFS/pnfs: Ensure that _pnfs_return_layout() waits for layoutreturn completion
      NFS/pnfs: Fix a credential use-after-free issue in pnfs_roc()
      Merge tag 'nfs-rdma-for-5.7-2' of git://git.linux-nfs.org/projects/anna/linux-nfs
      NFS: Fix a race in __nfs_list_for_each_server()

Xiyu Yang (2):
      SUNRPC: Remove unreachable error condition
      NFSv4: Remove unreachable error condition due to rpc_run_task()

 fs/nfs/nfs3acl.c               | 22 +++++++++++++++-------
 fs/nfs/nfs4proc.c              | 11 +++++++++--
 fs/nfs/pnfs.c                  | 11 +++++------
 fs/nfs/super.c                 |  2 +-
 include/linux/nfs_xdr.h        |  2 ++
 include/linux/sunrpc/clnt.h    | 13 ++++++++++++-
 include/trace/events/rpcrdma.h | 12 ++++--------
 net/sunrpc/clnt.c              | 24 ++++++++++++++++++------
 net/sunrpc/xprtrdma/rpc_rdma.c | 15 +++++++++++----
 net/sunrpc/xprtrdma/verbs.c    |  3 ++-
 10 files changed, 79 insertions(+), 36 deletions(-)

-- 
Trond Myklebust
Linux NFS client maintainer, Hammerspace
trond.myklebust@hammerspace.com



^ permalink raw reply	[flat|nested] 82+ messages in thread

* Re: [GIT PULL] Please pull NFS client bugfixes
  2019-08-27 19:26 Trond Myklebust
@ 2019-08-27 20:55 ` pr-tracker-bot
  0 siblings, 0 replies; 82+ messages in thread
From: pr-tracker-bot @ 2019-08-27 20:55 UTC (permalink / raw)
  To: Trond Myklebust; +Cc: torvalds, linux-nfs, linux-kernel

The pull request you sent on Tue, 27 Aug 2019 19:26:51 +0000:

> git://git.linux-nfs.org/projects/trondmy/linux-nfs.git tags/nfs-for-5.3-3

has been merged into torvalds/linux.git:
https://git.kernel.org/torvalds/c/9e8312f5e160ade069e131d54ab8652cf0e86e1a

Thank you!

-- 
Deet-doot-dot, I am a bot.
https://korg.wiki.kernel.org/userdoc/prtracker

^ permalink raw reply	[flat|nested] 82+ messages in thread

* [GIT PULL] Please pull NFS client bugfixes
@ 2019-08-27 19:26 Trond Myklebust
  2019-08-27 20:55 ` pr-tracker-bot
  0 siblings, 1 reply; 82+ messages in thread
From: Trond Myklebust @ 2019-08-27 19:26 UTC (permalink / raw)
  To: torvalds; +Cc: linux-nfs, linux-kernel

Hi Linus,

The following changes since commit d1abaeb3be7b5fa6d7a1fbbd2e14e3310005c4c1:

  Linux 5.3-rc5 (2019-08-18 14:31:08 -0700)

are available in the Git repository at:

  git://git.linux-nfs.org/projects/trondmy/linux-nfs.git tags/nfs-for-5.3-3

for you to fetch changes up to 99300a85260c2b7febd57082a617d1062532067e:

  NFS: remove set but not used variable 'mapping' (2019-08-27 10:24:56 -0400)

----------------------------------------------------------------
NFS client bugfixes for Linux 5.3

Highlights include:

Stable fixes:
- Fix a page lock leak in nfs_pageio_resend()
- Ensure O_DIRECT reports an error if the bytes read/written is 0
- Don't handle errors if the bind/connect succeeded
- Revert "NFSv4/flexfiles: Abort I/O early if the layout segment was invalidat
ed"

Bugfixes:
- Don't refresh attributes with mounted-on-file information
- Fix return values for nfs4_file_open() and nfs_finish_open()
- Fix pnfs layoutstats reporting of I/O errors
- Don't use soft RPC calls for pNFS/flexfiles I/O, and don't abort for
  soft I/O errors when the user specifies a hard mount.
- Various fixes to the error handling in sunrpc
- Don't report writepage()/writepages() errors twice.

----------------------------------------------------------------
Trond Myklebust (17):
      NFS: Don't refresh attributes with mounted-on-file information
      NFSv4: Fix return values for nfs4_file_open()
      NFSv4: Fix return value in nfs_finish_open()
      NFSv4/pnfs: Fix a page lock leak in nfs_pageio_resend()
      NFS: Ensure O_DIRECT reports an error if the bytes read/written is 0
      NFS: Fix initialisation of I/O result struct in nfs_pgio_rpcsetup
      NFS: On fatal writeback errors, we need to call nfs_inode_remove_request()
      SUNRPC: Don't handle errors if the bind/connect succeeded
      pNFS/flexfiles: Turn off soft RPC calls
      SUNRPC: Handle EADDRINUSE and ENOBUFS correctly
      Revert "NFSv4/flexfiles: Abort I/O early if the layout segment was invalidated"
      SUNRPC: Handle connection breakages correctly in call_status()
      pNFS/flexfiles: Don't time out requests on hard mounts
      NFS: Fix spurious EIO read errors
      NFS: Fix writepage(s) error handling to not report errors twice
      NFSv2: Fix eof handling
      NFSv2: Fix write regression

YueHaibing (1):
      NFS: remove set but not used variable 'mapping'

 fs/nfs/dir.c                           |  2 +-
 fs/nfs/direct.c                        | 27 ++++++++++++-------
 fs/nfs/flexfilelayout/flexfilelayout.c | 28 +++++++-------------
 fs/nfs/inode.c                         | 33 ++++++++++++++----------
 fs/nfs/internal.h                      | 10 ++++++++
 fs/nfs/nfs4file.c                      | 12 ++++-----
 fs/nfs/pagelist.c                      | 19 ++++++++------
 fs/nfs/pnfs_nfs.c                      | 15 +++++++----
 fs/nfs/proc.c                          |  7 +++--
 fs/nfs/read.c                          | 35 ++++++++++++++++++-------
 fs/nfs/write.c                         | 38 ++++++++++++---------------
 include/linux/sunrpc/sched.h           |  1 -
 net/sunrpc/clnt.c                      | 47 +++++++++++++++++++++++-----------
 net/sunrpc/xprt.c                      |  7 -----
 14 files changed, 163 insertions(+), 118 deletions(-)
-- 
Trond Myklebust
Linux NFS client maintainer, Hammerspace
trond.myklebust@hammerspace.com



^ permalink raw reply	[flat|nested] 82+ messages in thread

* Re: [GIT PULL] Please pull NFS client bugfixes
  2019-08-08 21:26 Trond Myklebust
@ 2019-08-09  1:30 ` pr-tracker-bot
  0 siblings, 0 replies; 82+ messages in thread
From: pr-tracker-bot @ 2019-08-09  1:30 UTC (permalink / raw)
  To: Trond Myklebust; +Cc: torvalds, linux-nfs, linux-kernel

The pull request you sent on Thu, 8 Aug 2019 21:26:49 +0000:

> git://git.linux-nfs.org/projects/trondmy/linux-nfs.git tags/nfs-for-5.3-2

has been merged into torvalds/linux.git:
https://git.kernel.org/torvalds/c/b678c568c561cf7e4ed40f4bcc3e85d2b50310a2

Thank you!

-- 
Deet-doot-dot, I am a bot.
https://korg.wiki.kernel.org/userdoc/prtracker

^ permalink raw reply	[flat|nested] 82+ messages in thread

* [GIT PULL] Please pull NFS client bugfixes
@ 2019-08-08 21:26 Trond Myklebust
  2019-08-09  1:30 ` pr-tracker-bot
  0 siblings, 1 reply; 82+ messages in thread
From: Trond Myklebust @ 2019-08-08 21:26 UTC (permalink / raw)
  To: torvalds; +Cc: linux-nfs, linux-kernel

Hi Linus,

The following changes since commit e21a712a9685488f5ce80495b37b9fdbe96c230d:

  Linux 5.3-rc3 (2019-08-04 18:40:12 -0700)

are available in the Git repository at:

  git://git.linux-nfs.org/projects/trondmy/linux-nfs.git tags/nfs-for-5.3-2

for you to fetch changes up to 67e7b52d44e3d539dfbfcd866c3d3d69da23a909:

  NFSv4: Ensure state recovery handles ETIMEDOUT correctly (2019-08-07 12:55:11 -0400)

----------------------------------------------------------------
NFS client bugfixes for Linux 5.3

Highlights include:

Stable fixes:
- NFSv4: Ensure we check the return value of update_open_stateid() so we
  correctly track active open state.
- NFSv4: Fix for delegation state recovery to ensure we recover all open
  modes that are active.
- NFSv4: Fix an Oops in nfs4_do_setattr

Bugfixes:
- NFS: Fix regression whereby fscache errors are appearing on 'nofsc' mounts
- NFSv4: Fix a potential sleep while atomic in nfs4_do_reclaim()
- NFSv4: Fix a credential refcount leak in nfs41_check_delegation_stateid
- pNFS: Report errors from the call to nfs4_select_rw_stateid()
- NFSv4: Various other delegation and open stateid recovery fixes
- NFSv4: Fix state recovery behaviour when server connection times out

----------------------------------------------------------------
Trond Myklebust (12):
      NFSv4: Fix a credential refcount leak in nfs41_check_delegation_stateid
      NFSv4: Fix delegation state recovery
      NFSv4: Print an error in the syslog when state is marked as irrecoverable
      NFSv4: When recovering state fails with EAGAIN, retry the same recovery
      NFSv4: Report the error from nfs4_select_rw_stateid()
      NFSv4.1: Fix open stateid recovery
      NFSv4.1: Only reap expired delegations
      NFSv4: Check the return value of update_open_stateid()
      NFSv4: Fix a potential sleep while atomic in nfs4_do_reclaim()
      NFSv4: Fix an Oops in nfs4_do_setattr
      NFS: Fix regression whereby fscache errors are appearing on 'nofsc' mounts
      NFSv4: Ensure state recovery handles ETIMEDOUT correctly

 fs/nfs/delegation.c |  25 ++++++++----
 fs/nfs/delegation.h |   2 +-
 fs/nfs/fscache.c    |   7 +++-
 fs/nfs/fscache.h    |   2 +-
 fs/nfs/nfs4_fs.h    |   3 +-
 fs/nfs/nfs4client.c |   5 ++-
 fs/nfs/nfs4proc.c   | 109 ++++++++++++++++++++++++++++++----------------------
 fs/nfs/nfs4state.c  |  49 ++++++++++++++++++-----
 fs/nfs/pnfs.c       |   7 +---
 fs/nfs/super.c      |   1 +
 10 files changed, 135 insertions(+), 75 deletions(-)

-- 
Trond Myklebust
Linux NFS client maintainer, Hammerspace
trond.myklebust@hammerspace.com



^ permalink raw reply	[flat|nested] 82+ messages in thread

* [GIT PULL] Please pull NFS client bugfixes
@ 2019-06-05 21:02 Schumaker, Anna
  0 siblings, 0 replies; 82+ messages in thread
From: Schumaker, Anna @ 2019-06-05 21:02 UTC (permalink / raw)
  To: torvalds; +Cc: linux-nfs, linux-kernel

Hi Linus,

The following changes since commit
cd6c84d8f0cdc911df435bb075ba22ce3c605b07:

  Linux 5.2-rc2 (2019-05-26 16:49:19 -0700)

are available in the Git repository at:

  git://git.linux-nfs.org/projects/anna/linux-nfs.git tags/nfs-for-5.2-
2

for you to fetch changes up to
ba851a39c9703f09684a541885ed176f8fb7c868:

  NFSv4.1: Fix bug only first CB_NOTIFY_LOCK is handled (2019-05-30
15:51:07 -0400)

----------------------------------------------------------------
These are mostly stable bugfixes found during testing, many during the
recent NFS bake-a-thon.

Stable bugfixes:
- SUNRPC: Fix regression in umount of a secure mount
- SUNRPC: Fix a use after free when a server rejects the RPCSEC_GSS
credential
- NFSv4.1: Again fix a race where CB_NOTIFY_LOCK fails to wake a waiter
- NFSv4.1: Fix bug only first CB_NOTIFY_LOCK is handled

Other bugfixes:
- xprtrdma: Use struct_size() in kzalloc()

Thanks,
Anna

----------------------------------------------------------------
Gustavo A. R. Silva (1):

      xprtrdma: Use struct_size() in kzalloc()

Olga Kornievskaia (1):
      SUNRPC fix regression in umount of a secure mount

Trond Myklebust (1):
      SUNRPC: Fix a use after free when a server rejects the RPCSEC_GSS
credential

Yihao Wu (2):
      NFSv4.1: Again fix a race where CB_NOTIFY_LOCK fails to wake a
waiter
      NFSv4.1: Fix bug only first CB_NOTIFY_LOCK is handled

 fs/nfs/nfs4proc.c           | 32 ++++++++++++--------------------
 net/sunrpc/clnt.c           | 30 +++++++++++++++---------------
 net/sunrpc/xprtrdma/verbs.c |  3 +--
 3 files changed, 28 insertions(+), 37 deletions(-)

^ permalink raw reply	[flat|nested] 82+ messages in thread

* Re: [GIT PULL] Please pull NFS client bugfixes
  2019-04-13 14:56 Trond Myklebust
@ 2019-04-13 22:00 ` pr-tracker-bot
  0 siblings, 0 replies; 82+ messages in thread
From: pr-tracker-bot @ 2019-04-13 22:00 UTC (permalink / raw)
  To: Trond Myklebust; +Cc: torvalds, linux-kernel, linux-nfs

The pull request you sent on Sat, 13 Apr 2019 14:56:35 +0000:

> git://git.linux-nfs.org/projects/trondmy/linux-nfs.git tags/nfs-for-5.1-4

has been merged into torvalds/linux.git:
https://git.kernel.org/torvalds/c/b60bc0665e6af8c55b946b67ea8cb235823bb74e

Thank you!

-- 
Deet-doot-dot, I am a bot.
https://korg.wiki.kernel.org/userdoc/prtracker

^ permalink raw reply	[flat|nested] 82+ messages in thread

* [GIT PULL] Please pull NFS client bugfixes
@ 2019-04-13 14:56 Trond Myklebust
  2019-04-13 22:00 ` pr-tracker-bot
  0 siblings, 1 reply; 82+ messages in thread
From: Trond Myklebust @ 2019-04-13 14:56 UTC (permalink / raw)
  To: torvalds; +Cc: linux-kernel, linux-nfs

Hi Linus,

The following changes since commit 582549e3fbe137eb6ce9be591aca25c2222a36b4:

  Merge tag 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/rdma/rdma (2019-04-10 09:39:04 -1000)

are available in the Git repository at:

  git://git.linux-nfs.org/projects/trondmy/linux-nfs.git tags/nfs-for-5.1-4

for you to fetch changes up to af6b61d7ef58099c82d854395a0e002be6bd036c:

  Revert "SUNRPC: Micro-optimise when the task is known not to be sleeping" (2019-04-11 15:41:14 -0400)

----------------------------------------------------------------
NFS client bugfixes for Linux 5.1

Highlights include:

Stable fixes:
- Fix a deadlock in close() due to incorrect draining of RDMA queues

Bugfixes:
- Revert "SUNRPC: Micro-optimise when the task is known not to be sleeping"
  as it is causing stack overflows
- Fix a regression where NFSv4 getacl and fs_locations stopped working
- Forbid setting AF_INET6 to "struct sockaddr_in"->sin_family.
- Fix xfstests failures due to incorrect copy_file_range() return values

----------------------------------------------------------------
Chuck Lever (2):
      NFS: Fix handling of reply page vector
      xprtrdma: Fix helper that drains the transport

Olga Kornievskaia (1):
      NFSv4.1 fix incorrect return value in copy_file_range

Tetsuo Handa (1):
      NFS: Forbid setting AF_INET6 to "struct sockaddr_in"->sin_family.

Trond Myklebust (1):
      Revert "SUNRPC: Micro-optimise when the task is known not to be sleeping"

 fs/nfs/nfs42proc.c           |  3 ---
 fs/nfs/nfs4file.c            |  4 +++-
 fs/nfs/nfs4xdr.c             |  4 ++--
 fs/nfs/super.c               |  3 ++-
 include/linux/sunrpc/sched.h |  8 --------
 net/sunrpc/clnt.c            | 45 ++++++++------------------------------------
 net/sunrpc/xprtrdma/verbs.c  |  2 +-
 7 files changed, 16 insertions(+), 53 deletions(-)

-- 
Trond Myklebust
Linux NFS client maintainer, Hammerspace
trond.myklebust@hammerspace.com



^ permalink raw reply	[flat|nested] 82+ messages in thread

* Re: [GIT PULL] Please pull NFS client bugfixes
  2018-12-19 16:49 Trond Myklebust
  2018-12-20  2:50 ` pr-tracker-bot
@ 2018-12-20 15:23 ` Geert Uytterhoeven
  1 sibling, 0 replies; 82+ messages in thread
From: Geert Uytterhoeven @ 2018-12-20 15:23 UTC (permalink / raw)
  To: Trond Myklebust; +Cc: torvalds, linux-kernel, linux-nfs

On Wed, Dec 19, 2018 at 9:28 PM Trond Myklebust <trondmy@hammerspace.com> wrote:
> The following 3 patches fix a regression in the NFS/RPC TPC re-
> connection code which can cause the RPC transmission to hang. The issue
> was discovered by Dave Wysochanski last week.
>
> With this pull, we still have one more regression to fix. MIPS is
> seeing data corruption due to the fact that the iovec_iter code does
> not appear to call flush_dcache_page() after copying data into the bvec
> pages. We need guidance from Al as to how he wants this fixed.

FTR, the report for that issue is
https://lore.kernel.org/lkml/CAMuHMdVJr0PwvJg3FeTCy7vxuyY1=S1tPLHO7hPsoZX4wZ+-cQ@mail.gmail.com/

Gr{oetje,eeting}s,

                        Geert

-- 
Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- geert@linux-m68k.org

In personal conversations with technical people, I call myself a hacker. But
when I'm talking to journalists I just say "programmer" or something like that.
                                -- Linus Torvalds

^ permalink raw reply	[flat|nested] 82+ messages in thread

* Re: [GIT PULL] Please pull NFS client  bugfixes
  2018-12-19 16:49 Trond Myklebust
@ 2018-12-20  2:50 ` pr-tracker-bot
  2018-12-20 15:23 ` Geert Uytterhoeven
  1 sibling, 0 replies; 82+ messages in thread
From: pr-tracker-bot @ 2018-12-20  2:50 UTC (permalink / raw)
  To: Trond Myklebust; +Cc: torvalds, linux-kernel, linux-nfs

The pull request you sent on Wed, 19 Dec 2018 16:49:11 +0000:

> git://git.linux-nfs.org/projects/trondmy/linux-nfs.git tags/nfs-for-4.20-6

has been merged into torvalds/linux.git:
https://git.kernel.org/torvalds/c/8c9dff1ebd721a3b19a002d1a901d4dc31b18ebb

Thank you!

-- 
Deet-doot-dot, I am a bot.
https://korg.wiki.kernel.org/userdoc/prtracker

^ permalink raw reply	[flat|nested] 82+ messages in thread

* [GIT PULL] Please pull NFS client  bugfixes
@ 2018-12-19 16:49 Trond Myklebust
  2018-12-20  2:50 ` pr-tracker-bot
  2018-12-20 15:23 ` Geert Uytterhoeven
  0 siblings, 2 replies; 82+ messages in thread
From: Trond Myklebust @ 2018-12-19 16:49 UTC (permalink / raw)
  To: torvalds; +Cc: linux-kernel, linux-nfs

Hi Linus,

The following 3 patches fix a regression in the NFS/RPC TPC re-
connection code which can cause the RPC transmission to hang. The issue
was discovered by Dave Wysochanski last week.

With this pull, we still have one more regression to fix. MIPS is
seeing data corruption due to the fact that the iovec_iter code does
not appear to call flush_dcache_page() after copying data into the bvec
pages. We need guidance from Al as to how he wants this fixed.

Cheers
  Trond

The following changes since commit 7566ec393f4161572ba6f11ad5171fd5d59b0fbd:

  Linux 4.20-rc7 (2018-12-16 15:46:55 -0800)

are available in the Git repository at:

  git://git.linux-nfs.org/projects/trondmy/linux-nfs.git tags/nfs-for-4.20-6

for you to fetch changes up to abc13275771fac77e2d7b129c289522dacb644b6:

  SUNRPC: Remove xprt_connect_status() (2018-12-18 11:04:10 -0500)

----------------------------------------------------------------
NFS client bugfixes for Linux 4.20

Bugfixes:
- Fix TCP socket disconnection races by ensuring we always call
  xprt_disconnect_done() after releasing the socket.
- Fix a race when clearing both XPRT_CONNECTING and XPRT_LOCKED
- Remove xprt_connect_status() so it does not mask errors that should
  be handled by call_connect_status()

----------------------------------------------------------------
Trond Myklebust (3):
      SUNRPC: Fix disconnection races
      SUNRPC: Fix a race with XPRT_CONNECTING
      SUNRPC: Remove xprt_connect_status()

 net/sunrpc/clnt.c     |  1 +
 net/sunrpc/xprt.c     | 35 ++++-------------------------------
 net/sunrpc/xprtsock.c | 10 ++++------
 3 files changed, 9 insertions(+), 37 deletions(-)

-- 
Trond Myklebust
Linux NFS client maintainer, Hammerspace
trond.myklebust@hammerspace.com



^ permalink raw reply	[flat|nested] 82+ messages in thread

* [GIT PULL] Please pull NFS client bugfixes
@ 2018-03-12 17:29 Trond Myklebust
  0 siblings, 0 replies; 82+ messages in thread
From: Trond Myklebust @ 2018-03-12 17:29 UTC (permalink / raw)
  To: torvalds; +Cc: linux-kernel, linux-nfs

Hi Linus,

The following changes since commit 1b88accf6a659c46d5c8e68912896f112bf882bb:

  Merge tag 'for_linus' of git://git.kernel.org/pub/scm/linux/kernel/git/mst/vhost (2018-03-07 17:49:33 -0800)

are available in the Git repository at:

  git://git.linux-nfs.org/projects/trondmy/linux-nfs.git tags/nfs-for-4.16-4

for you to fetch changes up to c4f24df942a181699c5bab01b8e5e82b925f77f3:

  NFS: Fix unstable write completion (2018-03-08 12:56:32 -0500)

----------------------------------------------------------------
NFS client bugfixes for Linux 4.16

Hightlights include the following stable fixes:

- NFS: Fix an incorrect type in struct nfs_direct_req
- pNFS: Prevent the layout header refcount going to zero in pnfs_roc()
- NFS: Fix unstable write completion

----------------------------------------------------------------
Trond Myklebust (3):
      NFS: Fix an incorrect type in struct nfs_direct_req
      pNFS: Prevent the layout header refcount going to zero in pnfs_roc()
      NFS: Fix unstable write completion

 fs/nfs/direct.c |  2 +-
 fs/nfs/pnfs.c   | 13 ++++++---
 fs/nfs/write.c  | 83 ++++++++++++++++++++++++++++++---------------------------
 3 files changed, 54 insertions(+), 44 deletions(-)

-- 
Trond Myklebust
Linux NFS client maintainer, PrimaryData
trond.myklebust@primarydata.com

^ permalink raw reply	[flat|nested] 82+ messages in thread

* [GIT PULL] Please pull NFS client bugfixes
@ 2018-02-25 17:02 Trond Myklebust
  0 siblings, 0 replies; 82+ messages in thread
From: Trond Myklebust @ 2018-02-25 17:02 UTC (permalink / raw)
  To: torvalds; +Cc: linux-kernel, linux-nfs

Hi Linus,

The following changes since commit af3e79d29555b97dd096e2f8e36a0f50213808a8:

  Merge tag 'leds_for-4.16-rc3' of git://git.kernel.org/pub/scm/linux/kernel/git/j.anaszewski/linux-leds (2018-02-20 10:05:02 -0800)

are available in the Git repository at:

  git://git.linux-nfs.org/projects/trondmy/linux-nfs.git tags/nfs-for-4.16-3

for you to fetch changes up to 1b7204064582792b77c6be796e78bd821c9f71b1:

  NFS: make struct nlmclnt_fl_close_lock_ops static (2018-02-22 12:23:01 -0500)

----------------------------------------------------------------
NFS client bugfixes for Linux 4.16

Hightlights include:
- Fix a broken cast in nfs4_callback_recallany()
- Fix an Oops during NFSv4 migration events
- make struct nlmclnt_fl_close_lock_ops static

----------------------------------------------------------------
Bill.Baker@oracle.com (1):
      nfs: system crashes after NFS4ERR_MOVED recovery

Colin Ian King (1):
      NFS: make struct nlmclnt_fl_close_lock_ops static

Trond Myklebust (1):
      NFSv4: Fix broken cast in nfs4_callback_recallany()

 fs/nfs/callback_proc.c | 14 ++++++--------
 fs/nfs/nfs3proc.c      |  2 +-
 fs/nfs/nfs4client.c    |  6 ++++--
 3 files changed, 11 insertions(+), 11 deletions(-)
-- 
Trond Myklebust
Linux NFS client maintainer, PrimaryData
trond.myklebust@primarydata.com

^ permalink raw reply	[flat|nested] 82+ messages in thread

* [GIT PULL] Please pull NFS client bugfixes
@ 2017-01-28 17:04 Trond Myklebust
  0 siblings, 0 replies; 82+ messages in thread
From: Trond Myklebust @ 2017-01-28 17:04 UTC (permalink / raw)
  To: torvalds; +Cc: linux-kernel, linux-nfs

Hi Linus,

The following changes since commit 7a308bb3016f57e5be11a677d15b821536419d36:

  Linux 4.10-rc5 (2017-01-22 12:54:15 -0800)

are available in the git repository at:

  git://git.linux-nfs.org/projects/trondmy/linux-nfs.git tags/nfs-for-4.10-4

for you to fetch changes up to ee6625a948d2e47267ec8fd97307fdd67d0f8a5b:

  pNFS: Fix a reference leak in _pnfs_return_layout (2017-01-26 15:50:41 -0500)

----------------------------------------------------------------
NFS client bugfixes for Linux 4.10

Stable patches:
- NFSv4.1: Fix a deadlock in layoutget
- NFSv4 must not bump sequence ids on NFS4ERR_MOVED errors
- NFSv4 Fix a regression with OPEN EXCLUSIVE4 mode
- Fix a memory leak when removing the SUNRPC module

Bugfixes:
- Fix a reference leak in _pnfs_return_layout

----------------------------------------------------------------
Benjamin Coddington (1):
      NFSv4.0: always send mode in SETATTR after EXCLUSIVE4

Chuck Lever (2):
      nfs: Don't increment lock sequence ID after NFS4ERR_MOVED
      nfs: Fix "Don't increment lock sequence ID after NFS4ERR_MOVED"

Kinglong Mee (1):
      SUNRPC: cleanup ida information when removing sunrpc module

Trond Myklebust (2):
      NFSv4.1: Fix a deadlock in layoutget
      pNFS: Fix a reference leak in _pnfs_return_layout

 fs/nfs/nfs4proc.c           | 4 +++-
 fs/nfs/nfs4state.c          | 1 +
 fs/nfs/pnfs.c               | 2 +-
 include/linux/nfs4.h        | 3 ++-
 include/linux/sunrpc/clnt.h | 1 +
 net/sunrpc/clnt.c           | 5 +++++
 net/sunrpc/sunrpc_syms.c    | 1 +
 7 files changed, 14 insertions(+), 3 deletions(-)
-- 
Trond Myklebust
Linux NFS client maintainer, PrimaryData
trond.myklebust@primarydata.com

^ permalink raw reply	[flat|nested] 82+ messages in thread

* [GIT PULL] Please pull NFS client bugfixes
@ 2017-01-16 20:14 Trond Myklebust
  0 siblings, 0 replies; 82+ messages in thread
From: Trond Myklebust @ 2017-01-16 20:14 UTC (permalink / raw)
  To: torvalds; +Cc: linux-kernel, linux-nfs

Hi Linus,

The following changes since commit a121103c922847ba5010819a3f250f1f7fc84ab8:

  Linux 4.10-rc3 (2017-01-08 14:18:17 -0800)

are available in the git repository at:

  git://git.linux-nfs.org/projects/trondmy/linux-nfs.git tags/nfs-for-4.10-3

for you to fetch changes up to c6180a6237174f481dc856ed6e890d8196b6f0fb:

  NFSv4: Fix client recovery when server reboots multiple times (2017-01-13 13:31:32 -0500)

----------------------------------------------------------------
NFS client bugfixes for Linux 4.10

Bugfixes:
- Fix invalid fget()/fput() calls when doing file locking
- Fix multiple directory cache invalidation issues due to the client failing
  to recognise that the directory wasn't changed.
- Fix client recovery when server reboots multiple times

----------------------------------------------------------------
Benjamin Coddington (1):
      nfs: Don't take a reference on fl->fl_file for LOCK operation

Trond Myklebust (5):
      NFSv4: Call update_changeattr() from _nfs4_proc_open only if a file was created
      NFSv4: Don't apply change_info4 twice on rename within a directory
      NFSv4: Don't call update_changeattr() unless the unlink is successful
      NFSv4: update_changeattr should update the attribute timestamp
      NFSv4: Fix client recovery when server reboots multiple times

 fs/nfs/nfs4proc.c  | 29 ++++++++++++++++++-----------
 fs/nfs/nfs4state.c |  1 -
 2 files changed, 18 insertions(+), 12 deletions(-)

-- 
Trond Myklebust
Linux NFS client maintainer, PrimaryData
trond.myklebust@primarydata.com

^ permalink raw reply	[flat|nested] 82+ messages in thread

* [GIT PULL] Please pull NFS client bugfixes
@ 2016-10-21 20:30 Anna Schumaker
  0 siblings, 0 replies; 82+ messages in thread
From: Anna Schumaker @ 2016-10-21 20:30 UTC (permalink / raw)
  To: Linus Torvalds; +Cc: Trond Myklebust, linux-nfs, linux-kernel

Hi Linus,

The following changes since commit 3f807e5ae5597bd65a6fff684083e8eaa21f3fa7:

  NFSv4.2: Fix a reference leak in nfs42_proc_layoutstats_generic (2016-10-04 16:30:54 -0400)

are available in the git repository at:

  git://git.linux-nfs.org/projects/anna/linux-nfs.git tags/nfs-for-4.9-2

for you to fetch changes up to 83aa3e0f791d458a28f91d7a50f92926f971ef7c:

  nfs4: fix missing-braces warning (2016-10-19 14:39:15 -0400)

----------------------------------------------------------------
Just two bugfixes this time:

Stable bugfix:
- Fix last_write_offset incorrectly set to page boundary

Other bugfix:
- Fix missing-braces warning

Thanks,
Anna
----------------------------------------------------------------
Arnd Bergmann (1):
      nfs4: fix missing-braces warning

Benjamin Coddington (1):
      pnfs/blocklayout: fix last_write_offset incorrectly set to page boundary

 fs/nfs/blocklayout/blocklayout.c | 3 ++-
 fs/nfs/nfs4proc.c                | 2 +-
 2 files changed, 3 insertions(+), 2 deletions(-)

^ permalink raw reply	[flat|nested] 82+ messages in thread

* [GIT PULL] Please pull NFS client bugfixes
@ 2015-10-07  2:52 Trond Myklebust
  0 siblings, 0 replies; 82+ messages in thread
From: Trond Myklebust @ 2015-10-07  2:52 UTC (permalink / raw)
  To: Linus Torvalds; +Cc: linux-kernel, linux-nfs

Hi Linus,

The following changes since commit 5634347dee31373a8faf084f4cdbf6d5ea0b03a4:

  Merge tag 'arm64-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/arm64/linux (2015-10-02 14:54:16 -0400)

are available in the git repository at:

  git://git.linux-nfs.org/projects/trondmy/linux-nfs.git tags/nfs-for-4.3-3

for you to fetch changes up to 39d0d3bdf7bab3021a31e501172ac0f18947f9b3:

  NFS: Fix a tracepoint NULL-pointer dereference (2015-10-06 18:56:25 -0400)

Cheers
  Trond

----------------------------------------------------------------
NFS client bugfixes for Linux 4.3

Highlights include:

Bugfixes:
- Fix a use-after-free bug in the RPC/RDMA client
- Fix a write performance regression
- Fix up page writeback accounting
- Don't try to reclaim unused state owners
- Fix a NFSv4 nograce recovery hang
- reset states to use open_stateid when returning delegation voluntarily
- Fix a tracepoint NULL-pointer dereference

----------------------------------------------------------------
Anna Schumaker (1):
      NFS: Fix a tracepoint NULL-pointer dereference

Benjamin Coddington (1):
      NFSv4: Fix a nograce recovery hang

Jeff Layton (1):
      nfs4: reset states to use open_stateid when returning delegation voluntarily

Steve Wise (1):
      xprtrdma: disconnect and flush cqs before freeing buffers

Trond Myklebust (5):
      NFS: Fix up page writeback accounting
      NFS: Fix a write performance regression
      NFSv4: Don't try to reclaim unused state owners
      NFSv4.1: nfs4_opendata_check_deleg needs to handle NFS4_OPEN_CLAIM_DELEG_CUR_FH
      Merge tag 'nfs-rdma-for-4.3-2' of git://git.linux-nfs.org/projects/anna/nfs-rdma

 fs/nfs/nfs4proc.c               | 15 +++++++++++++--
 fs/nfs/nfs4state.c              |  3 ++-
 fs/nfs/nfs4trace.h              |  2 +-
 fs/nfs/write.c                  | 14 +++++++-------
 net/sunrpc/xprtrdma/transport.c |  2 +-
 net/sunrpc/xprtrdma/verbs.c     |  9 ++++++---
 6 files changed, 30 insertions(+), 15 deletions(-)
-- 
Trond Myklebust
Linux NFS client maintainer, PrimaryData
trond.myklebust@primarydata.com




^ permalink raw reply	[flat|nested] 82+ messages in thread

* [GIT PULL] Please pull NFS client bugfixes
@ 2015-09-25 15:14 Trond Myklebust
  0 siblings, 0 replies; 82+ messages in thread
From: Trond Myklebust @ 2015-09-25 15:14 UTC (permalink / raw)
  To: Linus Torvalds; +Cc: Linux NFS Mailing List, Linux Kernel Mailing List

Hi Linus,

The following changes since commit 6ff33f3902c3b1c5d0db6b1e2c70b6d76fba357f:

  Linux 4.3-rc1 (2015-09-12 16:35:56 -0700)

are available in the git repository at:

  git://git.linux-nfs.org/projects/trondmy/linux-nfs.git tags/nfs-for-4.3-2

for you to fetch changes up to 500d701f336b2771d34e46da7875a4782515a652:

  NFS41: make close wait for layoutreturn (2015-09-23 08:55:32 -0400)

Cheers
  Trond

----------------------------------------------------------------
NFS client bugfixes for Linux 4.3

Highlights include:

Stable patches:
- fix v4.2 SEEK on files over 2 gigs
- Fix a layout segment reference leak when pNFS I/O falls back to inband I/O.
- Fix recovery of recalled read delegations

Bugfixes:
- Fix a case where NFSv4 fails to send CLOSE after a server reboot
- Fix sunrpc to wait for connections to complete before retrying
- Fix sunrpc races between transport connect/disconnect and shutdown
- Fix an infinite loop when layoutget fail with BAD_STATEID
- nfs/filelayout: Fix NULL reference caused by double freeing of fh_array
- Fix a bogus WARN_ON_ONCE() in O_DIRECT when layout commit_through_mds is set
- Fix layoutreturn/close ordering issues.

----------------------------------------------------------------
J. Bruce Fields (1):
      nfs: fix v4.2 SEEK on files over 2 gigs

Julia Lawall (1):
      SUNRPC: drop null test before destroy functions

Kinglong Mee (4):
      nfs/filelayout: Fix NULL reference caused by double freeing of fh_array
      NFS: Do cleanup before resetting pageio read/write to mds
      NFS: Fix an infinite loop when layoutget fail with BAD_STATEID
      NFS: Skip checking ds_cinfo.buckets when lseg's commit_through_mds is set

Olga Kornievskaia (1):
      Failing to send a CLOSE if file is opened WRONLY and server reboots on a 4.x mount

Peng Tao (2):
      nfs: fix pg_test page count calculation
      NFS41: make close wait for layoutreturn

Trond Myklebust (6):
      SUNRPC: Fix races between socket connection and destroy code
      SUNRPC: Ensure that we wait for connections to complete before retrying
      SUNRPC: Lock the transport layer on shutdown
      SUNRPC: xs_sock_mark_closed() does not need to trigger socket autoclose
      NFSv4: Recovery of recalled read delegations is broken
      NFSv4.x/pnfs: Don't try to recover stateids twice in layoutget

 fs/nfs/delegation.c             |   8 ++-
 fs/nfs/delegation.h             |   2 +-
 fs/nfs/direct.c                 |   7 ++-
 fs/nfs/filelayout/filelayout.c  |  31 ++++------
 fs/nfs/nfs42proc.c              |   4 +-
 fs/nfs/nfs4proc.c               | 127 ++++++++++++++++++++++++++--------------
 fs/nfs/nfs4state.c              |   2 +-
 fs/nfs/pagelist.c               |   2 +-
 fs/nfs/pnfs.c                   |  35 +++++++----
 fs/nfs/pnfs.h                   |   7 +++
 fs/nfs/read.c                   |   3 +
 fs/nfs/write.c                  |   3 +
 include/linux/sunrpc/xprtsock.h |   3 +
 net/sunrpc/sched.c              |  12 ++--
 net/sunrpc/xprt.c               |   6 ++
 net/sunrpc/xprtsock.c           |  15 +++--
 16 files changed, 172 insertions(+), 95 deletions(-)
-- 
Trond Myklebust
Linux NFS client maintainer, PrimaryData
trond.myklebust@primarydata.com




^ permalink raw reply	[flat|nested] 82+ messages in thread

* [GIT PULL] Please pull NFS client bugfixes
@ 2015-07-28 16:03 Trond Myklebust
  0 siblings, 0 replies; 82+ messages in thread
From: Trond Myklebust @ 2015-07-28 16:03 UTC (permalink / raw)
  To: Linus Torvalds; +Cc: linux-kernel, linux-nfs

Hi Linus,

The following changes since commit b4839ebe21fc5d543b933d83644981ea73e9ba36:

  nfs: Remove invalid tk_pid from debug message (2015-07-01 11:31:25 -0400)

are available in the git repository at:

  git://git.linux-nfs.org/projects/trondmy/linux-nfs.git tags/nfs-for-4.2-2

for you to fetch changes up to a49c269111a5b3c1fd2a98f36fa27423b94549f8:

  nfs: Fix an oops caused by using other thread's stack space in ASYNC mode (2015-07-28 09:07:03 -0400)

----------------------------------------------------------------
NFS client bugfixes for Linux 4.2

Highlights include:

Stable patches:
- Fix a situation where the client uses the wrong (zero) stateid.
- Fix a memory leak in nfs_do_recoalesce

Bugfixes:
- Plug a memory leak when ->prepare_layoutcommit fails
- Fix an Oops in the NFSv4 open code
- Fix a backchannel deadlock
- Fix a livelock in sunrpc when sendmsg fails due to low memory availability
- Don't revalidate the mapping if both size and change attr are up to date
- Ensure we don't miss a file extension when doing pNFS
- Several fixes to handle NFSv4.1 sequence operation status bits correctly
- Several pNFS layout return bugfixes

----------------------------------------------------------------
J. Bruce Fields (1):
      NFSv4.2: handle NFS-specific llseek errors

Jeff Layton (1):
      nfs: plug memory leak when ->prepare_layoutcommit fails

Kinglong Mee (1):
      nfs: Fix an oops caused by using other thread's stack space in ASYNC mode

NeilBrown (1):
      sunrpc: translate -EAGAIN to -ENOBUFS when socket is writable.

Trond Myklebust (24):
      SUNRPC: Don't reencode message if transmission failed with ENOBUFS
      SUNRPC: Don't confuse ENOBUFS with a write_space issue
      NFSv4.1: Handle SEQ4_STATUS_EXPIRED_SOME_STATE_REVOKED status bit correctly.
      NFSv4.1: Handle SEQ4_STATUS_RECALLABLE_STATE_REVOKED status bit correctly
      NFSv4.1: Handle SEQ4_STATUS_BACKCHANNEL_FAULT correctly
      NFSv4.1: nfs41_sequence_done should handle sequence flag errors
      NFSv4: Leases are renewed in sequence_done when we have sessions
      NFSv4.2/flexfiles: Fix a typo in the flexfiles layoutstats code
      pNFS: Layoutreturn must invalidate all existing layout segments.
      pNFS: pnfs_roc_drain should return 'true' when sleeping
      pNFS: Fix races between return-on-close and layoutreturn.
      pNFS: pnfs_roc_drain() fix a race with open
      pNFS: Don't throw out valid layout segments
      SUNRPC: Fix a backchannel deadlock
      SUNRPC: xprt_complete_bc_request must also decrement the free slot count
      NFSv4: We must set NFS_OPEN_STATE flag in nfs_resync_open_stateid_locked
      NFSv4/pnfs: Ensure we don't miss a file extension
      NFS: Don't revalidate the mapping if both size and change attr are up to date
      NFS: Set NFS_INO_REVAL_PAGECACHE if the change attribute is uninitialised
      NFS: Remove the "NFS_CAP_CHANGE_ATTR" capability
      NFS: nfs_mark_for_revalidate should always set NFS_INO_REVAL_PAGECACHE
      NFS: Fix a memory leak in nfs_do_recoalesce
      NFS: Don't clear desc->pg_moreio in nfs_do_recoalesce()
      SUNRPC: Report TCP errors to the caller

 fs/nfs/client.c                        |   2 +-
 fs/nfs/flexfilelayout/flexfilelayout.c |   2 +-
 fs/nfs/inode.c                         |  15 ++---
 fs/nfs/internal.h                      |  21 +++++++
 fs/nfs/nfs42proc.c                     |  19 ++++++-
 fs/nfs/nfs4proc.c                      |  36 +++++++-----
 fs/nfs/nfs4state.c                     |  29 +++++++---
 fs/nfs/pagelist.c                      |   7 ++-
 fs/nfs/pnfs.c                          | 101 +++++++++++++++++++--------------
 fs/nfs/write.c                         |  15 +++--
 include/linux/nfs_fs.h                 |   7 ++-
 include/linux/nfs_fs_sb.h              |   2 +-
 net/sunrpc/backchannel_rqst.c          |   6 +-
 net/sunrpc/clnt.c                      |   5 +-
 net/sunrpc/xprtsock.c                  |  25 +++++---
 15 files changed, 189 insertions(+), 103 deletions(-)
-- 
Trond Myklebust
Linux NFS client maintainer, PrimaryData
trond.myklebust@primarydata.com



^ permalink raw reply	[flat|nested] 82+ messages in thread

* [GIT PULL] Please pull NFS client bugfixes
@ 2015-03-06  3:46 Trond Myklebust
  0 siblings, 0 replies; 82+ messages in thread
From: Trond Myklebust @ 2015-03-06  3:46 UTC (permalink / raw)
  To: Linus Torvalds; +Cc: Linux NFS Mailing List, Linux Kernel Mailing List

Hi Linus,

The following changes since commit c517d838eb7d07bbe9507871fab3931deccff539:

  Linux 4.0-rc1 (2015-02-22 18:21:14 -0800)

are available in the git repository at:

  git://git.linux-nfs.org/projects/trondmy/linux-nfs.git tags/nfs-for-4.0-3

for you to fetch changes up to e11259f920d8cb3550e0f311c064bdabe1bc3aaf:

  NFSv4.1: Clear the old state by our client id before establishing a new lease (2015-03-03 21:52:30 -0500)

----------------------------------------------------------------
NFS client bugfixes for Linux 4.0

Highlights include:

- Fix a regression in the NFSv4 open state recovery code
- Fix a regression in the NFSv4 close code
- Fix regressions and side-effects of the loop-back mounted NFS fixes
  in 3.18, that cause the NFS read() syscall to return EBUSY.
- Fix regressions around the readdirplus code and how it interacts with
  the VFS lazy unmount changes that went into v3.18.
- Fix issues with out-of-order RPC call replies replacing updated
  attributes with stale ones (particularly after a truncate()).
- Fix an underflow checking issue with RPC/RDMA credits
- Fix a number of issues with the NFSv4 delegation return/free code.
- Fix issues around stale NFSv4.1 leases when doing a mount

----------------------------------------------------------------
Anna Schumaker (1):
      NFS: Fix stateid used for NFS v4 closes

Chuck Lever (1):
      xprtrdma: Store RDMA credits in unsigned variables

Trond Myklebust (23):
      Merge tag 'nfs-rdma-for-4.0-3' of git://git.linux-nfs.org/projects/anna/nfs-rdma
      NFSv4: nfs4_open_recover_helper() must set share access
      NFS: Ensure that buffered writes wait for O_DIRECT writes to complete
      NFS: Add a helper to set attribute barriers
      NFS: Add attribute update barriers to nfs_setattr_update_inode()
      NFS: Set an attribute barrier on all updates
      NFS: Add attribute update barriers to NFS writebacks
      NFSv4: Add attribute update barriers to delegreturn and pNFS layoutcommit
      NFS: Remove size hack in nfs_inode_attrs_need_update()
      NFS: Fix nfs_post_op_update_inode() to set an attribute barrier
      NFSv4: Set a barrier in the update_changeattr() helper
      NFS: Don't invalidate a submounted dentry in nfs_prime_dcache()
      NFSv3: Use the readdir fileid as the mounted-on-fileid
      NFS: Don't require a filehandle to refresh the inode in nfs_prime_dcache()
      NFSv4: Don't call put_rpccred() under the rcu_read_lock()
      NFSv4: Ensure that we don't reap a delegation that is being returned
      NFSv4: Ensure we honour NFS_DELEGATION_RETURNING in nfs_inode_set_delegation()
      NFSv4: Pin the superblock while we're returning the delegation
      NFSv4: Ensure we skip delegations that are already being returned
      NFS: Fix a regression in the read() syscall
      NFS: Don't write enable new pages while an invalidation is proceeding
      NFSv4: Fix a race in NFSv4.1 server trunking discovery
      NFSv4.1: Clear the old state by our client id before establishing a new lease

 fs/nfs/client.c                 |   2 +-
 fs/nfs/delegation.c             |  45 ++++++++++++----
 fs/nfs/dir.c                    |  22 ++++++--
 fs/nfs/file.c                   |  11 +++-
 fs/nfs/inode.c                  | 111 +++++++++++++++++++++++++++++++++-------
 fs/nfs/internal.h               |   1 +
 fs/nfs/nfs3proc.c               |   4 +-
 fs/nfs/nfs3xdr.c                |   5 ++
 fs/nfs/nfs4client.c             |   9 ++--
 fs/nfs/nfs4proc.c               |  31 +++++++----
 fs/nfs/nfs4session.h            |   1 +
 fs/nfs/nfs4state.c              |  18 ++++++-
 fs/nfs/proc.c                   |   6 +--
 fs/nfs/write.c                  |  30 +++++++++++
 include/linux/nfs_fs.h          |   5 +-
 net/sunrpc/xprtrdma/rpc_rdma.c  |   3 +-
 net/sunrpc/xprtrdma/xprt_rdma.h |   2 +-
 17 files changed, 244 insertions(+), 62 deletions(-)

-- 
Trond Myklebust
Linux NFS client maintainer, PrimaryData
trond.myklebust@primarydata.com





^ permalink raw reply	[flat|nested] 82+ messages in thread

* [GIT PULL] Please pull NFS client bugfixes
@ 2015-01-16 14:35 Trond Myklebust
  0 siblings, 0 replies; 82+ messages in thread
From: Trond Myklebust @ 2015-01-16 14:35 UTC (permalink / raw)
  To: Linus Torvalds; +Cc: Linux NFS Mailing List, Linux Kernel mailing list

Hi Linus,

The following changes since commit b1940cd21c0f4abdce101253e860feff547291b0:

  Linux 3.19-rc3 (2015-01-05 17:05:20 -0800)

are available in the git repository at:

  git://git.linux-nfs.org/projects/trondmy/linux-nfs.git tags/nfs-for-3.19-2

for you to fetch changes up to 4e379d36c050b0117b5d10048be63a44f5036115:

  NFSv4: Remove incorrect check in can_open_delegated() (2015-01-05 19:40:54 -0800)

----------------------------------------------------------------
NFS client bugfixes for Linux 3.19

Highlights include:

- Stable fix for a NFSv3/lockd race
- Fixes for several NFSv4.1 client id trunking bugs
- Remove an incorrect test when checking for delegated opens

----------------------------------------------------------------
Chuck Lever (1):
      NFS: Ignore transport protocol when detecting server trunking

Trond Myklebust (5):
      LOCKD: Fix a race when initialising nlmsvc_timeout
      NFSv4.1: Fix client id trunking on Linux
      NFSv4: Cache the NFSv4/v4.1 client owner_id in the struct nfs_client
      NFSv4/v4.1: Verify the client owner id during trunking detection
      NFSv4: Remove incorrect check in can_open_delegated()

 fs/lockd/svc.c            |  8 ++++----
 fs/nfs/nfs4client.c       | 42 +++++++++++++++++++++++++++---------------
 fs/nfs/nfs4proc.c         | 21 +++++++++++++++------
 include/linux/nfs_fs_sb.h |  3 +++
 4 files changed, 49 insertions(+), 25 deletions(-)

-- 
Trond Myklebust
Linux NFS client maintainer, PrimaryData
trond.myklebust@primarydata.com





^ permalink raw reply	[flat|nested] 82+ messages in thread

* [GIT PULL] Please pull NFS client bugfixes
@ 2014-11-14 23:04 Trond Myklebust
  0 siblings, 0 replies; 82+ messages in thread
From: Trond Myklebust @ 2014-11-14 23:04 UTC (permalink / raw)
  To: Linus Torvalds; +Cc: linux-nfs, linux-kernel

Hi Linus,

The following changes since commit 0df1f2487d2f0d04703f142813d53615d62a1da4:

  Linux 3.18-rc3 (2014-11-02 15:01:51 -0800)

are available in the git repository at:

  git://git.linux-nfs.org/projects/trondmy/linux-nfs.git tags/nfs-for-3.18-3

for you to fetch changes up to b3ecba096729f521312d1863ad22530695527aed:

  sunrpc: fix sleeping under rcu_read_lock in gss_stringify_acceptor (2014-11-13 13:15:49 -0500)

----------------------------------------------------------------
NFS client bugfixes for Linux 3.18

Highlights include:

- Stable patches to fix NFSv4.x delegation reclaim error paths
- Fix a bug whereby we were advertising NFSv4.1 but using NFSv4.2 features
- Fix a use-after-free problem with pNFS block layouts
- Fix a memory leak in the pNFS files O_DIRECT code
- Replace an intrusive and Oops-prone performance fix in the NFSv4 atomic
  open code with a safer one-line version and revert the two original patches.

----------------------------------------------------------------
Anna Schumaker (1):
      NFS: SEEK is an NFS v4.2 feature

Christoph Hellwig (1):
      pnfs/blocklayout: serialize GETDEVICEINFO calls

Jan Kara (2):
      nfs: Remove bogus assignment
      nfs: Fix use of uninitialized variable in nfs_getattr()

Jeff Layton (1):
      sunrpc: fix sleeping under rcu_read_lock in gss_stringify_acceptor

Peng Tao (1):
      nfs: fix pnfs direct write memory leak

Trond Myklebust (8):
      NFSv4: Ensure nfs_atomic_open set the dentry verifier on ENOENT
      Revert "NFS: remove BUG possibility in nfs4_open_and_get_state"
      Revert "NFS: nfs4_do_open should add negative results to the dcache."
      NFSv4: Ensure that we remove NFSv4.0 delegations when state has expired
      NFSv4.1: nfs41_clear_delegation_stateid shouldn't trust NFS_DELEGATED_STATE
      NFSv4: Fix races between nfs_remove_bad_delegation() and delegation return
      NFSv4: Ensure that we call FREE_STATEID when NFSv4.x stateids are revoked
      NFS: Don't try to reclaim delegation open state if recovery failed

Weston Andros Adamson (1):
      nfs: remove spurious WARN_ON_ONCE in write path

 fs/nfs/blocklayout/blocklayout.c |  2 +-
 fs/nfs/blocklayout/rpc_pipefs.c  | 14 +++---
 fs/nfs/delegation.c              | 25 ++++++++++-
 fs/nfs/delegation.h              |  1 +
 fs/nfs/dir.c                     |  1 +
 fs/nfs/direct.c                  |  1 +
 fs/nfs/filelayout/filelayout.c   |  3 --
 fs/nfs/inode.c                   |  2 +-
 fs/nfs/netns.h                   |  1 +
 fs/nfs/nfs4proc.c                | 95 +++++++++++++++++++---------------------
 fs/nfs/write.c                   |  2 -
 include/linux/nfs_xdr.h          | 11 +++++
 net/sunrpc/auth_gss/auth_gss.c   | 35 ++++++++++++---
 13 files changed, 124 insertions(+), 69 deletions(-)



^ permalink raw reply	[flat|nested] 82+ messages in thread

* [GIT PULL] Please pull NFS client bugfixes
@ 2014-09-19 19:32 Trond Myklebust
  0 siblings, 0 replies; 82+ messages in thread
From: Trond Myklebust @ 2014-09-19 19:32 UTC (permalink / raw)
  To: Linus Torvalds; +Cc: Linux NFS Mailing List, Linux Kernel mailing list

Hi Linus,

The following changes since commit 224ecbf5a674ec7da3a3b3ea21ca62e2853653fa:

  pnfs: fix filelayout_retry_commit when idx > 0 (2014-09-10 12:43:45 -0700)

are available in the git repository at:

  git://git.linux-nfs.org/projects/trondmy/linux-nfs.git tags/nfs-for-3.17-5

for you to fetch changes up to cd9288ffaea4359d5cfe2b8d264911506aed26a4:

  NFSv4: Fix another bug in the close/open_downgrade code (2014-09-18 13:04:22 -0400)

----------------------------------------------------------------
NFS client fixes for 3.17

Highligts:
- Fix an Oops in nfs4_open_and_get_state
- Fix an Oops in the nfs4_state_manager
- Fix another bug in the close/open_downgrade code

----------------------------------------------------------------
NeilBrown (1):
      NFS: remove BUG possibility in nfs4_open_and_get_state

Steve Dickson (1):
      NFSv4: nfs4_state_manager() vs. nfs_server_remove_lists()

Trond Myklebust (1):
      NFSv4: Fix another bug in the close/open_downgrade code

 fs/nfs/nfs4client.c | 38 ++++++++++++++++++++------------------
 fs/nfs/nfs4proc.c   | 40 ++++++++++++++++++++++------------------
 2 files changed, 42 insertions(+), 36 deletions(-)



^ permalink raw reply	[flat|nested] 82+ messages in thread

* [GIT PULL] Please pull NFS client bugfixes
@ 2014-01-31 21:41 Trond Myklebust
  0 siblings, 0 replies; 82+ messages in thread
From: Trond Myklebust @ 2014-01-31 21:41 UTC (permalink / raw)
  To: Torvalds Linus; +Cc: Linux NFS Mailing List, Linux Kernel mailing list

[-- Attachment #1: Type: text/plain, Size: 2360 bytes --]

Hi Linus,

The following changes since commit ed7e5423014ad89720fcf315c0b73f2c5d0c7bd2:

  pnfs: Proper delay for NFS4ERR_RECALLCONFLICT in layout_get_done (2014-01-22 18:10:49 -0700)

are available in the git repository at:

  git://git.linux-nfs.org/projects/trondmy/linux-nfs.git tags/nfs-for-3.14-2

for you to fetch changes up to a1800acaf7d1c2bf6d68b9a8f4ab8560cc66555a:

  nfs: initialize the ACL support bits to zero. (2014-01-31 08:28:16 -0500)

Please note that this pull excludes the fixes for the NFSv3 posix acl
regressions, since at least one of those patches will need an ack from
Al and/or Christoph.

Cheers
  Trond

----------------------------------------------------------------
NFS client bugfixes for Linux 3.14

Highlights:

- Fix several races in nfs_revalidate_mapping
- NFSv4.1 slot leakage in the pNFS files driver
- Stable fix for a slot leak in nfs40_sequence_done
- Don't reject NFSv4 servers that support ACLs with only ALLOW aces

----------------------------------------------------------------
Andy Adamson (1):
      NFSv4.1 free slot before resending I/O to MDS

Jeff Layton (3):
      NFS: fix the handling of NFS_INO_INVALID_DATA flag in nfs_revalidate_mapping
      sunrpc: turn warn_gssd() log message into a dprintk()
      nfs: add memory barriers around NFS_INO_INVALID_DATA and NFS_INO_INVALIDATING

Malahal Naineni (2):
      nfs: handle servers that support only ALLOW ACE type.
      nfs: initialize the ACL support bits to zero.

Trond Myklebust (4):
      NFS: Fix races in nfs_revalidate_mapping
      NFSv4: Fix a slot leak in nfs40_sequence_done
      NFSv4.1: Clean up nfs41_sequence_done
      NFSv4.1: Cleanup

 fs/nfs/dir.c                   | 13 +++++++++--
 fs/nfs/inode.c                 | 51 +++++++++++++++++++++++++++++++++++-------
 fs/nfs/nfs4_fs.h               |  1 +
 fs/nfs/nfs4client.c            |  5 +----
 fs/nfs/nfs4filelayout.c        |  8 +++++--
 fs/nfs/nfs4proc.c              | 31 ++++++++++++-------------
 fs/nfs/nfs4xdr.c               |  2 +-
 fs/nfs/nfstrace.h              |  1 +
 fs/nfs/write.c                 |  7 +++++-
 include/linux/nfs_fs.h         |  1 +
 net/sunrpc/auth_gss/auth_gss.c |  8 +------
 11 files changed, 86 insertions(+), 42 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] 82+ messages in thread

* [GIT PULL] Please pull NFS client bugfixes
@ 2013-12-05 17:20 Trond Myklebust
  0 siblings, 0 replies; 82+ messages in thread
From: Trond Myklebust @ 2013-12-05 17:20 UTC (permalink / raw)
  To: Torvalds Linus; +Cc: Linux NFS Mailing List, Linux Kernel mailing list

[-- Attachment #1: Type: text/plain, Size: 2279 bytes --]

Hi Linus,

The following changes since commit 8c2fabc6542d9d0f8b16bd1045c2eda59bdcde13:

  nfs: fix pnfs Kconfig defaults (2013-11-15 13:41:43 -0500)

are available in the git repository at:

  git://git.linux-nfs.org/projects/trondmy/linux-nfs.git tags/nfs-for-3.13-3

for you to fetch changes up to 3873d064b8538686bbbd4b858dc8a07db1f7f43a:

  nfs: fix do_div() warning by instead using sector_div() (2013-12-04 12:57:37 -0500)

----------------------------------------------------------------
NFS client bugfixes

- Stable fix for a NFSv4.1 delegation and state recovery deadlock
- Stable fix for a loop on irrecoverable errors when returning delegations
- Fix a 3-way deadlock between layoutreturn, open, and state recovery
- Update the MAINTAINERS file with contact information for Trond Myklebust
- Close needs to handle NFS4ERR_ADMIN_REVOKED
- Enabling v4.2 should not recompile nfsd and lockd
- Fix a couple of compile warnings

----------------------------------------------------------------
Andy Adamson (2):
      NFSv4 wait on recovery for async session errors
      SUNRPC: do not fail gss proc NULL calls with EACCES

Anna Schumaker (1):
      NFS: Enabling v4.2 should not recompile nfsd and lockd

Helge Deller (1):
      nfs: fix do_div() warning by instead using sector_div()

Trond Myklebust (5):
      NFS: Fix a warning in nfs_setsecurity
      NFSv4: Update list of irrecoverable errors on DELEGRETURN
      NFSv4: close needs to handle NFS4ERR_ADMIN_REVOKED
      NFSv4.1: Prevent a 3-way deadlock between layoutreturn, open and state recovery
      MAINTAINERS: Update contact information for Trond Myklebust

 MAINTAINERS                      |  4 ++--
 fs/nfs/blocklayout/blocklayout.h |  1 +
 fs/nfs/blocklayout/extents.c     |  2 +-
 fs/nfs/dns_resolve.c             |  2 ++
 fs/nfs/inode.c                   |  2 +-
 fs/nfs/internal.h                | 15 +++++++++++++++
 fs/nfs/nfs4_fs.h                 |  8 ++++++++
 fs/nfs/nfs4proc.c                | 30 +++++++++++++++++++++++-------
 include/linux/nfs4.h             | 10 ----------
 include/linux/nfs_fs.h           | 18 ------------------
 net/sunrpc/auth_gss/auth_gss.c   |  2 +-
 11 files changed, 54 insertions(+), 40 deletions(-)


[-- Attachment #2: This is a digitally signed message part --]
[-- Type: application/pgp-signature, Size: 836 bytes --]

^ permalink raw reply	[flat|nested] 82+ messages in thread

* [GIT PULL] Please pull NFS client bugfixes
@ 2013-11-16 21:09 Myklebust, Trond
  0 siblings, 0 replies; 82+ messages in thread
From: Myklebust, Trond @ 2013-11-16 21:09 UTC (permalink / raw)
  To: Linus Torvalds; +Cc: Linux NFS mailing list, linux-kernel

[-- Attachment #1: Type: text/plain, Size: 1851 bytes --]

Hi Linus

The following changes since commit fab99ebe39fe7d11fbd9b5fb84f07432af9ba36f:

  NFSv4.2: Remove redundant checks in nfs_setsecurity+nfs4_label_init_security (2013-11-04 16:42:52 -0500)

are available in the git repository at:

  git://git.linux-nfs.org/projects/trondmy/linux-nfs.git tags/nfs-for-3.13-2

for you to fetch changes up to 8c2fabc6542d9d0f8b16bd1045c2eda59bdcde13:

  nfs: fix pnfs Kconfig defaults (2013-11-15 13:41:43 -0500)

----------------------------------------------------------------
NFS client bugfixes:

- Stable fix for data corruption when retransmitting O_DIRECT writes
- Stable fix for a deep recursion/stack overflow bug in rpc_release_client
- Stable fix for infinite looping when mounting a NFSv4.x volume
- Fix a typo in the nfs mount option parser
- Allow pNFS layouts to be compiled into the kernel when NFSv4.1 is

----------------------------------------------------------------
Christoph Hellwig (1):
      nfs: fix pnfs Kconfig defaults

Jeff Layton (1):
      nfs: don't retry detect_trunking with RPC_AUTH_UNIX more than once

NeilBrown (1):
      NFS: correctly report misuse of "migration" mount option.

Trond Myklebust (2):
      SUNRPC: Fix a data corruption issue when retransmitting RPC calls
      SUNRPC: Avoid deep recursion in rpc_release_client

 fs/nfs/Kconfig        |  6 +++---
 fs/nfs/nfs4state.c    |  7 ++++++-
 fs/nfs/super.c        |  2 +-
 net/sunrpc/clnt.c     | 29 +++++++++++++++++------------
 net/sunrpc/xprtsock.c | 28 +++++++++++++++++++++-------
 5 files changed, 48 insertions(+), 24 deletions(-)

-- 
Trond Myklebust
Linux NFS client maintainer

NetApp
Trond.Myklebust@netapp.com
www.netapp.com

[-- Attachment #2: This is a digitally signed message part --]
[-- Type: application/pgp-signature, Size: 836 bytes --]

^ permalink raw reply	[flat|nested] 82+ messages in thread

* [GIT PULL] Please pull NFS client bugfixes
@ 2013-09-30 22:02 Myklebust, Trond
  0 siblings, 0 replies; 82+ messages in thread
From: Myklebust, Trond @ 2013-09-30 22:02 UTC (permalink / raw)
  To: Linus Torvalds; +Cc: Linux NFS mailing list, Linux Kernel mailing list

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #1: Type: text/plain; charset="utf-8", Size: 1930 bytes --]


Hi Linus,

The following changes since commit 4a10c2ac2f368583138b774ca41fac4207911983:

  Linux 3.12-rc2 (2013-09-23 15:41:09 -0700)

are available in the git repository at:

  git://git.linux-nfs.org/projects/trondmy/linux-nfs.git tags/nfs-for-3.12-4

for you to fetch changes up to 367156d9a87b21b5232dd93107c5fc61b09ba2ef:

  NFS: Give "flavor" an initial value to fix a compile warning (2013-09-29 16:03:34 -0400)

----------------------------------------------------------------
NFS client bugfixes for 3.12

- Stable fix for Oopses in the pNFS files layout driver
- Fix a regression when doing a non-exclusive file create on NFSv4.x
- NFSv4.1 security negotiation fixes when looking up the root filesystem
- Fix a memory ordering issue in the pNFS files layout driver

----------------------------------------------------------------
Anna Schumaker (1):
      NFS: Give "flavor" an initial value to fix a compile warning

Trond Myklebust (3):
      NFSv4: Honour the 'opened' parameter in the atomic_open() filesystem method
      NFSv4.1: nfs4_fl_prepare_ds - fix bugs when the connect attempt fails
      NFSv4.1: Ensure memory ordering between nfs4_ds_connect and nfs4_fl_prepare_ds

Weston Andros Adamson (1):
      NFSv4.1: try SECINFO_NO_NAME flavs until one works

 fs/nfs/dir.c               |  2 +-
 fs/nfs/nfs4file.c          |  3 ++-
 fs/nfs/nfs4filelayoutdev.c | 20 +++++++++-------
 fs/nfs/nfs4proc.c          | 58 +++++++++++++++++++++++++++++++++++++---------
 include/linux/nfs_xdr.h    |  3 ++-
 5 files changed, 63 insertions(+), 23 deletions(-)

-- 
Trond Myklebust
Linux NFS client maintainer

NetApp
Trond.Myklebust@netapp.com
www.netapp.com

-- 
Trond Myklebust
Linux NFS client maintainer

NetApp
Trond.Myklebust@netapp.com
www.netapp.com
ÿôèº{.nÇ+‰·Ÿ®‰­†+%ŠËÿ±éݶ\x17¥Šwÿº{.nÇ+‰·¥Š{±þG«éÿŠ{ayº\x1dʇڙë,j\a­¢f£¢·hšïêÿ‘êçz_è®\x03(­éšŽŠÝ¢j"ú\x1a¶^[m§ÿÿ¾\a«þG«éÿ¢¸?™¨è­Ú&£ø§~á¶iO•æ¬z·švØ^\x14\x04\x1a¶^[m§ÿÿÃ\fÿ¶ìÿ¢¸?–I¥

^ permalink raw reply	[flat|nested] 82+ messages in thread

* [GIT PULL] Please pull NFS client bugfixes
@ 2013-05-26 19:29 Myklebust, Trond
  0 siblings, 0 replies; 82+ messages in thread
From: Myklebust, Trond @ 2013-05-26 19:29 UTC (permalink / raw)
  To: Linus Torvalds; +Cc: Linux NFS mailing list, Linux Kernel mailing list

Hi Linus,

The following changes since commit f722406faae2d073cc1d01063d1123c35425939e:

  Linux 3.10-rc1 (2013-05-11 17:14:08 -0700)

are available in the git repository at:

  git://git.linux-nfs.org/projects/trondmy/linux-nfs.git tags/nfs-for-3.10-3

for you to fetch changes up to 83c168bf8017212a9d502536f9dcd0b54d24e330:

  NFS: Fix SETCLIENTID fallback if GSS is not available (2013-05-23 18:50:40 -0400)

----------------------------------------------------------------
NFS client bugfixes for 3.10

- Stable fix to prevent an rpc_task wakeup race
- Fix a NFSv4.1 session drain deadlock
- Fix a NFSv4/v4.1 mount regression when not running rpc.gssd
- Ensure auth_gss pipe detection works in namespaces
- Fix SETCLIENTID fallback if rpcsec_gss is not available

----------------------------------------------------------------
Andy Adamson (1):
      NFSv4.1 Fix a pNFS session draining deadlock

Chuck Lever (1):
      NFS: Fix SETCLIENTID fallback if GSS is not available

Trond Myklebust (4):
      SUNRPC: Fix a bug in gss_create_upcall
      SUNRPC: Faster detection if gssd is actually running
      SUNRPC: Convert auth_gss pipe detection to work in namespaces
      SUNRPC: Prevent an rpc_task wakeup race

 fs/nfs/callback_proc.c         |  2 +-
 fs/nfs/callback_xdr.c          |  2 +-
 fs/nfs/nfs4client.c            |  2 +-
 fs/nfs/nfs4proc.c              |  2 +-
 fs/nfs/nfs4session.c           |  4 +--
 fs/nfs/nfs4session.h           | 13 +++++----
 fs/nfs/nfs4state.c             | 15 +++++-----
 net/sunrpc/auth_gss/auth_gss.c | 62 ++++++++++++++++++++++++++++--------------
 net/sunrpc/netns.h             |  4 +++
 net/sunrpc/rpc_pipe.c          |  5 ++++
 net/sunrpc/sched.c             |  8 +++++-
 11 files changed, 78 insertions(+), 41 deletions(-)

-- 
Trond Myklebust
Linux NFS client maintainer

NetApp
Trond.Myklebust@netapp.com
www.netapp.com

^ permalink raw reply	[flat|nested] 82+ messages in thread

* [GIT PULL] Please pull NFS client bugfixes
@ 2013-03-26 18:26 Myklebust, Trond
  0 siblings, 0 replies; 82+ messages in thread
From: Myklebust, Trond @ 2013-03-26 18:26 UTC (permalink / raw)
  To: Linus Torvalds; +Cc: Linux NFS mailing list, linux-kernel

Hi Linus,

The following changes since commit 6dbe51c251a327e012439c4772097a13df43c5b8:

  Linux 3.9-rc1 (2013-03-03 15:11:05 -0800)

are available in the git repository at:

  git://git.linux-nfs.org/projects/trondmy/linux-nfs.git tags/nfs-for-3.9-3

for you to fetch changes up to 1166fde6a923c30f4351515b6a9a1efc513e7d00:

  SUNRPC: Add barriers to ensure read ordering in rpc_wake_up_task_queue_locked (2013-03-25 11:23:40 -0400)

----------------------------------------------------------------
NFS client bugfixes for Linux 3.9

- Fix an NFSv4 idmapper regression
- Fix an Oops in the pNFS blocks client
- Fix up various issues with pNFS layoutcommit
- Ensure correct read ordering of variables in rpc_wake_up_task_queue_locked

----------------------------------------------------------------
Trond Myklebust (5):
      NFSv4: Fix the string length returned by the idmapper
      NFSv4.1: Fix a race in pNFS layoutcommit
      NFSv4.1: Always clear the NFS_INO_LAYOUTCOMMIT in layoutreturn
      NFSv4.1: Add a helper pnfs_commit_and_return_layout
      SUNRPC: Add barriers to ensure read ordering in rpc_wake_up_task_queue_locked

fanchaoting (1):
      pnfs-block: removing DM device maybe cause oops when call dev_remove

 fs/nfs/blocklayout/blocklayoutdm.c |  4 +-
 fs/nfs/idmap.c                     | 13 +++---
 fs/nfs/nfs4filelayout.c            |  1 -
 fs/nfs/nfs4proc.c                  | 16 +-------
 fs/nfs/pnfs.c                      | 81 +++++++++++++++++++++++++++++++++-----
 fs/nfs/pnfs.h                      |  6 +++
 net/sunrpc/sched.c                 |  9 ++++-
 7 files changed, 96 insertions(+), 34 deletions(-)

-- 
Trond Myklebust
Linux NFS client maintainer

NetApp
Trond.Myklebust@netapp.com
www.netapp.com

^ permalink raw reply	[flat|nested] 82+ messages in thread

* [GIT PULL] Please pull NFS client bugfixes
@ 2013-03-03  0:08 Myklebust, Trond
  0 siblings, 0 replies; 82+ messages in thread
From: Myklebust, Trond @ 2013-03-03  0:08 UTC (permalink / raw)
  To: Linus Torvalds; +Cc: Linux NFS mailing list, linux-kernel

Hi Linus,

We've just concluded another Connectathon interoperability testing week,
and so here are the fixes for the bugs that were discovered.

Cheers,
  Trond

The following changes since commit 666b3d803a511fbc9bc5e5ea8ce66010cf03ea13:

  NLM: Ensure that we resend all pending blocking locks after a reclaim (2013-02-19 12:18:27 -0500)

are available in the git repository at:

  git://git.linux-nfs.org/projects/trondmy/linux-nfs.git tags/nfs-for-3.9-2

for you to fetch changes up to 512e4b291c0e97af24619a91f3e8963697da00d8:

  SUNRPC: One line comment fix (2013-03-02 15:54:11 -0800)

----------------------------------------------------------------
NFS client bugfixes for Linux 3.9

- Don't allow NFS silly-renamed files to be deleted
- Don't start the retransmission timer when out of socket space
- Fix a couple of pnfs-related Oopses.
- Fix one more NFSv4 state recovery deadlock
- Don't loop forever when LAYOUTGET returns NFS4ERR_LAYOUTTRYLATER

----------------------------------------------------------------
Benny Halevy (1):
      pnfs: fix resend_to_mds for directio

Jeff Layton (1):
      nfs: don't allow nfs_find_actor to match inodes of the wrong type

Trond Myklebust (4):
      NFS: Don't allow NFS silly-renamed files to be deleted, no signal
      SUNRPC: Don't start the retransmission timer when out of socket space
      NFSv4: Fix another open/open_recovery deadlock
      SUNRPC: One line comment fix

Weston Andros Adamson (4):
      NFSv4.1: Hold reference to layout hdr in layoutget
      PNFS: set the default DS timeout to 60 seconds
      SUNRPC: add call to get configured timeout
      NFSv4.1: LAYOUTGET EDELAY loops timeout to the MDS

 fs/nfs/inode.c              |  2 ++
 fs/nfs/nfs4filelayout.c     |  6 ++++--
 fs/nfs/nfs4filelayout.h     |  2 +-
 fs/nfs/nfs4proc.c           | 21 ++++++++++++++++++---
 fs/nfs/pnfs.c               | 21 +++++++++++++--------
 fs/nfs/pnfs.h               |  6 ++++--
 fs/nfs/unlink.c             | 20 +++++++++++++-------
 include/linux/nfs_xdr.h     |  1 +
 include/linux/sunrpc/clnt.h |  1 +
 net/sunrpc/clnt.c           | 15 +++++++++++++++
 net/sunrpc/xprt.c           |  6 +++++-
 11 files changed, 77 insertions(+), 24 deletions(-)

-- 
Trond Myklebust
Linux NFS client maintainer

NetApp
Trond.Myklebust@netapp.com
www.netapp.com

^ permalink raw reply	[flat|nested] 82+ messages in thread

* [GIT PULL] Please pull NFS client bugfixes
@ 2013-02-21  3:38 Myklebust, Trond
  0 siblings, 0 replies; 82+ messages in thread
From: Myklebust, Trond @ 2013-02-21  3:38 UTC (permalink / raw)
  To: Linus Torvalds; +Cc: Linux NFS mailing list, Linux Kernel mailing list

Hi Linus,

The following changes since commit 88b62b915b0b7e25870eb0604ed9a92ba4bfc9f7:

  Linux 3.8-rc6 (2013-02-01 12:08:14 +1100)

are available in the git repository at:

  git://git.linux-nfs.org/projects/trondmy/linux-nfs.git tags/nfs-for-3.9-1

for you to fetch changes up to 666b3d803a511fbc9bc5e5ea8ce66010cf03ea13:

  NLM: Ensure that we resend all pending blocking locks after a reclaim (2013-02-19 12:18:27 -0500)

----------------------------------------------------------------
NFS client bugfixes for Linux 3.9

- Fix an Oops in the pNFS layoutget code
- Fix a number of NFSv4 and v4.1 state recovery deadlocks and hangs
  due to the interaction of the session drain lock and state management
  locks.
- Remove task->tk_xprt, which was hiding a lot of RCU dereferencing bugs
- Fix a long standing NFSv3 posix lock recovery bug.
- Revert commit 324d003b0cd82151adbaecefef57b73f7959a469. It turned out
  that the root cause of the deadlock was due to interactions with the
  workqueues that have now been resolved.

----------------------------------------------------------------
Jeff Layton (1):
      sunrpc: silence build warning in gss_fill_context

Tim Gardner (1):
      nfs: remove kfree() redundant null checks

Trond Myklebust (18):
      SUNRPC: Eliminate task->tk_xprt accesses that bypass rcu_dereference()
      SUNRPC: Pass a pointer to struct rpc_xprt to the connect callback
      SUNRPC: Fix an RCU dereference in xs_local_rpcbind
      SUNRPC: Pass pointers to struct rpc_xprt to the congestion window
      SUNRPC: Fix an RCU dereference in xprt_reserve
      SUNRPC: Avoid RCU dereferences in the transport bind and connect code
      SUNRPC: Nuke the tk_xprt macro
      Revert "NFS: add nfs_sb_deactive_async to avoid deadlock"
      SUNRPC: Add missing static declaration to _gss_mech_get_by_name
      NFSv4: Allow the state manager to mark an open_owner as being recovered
      NFSv4.1: Prevent deadlocks between state recovery and file locking
      NFSv4.1: Don't lose locks when a server reboots during delegation return
      NFSv4: Fix up the return values of nfs4_open_delegation_recall
      NFSv4: Ensure delegation recall and byte range lock removal don't conflict
      NFSv4: Fix a reboot recovery race when opening a file
      NFSv4.1: Fix an ABBA locking issue with session and state serialisation
      NFSv4.1: Fix bulk recall and destroy of layouts
      NLM: Ensure that we resend all pending blocking locks after a reclaim

Weston Andros Adamson (1):
      NFSv4.1: Don't decode skipped layoutgets

fanchaoting (1):
      umount oops when remove blocklayoutdriver first

 fs/lockd/clntproc.c                   |   3 +
 fs/nfs/blocklayout/blocklayout.c      |   1 +
 fs/nfs/callback_proc.c                |  61 ++------------
 fs/nfs/delegation.c                   | 154 ++++++++++++++++++++++++----------
 fs/nfs/delegation.h                   |   1 +
 fs/nfs/getroot.c                      |   3 +-
 fs/nfs/inode.c                        |   5 +-
 fs/nfs/internal.h                     |   1 -
 fs/nfs/nfs4_fs.h                      |   4 +
 fs/nfs/nfs4proc.c                     | 133 ++++++++++++++++++++---------
 fs/nfs/nfs4state.c                    |  11 ++-
 fs/nfs/objlayout/objio_osd.c          |   1 +
 fs/nfs/pnfs.c                         | 150 ++++++++++++++++++++++++++++-----
 fs/nfs/pnfs.h                         |   7 +-
 fs/nfs/super.c                        |  49 -----------
 fs/nfs/unlink.c                       |   5 +-
 include/linux/sunrpc/sched.h          |   1 -
 include/linux/sunrpc/xprt.h           |   6 +-
 net/sunrpc/auth_gss/auth_gss.c        |   5 +-
 net/sunrpc/auth_gss/gss_mech_switch.c |   4 +-
 net/sunrpc/clnt.c                     |  16 ++--
 net/sunrpc/xprt.c                     |  21 +++--
 net/sunrpc/xprtrdma/rpc_rdma.c        |   4 +-
 net/sunrpc/xprtrdma/transport.c       |   7 +-
 net/sunrpc/xprtrdma/xprt_rdma.h       |   6 +-
 net/sunrpc/xprtsock.c                 |  16 ++--
 26 files changed, 415 insertions(+), 260 deletions(-)

-- 
Trond Myklebust
Linux NFS client maintainer

NetApp
Trond.Myklebust@netapp.com
www.netapp.com

^ permalink raw reply	[flat|nested] 82+ messages in thread

* [GIT PULL] Please pull NFS client bugfixes
@ 2013-01-07 15:45 Myklebust, Trond
  0 siblings, 0 replies; 82+ messages in thread
From: Myklebust, Trond @ 2013-01-07 15:45 UTC (permalink / raw)
  To: Linus Torvalds; +Cc: linux-kernel, Linux NFS mailing list

Hi Linus,

The following changes since commit d1c3ed669a2d452cacfb48c2d171a1f364dae2ed:

  Linux 3.8-rc2 (2013-01-02 18:13:21 -0800)

are available in the git repository at:

  git://git.linux-nfs.org/projects/trondmy/linux-nfs.git tags/nfs-for-3.8-2

for you to fetch changes up to ecf0eb9edbb607d74f74b73c14af8b43f3729528:

  nfs: avoid dereferencing null pointer in initiate_bulk_draining (2013-01-05 14:26:51 -0500)

----------------------------------------------------------------
NFS client bugfixes for Linux 3.8

- Fix a permissions problem when opening NFSv4 files that only have the
  exec bit set.
- Fix a couple of typos in pNFS (inverted logic), and the mount parsing
  (missing pointer dereference).
- Work around a series of deadlock issues due to workqueues using
  struct work_struct pointer address comparisons in the re-entrancy
  tests. Ensure that we don't free struct work_struct prematurely if
  our work function involves waiting for completion of other work
  items (e.g. by calling rpc_shutdown_client).
- Revert the part of commit 168e4b3 that is causing unnecessary warnings
  to be issued in the nfsd callback code.

----------------------------------------------------------------
Nickolai Zeldovich (1):
      nfs: avoid dereferencing null pointer in initiate_bulk_draining

Trond Myklebust (3):
      SUNRPC: Ensure that we free the rpc_task after cleanups are done
      NFS: Ensure that we free the rpc_task after read and write cleanups are done
      SUNRPC: Partial revert of commit 168e4b39d1afb79a7e3ea6c3bb246b4c82c6bdb9

Weston Andros Adamson (1):
      NFS: Fix access to suid/sgid executables

Xi Wang (1):
      nfs: fix null checking in nfs_get_option_str()

Yanchuan Nian (1):
      pnfs: Increase the refcount when LAYOUTGET fails the first time

 fs/nfs/callback_proc.c |  2 +-
 fs/nfs/dir.c           | 16 ++++++++++------
 fs/nfs/nfs4proc.c      | 18 +++++++++++-------
 fs/nfs/pnfs.c          |  2 +-
 fs/nfs/read.c          | 10 +++++++---
 fs/nfs/super.c         |  2 +-
 fs/nfs/write.c         | 10 +++++++---
 net/sunrpc/clnt.c      |  5 -----
 net/sunrpc/sched.c     | 27 +++++++++++++++++++++++----
 9 files changed, 61 insertions(+), 31 deletions(-)

-- 
Trond Myklebust
Linux NFS client maintainer

NetApp
Trond.Myklebust@netapp.com
www.netapp.com

^ permalink raw reply	[flat|nested] 82+ messages in thread

* [GIT PULL] Please pull NFS client bugfixes
@ 2012-11-03 19:48 Myklebust, Trond
  0 siblings, 0 replies; 82+ messages in thread
From: Myklebust, Trond @ 2012-11-03 19:48 UTC (permalink / raw)
  To: Linus Torvalds; +Cc: Linux NFS mailing list, Linux Kernel mailing list

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #1: Type: text/plain; charset="utf-8", Size: 2919 bytes --]

Hi Linus,

The following changes since commit 08f05c49749ee655bef921d12160960a273aad47:

  Return the right error value when dup[23]() newfd argument is too large (2012-10-30 21:27:28 -0700)

are available in the git repository at:

  git://git.linux-nfs.org/projects/trondmy/linux-nfs.git tags/nfs-for-3.7-4

for you to fetch changes up to 998f40b550f257e436485291802fa938e4cf580f:

  NFS4: nfs4_opendata_access should return errno (2012-11-02 18:51:54 -0400)

----------------------------------------------------------------
NFS bugfixes for Linux 3.7

- Fix a bunch of deadlock situations:
  * State recovery can deadlock if we fail to release sequence ids before
    scheduling the recovery thread.
  * Calling deactivate_super() from an RPC workqueue thread can deadlock
    because of the call to rpc_shutdown_client.
- Display the device name correctly in /proc/*/mounts
- Fix a number of incorrect error return values:
  * When NFSv3 mounts fail due to a timeout.
  * On NFSv4.1 backchannel setup failure
  * On NFSv4 open access checks
- pnfs_find_alloc_layout() must check the layout pointer for NULL
- Fix a regression in the legacy DNS resolved

----------------------------------------------------------------
Ben Hutchings (1):
      nfs: Show original device name verbatim in /proc/*/mount{s,info}

Bryan Schumaker (1):
      NFS: Wait for session recovery to finish before returning

NeilBrown (1):
      NFS: fix bug in legacy DNS resolver.

Scott Mayhew (1):
      nfsv3: Make v3 mounts fail with ETIMEDOUTs instead EIO on mountd timeouts

Trond Myklebust (3):
      NFSv4.1: We must release the sequence id when we fail to get a session slot
      NFSv4: nfs4_locku_done must release the sequence id
      NFSv4: Initialise the NFSv4.1 slot table highest_used_slotid correctly

Weston Andros Adamson (3):
      NFS: add nfs_sb_deactive_async to avoid deadlock
      SUNRPC: return proper errno from backchannel_rqst
      NFS4: nfs4_opendata_access should return errno

Yanchuan Nian (1):
      nfs: Check whether a layout pointer is NULL before free it

 fs/nfs/dns_resolve.c          |  5 +++--
 fs/nfs/inode.c                |  5 ++++-
 fs/nfs/internal.h             |  6 +++--
 fs/nfs/mount_clnt.c           |  2 +-
 fs/nfs/namespace.c            | 19 +++++++++++-----
 fs/nfs/nfs4namespace.c        |  3 ++-
 fs/nfs/nfs4proc.c             | 46 +++++++++++++++++++++++---------------
 fs/nfs/pnfs.c                 |  4 ++--
 fs/nfs/super.c                | 51 ++++++++++++++++++++++++++++++++++++++++++-
 fs/nfs/unlink.c               |  2 +-
 net/sunrpc/backchannel_rqst.c |  2 +-
 11 files changed, 110 insertions(+), 35 deletions(-)

-- 
Trond Myklebust
Linux NFS client maintainer

NetApp
Trond.Myklebust@netapp.com
www.netapp.com
ÿôèº{.nÇ+‰·Ÿ®‰­†+%ŠËÿ±éݶ\x17¥Šwÿº{.nÇ+‰·¥Š{±þG«éÿŠ{ayº\x1dʇڙë,j\a­¢f£¢·hšïêÿ‘êçz_è®\x03(­éšŽŠÝ¢j"ú\x1a¶^[m§ÿÿ¾\a«þG«éÿ¢¸?™¨è­Ú&£ø§~á¶iO•æ¬z·švØ^\x14\x04\x1a¶^[m§ÿÿÃ\fÿ¶ìÿ¢¸?–I¥

^ permalink raw reply	[flat|nested] 82+ messages in thread

* [GIT PULL] Please pull NFS client bugfixes...
@ 2012-10-22 17:42 Myklebust, Trond
  0 siblings, 0 replies; 82+ messages in thread
From: Myklebust, Trond @ 2012-10-22 17:42 UTC (permalink / raw)
  To: Linus Torvalds; +Cc: Linux NFS mailing list, Linux Kernel mailing list

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #1: Type: text/plain; charset="utf-8", Size: 1803 bytes --]

Hi Linus,

The following changes since commit ddffeb8c4d0331609ef2581d84de4d763607bd37:

  Linux 3.7-rc1 (2012-10-14 14:41:04 -0700)

are available in the git repository at:

  git://git.linux-nfs.org/projects/trondmy/linux-nfs.git tags/nfs-for-3.7-2

for you to fetch changes up to e9b7e91745fa9df94900c8ab08e633f336686098:

  NFSv4: Fix the return value for nfs_callback_start_svc (2012-10-16 13:14:42 -0400)

----------------------------------------------------------------
NFS client bugfixes for Linux 3.7

- Do not call pnfs_return_layout() from an rpciod context
- nfs4_ds_disconnect can cause Oopses. Kill it...
- Fix the return value for nfs_callback_start_svc
- Fix a number of compile warnings

----------------------------------------------------------------
Trond Myklebust (6):
      NFSv4.1: Kill nfs4_ds_disconnect()
      NFSv4.1: Do not call pnfs_return_layout() from an rpciod context
      NFSv4.1: Use kcalloc() to allocate zeroed arrays instead of kzalloc()
      NFSv4: fs/nfs/nfs4getroot.c needs to include "internal.h"
      NFSv4.1: Declare osd_pri_2_pnfs_err(), objio_init_read/write to be static
      NFSv4: Fix the return value for nfs_callback_start_svc

 fs/nfs/callback.c            |  2 +-
 fs/nfs/nfs4filelayout.c      | 21 ++++++++++++++++-----
 fs/nfs/nfs4filelayout.h      |  1 -
 fs/nfs/nfs4filelayoutdev.c   | 22 ----------------------
 fs/nfs/nfs4getroot.c         |  1 +
 fs/nfs/objlayout/objio_osd.c |  6 +++---
 fs/nfs/pnfs.h                |  1 +
 7 files changed, 22 insertions(+), 32 deletions(-)

-- 
Trond Myklebust
Linux NFS client maintainer

NetApp
Trond.Myklebust@netapp.com
www.netapp.com
ÿôèº{.nÇ+‰·Ÿ®‰­†+%ŠËÿ±éݶ\x17¥Šwÿº{.nÇ+‰·¥Š{±þG«éÿŠ{ayº\x1dʇڙë,j\a­¢f£¢·hšïêÿ‘êçz_è®\x03(­éšŽŠÝ¢j"ú\x1a¶^[m§ÿÿ¾\a«þG«éÿ¢¸?™¨è­Ú&£ø§~á¶iO•æ¬z·švØ^\x14\x04\x1a¶^[m§ÿÿÃ\fÿ¶ìÿ¢¸?–I¥

^ permalink raw reply	[flat|nested] 82+ messages in thread

* [GIT PULL] Please pull NFS client bugfixes
@ 2012-09-12 19:19 Myklebust, Trond
  0 siblings, 0 replies; 82+ messages in thread
From: Myklebust, Trond @ 2012-09-12 19:19 UTC (permalink / raw)
  To: Linus Torvalds; +Cc: Linux Kernel mailing list, Linux NFS mailing list

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #1: Type: text/plain; charset="utf-8", Size: 2477 bytes --]

Hi Linus,

The following changes since commit 086600430493e04b802bee6e5b3ce0458e4eb77f:

  NFSv3: Ensure that do_proc_get_root() reports errors correctly (2012-08-20 12:52:42 -0400)

are available in the git repository at:

  git://git.linux-nfs.org/projects/trondmy/linux-nfs.git tags/nfs-for-3.6-4

for you to fetch changes up to 7b281ee026552f10862b617a2a51acf49c829554:

  NFS: fsync() must exit with an error if page writeback failed (2012-09-11 15:38:32 -0400)

----------------------------------------------------------------
NFS client bugfixes for Linux 3.6

- Final (hopefully) fix for the range checking code in NFSv4 getacl. This
  should fix the Oopses being seen when the acl size is close to PAGE_SIZE.
- Fix a regression with the legacy binary mount code
- Fix a regression in the readdir cookieverf initialisation
- Fix an RPC over UDP regression
- Ensure that we report all errors in the NFSv4 open code
- Ensure that fsync() reports all relevant synchronisation errors.

----------------------------------------------------------------
Trond Myklebust (6):
      NFS: Fix the initialisation of the readdir 'cookieverf' array
      NFS: Fix a problem with the legacy binary mount code
      NFSv4: Fix range checking in __nfs4_get_acl_uncached and __nfs4_proc_set_acl
      NFSv4: Fix buffer overflow checking in __nfs4_get_acl_uncached
      SUNRPC: Fix a UDP transport regression
      NFS: fsync() must exit with an error if page writeback failed

Weston Andros Adamson (1):
      NFS: return error from decode_getfh in decode open

 fs/nfs/file.c                   |  4 ++-
 fs/nfs/inode.c                  |  2 +-
 fs/nfs/nfs3proc.c               |  2 +-
 fs/nfs/nfs4file.c               |  4 ++-
 fs/nfs/nfs4proc.c               | 55 +++++++++++++++++++----------------------
 fs/nfs/nfs4xdr.c                | 17 ++++++-------
 fs/nfs/super.c                  |  2 ++
 include/linux/nfs_fs.h          |  5 ----
 include/linux/nfs_xdr.h         |  2 +-
 include/linux/sunrpc/xprt.h     |  3 +++
 net/sunrpc/xprt.c               | 34 ++++++++++++++-----------
 net/sunrpc/xprtrdma/transport.c |  1 +
 net/sunrpc/xprtsock.c           |  3 +++
 13 files changed, 70 insertions(+), 64 deletions(-)

-- 
Trond Myklebust
Linux NFS client maintainer

NetApp
Trond.Myklebust@netapp.com
www.netapp.com
ÿôèº{.nÇ+‰·Ÿ®‰­†+%ŠËÿ±éݶ\x17¥Šwÿº{.nÇ+‰·¥Š{±þG«éÿŠ{ayº\x1dʇڙë,j\a­¢f£¢·hšïêÿ‘êçz_è®\x03(­éšŽŠÝ¢j"ú\x1a¶^[m§ÿÿ¾\a«þG«éÿ¢¸?™¨è­Ú&£ø§~á¶iO•æ¬z·švØ^\x14\x04\x1a¶^[m§ÿÿÃ\fÿ¶ìÿ¢¸?–I¥

^ permalink raw reply	[flat|nested] 82+ messages in thread

* [GIT PULL] Please pull NFS client bugfixes
@ 2012-07-13 15:14 Myklebust, Trond
  0 siblings, 0 replies; 82+ messages in thread
From: Myklebust, Trond @ 2012-07-13 15:14 UTC (permalink / raw)
  To: Linus Torvalds; +Cc: Linux NFS mailing list, Linux Kernel mailing list

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #1: Type: text/plain; charset="utf-8", Size: 1128 bytes --]

The following changes since commit 6b16351acbd415e66ba16bf7d473ece1574cf0bc:

  Linux 3.5-rc4 (2012-06-24 12:53:04 -0700)

are available in the git repository at:

  git://git.linux-nfs.org/projects/trondmy/linux-nfs.git tags/nfs-for-3.5-4

for you to fetch changes up to f1daf666dd7d097653bd38320248c68084b1febf:

  NFSv4: Fix an NFSv4 mount regression (2012-07-10 13:25:39 -0400)

----------------------------------------------------------------
NFS client bugfixes for Linux 3.5

- Fix an NFSv4 mount regression
- Fix O_DIRECT list manipulation snafus

----------------------------------------------------------------
Trond Myklebust (2):
      NFS: Fix list manipulation snafus in fs/nfs/direct.c
      NFSv4: Fix an NFSv4 mount regression

 fs/nfs/direct.c |    6 +++++-
 fs/nfs/super.c  |    2 ++
 2 files changed, 7 insertions(+), 1 deletion(-)

Cheers
  Trond

-- 
Trond Myklebust
Linux NFS client maintainer

NetApp
Trond.Myklebust@netapp.com
www.netapp.com

ÿôèº{.nÇ+‰·Ÿ®‰­†+%ŠËÿ±éݶ\x17¥Šwÿº{.nÇ+‰·¥Š{±þG«éÿŠ{ayº\x1dʇڙë,j\a­¢f£¢·hšïêÿ‘êçz_è®\x03(­éšŽŠÝ¢j"ú\x1a¶^[m§ÿÿ¾\a«þG«éÿ¢¸?™¨è­Ú&£ø§~á¶iO•æ¬z·švØ^\x14\x04\x1a¶^[m§ÿÿÃ\fÿ¶ìÿ¢¸?–I¥

^ permalink raw reply	[flat|nested] 82+ messages in thread

* [GIT PULL] Please pull NFS client bugfixes
@ 2012-05-02  3:57 Myklebust, Trond
  0 siblings, 0 replies; 82+ messages in thread
From: Myklebust, Trond @ 2012-05-02  3:57 UTC (permalink / raw)
  To: Linus Torvalds; +Cc: Linux NFS mailing list, Linux Kernel mailing list

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #1: Type: text/plain; charset="utf-8", Size: 11498 bytes --]

Hi Linus,

Please pull from the signed tag "nfs-for-3.4-4" in the repository at

   git pull git://git.linux-nfs.org/projects/trondmy/linux-nfs.git tags/nfs-for-3.4-4

This will update the following files through the appended changesets.

  Cheers,
    Trond

----
 fs/nfs/blocklayout/blocklayout.c |    4 +-
 fs/nfs/client.c                  |    5 +-
 fs/nfs/idmap.c                   |    4 +
 fs/nfs/internal.h                |    8 +-
 fs/nfs/namespace.c               |   93 +++++++------------------
 fs/nfs/nfs4_fs.h                 |   10 ++-
 fs/nfs/nfs4filelayoutdev.c       |    2 +-
 fs/nfs/nfs4namespace.c           |   86 +++++++++++++++++++++--
 fs/nfs/nfs4proc.c                |  142 +++++++++++++++++++++++++++----------
 fs/nfs/nfs4xdr.c                 |   44 ++++++++----
 fs/nfs/objlayout/objlayout.c     |    2 -
 fs/nfs/pnfs.c                    |    2 +-
 fs/nfs/super.c                   |    4 +-
 net/sunrpc/clnt.c                |   50 ++++++++++---
 net/sunrpc/rpc_pipe.c            |    3 +-
 15 files changed, 308 insertions(+), 151 deletions(-)

commit 3617e5031b3acec04efaa36566a8111ac8f07325
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date:   Mon Apr 30 12:04:58 2012 -0400

    NFSv4.1: Use the correct hostname in the client identifier string
    
    We need to use the hostname of the process that created the nfs_client.
    That hostname is now stored in the rpc_client->cl_nodename.
    
    Also remove the utsname()->domainname component. There is no reason
    to include the NIS/YP domainname in a client identifier string.
    
    Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>

commit cbbb34498f8b2b26cbdc79532c8a2ee5cd1e756a
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date:   Mon Apr 30 11:52:40 2012 -0400

    SUNRPC: RPC client must use the current utsname hostname string
    
    Now that the rpc client is namespace aware, it needs to use the
    utsname of the process that created it instead of using the
    init_utsname. Both rpc_new_client and rpc_clone_client need to
    be fixed.
    
    Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
    Cc: Stanislav Kinsbursky <skinsbursky@parallels.com>

commit 71dfc5fa5160bb73752f0731539404569a77faca
Author: Stanislav Kinsbursky <skinsbursky@parallels.com>
Date:   Sat Apr 28 19:32:21 2012 +0400

    NFS: get module in idmap PipeFS notifier callback
    
    This is bug fix.
    Notifier callback is called from SUNRPC module. So before dereferencing NFS
    module we have to make sure, that it's alive.
    
    Signed-off-by: Stanislav Kinsbursky <skinsbursky@parallels.com>
    Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>

commit e245d4250d0326cfcf7c816a2081b6ab2ea810be
Author: Bryan Schumaker <bjschuma@netapp.com>
Date:   Fri Apr 27 13:27:43 2012 -0400

    NFS: Remove unused function nfs_lookup_with_sec()
    
    This fixes a compiler warning.
    
    Signed-off-by: Bryan Schumaker <bjschuma@netapp.com>
    Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>

commit 7e6eb683d260d9325f0d1bd911518d5ed3cb4f0c
Author: Bryan Schumaker <bjschuma@netapp.com>
Date:   Fri Apr 27 13:27:42 2012 -0400

    NFS: Honor the authflavor set in the clone mount data
    
    The authflavor is set in an nfs_clone_mount structure and passed to the
    xdev_mount() functions where it was promptly ignored.  Instead, use it
    to initialize an rpc_clnt for the cloned server.
    
    Signed-off-by: Bryan Schumaker <bjschuma@netapp.com>
    Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>

commit f05d147f7e3cf0d86b3a4bd5603029a7cb109633
Author: Bryan Schumaker <bjschuma@netapp.com>
Date:   Fri Apr 27 13:27:41 2012 -0400

    NFS: Fix following referral mount points with different security
    
    I create a new proc_lookup_mountpoint() to use when submounting an NFS
    v4 share.  This function returns an rpc_clnt to use for performing an
    fs_locations() call on a referral's mountpoint.
    
    Signed-off-by: Bryan Schumaker <bjschuma@netapp.com>
    Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>

commit 72de53ec4bca39c26709122a8f78bfefe7b6bca4
Author: Bryan Schumaker <bjschuma@netapp.com>
Date:   Fri Apr 27 13:27:40 2012 -0400

    NFS: Do secinfo as part of lookup
    
    Whenever lookup sees wrongsec do a secinfo and retry the lookup to find
    attributes of the file or directory, such as "is this a referral
    mountpoint?".  This also allows me to remove handling -NFS4ERR_WRONSEC
    as part of getattr xdr decoding.
    
    Signed-off-by: Bryan Schumaker <bjschuma@netapp.com>
    Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>

commit db0a9593d52f935c80085d8993bdcead1ad30b0c
Author: Bryan Schumaker <bjschuma@netapp.com>
Date:   Fri Apr 27 13:27:39 2012 -0400

    NFS: Handle exceptions coming out of nfs4_proc_fs_locations()
    
    We don't want to return -NFS4ERR_WRONGSEC to the VFS because it could
    cause the kernel to oops.
    
    Signed-off-by: Bryan Schumaker <bjschuma@netapp.com>
    Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>

commit 31e4dda4747713de13889f7c79c7aec341fea61b
Author: Bryan Schumaker <bjschuma@netapp.com>
Date:   Fri Apr 27 13:27:38 2012 -0400

    NFS: Fix SECINFO_NO_NAME
    
    I was using the same decoder function for SECINFO and SECINFO_NO_NAME,
    so it was returning an error when it tried to decode an OP_SECINFO_NO_NAME
    header as OP_SECINFO.
    
    Signed-off-by: Bryan Schumaker <bjschuma@netapp.com>
    Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>

commit ea8cfa06795bb30d2ea61f503ef129284492c06a
Author: Stanislav Kinsbursky <skinsbursky@parallels.com>
Date:   Fri Apr 27 13:00:17 2012 +0400

    SUNRPC: traverse clients tree on PipeFS event
    
    v2: recursion was replaced by loop
    
    If client is a clone, then it's parent can not be in the list.
    But parent's Pipefs dentries have to be created and destroyed.
    
    Note: event skip helper for clients introduced
    
    Signed-off-by: Stanislav Kinsbursky <skinsbursky@parallels.com>
    Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>

commit 37629b572cc4e80fc24b4139a24df1a89415d534
Author: Stanislav Kinsbursky <skinsbursky@parallels.com>
Date:   Fri Apr 20 18:19:56 2012 +0400

    SUNRPC: set per-net PipeFS superblock before notification
    
    There can be a case, when on MOUNT event RPC client (after it's dentries were
    created) is not longer hold by anyone except notification callback.
    I.e. on release this client will be destoroyed. And it's dentries have to be
    destroyed as well. Which in turn requires per-net PipeFS superblock to be set.
    
    Signed-off-by: Stanislav Kinsbursky <skinsbursky@parallels.com>
    Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>

commit 7aab449e5a2ebfa9c5116e87e16536bc4195e4de
Author: Stanislav Kinsbursky <skinsbursky@parallels.com>
Date:   Fri Apr 20 18:19:18 2012 +0400

    SUNRPC: skip clients with program without PipeFS entries
    
    1) This is sane.
    2) Otherwise there will be soft lockup:
    
    do {
    	rpc_get_client_for_event (clnt->cl_dentry == NULL ==> choose)
    	__rpc_pipefs_event (clnt->cl_program->pipe_dir_name == NULL ==> return)
    } while (1)
    
    Signed-off-by: Stanislav Kinsbursky <skinsbursky@parallels.com>
    Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>

commit a4dff1bc492ee4a2184d384ae8b5bcab5859e150
Author: Stanislav Kinsbursky <skinsbursky@parallels.com>
Date:   Fri Apr 20 18:11:02 2012 +0400

    SUNRPC: skip dead but not buried clients on PipeFS events
    
    These clients can't be safely dereferenced if their counter in 0.
    
    Signed-off-by: Stanislav Kinsbursky <skinsbursky@parallels.com>
    Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>

commit 5794d21ef4639f0e33440927bb903f9598c21e92
Author: Sachin Prabhu <sprabhu@redhat.com>
Date:   Tue Apr 17 14:36:40 2012 +0100

    Avoid beyond bounds copy while caching ACL
    
    When attempting to cache ACLs returned from the server, if the bitmap
    size + the ACL size is greater than a PAGE_SIZE but the ACL size itself
    is smaller than a PAGE_SIZE, we can read past the buffer page boundary.
    
    Signed-off-by: Sachin Prabhu <sprabhu@redhat.com>
    Reported-by: Jian Li <jiali@redhat.com>
    Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>

commit 5a00689930ab975fdd1b37b034475017e460cf2a
Author: Sachin Prabhu <sprabhu@redhat.com>
Date:   Tue Apr 17 14:35:39 2012 +0100

    Avoid reading past buffer when calling GETACL
    
    Bug noticed in commit
    bf118a342f10dafe44b14451a1392c3254629a1f
    
    When calling GETACL, if the size of the bitmap array, the length
    attribute and the acl returned by the server is greater than the
    allocated buffer(args.acl_len), we can Oops with a General Protection
    fault at _copy_from_pages() when we attempt to read past the pages
    allocated.
    
    This patch allocates an extra PAGE for the bitmap and checks to see that
    the bitmap + attribute_length + ACLs don't exceed the buffer space
    allocated to it.
    
    Signed-off-by: Sachin Prabhu <sprabhu@redhat.com>
    Reported-by: Jian Li <jiali@redhat.com>
    [Trond: Fixed a size_t vs unsigned int printk() warning]
    Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>

commit 10bd295a0b6488ebe634b72a11d8986bd3af3819
Author: Jim Rees <rees@umich.edu>
Date:   Mon Apr 9 22:33:39 2012 -0400

    fix page number calculation bug for block layout decode buffer
    
    Signed-off-by: Jim Rees <rees@umich.edu>
    Suggested-by: Andy Adamson <andros@netapp.com>
    Suggested-by: Fred Isaman <iisaman@netapp.com>
    Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>

commit e5265a0c587423bbd21a6b39a572cecff16b9346
Author: Andy Adamson <andros@netapp.com>
Date:   Sat Apr 14 03:56:35 2012 -0400

    NFSv4.1 fix page number calculation bug for filelayout decode buffers
    
    Signed-off-by: Andy Adamson <andros@netapp.com>
    Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>

commit 9526b2b6d6b9f183b66cf21c4afa6e79d5a14f44
Author: Sachin Bhamare <sbhamare@panasas.com>
Date:   Fri Mar 30 14:29:59 2012 -0700

    pnfs-obj: Remove unused variable from objlayout_get_deviceinfo()
    
    Local variable 'sb' was not being used in objlayout_get_deviceinfo().
    
    Signed-off-by: Sachin Bhamare <sbhamare@panasas.com>
    Signed-off-by: Boaz Harrosh <bharrosh@panasas.com>
    Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>

commit 1aba1567637b93eee32253b42deaaad381c3175b
Author: Weston Andros Adamson <dros@netapp.com>
Date:   Tue Apr 24 16:50:37 2012 -0400

    nfs4: fix referrals on mounts that use IPv6 addrs
    
    All referrals (IPv4 addr, IPv6 addr, and DNS) are broken on mounts of
    IPv6 addresses, because validation code uses a path that is parsed
    from the dev_name ("<server>:<path>") by splitting on the first colon and
    colons are used in IPv6 addrs.
    This patch ignores colons within IPv6 addresses that are escaped by '[' and ']'.
    
    Signed-off-by: Weston Andros Adamson <dros@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

ÿôèº{.nÇ+‰·Ÿ®‰­†+%ŠËÿ±éݶ\x17¥Šwÿº{.nÇ+‰·¥Š{±þG«éÿŠ{ayº\x1dʇڙë,j\a­¢f£¢·hšïêÿ‘êçz_è®\x03(­éšŽŠÝ¢j"ú\x1a¶^[m§ÿÿ¾\a«þG«éÿ¢¸?™¨è­Ú&£ø§~á¶iO•æ¬z·švØ^\x14\x04\x1a¶^[m§ÿÿÃ\fÿ¶ìÿ¢¸?–I¥

^ permalink raw reply	[flat|nested] 82+ messages in thread

* [GIT PULL] please pull NFS client bugfixes
@ 2012-04-24 20:18 Myklebust, Trond
  0 siblings, 0 replies; 82+ messages in thread
From: Myklebust, Trond @ 2012-04-24 20:18 UTC (permalink / raw)
  To: Linus Torvalds; +Cc: Linux NFS mailing list, Linux Kernel mailing list

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #1: Type: text/plain; charset="utf-8", Size: 6247 bytes --]

Hi Linus,

Please pull from the signed tag "nfs-for-3.4-3" in the repository at

   git pull git://git.linux-nfs.org/projects/trondmy/linux-nfs.git tags/nfs-for-3.4-3

This will update the following files through the appended changesets.

  Cheers,
    Trond

----
 fs/nfs/dir.c             |    4 ++--
 fs/nfs/nfs4_fs.h         |    1 +
 fs/nfs/nfs4proc.c        |   44 ++++++++++++++++++++++++++++++++++++--------
 fs/nfs/nfs4state.c       |   31 +++++++++++++++++++------------
 fs/nfs/nfs4xdr.c         |    9 +++++----
 fs/nfs/read.c            |    2 +-
 fs/nfs/super.c           |    8 ++++++--
 fs/nfs/write.c           |    5 +++--
 include/linux/nfs_xdr.h  |    7 ++++++-
 net/sunrpc/sunrpc_syms.c |   17 +++++++++--------
 10 files changed, 88 insertions(+), 40 deletions(-)

commit 7bf97bc27308cfdc7a8dadd40ae50f7c4cb09b01
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date:   Sat Apr 21 12:36:19 2012 -0400

    NFSv4: Keep dropped state owners on the LRU list for a while
    
    To ensure that we don't reuse their identifiers.
    
    Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>

commit c77365c963cf8703ecf1004cd3b298068a3e1b76
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date:   Sat Apr 21 12:31:05 2012 -0400

    NFSv4: Ensure that we don't drop a state owner more than once
    
    Retest the RB_EMPTY_NODE() condition under the spin lock
    to ensure that we don't call rb_erase() more than once on the
    same state owner.
    
    Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>

commit 95b72eb0bdef6476b7e73061f0382adf46c5495a
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date:   Fri Apr 20 19:24:51 2012 -0400

    NFSv4: Ensure we do not reuse open owner names
    
    The NFSv4 spec is ambiguous about whether or not it is permissible
    to reuse open owner names, so play it safe. This patch adds a timestamp
    to the state_owner structure, and combines that with the IDA based
    uniquifier.
    Fixes a regression whereby the Linux server returns NFS4ERR_BAD_SEQID.
    
    Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>

commit 98a2139f4f4d7b5fcc3a54c7fddbe88612abed20
Author: Jan Kara <jack@suse.cz>
Date:   Sat Sep 3 01:09:43 2011 +0200

    nfs: Enclose hostname in brackets when needed in nfs_do_root_mount
    
    When hostname contains colon (e.g. when it is an IPv6 address) it needs
    to be enclosed in brackets to make parsing of NFS device string possible.
    Fix nfs_do_root_mount() to enclose hostname properly when needed. NFS code
    actually does not need this as it does not parse the string passed by
    nfs_do_root_mount() but the device string is exposed to userspace in
    /proc/mounts.
    
    CC: Josh Boyer <jwboyer@redhat.com>
    CC: Trond Myklebust <Trond.Myklebust@netapp.com>
    Signed-off-by: Jan Kara <jack@suse.cz>
    Cc: stable@vger.kernel.org
    Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>

commit 8ccd271f7a3a846ce6f85ead0760d9d12994a611
Author: Fred Isaman <iisaman@netapp.com>
Date:   Fri Apr 20 14:47:35 2012 -0400

    NFS: put open context on error in nfs_flush_multi
    
    Cc: <stable@vger.kernel.org>
    Signed-off-by: Fred Isaman <iisaman@netapp.com>
    Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>

commit 73fb7bc7c57d971b11f2e00536ac2d3e316e0609
Author: Fred Isaman <iisaman@netapp.com>
Date:   Fri Apr 20 14:47:34 2012 -0400

    NFS: put open context on error in nfs_pagein_multi
    
    Cc: <stable@vger.kernel.org>
    Signed-off-by: Fred Isaman <iisaman@netapp.com>
    Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>

commit 451146be933e26e21277852b5e40c6a52266ef96
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date:   Wed Apr 18 16:29:11 2012 -0400

    NFSv4: Fix open(O_TRUNC) and ftruncate() error handling
    
    If the file wasn't opened for writing, then truncate and ftruncate
    need to report the appropriate errors.
    
    Reported-by: Miklos Szeredi <miklos@szeredi.hu>
    Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
    Cc: stable@vger.kernel.org

commit 55725513b5ef9d462aa3e18527658a0362aaae83
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date:   Wed Apr 18 12:48:35 2012 -0400

    NFSv4: Ensure that we check lock exclusive/shared type against open modes
    
    Since we may be simulating flock() locks using NFS byte range locks,
    we can't rely on the VFS having checked the file open mode for us.
    
    Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
    Cc: stable@vger.kernel.org

commit 05ffe24f5290dc095f98fbaf84afe51ef404ccc5
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date:   Wed Apr 18 12:20:10 2012 -0400

    NFSv4: Ensure that the LOCK code sets exception->inode
    
    All callers of nfs4_handle_exception() that need to handle
    NFS4ERR_OPENMODE correctly should set exception->inode
    
    Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
    Cc: stable@vger.kernel.org

commit ca138f368a36dba40d3ef4a53d64af2011cda3c7
Author: Fred Isaman <iisaman@netapp.com>
Date:   Thu Apr 5 15:26:36 2012 -0400

    NFS: check for req==NULL in nfs_try_to_update_request cleanup
    
    Signed-off-by: Fred Isaman <iisaman@netapp.com>
    Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>

commit adae0fe0ea87e8fb1a72dde304937c60759b495f
Author: Stanislav Kinsbursky <skinsbursky@parallels.com>
Date:   Thu Apr 5 21:04:37 2012 +0400

    SUNRPC: register PipeFS file system after pernet sybsystem
    
    PipeFS superblock creation routine relays on SUNRPC pernet data presense, which
    is created on register_pernet_subsys() call in SUNRPC module init function.
    Registering of PipeFS filesystem prior to registering of per-net subsystem
    leads to races (mount of PipeFS can dereference uninitialized data).
    
    Signed-off-by: Stanislav Kinsbursky <skinsbursky@parallels.com>
    Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>


-- 
Trond Myklebust
Linux NFS client maintainer

NetApp
Trond.Myklebust@netapp.com
www.netapp.com

ÿôèº{.nÇ+‰·Ÿ®‰­†+%ŠËÿ±éݶ\x17¥Šwÿº{.nÇ+‰·¥Š{±þG«éÿŠ{ayº\x1dʇڙë,j\a­¢f£¢·hšïêÿ‘êçz_è®\x03(­éšŽŠÝ¢j"ú\x1a¶^[m§ÿÿ¾\a«þG«éÿ¢¸?™¨è­Ú&£ø§~á¶iO•æ¬z·švØ^\x14\x04\x1a¶^[m§ÿÿÃ\fÿ¶ìÿ¢¸?–I¥

^ permalink raw reply	[flat|nested] 82+ messages in thread

* [GIT PULL] Please pull NFS client bugfixes
@ 2011-12-20  6:15 Trond Myklebust
  0 siblings, 0 replies; 82+ messages in thread
From: Trond Myklebust @ 2011-12-20  6:15 UTC (permalink / raw)
  To: Linus Torvalds; +Cc: linux-nfs, linux-kernel

Hi Linus,

Please pull from the "bugfixes" branch of the repository at

   git pull git://git.linux-nfs.org/projects/trondmy/linux-nfs.git bugfixes

This will update the following files through the appended changesets.

  Cheers,
    Trond

----
 fs/nfs/file.c      |    2 +-
 fs/nfs/nfs4proc.c  |   24 ++++++++++++++++--------
 fs/nfs/nfs4state.c |   33 +++++++++++++++++++++------------
 net/sunrpc/sched.c |   30 +++++++++++++++++++++++-------
 net/sunrpc/xprt.c  |   10 ++++------
 5 files changed, 65 insertions(+), 34 deletions(-)

commit 6c52961743f38747401b47127b82159ab6d8a7a4
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date:   Thu Dec 15 18:38:10 2011 -0500

    NFS: Fix a regression in nfs_file_llseek()
    
    After commit 06222e491e663dac939f04b125c9dc52126a75c4 (fs: handle
    SEEK_HOLE/SEEK_DATA properly in all fs's that define their own llseek)
    the behaviour of llseek() was changed so that it always revalidates
    the file size. The bug appears to be due to a logic error in the
    afore-mentioned commit, which always evaluates to 'true'.
    
    Reported-by: Roel Kluin <roel.kluin@gmail.com>
    Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
    Cc: stable@vger.kernel.org [>=3.1]

commit 652f89f64fabcdae9143ee2b4253cfa838fb0279
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date:   Fri Dec 9 19:05:58 2011 -0500

    NFSv4: Do not accept delegated opens when a delegation recall is in effect
    
    ...and report the servers that try to return a delegation when the client
    is using the CLAIM_DELEG_CUR open mode. That behaviour is explicitly
    forbidden in RFC3530.
    
    Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>

commit 4b44b40e04a758e2242ff4a3f7c15982801ec8bc
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date:   Fri Dec 9 16:31:52 2011 -0500

    NFSv4: Ensure correct locking when accessing the 'lock_states' list
    
    There are currently 2 places in the state recovery code, where we do not
    take sufficient precautions before accessing the state->lock_states. In
    both cases, we should be holding the state->state_lock.
    
    Reported-by: Pascal Bouchareine <pascal@gandi.net>
    Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>

commit 111d489f0fb431f4ae85d96851fbf8d3248c09d8
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date:   Thu Dec 1 16:37:42 2011 -0500

    NFSv4.1: Ensure that we handle _all_ SEQUENCE status bits.
    
    Currently, the code assumes that the SEQUENCE status bits are mutually
    exclusive. They are not...
    
    Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
    Cc: stable@vger.kernel.org [>= 2.6.34]

commit 4f38e4aadcca319650c0de31edf7193d7c384de2
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date:   Thu Dec 1 16:31:34 2011 -0500

    NFSv4: Don't error if we handled it in nfs4_recovery_handle_error
    
    If we handled an error condition, then nfs4_recovery_handle_error should
    return '0' so that the state recovery thread can continue.
    Also ensure that nfs4_check_lease() continues to abort if we haven't got
    any credentials by having it return ENOKEY (which is not handled).
    
    Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>

commit c25573b5134294c0be82bfaecc6d08136835b271
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date:   Thu Dec 1 14:16:17 2011 -0500

    SUNRPC: Ensure we always bump the backlog queue in xprt_free_slot
    
    Whenever we free a slot, we know that the resulting xprt->num_reqs will
    be less than xprt->max_reqs, so we know that we can release at least one
    backlogged rpc_task.
    
    Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
    Cc: stable@vger.kernel.org [>=3.1]

commit 7fdcf13b292e8b2e38e42de24be2503e37b2cf97
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date:   Thu Dec 1 14:00:15 2011 -0500

    SUNRPC: Fix the execution time statistics in the face of RPC restarts
    
    If the rpc_task gets restarted, then we want to ensure that we don't
    double-count the execution time statistics, timeout data, etc.
    
    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] 82+ messages in thread

* [GIT PULL] Please pull NFS client bugfixes
@ 2011-11-22 11:50 Trond Myklebust
  0 siblings, 0 replies; 82+ messages in thread
From: Trond Myklebust @ 2011-11-22 11:50 UTC (permalink / raw)
  To: Linus Torvalds; +Cc: linux-nfs, linux-kernel

Hi Linus,

Please pull from the "bugfixes" branch of the repository at

   git pull git://git.linux-nfs.org/projects/trondmy/linux-nfs.git bugfixes

This will update the following files through the appended changesets.

  Cheers,
    Trond

----
 fs/nfs/dir.c            |    2 +-
 fs/nfs/file.c           |   91 ++++++++++++++++++++++++++--------------------
 fs/nfs/inode.c          |    2 +-
 fs/nfs/internal.h       |    2 +
 fs/nfs/nfs3proc.c       |    1 +
 fs/nfs/nfs4proc.c       |    4 +-
 fs/nfs/pnfs.c           |   26 +++++++++++---
 fs/nfs/proc.c           |    1 +
 fs/nfs/read.c           |   14 +------
 include/linux/nfs_fs.h  |    3 ++
 include/linux/nfs_xdr.h |    1 +
 net/sunrpc/xprtsock.c   |    4 ++-
 12 files changed, 89 insertions(+), 62 deletions(-)

commit 62e4a76987eab2b7fa952546614bc83e5bfc9d3e
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date:   Thu Nov 10 14:30:37 2011 -0500

    NFS: Revert pnfs ugliness from the generic NFS read code path
    
    pNFS-specific code belongs in the pnfs layer. It should not be
    hijacking generic NFS read or write code paths.
    
    Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>

commit 2aa13531bbbc6582874bedfcd853e1058b0fb4f9
Author: Stanislav Kinsbursky <skinsbursky@parallels.com>
Date:   Thu Nov 10 14:33:23 2011 +0300

    SUNRPC: destroy freshly allocated transport in case of sockaddr init error
    
    Otherwise we will leak xprt structure and struct net reference.
    
    Signed-off-by: Stanislav Kinsbursky <skinsbursky@parallels.com>
    Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>

commit a6f498a891c730327645a7afa10c5ae977de6fd8
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date:   Mon Nov 7 15:50:32 2011 -0500

    NFS: Fix a regression in the referral code
    
    Fix a regression that was introduced by commit
    0c2e53f11a6dae9e3af5f50f5ad0382e7c3e0cfa (NFS: Remove the unused
    "lookupfh()" version of nfs4_proc_lookup()).
    
    In the case where the lookup gets an NFS4ERR_MOVED, we want to return
    the result of nfs4_get_referral(). Instead, that value is getting
    clobbered by the call to nfs4_handle_exception()...
    
    Reported-by: Tigran Mkrtchyan <tigran.mkrtchyan@desy.de>
    Tested-by: Tigran Mkrtchyan <tigran.mkrtchyan@desy.de>
    Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>

commit 0486958f57a496212e3c1e3d9194deebba3dc3d4
Author: Jeff Layton <jlayton@redhat.com>
Date:   Fri Nov 4 13:31:22 2011 -0400

    nfs: move nfs_file_operations declaration to bottom of file.c (try #2)
    
    ...a remove a set of forward declarations.
    
    Signed-off-by: Jeff Layton <jlayton@redhat.com>
    Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>

commit 1788ea6e3b2a58cf4fb00206e362d9caff8d86a7
Author: Jeff Layton <jlayton@redhat.com>
Date:   Fri Nov 4 13:31:21 2011 -0400

    nfs: when attempting to open a directory, fall back on normal lookup (try #5)
    
    commit d953126 changed how nfs_atomic_lookup handles an -EISDIR return
    from an OPEN call. Prior to that patch, that caused the client to fall
    back to doing a normal lookup. When that patch went in, the code began
    returning that error to userspace. The d_revalidate codepath however
    never had the corresponding change, so it was still possible to end up
    with a NULL ctx->state pointer after that.
    
    That patch caused a regression. When we attempt to open a directory that
    does not have a cached dentry, that open now errors out with EISDIR. If
    you attempt the same open with a cached dentry, it will succeed.
    
    Fix this by reverting the change in nfs_atomic_lookup and allowing
    attempts to open directories to fall back to a normal lookup
    
    Also, add a NFSv4-specific f_ops->open routine that just returns
    -ENOTDIR. This should never be called if things are working properly,
    but if it ever is, then the dprintk may help in debugging.
    
    To facilitate this, a new file_operations field is also added to the
    nfs_rpc_ops struct.
    
    Cc: stable@kernel.org
    Signed-off-by: Jeff Layton <jlayton@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] 82+ messages in thread

* [GIT PULL] Please pull NFS client bugfixes
@ 2011-08-19  1:05 Trond Myklebust
  0 siblings, 0 replies; 82+ messages in thread
From: Trond Myklebust @ 2011-08-19  1:05 UTC (permalink / raw)
  To: Linus Torvalds

Hi Linus,

Please pull from the "bugfixes" branch of the repository at

   git pull git://git.linux-nfs.org/projects/trondmy/linux-nfs.git bugfixes

This will update the following files through the appended changesets.

  Cheers,
    Trond

----
 fs/nfs/blocklayout/blocklayout.c    |    1 +
 fs/nfs/callback.h                   |    2 +-
 fs/nfs/callback_proc.c              |   25 +++++++++++++++++++------
 fs/nfs/callback_xdr.c               |   24 +++++++-----------------
 fs/nfs/objlayout/objio_osd.c        |   28 ++++++++++++----------------
 fs/nfs/objlayout/pnfs_osd_xdr_cli.c |    3 +++
 6 files changed, 43 insertions(+), 40 deletions(-)

commit 910ac68a2b80c7de95bc8488734067b1bb15d583
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date:   Tue Aug 2 14:46:52 2011 -0400

    NFSv4.1: Return NFS4ERR_BADSESSION to callbacks during session resets
    
    If the client is in the process of resetting the session when it receives
    a callback, then returning NFS4ERR_DELAY may cause a deadlock with the
    DESTROY_SESSION call.
    
    Basically, if the client returns NFS4ERR_DELAY in response to the
    CB_SEQUENCE call, then the server is entitled to believe that the
    client is busy because it is already processing that call. In that
    case, the server is perfectly entitled to respond with a
    NFS4ERR_BACK_CHAN_BUSY to any DESTROY_SESSION call.
    
    Fix this by having the client reply with a NFS4ERR_BADSESSION in
    response to the callback if it is resetting the session.
    
    Cc: stable@kernel.org [2.6.38+]
    Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>

commit 55a673990ec04cf63005318bcf08c2b0046e5778
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date:   Tue Aug 2 14:46:29 2011 -0400

    NFSv4.1: Fix the callback 'highest_used_slotid' behaviour
    
    Currently, there is no guarantee that we will call nfs4_cb_take_slot() even
    though nfs4_callback_compound() will consistently call
    nfs4_cb_free_slot() provided the cb_process_state has set the 'clp' field.
    The result is that we can trigger the BUG_ON() upon the next call to
    nfs4_cb_take_slot().
    
    This patch fixes the above problem by using the slot id that was taken in
    the CB_SEQUENCE operation as a flag for whether or not we need to call
    nfs4_cb_free_slot().
    It also fixes an atomicity problem: we need to set tbl->highest_used_slotid
    atomically with the check for NFS4_SESSION_DRAINING, otherwise we end up
    racing with the various tests in nfs4_begin_drain_session().
    
    Cc: stable@kernel.org [2.6.38+]
    Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>

commit 9af7db3228acc286c50e3a0f054ec982efdbc6c6
Author: Boaz Harrosh <bharrosh@panasas.com>
Date:   Wed Aug 3 21:52:51 2011 -0700

    pnfs-obj: Fix the comp_index != 0 case
    
    There were bugs in the case of partial layout where olo_comp_index
    is not zero. This used to work and was tested but one of the later
    cleanup SQUASHMEs broke it and was not tested since.
    
    Also add a dprint that specify those received layout parameters.
    Everything else was already printed.
    
    [Needed in v3.0]
    CC: Stable Tree <stable@kernel.org>
    Signed-off-by: Boaz Harrosh <bharrosh@panasas.com>
    Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>

commit 20618b21da0796115e81906d24ff1601552701b7
Author: Boaz Harrosh <bharrosh@panasas.com>
Date:   Wed Aug 3 21:54:33 2011 -0700

    pnfs-obj: Bug when we are running out of bio
    
    When we have a situation that the number of pages we want
    to encode is bigger then the size of the bio. (Which can
    currently happen only when all IO is going to a single device
    .e.g group_width==1) then the IO is submitted short and we
    report back only the amount of bytes we actually wrote/read
    and all is fine. BUT ...
    
    There was a bug that the current length counter was advanced
    before the fail to add the extra page, and we come to a situation
    that the CDB length was one-page longer then the actual bio size,
    which is of course rejected by the osd-target.
    
    While here also fix the bio size calculation, in the case
    that we received more then one group of devices.
    
    CC: Stable Tree <stable@kernel.org>
    Signed-off-by: Boaz Harrosh <bharrosh@panasas.com>
    Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>

commit 88c9e42196285a7c573e2abda11a4b5037c669bc
Author: Heiko Carstens <heiko.carstens@de.ibm.com>
Date:   Tue Aug 2 09:57:35 2011 +0200

    nfs: add missing prefetch.h include
    
    Fix this compile error on s390:
    
      CC [M]  fs/nfs/blocklayout/blocklayout.o
    fs/nfs/blocklayout/blocklayout.c: In function 'bl_end_io_read':
    fs/nfs/blocklayout/blocklayout.c:201:4: error: implicit declaration of function 'prefetchw'
    
    Introduced with 9549ec01 "pnfsblock: bl_read_pagelist".
    
    Cc: Fred Isaman <iisaman@citi.umich.edu>
    Signed-off-by: Heiko Carstens <heiko.carstens@de.ibm.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] 82+ messages in thread

* [GIT PULL] Please pull NFS client bugfixes
@ 2011-07-12 23:30 Trond Myklebust
  0 siblings, 0 replies; 82+ messages in thread
From: Trond Myklebust @ 2011-07-12 23:30 UTC (permalink / raw)
  To: Linus Torvalds

Hi Linus,

Please pull from the "bugfixes" branch of the repository at

   git pull git://git.linux-nfs.org/projects/trondmy/nfs-2.6.git bugfixes

This will update the following files through the appended changesets.

Kudos to Ben Greear for finding a 4 year old bug in the rpcbind client code!

  Cheers,
    Trond

----
 fs/nfs/nfs4filelayout.c |    1 -
 fs/nfs/nfs4xdr.c        |    2 +-
 fs/nfs/write.c          |    2 ++
 net/sunrpc/rpcb_clnt.c  |    2 +-
 net/sunrpc/sched.c      |   27 +++++++++++----------------
 5 files changed, 15 insertions(+), 19 deletions(-)

commit ec0dd267bf7d08cb30e321e45a75fd40edd7e528
Author: Ben Greear <greearb@candelatech.com>
Date:   Tue Jul 12 10:27:55 2011 -0700

    SUNRPC: Fix use of static variable in rpcb_getport_async
    
    Because struct rpcbind_args *map was declared static, if two
    threads entered this method at the same time, the values
    assigned to map could be sent two two differen tasks.
    This could cause all sorts of problems, include use-after-free
    and double-free of memory.
    
    Fix this by removing the static declaration so that the map
    pointer is on the stack.
    
    Signed-off-by: Ben Greear <greearb@candelatech.com>
    Cc: stable@kernel.org
    Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>

commit e5012d1f3861d18c7f3814e757c1c3ab3741dbcd
Author: Andy Adamson <andros@netapp.com>
Date:   Mon Jul 11 17:17:42 2011 -0400

    NFSv4.1: update nfs4_fattr_bitmap_maxsz
    
    Attribute IDs assigned in RFC 5661 now require three bitmaps.
    Fixes hitting a BUG_ON in xdr_shrink_bufhead when getting ACLs.
    
    Signed-off-by: Andy Adamson <andros@netapp.com>
    Cc:stable@kernel.org [2.6.39]
    Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>

commit b55c59892e1f3b6c7d4b9ccffb4263e1486fb990
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date:   Wed Jul 6 19:58:23 2011 -0400

    SUNRPC: Fix a race between work-queue and rpc_killall_tasks
    
    Since rpc_killall_tasks may modify the rpc_task's tk_action field
    without any locking, we need to be careful when dereferencing it.
    
    Reported-by: Ben Greear <greearb@candelatech.com>
    Tested-by: Ben Greear <greearb@candelatech.com>
    Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
    Cc: stable@kernel.org

commit 2bea038c52e88badbbd5b420c1de918f7f2579e9
Author: Boaz Harrosh <bharrosh@panasas.com>
Date:   Thu Jun 16 11:35:46 2011 -0400

    pnfs: write: Set mds_offset in the generic layer - it is needed by all LDs
    
    In current pnfs tree, all the layouts set mds_offset in their
    .write_pagelist member.
    mds_offset is only used by generic layer and should be handled by it.
    
    This patch is for upstream. It is needed in this -rc series to fix a
    bug in objects layout_commit.
    
    I'll send patches for objects and blocks to be
    squashed into current pnfs tree.
    
    TODO: It looks like the read path needs the same patch.
    
    Signed-off-by: Boaz Harrosh <bharrosh@panasas.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] 82+ messages in thread

* [GIT PULL] Please pull NFS client bugfixes
@ 2011-05-13 20:23 Trond Myklebust
  0 siblings, 0 replies; 82+ messages in thread
From: Trond Myklebust @ 2011-05-13 20:23 UTC (permalink / raw)
  To: Linus Torvalds

Hi Linus,

Please pull from the "bugfixes" branch of the repository at

   git pull git://git.linux-nfs.org/projects/trondmy/nfs-2.6.git bugfixes

This will update the following files through the appended changesets.

  Cheers,
    Trond

----
 fs/nfs/nfs4filelayout.c    |   27 ++++++++++++++++-----------
 fs/nfs/nfs4filelayout.h    |    2 +-
 fs/nfs/nfs4filelayoutdev.c |   34 +++++++++++++++++-----------------
 fs/nfs/nfs4proc.c          |    6 ++++++
 fs/nfs/pnfs.c              |   34 ++++++++++++++++++++--------------
 fs/nfs/pnfs.h              |    6 +++---
 fs/nfs/read.c              |    4 ++--
 fs/nfs/write.c             |    4 ++--
 include/linux/nfs_xdr.h    |    1 +
 9 files changed, 68 insertions(+), 50 deletions(-)

commit a75b9df9d3bfc3cd1083974c045ae31ce5f3434f
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date:   Wed May 11 18:00:51 2011 -0400

    NFSv4.1: Ensure that layoutget uses the correct gfp modes
    
    Currently, writebacks may end up recursing back into the filesystem due to
    GFP_KERNEL direct reclaims in the pnfs subsystem.
    
    Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>

commit 2887fe45522843149ccf72e01f43813be4fb36c5
Author: Andy Adamson <andros@netapp.com>
Date:   Wed May 11 01:19:58 2011 -0400

    NFSv4.1: remove pnfs_layout_hdr from pnfs_destroy_all_layouts tmp_list
    
    Prevents an infinite loop as list was never emptied.
    
    Signed-off-by: Andy Adamson <andros@netapp.com>
    Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>

commit a8a4ae3a899a6c0b4771cc57884800d8b76a6996
Author: Andy Adamson <andros@netapp.com>
Date:   Tue May 3 13:43:03 2011 -0400

    NFSv41: Resend on NFS4ERR_RETRY_UNCACHED_REP
    
    Free the slot and resend the RPC with new session <slot#,seq#>.
    
    For nfs4_async_handle_error, return -EAGAIN and set the task->tk_status to 0
    to restart the async rpc in the rpc_restart_call_prepare state which resets
    the slot.
    
    For nfs4_handle_exception, retrying a call that uses nfs4_call_sync will
    reset the slot via nfs41_call_sync_prepare.
    
    For open/close/lock/locku/delegreturn/layoutcommit/unlink/rename/write
    cachethis is true, so these operations will not trigger an
    NFS4ERR_RETRY_UNCACHED_REP.
    
    Signed-off-by: Andy Adamson <andros@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] 82+ messages in thread

* [GIT PULL] please pull NFS client bugfixes
@ 2011-04-08 18:40 Trond Myklebust
  0 siblings, 0 replies; 82+ messages in thread
From: Trond Myklebust @ 2011-04-08 18:40 UTC (permalink / raw)
  To: Linus Torvalds

Hi Linus,

Please pull from the "bugfixes" branch of the repository at

   git pull git://git.linux-nfs.org/projects/trondmy/nfs-2.6.git bugfixes

This will update the following files through the appended changesets.

  Cheers,
    Trond

----
 fs/nfs/namespace.c                  |   58 +++++++++++++++--------------------
 fs/nfs/nfs4proc.c                   |    4 +--
 net/sunrpc/auth_gss/gss_krb5_mech.c |    2 +-
 3 files changed, 27 insertions(+), 37 deletions(-)

commit 37adb89fadd65ce47f7e5cfd564938a76b351948
Author: Bryan Schumaker <bjschuma@netapp.com>
Date:   Thu Apr 7 16:02:20 2011 -0400

    NFS: Change initial mount authflavor only when server returns NFS4ERR_WRONGSEC
    
    When attempting an initial mount, we should only attempt other
    authflavors if AUTH_UNIX receives a NFS4ERR_WRONGSEC error.
    This allows other errors to be passed back to userspace programs.
    
    Signed-off-by: Bryan Schumaker <bjschuma@netapp.com>
    Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>

commit 418875900e3de4831c84f86ae4756690dac5be77
Author: Bryan Schumaker <bjschuma@netapp.com>
Date:   Wed Apr 6 14:33:28 2011 -0400

    NFS: Fix a signed vs. unsigned secinfo bug
    
    rpc_authflavor_t is cast from an unsigned int, but the
    initial code tried to use it as a signed int.  I fix
    this by passing an rpc_authflavor_t pointer around, and
    returning signed integers from functions.
    
    Signed-off-by: Bryan Schumaker <bjschuma@netapp.com>
    Reported-by: Dan Carpenter <error27@gmail.com>
    Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>

commit 0867659fa3c245bf203d837a82e0f6ea5079c2c5
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date:   Wed Apr 6 10:13:32 2011 -0700

    Revert "net/sunrpc: Use static const char arrays"
    
    This reverts commit 411b5e05617593efebc06241dbc56f42150f2abe.
    
    Olga Kornievskaia reports:
    
    Problem: linux client mounting linux server using rc4-hmac-md5
    enctype. gssd fails with create a context after receiving a reply from
    the server.
    
    Diagnose: putting printout statements in the server kernel and
    kerberos libraries revealed that client and server derived different
    integrity keys.
    
    Server kernel code was at fault due the the commit
    
    [aglo@skydive linux-pnfs]$ git show 411b5e05617593efebc06241dbc56f42150f2abe
    
    Trond: The problem is that since it relies on virt_to_page(), you cannot
    call sg_set_buf() for data in the const section.
    
    Reported-by: Olga Kornievskaia <aglo@citi.umich.edu>
    Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
    Cc: stable@kernel.org	[2.6.36+]


-- 
Trond Myklebust
Linux NFS client maintainer

NetApp
Trond.Myklebust@netapp.com
www.netapp.com


^ permalink raw reply	[flat|nested] 82+ messages in thread

* [GIT PULL] Please pull NFS client bugfixes
@ 2011-03-14 18:09 Trond Myklebust
  0 siblings, 0 replies; 82+ messages in thread
From: Trond Myklebust @ 2011-03-14 18:09 UTC (permalink / raw)
  To: Linus Torvalds

Hi Linus,

Please pull from the "bugfixes" branch of the repository at

   git pull git://git.linux-nfs.org/projects/trondmy/nfs-2.6.git bugfixes

This will update the following files through the appended changesets.

  Cheers,
    Trond

----
 fs/nfs/inode.c                           |    7 ++-
 fs/nfs/nfs4_fs.h                         |   10 ++-
 fs/nfs/nfs4filelayoutdev.c               |    4 +
 fs/nfs/nfs4proc.c                        |   91 +++++++++++++++++-------------
 fs/nfs/nfs4state.c                       |   29 +++++++---
 fs/nfs/nfs4xdr.c                         |    4 +-
 fs/nfs/nfsroot.c                         |   29 +++++-----
 fs/nfs/unlink.c                          |    2 +-
 fs/nfs/write.c                           |    2 +
 include/linux/nfs_fs_sb.h                |   10 +--
 include/linux/sunrpc/sched.h             |    1 +
 kernel/sched.c                           |    1 +
 net/sunrpc/sched.c                       |   75 ++++++++++++++++++++-----
 net/sunrpc/xprtrdma/svc_rdma_transport.c |    1 +
 net/sunrpc/xprtsock.c                    |    3 +-
 15 files changed, 178 insertions(+), 91 deletions(-)

commit 53d4737580535e073963b91ce87d4216e434fab5
Author: Chuck Lever <chuck.lever@oracle.com>
Date:   Fri Mar 11 15:31:06 2011 -0500

    NFS: NFSROOT should default to "proto=udp"
    
    There have been a number of recent reports that NFSROOT is no longer
    working with default mount options, but fails only with certain NICs.
    
    Brian Downing <bdowning@lavos.net> bisected to commit 56463e50 "NFS:
    Use super.c for NFSROOT mount option parsing".  Among other things,
    this commit changes the default mount options for NFSROOT to use TCP
    instead of UDP as the underlying transport.
    
    TCP seems less able to deal with NICs that are slow to initialize.
    The system logs that have accompanied reports of problems all show
    that NFSROOT attempts to establish a TCP connection before the NIC is
    fully initialized, and thus the TCP connection attempt fails.
    
    When a TCP connection attempt fails during a mount operation, the
    NFS stack needs to fail the operation.  Usually user space knows how
    and when to retry it.  The network layer does not report a distinct
    error code for this particular failure mode.  Thus, there isn't a
    clean way for the RPC client to see that it needs to retry in this
    case, but not in others.
    
    Because NFSROOT is used in some environments where it is not possible
    to update the kernel command line to specify "udp", the proper thing
    to do is change NFSROOT to use UDP by default, as it did before commit
    56463e50.
    
    To make it easier to see how to change default mount options for
    NFSROOT and to distinguish default settings from mandatory settings,
    I've adjusted a couple of areas to document the specifics.
    
    root_nfs_cat() is also modified to deal with commas properly when
    concatenating strings containing mount option lists.  This keeps
    root_nfs_cat() call sites simpler, now that we may be concatenating
    multiple mount option strings.
    
    Tested-by: Brian Downing <bdowning@lavos.net>
    Tested-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
    Signed-off-by: Chuck Lever <chuck.lever@oracle.com>
    Cc: <stable@kernel.org> # 2.6.37
    Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>

commit 57df216bd8c8813a79a6a618e3d2ec937d532b86
Author: Huang Weiyi <weiyi.huang@gmail.com>
Date:   Tue Mar 8 23:11:30 2011 +0000

    nfs4: remove duplicated #include
    
    Remove duplicated #include('s) in
      fs/nfs/nfs4proc.c
    
    Signed-off-by: Huang Weiyi <weiyi.huang@gmail.com>
    Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>

commit f9feab1e180d1392f2f59d692826c6da2e57adf4
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date:   Wed Mar 9 16:12:46 2011 -0500

    NFSv4: nfs4_state_mark_reclaim_nograce() should be static
    
    There are no more external users of nfs4_state_mark_reclaim_nograce() or
    nfs4_state_mark_reclaim_reboot(), so mark them as static.
    
    Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>

commit ecac799a5ecc364006f0db6f2db15e77ed4d63e2
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date:   Wed Mar 9 16:00:56 2011 -0500

    NFSv4: Fix the setlk error handler
    
    Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>

commit b4410c2f7f775b03da31566c05bb8d2383c7dc27
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date:   Wed Mar 9 16:00:55 2011 -0500

    NFSv4.1: Fix the handling of the SEQUENCE status bits
    
    We want SEQUENCE status bits to be handled by the state manager in order
    to avoid threading issues.
    
    Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>

commit 0400a6b0cb756f976bae32ae8db47bfa9853897c
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date:   Wed Mar 9 16:00:53 2011 -0500

    NFSv4/4.1: Fix nfs4_schedule_state_recovery abuses
    
    nfs4_schedule_state_recovery() should only be used when we need to force
    the state manager to check the lease. If we just want to start the
    state manager in order to handle a state recovery situation, we should be
    using nfs4_schedule_state_manager().
    
    This patch fixes the abuses of nfs4_schedule_state_recovery() by replacing
    its use with a set of helper functions that do the right thing.
    
    Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>

commit c34c32ea97718bb24fc06158733580003ba89211
Author: Andy Adamson <andros@netapp.com>
Date:   Wed Mar 9 13:13:46 2011 -0500

    NFSv4.1 reclaim complete must wait for completion
    
    Signed-off-by: Andy Adamson <andros@netapp.com>
    [Trond: fix whitespace errors]
    Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>

commit 114f64b5f24abac33a42f4f1856eb3a9766d497e
Author: Andy Adamson <andros@netapp.com>
Date:   Wed Mar 9 13:13:45 2011 -0500

    NFSv4: remove duplicate clientid in struct nfs_client
    
    Signed-off-by: Andy Adamson <andros@netapp.com>
    Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>

commit 7d6d63d6427090cbb1d282364b65b12634ca59bd
Author: Ricardo Labiaga <Ricardo.Labiaga@netapp.com>
Date:   Wed Mar 9 13:13:44 2011 -0500

    NFSv4.1: Retry CREATE_SESSION on NFS4ERR_DELAY
    
    Fix bug where we currently retry the EXCHANGEID call again, eventhough
    we already have a valid clientid.  Instead, delay and retry the CREATE_SESSION
    call.
    
    Signed-off-by: Ricardo Labiaga <Ricardo.Labiaga@netapp.com>
    Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>

commit 4cea288aaf0e11647880cc487350b1dc45d9febc
Author: Ben Hutchings <bhutchings@solarflare.com>
Date:   Tue Feb 22 21:54:34 2011 +0000

    sunrpc: Propagate errors from xs_bind() through xs_create_sock()
    
    xs_create_sock() is supposed to return a pointer or an ERR_PTR-encoded
    error, but it currently returns 0 if xs_bind() fails.
    
    Signed-off-by: Ben Hutchings <bhutchings@solarflare.com>
    Cc: stable@kernel.org [v2.6.37]
    Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>

commit 3fa0b4e201d254b52a251fa348bd53e53000cff6
Author: Frank Filz <ffilzlnx@us.ibm.com>
Date:   Thu Dec 2 19:31:23 2010 +0000

    (try3-resend) Fix nfs_compat_user_ino64 so it doesn't cause problems if bit 31 or 63 are set in fileid
    
    The problem was use of an int32, which when converted to a uint64
    is sign extended resulting in a fileid that doesn't fit in 32 bits
    even though the intent of the function is to fit the fileid into
    32 bits.
    
    Signed-off-by: Frank Filz <ffilzlnx@us.ibm.com>
    Reviewed-by: Jeff Layton <jlayton@redhat.com>
    [Trond: Added an include for compat.h]
    Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>

commit 43b7c3f051dea504afccc39bcb56d8e26c2e0b77
Author: Jovi Zhang <bookjovi@gmail.com>
Date:   Wed Mar 2 23:19:37 2011 +0000

    nfs: fix compilation warning
    
    this commit fix compilation warning as following:
    linux-2.6/fs/nfs/nfs4proc.c:3265: warning: comparison of distinct pointer types lacks a cast
    
    Signed-off-by: Jovi Zhang <bookjovi@gmail.com>
    Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>

commit b9f810570d9cc13177128e11a74e22d37aa68a1a
Author: Stanislav Fomichev <kernel@fomichev.me>
Date:   Sat Feb 5 23:13:01 2011 +0000

    nfs: add kmalloc return value check in decode_and_add_ds
    
    add kmalloc return value check in decode_and_add_ds
    
    Signed-off-by: Stanislav Fomichev <kernel@fomichev.me>
    Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>

commit a5e502681007779d4762fb3ef7e80a3ecd1cfe6b
Author: Jesper Juhl <jj@chaosbits.net>
Date:   Sat Jan 22 21:40:20 2011 +0000

    SUNRPC: Remove resource leak in svc_rdma_send_error()
    
    We leak the memory allocated to 'ctxt' when we return after
    'ib_dma_mapping_error()' returns !=0.
    
    Signed-off-by: Jesper Juhl <jj@chaosbits.net>
    Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>

commit d2224e7afbf2a6556f4f8f25bc0e96d99ec4d2bd
Author: Jeff Layton <jlayton@redhat.com>
Date:   Sun Mar 6 17:14:13 2011 +0000

    nfs: close NFSv4 COMMIT vs. CLOSE race
    
    I've been adding in more artificial delays in the NFSv4 commit and close
    codepaths to uncover races. The kernel I'm testing has the patch to
    close the race in __rpc_wait_for_completion_task that's in Trond's
    cthon2011 branch. The reproducer I've been using does this in a loop:
    
    	mkdir("DIR");
    	fd = open("DIR/FILE", O_WRONLY|O_CREAT|O_EXCL, 0644);
    	write(fd, "abcdefg", 7);
    	close(fd);
    	unlink("DIR/FILE");
    	rmdir("DIR");
    
    The above reproducer shouldn't result in any silly-renaming. However,
    when I add a "msleep(100)" just after the nfs_commit_clear_lock call in
    nfs_commit_release, I can almost always force one to occur. If I can
    force it to occur with that, then it can happen without that delay
    given the right timing.
    
    nfs_commit_inode waits for the NFS_INO_COMMIT bit to clear when called
    with FLUSH_SYNC set. nfs_commit_rpcsetup on the other hand does not wait
    for the task to complete before putting its reference to it, so the last
    reference get put in rpc_release task and gets queued to a workqueue.
    
    In this situation, the last open context reference may be put by the
    COMMIT release instead of the close() syscall. The close() syscall
    returns too quickly and the unlink runs while the d_count is still
    high since the COMMIT release hasn't put its dentry reference yet.
    
    Fix this by having rpc_commit_rpcsetup wait for the RPC call to complete
    before putting the task reference when FLUSH_SYNC is set. With this, the
    last reference is put by the process that's initiating the FLUSH_SYNC
    commit and the race is closed.
    
    Signed-off-by: Jeff Layton <jlayton@redhat.com>
    Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>

commit bf294b41cefcb22fc3139e0f42c5b3f06728bd5e
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date:   Mon Feb 21 11:05:41 2011 -0800

    SUNRPC: Close a race in __rpc_wait_for_completion_task()
    
    Although they run as rpciod background tasks, under normal operation
    (i.e. no SIGKILL), functions like nfs_sillyrename(), nfs4_proc_unlck()
    and nfs4_do_close() want to be fully synchronous. This means that when we
    exit, we want all references to the rpc_task to be gone, and we want
    any dentry references etc. held by that task to be released.
    
    For this reason these functions call __rpc_wait_for_completion_task(),
    followed by rpc_put_task() in the expectation that the latter will be
    releasing the last reference to the rpc_task, and thus ensuring that the
    callback_ops->rpc_release() has been called synchronously.
    
    This patch fixes a race which exists due to the fact that
    rpciod calls rpc_complete_task() (in order to wake up the callers of
    __rpc_wait_for_completion_task()) and then subsequently calls
    rpc_put_task() without ensuring that these two steps are done atomically.
    
    In order to avoid adding new spin locks, the patch uses the existing
    waitqueue spin lock to order the rpc_task reference count releases between
    the waiting process and rpciod.
    The common case where nobody is waiting for completion is optimised for by
    checking if the RPC_TASK_ASYNC flag is cleared and/or if the rpc_task
    reference count is 1: in those cases we drop trying to grab the spin lock,
    and immediately free up the rpc_task.
    
    Those few processes that need to put the rpc_task from inside an
    asynchronous context and that do not care about ordering are given a new
    helper: rpc_put_task_async().
    
    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] 82+ messages in thread

* [GIT PULL] Please pull NFS client bugfixes
@ 2010-11-26 18:56 Trond Myklebust
  0 siblings, 0 replies; 82+ messages in thread
From: Trond Myklebust @ 2010-11-26 18:56 UTC (permalink / raw)
  To: Linus Torvalds; +Cc: linux-nfs, linux-kernel

Hi Linus,

Please pull from the "bugfixes" branch of the repository at

   git pull git://git.linux-nfs.org/projects/trondmy/nfs-2.6.git bugfixes

This will update the following files through the appended changesets.

  Cheers,
    Trond

----
 fs/nfs/dir.c            |   62 +++++++++++++++++++++++++---------------------
 fs/nfs/direct.c         |    2 +-
 fs/nfs/internal.h       |    9 +++++++
 fs/nfs/nfs2xdr.c        |    4 ++-
 fs/nfs/nfs3xdr.c        |    4 ++-
 fs/nfs/nfs4xdr.c        |    6 ++++-
 include/linux/nfs_xdr.h |    1 +
 net/sunrpc/clnt.c       |   24 +++++++++++-------
 8 files changed, 71 insertions(+), 41 deletions(-)

commit 0b26a0bf6ff398185546432420bb772bcfdf8d94
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date:   Sat Nov 20 14:26:44 2010 -0500

    NFS: Ensure we return the dirent->d_type when it is known
    
    Store the dirent->d_type in the struct nfs_cache_array_entry so that we
    can use it in getdents() calls.
    
    This fixes a regression with the new readdir code.
    
    Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>

commit 3020093f578fb6c9acc6914dfd887a1ebd1db659
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date:   Sat Nov 20 15:18:22 2010 -0500

    NFS: Correct the array bound calculation in nfs_readdir_add_to_array
    
    It looks as if the array size calculation in MAX_READDIR_ARRAY does not
    take the alignment of struct nfs_cache_array_entry into account.
    
    Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>

commit ece0b4233b6b915d1f63add2bd9f2733aec6317a
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date:   Sat Nov 20 13:55:33 2010 -0500

    NFS: Don't ignore errors from nfs_do_filldir()
    
    We should ignore the errors from the filldir callback, and just interpret
    them as meaning we should exit, however we should definitely pass back
    ENOMEM errors.
    
    Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>

commit 85f8607e163f8d281fb407357279cb4ac6df12e6
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date:   Sat Nov 20 13:24:49 2010 -0500

    NFS: Fix the error handling in "uncached_readdir()"
    
    Currently, uncached_readdir() is broken because if fails to handle
    the results from nfs_readdir_xdr_to_array() correctly.
    
    Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>

commit 7a8e1dc34f52fd2927dbf7e520d7cd8eadc51336
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date:   Sat Nov 20 13:24:46 2010 -0500

    NFS: Fix a page leak in uncached_readdir()
    
    Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>

commit e7c58e974a0318fcca5368e7b3570e10e9ae9028
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date:   Sat Nov 20 13:22:24 2010 -0500

    NFS: Fix a page leak in nfs_do_filldir()
    
    nfs_do_filldir() must always free desc->page when it is done, otherwise
    we end up leaking the page.
    
    Also remove unused variable 'dentry'.
    
    Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>

commit 5c346854d8ce6ca91931f8fc9177934257a667d0
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date:   Sat Nov 20 12:43:45 2010 -0500

    NFS: Assume eof if the server returns no readdir records
    
    Some servers are known to be buggy w.r.t. this. Deal with them...
    
    Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>

commit 463a376eae1c92a66c912af539bfd4bbefa37673
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date:   Sat Nov 20 12:22:20 2010 -0500

    NFS: Buffer overflow in ->decode_dirent() should not be fatal
    
    Overflowing the buffer in the readdir ->decode_dirent() should not lead to
    a fatal error, but rather to an attempt to reread the record in question.
    
    Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>

commit b47d19de2c714020ba8f5545a6e7d4968f37eb45
Author: Arun Bharadwaj <arun@linux.vnet.ibm.com>
Date:   Thu Nov 18 10:36:43 2010 +0000

    Pure nfs client performance using odirect.
    
    When an application opens a file with O_DIRECT flag, if the size of
    the data that is written is equal to wsize, the client sends a
    WRITE RPC with stable flag set to UNSTABLE followed by a single
    COMMIT RPC rather than sending a single WRITE RPC with the stable
    flag set to FILE_SYNC. This a bug.
    
    Patch to fix this.
    
    Signed-off-by: Arun R Bharadwaj <arun@linux.vnet.ibm.com>
    Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>

commit 5fc43978a79e8021c189660ab63249fd29c5fb32
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date:   Sat Nov 20 11:13:31 2010 -0500

    SUNRPC: Fix an infinite loop in call_refresh/call_refreshresult
    
    If the rpcauth_refreshcred() call returns an error other than
    EACCES, ENOMEM or ETIMEDOUT, we currently end up looping forever
    between call_refresh and call_refreshresult.
    
    The correct thing to do here is to exit on all errors except
    EAGAIN and ETIMEDOUT, for which case we retry 3 times, then
    return EACCES.
    
    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] 82+ messages in thread

* [GIT PULL] Please pull NFS client bugfixes...
@ 2010-05-26 19:42 Trond Myklebust
  0 siblings, 0 replies; 82+ messages in thread
From: Trond Myklebust @ 2010-05-26 19:42 UTC (permalink / raw)
  To: Linus Torvalds; +Cc: linux-nfs, linux-kernel

Hi Linus,

Please pull from the "bugfixes" branch of the repository at

   git pull git://git.linux-nfs.org/projects/trondmy/nfs-2.6.git bugfixes

This will update the following files through the appended changesets.

  Cheers,
    Trond

----
 fs/nfs/dir.c          |    1 +
 fs/nfs/write.c        |   20 ++++++++++++++++----
 net/sunrpc/xprtsock.c |   29 ++++++++++++++++++-----------
 3 files changed, 35 insertions(+), 15 deletions(-)

commit 0522f6adedd2736cbca3c0e16ca51df668993eee
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date:   Wed May 26 08:42:24 2010 -0400

    NFS: Fix another nfs_wb_page() deadlock
    
    J.R. Okajima reports that the call to sync_inode() in nfs_wb_page() can
    deadlock with other writeback flush calls. It boils down to the fact
    that we cannot ever call writeback_single_inode() while holding a page
    lock (even if we do set nr_to_write to zero) since another process may
    already be waiting in the call to do_writepages(), and so will deny us
    the I_SYNC lock.
    
    Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>

commit c5efa5fc91f1f6d1d47e65f39e7ec6d1157c777d
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date:   Wed May 26 08:42:11 2010 -0400

    NFS: Ensure that we mark the inode as dirty if we exit early from commit
    
    If we exit from nfs_commit_inode() without ensuring that the COMMIT rpc
    call has been completed, we must re-mark the inode as dirty. Otherwise,
    future calls to sync_inode() with the WB_SYNC_ALL flag set will fail to
    ensure that the data is on the disk.
    
    Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>

commit 59844a9bd73e084b0ffefc0e13226098e28c71ad
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date:   Wed May 26 08:42:24 2010 -0400

    NFS: Fix a lock imbalance typo in nfs_access_cache_shrinker
    
    Commit 9c7e7e23371e629dbb3b341610a418cdf1c19d91 (NFS: Don't call iput() in
    nfs_access_cache_shrinker) unintentionally removed the spin unlock for the
    inode->i_lock.
    
    Reported-by: David Howells <dhowells@redhat.com>
    Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>

commit 0a68b0bed08eeb7ec62e0125f17856b1ccb1ea4b
Author: J. Bruce Fields <bfields@citi.umich.edu>
Date:   Wed May 26 08:42:24 2010 -0400

    sunrpc: fix leak on error on socket xprt setup
    
    Also collect exit code together while we're at it.
    
    Signed-off-by: J. Bruce Fields <bfields@citi.umich.edu>
    Cc: Trond Myklebust <Trond.Myklebust@netapp.com>
    Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>



^ permalink raw reply	[flat|nested] 82+ messages in thread

* [GIT PULL] Please pull NFS client bugfixes...
@ 2010-05-07  2:22 Trond Myklebust
  0 siblings, 0 replies; 82+ messages in thread
From: Trond Myklebust @ 2010-05-07  2:22 UTC (permalink / raw)
  To: Linus Torvalds; +Cc: linux-nfs, linux-kernel, David Howells, Paul E. McKenney

Hi Linus,

Please pull from the "bugfixes" branch of the repository at

   git pull git://git.linux-nfs.org/projects/trondmy/nfs-2.6.git bugfixes

This will update the following files through the appended changesets.

  Cheers,
    Trond

----
 fs/nfs/delegation.c |   86 ++++++++++++++++++++++++++++++---------------------
 1 files changed, 51 insertions(+), 35 deletions(-)

commit 17d2c0a0c4d4e074f0a2a5c0090ff6d88f5e1d44
Author: David Howells <dhowells@redhat.com>
Date:   Sat May 1 12:37:18 2010 -0400

    NFS: Fix RCU issues in the NFSv4 delegation code
    
    Fix a number of RCU issues in the NFSv4 delegation code.
    
     (1) delegation->cred doesn't need to be RCU protected as it's essentially an
         invariant refcounted structure.
    
         By the time we get to nfs_free_delegation(), the delegation is being
         released, so no one else should be attempting to use the saved
         credentials, and they can be cleared.
    
         However, since the list of delegations could still be under traversal at
         this point by such as nfs_client_return_marked_delegations(), the cred
         should be released in nfs_do_free_delegation() rather than in
         nfs_free_delegation().  Simply using rcu_assign_pointer() to clear it is
         insufficient as that doesn't stop the cred from being destroyed, and nor
         does calling put_rpccred() after call_rcu(), given that the latter is
         asynchronous.
    
     (2) nfs_detach_delegation_locked() and nfs_inode_set_delegation() should use
         rcu_derefence_protected() because they can only be called if
         nfs_client::cl_lock is held, and that guards against anyone changing
         nfsi->delegation under it.  Furthermore, the barrier imposed by
         rcu_dereference() is superfluous, given that the spin_lock() is also a
         barrier.
    
     (3) nfs_detach_delegation_locked() is now passed a pointer to the nfs_client
         struct so that it can issue lockdep advice based on clp->cl_lock for (2).
    
     (4) nfs_inode_return_delegation_noreclaim() and nfs_inode_return_delegation()
         should use rcu_access_pointer() outside the spinlocked region as they
         merely examine the pointer and don't follow it, thus rendering unnecessary
         the need to impose a partial ordering over the one item of interest.
    
         These result in an RCU warning like the following:
    
    [ INFO: suspicious rcu_dereference_check() usage. ]
    ---------------------------------------------------
    fs/nfs/delegation.c:332 invoked rcu_dereference_check() without protection!
    
    other info that might help us debug this:
    
    rcu_scheduler_active = 1, debug_locks = 0
    2 locks held by mount.nfs4/2281:
     #0:  (&type->s_umount_key#34){+.+...}, at: [<ffffffff810b25b4>] deactivate_super+0x60/0x80
     #1:  (iprune_sem){+.+...}, at: [<ffffffff810c332a>] invalidate_inodes+0x39/0x13a
    
    stack backtrace:
    Pid: 2281, comm: mount.nfs4 Not tainted 2.6.34-rc1-cachefs #110
    Call Trace:
     [<ffffffff8105149f>] lockdep_rcu_dereference+0xaa/0xb2
     [<ffffffffa00b4591>] nfs_inode_return_delegation_noreclaim+0x5b/0xa0 [nfs]
     [<ffffffffa0095d63>] nfs4_clear_inode+0x11/0x1e [nfs]
     [<ffffffff810c2d92>] clear_inode+0x9e/0xf8
     [<ffffffff810c3028>] dispose_list+0x67/0x10e
     [<ffffffff810c340d>] invalidate_inodes+0x11c/0x13a
     [<ffffffff810b1dc1>] generic_shutdown_super+0x42/0xf4
     [<ffffffff810b1ebe>] kill_anon_super+0x11/0x4f
     [<ffffffffa009893c>] nfs4_kill_super+0x3f/0x72 [nfs]
     [<ffffffff810b25bc>] deactivate_super+0x68/0x80
     [<ffffffff810c6744>] mntput_no_expire+0xbb/0xf8
     [<ffffffff810c681b>] release_mounts+0x9a/0xb0
     [<ffffffff810c689b>] put_mnt_ns+0x6a/0x79
     [<ffffffffa00983a1>] nfs_follow_remote_path+0x5a/0x146 [nfs]
     [<ffffffffa0098334>] ? nfs_do_root_mount+0x82/0x95 [nfs]
     [<ffffffffa00985a9>] nfs4_try_mount+0x75/0xaf [nfs]
     [<ffffffffa0098874>] nfs4_get_sb+0x291/0x31a [nfs]
     [<ffffffff810b2059>] vfs_kern_mount+0xb8/0x177
     [<ffffffff810b2176>] do_kern_mount+0x48/0xe8
     [<ffffffff810c810b>] do_mount+0x782/0x7f9
     [<ffffffff810c8205>] sys_mount+0x83/0xbe
     [<ffffffff81001eeb>] system_call_fastpath+0x16/0x1b
    
    Also on:
    
    fs/nfs/delegation.c:215 invoked rcu_dereference_check() without protection!
     [<ffffffff8105149f>] lockdep_rcu_dereference+0xaa/0xb2
     [<ffffffffa00b4223>] nfs_inode_set_delegation+0xfe/0x219 [nfs]
     [<ffffffffa00a9c6f>] nfs4_opendata_to_nfs4_state+0x2c2/0x30d [nfs]
     [<ffffffffa00aa15d>] nfs4_do_open+0x2a6/0x3a6 [nfs]
     ...
    
    And:
    
    fs/nfs/delegation.c:40 invoked rcu_dereference_check() without protection!
     [<ffffffff8105149f>] lockdep_rcu_dereference+0xaa/0xb2
     [<ffffffffa00b3bef>] nfs_free_delegation+0x3d/0x6e [nfs]
     [<ffffffffa00b3e71>] nfs_do_return_delegation+0x26/0x30 [nfs]
     [<ffffffffa00b406a>] __nfs_inode_return_delegation+0x1ef/0x1fe [nfs]
     [<ffffffffa00b448a>] nfs_client_return_marked_delegations+0xc9/0x124 [nfs]
     ...
    
    Signed-off-by: David Howells <dhowells@redhat.com>
    Signed-off-by: Paul E. McKenney <paulmck@linux.vnet.ibm.com>
    Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>

commit 8f649c376254755f2261a693b3d48d09126218dc
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date:   Sat May 1 12:36:18 2010 -0400

    NFSv4: Fix the locking in nfs_inode_reclaim_delegation()
    
    Ensure that we correctly rcu-dereference the delegation itself, and that we
    protect against removal while we're changing the contents.
    
    Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
    Signed-off-by: David Howells <dhowells@redhat.com>
    Signed-off-by: Paul E. McKenney <paulmck@linux.vnet.ibm.com>



^ permalink raw reply	[flat|nested] 82+ messages in thread

* [GIT PULL] Please pull NFS client bugfixes
@ 2010-04-29 16:48 Trond Myklebust
  0 siblings, 0 replies; 82+ messages in thread
From: Trond Myklebust @ 2010-04-29 16:48 UTC (permalink / raw)
  To: Linus Torvalds; +Cc: linux-nfs, linux-kernel

Hi Linus,

Please pull from the "bugfixes" branch of the repository at

   git pull git://git.linux-nfs.org/projects/trondmy/nfs-2.6.git bugfixes

This will update the following files through the appended changesets.

  Cheers,
    Trond

----
 fs/nfs/client.c        |    2 +
 fs/nfs/dir.c           |    2 +-
 fs/nfs/nfs4proc.c      |    5 +++-
 fs/nfs/super.c         |    3 +-
 fs/nfs/write.c         |   55 +++++++++++++++++++++++++++++++----------------
 include/linux/nfs_fs.h |    1 +
 net/sunrpc/auth.c      |    2 +-
 7 files changed, 47 insertions(+), 23 deletions(-)

commit 9699eda6bc1f708a28acb716e1477aa351362fe2
Author: Xiaotian Feng <dfeng@redhat.com>
Date:   Thu Apr 22 18:56:17 2010 +0800

    nfs: fix memory leak in nfs_get_sb with CONFIG_NFS_V4
    
    With CONFIG_NFS_V4 and data version 4, nfs_get_sb will allocate memory for
    export_path in nfs4_validate_text_mount_data, so we need to free it then.
    This is addressed in following kmemleak report:
    
    unreferenced object 0xffff88016bf48a50 (size 16):
      comm "mount.nfs", pid 22567, jiffies 4651574704 (age 175471.200s)
      hex dump (first 16 bytes):
        2f 6f 70 74 2f 77 6f 72 6b 00 6b 6b 6b 6b 6b a5  /opt/work.kkkkk.
      backtrace:
        [<ffffffff814b34f9>] kmemleak_alloc+0x60/0xa7
        [<ffffffff81102c76>] kmemleak_alloc_recursive.clone.5+0x1b/0x1d
        [<ffffffff811046b3>] __kmalloc_track_caller+0x18f/0x1b7
        [<ffffffff810e1b08>] kstrndup+0x37/0x54
        [<ffffffffa0336971>] nfs_parse_devname+0x152/0x204 [nfs]
        [<ffffffffa0336af3>] nfs4_validate_text_mount_data+0xd0/0xdc [nfs]
        [<ffffffffa0338deb>] nfs_get_sb+0x325/0x736 [nfs]
        [<ffffffff81113671>] vfs_kern_mount+0xbd/0x17c
        [<ffffffff81113798>] do_kern_mount+0x4d/0xed
        [<ffffffff81129a87>] do_mount+0x787/0x7fe
        [<ffffffff81129b86>] sys_mount+0x88/0xc2
        [<ffffffff81009b42>] system_call_fastpath+0x16/0x1b
    
    Signed-off-by: Xiaotian Feng <dfeng@redhat.com>
    Cc: Trond Myklebust <Trond.Myklebust@netapp.com>
    Cc: Chuck Lever <chuck.lever@oracle.com>
    Cc: Benny Halevy <bhalevy@panasas.com>
    Cc: Al Viro <viro@ZenIV.linux.org.uk>
    Cc: Andy Adamson <andros@netapp.com>
    Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>

commit acf82b85a70f39786e3cbb1ffed8655bcc972424
Author: Dan Carpenter <error27@gmail.com>
Date:   Thu Apr 22 11:28:39 2010 +0200

    nfs: fix some issues in nfs41_proc_reclaim_complete()
    
    The original code passed an ERR_PTR() to rpc_put_task() and instead of
    returning zero on success it returned -ENOMEM.
    
    Signed-off-by: Dan Carpenter <error27@gmail.com>
    Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>

commit ba8b06e67ed7a560b0e7c80091bcadda4f4727a5
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date:   Tue Apr 27 18:33:54 2010 -0400

    NFS: Ensure that nfs_wb_page() waits for Pg_writeback to clear
    
    Neil Brown reports that he is seeing the BUG_ON(ret == 0) trigger in
    nfs_page_async_flush. According to the trace in
         https://bugzilla.novell.com/show_bug.cgi?id=599628
    the problem appears to be due to nfs_wb_page() not waiting for the
    PG_writeback flag to clear.
    
    There is a ditto problem in nfs_wb_page_cancel()
    
    Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>

commit 71d0a6112a363e703e383ae5b12c492485c39701
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date:   Thu Apr 22 15:35:57 2010 -0400

    NFS: Fix an unstable write data integrity race
    
    Commit 2c61be0a9478258f77b66208a0c4b1f5f8161c3c (NFS: Ensure that the WRITE
    and COMMIT RPC calls are always uninterruptible) exposed a race on file
    close. In order to ensure correct close-to-open behaviour, we want to wait
    for all outstanding background commit operations to complete.
    
    This patch adds an inode flag that indicates if a commit operation is under
    way, and provides a mechanism to allow ->write_inode() to wait for its
    completion if this is a data integrity flush.
    
    Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>

commit cdd29ecfcb9554132cd94b82ae8b69ba37adb3b5
Author: Dan Carpenter <error27@gmail.com>
Date:   Thu Apr 22 15:35:56 2010 -0400

    nfs: testing for null instead of ERR_PTR()
    
    nfs_path() returns an ERR_PTR(), it doesn't return null.
    
    Signed-off-by: Dan Carpenter <error27@gmail.com>
    Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>

commit 356e76b855bdbfd8d1c5e75bcf0c6bf0dfe83496
Author: Chuck Lever <chuck.lever@oracle.com>
Date:   Thu Apr 22 15:35:56 2010 -0400

    NFS: rsize and wsize settings ignored on v4 mounts
    
    NFSv4 mounts ignore the rsize and wsize mount options, and always use
    the default transfer size for both.  This seems to be because all
    NFSv4 mounts are now cloned, and the cloning logic doesn't copy the
    rsize and wsize settings from the parent nfs_server.
    
    I tested Fedora's 2.6.32.11-99 and it seems to have this problem as
    well, so I'm guessing that .33, .32, and perhaps older kernels have
    this issue as well.
    
    Signed-off-by: Chuck Lever <chuck.lever@oracle.com>
    Cc: Stable <stable@kernel.org>
    Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>

commit 1f063d2cdf332a8a5722006b1345d15d16007c6e
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date:   Thu Apr 22 15:35:55 2010 -0400

    NFSv4: Don't attempt an atomic open if the file is a mountpoint
    
    Fix https://bugzilla.kernel.org/show_bug.cgi?id=15789
    
    Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>

commit 3d7b08945e54a3a5358d5890240619a013cb7388
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date:   Thu Apr 22 15:35:55 2010 -0400

    SUNRPC: Fix a bug in rpcauth_prune_expired
    
    Don't want to evict a credential if cred->cr_expire == jiffies, since that
    means that it was just placed on the cred_unused list. We therefore need to
    use time_in_range() rather than time_in_range_open().
    
    Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>



^ permalink raw reply	[flat|nested] 82+ messages in thread

* [GIT PULL] Please pull NFS client bugfixes
@ 2010-03-23 17:00 Trond Myklebust
  0 siblings, 0 replies; 82+ messages in thread
From: Trond Myklebust @ 2010-03-23 17:00 UTC (permalink / raw)
  To: Linus Torvalds; +Cc: linux-nfs, linux-kernel

Hi Linus,

Please pull from the "bugfixes" branch of the repository at

   git pull git://git.linux-nfs.org/projects/trondmy/nfs-2.6.git bugfixes

This will update the following files through the appended changesets.

  Cheers,
    Trond

----
 fs/nfs/file.c                  |    3 ++-
 fs/nfs/nfs4xdr.c               |    2 ++
 include/linux/sunrpc/bc_xprt.h |    5 ++++-
 net/sunrpc/auth_gss/auth_gss.c |    5 ++---
 net/sunrpc/bc_svc.c            |   15 ---------------
 net/sunrpc/clnt.c              |    1 +
 net/sunrpc/rpc_pipe.c          |    2 ++
 net/sunrpc/xprt.c              |   22 +++++++++-------------
 net/sunrpc/xprtsock.c          |    3 ---
 9 files changed, 22 insertions(+), 36 deletions(-)

commit 556ae3bb32cabe483375b857dda1322384c57b65
Author: Jeff Layton <jlayton@redhat.com>
Date:   Sun Mar 21 12:10:36 2010 -0400

    NFS: don't try to decode GETATTR if DELEGRETURN returned error
    
    The reply parsing code attempts to decode the GETATTR response even if
    the DELEGRETURN portion of the compound returned an error. The GETATTR
    response won't actually exist if that's the case and we're asking the
    parser to read past the end of the response.
    
    This bug is fairly benign. The parser catches this without reading past
    the end of the response and decode_getfattr returns -EIO. Earlier
    kernels however had decode_op_hdr using the READ_BUF macro, and this
    bug would make this printk pop any time the client got an error from
    a delegreturn:
    
    kernel: decode_op_hdr: reply buffer overflowed in line XXXX
    
    More recent kernels seem to have replaced this printk with a dprintk.
    
    Signed-off-by: Jeff Layton <jlayton@redhat.com>
    Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>

commit f1f0abe192a72e75d7c59972e30784d043fd8d73
Author: Dan Carpenter <error27@gmail.com>
Date:   Sun Mar 21 12:10:34 2010 -0400

    sunrpc: handle allocation errors from __rpc_lookup_create()
    
    __rpc_lookup_create() can return ERR_PTR(-ENOMEM).
    
    Signed-off-by: Dan Carpenter <error27@gmail.com>
    Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
    Cc: stable@kernel.org

commit ff0901f8036a1586037c30a365c9666e946af0f1
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date:   Fri Mar 19 16:17:45 2010 -0400

    SUNRPC: Fix the return value of rpc_run_bc_task()
    
    Currently rpc_run_bc_task() will return NULL if the task allocation failed.
    However the only caller is bc_send, which assumes that the return value
    will be an ERR_PTR.
    
    Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>

commit c9acb42ef1904d15d0fb315061cefbe638f67f3a
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date:   Fri Mar 19 15:36:22 2010 -0400

    SUNRPC: Fix a use after free bug with the NFSv4.1 backchannel
    
    The ->release_request() callback was designed to allow the transport layer
    to do housekeeping after the RPC call is done. It cannot be used to free
    the request itself, and doing so leads to a use-after-free bug in
    xprt_release().
    
    Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>

commit cdead7cf12896c0e50a8be2e52de52c364603095
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date:   Fri Mar 19 15:36:22 2010 -0400

    SUNRPC: Fix a potential memory leak in auth_gss
    
    The function alloc_enc_pages() currently fails to release the pointer
    rqstp->rq_enc_pages in the error path.
    
    Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
    Acked-by: J. Bruce Fields <bfields@citi.umich.edu>
    Cc: stable@kernel.org

commit d812e575822a2b7ab1a7cadae2571505ec6ec2bd
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date:   Fri Mar 19 13:55:17 2010 -0400

    NFS: Prevent another deadlock in nfs_release_page()
    
    We should not attempt to free the page if __GFP_FS is not set. Otherwise we
    can deadlock as per
    
      http://bugzilla.kernel.org/show_bug.cgi?id=15578
    
    Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
    Cc: stable@kernel.org



^ permalink raw reply	[flat|nested] 82+ messages in thread

* [GIT PULL] Please pull NFS client bugfixes...
@ 2010-03-17 21:55 Trond Myklebust
  0 siblings, 0 replies; 82+ messages in thread
From: Trond Myklebust @ 2010-03-17 21:55 UTC (permalink / raw)
  To: Linus Torvalds; +Cc: linux-nfs, linux-kernel

Hi Linus,

Please pull from the "bugfixes" branch of the repository at

   git pull git://git.linux-nfs.org/projects/trondmy/nfs-2.6.git bugfixes

This will update the following files through the appended changesets.

  Cheers,
    Trond

----
 fs/nfs/callback_xdr.c |    1 +
 fs/nfs/delegation.h   |    6 ++++++
 fs/nfs/dir.c          |    2 +-
 fs/nfs/inode.c        |    2 +-
 fs/nfs/nfs4proc.c     |    1 +
 fs/nfs/pagelist.c     |   23 +++++++++++++----------
 fs/nfs/super.c        |   25 ++++++++++++++++++++-----
 net/sunrpc/xprtsock.c |    8 ++------
 8 files changed, 45 insertions(+), 23 deletions(-)

commit cfbc0683af235106e7dabe92003870b82ad6f0ba
Author: NeilBrown <neilb@suse.de>
Date:   Thu Mar 11 11:20:17 2010 +1100

    NFS: ensure bdi_unregister is called on mount failure.
    
    bdi_unregister is called by nfs_put_super which is only called by
    generic_shutdown_super if ->s_root is not NULL.  So if we error out
    in a circumstance where we called nfs_bdi_register (i.e. server !=
    NULL) but have not set s_root, then we need to call bdi_unregister
    explicitly in nfs_get_sb and various other *_get_sb() functions.
    
    Signed-off-by: NeilBrown <neilb@suse.de>
    Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>

commit bb6fbc4548b9ae7ebbd06ef72f00229df259d217
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date:   Thu Mar 11 09:19:35 2010 -0500

    NFS: Avoid a deadlock in nfs_release_page
    
    J.R. Okajima reports the following deadlock:
    
    INFO: task kswapd0:305 blocked for more than 120 seconds.
    "echo 0 > /proc/sys/kernel/hung_task_timeout_secs" disables this message.
    kswapd0       D 0000000000000001     0   305      2 0x00000000
     ffff88001f21d4f0 0000000000000046 ffff88001fdea680 ffff88001f21c000
     ffff88001f21dfd8 ffff88001f21c000 ffff88001f21dfd8 ffff88001f21dfd8
     ffff88001fdea040 0000000000014c00 0000000000000001 ffff88001fdea040
    Call Trace:
     [<ffffffff8146155d>] io_schedule+0x4d/0x70
     [<ffffffff810d2be5>] sync_page+0x65/0xa0
     [<ffffffff81461b12>] __wait_on_bit_lock+0x52/0xb0
     [<ffffffff810d2b80>] ? sync_page+0x0/0xa0
     [<ffffffff810d2b64>] __lock_page+0x64/0x70
     [<ffffffff81070ce0>] ? wake_bit_function+0x0/0x40
     [<ffffffff810df1d4>] truncate_inode_pages_range+0x344/0x4a0
     [<ffffffff810df340>] truncate_inode_pages+0x10/0x20
     [<ffffffff8112cbfe>] generic_delete_inode+0x15e/0x190
     [<ffffffff8112cc8d>] generic_drop_inode+0x5d/0x80
     [<ffffffff8112bb88>] iput+0x78/0x80
     [<ffffffff811bc908>] nfs_dentry_iput+0x38/0x50
     [<ffffffff811285f4>] dentry_iput+0x84/0x110
     [<ffffffff811286ae>] d_kill+0x2e/0x60
     [<ffffffff8112912a>] dput+0x7a/0x170
     [<ffffffff8111e925>] path_put+0x15/0x40
     [<ffffffff811c3a44>] __put_nfs_open_context+0xa4/0xb0
     [<ffffffff811cb5d0>] ? nfs_free_request+0x0/0x50
     [<ffffffff811c3b0b>] put_nfs_open_context+0xb/0x10
     [<ffffffff811cb5f9>] nfs_free_request+0x29/0x50
     [<ffffffff81234b7e>] kref_put+0x8e/0xe0
     [<ffffffff811cb594>] nfs_release_request+0x14/0x20
     [<ffffffff811cf769>] nfs_find_and_lock_request+0x89/0xa0
     [<ffffffff811d1180>] nfs_wb_page+0x80/0x110
     [<ffffffff811c0770>] nfs_release_page+0x70/0x90
     [<ffffffff810d18ee>] try_to_release_page+0x5e/0x80
     [<ffffffff810e1178>] shrink_page_list+0x638/0x860
     [<ffffffff810e19de>] shrink_zone+0x63e/0xc40
    
    We can fix this by making the call to put_nfs_open_context() happen when we
    actually remove the write request from the inode (which is done by the
    nfsiod thread in this case).
    
    Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
    Cc: stable@kernel.org

commit b4d2314bb88b07e5a04e6c75b442a1dfcd60e340
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date:   Wed Mar 10 15:21:44 2010 -0500

    NFSv4: Don't ignore the NFS_INO_REVAL_FORCED flag in nfs_revalidate_inode()
    
    If the NFS_INO_REVAL_FORCED flag is set, that means that we don't yet have
    an up to date attribute cache. Even if we hold a delegation, we must
    put a GETATTR on the wire.
    
    Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
    Cc: stable@kernel.org

commit 49697ee79242d5f8ac88f1ebc62e583d16bcc687
Author: Steve Dickson <SteveD@redhat.com>
Date:   Tue Oct 13 16:07:33 2009 -0400

    nfs4: Make the v4 callback service hidden
    
    To avoid hangs in the svc_unregister(), on version 4 mounts
    (and unmounts), when rpcbind is not running, make the nfs4 callback
    program an 'hidden' service by setting the 'vs_hidden' flag in the
    nfs4_callback_version structure.
    
    Signed-off-by: Steve Dickson <steved@redhat.com>
    Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>

commit 7dd08a570dcf45d52155996fee688405635ee481
Author: Dan Carpenter <error27@gmail.com>
Date:   Sat Mar 6 15:02:22 2010 +0300

    nfs: fix unlikely memory leak
    
    I'll admit that it's unlikely for the first allocation to fail and
    the second one to succeed.  I won't be offended if you ignore this
    patch.
    
    Signed-off-by: Dan Carpenter <error27@gmail.com>
    Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>

commit 5fe46e9d733f19a880ef7e516002bd4c2b833e14
Author: Bian Naimeng <biannm@cn.fujitsu.com>
Date:   Mon Mar 8 14:49:01 2010 +0800

    rpc client can not deal with ENOSOCK, so translate it into ENOCONN
    
    If NFSv4 client send a request before connect, or the old connection was broken
    because a ETIMEOUT error catched by call_status, ->send_request will return
    ENOSOCK, but rpc layer can not deal with it, so make sure ->send_request can
    translate ENOSOCK into ENOCONN.
    
    Signed-off-by: Bian Naimeng <biannm@cn.fujitsu.com>
    Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>



^ permalink raw reply	[flat|nested] 82+ messages in thread

* [GIT PULL] Please pull NFS client bugfixes
@ 2010-02-04 19:10 Trond Myklebust
  0 siblings, 0 replies; 82+ messages in thread
From: Trond Myklebust @ 2010-02-04 19:10 UTC (permalink / raw)
  To: Linus Torvalds; +Cc: linux-kernel, linux-nfs

Hi Linus,

Please pull from the "bugfixes" branch of the repository at

   git pull git://git.linux-nfs.org/projects/trondmy/nfs-2.6.git bugfixes

This will update the following files through the appended changesets.

  Cheers,
    Trond

----
 fs/nfs/file.c      |    2 +
 fs/nfs/inode.c     |    4 ++-
 fs/nfs/nfs4_fs.h   |    2 +
 fs/nfs/nfs4proc.c  |   78 ++++++++++++++++++++++++++++++++++++++-------------
 fs/nfs/nfs4state.c |    2 +-
 fs/nfs/pagelist.c  |   17 ++++++-----
 fs/nfs/super.c     |   15 +++++++++-
 fs/nfs/sysctl.c    |    2 +
 fs/nfs/write.c     |    3 +-
 9 files changed, 93 insertions(+), 32 deletions(-)

commit 9b4b351346b41d923d69adec865814fdaac4dba9
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date:   Wed Feb 3 08:27:35 2010 -0500

    NFS: Don't clobber the attribute type in nfs_update_inode()
    
    If the NFS_ATTR_FATTR_TYPE field isn't set in fattr->valid, then we should
    not set the S_IFMT part of inode->i_mode.
    
    Reported-by: Al Viro <viro@zeniv.linux.org.uk>
    Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>

commit 387c149b54b4321cbc790dadbd4f8eedb5a90468
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date:   Wed Feb 3 08:27:35 2010 -0500

    NFS: Fix a umount race
    
    Ensure that we unregister the bdi before kill_anon_super() calls
    ida_remove() on our device name.
    
    Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
    Cc: stable@kernel.org

commit 9f557cd8073104b39528794d44e129331ded649f
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date:   Wed Feb 3 08:27:22 2010 -0500

    NFS: Fix an Oops when truncating a file
    
    The VM/VFS does not allow mapping->a_ops->invalidatepage() to fail.
    Unfortunately, nfs_wb_page_cancel() may fail if a fatal signal occurs.
    Since the NFS code assumes that the page stays mapped for as long as the
    writeback is active, we can end up Oopsing (among other things).
    
    The only safe fix here is to convert nfs_wait_on_request(), so as to make
    it uninterruptible (as is already the case with wait_on_page_writeback()).
    
    
    Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
    Cc: stable@kernel.org

commit a2c0b9e291208f65221a0ad8a0c80a377707d480
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date:   Tue Jan 26 15:42:47 2010 -0500

    NFS: Ensure that we handle NFS4ERR_STALE_STATEID correctly
    
    Even if the server is crazy, we should be able to mark the stateid as being
    bad, to ensure it gets recovered.
    
    Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
    Reviewed-by: Chuck Lever <chuck.lever@oracle.com>

commit 03391693a95900875b0973569d2d73ff3aa8972e
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date:   Tue Jan 26 15:42:38 2010 -0500

    NFSv4.1: Don't call nfs4_schedule_state_recovery() unnecessarily
    
    Currently, nfs4_handle_exception() will call it twice if called with an
    error of -NFS4ERR_STALE_CLIENTID, -NFS4ERR_STALE_STATEID or
    -NFS4ERR_EXPIRED.
    
    Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
    Reviewed-by: Chuck Lever <chuck.lever@oracle.com>

commit 8e469ebd6dc32cbaf620e134d79f740bf0ebab79
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date:   Tue Jan 26 15:42:30 2010 -0500

    NFSv4: Don't allow posix locking against servers that don't support it
    
    Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
    Cc: stable@kernel.org
    Reviewed-by: Chuck Lever <chuck.lever@oracle.com>

commit 2bee72a6aa1e6d0a4f5da56217f0d0bbbdd0d9a3
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date:   Tue Jan 26 15:42:21 2010 -0500

    NFSv4: Ensure that the NFSv4 locking can recover from stateid errors
    
    In most cases, we just want to mark the lock_stateid sequence id as being
    uninitialised.
    
    Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
    Cc: stable@kernel.org
    Reviewed-by: Chuck Lever <chuck.lever@oracle.com>

commit b0706ca415b188ed58788420de4d5c9972b2afb2
Author: David Howells <dhowells@redhat.com>
Date:   Tue Jan 26 15:42:11 2010 -0500

    NFS: Avoid warnings when CONFIG_NFS_V4=n
    
    Avoid the following warnings when CONFIG_NFS_V4=n:
    
    	fs/nfs/sysctl.c:19: warning: unused variable `nfs_set_port_max'
    	fs/nfs/sysctl.c:18: warning: unused variable `nfs_set_port_min'
    
    by making those variables contingent on NFSv4 being configured.
    
    Signed-off-by: David Howells <dhowells@redhat.com>
    Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
    Reviewed-by: Chuck Lever <chuck.lever@oracle.com>

commit 0aa05887af728b058af91197f0ae9b3ae63dd74a
Author: H Hartley Sweeten <hartleys@visionengravers.com>
Date:   Tue Jan 26 15:42:03 2010 -0500

    NFS: Make nfs_commitdata_release static
    
    The symbol nfs_commitdata_release is only used locally
    in this file. Make it static to prevent the following sparse warning:
    
    warning: symbol 'nfs_commitdata_release' was not declared. Should it be static?
    
    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>
    Reviewed-by: Chuck Lever <chuck.lever@oracle.com>

commit 82be934a59ff891cac598727e5a862ba2b9d1fac
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date:   Tue Jan 26 15:41:53 2010 -0500

    NFS: Try to commit unstable writes in nfs_release_page()
    
    If someone calls nfs_release_page(), we presumably already know that the
    page is clean, however it may be holding an unstable write.
    
    Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
    Cc: stable@kernel.org
    Reviewed-by: Chuck Lever <chuck.lever@oracle.com>

commit c9edda7140ec6a22accf7f2f86da362dfbfd41fc
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date:   Tue Jan 26 15:41:34 2010 -0500

    NFS: Fix a reference leak in nfs_wb_cancel_page()
    
    Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
    Cc: stable@kernel.org
    Reviewed-by: Chuck Lever <chuck.lever@oracle.com>

diff --git a/fs/nfs/file.c b/fs/nfs/file.c
index 6b89132..63f2071 100644
--- a/fs/nfs/file.c
+++ b/fs/nfs/file.c
@@ -486,6 +486,8 @@ static int nfs_release_page(struct page *page, gfp_t gfp)
 {
 	dfprintk(PAGECACHE, "NFS: release_page(%p)\n", page);
 
+	if (gfp & __GFP_WAIT)
+		nfs_wb_page(page->mapping->host, page);
 	/* If PagePrivate() is set, then the page is not freeable */
 	if (PagePrivate(page))
 		return 0;
diff --git a/fs/nfs/inode.c b/fs/nfs/inode.c
index faa0918..f141bde 100644
--- a/fs/nfs/inode.c
+++ b/fs/nfs/inode.c
@@ -1261,8 +1261,10 @@ static int nfs_update_inode(struct inode *inode, struct nfs_fattr *fattr)
 
 	if (fattr->valid & NFS_ATTR_FATTR_MODE) {
 		if ((inode->i_mode & S_IALLUGO) != (fattr->mode & S_IALLUGO)) {
+			umode_t newmode = inode->i_mode & S_IFMT;
+			newmode |= fattr->mode & S_IALLUGO;
+			inode->i_mode = newmode;
 			invalid |= NFS_INO_INVALID_ATTR|NFS_INO_INVALID_ACCESS|NFS_INO_INVALID_ACL;
-			inode->i_mode = fattr->mode;
 		}
 	} else if (server->caps & NFS_CAP_MODE)
 		invalid |= save_cache_validity & (NFS_INO_INVALID_ATTR
diff --git a/fs/nfs/nfs4_fs.h b/fs/nfs/nfs4_fs.h
index 865265b..0c6fda3 100644
--- a/fs/nfs/nfs4_fs.h
+++ b/fs/nfs/nfs4_fs.h
@@ -146,6 +146,7 @@ enum {
 	NFS_O_RDWR_STATE,		/* OPEN stateid has read/write state */
 	NFS_STATE_RECLAIM_REBOOT,	/* OPEN stateid server rebooted */
 	NFS_STATE_RECLAIM_NOGRACE,	/* OPEN stateid needs to recover state */
+	NFS_STATE_POSIX_LOCKS,		/* Posix locks are supported */
 };
 
 struct nfs4_state {
@@ -277,6 +278,7 @@ extern void nfs4_state_set_mode_locked(struct nfs4_state *, fmode_t);
 extern void nfs4_schedule_state_recovery(struct nfs_client *);
 extern void nfs4_schedule_state_manager(struct nfs_client *);
 extern int nfs4_state_mark_reclaim_nograce(struct nfs_client *clp, struct nfs4_state *state);
+extern int nfs4_state_mark_reclaim_reboot(struct nfs_client *clp, struct nfs4_state *state);
 extern void nfs41_handle_sequence_flag_errors(struct nfs_client *clp, u32 flags);
 extern void nfs4_put_lock_state(struct nfs4_lock_state *lsp);
 extern int nfs4_set_lock_state(struct nfs4_state *state, struct file_lock *fl);
diff --git a/fs/nfs/nfs4proc.c b/fs/nfs/nfs4proc.c
index 198d51d..375f0fa 100644
--- a/fs/nfs/nfs4proc.c
+++ b/fs/nfs/nfs4proc.c
@@ -249,19 +249,15 @@ static int nfs4_handle_exception(const struct nfs_server *server, int errorcode,
 			if (state == NULL)
 				break;
 			nfs4_state_mark_reclaim_nograce(clp, state);
-		case -NFS4ERR_STALE_CLIENTID:
+			goto do_state_recovery;
 		case -NFS4ERR_STALE_STATEID:
-		case -NFS4ERR_EXPIRED:
-			nfs4_schedule_state_recovery(clp);
-			ret = nfs4_wait_clnt_recover(clp);
-			if (ret == 0)
-				exception->retry = 1;
-#if !defined(CONFIG_NFS_V4_1)
-			break;
-#else /* !defined(CONFIG_NFS_V4_1) */
-			if (!nfs4_has_session(server->nfs_client))
+			if (state == NULL)
 				break;
-			/* FALLTHROUGH */
+			nfs4_state_mark_reclaim_reboot(clp, state);
+		case -NFS4ERR_STALE_CLIENTID:
+		case -NFS4ERR_EXPIRED:
+			goto do_state_recovery;
+#if defined(CONFIG_NFS_V4_1)
 		case -NFS4ERR_BADSESSION:
 		case -NFS4ERR_BADSLOT:
 		case -NFS4ERR_BAD_HIGH_SLOT:
@@ -274,7 +270,7 @@ static int nfs4_handle_exception(const struct nfs_server *server, int errorcode,
 			nfs4_schedule_state_recovery(clp);
 			exception->retry = 1;
 			break;
-#endif /* !defined(CONFIG_NFS_V4_1) */
+#endif /* defined(CONFIG_NFS_V4_1) */
 		case -NFS4ERR_FILE_OPEN:
 			if (exception->timeout > HZ) {
 				/* We have retried a decent amount, time to
@@ -293,6 +289,12 @@ static int nfs4_handle_exception(const struct nfs_server *server, int errorcode,
 	}
 	/* We failed to handle the error */
 	return nfs4_map_errors(ret);
+do_state_recovery:
+	nfs4_schedule_state_recovery(clp);
+	ret = nfs4_wait_clnt_recover(clp);
+	if (ret == 0)
+		exception->retry = 1;
+	return ret;
 }
 

@@ -1658,6 +1660,8 @@ static int _nfs4_do_open(struct inode *dir, struct path *path, fmode_t fmode, in
 	status = PTR_ERR(state);
 	if (IS_ERR(state))
 		goto err_opendata_put;
+	if ((opendata->o_res.rflags & NFS4_OPEN_RESULT_LOCKTYPE_POSIX) != 0)
+		set_bit(NFS_STATE_POSIX_LOCKS, &state->flags);
 	nfs4_opendata_put(opendata);
 	nfs4_put_state_owner(sp);
 	*res = state;
@@ -3422,15 +3426,14 @@ _nfs4_async_handle_error(struct rpc_task *task, const struct nfs_server *server,
 			if (state == NULL)
 				break;
 			nfs4_state_mark_reclaim_nograce(clp, state);
-		case -NFS4ERR_STALE_CLIENTID:
+			goto do_state_recovery;
 		case -NFS4ERR_STALE_STATEID:
+			if (state == NULL)
+				break;
+			nfs4_state_mark_reclaim_reboot(clp, state);
+		case -NFS4ERR_STALE_CLIENTID:
 		case -NFS4ERR_EXPIRED:
-			rpc_sleep_on(&clp->cl_rpcwaitq, task, NULL);
-			nfs4_schedule_state_recovery(clp);
-			if (test_bit(NFS4CLNT_MANAGER_RUNNING, &clp->cl_state) == 0)
-				rpc_wake_up_queued_task(&clp->cl_rpcwaitq, task);
-			task->tk_status = 0;
-			return -EAGAIN;
+			goto do_state_recovery;
 #if defined(CONFIG_NFS_V4_1)
 		case -NFS4ERR_BADSESSION:
 		case -NFS4ERR_BADSLOT:
@@ -3458,6 +3461,13 @@ _nfs4_async_handle_error(struct rpc_task *task, const struct nfs_server *server,
 	}
 	task->tk_status = nfs4_map_errors(task->tk_status);
 	return 0;
+do_state_recovery:
+	rpc_sleep_on(&clp->cl_rpcwaitq, task, NULL);
+	nfs4_schedule_state_recovery(clp);
+	if (test_bit(NFS4CLNT_MANAGER_RUNNING, &clp->cl_state) == 0)
+		rpc_wake_up_queued_task(&clp->cl_rpcwaitq, task);
+	task->tk_status = 0;
+	return -EAGAIN;
 }
 
 static int
@@ -4088,6 +4098,28 @@ static const struct rpc_call_ops nfs4_recover_lock_ops = {
 	.rpc_release = nfs4_lock_release,
 };
 
+static void nfs4_handle_setlk_error(struct nfs_server *server, struct nfs4_lock_state *lsp, int new_lock_owner, int error)
+{
+	struct nfs_client *clp = server->nfs_client;
+	struct nfs4_state *state = lsp->ls_state;
+
+	switch (error) {
+	case -NFS4ERR_ADMIN_REVOKED:
+	case -NFS4ERR_BAD_STATEID:
+	case -NFS4ERR_EXPIRED:
+		if (new_lock_owner != 0 ||
+		   (lsp->ls_flags & NFS_LOCK_INITIALIZED) != 0)
+			nfs4_state_mark_reclaim_nograce(clp, state);
+		lsp->ls_seqid.flags &= ~NFS_SEQID_CONFIRMED;
+		break;
+	case -NFS4ERR_STALE_STATEID:
+		if (new_lock_owner != 0 ||
+		    (lsp->ls_flags & NFS_LOCK_INITIALIZED) != 0)
+			nfs4_state_mark_reclaim_reboot(clp, state);
+		lsp->ls_seqid.flags &= ~NFS_SEQID_CONFIRMED;
+	};
+}
+
 static int _nfs4_do_setlk(struct nfs4_state *state, int cmd, struct file_lock *fl, int recovery_type)
 {
 	struct nfs4_lockdata *data;
@@ -4126,6 +4158,9 @@ static int _nfs4_do_setlk(struct nfs4_state *state, int cmd, struct file_lock *f
 	ret = nfs4_wait_for_completion_rpc_task(task);
 	if (ret == 0) {
 		ret = data->rpc_status;
+		if (ret)
+			nfs4_handle_setlk_error(data->server, data->lsp,
+					data->arg.new_lock_owner, ret);
 	} else
 		data->cancelled = 1;
 	rpc_put_task(task);
@@ -4181,8 +4216,11 @@ static int _nfs4_proc_setlk(struct nfs4_state *state, int cmd, struct file_lock
 {
 	struct nfs_inode *nfsi = NFS_I(state->inode);
 	unsigned char fl_flags = request->fl_flags;
-	int status;
+	int status = -ENOLCK;
 
+	if ((fl_flags & FL_POSIX) &&
+			!test_bit(NFS_STATE_POSIX_LOCKS, &state->flags))
+		goto out;
 	/* Is this a delegated open? */
 	status = nfs4_set_lock_state(state, request);
 	if (status != 0)
diff --git a/fs/nfs/nfs4state.c b/fs/nfs/nfs4state.c
index 6d263ed..c1e2733 100644
--- a/fs/nfs/nfs4state.c
+++ b/fs/nfs/nfs4state.c
@@ -901,7 +901,7 @@ void nfs4_schedule_state_recovery(struct nfs_client *clp)
 	nfs4_schedule_state_manager(clp);
 }
 
-static int nfs4_state_mark_reclaim_reboot(struct nfs_client *clp, struct nfs4_state *state)
+int nfs4_state_mark_reclaim_reboot(struct nfs_client *clp, struct nfs4_state *state)
 {
 
 	set_bit(NFS_STATE_RECLAIM_REBOOT, &state->flags);
diff --git a/fs/nfs/pagelist.c b/fs/nfs/pagelist.c
index e297593..a12c45b 100644
--- a/fs/nfs/pagelist.c
+++ b/fs/nfs/pagelist.c
@@ -176,6 +176,12 @@ void nfs_release_request(struct nfs_page *req)
 	kref_put(&req->wb_kref, nfs_free_request);
 }
 
+static int nfs_wait_bit_uninterruptible(void *word)
+{
+	io_schedule();
+	return 0;
+}
+
 /**
  * nfs_wait_on_request - Wait for a request to complete.
  * @req: request to wait upon.
@@ -186,14 +192,9 @@ void nfs_release_request(struct nfs_page *req)
 int
 nfs_wait_on_request(struct nfs_page *req)
 {
-	int ret = 0;
-
-	if (!test_bit(PG_BUSY, &req->wb_flags))
-		goto out;
-	ret = out_of_line_wait_on_bit(&req->wb_flags, PG_BUSY,
-			nfs_wait_bit_killable, TASK_KILLABLE);
-out:
-	return ret;
+	return wait_on_bit(&req->wb_flags, PG_BUSY,
+			nfs_wait_bit_uninterruptible,
+			TASK_UNINTERRUPTIBLE);
 }
 
 /**
diff --git a/fs/nfs/super.c b/fs/nfs/super.c
index ce907ef..f1afee4 100644
--- a/fs/nfs/super.c
+++ b/fs/nfs/super.c
@@ -243,6 +243,7 @@ static int  nfs_show_stats(struct seq_file *, struct vfsmount *);
 static int nfs_get_sb(struct file_system_type *, int, const char *, void *, struct vfsmount *);
 static int nfs_xdev_get_sb(struct file_system_type *fs_type,
 		int flags, const char *dev_name, void *raw_data, struct vfsmount *mnt);
+static void nfs_put_super(struct super_block *);
 static void nfs_kill_super(struct super_block *);
 static int nfs_remount(struct super_block *sb, int *flags, char *raw_data);
 
@@ -266,6 +267,7 @@ static const struct super_operations nfs_sops = {
 	.alloc_inode	= nfs_alloc_inode,
 	.destroy_inode	= nfs_destroy_inode,
 	.write_inode	= nfs_write_inode,
+	.put_super	= nfs_put_super,
 	.statfs		= nfs_statfs,
 	.clear_inode	= nfs_clear_inode,
 	.umount_begin	= nfs_umount_begin,
@@ -335,6 +337,7 @@ static const struct super_operations nfs4_sops = {
 	.alloc_inode	= nfs_alloc_inode,
 	.destroy_inode	= nfs_destroy_inode,
 	.write_inode	= nfs_write_inode,
+	.put_super	= nfs_put_super,
 	.statfs		= nfs_statfs,
 	.clear_inode	= nfs4_clear_inode,
 	.umount_begin	= nfs_umount_begin,
@@ -2258,6 +2261,17 @@ error_splat_super:
 }
 
 /*
+ * Ensure that we unregister the bdi before kill_anon_super
+ * releases the device name
+ */
+static void nfs_put_super(struct super_block *s)
+{
+	struct nfs_server *server = NFS_SB(s);
+
+	bdi_unregister(&server->backing_dev_info);
+}
+
+/*
  * Destroy an NFS2/3 superblock
  */
 static void nfs_kill_super(struct super_block *s)
@@ -2265,7 +2279,6 @@ static void nfs_kill_super(struct super_block *s)
 	struct nfs_server *server = NFS_SB(s);
 
 	kill_anon_super(s);
-	bdi_unregister(&server->backing_dev_info);
 	nfs_fscache_release_super_cookie(s);
 	nfs_free_server(server);
 }
diff --git a/fs/nfs/sysctl.c b/fs/nfs/sysctl.c
index 70e1fbb..ad4d2e7 100644
--- a/fs/nfs/sysctl.c
+++ b/fs/nfs/sysctl.c
@@ -15,8 +15,10 @@
 
 #include "callback.h"
 
+#ifdef CONFIG_NFS_V4
 static const int nfs_set_port_min = 0;
 static const int nfs_set_port_max = 65535;
+#endif
 static struct ctl_table_header *nfs_callback_sysctl_table;
 
 static ctl_table nfs_cb_sysctls[] = {
diff --git a/fs/nfs/write.c b/fs/nfs/write.c
index d171696..7b54b8b 100644
--- a/fs/nfs/write.c
+++ b/fs/nfs/write.c
@@ -1233,7 +1233,7 @@ int nfs_writeback_done(struct rpc_task *task, struct nfs_write_data *data)
 

 #if defined(CONFIG_NFS_V3) || defined(CONFIG_NFS_V4)
-void nfs_commitdata_release(void *data)
+static void nfs_commitdata_release(void *data)
 {
 	struct nfs_write_data *wdata = data;
 
@@ -1541,6 +1541,7 @@ int nfs_wb_page_cancel(struct inode *inode, struct page *page)
 			break;
 		}
 		ret = nfs_wait_on_request(req);
+		nfs_release_request(req);
 		if (ret < 0)
 			goto out;
 	}


^ permalink raw reply	[flat|nested] 82+ messages in thread

* Re: [GIT PULL] Please pull NFS client bugfixes....
  2010-01-08  2:00                     ` Linus Torvalds
@ 2010-01-14 13:18                       ` Peter Zijlstra
  0 siblings, 0 replies; 82+ messages in thread
From: Peter Zijlstra @ 2010-01-14 13:18 UTC (permalink / raw)
  To: Linus Torvalds
  Cc: Trond Myklebust, Andi Kleen, Linux Kernel Mailing List, Ingo Molnar

On Thu, 2010-01-07 at 18:00 -0800, Linus Torvalds wrote:
> 
> On Thu, 7 Jan 2010, Linus Torvalds wrote:
> > 
> > You cannot mmap a directory (and you can't readdir a non-directory), so if 
> > it's a per-inode NFS lock, then the simplest fix _might_ be to just put 
> > directory locks in a different lockdep class from non-directory locks. 
> > That might fix it.
> > 
> > Of course, if it's not a per-inode lock, that doesn't help.
> 
> Hmm. I notice that we already do this in unlock_new_inode() for i_mutex. 
> And I googled for the problem, and it does indeed seem to be about the 
> normal i_mutex <-> mmap_sem thing with filldir-vs-mmap.
> 
> Is there perhaps some path where NFS creates new inodes without going 
> through the normal path? Like the root inode or something? So then you'd 
> have a root inode with i_mutex annotated as being in the same class as a 
> regular file, which completes the lockdep chain.

Quite possible, but I got lost trying to find anything like the root
inode.

> Or maybe there is something else I'm missing.
> 
> I'm adding Peter and Ingo to the Cc as the "lockdep guys". Maybe they see 
> what I am missing.

Not really, nfs_fhget() seems to know about directories as it has a
S_ISDIR() check of itself before doing unlock_new_inode(), so I would
expect unlock_new_inode() to indeed set the
file_system_type::i_mutex_dir_key.




^ permalink raw reply	[flat|nested] 82+ messages in thread

* Re: [GIT PULL] Please pull NFS client bugfixes....
  2010-01-08  1:30                 ` Linus Torvalds
  2010-01-08  1:35                   ` Linus Torvalds
@ 2010-01-08  5:19                   ` Andi Kleen
  1 sibling, 0 replies; 82+ messages in thread
From: Andi Kleen @ 2010-01-08  5:19 UTC (permalink / raw)
  To: Linus Torvalds; +Cc: Trond Myklebust, linux-kernel

Linus Torvalds <torvalds@linux-foundation.org> writes:

> I've not actually seen the lockdep chain, so I don't know 
> the deails. Pointers?


=======================================================
[ INFO: possible circular locking dependency detected ]
2.6.33-rc1-git3-MCE6 #12
-------------------------------------------------------
udevinfo/2562 is trying to acquire lock:
 (&sb->s_type->i_mutex_key#5){+.+.+.}, at: [<ffffffff81185188>] nfs_revalidate_mapping+0x7c/0xc5

but task is already holding lock:
 (&mm->mmap_sem){++++++}, at: [<ffffffff810ae75b>] sys_mmap_pgoff+0xd3/0x1a0

which lock already depends on the new lock.


the existing dependency chain (in reverse order) is:

-> #1 (&mm->mmap_sem){++++++}:
       [<ffffffff81068c48>] __lock_acquire+0x1432/0x1771
       [<ffffffff81069043>] lock_acquire+0xbc/0xd9
       [<ffffffff810b1a90>] might_fault+0x84/0xa4
       [<ffffffff810e3c78>] filldir+0x6a/0xcb
       [<ffffffff81180d58>] nfs_do_filldir+0x39d/0x4ac
       [<ffffffff8118167c>] nfs_readdir+0x815/0x8b6
       [<ffffffff810e3df7>] vfs_readdir+0x6c/0xa1
       [<ffffffff810e3f6a>] sys_getdents+0x7d/0xc9
       [<ffffffff810029eb>] system_call_fastpath+0x16/0x1b

-> #0 (&sb->s_type->i_mutex_key#5){+.+.+.}:
       [<ffffffff8106896d>] __lock_acquire+0x1157/0x1771
       [<ffffffff81069043>] lock_acquire+0xbc/0xd9
       [<ffffffff8149472c>] mutex_lock_nested+0x68/0x2d2
       [<ffffffff81185188>] nfs_revalidate_mapping+0x7c/0xc5
       [<ffffffff81182c0a>] nfs_file_mmap+0x68/0x71
       [<ffffffff810b99bf>] mmap_region+0x311/0x530
       [<ffffffff810b9e6e>] do_mmap_pgoff+0x290/0x2f3
       [<ffffffff810ae77c>] sys_mmap_pgoff+0xf4/0x1a0
       [<ffffffff81006ba2>] sys_mmap+0x1d/0x1f
       [<ffffffff810029eb>] system_call_fastpath+0x16/0x1b

other info that might help us debug this:

1 lock held by udevinfo/2562:
 #0:  (&mm->mmap_sem){++++++}, at: [<ffffffff810ae75b>] sys_mmap_pgoff+0xd3/0x1a0

stack backtrace:
Pid: 2562, comm: udevinfo Not tainted 2.6.33-rc1-git3-MCE6 #12
Call Trace:
 [<ffffffff810672c8>] print_circular_bug+0xb3/0xc2
 [<ffffffff8106896d>] __lock_acquire+0x1157/0x1771
 [<ffffffff8105b031>] ? sched_clock_local+0x1c/0x80
 [<ffffffff81069043>] lock_acquire+0xbc/0xd9
 [<ffffffff81185188>] ? nfs_revalidate_mapping+0x7c/0xc5
 [<ffffffff8149472c>] mutex_lock_nested+0x68/0x2d2
 [<ffffffff81185188>] ? nfs_revalidate_mapping+0x7c/0xc5
 [<ffffffff8105b15e>] ? sched_clock_cpu+0xc9/0xce
 [<ffffffff81185188>] ? nfs_revalidate_mapping+0x7c/0xc5
 [<ffffffff810b991c>] ? mmap_region+0x26e/0x530
 [<ffffffff81185188>] nfs_revalidate_mapping+0x7c/0xc5
 [<ffffffff81182c0a>] nfs_file_mmap+0x68/0x71
 [<ffffffff810b99bf>] mmap_region+0x311/0x530
 [<ffffffff810b9e6e>] do_mmap_pgoff+0x290/0x2f3
 [<ffffffff810ae77c>] sys_mmap_pgoff+0xf4/0x1a0
 [<ffffffff81495c86>] ? trace_hardirqs_on_thunk+0x3a/0x3f
 [<ffffffff81006ba2>] sys_mmap+0x1d/0x1f
 [<ffffffff810029eb>] system_call_fastpath+0x16/0x1b

-Andi

-- 
ak@linux.intel.com -- Speaking for myself only.

^ permalink raw reply	[flat|nested] 82+ messages in thread

* Re: [GIT PULL] Please pull NFS client bugfixes....
  2010-01-08  1:35                   ` Linus Torvalds
@ 2010-01-08  2:00                     ` Linus Torvalds
  2010-01-14 13:18                       ` Peter Zijlstra
  0 siblings, 1 reply; 82+ messages in thread
From: Linus Torvalds @ 2010-01-08  2:00 UTC (permalink / raw)
  To: Trond Myklebust
  Cc: Andi Kleen, Linux Kernel Mailing List, Peter Zijlstra, Ingo Molnar



On Thu, 7 Jan 2010, Linus Torvalds wrote:
> 
> You cannot mmap a directory (and you can't readdir a non-directory), so if 
> it's a per-inode NFS lock, then the simplest fix _might_ be to just put 
> directory locks in a different lockdep class from non-directory locks. 
> That might fix it.
> 
> Of course, if it's not a per-inode lock, that doesn't help.

Hmm. I notice that we already do this in unlock_new_inode() for i_mutex. 
And I googled for the problem, and it does indeed seem to be about the 
normal i_mutex <-> mmap_sem thing with filldir-vs-mmap.

Is there perhaps some path where NFS creates new inodes without going 
through the normal path? Like the root inode or something? So then you'd 
have a root inode with i_mutex annotated as being in the same class as a 
regular file, which completes the lockdep chain.

Or maybe there is something else I'm missing.

I'm adding Peter and Ingo to the Cc as the "lockdep guys". Maybe they see 
what I am missing.

		Linus

^ permalink raw reply	[flat|nested] 82+ messages in thread

* Re: [GIT PULL] Please pull NFS client bugfixes....
  2010-01-08  1:30                 ` Linus Torvalds
@ 2010-01-08  1:35                   ` Linus Torvalds
  2010-01-08  2:00                     ` Linus Torvalds
  2010-01-08  5:19                   ` Andi Kleen
  1 sibling, 1 reply; 82+ messages in thread
From: Linus Torvalds @ 2010-01-08  1:35 UTC (permalink / raw)
  To: Trond Myklebust; +Cc: Andi Kleen, linux-kernel



On Thu, 7 Jan 2010, Linus Torvalds wrote:
> 
> However, I still suspect that the lock inversion problem can probably be 
> fixed without any of that at all. Maybe you can just break the chain 
> somewhere else. I've not actually seen the lockdep chain, so I don't know 
> the deails. Pointers?

For example, if we're talking about readdir having a lock the other way 
(NFS lock taken before the mmap_sem), it's entirely possible that there is 
nothing to "fix" but some lockdep annotation.

You cannot mmap a directory (and you can't readdir a non-directory), so if 
it's a per-inode NFS lock, then the simplest fix _might_ be to just put 
directory locks in a different lockdep class from non-directory locks. 
That might fix it.

Of course, if it's not a per-inode lock, that doesn't help.

And maybe I'm missing something entirely, and such games with lockdep 
classes are pointless, and I'm a moron. Quite possible.

		Linus

^ permalink raw reply	[flat|nested] 82+ messages in thread

* Re: [GIT PULL] Please pull NFS client bugfixes....
  2010-01-08  1:22               ` Trond Myklebust
  2010-01-08  1:26                 ` Trond Myklebust
@ 2010-01-08  1:30                 ` Linus Torvalds
  2010-01-08  1:35                   ` Linus Torvalds
  2010-01-08  5:19                   ` Andi Kleen
  1 sibling, 2 replies; 82+ messages in thread
From: Linus Torvalds @ 2010-01-08  1:30 UTC (permalink / raw)
  To: Trond Myklebust; +Cc: Andi Kleen, linux-kernel



On Thu, 7 Jan 2010, Trond Myklebust wrote:
> 
> I don't think anyone has been advocating doing the revalidation _after_
> the call to mmap_region(). All I want is to be able to do it as part of
> the mmap() syscall. It would be quite OK to add a ->pre_mmap() (which is
> what I believe Peter's patches do).

->pre_mmap is better, but not obviously so. We'd have to call ->pre_mmap() 
so _long_ before the mmap that it might be that the mmap never happens at 
all (due to errors happening later). 

Sounds like that would work in your particular case, though.

However, I still suspect that the lock inversion problem can probably be 
fixed without any of that at all. Maybe you can just break the chain 
somewhere else. I've not actually seen the lockdep chain, so I don't know 
the deails. Pointers?

		Linus

^ permalink raw reply	[flat|nested] 82+ messages in thread

* Re: [GIT PULL] Please pull NFS client bugfixes....
  2010-01-08  1:22               ` Trond Myklebust
@ 2010-01-08  1:26                 ` Trond Myklebust
  2010-01-08  1:30                 ` Linus Torvalds
  1 sibling, 0 replies; 82+ messages in thread
From: Trond Myklebust @ 2010-01-08  1:26 UTC (permalink / raw)
  To: Linus Torvalds; +Cc: Andi Kleen, linux-kernel

On Thu, 2010-01-07 at 20:22 -0500, Trond Myklebust wrote: 
> All I want to ensure is that people who use non-posix-lock based
> synchronisation can set the 'noac' flag, and be assured that if mmap()
> is called _after_ they have grabbed their lock, then the page cache will
> be duly revalidated (under the lock), and the fresh data will be made
> available.

BTW: This is the same guarantee that we offer in the case of standard
read() (and write()) when 'noac' is set.

^ permalink raw reply	[flat|nested] 82+ messages in thread

* Re: [GIT PULL] Please pull NFS client bugfixes....
  2010-01-08  1:12             ` Linus Torvalds
  2010-01-08  1:22               ` Trond Myklebust
@ 2010-01-08  1:22               ` Linus Torvalds
  1 sibling, 0 replies; 82+ messages in thread
From: Linus Torvalds @ 2010-01-08  1:22 UTC (permalink / raw)
  To: Trond Myklebust; +Cc: Andi Kleen, linux-kernel



On Thu, 7 Jan 2010, Linus Torvalds wrote:
> 
> A filesystem that depends on the different phases would be a fundamentally 
> buggy filesystem. Right now mmap is "atomic", and you can pre-populate (or 
> pre-verify, like NFS does) the mapping in the _knowledge_ that there are 
> no page faults that will populate it concurrently. Exactly because we hold 
> the mmap_sem for writing.

Side note: I realize that a filesystem could add its own lock, but that 
doesn't _help_ anything. In that case, it needs to take the lock while 
under the mmap_sem, and release it later in the "post-mmap-sem" callback, 
but not only is that ugly, it means that there is a mmap_sem -> newlock 
dependency between the two, which means that any lock dependency of code 
that runs under the new lock will not really have changed. You might as 
well have run it under the mmap_lock to begin with.

That's why I claim it's buggy. 

I'm sure you can do clever things for special cases, but it all sounds 
like you really need to fix the lockdep chain some way.

If you absolutely have to do the revalidation at mmap() time, then the 
lock chain needs to be broken somewhere else. Since this is a filesystem, 
and mmap_sem is involved, I can only assume that the other part of the 
chain is "readdir()" as usual.

See the whole sysfs discussion about that (look for sysfs and filldir on 
the kernel list a week or two ago).

		Linus

^ permalink raw reply	[flat|nested] 82+ messages in thread

* Re: [GIT PULL] Please pull NFS client bugfixes....
  2010-01-08  1:12             ` Linus Torvalds
@ 2010-01-08  1:22               ` Trond Myklebust
  2010-01-08  1:26                 ` Trond Myklebust
  2010-01-08  1:30                 ` Linus Torvalds
  2010-01-08  1:22               ` Linus Torvalds
  1 sibling, 2 replies; 82+ messages in thread
From: Trond Myklebust @ 2010-01-08  1:22 UTC (permalink / raw)
  To: Linus Torvalds; +Cc: Andi Kleen, linux-kernel

On Thu, 2010-01-07 at 17:12 -0800, Linus Torvalds wrote: 
> 
> On Thu, 7 Jan 2010, Trond Myklebust wrote:
> > > 
> > > Because it means that you can trivially take page faults before the thing 
> > > is validated (think threads).
> > 
> > Which would mean that another process/thread already has part of the
> > file mmapped on the same client. I'm not arguing that have to revalidate
> > in _that_ case.
> 
> No, I'm talking about the new mapping. Nothing else.
> 
> If the mmap'ing thread releases mmap_sem, and then does the revalidate, 
> then you can have
> 
> 	thread1				thread2
> 	-------				-------
> 
> 	mmap
> 	map it in
> 	release mmap_sem
> 					page-fault the mapping before it got validated
> 	->post_mmap()
> 	revalidate outside mmap_sem
> 
> See? No "already part of the file mmapped" case at all. The exact mmap 
> that you just set up - without the revalidation having happened.
> 
> In fact, because of this kind of _fundamental_ race, I don't see why I 
> would ever accept any patches that add multiple mmap() down-calls at 
> different phases to the filesystem at the VFS layer.
> 
> A filesystem that depends on the different phases would be a fundamentally 
> buggy filesystem. Right now mmap is "atomic", and you can pre-populate (or 
> pre-verify, like NFS does) the mapping in the _knowledge_ that there are 
> no page faults that will populate it concurrently. Exactly because we hold 
> the mmap_sem for writing.

I don't think anyone has been advocating doing the revalidation _after_
the call to mmap_region(). All I want is to be able to do it as part of
the mmap() syscall. It would be quite OK to add a ->pre_mmap() (which is
what I believe Peter's patches do).

All I want to ensure is that people who use non-posix-lock based
synchronisation can set the 'noac' flag, and be assured that if mmap()
is called _after_ they have grabbed their lock, then the page cache will
be duly revalidated (under the lock), and the fresh data will be made
available.

Trond

^ permalink raw reply	[flat|nested] 82+ messages in thread

* Re: [GIT PULL] Please pull NFS client bugfixes....
  2010-01-08  1:03           ` Trond Myklebust
@ 2010-01-08  1:12             ` Linus Torvalds
  2010-01-08  1:22               ` Trond Myklebust
  2010-01-08  1:22               ` Linus Torvalds
  0 siblings, 2 replies; 82+ messages in thread
From: Linus Torvalds @ 2010-01-08  1:12 UTC (permalink / raw)
  To: Trond Myklebust; +Cc: Andi Kleen, linux-kernel



On Thu, 7 Jan 2010, Trond Myklebust wrote:
> > 
> > Because it means that you can trivially take page faults before the thing 
> > is validated (think threads).
> 
> Which would mean that another process/thread already has part of the
> file mmapped on the same client. I'm not arguing that have to revalidate
> in _that_ case.

No, I'm talking about the new mapping. Nothing else.

If the mmap'ing thread releases mmap_sem, and then does the revalidate, 
then you can have

	thread1				thread2
	-------				-------

	mmap
	map it in
	release mmap_sem
					page-fault the mapping before it got validated
	->post_mmap()
	revalidate outside mmap_sem

See? No "already part of the file mmapped" case at all. The exact mmap 
that you just set up - without the revalidation having happened.

In fact, because of this kind of _fundamental_ race, I don't see why I 
would ever accept any patches that add multiple mmap() down-calls at 
different phases to the filesystem at the VFS layer.

A filesystem that depends on the different phases would be a fundamentally 
buggy filesystem. Right now mmap is "atomic", and you can pre-populate (or 
pre-verify, like NFS does) the mapping in the _knowledge_ that there are 
no page faults that will populate it concurrently. Exactly because we hold 
the mmap_sem for writing.

				Linus

^ permalink raw reply	[flat|nested] 82+ messages in thread

* Re: [GIT PULL] Please pull NFS client bugfixes....
  2010-01-08  0:45           ` Andi Kleen
@ 2010-01-08  1:03             ` Trond Myklebust
  0 siblings, 0 replies; 82+ messages in thread
From: Trond Myklebust @ 2010-01-08  1:03 UTC (permalink / raw)
  To: Andi Kleen; +Cc: Linus Torvalds, linux-kernel

On Fri, 2010-01-08 at 01:45 +0100, Andi Kleen wrote: 
> > If that is ok, then why do the revalidate at all? Just do the open/close 
> > consistency and validate at open time, not mmap time.
> 
> That's exactly what my patch does :)

Actually, it doesn't....

It does remove the validation at mmap time, but it adds nothing at open
time to ensure that we call nfs_revalidate_mapping().

...and as I said, it breaks 'noac'.

Trond

^ permalink raw reply	[flat|nested] 82+ messages in thread

* Re: [GIT PULL] Please pull NFS client bugfixes....
  2010-01-08  0:34         ` Linus Torvalds
  2010-01-08  0:45           ` Andi Kleen
@ 2010-01-08  1:03           ` Trond Myklebust
  2010-01-08  1:12             ` Linus Torvalds
  1 sibling, 1 reply; 82+ messages in thread
From: Trond Myklebust @ 2010-01-08  1:03 UTC (permalink / raw)
  To: Linus Torvalds; +Cc: Andi Kleen, linux-kernel

On Thu, 2010-01-07 at 16:34 -0800, Linus Torvalds wrote: 
> 
> On Thu, 7 Jan 2010, Trond Myklebust wrote:
> > 
> > Yes. I want to pursue Peter Zijlstra's patches, which split up the mmap
> > function into a set of parts which require the mmap_sem, and other parts
> > which don't, and that adds a filesystem callback that allows for
> > revalidation to occur outside the mmap_sem.
> 
> I'm sorry, but that just sounds STUPID.
> 
> Why?
> 
> Because it means that you can trivially take page faults before the thing 
> is validated (think threads).

Which would mean that another process/thread already has part of the
file mmapped on the same client. I'm not arguing that have to revalidate
in _that_ case.

> If that is ok, then why do the revalidate at all? Just do the open/close 
> consistency and validate at open time, not mmap time.

That violates the expected semantics of the 'noac' mount option.

Trond

^ permalink raw reply	[flat|nested] 82+ messages in thread

* Re: [GIT PULL] Please pull NFS client bugfixes....
  2010-01-08  0:34         ` Linus Torvalds
@ 2010-01-08  0:45           ` Andi Kleen
  2010-01-08  1:03             ` Trond Myklebust
  2010-01-08  1:03           ` Trond Myklebust
  1 sibling, 1 reply; 82+ messages in thread
From: Andi Kleen @ 2010-01-08  0:45 UTC (permalink / raw)
  To: Linus Torvalds; +Cc: Trond Myklebust, Andi Kleen, linux-kernel

> If that is ok, then why do the revalidate at all? Just do the open/close 
> consistency and validate at open time, not mmap time.

That's exactly what my patch does :)

-Andi

---


NFS: don't revalidate in mmap v2

nfs_revalidate_mapping takes i_mutex, but mmap already has mmap_sem
and taking i_mutex inside mmap_sem is not allowed by the VFS.

So don't revalidate on mmap time. In theory users could
rely on it, but it's unlikely enough for mmap.

This fixes a lockdep warning that happens at every boot
on my nfsroot test system.

v2: Fix unused variable warning, add comment

Signed-off-by: Andi Kleen <ak@linux.intel.com>

---
 fs/nfs/file.c |   14 +++++++-------
 1 file changed, 7 insertions(+), 7 deletions(-)

Index: linux/fs/nfs/file.c
===================================================================
--- linux.orig/fs/nfs/file.c
+++ linux/fs/nfs/file.c
@@ -291,20 +291,20 @@ static int
 nfs_file_mmap(struct file * file, struct vm_area_struct * vma)
 {
 	struct dentry *dentry = file->f_path.dentry;
-	struct inode *inode = dentry->d_inode;
 	int	status;
 
 	dprintk("NFS: mmap(%s/%s)\n",
 		dentry->d_parent->d_name.name, dentry->d_name.name);
 
-	/* Note: generic_file_mmap() returns ENOSYS on nommu systems
-	 *       so we call that before revalidating the mapping
-	 */
 	status = generic_file_mmap(file, vma);
-	if (!status) {
+	/*
+	 * This used to be a synchronization point,
+	 * but this causes lock order inversions with i_mutex / mmap_sem.
+	 * It's unclear anyone relies on mmap being a synchronization
+	 * point anyways, so just removed it here -AK
+	 */
+	if (!status)
 		vma->vm_ops = &nfs_file_vm_ops;
-		status = nfs_revalidate_mapping(inode, file->f_mapping);
-	}
 	return status;
 }
 

-- 
ak@linux.intel.com -- Speaking for myself only.

^ permalink raw reply	[flat|nested] 82+ messages in thread

* Re: [GIT PULL] Please pull NFS client bugfixes....
  2010-01-08  0:14       ` Trond Myklebust
  2010-01-08  0:34         ` Linus Torvalds
@ 2010-01-08  0:43         ` Andi Kleen
  1 sibling, 0 replies; 82+ messages in thread
From: Andi Kleen @ 2010-01-08  0:43 UTC (permalink / raw)
  To: Trond Myklebust; +Cc: Andi Kleen, linux-kernel, torvalds

On Thu, Jan 07, 2010 at 07:14:42PM -0500, Trond Myklebust wrote:
> On Fri, 2010-01-08 at 00:51 +0100, Andi Kleen wrote: 
> > > I'd like to see this fixed, but I do not want to jump onto a solution
> > > that changes the behaviour of mmap() w.r.t. revalidation. The current
> > > behaviour dates back at least to 2.3.x if not before.
> > 
> > So do you have a plan to fix it?
> 
> Yes. I want to pursue Peter Zijlstra's patches, which split up the mmap
> function into a set of parts which require the mmap_sem, and other parts
> which don't, and that adds a filesystem callback that allows for
> revalidation to occur outside the mmap_sem.

Is that really a 2.6.33 solution?

It sounds intrusive.

> 
> > I don't think it'll be possible to do drastic changes in the
> > VFS for 2.6.33, and it seems preserving the current semantics
> > would need that.
> > 
> > > That's why I'm working slowly on this.
> > 
> > Delaying a fix to after 2.6.33 is not an option imho.
> > 
> > It hits everyone with LOCKDEP enabled who uses mmap over NFS.
> > That's new in 2.6.33, previously LOCKDEP didn't diagnose this.
> > 
> > I'll keep using my patch, but I suppose once we're going more
> > towards a release you'll get more reports of this.
> 
> Why should this particular issue require us to rush into a solution?

Because every lockdep user NFS+mmap gets spammed now.

That's like having an oops in the startup sequence. The system
might still boot, but users are not happy.

> This has been there for literally _years_, and I've never heard of a
> single incident in which a deadlock actually occurred. The only reason
> why we've noticed it at all is because lockdep has started to whine.

I bet there were deadlocks somewhere, probably just didn't get reported.

-Andi
-- 
ak@linux.intel.com -- Speaking for myself only.

^ permalink raw reply	[flat|nested] 82+ messages in thread

* Re: [GIT PULL] Please pull NFS client bugfixes....
  2010-01-08  0:14       ` Trond Myklebust
@ 2010-01-08  0:34         ` Linus Torvalds
  2010-01-08  0:45           ` Andi Kleen
  2010-01-08  1:03           ` Trond Myklebust
  2010-01-08  0:43         ` Andi Kleen
  1 sibling, 2 replies; 82+ messages in thread
From: Linus Torvalds @ 2010-01-08  0:34 UTC (permalink / raw)
  To: Trond Myklebust; +Cc: Andi Kleen, linux-kernel



On Thu, 7 Jan 2010, Trond Myklebust wrote:
> 
> Yes. I want to pursue Peter Zijlstra's patches, which split up the mmap
> function into a set of parts which require the mmap_sem, and other parts
> which don't, and that adds a filesystem callback that allows for
> revalidation to occur outside the mmap_sem.

I'm sorry, but that just sounds STUPID.

Why?

Because it means that you can trivially take page faults before the thing 
is validated (think threads).

If that is ok, then why do the revalidate at all? Just do the open/close 
consistency and validate at open time, not mmap time.

		Linus

^ permalink raw reply	[flat|nested] 82+ messages in thread

* Re: [GIT PULL] Please pull NFS client bugfixes....
  2010-01-07 23:51     ` Andi Kleen
@ 2010-01-08  0:14       ` Trond Myklebust
  2010-01-08  0:34         ` Linus Torvalds
  2010-01-08  0:43         ` Andi Kleen
  0 siblings, 2 replies; 82+ messages in thread
From: Trond Myklebust @ 2010-01-08  0:14 UTC (permalink / raw)
  To: Andi Kleen; +Cc: linux-kernel, torvalds

On Fri, 2010-01-08 at 00:51 +0100, Andi Kleen wrote: 
> > I'd like to see this fixed, but I do not want to jump onto a solution
> > that changes the behaviour of mmap() w.r.t. revalidation. The current
> > behaviour dates back at least to 2.3.x if not before.
> 
> So do you have a plan to fix it?

Yes. I want to pursue Peter Zijlstra's patches, which split up the mmap
function into a set of parts which require the mmap_sem, and other parts
which don't, and that adds a filesystem callback that allows for
revalidation to occur outside the mmap_sem.

> I don't think it'll be possible to do drastic changes in the
> VFS for 2.6.33, and it seems preserving the current semantics
> would need that.
> 
> > That's why I'm working slowly on this.
> 
> Delaying a fix to after 2.6.33 is not an option imho.
> 
> It hits everyone with LOCKDEP enabled who uses mmap over NFS.
> That's new in 2.6.33, previously LOCKDEP didn't diagnose this.
> 
> I'll keep using my patch, but I suppose once we're going more
> towards a release you'll get more reports of this.

Why should this particular issue require us to rush into a solution?
This has been there for literally _years_, and I've never heard of a
single incident in which a deadlock actually occurred. The only reason
why we've noticed it at all is because lockdep has started to whine.

I agree it should be fixed.

I don't agree that it is urgent enough to warrant kneejerk reactions in
2.6.33 which change long established behaviours that people are actually
relying on.

  Trond

^ permalink raw reply	[flat|nested] 82+ messages in thread

* Re: [GIT PULL] Please pull NFS client bugfixes....
  2010-01-07 21:53   ` Trond Myklebust
@ 2010-01-07 23:51     ` Andi Kleen
  2010-01-08  0:14       ` Trond Myklebust
  0 siblings, 1 reply; 82+ messages in thread
From: Andi Kleen @ 2010-01-07 23:51 UTC (permalink / raw)
  To: Trond Myklebust; +Cc: Andi Kleen, linux-kernel, torvalds

> I'd like to see this fixed, but I do not want to jump onto a solution
> that changes the behaviour of mmap() w.r.t. revalidation. The current
> behaviour dates back at least to 2.3.x if not before.

So do you have a plan to fix it?

I don't think it'll be possible to do drastic changes in the
VFS for 2.6.33, and it seems preserving the current semantics
would need that.

> That's why I'm working slowly on this.

Delaying a fix to after 2.6.33 is not an option imho.

It hits everyone with LOCKDEP enabled who uses mmap over NFS.
That's new in 2.6.33, previously LOCKDEP didn't diagnose this.

I'll keep using my patch, but I suppose once we're going more
towards a release you'll get more reports of this.

-Andi
-- 
ak@linux.intel.com -- Speaking for myself only.

^ permalink raw reply	[flat|nested] 82+ messages in thread

* Re: [GIT PULL] Please pull NFS client bugfixes....
  2010-01-07 21:00 ` Andi Kleen
  2010-01-07 21:23   ` Peter Staubach
@ 2010-01-07 21:53   ` Trond Myklebust
  2010-01-07 23:51     ` Andi Kleen
  1 sibling, 1 reply; 82+ messages in thread
From: Trond Myklebust @ 2010-01-07 21:53 UTC (permalink / raw)
  To: Andi Kleen; +Cc: linux-kernel, torvalds

On Thu, 2010-01-07 at 22:00 +0100, Andi Kleen wrote: 
> > Hi Linus,
> >
> > Please pull from the "bugfixes" branch of the repository at
> >
> >    git pull git://git.linux-nfs.org/projects/trondmy/nfs-2.6.git bugfixes
> >
> > This will update the following files through the appended changesets.
> 
> How about the mmap lock order inversion patch?
> 
> That problem is still there and hits immediately after mounting root 
> with a lockdep warning on any lockdep enabled NFS root kernel.

I'd like to see this fixed, but I do not want to jump onto a solution
that changes the behaviour of mmap() w.r.t. revalidation. The current
behaviour dates back at least to 2.3.x if not before.

That's why I'm working slowly on this.

Cheers
  Trond

^ permalink raw reply	[flat|nested] 82+ messages in thread

* Re: [GIT PULL] Please pull NFS client bugfixes....
  2010-01-07 21:23   ` Peter Staubach
@ 2010-01-07 21:35     ` Andi Kleen
  0 siblings, 0 replies; 82+ messages in thread
From: Andi Kleen @ 2010-01-07 21:35 UTC (permalink / raw)
  To: Peter Staubach; +Cc: Andi Kleen, Trond.Myklebust, linux-kernel, torvalds

On Thu, Jan 07, 2010 at 04:23:22PM -0500, Peter Staubach wrote:
> It seems to me that NFS must do some sort of validation at
> this point.  This is one of the last points where the NFS
> client can do validation for mmap'd files.

Typically there is a open directly before it. open seems
like a much more natural point to synchronize than mmap.

Also so far nobody could point me to a standard text or similar
who said mmap needs synchronization, just some vague beliefs.

And the fact is right now with the current Linux VFS and
NFS locking mmap can't do it reliably.

> I think that the file system must have a way to do validation
> and page invalidation during mmap.  Perhaps we can reorder
> things or add another entry point which is invoked after the
> page mapping is set up which would give the file system to
> check to ensure that the page cache is filled with valid data.

If someone has a better patch feel free to post it, but ignoring
the problem like it has been done so far doesn't fly.

I know that my patch works for me at least.

-Andi


^ permalink raw reply	[flat|nested] 82+ messages in thread

* Re: [GIT PULL] Please pull NFS client bugfixes....
  2010-01-07 21:00 ` Andi Kleen
@ 2010-01-07 21:23   ` Peter Staubach
  2010-01-07 21:35     ` Andi Kleen
  2010-01-07 21:53   ` Trond Myklebust
  1 sibling, 1 reply; 82+ messages in thread
From: Peter Staubach @ 2010-01-07 21:23 UTC (permalink / raw)
  To: Andi Kleen; +Cc: Trond.Myklebust, linux-kernel, torvalds

Andi Kleen wrote:
>> Hi Linus,
>>
>> Please pull from the "bugfixes" branch of the repository at
>>
>>    git pull git://git.linux-nfs.org/projects/trondmy/nfs-2.6.git bugfixes
>>
>> This will update the following files through the appended changesets.
> 
> How about the mmap lock order inversion patch?
> 
> That problem is still there and hits immediately after mounting root 
> with a lockdep warning on any lockdep enabled NFS root kernel.
> 

It seems to me that NFS must do some sort of validation at
this point.  This is one of the last points where the NFS
client can do validation for mmap'd files.

Simply crossing our fingers probably won't be sufficient.  :-)

I think that the file system must have a way to do validation
and page invalidation during mmap.  Perhaps we can reorder
things or add another entry point which is invoked after the
page mapping is set up which would give the file system to
check to ensure that the page cache is filled with valid data.

		ps

> -Andi
> 
> ---
> 
> NFS: don't revalidate in mmap
> 
> nfs_revalidate_mapping takes i_mutex, but mmap already has mmap_sem
> hold and taking i_mutex inside mmap_sem is not allowed by the VFS.
> 
> So don't revalidate on mmap time and trust it has been already done.
> 
> Signed-off-by: Andi Kleen <ak@linux.intel.com>
> 
> ---
>  fs/nfs/file.c |    7 +------
>  1 file changed, 1 insertion(+), 6 deletions(-)
> 
> Index: linux-2.6.32-ak/fs/nfs/file.c
> ===================================================================
> --- linux-2.6.32-ak.orig/fs/nfs/file.c
> +++ linux-2.6.32-ak/fs/nfs/file.c
> @@ -297,14 +297,9 @@ nfs_file_mmap(struct file * file, struct
>  	dprintk("NFS: mmap(%s/%s)\n",
>  		dentry->d_parent->d_name.name, dentry->d_name.name);
>  
> -	/* Note: generic_file_mmap() returns ENOSYS on nommu systems
> -	 *       so we call that before revalidating the mapping
> -	 */
>  	status = generic_file_mmap(file, vma);
> -	if (!status) {
> +	if (!status)
>  		vma->vm_ops = &nfs_file_vm_ops;
> -		status = nfs_revalidate_mapping(inode, file->f_mapping);
> -	}
>  	return status;
>  }
>  
> 
> 


^ permalink raw reply	[flat|nested] 82+ messages in thread

* Re: [GIT PULL] Please pull NFS client bugfixes....
  2010-01-07 20:29 Trond Myklebust
@ 2010-01-07 21:00 ` Andi Kleen
  2010-01-07 21:23   ` Peter Staubach
  2010-01-07 21:53   ` Trond Myklebust
  0 siblings, 2 replies; 82+ messages in thread
From: Andi Kleen @ 2010-01-07 21:00 UTC (permalink / raw)
  To: Trond.Myklebust; +Cc: linux-kernel, torvalds


> Hi Linus,
>
> Please pull from the "bugfixes" branch of the repository at
>
>    git pull git://git.linux-nfs.org/projects/trondmy/nfs-2.6.git bugfixes
>
> This will update the following files through the appended changesets.

How about the mmap lock order inversion patch?

That problem is still there and hits immediately after mounting root 
with a lockdep warning on any lockdep enabled NFS root kernel.

-Andi

---

NFS: don't revalidate in mmap

nfs_revalidate_mapping takes i_mutex, but mmap already has mmap_sem
hold and taking i_mutex inside mmap_sem is not allowed by the VFS.

So don't revalidate on mmap time and trust it has been already done.

Signed-off-by: Andi Kleen <ak@linux.intel.com>

---
 fs/nfs/file.c |    7 +------
 1 file changed, 1 insertion(+), 6 deletions(-)

Index: linux-2.6.32-ak/fs/nfs/file.c
===================================================================
--- linux-2.6.32-ak.orig/fs/nfs/file.c
+++ linux-2.6.32-ak/fs/nfs/file.c
@@ -297,14 +297,9 @@ nfs_file_mmap(struct file * file, struct
 	dprintk("NFS: mmap(%s/%s)\n",
 		dentry->d_parent->d_name.name, dentry->d_name.name);
 
-	/* Note: generic_file_mmap() returns ENOSYS on nommu systems
-	 *       so we call that before revalidating the mapping
-	 */
 	status = generic_file_mmap(file, vma);
-	if (!status) {
+	if (!status)
 		vma->vm_ops = &nfs_file_vm_ops;
-		status = nfs_revalidate_mapping(inode, file->f_mapping);
-	}
 	return status;
 }
 


-- 
ak@linux.intel.com -- Speaking for myself only.

^ permalink raw reply	[flat|nested] 82+ messages in thread

* [GIT PULL] Please pull NFS client bugfixes....
@ 2010-01-07 20:29 Trond Myklebust
  2010-01-07 21:00 ` Andi Kleen
  0 siblings, 1 reply; 82+ messages in thread
From: Trond Myklebust @ 2010-01-07 20:29 UTC (permalink / raw)
  To: Linus Torvalds
  Cc: linux-nfs, linux-kernel, OGAWA Hirofumi, Marvin, Andrew Morton,
	Randy Dunlap, Jeff Layton

Hi Linus,

Please pull from the "bugfixes" branch of the repository at

   git pull git://git.linux-nfs.org/projects/trondmy/nfs-2.6.git bugfixes

This will update the following files through the appended changesets.

  Cheers,
    Trond

----
 fs/nfs/dir.c                          |    1 +
 net/sunrpc/auth_gss/auth_gss.c        |   17 ++++++++++++++++-
 net/sunrpc/auth_gss/gss_krb5_mech.c   |    4 +++-
 net/sunrpc/auth_gss/gss_mech_switch.c |    2 +-
 4 files changed, 21 insertions(+), 3 deletions(-)

commit 56335936de1a41c8978fde62b2158af77ddc7258
Author: OGAWA Hirofumi <hirofumi@mail.parknet.co.jp>
Date:   Wed Jan 6 18:48:26 2010 -0500

    nfs: fix oops in nfs_rename()
    
    Recent change is missing to update "rehash".  With that change, it will
    become the cause of adding dentry to hash twice.
    
    This explains the reason of Oops (dereference the freed dentry in
    __d_lookup()) on my machine.
    
    Signed-off-by: OGAWA Hirofumi <hirofumi@mail.parknet.co.jp>
    Reported-by: Marvin <marvin24@gmx.de>
    Cc: Trond Myklebust <trond.myklebust@fys.uio.no>
    Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
    Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>

commit 6c8530993e1fdf1d6af0403e796fe14d80b4b097
Author: Randy Dunlap <randy.dunlap@oracle.com>
Date:   Wed Jan 6 17:26:27 2010 -0500

    sunrpc: fix build-time warning
    
    Fix auth_gss printk format warning:
    
    net/sunrpc/auth_gss/auth_gss.c:660: warning: format '%ld' expects type 'long int', but argument 3 has type 'ssize_t'
    
    Signed-off-by: Randy Dunlap <randy.dunlap@oracle.com>
    Acked-by: Jeff Layton <jlayton@redhat.com>
    Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>

commit 486bad2e40e938cd68fd853b7a9fa3115a9d3a4a
Author: Jeff Layton <jlayton@redhat.com>
Date:   Fri Dec 18 16:28:20 2009 -0500

    sunrpc: on successful gss error pipe write, don't return error
    
    When handling the gssd downcall, the kernel should distinguish between a
    successful downcall that contains an error code and a failed downcall
    (i.e. where the parsing failed or some other sort of problem occurred).
    
    In the former case, gss_pipe_downcall should be returning the number of
    bytes written to the pipe instead of an error. In the event of other
    errors, we generally want the initiating task to retry the upcall so
    we set msg.errno to -EAGAIN. An unexpected error code here is a bug
    however, so BUG() in that case.
    
    Signed-off-by: Jeff Layton <jlayton@redhat.com>
    Cc: stable@kernel.org
    Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>

commit b891e4a05ef6beac85465295a032431577c66b16
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date:   Fri Dec 18 16:28:12 2009 -0500

    SUNRPC: Fix the return value in gss_import_sec_context()
    
    If the context allocation fails, it will return GSS_S_FAILURE, which is
    neither a valid error code, nor is it even negative.
    
    Return ENOMEM instead...
    
    Reported-by: Jeff Layton <jlayton@redhat.com>
    Cc: stable@kernel.org
    Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>

commit 14ace024b1e16d2bb9445c8387494fbbd820a738
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date:   Fri Dec 18 16:28:05 2009 -0500

    SUNRPC: Fix up an error return value in gss_import_sec_context_kerberos()
    
    If the context allocation fails, the function currently returns a random
    error code, since the variable 'p' still points to a valid memory location.
    
    Ensure that it returns ENOMEM...
    
    Cc: stable@kernel.org
    Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>

diff --git a/fs/nfs/dir.c b/fs/nfs/dir.c
index 2c5ace4..3c7f03b 100644
--- a/fs/nfs/dir.c
+++ b/fs/nfs/dir.c
@@ -1615,6 +1615,7 @@ static int nfs_rename(struct inode *old_dir, struct dentry *old_dentry,
 				goto out;
 
 			new_dentry = dentry;
+			rehash = NULL;
 			new_inode = NULL;
 		}
 	}
diff --git a/net/sunrpc/auth_gss/auth_gss.c b/net/sunrpc/auth_gss/auth_gss.c
index 3c3c50f..f7a7f83 100644
--- a/net/sunrpc/auth_gss/auth_gss.c
+++ b/net/sunrpc/auth_gss/auth_gss.c
@@ -644,7 +644,22 @@ gss_pipe_downcall(struct file *filp, const char __user *src, size_t mlen)
 	p = gss_fill_context(p, end, ctx, gss_msg->auth->mech);
 	if (IS_ERR(p)) {
 		err = PTR_ERR(p);
-		gss_msg->msg.errno = (err == -EAGAIN) ? -EAGAIN : -EACCES;
+		switch (err) {
+		case -EACCES:
+			gss_msg->msg.errno = err;
+			err = mlen;
+			break;
+		case -EFAULT:
+		case -ENOMEM:
+		case -EINVAL:
+		case -ENOSYS:
+			gss_msg->msg.errno = -EAGAIN;
+			break;
+		default:
+			printk(KERN_CRIT "%s: bad return from "
+				"gss_fill_context: %zd\n", __func__, err);
+			BUG();
+		}
 		goto err_release_msg;
 	}
 	gss_msg->ctx = gss_get_ctx(ctx);
diff --git a/net/sunrpc/auth_gss/gss_krb5_mech.c b/net/sunrpc/auth_gss/gss_krb5_mech.c
index ef45eba..2deb0ed 100644
--- a/net/sunrpc/auth_gss/gss_krb5_mech.c
+++ b/net/sunrpc/auth_gss/gss_krb5_mech.c
@@ -131,8 +131,10 @@ gss_import_sec_context_kerberos(const void *p,
 	struct	krb5_ctx *ctx;
 	int tmp;
 
-	if (!(ctx = kzalloc(sizeof(*ctx), GFP_NOFS)))
+	if (!(ctx = kzalloc(sizeof(*ctx), GFP_NOFS))) {
+		p = ERR_PTR(-ENOMEM);
 		goto out_err;
+	}
 
 	p = simple_get_bytes(p, end, &ctx->initiate, sizeof(ctx->initiate));
 	if (IS_ERR(p))
diff --git a/net/sunrpc/auth_gss/gss_mech_switch.c b/net/sunrpc/auth_gss/gss_mech_switch.c
index 6efbb0c..76e4c6f 100644
--- a/net/sunrpc/auth_gss/gss_mech_switch.c
+++ b/net/sunrpc/auth_gss/gss_mech_switch.c
@@ -252,7 +252,7 @@ gss_import_sec_context(const void *input_token, size_t bufsize,
 		       struct gss_ctx		**ctx_id)
 {
 	if (!(*ctx_id = kzalloc(sizeof(**ctx_id), GFP_KERNEL)))
-		return GSS_S_FAILURE;
+		return -ENOMEM;
 	(*ctx_id)->mech_type = gss_mech_get(mech);
 
 	return mech->gm_ops


^ permalink raw reply	[flat|nested] 82+ messages in thread

* [GIT PULL] Please pull NFS client bugfixes
@ 2009-05-26 19:06 Trond Myklebust
  0 siblings, 0 replies; 82+ messages in thread
From: Trond Myklebust @ 2009-05-26 19:06 UTC (permalink / raw)
  To: Linus Torvalds
  Cc: linux-nfs, linux-kernel, Sam Ravnborg, Steven Whitehouse,
	Stephen Rothwell, Vu Pham, Tom Talpey

Hi Linus,

Please pull from the "bugfixes" branch of the repository at

   git pull git://git.linux-nfs.org/projects/trondmy/nfs-2.6.git bugfixes

This will update the following files through the appended changesets.

  Cheers,
    Trond

----
 fs/nfs/nfs4proc.c           |    9 +++------
 fs/nfs/nfsroot.c            |    2 +-
 net/sunrpc/xprtrdma/verbs.c |    3 ++-
 3 files changed, 6 insertions(+), 8 deletions(-)

commit 95baa25c7321eb8613246acbf61b97911cc748d3
Author: Trond Myklebust <Trond.Myklebust@netapp.com>
Date:   Tue May 26 14:51:00 2009 -0400

    NFSv4: Fix the case where NFSv4 renewal fails
    
    If the asynchronous lease renewal fails (usually due to a soft timeout),
    then we _must_ schedule state recovery in order to ensure that we don't
    lose the lease unnecessarily or, if the lease is already lost, that we
    recover the locking state promptly...
    
    Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>

commit d0367a508af9cf97beb202935bb9ad8883d30cd1
Author: Sam Ravnborg <sam@ravnborg.org>
Date:   Tue May 26 14:51:00 2009 -0400

    nfs: fix build error in nfsroot with initconst
    
    fix build error with latest kbuild adjustments to initconst.
    
    The commit a447c0932445f92ce6f4c1bd020f62c5097a7842 ("vfs: Use
    const for kernel parser table") changed:
    
        static match_table_t __initdata tokens = {
    to
        static match_table_t __initconst tokens = {
    
    But the missing const causes powerpc to fail with latest
    updates to __initconst like this:
    
    fs/nfs/nfsroot.c:400: error: __setup_str_nfs_root_setup causes a section type conflict
    fs/nfs/nfsroot.c:400: error: __setup_str_nfs_root_setup causes a section type conflict
    
    The bug is only present with kbuild-next.
    Following patch has been build tested.
    
    Signed-off-by: Sam Ravnborg <sam@ravnborg.org>
    Cc: Steven Whitehouse <swhiteho@redhat.com>
    Cc: Stephen Rothwell <sfr@canb.auug.org.au>
    Acked-by: Jan Beulich <jbeulich@novell.com>
    Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>

commit 68743082b560067e3e93eab8b2568f238e486865
Author: Vu Pham <vu@mellanox.com>
Date:   Tue May 26 14:51:00 2009 -0400

    XPRTRDMA: fix client rpcrdma FRMR registration on mlx4 devices
    
    mlx4/connectX FRMR requires local write enable together with remote
    rdma write enable. This fixes NFS/RDMA operation over the ConnectX
    Infiniband HCA in the default memreg mode.
    
    Signed-off-by: Vu Pham <vu@mellanox.com>
    Signed-off-by: Tom Talpey <tmtalpey@gmail.com>
    Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>

diff --git a/fs/nfs/nfs4proc.c b/fs/nfs/nfs4proc.c
index a4d2426..4674f80 100644
--- a/fs/nfs/nfs4proc.c
+++ b/fs/nfs/nfs4proc.c
@@ -2594,12 +2594,9 @@ static void nfs4_renew_done(struct rpc_task *task, void *data)
 	unsigned long timestamp = (unsigned long)data;
 
 	if (task->tk_status < 0) {
-		switch (task->tk_status) {
-			case -NFS4ERR_STALE_CLIENTID:
-			case -NFS4ERR_EXPIRED:
-			case -NFS4ERR_CB_PATH_DOWN:
-				nfs4_schedule_state_recovery(clp);
-		}
+		/* Unless we're shutting down, schedule state recovery! */
+		if (test_bit(NFS_CS_RENEWD, &clp->cl_res_state) != 0)
+			nfs4_schedule_state_recovery(clp);
 		return;
 	}
 	spin_lock(&clp->cl_lock);
diff --git a/fs/nfs/nfsroot.c b/fs/nfs/nfsroot.c
index d9ef602..e3ed590 100644
--- a/fs/nfs/nfsroot.c
+++ b/fs/nfs/nfsroot.c
@@ -129,7 +129,7 @@ enum {
 	Opt_err
 };
 
-static match_table_t __initconst tokens = {
+static const match_table_t tokens __initconst = {
 	{Opt_port, "port=%u"},
 	{Opt_rsize, "rsize=%u"},
 	{Opt_wsize, "wsize=%u"},
diff --git a/net/sunrpc/xprtrdma/verbs.c b/net/sunrpc/xprtrdma/verbs.c
index 3b21e0c..465aafc 100644
--- a/net/sunrpc/xprtrdma/verbs.c
+++ b/net/sunrpc/xprtrdma/verbs.c
@@ -1495,7 +1495,8 @@ rpcrdma_register_frmr_external(struct rpcrdma_mr_seg *seg,
 	frmr_wr.wr.fast_reg.page_shift = PAGE_SHIFT;
 	frmr_wr.wr.fast_reg.length = i << PAGE_SHIFT;
 	frmr_wr.wr.fast_reg.access_flags = (writing ?
-				IB_ACCESS_REMOTE_WRITE : IB_ACCESS_REMOTE_READ);
+				IB_ACCESS_REMOTE_WRITE | IB_ACCESS_LOCAL_WRITE :
+				IB_ACCESS_REMOTE_READ);
 	frmr_wr.wr.fast_reg.rkey = seg1->mr_chunk.rl_mw->r.frmr.fr_mr->rkey;
 	DECR_CQCOUNT(&r_xprt->rx_ep);
 

-- 
Trond Myklebust
Linux NFS client maintainer

NetApp
Trond.Myklebust@netapp.com
www.netapp.com

^ permalink raw reply	[flat|nested] 82+ messages in thread

end of thread, other threads:[~2021-01-12 18:01 UTC | newest]

Thread overview: 82+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2015-01-29 21:37 [GIT PULL] Please pull NFS client bugfixes Trond Myklebust
  -- strict thread matches above, loose matches on Subject: below --
2021-01-12 14:31 Trond Myklebust
2021-01-12 18:00 ` pr-tracker-bot
2020-09-28 17:27 Trond Myklebust
2020-09-28 18:16 ` pr-tracker-bot
2020-05-15 21:00 Trond Myklebust
2020-05-15 21:10 ` pr-tracker-bot
2020-05-02 13:35 Trond Myklebust
2020-05-02 18:45 ` pr-tracker-bot
2019-08-27 19:26 Trond Myklebust
2019-08-27 20:55 ` pr-tracker-bot
2019-08-08 21:26 Trond Myklebust
2019-08-09  1:30 ` pr-tracker-bot
2019-06-05 21:02 Schumaker, Anna
2019-04-13 14:56 Trond Myklebust
2019-04-13 22:00 ` pr-tracker-bot
2018-12-19 16:49 Trond Myklebust
2018-12-20  2:50 ` pr-tracker-bot
2018-12-20 15:23 ` Geert Uytterhoeven
2018-03-12 17:29 Trond Myklebust
2018-02-25 17:02 Trond Myklebust
2017-01-28 17:04 Trond Myklebust
2017-01-16 20:14 Trond Myklebust
2016-10-21 20:30 Anna Schumaker
2015-10-07  2:52 Trond Myklebust
2015-09-25 15:14 Trond Myklebust
2015-07-28 16:03 Trond Myklebust
2015-03-06  3:46 Trond Myklebust
2015-01-16 14:35 Trond Myklebust
2014-11-14 23:04 Trond Myklebust
2014-09-19 19:32 Trond Myklebust
2014-01-31 21:41 Trond Myklebust
2013-12-05 17:20 Trond Myklebust
2013-11-16 21:09 Myklebust, Trond
2013-09-30 22:02 Myklebust, Trond
2013-05-26 19:29 Myklebust, Trond
2013-03-26 18:26 Myklebust, Trond
2013-03-03  0:08 Myklebust, Trond
2013-02-21  3:38 Myklebust, Trond
2013-01-07 15:45 Myklebust, Trond
2012-11-03 19:48 Myklebust, Trond
2012-10-22 17:42 Myklebust, Trond
2012-09-12 19:19 Myklebust, Trond
2012-07-13 15:14 Myklebust, Trond
2012-05-02  3:57 Myklebust, Trond
2012-04-24 20:18 [GIT PULL] please " Myklebust, Trond
2011-12-20  6:15 [GIT PULL] Please " Trond Myklebust
2011-11-22 11:50 Trond Myklebust
2011-08-19  1:05 Trond Myklebust
2011-07-12 23:30 Trond Myklebust
2011-05-13 20:23 Trond Myklebust
2011-04-08 18:40 [GIT PULL] please " Trond Myklebust
2011-03-14 18:09 [GIT PULL] Please " Trond Myklebust
2010-11-26 18:56 Trond Myklebust
2010-05-26 19:42 Trond Myklebust
2010-05-07  2:22 Trond Myklebust
2010-04-29 16:48 Trond Myklebust
2010-03-23 17:00 Trond Myklebust
2010-03-17 21:55 Trond Myklebust
2010-02-04 19:10 Trond Myklebust
2010-01-07 20:29 Trond Myklebust
2010-01-07 21:00 ` Andi Kleen
2010-01-07 21:23   ` Peter Staubach
2010-01-07 21:35     ` Andi Kleen
2010-01-07 21:53   ` Trond Myklebust
2010-01-07 23:51     ` Andi Kleen
2010-01-08  0:14       ` Trond Myklebust
2010-01-08  0:34         ` Linus Torvalds
2010-01-08  0:45           ` Andi Kleen
2010-01-08  1:03             ` Trond Myklebust
2010-01-08  1:03           ` Trond Myklebust
2010-01-08  1:12             ` Linus Torvalds
2010-01-08  1:22               ` Trond Myklebust
2010-01-08  1:26                 ` Trond Myklebust
2010-01-08  1:30                 ` Linus Torvalds
2010-01-08  1:35                   ` Linus Torvalds
2010-01-08  2:00                     ` Linus Torvalds
2010-01-14 13:18                       ` Peter Zijlstra
2010-01-08  5:19                   ` Andi Kleen
2010-01-08  1:22               ` Linus Torvalds
2010-01-08  0:43         ` Andi Kleen
2009-05-26 19:06 Trond Myklebust

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).