All of lore.kernel.org
 help / color / mirror / Atom feed
From: Alejandro Colomar <alx@kernel.org>
To: Yang Xu <xuyang2018.jy@fujitsu.com>
Cc: linux-man@vger.kernel.org
Subject: Re: [PATCH 2/2] swapon.2: Adjust decreased value under CONFIG_DEVICE_PRIVATE
Date: Fri, 22 Dec 2023 10:50:31 +0100	[thread overview]
Message-ID: <ZYVb54l_2AicJCLo@debian> (raw)
In-Reply-To: <20231222030709.139005-2-xuyang2018.jy@fujitsu.com>

[-- Attachment #1: Type: text/plain, Size: 1493 bytes --]

Hi Yang,

On Thu, Dec 21, 2023 at 10:07:09PM -0500, Yang Xu wrote:
> After 4.14 kernel patch [1], it addes SWP_DEVICE_NUM macro and value is 2.
> After 5.14 kernel patch[2], it incrase this SWP_DEVICE_NUM macro to 4.
> So we should add this info in here to calculate MAX_SWAPFILES.
> 
> [1]https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/include/linux/swap.h?id=5042db43cc
> [2]https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/include/linux/swap.h?id=b756a3b5e
> Signed-off-by: Yang Xu <xuyang2018.jy@fujitsu.com>
> ---
>  man2/swapon.2 | 3 ++-
>  1 file changed, 2 insertions(+), 1 deletion(-)
> 
> diff --git a/man2/swapon.2 b/man2/swapon.2
> index b2651fc39..21d6416eb 100644
> --- a/man2/swapon.2
> +++ b/man2/swapon.2
> @@ -177,7 +177,8 @@ Since Linux 2.6.32, the limit is further decreased by 1
>  if the kernel is built with the
>  .B CONFIG_MEMORY_FAILURE
>  option.
> -Since Linux 5.14, the limit is further decreased by 4
> +Since Linux 4.14, the limit is decreased by 2,
> +since Linux 5.14, the limit is decreased by 4

Why remove "further"?  Please add in parentheses the total value after
the decrease (thus: 123) to clarify what is the limit after so many
decreases.

Have a lovely day,
Alex

>  if the kernel is built with the
>  .B CONFIG_DEVICE_PRIVATE
>  option.
> -- 
> 2.27.0
> 
> 

-- 
<https://www.alejandro-colomar.es/>
Looking for a remote C programming job at the moment.

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 833 bytes --]

  reply	other threads:[~2023-12-22  9:50 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-12-22  3:07 [PATCH 1/2] man2/swapon.2: Make description more clear Yang Xu
2023-12-22  3:07 ` [PATCH 2/2] swapon.2: Adjust decreased value under CONFIG_DEVICE_PRIVATE Yang Xu
2023-12-22  9:50   ` Alejandro Colomar [this message]
2023-12-22  9:57 ` [PATCH 1/2] man2/swapon.2: Make description more clear Alejandro Colomar

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=ZYVb54l_2AicJCLo@debian \
    --to=alx@kernel.org \
    --cc=linux-man@vger.kernel.org \
    --cc=xuyang2018.jy@fujitsu.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.