linux-doc.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] docs: fscrypt: document EFAULT return for FS_IOC_SET_ENCRYPTION_POLICY
@ 2025-10-10 15:47 Divya Bharathi
  2025-10-10 20:39 ` Eric Biggers
  0 siblings, 1 reply; 2+ messages in thread
From: Divya Bharathi @ 2025-10-10 15:47 UTC (permalink / raw)
  To: linux-fscrypt
  Cc: ebiggers, tytso, aegeuk, orbet, linux-doc, linux-kernel,
	Divya Bharathi

Signed-off-by: Divya Bharathi <divya27392@gmail.com>
---
 Documentation/filesystems/fscrypt.rst | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/Documentation/filesystems/fscrypt.rst b/Documentation/filesystems/fscrypt.rst
index 4a3e844b7..26cb409e3 100644
--- a/Documentation/filesystems/fscrypt.rst
+++ b/Documentation/filesystems/fscrypt.rst
@@ -729,6 +729,8 @@ FS_IOC_SET_ENCRYPTION_POLICY can fail with the following errors:
   version, mode(s), or flags; or reserved bits were set); or a v1
   encryption policy was specified but the directory has the casefold
   flag enabled (casefolding is incompatible with v1 policies).
+- ``EFAULT``: an invalid pointer was passed for the encryption policy
+  structure
 - ``ENOKEY``: a v2 encryption policy was specified, but the key with
   the specified ``master_key_identifier`` has not been added, nor does
   the process have the CAP_FOWNER capability in the initial user
-- 
2.51.0


^ permalink raw reply related	[flat|nested] 2+ messages in thread

* Re: [PATCH] docs: fscrypt: document EFAULT return for FS_IOC_SET_ENCRYPTION_POLICY
  2025-10-10 15:47 [PATCH] docs: fscrypt: document EFAULT return for FS_IOC_SET_ENCRYPTION_POLICY Divya Bharathi
@ 2025-10-10 20:39 ` Eric Biggers
  0 siblings, 0 replies; 2+ messages in thread
From: Eric Biggers @ 2025-10-10 20:39 UTC (permalink / raw)
  To: Divya Bharathi
  Cc: linux-fscrypt, tytso, jaegeuk, corbet, linux-doc, linux-kernel

On Fri, Oct 10, 2025 at 09:17:53PM +0530, Divya Bharathi wrote:
> Signed-off-by: Divya Bharathi <divya27392@gmail.com>
> ---
>  Documentation/filesystems/fscrypt.rst | 2 ++
>  1 file changed, 2 insertions(+)
> 
> diff --git a/Documentation/filesystems/fscrypt.rst b/Documentation/filesystems/fscrypt.rst
> index 4a3e844b7..26cb409e3 100644
> --- a/Documentation/filesystems/fscrypt.rst
> +++ b/Documentation/filesystems/fscrypt.rst
> @@ -729,6 +729,8 @@ FS_IOC_SET_ENCRYPTION_POLICY can fail with the following errors:
>    version, mode(s), or flags; or reserved bits were set); or a v1
>    encryption policy was specified but the directory has the casefold
>    flag enabled (casefolding is incompatible with v1 policies).
> +- ``EFAULT``: an invalid pointer was passed for the encryption policy
> +  structure
>  - ``ENOKEY``: a v2 encryption policy was specified, but the key with
>    the specified ``master_key_identifier`` has not been added, nor does
>    the process have the CAP_FOWNER capability in the initial user
> -- 
> 2.51.0
> 

Thanks for the patch!

I think I omitted EFAULT intentionally, since it's always a possibility
for almost any ioctl or syscall that takes a pointer parameter.

If we'd like to explicitly document it, it probably should be documented
for all the ioctls in fscrypt.rst, rather than just
FS_IOC_SET_ENCRYPTION_POLICY.

Also, the list of error codes is alphabetized.  EFAULT should go into
the correct position in the list.

- Eric

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2025-10-10 20:39 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2025-10-10 15:47 [PATCH] docs: fscrypt: document EFAULT return for FS_IOC_SET_ENCRYPTION_POLICY Divya Bharathi
2025-10-10 20:39 ` Eric Biggers

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).