public inbox for linux-man@vger.kernel.org
 help / color / mirror / Atom feed
From: "Alejandro Colomar (man-pages)" <alx.manpages@gmail.com>
To: Alex Baranowski <alexbaranowski@euro-linux.com>
Cc: linux-man@vger.kernel.org, mtk.manpages@gmail.com
Subject: Re: [PATCH] fixes on swapon.2 CONFIG_DEVICE_PRIVATE decreases number of available swap files
Date: Tue, 25 Jan 2022 19:29:23 +0100	[thread overview]
Message-ID: <42c8d669-e3b6-2231-e273-fb6c7ec0fda7@gmail.com> (raw)
In-Reply-To: <d3bc64b3-a1ec-7165-1eed-506d348762c3@euro-linux.com>

Hello Alex,

On 1/17/22 23:21, Alex Baranowski wrote:
> Howdy (It's probably the nearest thing to Polish Siemanko!)!
> 
> Firstly I'm sorry - I might send empty mail before this one (misclick).
> 
> I noticed that swapon docs are missing some newer information about
> CONFIG_DEVICE_PRIVATE that decreases the number of available swap files.
> When it comes to kernel versions that I used
> https://elixir.bootlin.com/linux/v5.14/source/include/linux/swap.h and
> https://elixir.bootlin.com/linux/v4.14/source/include/linux/swap.h to
> check when the changes were introduced. I also tested the manage with
> `man path-to-file` if it looks OK. I signed off as Aleksander Baranowski
> as it is my legal name.
> 
> Patch:
> 
> From 547cff381f0321dd6bffdaa2cc5c6fe9b44464ef Mon Sep 17 00:00:00 2001
> From: Alex Baranowski <alex@euro-linux.com>
> Date: Mon, 17 Jan 2022 22:36:34 +0100
> Subject: [PATCH] fixes on swapon.2 CONFIG_DEVICE_PRIVATE decreases
> number of
>  available swap files
> 
> Signed-off-by: Aleksander Baranowski <alex@euro-linux.com>

I tried to apply your patch, but it didn't work (maybe your mailer
messed with it?).  So I applied a similar patch based on yours.  I used
a text more similar to the surrounding text, to make it a bit more
consistent.

<http://www.alejandro-colomar.es/src/alx/linux/man-pages/man-pages.git/commit/?id=c56180ba830bfd5c5f0668b74e3b3ccc90716c3b>

Thanks!

Alex

    swapon.2: CONFIG_DEVICE_PRIVATE decreases number of available swap
files by 4

    [Aleksander]:
    I noticed that swapon docs are missing some newer information
    about CONFIG_DEVICE_PRIVATE that decreases the number of available
    swap files.  When it comes to kernel versions that I used
    <https://elixir.bootlin.com/linux/v5.14/source/include/linux/swap.h>
    and
    <https://elixir.bootlin.com/linux/v4.14/source/include/linux/swap.h>
    to check when the changes were introduced.

    Reported-by: Aleksander Baranowski <alex@euro-linux.com>
    Signed-off-by: Alejandro Colomar <alx.manpages@gmail.com>

diff --git a/man2/swapon.2 b/man2/swapon.2
index 07d5fe86c..29e32f308 100644
--- a/man2/swapon.2
+++ b/man2/swapon.2
@@ -33,6 +33,9 @@
 .\" 2004-12-14 mtk, Anand Kumria: added new errors
 .\" 2007-06-22 Ivana Varekova <varekova@redhat.com>, mtk
 .\"     Update text describing limit on number of swap files.
+.\" 2021-01-17 Alex Baranowski <alex@euro-linux.com>
+.\"     Update information about available swap files decreased by
+.\"     CONFIG_DEVICE_PRIVATE option.
 .\"
 .\" FIXME Linux 3.11 added SWAP_FLAG_DISCARD_ONCE and
SWAP_FLAG_DISCARD_PAGES
 .\"    commit dcf6b7ddd7df8965727746f89c59229b23180e5a
@@ -190,6 +193,10 @@ Since kernel 2.6.32, the limit is further decreased
by 1
 if the kernel is built with the
 .B CONFIG_MEMORY_FAILURE
 option.
+Since kernel 5.14, the limit is further decreased by 4
+if the kernel is built with the
+.B CONFIG_DEVICE_PRIVATE
+option.
 .PP
 Discard of swap pages was introduced in kernel 2.6.29,
 then made conditional


-- 
Alejandro Colomar
Linux man-pages comaintainer; https://www.kernel.org/doc/man-pages/
http://www.alejandro-colomar.es/

  reply	other threads:[~2022-01-25 18:29 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-01-17 22:21 [PATCH] fixes on swapon.2 CONFIG_DEVICE_PRIVATE decreases number of available swap files Alex Baranowski
2022-01-25 18:29 ` Alejandro Colomar (man-pages) [this message]
  -- strict thread matches above, loose matches on Subject: below --
2022-01-17 21:40 [PATCH] fixes on swapon.2 CONFIG_DEVICE_PRIVATE decreases number of, " Alex Baranowski

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=42c8d669-e3b6-2231-e273-fb6c7ec0fda7@gmail.com \
    --to=alx.manpages@gmail.com \
    --cc=alexbaranowski@euro-linux.com \
    --cc=linux-man@vger.kernel.org \
    --cc=mtk.manpages@gmail.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox