]> git.karo-electronics.de Git - karo-tx-linux.git/commit
ceph: avoid calling ceph_renew_caps() infinitely
authorYan, Zheng <zyan@redhat.com>
Sun, 29 Jan 2017 14:15:47 +0000 (22:15 +0800)
committerIlya Dryomov <idryomov@gmail.com>
Mon, 20 Feb 2017 11:16:07 +0000 (12:16 +0100)
commitc1944fedd8c492ce1c1a99ca9064dcc7bafa80e9
tree391d043097c793dacc36aae7c9c9e354d80553bb
parent00f06cba53f53f3f7be8ac4f9ba2c2f6a94bca6f
ceph: avoid calling ceph_renew_caps() infinitely

__ceph_caps_mds_wanted() ignores caps from stale session. So the
return value of __ceph_caps_mds_wanted() can keep the same across
ceph_renew_caps(). This causes try_get_cap_refs() to keep calling
ceph_renew_caps(). The fix is ignore the session valid check for
the try_get_cap_refs() case. If session is stale, just let the
caps requester sleep.

Signed-off-by: Yan, Zheng <zyan@redhat.com>
fs/ceph/caps.c
fs/ceph/file.c
fs/ceph/super.h