linux-api.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH v2] fideduperange.2: fix the discussion of maximum sizes
@ 2016-11-23  4:48 Darrick J. Wong
       [not found] ` <20161123044816.GG16807-PTl6brltDGh4DFYR7WNSRA@public.gmane.org>
  0 siblings, 1 reply; 4+ messages in thread
From: Darrick J. Wong @ 2016-11-23  4:48 UTC (permalink / raw)
  To: mtk.manpages-Re5JQEeQqe8AvxtiuMwx3w
  Cc: linux-fsdevel-u79uwXL29TY76Z2rM5mHXA,
	linux-api-u79uwXL29TY76Z2rM5mHXA,
	linux-xfs-u79uwXL29TY76Z2rM5mHXA,
	linux-btrfs-u79uwXL29TY76Z2rM5mHXA,
	linux-man-u79uwXL29TY76Z2rM5mHXA, osandov-nWWhXC5lh1RBDgjK7y7TUQ

Fix the discussion of the limitations on the dest_count and src_length
parameters to the fideduperange ioctl to reflect what's actually in the
kernel.

Signed-off-by: Darrick J. Wong <darrick.wong-QHcLZuEGTsvQT0dZR+AlfA@public.gmane.org>
---
 man2/ioctl_fideduperange.2 |   20 +++++++++++++++++---
 1 file changed, 17 insertions(+), 3 deletions(-)

diff --git a/man2/ioctl_fideduperange.2 b/man2/ioctl_fideduperange.2
index 2112d10..057229d 100644
--- a/man2/ioctl_fideduperange.2
+++ b/man2/ioctl_fideduperange.2
@@ -95,7 +95,7 @@ struct file_dedupe_range_info {
 .in
 
 Each deduplication operation targets
-.IR length
+.IR src_length
 bytes in file descriptor
 .IR dest_fd
 at offset
@@ -108,8 +108,15 @@ During the call,
 must be open for reading and
 .IR dest_fd
 must be open for writing.
-For any call to this ioctl, there may not be more than 65,536
-requests attached; each request may not exceed 16MiB.
+The combined size of the struct
+.IR file_dedupe_range
+and the struct
+.IR file_dedupe_range_info
+array must not exceed the system page size.
+The maximum size of
+.IR src_length
+is filesystem dependent and is typically 16MiB.
+This limit will be enforced silently by the filesystem.
 By convention, the storage used by
 .IR src_fd
 is mapped into
@@ -144,6 +151,13 @@ is set to indicate the error.
 .SH ERRORS
 Error codes can be one of, but are not limited to, the following:
 .TP
+.B ENOMEM
+The kernel was unable to allocate sufficient memory to perform the
+operation or
+.IR dest_count
+is so large that the input argument description spans more than a single
+page of memory.
+.TP
 .B EBADF
 .IR src_fd
 is not open for reading;
--
To unsubscribe from this list: send the line "unsubscribe linux-man" in
the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

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

* Re: [PATCH v2] fideduperange.2: fix the discussion of maximum sizes
       [not found] ` <20161123044816.GG16807-PTl6brltDGh4DFYR7WNSRA@public.gmane.org>
