]> git.baikalelectronics.ru Git - kernel.git/commit
ceph: fix auth cap handling logic in remove_session_caps_cb
authorJeff Layton <jlayton@kernel.org>
Thu, 2 Sep 2021 16:47:01 +0000 (12:47 -0400)
committerIlya Dryomov <idryomov@gmail.com>
Mon, 8 Nov 2021 02:29:51 +0000 (03:29 +0100)
commit5dc9d593fb667deed4d1b475e90057073b2e219e
tree59d272dacf493f6fc83e9e1e37791c0dff5bd19e
parentd39ff78cb1b44d92f50fb6b613e2817b89711a0b
ceph: fix auth cap handling logic in remove_session_caps_cb

The existing logic relies on ci->i_auth_cap being NULL, but if we end up
removing the auth cap early, then we'll do a lot of useless work and
lock-taking on the remaining caps. Ensure that we only do the auth cap
removal when we're _actually_ removing the auth cap.

Signed-off-by: Jeff Layton <jlayton@kernel.org>
Signed-off-by: Ilya Dryomov <idryomov@gmail.com>
fs/ceph/mds_client.c