OpenVZ Forum


Home » Mailing lists » Devel » [PATCH 2/4] NFS: replace per-net client lock by mutex
Re: [PATCH 2/4] NFS: replace per-net client lock by mutex [message #45338 is a reply to message #45334] Mon, 27 February 2012 15:00 Go to previous messageGo to previous message
Myklebust, Trond is currently offline  Myklebust, Trond
Messages: 52
Registered: November 2011
Member
On Mon, 2012-02-27 at 17:49 +0400, Stanislav Kinsbursky wrote:
> Lockdep is sad otherwise, because inode mutex is taken on PipeFS dentry
> creation, which can be called on mount notification, where this per-net client
> lock is taken on clients list walk.
>
> Note: I used simple mutex instead of rw semaphore because of
> nfs_put_client->atomic_dec_and_mutex_lock() call. Probably, there is a better
> solution here.
>
> Signed-off-by: Stanislav Kinsbursky <skinsbursky@parallels.com>
>

This is overkill... We end up blocking NFSv4 callbacks while the
rpc_pipefs notifier runs through the nfs_clients creating or destroying
idmapper dentries.

Surely the rpc_pipefs_event() can take a reference to the nfs_client and
then drop the spin_lock if it sees that it needs to create or destroy a
dentry?

--
Trond Myklebust
Linux NFS client maintainer

NetApp
Trond.Myklebust@netapp.com
www.netapp.com
 
Read Message
Read Message
Read Message
Previous Topic: [PATCH 0/4] SUNRPC: several fixes around PipeFS objects
Next Topic: [PATCH v2 0/4] SUNRPC: several fixes around PipeFS objects
Goto Forum:
  


Current Time: Tue Aug 26 02:10:59 GMT 2025

Total time taken to generate the page: 0.05749 seconds