]> git.baikalelectronics.ru Git - kernel.git/commit
ceph: only queue async writeback on cap revocation if there is dirty data
authorSage Weil <sage@newdream.net>
Thu, 5 Aug 2010 20:53:18 +0000 (13:53 -0700)
committerSage Weil <sage@newdream.net>
Thu, 5 Aug 2010 20:53:40 +0000 (13:53 -0700)
commit60c0cd930e7a88d8c1ffda1bc5cf34b3360fd75d
tree7974963003e0b8ef26fdfb3a8120c6b4b588a01b
parentf86725260c6625bd8081bb014703a9023d7cf86f
ceph: only queue async writeback on cap revocation if there is dirty data

Normally, if the Fb cap bit is being revoked, we queue an async writeback.
If there is no dirty data but we still hold the cap, this leaves the
client sitting around doing nothing until the cap timeouts expire and the
cap is released on its own (as it would have been without the revocation).

Instead, only queue writeback if the bit is actually used (i.e., we have
dirty data).  If not, we can reply to the revocation immediately.

Signed-off-by: Sage Weil <sage@newdream.net>
fs/ceph/caps.c