]> git.hungrycats.org Git - linux/commit
ceph: pass cred pointer to ceph_mds_auth_match()
authorMax Kellermann <max.kellermann@ionos.com>
Sat, 23 Nov 2024 07:21:20 +0000 (08:21 +0100)
committerIlya Dryomov <idryomov@gmail.com>
Mon, 25 Nov 2024 14:51:13 +0000 (15:51 +0100)
commit23426309a4064b25a961e1c72961d8bfc7c8c990
treee5594236532ff33a6c35a5f119c39100b8f4a970
parent8ea412e181310666b4b36573480fc64425313d8b
ceph: pass cred pointer to ceph_mds_auth_match()

This eliminates a redundant get_current_cred() call, because
ceph_mds_check_access() has already obtained this pointer.

As a side effect, this also fixes a reference leak in
ceph_mds_auth_match(): by omitting the get_current_cred() call, no
additional cred reference is taken.

Cc: stable@vger.kernel.org
Fixes: 596afb0b8933 ("ceph: add ceph_mds_check_access() helper")
Signed-off-by: Max Kellermann <max.kellermann@ionos.com>
Reviewed-by: Xiubo Li <xiubli@redhat.com>
Signed-off-by: Ilya Dryomov <idryomov@gmail.com>
fs/ceph/mds_client.c