OSDN Git Service

ceph: only check pool permissions for regular files
authorJeff Layton <jlayton@kernel.org>
Tue, 26 Jan 2021 16:49:54 +0000 (11:49 -0500)
committerIlya Dryomov <idryomov@gmail.com>
Tue, 27 Apr 2021 21:52:23 +0000 (23:52 +0200)
commite9b2250156c381b0973ea6ec3890fe8706426ecc
tree56bf404e8d2b95ee2a6b59638ffb26fb1c615c72
parent3d8b6987a276f4292b5b71f4df8fe34129ab9e5d
ceph: only check pool permissions for regular files

There is no need to do a ceph_pool_perm_check() on anything that isn't a
regular file, as the MDS is what handles talking to the OSD in those
cases. Just return 0 if it's not a regular file.

Reported-by: Luis Henriques <lhenriques@suse.de>
Signed-off-by: Jeff Layton <jlayton@kernel.org>
Reviewed-by: Xiubo Li <xiubli@redhat.com>
Signed-off-by: Ilya Dryomov <idryomov@gmail.com>
fs/ceph/addr.c