1. 18 11月, 2017 14 次提交
  2. 17 10月, 2017 1 次提交
  3. 05 10月, 2017 1 次提交
    • T
      NFSv4/pnfs: Fix an infinite layoutget loop · e8fa33a6
      Trond Myklebust 提交于
      Since we can now use a lock stateid or a delegation stateid, that
      differs from the context stateid, we need to change the test in
      nfs4_layoutget_handle_exception() to take this into account.
      
      This fixes an infinite layoutget loop in the NFS client whereby
      it keeps retrying the initial layoutget using the same broken
      stateid.
      
      Fixes: 70d2f7b1 ("pNFS: Use the standard I/O stateid when...")
      Signed-off-by: NTrond Myklebust <trond.myklebust@primarydata.com>
      e8fa33a6
  4. 07 9月, 2017 1 次提交
  5. 14 8月, 2017 2 次提交
  6. 10 8月, 2017 1 次提交
  7. 07 8月, 2017 3 次提交
  8. 02 8月, 2017 2 次提交
  9. 29 7月, 2017 1 次提交
    • B
      NFSv4.1: Fix a race where CB_NOTIFY_LOCK fails to wake a waiter · b7dbcc0e
      Benjamin Coddington 提交于
      nfs4_retry_setlk() sets the task's state to TASK_INTERRUPTIBLE within the
      same region protected by the wait_queue's lock after checking for a
      notification from CB_NOTIFY_LOCK callback.  However, after releasing that
      lock, a wakeup for that task may race in before the call to
      freezable_schedule_timeout_interruptible() and set TASK_WAKING, then
      freezable_schedule_timeout_interruptible() will set the state back to
      TASK_INTERRUPTIBLE before the task will sleep.  The result is that the task
      will sleep for the entire duration of the timeout.
      
      Since we've already set TASK_INTERRUPTIBLE in the locked section, just use
      freezable_schedule_timout() instead.
      
      Fixes: a1d617d8 ("nfs: allow blocking locks to be awoken by lock callbacks")
      Signed-off-by: NBenjamin Coddington <bcodding@redhat.com>
      Reviewed-by: NJeff Layton <jlayton@redhat.com>
      Cc: stable@vger.kernel.org # v4.9+
      Signed-off-by: NAnna Schumaker <Anna.Schumaker@Netapp.com>
      b7dbcc0e
  10. 27 7月, 2017 1 次提交
  11. 14 7月, 2017 4 次提交
  12. 28 6月, 2017 1 次提交
    • T
      NFSv4.1: Fix a race in nfs4_proc_layoutget · bd171930
      Trond Myklebust 提交于
      If the task calling layoutget is signalled, then it is possible for the
      calls to nfs4_sequence_free_slot() and nfs4_layoutget_prepare() to race,
      in which case we leak a slot.
      The fix is to move the call to nfs4_sequence_free_slot() into the
      nfs4_layoutget_release() so that it gets called at task teardown time.
      
      Fixes: 2e80dbe7 ("NFSv4.1: Close callback races for OPEN, LAYOUTGET...")
      Cc: stable@vger.kernel.org # v4.8+
      Signed-off-by: NTrond Myklebust <trond.myklebust@primarydata.com>
      bd171930
  13. 20 6月, 2017 1 次提交
    • I
      sched/wait: Rename wait_queue_t => wait_queue_entry_t · ac6424b9
      Ingo Molnar 提交于
      Rename:
      
      	wait_queue_t		=>	wait_queue_entry_t
      
      'wait_queue_t' was always a slight misnomer: its name implies that it's a "queue",
      but in reality it's a queue *entry*. The 'real' queue is the wait queue head,
      which had to carry the name.
      
      Start sorting this out by renaming it to 'wait_queue_entry_t'.
      
      This also allows the real structure name 'struct __wait_queue' to
      lose its double underscore and become 'struct wait_queue_entry',
      which is the more canonical nomenclature for such data types.
      
      Cc: Linus Torvalds <torvalds@linux-foundation.org>
      Cc: Peter Zijlstra <peterz@infradead.org>
      Cc: Thomas Gleixner <tglx@linutronix.de>
      Cc: linux-kernel@vger.kernel.org
      Signed-off-by: NIngo Molnar <mingo@kernel.org>
      ac6424b9
  14. 06 6月, 2017 1 次提交
  15. 10 5月, 2017 1 次提交
  16. 06 5月, 2017 2 次提交
  17. 29 4月, 2017 2 次提交
  18. 21 4月, 2017 1 次提交
    • B
      NFS: Always wait for I/O completion before unlock · f30cb757
      Benjamin Coddington 提交于
      NFS attempts to wait for read and write completion before unlocking in
      order to ensure that the data returned was protected by the lock.  When
      this waiting is interrupted by a signal, the unlock may be skipped, and
      messages similar to the following are seen in the kernel ring buffer:
      
      [20.167876] Leaked locks on dev=0x0:0x2b ino=0x8dd4c3:
      [20.168286] POSIX: fl_owner=ffff880078b06940 fl_flags=0x1 fl_type=0x0 fl_pid=20183
      [20.168727] POSIX: fl_owner=ffff880078b06680 fl_flags=0x1 fl_type=0x0 fl_pid=20185
      
      For NFSv3, the missing unlock will cause the server to refuse conflicting
      locks indefinitely.  For NFSv4, the leftover lock will be removed by the
      server after the lease timeout.
      
      This patch fixes this issue by skipping the usual wait in
      nfs_iocounter_wait if the FL_CLOSE flag is set when signaled.  Instead, the
      wait happens in the unlock RPC task on the NFS UOC rpc_waitqueue.
      
      For NFSv3, use lockd's new nlmclnt_operations along with
      nfs_async_iocounter_wait to defer NLM's unlock task until the lock
      context's iocounter reaches zero.
      
      For NFSv4, call nfs_async_iocounter_wait() directly from unlock's
      current rpc_call_prepare.
      Signed-off-by: NBenjamin Coddington <bcodding@redhat.com>
      Reviewed-by: NJeff Layton <jlayton@redhat.com>
      Signed-off-by: NTrond Myklebust <trond.myklebust@primarydata.com>
      f30cb757