]> git-server-git.apps.pok.os.sepia.ceph.com Git - ceph.git/commit
client: add mount/initialize states support and convert to RWRef
authorXiubo Li <xiubli@redhat.com>
Sun, 2 Aug 2020 00:35:24 +0000 (08:35 +0800)
committerXiubo Li <xiubli@redhat.com>
Thu, 6 Aug 2020 08:23:29 +0000 (16:23 +0800)
commit1198a47b97dc8dc6293e3f9b6aa2aaf0e2ff39b1
tree90e2544a8962ca11ea7434361e1210d15db085f9
parent96514a11ff52b98eb9ae5bc1cdb88dea551b6944
client: add mount/initialize states support and convert to RWRef

This will help us to break the big client_lock. Such as if we want
to add one separate lock for each inode, it will work like:

inode_lock.lock();
...
client_lock.lock();

client_lock.unlock();
...
inode_lock.unlock();

So we must get rid of the client_lock for all the "readers", which
must hold the client_lock from the beginning until the end.

Fixes: https://tracker.ceph.com/issues/46649
Signed-off-by: Xiubo Li <xiubli@redhat.com>
src/client/Client.cc
src/client/Client.h