android_kernel_xiaomi_sm8450/fs/verity
Christian Brauner b0fa673c8c fs: add file and path permissions helpers
[ Upstream commit 02f92b3868a1b34ab98464e76b0e4e060474ba10 ]

Add two simple helpers to check permissions on a file and path
respectively and convert over some callers. It simplifies quite a few
codepaths and also reduces the churn in later patches quite a bit.
Christoph also correctly points out that this makes codepaths (e.g.
ioctls) way easier to follow that would otherwise have to do more
complex argument passing than necessary.

Link: https://lore.kernel.org/r/20210121131959.646623-4-christian.brauner@ubuntu.com
Cc: David Howells <dhowells@redhat.com>
Cc: Al Viro <viro@zeniv.linux.org.uk>
Cc: linux-fsdevel@vger.kernel.org
Suggested-by: Christoph Hellwig <hch@lst.de>
Reviewed-by: Christoph Hellwig <hch@lst.de>
Reviewed-by: James Morris <jamorris@linux.microsoft.com>
Signed-off-by: Christian Brauner <christian.brauner@ubuntu.com>
Signed-off-by: Chuck Lever <chuck.lever@oracle.com>
Signed-off-by: Sasha Levin <sashal@kernel.org>
2024-06-21 14:52:58 +02:00
..
enable.c fs: add file and path permissions helpers 2024-06-21 14:52:58 +02:00
fsverity_private.h fs-verity: remove unnecessary extern keywords 2020-05-12 16:44:00 -07:00
hash_algs.c fs-verity: use mempool for hash requests 2020-01-14 13:28:05 -08:00
init.c fs-verity: support builtin file signatures 2019-08-12 19:33:50 -07:00
Kconfig fs-verity: support builtin file signatures 2019-08-12 19:33:50 -07:00
Makefile fs-verity: support builtin file signatures 2019-08-12 19:33:50 -07:00
measure.c fs-verity: fix all kerneldoc warnings 2020-05-12 16:43:59 -07:00
open.c fs-verity: fix signed integer overflow with i_size near S64_MAX 2021-10-06 15:55:46 +02:00
signature.c fsverity: skip PKCS#7 parser when keyring is empty 2023-09-19 12:20:22 +02:00
verify.c fsverity: Remove WQ_UNBOUND from fsverity read workqueue 2023-04-05 11:23:40 +02:00