WSL2-Linux-Kernel/fs/cachefiles
Christian Brauner b3679e8b59 fs: add is_idmapped_mnt() helper
commit bb49e9e730 upstream.

Multiple places open-code the same check to determine whether a given
mount is idmapped. Introduce a simple helper function that can be used
instead. This allows us to get rid of the fragile open-coding. We will
later change the check that is used to determine whether a given mount
is idmapped. Introducing a helper allows us to do this in a single
place instead of doing it for multiple places.

Link: https://lore.kernel.org/r/20211123114227.3124056-2-brauner@kernel.org (v1)
Link: https://lore.kernel.org/r/20211130121032.3753852-2-brauner@kernel.org (v2)
Link: https://lore.kernel.org/r/20211203111707.3901969-2-brauner@kernel.org
Cc: Seth Forshee <sforshee@digitalocean.com>
Cc: Christoph Hellwig <hch@lst.de>
Cc: Al Viro <viro@zeniv.linux.org.uk>
CC: linux-fsdevel@vger.kernel.org
Reviewed-by: Amir Goldstein <amir73il@gmail.com>
Reviewed-by: Seth Forshee <sforshee@digitalocean.com>
Signed-off-by: Christian Brauner <christian.brauner@ubuntu.com>
Signed-off-by: Christian Brauner (Microsoft) <brauner@kernel.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2022-07-02 16:41:14 +02:00
..
Kconfig fscache, cachefiles: Remove the histogram stuff 2021-08-27 13:34:02 +01:00
Makefile fscache, cachefiles: Remove the histogram stuff 2021-08-27 13:34:02 +01:00
bind.c fs: add is_idmapped_mnt() helper 2022-07-02 16:41:14 +02:00
daemon.c treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 36 2019-05-24 17:27:11 +02:00
interface.c cachefiles: Change %p in format strings to something else 2021-08-27 13:34:02 +01:00
internal.h fscache, cachefiles: Remove the histogram stuff 2021-08-27 13:34:02 +01:00
io.c cachefiles: Use file_inode() rather than accessing ->f_inode 2021-08-25 15:20:25 +01:00
key.c cachefiles: Change %p in format strings to something else 2021-08-27 13:34:02 +01:00
main.c fscache, cachefiles: Remove the histogram stuff 2021-08-27 13:34:02 +01:00
namei.c cachefiles: Change %p in format strings to something else 2021-08-27 13:34:02 +01:00
rdwr.c fs/cachefiles: Remove wait_bit_key layout dependency 2021-03-23 20:54:29 +00:00
security.c treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 36 2019-05-24 17:27:11 +02:00
xattr.c cachefiles: Change %p in format strings to something else 2021-08-27 13:34:02 +01:00