@ 2016-11-23  4:49   ` Omar Sandoval
  2016-11-23  7:06     ` Michael Kerrisk (man-pages)
  2016-11-23  7:05   ` Michael Kerrisk (man-pages)
  1 sibling, 1 reply; 4+ messages in thread
From: Omar Sandoval @ 2016-11-23  4:49 UTC (permalink / raw)
  To: Darrick J. Wong
  Cc: mtk.manpages-Re5JQEeQqe8AvxtiuMwx3w,
	linux-fsdevel-u79uwXL29TY76Z2rM5mHXA,
	linux-api-u79uwXL29TY76Z2rM5mHXA,
	linux-xfs-u79uwXL29TY76Z2rM5mHXA,
	linux-btrfs-u79uwXL29TY76Z2rM5mHXA,
	linux-man-u79uwXL29TY76Z2rM5mHXA

On Tue, Nov 22, 2016 at 08:48:16PM -0800, Darrick J. Wong wrote:
> Fix the discussion of the limitations on the dest_count and src_length
> parameters to the fideduperange ioctl to reflect what's actually in the
> kernel.
> 
> Signed-off-by: Darrick J. Wong <darrick.wong-QHcLZuEGTsvQT0dZR+AlfA@public.gmane.org>
> ---
>  man2/ioctl_fideduperange.2 |   20 +++++++++++++++++---
>  1 file changed, 17 insertions(+), 3 deletions(-)
> 
> diff --git a/man2/ioctl_fideduperange.2 b/man2/ioctl_fideduperange.2
> index 2112d10..057229d 100644
> --- a/man2/ioctl_fideduperange.2
> +++ b/man2/ioctl_fideduperange.2
> @@ -95,7 +95,7 @@ struct file_dedupe_range_info {
>  .in
>  
>  Each deduplication operation targets
> -.IR length
> +.IR src_length
>  bytes in file descriptor
>  .IR dest_fd
>  at offset
> @@ -108,8 +108,15 @@ During the call,
>  must be open for reading and
>  .IR dest_fd
>  must be open for writing.
> -For any call to this ioctl, there may not be more than 65,536
> -requests attached; each request may not exceed 16MiB.
> +The combined size of the struct
> +.IR file_dedupe_range
> +and the struct
> +.IR file_dedupe_range_info
> +array must not exceed the system page size.
> +The maximum size of
> +.IR src_length
> +is filesystem dependent and is typically 16MiB.
> +This limit will be enforced silently by the filesystem.
>  By convention, the storage used by
>  .IR src_fd
>  is mapped into
> @@ -144,6 +151,13 @@ is set to indicate the error.
>  .SH ERRORS
>  Error codes can be one of, but are not limited to, the following:
>  .TP
> +.B ENOMEM
> +The kernel was unable to allocate sufficient memory to perform the
> +operation or
> +.IR dest_count
> +is so large that the input argument description spans more than a single
> +page of memory.
> +.TP
>  .B EBADF
>  .IR src_fd
>  is not open for reading;

Reviewed-by: Omar Sandoval <osandov-b10kYP2dOMg@public.gmane.org>

-- 
Omar

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

* Re: [PATCH v2] fideduperange.2: fix the discussion of maximum sizes
       [not found] ` <20161123044816.GG16807-PTl6brltDGh4DFYR7WNSRA@public.gmane.org>
  2016-11-23  4:49   ` Omar Sandoval
@ 2016-11-23  7:05   ` Michael Kerrisk (man-pages)
  1 sibling, 0 replies; 4+ messages in thread
From: Michael Kerrisk (man-pages) @ 2016-11-23  7:05 UTC (permalink / raw)
  To: Darrick J. Wong
  Cc: mtk.manpages-Re5JQEeQqe8AvxtiuMwx3w,
	linux-fsdevel-u79uwXL29TY76Z2rM5mHXA,
	linux-api-u79uwXL29TY76Z2rM5mHXA,
	linux-xfs-u79uwXL29TY76Z2rM5mHXA,
	linux-btrfs-u79uwXL29TY76Z2rM5mHXA,
	linux-man-u79uwXL29TY76Z2rM5mHXA, osandov-nWWhXC5lh1RBDgjK7y7TUQ

On 11/23/2016 05:48 AM, Darrick J. Wong wrote:
> Fix the discussion of the limitations on the dest_count and src_length
> parameters to the fideduperange ioctl to reflect what's actually in the
> kernel.

Thanks Darrick. Applied.

Cheers,

Michael


