1. 31 7月, 2012 3 次提交
    • J
      nfs: skip commit in releasepage if we're freeing memory for fs-related reasons · 5cf02d09
      Jeff Layton 提交于
      We've had some reports of a deadlock where rpciod ends up with a stack
      trace like this:
      
          PID: 2507   TASK: ffff88103691ab40  CPU: 14  COMMAND: "rpciod/14"
           #0 [ffff8810343bf2f0] schedule at ffffffff814dabd9
           #1 [ffff8810343bf3b8] nfs_wait_bit_killable at ffffffffa038fc04 [nfs]
           #2 [ffff8810343bf3c8] __wait_on_bit at ffffffff814dbc2f
           #3 [ffff8810343bf418] out_of_line_wait_on_bit at ffffffff814dbcd8
           #4 [ffff8810343bf488] nfs_commit_inode at ffffffffa039e0c1 [nfs]
           #5 [ffff8810343bf4f8] nfs_release_page at ffffffffa038bef6 [nfs]
           #6 [ffff8810343bf528] try_to_release_page at ffffffff8110c670
           #7 [ffff8810343bf538] shrink_page_list.clone.0 at ffffffff81126271
           #8 [ffff8810343bf668] shrink_inactive_list at ffffffff81126638
           #9 [ffff8810343bf818] shrink_zone at ffffffff8112788f
          #10 [ffff8810343bf8c8] do_try_to_free_pages at ffffffff81127b1e
          #11 [ffff8810343bf958] try_to_free_pages at ffffffff8112812f
          #12 [ffff8810343bfa08] __alloc_pages_nodemask at ffffffff8111fdad
          #13 [ffff8810343bfb28] kmem_getpages at ffffffff81159942
          #14 [ffff8810343bfb58] fallback_alloc at ffffffff8115a55a
          #15 [ffff8810343bfbd8] ____cache_alloc_node at ffffffff8115a2d9
          #16 [ffff8810343bfc38] kmem_cache_alloc at ffffffff8115b09b
          #17 [ffff8810343bfc78] sk_prot_alloc at ffffffff81411808
          #18 [ffff8810343bfcb8] sk_alloc at ffffffff8141197c
          #19 [ffff8810343bfce8] inet_create at ffffffff81483ba6
          #20 [ffff8810343bfd38] __sock_create at ffffffff8140b4a7
          #21 [ffff8810343bfd98] xs_create_sock at ffffffffa01f649b [sunrpc]
          #22 [ffff8810343bfdd8] xs_tcp_setup_socket at ffffffffa01f6965 [sunrpc]
          #23 [ffff8810343bfe38] worker_thread at ffffffff810887d0
          #24 [ffff8810343bfee8] kthread at ffffffff8108dd96
          #25 [ffff8810343bff48] kernel_thread at ffffffff8100c1ca
      
      rpciod is trying to allocate memory for a new socket to talk to the
      server. The VM ends up calling ->releasepage to get more memory, and it
      tries to do a blocking commit. That commit can't succeed however without
      a connected socket, so we deadlock.
      
      Fix this by setting PF_FSTRANS on the workqueue task prior to doing the
      socket allocation, and having nfs_release_page check for that flag when
      deciding whether to do a commit call. Also, set PF_FSTRANS
      unconditionally in rpc_async_schedule since that function can also do
      allocations sometimes.
      Signed-off-by: NJeff Layton <jlayton@redhat.com>
      Signed-off-by: NTrond Myklebust <Trond.Myklebust@netapp.com>
      Cc: stable@vger.kernel.org
      5cf02d09
    • J
      sunrpc: clarify comments on rpc_make_runnable · 506026c3
      Jeff Layton 提交于
      rpc_make_runnable is not generally called with the queue lock held, unless
      it's waking up a task that has been sitting on a waitqueue. This is safe
      when the task has not entered the FSM yet, but the comments don't really
      spell this out.
      Signed-off-by: NJeff Layton <jlayton@redhat.com>
      Signed-off-by: NTrond Myklebust <Trond.Myklebust@netapp.com>
      506026c3
    • J
      sunrpc: clnt: Add missing braces · cac5d07e
      Joe Perches 提交于
      Add a missing set of braces that commit 4e0038b6
      ("SUNRPC: Move clnt->cl_server into struct rpc_xprt")
      forgot.
      Signed-off-by: NJoe Perches <joe@perches.com>
      Signed-off-by: NTrond Myklebust <Trond.Myklebust@netapp.com>
      Cc: stable@vger.kernel.org [>= 3.4]
      cac5d07e
  2. 18 7月, 2012 1 次提交
  3. 17 7月, 2012 1 次提交
    • C
      SUNRPC: Add rpcauth_list_flavors() · 6a1a1e34
      Chuck Lever 提交于
      The gss_mech_list_pseudoflavors() function provides a list of
      currently registered GSS pseudoflavors.  This list does not include
      any non-GSS flavors that have been registered with the RPC client.
      nfs4_find_root_sec() currently adds these extra flavors by hand.
      
      Instead, nfs4_find_root_sec() should be looking at the set of flavors
      that have been explicitly registered via rpcauth_register().  And,
      other areas of code will soon need the same kind of list that
      contains all flavors the kernel currently knows about (see below).
      
      Rather than cloning the open-coded logic in nfs4_find_root_sec() to
      those new places, introduce a generic RPC function that generates a
      full list of registered auth flavors and pseudoflavors.
      
      A new rpc_authops method is added that lists a flavor's
      pseudoflavors, if it has any.  I encountered an interesting module
      loader loop when I tried to get the RPC client to invoke
      gss_mech_list_pseudoflavors() by name.
      
      This patch is a pre-requisite for server trunking discovery, and a
      pre-requisite for fixing up the in-kernel mount client to do better
      automatic security flavor selection.
      Signed-off-by: NChuck Lever <chuck.lever@oracle.com>
      Signed-off-by: NTrond Myklebust <Trond.Myklebust@netapp.com>
      6a1a1e34
  4. 29 6月, 2012 9 次提交
  5. 27 6月, 2012 1 次提交
  6. 12 6月, 2012 1 次提交
  7. 01 6月, 2012 8 次提交
  8. 20 5月, 2012 1 次提交
  9. 17 5月, 2012 2 次提交
  10. 16 5月, 2012 1 次提交
  11. 15 5月, 2012 1 次提交
    • R
      sunrpc: fix kernel-doc warnings · bda14606
      Randy Dunlap 提交于
      Fix kernel-doc warnings in sunrpc/rpc_pipe.c and
      sunrpc/rpcb_clnt.c:
      
      Warning(net/sunrpc/rpcb_clnt.c:428): No description found for parameter 'net'
      Warning(net/sunrpc/rpcb_clnt.c:567): No description found for parameter 'net'
      
      Warning(net/sunrpc/rpc_pipe.c:133): No description found for parameter 'pipe'
      Warning(net/sunrpc/rpc_pipe.c:133): Excess function parameter 'inode' description in 'rpc_queue_upcall'
      Warning(net/sunrpc/rpc_pipe.c:839): No description found for parameter 'pipe'
      Warning(net/sunrpc/rpc_pipe.c:839): Excess function parameter 'ops' description in 'rpc_mkpipe_dentry'
      Warning(net/sunrpc/rpc_pipe.c:839): Excess function parameter 'flags' description in 'rpc_mkpipe_dentry'
      Warning(net/sunrpc/rpc_pipe.c:949): No description found for parameter 'dentry'
      Warning(net/sunrpc/rpc_pipe.c:949): Excess function parameter 'clnt' description in 'rpc_remove_client_dir'
      Signed-off-by: NRandy Dunlap <rdunlap@xenotime.net>
      Signed-off-by: NTrond Myklebust <Trond.Myklebust@netapp.com>
      bda14606
  12. 11 5月, 2012 1 次提交
    • L
      vfs: make it possible to access the dentry hash/len as one 64-bit entry · 26fe5750
      Linus Torvalds 提交于
      This allows comparing hash and len in one operation on 64-bit
      architectures.  Right now only __d_lookup_rcu() takes advantage of this,
      since that is the case we care most about.
      
      The use of anonymous struct/unions hides the alternate 64-bit approach
      from most users, the exception being a few cases where we initialize a
      'struct qstr' with a static initializer.  This makes the problematic
      cases use a new QSTR_INIT() helper function for that (but initializing
      just the name pointer with a "{ .name = xyzzy }" initializer remains
      valid, as does just copying another qstr structure).
      Signed-off-by: NLinus Torvalds <torvalds@linux-foundation.org>
      26fe5750
  13. 04 5月, 2012 1 次提交
  14. 03 5月, 2012 1 次提交
  15. 30 4月, 2012 1 次提交
  16. 28 4月, 2012 4 次提交
  17. 26 4月, 2012 1 次提交
  18. 22 4月, 2012 1 次提交
  19. 18 4月, 2012 1 次提交