> Signed-off-by: Darrick J. Wong <darrick.wong-QHcLZuEGTsvQT0dZR+AlfA@public.gmane.org>
> ---
>  man2/ioctl_fideduperange.2 |   20 +++++++++++++++++---
>  1 file changed, 17 insertions(+), 3 deletions(-)
> 
> diff --git a/man2/ioctl_fideduperange.2 b/man2/ioctl_fideduperange.2
> index 2112d10..057229d 100644
> --- a/man2/ioctl_fideduperange.2
> +++ b/man2/ioctl_fideduperange.2
> @@ -95,7 +95,7 @@ struct file_dedupe_range_info {
>  .in
>  
>  Each deduplication operation targets
> -.IR length
> +.IR src_length
>  bytes in file descriptor
>  .IR dest_fd
>  at offset
> @@ -108,8 +108,15 @@ During the call,
>  must be open for reading and
>  .IR dest_fd
>  must be open for writing.
> -For any call to this ioctl, there may not be more than 65,536
> -requests attached; each request may not exceed 16MiB.
> +The combined size of the struct
> +.IR file_dedupe_range
> +and the struct
> +.IR file_dedupe_range_info
> +array must not exceed the system page size.
> +The maximum size of
> +.IR src_length
> +is filesystem dependent and is typically 16MiB.
> +This limit will be enforced silently by the filesystem.
>  By convention, the storage used by
>  .IR src_fd
>  is mapped into
> @@ -144,6 +151,13 @@ is set to indicate the error.
>  .SH ERRORS
>  Error codes can be one of, but are not limited to, the following:
>  .TP
> +.B ENOMEM
> +The kernel was unable to allocate sufficient memory to perform the
> +operation or
> +.IR dest_count
> +is so large that the input argument description spans more than a single
> +page of memory.
> +.TP
>  .B EBADF
>  .IR src_fd
>  is not open for reading;
> .
> 


-- 
Michael Kerrisk
Linux man-pages maintainer; http://www.kernel.org/doc/man-pages/
Linux/UNIX System Programming Training: http://man7.org/training/
--
To unsubscribe from this list: send the line "unsubscribe linux-man" in
the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

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

* Re: [PATCH v2] fideduperange.2: fix the discussion of maximum sizes
  2016-11-23  4:49   ` Omar Sandoval
@ 2016-11-23  7:06     ` Michael Kerrisk (man-pages)
  0 siblings, 0 replies; 4+ messages in thread
From: Michael Kerrisk (man-pages) @ 2016-11-23  7:06 UTC (permalink / raw)
  To: Omar Sandoval, Darrick J. Wong
  Cc: mtk.manpages-Re5JQEeQqe8AvxtiuMwx3w,
	linux-fsdevel-u79uwXL29TY76Z2rM5mHXA,
	linux-api-u79uwXL29TY76Z2rM5mHXA,
	linux-xfs-u79uwXL29TY76Z2rM5mHXA,
	linux-btrfs-u79uwXL29TY76Z2rM5mHXA,
	linux-man-u79uwXL29TY76Z2rM5mHXA

On 11/23/2016 05:49 AM, Omar Sandoval wrote:
> On Tue, Nov 22, 2016 at 08:48:16PM -0800, Darrick J. Wong wrote:
>> Fix the discussion of the limitations on the dest_count and src_length
>> parameters to the fideduperange ioctl to reflect what's actually in the
>> kernel.
>>
>> Signed-off-by: Darrick J. Wong <darrick.wong-QHcLZuEGTsvQT0dZR+AlfA@public.gmane.org>
>> ---
>>  man2/ioctl_fideduperange.2 |   20 +++++++++++++++++---
>>  1 file changed, 17 insertions(+), 3 deletions(-)
>>
>> diff --git a/man2/ioctl_fideduperange.2 b/man2/ioctl_fideduperange.2
>> index 2112d10..057229d 100644
>> --- a/man2/ioctl_fideduperange.2
>> +++ b/man2/ioctl_fideduperange.2

[...]

> Reviewed-by: Omar Sandoval <osandov-b10kYP2dOMg@public.gmane.org>

Thanks Omar!

Cheers,

Michael


-- 
Michael Kerrisk
Linux man-pages maintainer; http://www.kernel.org/doc/man-pages/
Linux/UNIX System Programming Training: http://man7.org/training/

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

end of thread, other threads:[~2016-11-23  7:06 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2016-11-23  4:48 [PATCH v2] fideduperange.2: fix the discussion of maximum sizes Darrick J. Wong
     [not found] ` <20161123044816.GG16807-PTl6brltDGh4DFYR7WNSRA@public.gmane.org>
2016-11-23  4:49   ` Omar Sandoval
2016-11-23  7:06     ` Michael Kerrisk (man-pages)
2016-11-23  7:05   ` Michael Kerrisk (man-pages)

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).